Compare commits

..

No commits in common. "main" and "0.15.0" have entirely different histories.
main ... 0.15.0

11 changed files with 116 additions and 122 deletions

View File

@ -9,26 +9,7 @@
> 中文名:思绪思维导图。一个简单&强大的 Web 思维导图库和思维导图软件。 > 中文名:思绪思维导图。一个简单&强大的 Web 思维导图库和思维导图软件。
# 客户端和插件 本项目主要包含以下内容:
- 思绪思维导图客户端
支持Windows、Mac及Linux系统。下载地址[Github](https://github.com/wanglin2/mind-map/releases)、[百度网盘](https://pan.baidu.com/s/1C8phEJ5pagAAa-o1tU42Uw?pwd=jqfb)、[夸克网盘](https://pan.quark.cn/s/2733982f1976)
> 如果在macOS上安装后无法打开报错**不受信任**或者**移到垃圾箱**,执行下面命令后再启动即可:
> ``` shell
> sudo xattr -d com.apple.quarantine /Applications/思绪思维导图.app
> ```
- Obsidian插件
下载地址:[Github](https://github.com/wanglin2/obsidian-simplemindmap/releases)
- UTools插件
已上架[uTools](https://www.u.tools/)插件应用市场,可直接在`uTools`插件应用市场中搜索`思绪`进行安装,也可以直接访问该地址:[主页](https://www.u-tools.cn/plugins/detail/%E6%80%9D%E7%BB%AA%E6%80%9D%E7%BB%B4%E5%AF%BC%E5%9B%BE/),点击右侧的【启动】按钮进行安装
# 库
- 一个 `js` 思维导图库,不依赖任何框架,可以用来快速完成 Web 思维导图产品的开发。 - 一个 `js` 思维导图库,不依赖任何框架,可以用来快速完成 Web 思维导图产品的开发。
@ -38,6 +19,18 @@
> 在线地址:[https://wanglin2.github.io/mind-map/](https://wanglin2.github.io/mind-map/) > 在线地址:[https://wanglin2.github.io/mind-map/](https://wanglin2.github.io/mind-map/)
- 客户端和插件
> 1.独立客户端支持Windows、Mac及Linux系统。
>
> 下载地址:[Github](https://github.com/wanglin2/mind-map/releases)、[百度云盘](https://pan.baidu.com/s/1huasEbKsGNH2Af68dvWiOg?pwd=3bp3)
> 2.`uTools`插件,现已上架[uTools](https://www.u.tools/)插件应用市场。
>
> 可直接在`uTools`插件应用市场中搜索`思绪`进行安装,也可以直接访问该地址:[主页](https://www.u-tools.cn/plugins/detail/%E6%80%9D%E7%BB%AA%E6%80%9D%E7%BB%B4%E5%AF%BC%E5%9B%BE/),点击右侧的【启动】按钮进行安装。
> 3.`obsidian`插件,正在开发中,敬请期待~
- 云存储版本,如果你需要带后端的云存储版本,可以尝试我们开发的另一个项目[理想文档](https://github.com/wanglin2/lx-doc)。 - 云存储版本,如果你需要带后端的云存储版本,可以尝试我们开发的另一个项目[理想文档](https://github.com/wanglin2/lx-doc)。
# 特性 # 特性
@ -117,15 +110,27 @@ const mindMap = new MindMap({
# License # License
[MIT](./LICENSE)。保留`simple-mind-map`版权声明和注明来源的情况下可随意商用,如有疑问或不想保留可联系作者微信wanglinguanfang通过付费的方式去除。 [MIT](./LICENSE)。保留`simple-mind-map`版权声明和注明来源的情况下可随意商用,如有疑问或不想保留可联系作者通过付费的方式去除。
> 示例:可以在你应用中的关于页面、帮助页面、文档页面、开源声明等任何页面添加以下内容: > 示例:可以在你应用中的关于页面、帮助页面、文档页面、开源声明等任何页面添加以下内容:
> >
> 本产品思维导图基于SimpleMindMap项目开发版权归源项目所有[开源协议](https://github.com/wanglin2/mind-map/blob/main/LICENSE)。 > 本产品思维导图基于SimpleMindMap项目开发版权归源项目所有[开源协议](https://github.com/wanglin2/mind-map/blob/main/LICENSE)。
# 开发帮助/技术支持/咨询等 # 微信交流群
因精力有限,及重心转变,暂不提供任何开发支持(包括有偿),请见谅! 微信添加`wanglinguanfang`拉你入群。根据过往的经验大部分问题都可以通过查看issue列表或文档解决所以提问前请确保你已经阅读完了所有文档文档里没有的可在群里提问不必私聊作者如果你一定要私聊请先赞助本项目¥200+)。
<table>
<tr>
<td align="center" style="word-wrap: break-word; width: 75.0; height: 75.0">
<a href="http://drawon.cn/">
<img src="./web/src/assets/img/gzh.jpeg" width="100;" style="border-radius:50%;align-items:center;justify-content:center;overflow:hidden;padding-top:10px"/>
<br />
<sub style="font-size:14px"><b>微信公众号</b></sub>
</a>
</td>
</tr>
</table>
# star # star
@ -151,7 +156,18 @@ const mindMap = new MindMap({
</tr> </tr>
</table> </table>
# 感谢赞赏过本项目的人 # 请作者喝杯咖啡
开源不易,如果本项目有帮助到你的话,可以考虑请作者喝杯咖啡~你的赞助对项目的可持续发展非常重要,是作者持续维护的最大动力。
> 推荐使用支付宝,微信获取不到头像。转账请备注【思维导图赞助】。
> 赞助等级最强王者¥500+、星耀赞助¥300+、钻石赞助¥200+、黄金赞助¥100+)、青铜赞助
<p>
<img src="./web/src/assets/img/alipay.jpg" style="width: 300px" />
<img src="./web/src/assets/img/wechat.jpg" style="width: 300px" />
</p>
## 最强王者 ## 最强王者
@ -185,13 +201,6 @@ const mindMap = new MindMap({
<sub style="font-size:14px"><b>沨沄</b></sub> <sub style="font-size:14px"><b>沨沄</b></sub>
</a> </a>
</td> </td>
<td align="center" style="word-wrap: break-word; width: 75.0; height: 75.0">
<a href="#">
<img src="./web/src/assets/avatar/行.jpg" width="50;" style="border-radius:50%;align-items:center;justify-content:center;overflow:hidden;padding-top:10px"/>
<br />
<sub style="font-size:14px"><b></b></sub>
</a>
</td>
</tr> </tr>
</table> </table>
@ -1017,12 +1026,5 @@ const mindMap = new MindMap({
<sub style="font-size:14px"><b>Towards the future</b></sub> <sub style="font-size:14px"><b>Towards the future</b></sub>
</a> </a>
</td> </td>
<td align="center" style="word-wrap: break-word; width: 75.0; height: 75.0">
<a href="#">
<img src="./web/src/assets/avatar/default.png" width="50;" style="border-radius:50%;align-items:center;justify-content:center;overflow:hidden;padding-top:10px"/>
<br />
<sub style="font-size:14px"><b>安嘉</b></sub>
</a>
</td>
</tr> </tr>
</table> </table>

View File

@ -1,4 +1,4 @@
.imgUploadContainer[data-v-6399710d]{width:100%;height:100%;display:flex;justify-content:center;align-items:center;background-color:hsla(0,0%,100%,.9);z-index:1000}.imgUploadContainer .imgUploadPanel[data-v-6399710d]{position:relative;width:100%;font-size:22px;white-space:nowrap;color:#909090;cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none}.imgUploadContainer .imgUploadPanel .title[data-v-6399710d]{margin-bottom:15px;font-size:22px;font-weight:700;color:hsla(218,9%,51%,.8)}.imgUploadContainer .imgUploadPanel .closeBtn[data-v-6399710d]{position:absolute;right:25px;top:32px;cursor:pointer}.imgUploadContainer .imgUploadPanel .imgUploadInputArea[data-v-6399710d]{display:block;width:100%;height:200px;font-size:20px;color:rgba(51,51,51,.4);background-color:hsla(0,0%,87%,.6);border:none;outline:none;cursor:pointer;text-align:center;display:flex;justify-content:center;align-items:center;white-space:normal;padding:10px}.imgUploadContainer .imgUploadPanel #imgUploadInput[data-v-6399710d]{display:none}.imgUploadContainer .imgUploadPanel .uploadInfoBox[data-v-6399710d]{position:relative;width:100%;height:200px;background-color:hsla(0,0%,87%,.6)}.imgUploadContainer .imgUploadPanel .uploadInfoBox .previewBox[data-v-6399710d]{width:100%;height:100%;background-size:contain;background-repeat:no-repeat;background-position:50%}.imgUploadContainer .imgUploadPanel .uploadInfoBox .delBtn[data-v-6399710d]{position:absolute;right:0;top:0;cursor:pointer;width:20px;height:20px;background-color:#fff}.nodeImageDialog .title[data-v-4b797c30]{font-size:18px;margin-bottom:12px}.nodeImageDialog .inputBox[data-v-4b797c30]{display:flex;align-items:center;margin-bottom:10px}.nodeImageDialog .inputBox .label[data-v-4b797c30]{width:150px}.nodeHyperlinkDialog .item[data-v-187bf89f]{display:flex;align-items:center;margin-bottom:10px}.nodeHyperlinkDialog .item .name[data-v-187bf89f]{display:block;width:50px}.nodeIconDialog[data-v-41bec544] .el-dialog__body{padding:0 20px}.nodeIconDialog .deleteBtn[data-v-41bec544]{margin-bottom:20px}.nodeIconDialog .item[data-v-41bec544]{margin-bottom:20px;font-weight:700}.nodeIconDialog .item .title[data-v-41bec544]{margin-bottom:10px}.nodeIconDialog .item .list[data-v-41bec544]{display:flex;flex-wrap:wrap}.nodeIconDialog .item .list .icon[data-v-41bec544]{width:24px;height:24px;margin-right:10px;margin-bottom:10px;cursor:pointer;position:relative}.nodeIconDialog .item .list .icon[data-v-41bec544] img,.nodeIconDialog .item .list .icon[data-v-41bec544] svg{width:100%;height:100%}.nodeIconDialog .item .list .icon.selected[data-v-41bec544]:after{content:"";position:absolute;left:-4px;top:-4px;width:28px;height:28px;border-radius:50%;border:2px solid #409eff} .imgUploadContainer[data-v-6399710d]{width:100%;height:100%;display:flex;justify-content:center;align-items:center;background-color:hsla(0,0%,100%,.9);z-index:1000}.imgUploadContainer .imgUploadPanel[data-v-6399710d]{position:relative;width:100%;font-size:22px;white-space:nowrap;color:#909090;cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none}.imgUploadContainer .imgUploadPanel .title[data-v-6399710d]{margin-bottom:15px;font-size:22px;font-weight:700;color:hsla(218,9%,51%,.8)}.imgUploadContainer .imgUploadPanel .closeBtn[data-v-6399710d]{position:absolute;right:25px;top:32px;cursor:pointer}.imgUploadContainer .imgUploadPanel .imgUploadInputArea[data-v-6399710d]{display:block;width:100%;height:200px;font-size:20px;color:rgba(51,51,51,.4);background-color:hsla(0,0%,87%,.6);border:none;outline:none;cursor:pointer;text-align:center;display:flex;justify-content:center;align-items:center;white-space:normal;padding:10px}.imgUploadContainer .imgUploadPanel #imgUploadInput[data-v-6399710d]{display:none}.imgUploadContainer .imgUploadPanel .uploadInfoBox[data-v-6399710d]{position:relative;width:100%;height:200px;background-color:hsla(0,0%,87%,.6)}.imgUploadContainer .imgUploadPanel .uploadInfoBox .previewBox[data-v-6399710d]{width:100%;height:100%;background-size:contain;background-repeat:no-repeat;background-position:50%}.imgUploadContainer .imgUploadPanel .uploadInfoBox .delBtn[data-v-6399710d]{position:absolute;right:0;top:0;cursor:pointer;width:20px;height:20px;background-color:#fff}.nodeImageDialog .title[data-v-8ebe4db2]{font-size:18px;margin-bottom:12px}.nodeImageDialog .inputBox[data-v-8ebe4db2]{display:flex;align-items:center;margin-bottom:10px}.nodeImageDialog .inputBox .label[data-v-8ebe4db2]{width:150px}.nodeHyperlinkDialog .item[data-v-187bf89f]{display:flex;align-items:center;margin-bottom:10px}.nodeHyperlinkDialog .item .name[data-v-187bf89f]{display:block;width:50px}.nodeIconDialog[data-v-41bec544] .el-dialog__body{padding:0 20px}.nodeIconDialog .deleteBtn[data-v-41bec544]{margin-bottom:20px}.nodeIconDialog .item[data-v-41bec544]{margin-bottom:20px;font-weight:700}.nodeIconDialog .item .title[data-v-41bec544]{margin-bottom:10px}.nodeIconDialog .item .list[data-v-41bec544]{display:flex;flex-wrap:wrap}.nodeIconDialog .item .list .icon[data-v-41bec544]{width:24px;height:24px;margin-right:10px;margin-bottom:10px;cursor:pointer;position:relative}.nodeIconDialog .item .list .icon[data-v-41bec544] img,.nodeIconDialog .item .list .icon[data-v-41bec544] svg{width:100%;height:100%}.nodeIconDialog .item .list .icon.selected[data-v-41bec544]:after{content:"";position:absolute;left:-4px;top:-4px;width:28px;height:28px;border-radius:50%;border:2px solid #409eff}
/*! /*!
* @toast-ui/editor * @toast-ui/editor

2
dist/js/app.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

65
dist/js/chunk-c8ebd342.js vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -9,7 +9,7 @@
}) })
} catch (error) { } catch (error) {
console.log(error) console.log(error)
}</script><link href="dist/css/chunk-vendors.css?227f61428db154a5d9bc" rel="stylesheet"><link href="dist/css/app.css?227f61428db154a5d9bc" rel="stylesheet"></head><body><noscript><strong>We're sorry but thoughts doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script>const getDataFromBackend = () => { }</script><link href="dist/css/chunk-vendors.css?685589f1058f5fbca0d2" rel="stylesheet"><link href="dist/css/app.css?685589f1058f5fbca0d2" rel="stylesheet"></head><body><noscript><strong>We're sorry but thoughts doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script>const getDataFromBackend = () => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
setTimeout(() => { setTimeout(() => {
resolve({ resolve({
@ -83,4 +83,4 @@
// 可以通过window.$bus.$on()来监听应用的一些事件 // 可以通过window.$bus.$on()来监听应用的一些事件
// 实例化页面 // 实例化页面
window.initApp() window.initApp()
}</script><script src="dist/js/chunk-vendors.js?227f61428db154a5d9bc"></script><script src="dist/js/app.js?227f61428db154a5d9bc"></script></body></html> }</script><script src="dist/js/chunk-vendors.js?685589f1058f5fbca0d2"></script><script src="dist/js/app.js?685589f1058f5fbca0d2"></script></body></html>

View File

@ -32,16 +32,9 @@ const defaultTagStyle = {
//width: 30 // 标签矩形的宽度,如果不设置,默认以文字的宽度+paddingX*2为宽度 //width: 30 // 标签矩形的宽度,如果不设置,默认以文字的宽度+paddingX*2为宽度
} }
// 获取图片的真实url
// 因为如果注册了NodeBase64ImageStorage插件那么节点图片字段保存的实际是一个id所以如果要获取图片真实的url可以通过该方法
function getImageUrl() {
const img = this.getData('image')
return (this.mindMap.renderer.renderTree.data.imgMap || {})[img] || img
}
// 创建图片节点 // 创建图片节点
function createImgNode() { function createImgNode() {
const img = this.getImageUrl() let img = this.getData('image')
if (!img) { if (!img) {
return return
} }
@ -577,7 +570,6 @@ function isUseCustomNodeContent() {
} }
export default { export default {
getImageUrl,
createImgNode, createImgNode,
getImgShowSize, getImgShowSize,
createIconNode, createIconNode,

Binary file not shown.

Before

Width:  |  Height:  |  Size: 51 KiB

View File

@ -72,7 +72,7 @@ export default {
this.reset() this.reset()
if (this.activeNodes.length > 0) { if (this.activeNodes.length > 0) {
let firstNode = this.activeNodes[0] let firstNode = this.activeNodes[0]
let img = firstNode.getImageUrl() || '' let img = firstNode.getData('image') || ''
if (img) { if (img) {
if (/^https?:\/\//.test(img)) { if (/^https?:\/\//.test(img)) {
this.imgUrl = img this.imgUrl = img

View File

@ -29,7 +29,7 @@ export default {
onNodeTmgDblclick(node, e) { onNodeTmgDblclick(node, e) {
e.stopPropagation() e.stopPropagation()
e.preventDefault() e.preventDefault()
this.images = [node.getImageUrl()] this.images = [node.nodeData.data.image]
this.$viewerApi({ this.$viewerApi({
images: this.images images: this.images
}) })