@opentiny/vue-tree
Advanced tools
Comparing version 2.9.0 to 2.10.0
@@ -84,4 +84,6 @@ function _extends() { | ||
props: { | ||
default: function _default2() { | ||
return { | ||
default: function _default2(context) { | ||
var ctx = this || context; | ||
var lazy = ctx.lazy; | ||
var defaultProps = { | ||
children: "children", | ||
@@ -91,2 +93,6 @@ label: "label", | ||
}; | ||
lazy && Object.assign(defaultProps, { | ||
isLeaf: "isLeaf" | ||
}); | ||
return defaultProps; | ||
} | ||
@@ -111,3 +117,45 @@ }, | ||
}, | ||
shrinkIcon: Object | ||
showNumber: { | ||
type: Boolean, | ||
default: false | ||
}, | ||
collapsible: { | ||
type: Boolean, | ||
default: true | ||
}, | ||
showCheckEasily: { | ||
type: Boolean, | ||
default: false | ||
}, | ||
nodeHeight: Number, | ||
shrinkIcon: Object, | ||
expandIconColor: String, | ||
shrinkIconColor: String, | ||
size: { | ||
type: String, | ||
default: "medium" | ||
}, | ||
deleteDisabledKeys: Array, | ||
editDisabledKeys: Array, | ||
addDisabledKeys: Array, | ||
theme: String, | ||
viewType: { | ||
type: String, | ||
default: "tree", | ||
validator: function validator(value) { | ||
return ~["tree", "plain"].indexOf(value); | ||
} | ||
}, | ||
pathSplit: { | ||
type: String, | ||
default: "/" | ||
}, | ||
filterPlainMethod: Function, | ||
afterLoad: Function, | ||
lazyCurrent: Boolean, | ||
baseIndent: { | ||
type: Number, | ||
default: 0 | ||
}, | ||
showLine: Boolean | ||
}), | ||
@@ -122,3 +170,3 @@ setup: function setup(props, context) { | ||
}); | ||
var version = "2.9.0"; | ||
var version = "2.10.0"; | ||
Tree.install = function(Vue) { | ||
@@ -125,0 +173,0 @@ Vue.component(Tree.name, Tree); |
398
lib/pc.js
import { renderless as renderless$1, api as api$1 } from "@opentiny/vue-renderless/tree/vue"; | ||
import { directive, h, setup as _setup, defineComponent, props } from "@opentiny/vue-common"; | ||
import { iconChevronRight, iconLoading, iconArrowBottom, iconEdit, iconMinusSquare, iconPlusSquare, iconWarning, iconMarkOn } from "@opentiny/vue-icon"; | ||
import Switch from "@opentiny/vue-switch"; | ||
import Popover from "@opentiny/vue-popover"; | ||
import Button from "@opentiny/vue-button"; | ||
import Checkbox from "@opentiny/vue-checkbox"; | ||
import Clickoutside from "@opentiny/vue-renderless/common/deps/clickoutside"; | ||
import { renderless, api } from "@opentiny/vue-renderless/tree-node/vue"; | ||
import CollapseTransition from "@opentiny/vue-collapse-transition"; | ||
import Checkbox from "@opentiny/vue-checkbox"; | ||
import { iconChevronRight, iconLoading } from "@opentiny/vue-icon"; | ||
import Radio from "@opentiny/vue-radio"; | ||
import Clickoutside from "@opentiny/vue-renderless/common/deps/clickoutside"; | ||
import Input from "@opentiny/vue-input"; | ||
function normalizeComponent(scriptExports, render, staticRenderFns, functionalTemplate, injectStyles, scopeId, moduleIdentifier, shadowMode) { | ||
@@ -85,2 +89,4 @@ var options = typeof scriptExports === "function" ? scriptExports.options : scriptExports; | ||
shrinkIcon: Object, | ||
expandIconColor: String, | ||
shrinkIconColor: String, | ||
renderContent: Function, | ||
@@ -106,3 +112,20 @@ renderAfterExpand: { | ||
} | ||
} | ||
}, | ||
showNumber: { | ||
type: Boolean, | ||
default: false | ||
}, | ||
collapsible: { | ||
type: Boolean, | ||
default: true | ||
}, | ||
nodeHeight: Number, | ||
checkEasily: { | ||
type: Boolean, | ||
default: false | ||
}, | ||
action: Object, | ||
nodeKey: String, | ||
theme: String, | ||
showLine: Boolean | ||
}, | ||
@@ -113,4 +136,9 @@ components: { | ||
TinyRadio: Radio, | ||
TinyInput: Input, | ||
IconChevronRight: iconChevronRight(), | ||
IconLoading: iconLoading(), | ||
IconArrowBottom: iconArrowBottom(), | ||
IconEdit: iconEdit(), | ||
IconMinusSquare: iconMinusSquare(), | ||
IconPlusSquare: iconPlusSquare(), | ||
MenuContext: { | ||
@@ -126,3 +154,4 @@ props: { | ||
return tree && tree.scopedSlots && tree.scopedSlots.contextmenu && tree.scopedSlots.contextmenu({ | ||
data | ||
data, | ||
node: this.node | ||
}); | ||
@@ -173,3 +202,5 @@ } | ||
var _c = _vm._self._c || _h; | ||
return _c("div", [_c("div", { | ||
return _c("div", { | ||
staticClass: "tiny-tree-node__wrapper" | ||
}, [_c("div", { | ||
directives: [{ | ||
@@ -188,3 +219,3 @@ name: "show", | ||
"is-checked": !_vm.node.disabled && _vm.node.checked | ||
}, _class["is-indeterminate"] = !_vm.node.disabled && _vm.node.indeterminate, _class["is-focusable"] = !_vm.node.disabled, _class["is-expanded"] = _vm.state.expanded, _class), | ||
}, _class["is-indeterminate"] = !_vm.node.disabled && _vm.node.indeterminate, _class["is-focusable"] = !_vm.node.disabled, _class["is-expanded"] = _vm.state.expanded, _class["is-checked"] = !_vm.node.disabled && _vm.node.checked, _class["is-loading"] = _vm.node.loading, _class["show-line"] = _vm.showLine, _class), | ||
attrs: { | ||
@@ -227,5 +258,10 @@ "role": "treeitem", | ||
}, [_c("div", { | ||
staticClass: "tiny-tree-node__content", | ||
class: { | ||
"tiny-tree-node__content": true, | ||
"tiny-tree-node__content-number": _vm.showNumber | ||
}, | ||
style: { | ||
"padding-left": (_vm.node.level - 1) * _vm.state.tree.indent + "px" | ||
"margin-left": _vm.state.computedIndent, | ||
"height": _vm.nodeHeight ? _vm.nodeHeight + "px" : void 0, | ||
"line-height": _vm.nodeHeight ? _vm.nodeHeight + "px" : void 0 | ||
}, | ||
@@ -237,3 +273,12 @@ on: { | ||
} | ||
}, [_c("span", { | ||
}, [_vm.showLine ? _c("span", { | ||
staticClass: "tiny-tree-node__content-indent", | ||
style: { | ||
width: _vm.state.computedIndent | ||
} | ||
}) : _vm._e(), _c("div", { | ||
staticClass: "tiny-tree-node__content-left" | ||
}, [_vm.showNumber ? [_c("span", { | ||
staticClass: "tree-node-number" | ||
}, [_vm._v(_vm._s(_vm.node.data.number))])] : [_c("span", { | ||
staticClass: "tree-node-icon", | ||
@@ -249,10 +294,14 @@ on: { | ||
"is-leaf": _vm.node.isLeaf | ||
}] | ||
})] : [_c(_vm.state.tree.icon ? _vm.state.tree.icon : "icon-chevron-right", { | ||
}], | ||
attrs: { | ||
"fill": _vm.state.expanded ? _vm.state.shrinkIconColor : _vm.state.expandIconColor | ||
} | ||
})] : [_c(_vm.state.computedExpandIcon, { | ||
tag: "component", | ||
class: ["tiny-tree-node__expand-icon", { | ||
"is-leaf": _vm.node.isLeaf, | ||
expanded: !_vm.node.isLeaf && _vm.state.expanded | ||
expanded: !_vm.node.isLeaf && _vm.state.expanded, | ||
"is-saas-theme": _vm.state.isSaaSTheme | ||
}] | ||
})]], 2), _vm.showCheckbox ? _c("checkbox", { | ||
})]], 2)], _vm.showCheckbox ? _c("checkbox", { | ||
ref: "checkbox", | ||
@@ -280,10 +329,91 @@ attrs: { | ||
} | ||
}) : _vm._e(), _vm.node.loading ? _c("icon-loading", { | ||
staticClass: "tiny-tree-node__loading-icon tiny-svg-size" | ||
}) : _vm._e(), _c("node-content", { | ||
}) : _vm._e(), _vm.node.loading ? _c("svg", { | ||
staticClass: "tiny-tree-node__loading tiny-svg circular", | ||
attrs: { | ||
"viewBox": "25 25 50 50" | ||
} | ||
}, [_c("circle", { | ||
staticClass: "path", | ||
attrs: { | ||
"cx": "50", | ||
"cy": "50", | ||
"r": "24", | ||
"fill": "none" | ||
} | ||
})]) : _vm._e(), _vm._t("prefix", null, { | ||
"node": _vm.node | ||
}), _vm.action.type === "edit" && _vm.action.node && _vm.action.node === _vm.node ? [_c("tiny-input", { | ||
ref: "editInput", | ||
attrs: { | ||
"autofocus": "", | ||
"clearable": "" | ||
}, | ||
on: { | ||
"keyup": function keyup($event) { | ||
if (!$event.type.indexOf("key") && _vm._k($event.keyCode, "enter", 13, $event.key, "Enter")) | ||
return null; | ||
return _vm.saveEdit($event); | ||
}, | ||
"blur": function blur($event) { | ||
return _vm.saveEdit($event); | ||
}, | ||
"click": function click($event) { | ||
$event.stopPropagation(); | ||
return function($event2) { | ||
return $event2.stopPropagation(); | ||
}.apply(null, arguments); | ||
} | ||
}, | ||
model: { | ||
value: _vm.action.label, | ||
callback: function callback($$v) { | ||
_vm.$set(_vm.action, "label", $$v); | ||
}, | ||
expression: "action.label" | ||
} | ||
})] : [_c("node-content", { | ||
attrs: { | ||
"node": _vm.node, | ||
"render-content": _vm.renderContent | ||
} | ||
})], 1), _c("collapse-transition", [!_vm.renderAfterExpand || _vm.state.childNodeRendered ? _c("div", { | ||
})], _vm._t("suffix", null, { | ||
"node": _vm.node | ||
})], 2), _c("div", { | ||
staticClass: "tiny-tree-node__content-right" | ||
}, [_vm._t("operation", null, { | ||
"node": _vm.node | ||
}), _vm.action.show ? [_c("span", { | ||
attrs: { | ||
"title": _vm.t("ui.base.edit") | ||
} | ||
}, [!_vm.action.deleteDisabled.includes(_vm.node.data[_vm.nodeKey]) ? _c("icon-edit", { | ||
on: { | ||
"click": function click($event) { | ||
$event.stopPropagation(); | ||
return _vm.openEdit(_vm.node); | ||
} | ||
} | ||
}) : _vm._e()], 1), _c("span", { | ||
attrs: { | ||
"title": _vm.t("ui.base.delete") | ||
} | ||
}, [!_vm.action.editDisabled.includes(_vm.node.data[_vm.nodeKey]) ? _c("icon-minus-square", { | ||
on: { | ||
"click": function click($event) { | ||
$event.stopPropagation(); | ||
return _vm.deleteNode($event, _vm.node); | ||
} | ||
} | ||
}) : _vm._e()], 1), _c("span", { | ||
attrs: { | ||
"title": _vm.t("ui.tree.newNodeTitle") | ||
} | ||
}, [!_vm.node.data._isNewNode && !_vm.action.addDisabled.includes(_vm.node.data[_vm.nodeKey]) ? _c("icon-plus-square", { | ||
on: { | ||
"click": function click($event) { | ||
$event.stopPropagation(); | ||
return _vm.addNode(_vm.node); | ||
} | ||
} | ||
}) : _vm._e()], 1)] : _vm._e()], 2)]), _vm.node.childNodes.length ? [_c("collapse-transition", [!_vm.renderAfterExpand || _vm.state.childNodeRendered ? _c("div", { | ||
directives: [{ | ||
@@ -296,2 +426,5 @@ name: "show", | ||
staticClass: "tiny-tree-node__children", | ||
style: { | ||
"margin-left": _vm.state.computedIndent | ||
}, | ||
attrs: { | ||
@@ -301,23 +434,60 @@ "role": "group", | ||
} | ||
}, _vm._l(_vm.node.childNodes, function(child) { | ||
}, [_vm.showLine ? _c("span", { | ||
staticClass: "tiny-tree-node__children-indent", | ||
style: { | ||
width: _vm.state.computedIndent, | ||
left: "-" + _vm.state.computedIndent | ||
} | ||
}) : _vm._e(), _vm._l(_vm.node.childNodes, function(child) { | ||
return _c("tree-node", { | ||
key: _vm.getNodeKey(child), | ||
attrs: { | ||
"showRadio": _vm.showRadio, | ||
"currentRadio": _vm.currentRadio, | ||
"action": _vm.action, | ||
"show-radio": _vm.showRadio, | ||
"theme": _vm.theme, | ||
"current-radio": _vm.currentRadio, | ||
"render-content": _vm.renderContent, | ||
"expandIcon": _vm.state.expandIcon, | ||
"shrinkIcon": _vm.state.shrinkIcon, | ||
"expand-icon": _vm.state.expandIcon, | ||
"shrink-icon": _vm.state.shrinkIcon, | ||
"expand-icon-color": _vm.state.expandIconColor, | ||
"shrink-icon-color": _vm.state.shrinkIconColor, | ||
"render-after-expand": _vm.renderAfterExpand, | ||
"show-checkbox": _vm.showCheckbox, | ||
"node": child | ||
"show-number": _vm.showNumber, | ||
"node-height": _vm.nodeHeight, | ||
"node-key": _vm.nodeKey, | ||
"check-easily": _vm.checkEasily, | ||
"node": child, | ||
"show-line": _vm.showLine | ||
}, | ||
on: { | ||
"node-expand": _vm.handleChildNodeExpand, | ||
"radio-change": function radioChange($event) { | ||
return _vm.$emit("radio-change", $event); | ||
}, | ||
"node-expand": _vm.handleChildNodeExpand | ||
} | ||
} | ||
}, | ||
scopedSlots: _vm._u([{ | ||
key: "prefix", | ||
fn: function fn(slotScoped) { | ||
return [_vm._t("prefix", null, { | ||
"node": slotScoped.node | ||
})]; | ||
} | ||
}, { | ||
key: "suffix", | ||
fn: function fn(slotScoped) { | ||
return [_vm._t("suffix", null, { | ||
"node": slotScoped.node | ||
})]; | ||
} | ||
}, { | ||
key: "operation", | ||
fn: function fn(slotScoped) { | ||
return [_vm._t("operation", null, { | ||
"node": slotScoped.node | ||
})]; | ||
} | ||
}], null, true) | ||
}); | ||
}), 1) : _vm._e()])], 1), _vm.state.showMenu && _vm.TreeRoot.showContextmenu ? _c("div", { | ||
})], 2) : _vm._e()])] : _vm._e()], 2), _vm.state.showMenu && _vm.TreeRoot.showContextmenu ? _c("div", { | ||
directives: [{ | ||
@@ -358,7 +528,16 @@ name: "clickoutside", | ||
var __vue2_script = defineComponent({ | ||
props: [].concat(props, ["data", "dataset", "parentKey", "expandIcon", "shrinkIcon", "emptyText", "renderAfterExpand", "nodeKey", "checkStrictly", "defaultExpandAll", "expandOnClickNode", "checkOnClickNode", "checkDescendants", "autoExpandParent", "defaultCheckedKeys", "defaultExpandedKeys", "defaultExpandedKeysHighlight", "currentNodeKey", "renderContent", "showCheckbox", "draggable", "allowDrag", "allowDrop", "props", "lazy", "highlightCurrent", "load", "filterNodeMethod", "accordion", "indent", "icon", "iconTriggerClickNode", "showRadio", "showContextmenu"]), | ||
directives: directive({ | ||
Clickoutside | ||
}), | ||
props: [].concat(props, ["data", "dataset", "parentKey", "expandIcon", "shrinkIcon", "expandIconColor", "shrinkIconColor", "emptyText", "renderAfterExpand", "nodeKey", "checkStrictly", "defaultExpandAll", "expandOnClickNode", "checkOnClickNode", "checkDescendants", "autoExpandParent", "defaultCheckedKeys", "defaultExpandedKeys", "defaultExpandedKeysHighlight", "currentNodeKey", "renderContent", "showCheckbox", "draggable", "allowDrag", "allowDrop", "props", "lazy", "highlightCurrent", "load", "filterNodeMethod", "accordion", "indent", "icon", "iconTriggerClickNode", "showRadio", "showContextmenu", "showNumber", "collapsible", "nodeHeight", "showCheckEasily", "size", "deleteDisabledKeys", "editDisabledKeys", "addDisabledKeys", "theme", "viewType", "pathSplit", "filterPlainMethod", "afterLoad", "lazyCurrent", "baseIndent", "showLine"]), | ||
components: { | ||
TreeNode | ||
TreeNode, | ||
IconWarning: iconWarning(), | ||
IconMarkOn: iconMarkOn(), | ||
TinyPopover: Popover, | ||
TinyCheckbox: Checkbox, | ||
TinyButton: Button, | ||
TinySwitch: Switch | ||
}, | ||
emits: ["node-expand", "node-drag-leave", "check-change", "check", "node-drag-over", "node-drag-enter", "node-drag-start", "node-drag-end", "node-drop", "current-change", "node-click"], | ||
emits: ["node-expand", "node-drag-leave", "check-change", "check", "node-drag-over", "node-drag-enter", "node-drag-start", "node-drag-end", "node-drop", "current-change", "node-click", "leave-plain-view", "check-plain"], | ||
provide: function provide2() { | ||
@@ -389,3 +568,4 @@ return { | ||
"is-drop-not-allow": !_vm.state.dragState.allowDrop, | ||
"is-drop-inner": _vm.state.dragState.dropType === "inner" | ||
"is-drop-inner": _vm.state.dragState.dropType === "inner", | ||
"tiny-tree--small": _vm.size === "small" | ||
}, | ||
@@ -395,10 +575,17 @@ attrs: { | ||
} | ||
}, [_vm._l(_vm.state.root.childNodes, function(child) { | ||
}, [_vm.viewType === "tree" ? _vm._l(_vm.state.root.childNodes, function(child) { | ||
return _c("tree-node", { | ||
key: _vm.getNodeKey(child), | ||
attrs: { | ||
"showRadio": _vm.showRadio, | ||
"currentRadio": _vm.state.currentRadio, | ||
"expandIcon": _vm.expandIcon, | ||
"shrinkIcon": _vm.shrinkIcon, | ||
"action": _vm.state.action, | ||
"show-radio": _vm.showRadio, | ||
"theme": _vm.theme, | ||
"show-number": _vm.showNumber, | ||
"collapsible": _vm.collapsible, | ||
"node-height": _vm.nodeHeight, | ||
"current-radio": _vm.state.currentRadio, | ||
"expand-icon": _vm.expandIcon, | ||
"shrink-icon": _vm.shrinkIcon, | ||
"expand-icon-color": _vm.expandIconColor, | ||
"shrink-icon-color": _vm.shrinkIconColor, | ||
"node": child, | ||
@@ -408,3 +595,6 @@ "props": _vm.props, | ||
"show-checkbox": _vm.showCheckbox, | ||
"render-content": _vm.renderContent | ||
"node-key": _vm.nodeKey, | ||
"render-content": _vm.renderContent, | ||
"check-easily": _vm.state.checkEasily, | ||
"show-line": _vm.showLine | ||
}, | ||
@@ -416,5 +606,57 @@ on: { | ||
"node-expand": _vm.handleNodeExpand | ||
}, | ||
scopedSlots: _vm._u([{ | ||
key: "prefix", | ||
fn: function fn(slotScoped) { | ||
return [_vm._t("prefix", null, { | ||
"node": slotScoped.node | ||
})]; | ||
} | ||
}, { | ||
key: "suffix", | ||
fn: function fn(slotScoped) { | ||
return [_vm._t("suffix", null, { | ||
"node": slotScoped.node | ||
})]; | ||
} | ||
}, { | ||
key: "operation", | ||
fn: function fn(slotScoped) { | ||
return [_vm._t("operation", null, { | ||
"node": slotScoped.node | ||
})]; | ||
} | ||
}], null, true) | ||
}); | ||
}) : _vm.viewType === "plain" ? _vm._l(_vm.state.plainNodeStore.filteredNodes, function(plainNode, i) { | ||
return _c("div", { | ||
key: plainNode.nodeKeyPath + "-" + i, | ||
staticClass: "tiny-tree__plain-node" | ||
}, [_c("div", { | ||
staticClass: "tiny-tree__plain-node-title" | ||
}, [_c("tiny-checkbox", { | ||
attrs: { | ||
"modelValue": plainNode.node.checked, | ||
"indeterminate": plainNode.node.indeterminate, | ||
"disabled": !!plainNode.node.disabled | ||
}, | ||
on: { | ||
"change": function change($event) { | ||
return _vm.handleCheckPlainNode($event, plainNode); | ||
} | ||
} | ||
}); | ||
}), _vm.state.isEmpty ? _c("div", { | ||
}), _c("span", { | ||
staticClass: "tiny-tree__plain-node-title-txt" | ||
}, [_vm._v(_vm._s(plainNode.title))]), _c("span", { | ||
staticClass: "tiny-tree__plain-node-title-loc" | ||
}, [_c("icon-mark-on", { | ||
on: { | ||
"click": function click($event) { | ||
return _vm.handleClickPlainNode($event, plainNode); | ||
} | ||
} | ||
})], 1)], 1), plainNode.auxi ? _c("div", { | ||
staticClass: "tiny-tree__plain-node-auxi" | ||
}, [_c("div", [_vm._v(_vm._s(plainNode.auxi))])]) : _vm._e()]); | ||
}) : _vm._e(), _vm.state.isEmpty ? _c("div", { | ||
staticClass: "tiny-tree__empty-block" | ||
@@ -434,3 +676,77 @@ }, [_vm._t("empty", function() { | ||
staticClass: "tiny-tree__drop-indicator" | ||
})], 2); | ||
}), _vm.state.store.checkStrictly && _vm.showCheckEasily ? _c("div", { | ||
staticClass: "tiny-tree__strict-bottom" | ||
}, [_c("div", { | ||
staticClass: "tiny-tree__strict-bottom-content" | ||
}, [_c("tiny-switch", { | ||
attrs: { | ||
"mini": "" | ||
}, | ||
on: { | ||
"change": _vm.switchToggle | ||
}, | ||
model: { | ||
value: _vm.state.checkEasily, | ||
callback: function callback($$v) { | ||
_vm.$set(_vm.state, "checkEasily", $$v); | ||
}, | ||
expression: "state.checkEasily" | ||
} | ||
}), _c("div", { | ||
staticClass: "tiny-tree__bottom-text" | ||
}, [_vm._t("switchText", function() { | ||
return [_c("span", [_vm._v(_vm._s(_vm.t("ui.tree.switchText")))])]; | ||
})], 2)], 1)]) : _vm._e(), _c("tiny-popover", { | ||
ref: "deletePopover", | ||
attrs: { | ||
"popper-class": "tiny-tree__del-popover", | ||
"placement": "top", | ||
"width": _vm.state.action.isLeaf ? 200 : 270, | ||
"trigger": "manual", | ||
"reference": _vm.state.action.referenceElm | ||
}, | ||
model: { | ||
value: _vm.state.action.popoverVisible, | ||
callback: function callback($$v) { | ||
_vm.$set(_vm.state.action, "popoverVisible", $$v); | ||
}, | ||
expression: "state.action.popoverVisible" | ||
} | ||
}, [_c("div", { | ||
directives: [{ | ||
name: "clickoutside", | ||
rawName: "v-clickoutside", | ||
value: _vm.cancelDelete, | ||
expression: "cancelDelete" | ||
}], | ||
staticClass: "tiny-tree__del-body" | ||
}, [_c("div", { | ||
staticClass: "tiny-tree__del-icon" | ||
}, [_c("icon-warning")], 1), _c("div", { | ||
staticClass: "tiny-tree__del-content" | ||
}, [_vm.state.action.isLeaf ? [_c("div", [_vm._v(_vm._s(_vm.t("ui.tree.deleteTip")))])] : [_c("div", [_vm._v(_vm._s(_vm.t("ui.tree.preserveSubnodeTip")))]), _c("div", { | ||
staticClass: "tiny-tree__del-checkbox" | ||
}, [_c("tiny-checkbox", { | ||
ref: "deleteCheckbox", | ||
model: { | ||
value: _vm.state.action.isSaveChildNode, | ||
callback: function callback($$v) { | ||
_vm.$set(_vm.state.action, "isSaveChildNode", $$v); | ||
}, | ||
expression: "state.action.isSaveChildNode" | ||
} | ||
}, [_vm._v(_vm._s(_vm.t("ui.tree.preserveSubnodeData")))])], 1)]], 2)]), _c("div", { | ||
staticClass: "tiny-tree__del-footer" | ||
}, [_c("tiny-button", { | ||
on: { | ||
"click": _vm.cancelDelete | ||
} | ||
}, [_vm._v(_vm._s(_vm.t("ui.base.cancel")))]), _c("tiny-button", { | ||
attrs: { | ||
"type": "primary" | ||
}, | ||
on: { | ||
"click": _vm.deleteAction | ||
} | ||
}, [_vm._v(_vm._s(_vm.t("ui.base.confirm")))])], 1)])], 2); | ||
}; | ||
@@ -437,0 +753,0 @@ var staticRenderFns = []; |
{ | ||
"name": "@opentiny/vue-tree", | ||
"version": "2.9.0", | ||
"version": "2.10.0", | ||
"description": "", | ||
@@ -8,5 +8,6 @@ "main": "./lib/index.js", | ||
"sideEffects": false, | ||
"type": "module", | ||
"dependencies": { | ||
"@opentiny/vue-renderless": "~3.9.0", | ||
"@opentiny/vue-common": "~2.9.0" | ||
"@opentiny/vue-renderless": "~3.10.0", | ||
"@opentiny/vue-common": "~2.10.0" | ||
}, | ||
@@ -13,0 +14,0 @@ "license": "MIT", |
@@ -1,249 +0,8 @@ | ||
declare const _default: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api/dist/vue-composition-api.js").ShallowUnwrapRef<() => import("vue").VNode> & import("@vue/composition-api/dist/vue-composition-api.js").Data, {}, {}, { | ||
_constants: { | ||
type: ObjectConstructor; | ||
default: () => { | ||
EMPTY_TEXT_LOCAL: string; | ||
}; | ||
}; | ||
accordion: BooleanConstructor; | ||
allowDrag: FunctionConstructor; | ||
allowDrop: FunctionConstructor; | ||
autoExpandParent: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
checkDescendants: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
checkOnClickNode: BooleanConstructor; | ||
checkStrictly: BooleanConstructor; | ||
currentNodeKey: (NumberConstructor | StringConstructor)[]; | ||
data: { | ||
type: ArrayConstructor; | ||
}; | ||
dataset: ObjectConstructor; | ||
defaultCheckedKeys: ArrayConstructor; | ||
defaultExpandAll: BooleanConstructor; | ||
defaultExpandedKeys: ArrayConstructor; | ||
defaultExpandedKeysHighlight: (NumberConstructor | StringConstructor)[]; | ||
draggable: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
emptyText: StringConstructor; | ||
expandIcon: ObjectConstructor; | ||
expandOnClickNode: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
filterNodeMethod: FunctionConstructor; | ||
highlightCurrent: BooleanConstructor; | ||
icon: ObjectConstructor; | ||
iconTriggerClickNode: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
indent: { | ||
type: NumberConstructor; | ||
default: number; | ||
}; | ||
lazy: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
load: FunctionConstructor; | ||
nodeKey: StringConstructor; | ||
parentKey: StringConstructor; | ||
props: { | ||
default(): { | ||
children: string; | ||
label: string; | ||
disabled: string; | ||
}; | ||
}; | ||
renderAfterExpand: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
renderContent: FunctionConstructor; | ||
showCheckbox: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
showContextmenu: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
showRadio: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
shrinkIcon: ObjectConstructor; | ||
tiny_mode: StringConstructor; | ||
tiny_mode_root: BooleanConstructor; | ||
tiny_template: (ObjectConstructor | FunctionConstructor)[]; | ||
tiny_renderless: FunctionConstructor; | ||
tiny_theme: StringConstructor; | ||
tiny_chart_theme: ObjectConstructor; | ||
}, { | ||
props: { | ||
children: string; | ||
label: string; | ||
disabled: string; | ||
}; | ||
tiny_mode_root: boolean; | ||
_constants: Record<string, any>; | ||
accordion: boolean; | ||
showCheckbox: boolean; | ||
draggable: boolean; | ||
lazy: boolean; | ||
defaultExpandAll: boolean; | ||
expandOnClickNode: boolean; | ||
checkOnClickNode: boolean; | ||
checkStrictly: boolean; | ||
highlightCurrent: boolean; | ||
autoExpandParent: boolean; | ||
checkDescendants: boolean; | ||
iconTriggerClickNode: boolean; | ||
indent: number; | ||
renderAfterExpand: boolean; | ||
showContextmenu: boolean; | ||
showRadio: boolean; | ||
} & { | ||
data?: unknown[] | undefined; | ||
tiny_mode?: string | undefined; | ||
tiny_template?: unknown; | ||
tiny_renderless?: Function | undefined; | ||
tiny_theme?: string | undefined; | ||
tiny_chart_theme?: Record<string, any> | undefined; | ||
icon?: Record<string, any> | undefined; | ||
dataset?: Record<string, any> | undefined; | ||
parentKey?: string | undefined; | ||
load?: Function | undefined; | ||
defaultCheckedKeys?: unknown[] | undefined; | ||
renderContent?: Function | undefined; | ||
allowDrag?: Function | undefined; | ||
allowDrop?: Function | undefined; | ||
defaultExpandedKeys?: unknown[] | undefined; | ||
emptyText?: string | undefined; | ||
expandIcon?: Record<string, any> | undefined; | ||
filterNodeMethod?: Function | undefined; | ||
nodeKey?: string | undefined; | ||
shrinkIcon?: Record<string, any> | undefined; | ||
currentNodeKey?: string | number | undefined; | ||
defaultExpandedKeysHighlight?: string | number | undefined; | ||
declare const _default: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api/dist/vue-composition-api.js").ShallowUnwrapRef<unknown> & import("@vue/composition-api/dist/vue-composition-api.js").Data, {}, {}, unknown, { | ||
[x: string]: any; | ||
}> & import("vue").VueConstructor<import("vue").default> & (new (...args: any[]) => import("@vue/composition-api/dist/vue-composition-api.js").ComponentRenderProxy<{ | ||
props: { | ||
children: string; | ||
label: string; | ||
disabled: string; | ||
}; | ||
tiny_mode_root: boolean; | ||
_constants: Record<string, any>; | ||
accordion: boolean; | ||
showCheckbox: boolean; | ||
draggable: boolean; | ||
lazy: boolean; | ||
defaultExpandAll: boolean; | ||
expandOnClickNode: boolean; | ||
checkOnClickNode: boolean; | ||
checkStrictly: boolean; | ||
highlightCurrent: boolean; | ||
autoExpandParent: boolean; | ||
checkDescendants: boolean; | ||
iconTriggerClickNode: boolean; | ||
indent: number; | ||
renderAfterExpand: boolean; | ||
showContextmenu: boolean; | ||
showRadio: boolean; | ||
} & { | ||
data?: unknown[] | undefined; | ||
tiny_mode?: string | undefined; | ||
tiny_template?: unknown; | ||
tiny_renderless?: Function | undefined; | ||
tiny_theme?: string | undefined; | ||
tiny_chart_theme?: Record<string, any> | undefined; | ||
icon?: Record<string, any> | undefined; | ||
dataset?: Record<string, any> | undefined; | ||
parentKey?: string | undefined; | ||
load?: Function | undefined; | ||
defaultCheckedKeys?: unknown[] | undefined; | ||
renderContent?: Function | undefined; | ||
allowDrag?: Function | undefined; | ||
allowDrop?: Function | undefined; | ||
defaultExpandedKeys?: unknown[] | undefined; | ||
emptyText?: string | undefined; | ||
expandIcon?: Record<string, any> | undefined; | ||
filterNodeMethod?: Function | undefined; | ||
nodeKey?: string | undefined; | ||
shrinkIcon?: Record<string, any> | undefined; | ||
currentNodeKey?: string | number | undefined; | ||
defaultExpandedKeysHighlight?: string | number | undefined; | ||
}, import("@vue/composition-api/dist/vue-composition-api.js").ShallowUnwrapRef<() => import("vue").VNode>, import("@vue/composition-api/dist/vue-composition-api.js").Data, {}, {}, { | ||
props: { | ||
children: string; | ||
label: string; | ||
disabled: string; | ||
}; | ||
tiny_mode_root: boolean; | ||
_constants: Record<string, any>; | ||
accordion: boolean; | ||
showCheckbox: boolean; | ||
draggable: boolean; | ||
lazy: boolean; | ||
defaultExpandAll: boolean; | ||
expandOnClickNode: boolean; | ||
checkOnClickNode: boolean; | ||
checkStrictly: boolean; | ||
highlightCurrent: boolean; | ||
autoExpandParent: boolean; | ||
checkDescendants: boolean; | ||
iconTriggerClickNode: boolean; | ||
indent: number; | ||
renderAfterExpand: boolean; | ||
showContextmenu: boolean; | ||
showRadio: boolean; | ||
} & { | ||
data?: unknown[] | undefined; | ||
tiny_mode?: string | undefined; | ||
tiny_template?: unknown; | ||
tiny_renderless?: Function | undefined; | ||
tiny_theme?: string | undefined; | ||
tiny_chart_theme?: Record<string, any> | undefined; | ||
icon?: Record<string, any> | undefined; | ||
dataset?: Record<string, any> | undefined; | ||
parentKey?: string | undefined; | ||
load?: Function | undefined; | ||
defaultCheckedKeys?: unknown[] | undefined; | ||
renderContent?: Function | undefined; | ||
allowDrag?: Function | undefined; | ||
allowDrop?: Function | undefined; | ||
defaultExpandedKeys?: unknown[] | undefined; | ||
emptyText?: string | undefined; | ||
expandIcon?: Record<string, any> | undefined; | ||
filterNodeMethod?: Function | undefined; | ||
nodeKey?: string | undefined; | ||
shrinkIcon?: Record<string, any> | undefined; | ||
currentNodeKey?: string | number | undefined; | ||
defaultExpandedKeysHighlight?: string | number | undefined; | ||
}, { | ||
props: { | ||
children: string; | ||
label: string; | ||
disabled: string; | ||
}; | ||
_constants: Record<string, any>; | ||
showCheckbox: boolean; | ||
draggable: boolean; | ||
lazy: boolean; | ||
expandOnClickNode: boolean; | ||
autoExpandParent: boolean; | ||
checkDescendants: boolean; | ||
iconTriggerClickNode: boolean; | ||
indent: number; | ||
renderAfterExpand: boolean; | ||
showContextmenu: boolean; | ||
showRadio: boolean; | ||
}, true>); | ||
[x: string]: any; | ||
}, import("@vue/composition-api/dist/vue-composition-api.js").ShallowUnwrapRef<unknown>, import("@vue/composition-api/dist/vue-composition-api.js").Data, {}, {}, { | ||
[x: string]: any; | ||
}, {}, true>); | ||
export default _default; |
@@ -1,2 +0,2 @@ | ||
declare const _sfc_main: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api/dist/vue-composition-api.js").ShallowUnwrapRef<import("@vue/composition-api/dist/vue-composition-api.js").Data> & import("@vue/composition-api/dist/vue-composition-api.js").Data, {}, {}, Readonly<{ | ||
declare const _default: import("vue").ComponentOptions<import("vue").default, import("@vue/composition-api/dist/vue-composition-api.js").ShallowUnwrapRef<import("@vue/composition-api/dist/vue-composition-api.js").Data> & import("@vue/composition-api/dist/vue-composition-api.js").Data, {}, {}, Readonly<{ | ||
[x: string]: any; | ||
@@ -12,2 +12,2 @@ }>, { | ||
}, true>); | ||
export default _sfc_main; | ||
export default _default; |
@@ -1,49 +0,2 @@ | ||
declare const _sfc_main: { | ||
name: string; | ||
componentName: string; | ||
directives: any; | ||
inject: string[]; | ||
provide(): { | ||
parentTree: any; | ||
}; | ||
emits: string[]; | ||
props: { | ||
node: { | ||
default(): {}; | ||
}; | ||
props: {}; | ||
expandIcon: ObjectConstructor; | ||
shrinkIcon: ObjectConstructor; | ||
renderContent: FunctionConstructor; | ||
renderAfterExpand: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
showCheckbox: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
showRadio: { | ||
type: BooleanConstructor; | ||
default: boolean; | ||
}; | ||
currentRadio: { | ||
type: ObjectConstructor; | ||
default(): { | ||
value: null; | ||
}; | ||
}; | ||
}; | ||
components: undefined; | ||
setup(props: any, context: any): { | ||
t: (this: any, path: any, options?: any) => any; | ||
vm: any; | ||
f: (props: any, attrs?: {}) => {}; | ||
a: (attrs: any, filters: any, include: any) => {}; | ||
d: (props: any) => void; | ||
dp: (props: any) => void; | ||
gcls: (key: any) => any; | ||
m: (...cssClasses: any[]) => string; | ||
}; | ||
}; | ||
export default _sfc_main; | ||
declare const _default: import("vue/types/vue").ExtendedVue<import("vue").default, unknown, unknown, unknown, Record<never, any>>; | ||
export default _default; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
31619
9
962
Yes
+ Added@opentiny/vue-common@2.10.0(transitive)
+ Added@opentiny/vue-locale@2.10.0(transitive)
+ Added@opentiny/vue-renderless@3.10.7(transitive)
+ Added@opentiny/vue-theme@3.10.4(transitive)
+ Added@opentiny/vue-theme-mobile@3.10.1(transitive)
- Removed@opentiny/vue-common@2.9.0(transitive)
- Removed@opentiny/vue-locale@2.9.0(transitive)
- Removed@opentiny/vue-renderless@3.9.3(transitive)
- Removed@opentiny/vue-theme@3.9.4(transitive)
- Removed@opentiny/vue-theme-mobile@3.9.0(transitive)
Updated@opentiny/vue-common@~2.10.0