| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314 |
- import PropTypes from '../_util/vue-types';
- export var treeNodeProps = {
- eventKey: [String, Number],
- prefixCls: String,
- // By parent
- // expanded: { type: Boolean, default: undefined },
- // selected: { type: Boolean, default: undefined },
- // checked: { type: Boolean, default: undefined },
- // loaded: { type: Boolean, default: undefined },
- // loading: { type: Boolean, default: undefined },
- // halfChecked: { type: Boolean, default: undefined },
- // dragOver: { type: Boolean, default: undefined },
- // dragOverGapTop: { type: Boolean, default: undefined },
- // dragOverGapBottom: { type: Boolean, default: undefined },
- // pos: String,
- title: PropTypes.any,
- /** New added in Tree for easy data access */
- data: {
- type: Object,
- default: undefined
- },
- parent: {
- type: Object,
- default: undefined
- },
- isStart: {
- type: Array
- },
- isEnd: {
- type: Array
- },
- active: {
- type: Boolean,
- default: undefined
- },
- onMousemove: {
- type: Function
- },
- // By user
- isLeaf: {
- type: Boolean,
- default: undefined
- },
- checkable: {
- type: Boolean,
- default: undefined
- },
- selectable: {
- type: Boolean,
- default: undefined
- },
- disabled: {
- type: Boolean,
- default: undefined
- },
- disableCheckbox: {
- type: Boolean,
- default: undefined
- },
- icon: PropTypes.any,
- switcherIcon: PropTypes.any,
- domRef: {
- type: Function
- }
- };
- export var nodeListProps = {
- prefixCls: {
- type: String
- },
- // data: { type: Array as PropType<FlattenNode[]> },
- motion: {
- type: Object
- },
- focusable: {
- type: Boolean
- },
- activeItem: {
- type: Object
- },
- focused: {
- type: Boolean
- },
- tabindex: {
- type: Number
- },
- checkable: {
- type: Boolean
- },
- selectable: {
- type: Boolean
- },
- disabled: {
- type: Boolean
- },
- // expandedKeys: { type: Array as PropType<Key[]> },
- // selectedKeys: { type: Array as PropType<Key[]> },
- // checkedKeys: { type: Array as PropType<Key[]> },
- // loadedKeys: { type: Array as PropType<Key[]> },
- // loadingKeys: { type: Array as PropType<Key[]> },
- // halfCheckedKeys: { type: Array as PropType<Key[]> },
- // keyEntities: { type: Object as PropType<Record<Key, DataEntity<DataNode>>> },
- // dragging: { type: Boolean as PropType<boolean> },
- // dragOverNodeKey: { type: [String, Number] as PropType<Key> },
- // dropPosition: { type: Number as PropType<number> },
- // Virtual list
- height: {
- type: Number
- },
- itemHeight: {
- type: Number
- },
- virtual: {
- type: Boolean
- },
- onScroll: {
- type: Function
- },
- onKeydown: {
- type: Function
- },
- onFocus: {
- type: Function
- },
- onBlur: {
- type: Function
- },
- onActiveChange: {
- type: Function
- },
- onContextmenu: {
- type: Function
- },
- onListChangeStart: {
- type: Function
- },
- onListChangeEnd: {
- type: Function
- }
- };
- export var treeProps = function treeProps() {
- return {
- prefixCls: String,
- focusable: {
- type: Boolean,
- default: undefined
- },
- activeKey: [Number, String],
- tabindex: Number,
- children: PropTypes.any,
- treeData: {
- type: Array
- },
- fieldNames: {
- type: Object
- },
- showLine: {
- type: [Boolean, Object],
- default: undefined
- },
- showIcon: {
- type: Boolean,
- default: undefined
- },
- icon: PropTypes.any,
- selectable: {
- type: Boolean,
- default: undefined
- },
- disabled: {
- type: Boolean,
- default: undefined
- },
- multiple: {
- type: Boolean,
- default: undefined
- },
- checkable: {
- type: Boolean,
- default: undefined
- },
- checkStrictly: {
- type: Boolean,
- default: undefined
- },
- draggable: {
- type: [Function, Boolean]
- },
- defaultExpandParent: {
- type: Boolean,
- default: undefined
- },
- autoExpandParent: {
- type: Boolean,
- default: undefined
- },
- defaultExpandAll: {
- type: Boolean,
- default: undefined
- },
- defaultExpandedKeys: {
- type: Array
- },
- expandedKeys: {
- type: Array
- },
- defaultCheckedKeys: {
- type: Array
- },
- checkedKeys: {
- type: [Object, Array]
- },
- defaultSelectedKeys: {
- type: Array
- },
- selectedKeys: {
- type: Array
- },
- allowDrop: {
- type: Function
- },
- dropIndicatorRender: {
- type: Function
- },
- onFocus: {
- type: Function
- },
- onBlur: {
- type: Function
- },
- onKeydown: {
- type: Function
- },
- onContextmenu: {
- type: Function
- },
- onClick: {
- type: Function
- },
- onDblclick: {
- type: Function
- },
- onScroll: {
- type: Function
- },
- onExpand: {
- type: Function
- },
- onCheck: {
- type: Function
- },
- onSelect: {
- type: Function
- },
- onLoad: {
- type: Function
- },
- loadData: {
- type: Function
- },
- loadedKeys: {
- type: Array
- },
- onMouseenter: {
- type: Function
- },
- onMouseleave: {
- type: Function
- },
- onRightClick: {
- type: Function
- },
- onDragstart: {
- type: Function
- },
- onDragenter: {
- type: Function
- },
- onDragover: {
- type: Function
- },
- onDragleave: {
- type: Function
- },
- onDragend: {
- type: Function
- },
- onDrop: {
- type: Function
- },
- /**
- * Used for `rc-tree-select` only.
- * Do not use in your production code directly since this will be refactor.
- */
- onActiveChange: {
- type: Function
- },
- filterTreeNode: {
- type: Function
- },
- motion: PropTypes.any,
- switcherIcon: PropTypes.any,
- // Virtual List
- height: Number,
- itemHeight: Number,
- virtual: {
- type: Boolean,
- default: undefined
- },
- // direction for drag logic
- direction: {
- type: String
- }
- };
- };
|