no message
This commit is contained in:
parent
8a59185156
commit
1f36606e94
1566
simple-mind-map/package-lock.json
generated
1566
simple-mind-map/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -7,6 +7,7 @@ export const CONSTANTS = {
|
|||||||
EDIT: 'edit'
|
EDIT: 'edit'
|
||||||
},
|
},
|
||||||
LAYOUT: {
|
LAYOUT: {
|
||||||
|
FORCE_DIRECTED: 'forceDirected',
|
||||||
LOGICAL_STRUCTURE: 'logicalStructure',
|
LOGICAL_STRUCTURE: 'logicalStructure',
|
||||||
LOGICAL_STRUCTURE_LEFT: 'logicalStructureLeft',
|
LOGICAL_STRUCTURE_LEFT: 'logicalStructureLeft',
|
||||||
MIND_MAP: 'mindMap',
|
MIND_MAP: 'mindMap',
|
||||||
@ -97,6 +98,10 @@ export const initRootNodePositionMap = {
|
|||||||
|
|
||||||
// 布局结构列表
|
// 布局结构列表
|
||||||
export const layoutList = [
|
export const layoutList = [
|
||||||
|
{
|
||||||
|
name: '力导向图',
|
||||||
|
value: CONSTANTS.LAYOUT.FORCE_DIRECTED
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: '逻辑结构图',
|
name: '逻辑结构图',
|
||||||
value: CONSTANTS.LAYOUT.LOGICAL_STRUCTURE
|
value: CONSTANTS.LAYOUT.LOGICAL_STRUCTURE
|
||||||
@ -155,6 +160,7 @@ export const layoutList = [
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
export const layoutValueList = [
|
export const layoutValueList = [
|
||||||
|
CONSTANTS.LAYOUT.FORCE_DIRECTED,
|
||||||
CONSTANTS.LAYOUT.LOGICAL_STRUCTURE,
|
CONSTANTS.LAYOUT.LOGICAL_STRUCTURE,
|
||||||
CONSTANTS.LAYOUT.LOGICAL_STRUCTURE_LEFT,
|
CONSTANTS.LAYOUT.LOGICAL_STRUCTURE_LEFT,
|
||||||
CONSTANTS.LAYOUT.MIND_MAP,
|
CONSTANTS.LAYOUT.MIND_MAP,
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
import merge from 'deepmerge'
|
import merge from 'deepmerge'
|
||||||
import LogicalStructure from '../../layouts/LogicalStructure'
|
import LogicalStructure from '../../layouts/LogicalStructure'
|
||||||
|
import ForceDirected from '../../layouts/ForceDirected'
|
||||||
import MindMap from '../../layouts/MindMap'
|
import MindMap from '../../layouts/MindMap'
|
||||||
import CatalogOrganization from '../../layouts/CatalogOrganization'
|
import CatalogOrganization from '../../layouts/CatalogOrganization'
|
||||||
import OrganizationStructure from '../../layouts/OrganizationStructure'
|
import OrganizationStructure from '../../layouts/OrganizationStructure'
|
||||||
@ -44,6 +45,8 @@ import { Polygon } from '@svgdotjs/svg.js'
|
|||||||
|
|
||||||
// 布局列表
|
// 布局列表
|
||||||
const layouts = {
|
const layouts = {
|
||||||
|
// 力导向图
|
||||||
|
[CONSTANTS.LAYOUT.FORCE_DIRECTED]: ForceDirected,
|
||||||
// 逻辑结构图
|
// 逻辑结构图
|
||||||
[CONSTANTS.LAYOUT.LOGICAL_STRUCTURE]: LogicalStructure,
|
[CONSTANTS.LAYOUT.LOGICAL_STRUCTURE]: LogicalStructure,
|
||||||
// 向左逻辑结构图
|
// 向左逻辑结构图
|
||||||
|
|||||||
@ -179,7 +179,7 @@ class NodeImgAdjust {
|
|||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
this.onMousedown(e)
|
this.onMousedown(e)
|
||||||
})
|
})
|
||||||
btnEl.addEventListener('mouseup', e => {
|
btnEl.addEventListener('mouseup', () => {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
//点击后直接松开异常处理; 其他事件响应之后处理
|
//点击后直接松开异常处理; 其他事件响应之后处理
|
||||||
this.hideHandleEl()
|
this.hideHandleEl()
|
||||||
|
|||||||
13604
web/package-lock.json
generated
13604
web/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -1,5 +1,6 @@
|
|||||||
// 布局结构图片映射
|
// 布局结构图片映射
|
||||||
export const layoutImgMap = {
|
export const layoutImgMap = {
|
||||||
|
forceDirected: require('../assets/img/structures/rightFishbone2.jpg'),
|
||||||
logicalStructure: require('../assets/img/structures/logicalStructure.jpg'),
|
logicalStructure: require('../assets/img/structures/logicalStructure.jpg'),
|
||||||
logicalStructureLeft: require('../assets/img/structures/logicalStructureLeft.jpg'),
|
logicalStructureLeft: require('../assets/img/structures/logicalStructureLeft.jpg'),
|
||||||
mindMap: require('../assets/img/structures/mindMap.jpg'),
|
mindMap: require('../assets/img/structures/mindMap.jpg'),
|
||||||
|
|||||||
@ -651,6 +651,10 @@ export const alignList = [
|
|||||||
|
|
||||||
// 结构列表
|
// 结构列表
|
||||||
export const layoutGroupList = [
|
export const layoutGroupList = [
|
||||||
|
{
|
||||||
|
name: 'Force directed graph',
|
||||||
|
list: ['forceDirected']
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'Logical structure',
|
name: 'Logical structure',
|
||||||
list: ['logicalStructure', 'logicalStructureLeft']
|
list: ['logicalStructure', 'logicalStructureLeft']
|
||||||
|
|||||||
@ -674,6 +674,10 @@ export const alignList = [
|
|||||||
|
|
||||||
// Danh sách cấu trúc
|
// Danh sách cấu trúc
|
||||||
export const layoutGroupList = [
|
export const layoutGroupList = [
|
||||||
|
{
|
||||||
|
name: 'Sơ đồ tư duy',
|
||||||
|
list: ['forceDirected']
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'Sơ đồ cấu trúc logic',
|
name: 'Sơ đồ cấu trúc logic',
|
||||||
list: ['logicalStructure', 'logicalStructureLeft']
|
list: ['logicalStructure', 'logicalStructureLeft']
|
||||||
|
|||||||
@ -752,6 +752,10 @@ export const alignList = [
|
|||||||
|
|
||||||
// 结构列表
|
// 结构列表
|
||||||
export const layoutGroupList = [
|
export const layoutGroupList = [
|
||||||
|
{
|
||||||
|
name: '力导向图',
|
||||||
|
list: ['forceDirected']
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: '逻辑结构图',
|
name: '逻辑结构图',
|
||||||
list: ['logicalStructure', 'logicalStructureLeft']
|
list: ['logicalStructure', 'logicalStructureLeft']
|
||||||
|
|||||||
@ -650,6 +650,10 @@ export const alignList = [
|
|||||||
|
|
||||||
// 结构列表
|
// 结构列表
|
||||||
export const layoutGroupList = [
|
export const layoutGroupList = [
|
||||||
|
{
|
||||||
|
name: '力導向圖',
|
||||||
|
list: ['forceDirected']
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: '邏輯結構圖',
|
name: '邏輯結構圖',
|
||||||
list: ['logicalStructure', 'logicalStructureLeft']
|
list: ['logicalStructure', 'logicalStructureLeft']
|
||||||
|
|||||||
@ -97,16 +97,16 @@ import Themes from 'simple-mind-map-plugin-themes'
|
|||||||
// 协同编辑插件
|
// 协同编辑插件
|
||||||
// import Cooperate from 'simple-mind-map/src/plugins/Cooperate.js'
|
// import Cooperate from 'simple-mind-map/src/plugins/Cooperate.js'
|
||||||
// 以下插件为付费插件,详情请查看开发文档。依次为:手绘风格插件、标记插件、编号插件、Freemind软件格式导入导出插件、Excel软件格式导入导出插件、待办插件、节点连线流动效果插件、动量效果插件、向右鱼骨图插件、节点链接插件、扩展节点形状插件、扩展主题列表插件
|
// 以下插件为付费插件,详情请查看开发文档。依次为:手绘风格插件、标记插件、编号插件、Freemind软件格式导入导出插件、Excel软件格式导入导出插件、待办插件、节点连线流动效果插件、动量效果插件、向右鱼骨图插件、节点链接插件、扩展节点形状插件、扩展主题列表插件
|
||||||
import HandDrawnLikeStyle from 'simple-mind-map-plugin-handdrawnlikestyle'
|
// import HandDrawnLikeStyle from 'simple-mind-map-plugin-handdrawnlikestyle'
|
||||||
import Notation from 'simple-mind-map-plugin-notation'
|
// import Notation from 'simple-mind-map-plugin-notation'
|
||||||
import Numbers from 'simple-mind-map-plugin-numbers'
|
// import Numbers from 'simple-mind-map-plugin-numbers'
|
||||||
import Freemind from 'simple-mind-map-plugin-freemind'
|
// import Freemind from 'simple-mind-map-plugin-freemind'
|
||||||
import Excel from 'simple-mind-map-plugin-excel'
|
// import Excel from 'simple-mind-map-plugin-excel'
|
||||||
import Checkbox from 'simple-mind-map-plugin-checkbox'
|
// import Checkbox from 'simple-mind-map-plugin-checkbox'
|
||||||
import LineFlow from 'simple-mind-map-plugin-lineflow'
|
// import LineFlow from 'simple-mind-map-plugin-lineflow'
|
||||||
import Momentum from 'simple-mind-map-plugin-momentum'
|
// import Momentum from 'simple-mind-map-plugin-momentum'
|
||||||
import RightFishbone from 'simple-mind-map-plugin-right-fishbone'
|
// import RightFishbone from 'simple-mind-map-plugin-right-fishbone'
|
||||||
import NodeLink from 'simple-mind-map-plugin-node-link'
|
// import NodeLink from 'simple-mind-map-plugin-node-link'
|
||||||
// import MoreShapes from 'simple-mind-map-plugin-more-shapes'
|
// import MoreShapes from 'simple-mind-map-plugin-more-shapes'
|
||||||
// import MoreThemes from 'simple-mind-map-plugin-more-themes'
|
// import MoreThemes from 'simple-mind-map-plugin-more-themes'
|
||||||
// npm link simple-mind-map simple-mind-map-plugin-excel simple-mind-map-plugin-freemind simple-mind-map-plugin-numbers simple-mind-map-plugin-notation simple-mind-map-plugin-handdrawnlikestyle simple-mind-map-plugin-checkbox simple-mind-map-plugin-lineflow simple-mind-map-plugin-momentum simple-mind-map-plugin-right-fishbone simple-mind-map-plugin-node-link
|
// npm link simple-mind-map simple-mind-map-plugin-excel simple-mind-map-plugin-freemind simple-mind-map-plugin-numbers simple-mind-map-plugin-notation simple-mind-map-plugin-handdrawnlikestyle simple-mind-map-plugin-checkbox simple-mind-map-plugin-lineflow simple-mind-map-plugin-momentum simple-mind-map-plugin-right-fishbone simple-mind-map-plugin-node-link
|
||||||
@ -688,10 +688,10 @@ export default {
|
|||||||
loadPlugins() {
|
loadPlugins() {
|
||||||
if (this.openNodeRichText) this.addRichTextPlugin()
|
if (this.openNodeRichText) this.addRichTextPlugin()
|
||||||
if (this.isShowScrollbar) this.addScrollbarPlugin()
|
if (this.isShowScrollbar) this.addScrollbarPlugin()
|
||||||
if (typeof HandDrawnLikeStyle !== 'undefined') {
|
// if (typeof HandDrawnLikeStyle !== 'undefined') {
|
||||||
this.$store.commit('setSupportHandDrawnLikeStyle', true)
|
// this.$store.commit('setSupportHandDrawnLikeStyle', true)
|
||||||
if (this.isUseHandDrawnLikeStyle) this.addHandDrawnLikeStylePlugin()
|
// if (this.isUseHandDrawnLikeStyle) this.addHandDrawnLikeStylePlugin()
|
||||||
}
|
// }
|
||||||
if (typeof Momentum !== 'undefined') {
|
if (typeof Momentum !== 'undefined') {
|
||||||
this.$store.commit('setSupportMomentum', true)
|
this.$store.commit('setSupportMomentum', true)
|
||||||
if (this.isUseMomentum) this.addMomentumPlugin()
|
if (this.isUseMomentum) this.addMomentumPlugin()
|
||||||
@ -853,7 +853,7 @@ export default {
|
|||||||
addHandDrawnLikeStylePlugin() {
|
addHandDrawnLikeStylePlugin() {
|
||||||
try {
|
try {
|
||||||
if (!this.mindMap) return
|
if (!this.mindMap) return
|
||||||
this.mindMap.addPlugin(HandDrawnLikeStyle)
|
// this.mindMap.addPlugin(HandDrawnLikeStyle)
|
||||||
this.mindMap.reRender()
|
this.mindMap.reRender()
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log('手绘风格插件不存在')
|
console.log('手绘风格插件不存在')
|
||||||
@ -863,7 +863,7 @@ export default {
|
|||||||
// 移除手绘风格插件
|
// 移除手绘风格插件
|
||||||
removeHandDrawnLikeStylePlugin() {
|
removeHandDrawnLikeStylePlugin() {
|
||||||
try {
|
try {
|
||||||
this.mindMap.removePlugin(HandDrawnLikeStyle)
|
// this.mindMap.removePlugin(HandDrawnLikeStyle)
|
||||||
this.mindMap.reRender()
|
this.mindMap.reRender()
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log('手绘风格插件不存在')
|
console.log('手绘风格插件不存在')
|
||||||
|
|||||||
@ -15,6 +15,7 @@
|
|||||||
@click="useLayout(item)"
|
@click="useLayout(item)"
|
||||||
:class="{ active: item === layout }"
|
:class="{ active: item === layout }"
|
||||||
>
|
>
|
||||||
|
<span style="font-size: 12px;">{{ item }}</span>
|
||||||
<img :src="layoutImgMap[item]" alt="" />
|
<img :src="layoutImgMap[item]" alt="" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user