@king-design/vue 2.1.2 → 2.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/affix/index.d.ts +2 -2
- package/components/affix/index.js +0 -5
- package/components/affix/index.spec.js +84 -108
- package/components/affix/index.vdt.js +5 -8
- package/components/affix/useStyle.js +8 -19
- package/components/badge/index.js +0 -2
- package/components/badge/index.vdt.js +5 -9
- package/components/badge/styles.js +0 -2
- package/components/breadcrumb/index.js +0 -4
- package/components/breadcrumb/index.spec.js +6 -6
- package/components/breadcrumb/index.vdt.js +5 -14
- package/components/breadcrumb/item.js +0 -8
- package/components/breadcrumb/item.vdt.js +3 -6
- package/components/breadcrumb/styles.js +0 -3
- package/components/button/dynamicButton.d.ts +1 -1
- package/components/button/dynamicButton.js +2 -5
- package/components/button/group.js +2 -10
- package/components/button/group.vdt.js +4 -7
- package/components/button/index.js +3 -27
- package/components/button/index.spec.js +74 -96
- package/components/button/index.vdt.js +19 -29
- package/components/button/styles.d.ts +2 -2
- package/components/button/styles.js +4 -48
- package/components/card/column.js +0 -2
- package/components/card/column.vdt.js +5 -10
- package/components/card/index.js +0 -4
- package/components/card/index.vdt.js +4 -16
- package/components/carousel/index.js +1 -19
- package/components/carousel/index.spec.js +127 -163
- package/components/carousel/index.vdt.js +12 -15
- package/components/carousel/item.js +0 -2
- package/components/carousel/item.vdt.js +4 -7
- package/components/carousel/styles.js +0 -1
- package/components/carousel/useAutoplay.js +0 -4
- package/components/carousel/useItems.js +4 -20
- package/components/carousel/useSlide.js +57 -89
- package/components/cascader/index.js +3 -18
- package/components/cascader/index.spec.js +365 -379
- package/components/cascader/index.vdt.js +14 -31
- package/components/cascader/styles.js +0 -6
- package/components/cascader/useFields.js +1 -4
- package/components/cascader/useFilterable.js +2 -19
- package/components/cascader/useLabel.js +1 -9
- package/components/cascader/useLoad.js +22 -35
- package/components/cascader/useValue.d.ts +2 -2
- package/components/cascader/useValue.js +6 -27
- package/components/checkbox/index.js +5 -27
- package/components/checkbox/index.spec.js +129 -171
- package/components/checkbox/index.vdt.js +12 -16
- package/components/checkbox/styles.js +0 -10
- package/components/code/crossDomain.js +2 -9
- package/components/code/index.js +0 -9
- package/components/code/index.spec.js +46 -55
- package/components/code/index.vdt.js +6 -14
- package/components/code/styles.js +0 -1
- package/components/code/useEditor.js +5 -10
- package/components/collapse/index.d.ts +1 -1
- package/components/collapse/index.js +3 -14
- package/components/collapse/index.spec.js +47 -60
- package/components/collapse/index.vdt.js +4 -12
- package/components/collapse/item.js +0 -10
- package/components/collapse/item.vdt.js +7 -14
- package/components/collapse/styles.js +0 -1
- package/components/colorpicker/drag.js +0 -5
- package/components/colorpicker/index.js +0 -4
- package/components/colorpicker/index.spec.js +211 -259
- package/components/colorpicker/index.vdt.js +8 -11
- package/components/colorpicker/panel.js +0 -5
- package/components/colorpicker/panel.vdt.js +21 -26
- package/components/colorpicker/styles.js +2 -13
- package/components/colorpicker/useDrag.js +22 -26
- package/components/colorpicker/useInput.js +0 -16
- package/components/colorpicker/usePointer.js +15 -18
- package/components/colorpicker/useValue.js +2 -7
- package/components/context.d.ts +2 -2
- package/components/context.js +2 -19
- package/components/datepicker/basepicker.d.ts +8 -8
- package/components/datepicker/basepicker.js +20 -90
- package/components/datepicker/calendar.js +0 -11
- package/components/datepicker/calendar.vdt.js +11 -14
- package/components/datepicker/constants.js +0 -1
- package/components/datepicker/dayjs.js +1 -1
- package/components/datepicker/helpers.js +3 -15
- package/components/datepicker/index.js +6 -32
- package/components/datepicker/index.spec.js +1141 -1448
- package/components/datepicker/index.vdt.js +20 -34
- package/components/datepicker/shortcuts.d.ts +1 -1
- package/components/datepicker/shortcuts.js +0 -4
- package/components/datepicker/styles.js +0 -8
- package/components/datepicker/time.d.ts +1 -1
- package/components/datepicker/time.js +3 -23
- package/components/datepicker/time.vdt.js +4 -5
- package/components/datepicker/useDays.js +2 -9
- package/components/datepicker/useDisabled.js +6 -23
- package/components/datepicker/useFocusDate.js +0 -2
- package/components/datepicker/useFormats.js +6 -15
- package/components/datepicker/useKeyboards.js +20 -36
- package/components/datepicker/useMonths.js +0 -6
- package/components/datepicker/usePanel.js +0 -10
- package/components/datepicker/useShowDate.js +10 -37
- package/components/datepicker/useStatus.js +3 -15
- package/components/datepicker/useValue.js +22 -35
- package/components/datepicker/useYears.js +4 -15
- package/components/diagram/diagram.js +17 -43
- package/components/diagram/diagram.vdt.js +2 -5
- package/components/diagram/graph.js +6 -6
- package/components/diagram/index.d.ts +1 -1
- package/components/diagram/index.js +7 -7
- package/components/diagram/index.spec.js +369 -495
- package/components/diagram/layouts/circle.js +6 -14
- package/components/diagram/layouts/flow.js +7 -15
- package/components/diagram/layouts/layout.js +6 -28
- package/components/diagram/layouts/organic.js +3 -11
- package/components/diagram/layouts/partition.js +4 -12
- package/components/diagram/layouts/radial.js +6 -18
- package/components/diagram/layouts/stack.js +6 -14
- package/components/diagram/layouts/tree.js +11 -21
- package/components/diagram/mxgraph/handler/mxConnectionHandler.js +15 -22
- package/components/diagram/mxgraph/handler/mxConstraintHandler.js +4 -4
- package/components/diagram/mxgraph/handler/mxEdgeHandler.js +11 -15
- package/components/diagram/mxgraph/handler/mxGraphHandler.js +6 -9
- package/components/diagram/mxgraph/handler/mxRubberband.js +4 -4
- package/components/diagram/mxgraph/handler/mxVertexHandler.js +7 -10
- package/components/diagram/mxgraph/index.js +0 -2
- package/components/diagram/mxgraph/mx.js +3 -3
- package/components/diagram/mxgraph/shape/mxCloud.js +2 -2
- package/components/diagram/mxgraph/shape/mxCylinder.js +4 -9
- package/components/diagram/mxgraph/shape/mxEllipse.js +2 -2
- package/components/diagram/mxgraph/shape/mxHexagon.js +2 -2
- package/components/diagram/mxgraph/shape/mxLine.js +2 -2
- package/components/diagram/mxgraph/shape/mxRectangleShape.js +2 -2
- package/components/diagram/mxgraph/shape/mxRhombus.js +6 -12
- package/components/diagram/mxgraph/shape/mxShape.js +0 -1
- package/components/diagram/mxgraph/shape/mxTriangle.js +2 -2
- package/components/diagram/mxgraph/util/mxConstants.js +2 -2
- package/components/diagram/mxgraph/util/mxGuide.js +5 -7
- package/components/diagram/mxgraph/view/mxCellEditor.js +16 -29
- package/components/diagram/mxgraph/view/mxCellRenderer.js +0 -2
- package/components/diagram/mxgraph/view/mxGraph.js +14 -32
- package/components/diagram/shapes/base.d.ts +1 -1
- package/components/diagram/shapes/base.js +9 -39
- package/components/diagram/shapes/callout.js +10 -23
- package/components/diagram/shapes/circle.js +3 -10
- package/components/diagram/shapes/document.js +5 -16
- package/components/diagram/shapes/ellipse.js +0 -5
- package/components/diagram/shapes/generateShapes.d.ts +1 -1
- package/components/diagram/shapes/generateShapes.js +0 -9
- package/components/diagram/shapes/hexagon.js +9 -26
- package/components/diagram/shapes/image.js +1 -9
- package/components/diagram/shapes/line.d.ts +2 -2
- package/components/diagram/shapes/line.js +13 -48
- package/components/diagram/shapes/parallelogram.js +9 -26
- package/components/diagram/shapes/rectangle.js +1 -9
- package/components/diagram/shapes/shape.js +6 -35
- package/components/diagram/shapes/square.js +3 -11
- package/components/diagram/shapes/text.js +0 -5
- package/components/diagram/styles.js +0 -1
- package/components/dialog/alert.vdt.js +9 -19
- package/components/dialog/base.js +1 -29
- package/components/dialog/base.vdt.js +14 -29
- package/components/dialog/index.js +6 -31
- package/components/dialog/index.spec.js +416 -503
- package/components/dialog/staticMethods.d.ts +1 -1
- package/components/dialog/staticMethods.js +2 -13
- package/components/dialog/styles.js +0 -11
- package/components/dialog/useDraggable.js +0 -6
- package/components/dialog/useEscClosable.js +4 -12
- package/components/dialog/useFixBody.d.ts +1 -1
- package/components/dialog/useFixBody.js +0 -11
- package/components/dialog/usePosition.js +7 -5
- package/components/drawer/index.js +0 -5
- package/components/drawer/index.spec.js +126 -168
- package/components/drawer/index.vdt.js +3 -9
- package/components/drawer/styles.d.ts +2 -2
- package/components/drawer/styles.js +0 -4
- package/components/dropdown/dropdown.d.ts +2 -2
- package/components/dropdown/dropdown.js +33 -89
- package/components/dropdown/index.js +2 -6
- package/components/dropdown/index.spec.js +388 -496
- package/components/dropdown/item.js +4 -25
- package/components/dropdown/item.vdt.js +5 -8
- package/components/dropdown/menu.js +14 -29
- package/components/dropdown/menu.vdt.js +5 -13
- package/components/dropdown/styles.js +0 -9
- package/components/dropdown/useKeyboard.d.ts +2 -2
- package/components/dropdown/useKeyboard.js +8 -30
- package/components/dropdown/usePosition.d.ts +2 -1
- package/components/dropdown/usePosition.js +33 -28
- package/components/dropdown/useTransition.js +0 -8
- package/components/editable/index.d.ts +1 -1
- package/components/editable/index.js +4 -28
- package/components/editable/index.spec.js +152 -189
- package/components/editable/index.vdt.js +8 -11
- package/components/editable/styles.js +0 -1
- package/components/form/form.js +0 -18
- package/components/form/form.vdt.js +4 -7
- package/components/form/index.spec.js +1057 -1280
- package/components/form/item.d.ts +1 -1
- package/components/form/item.js +0 -12
- package/components/form/item.vdt.js +17 -31
- package/components/form/methods.d.ts +5 -5
- package/components/form/methods.js +2 -12
- package/components/form/styles.js +0 -8
- package/components/form/useDirty.js +2 -7
- package/components/form/useError.js +2 -10
- package/components/form/useValidate.d.ts +1 -1
- package/components/form/useValidate.js +8 -24
- package/components/grid/col.d.ts +3 -3
- package/components/grid/col.js +0 -7
- package/components/grid/col.vdt.js +8 -13
- package/components/grid/constants.d.ts +6 -6
- package/components/grid/row.js +0 -5
- package/components/grid/row.vdt.js +5 -8
- package/components/grid/styles.js +0 -7
- package/components/grid/useBreakpoints.js +0 -5
- package/components/grid/useGutter.js +5 -25
- package/components/icon/index.js +0 -10
- package/components/icon/index.vdt.js +7 -13
- package/components/icon/styles.js +0 -1
- package/components/input/index.d.ts +3 -3
- package/components/input/index.js +0 -14
- package/components/input/index.spec.js +185 -239
- package/components/input/index.vdt.js +39 -49
- package/components/input/search.js +0 -20
- package/components/input/search.vdt.js +6 -9
- package/components/input/styles.js +0 -26
- package/components/input/useAutoRows.js +6 -18
- package/components/input/useAutoWidth.js +0 -5
- package/components/input/useFrozen.js +0 -6
- package/components/input/useShowPassword.js +2 -5
- package/components/layout/aside.js +5 -17
- package/components/layout/aside.vdt.js +5 -9
- package/components/layout/body.js +5 -17
- package/components/layout/footer.js +1 -7
- package/components/layout/header.js +7 -21
- package/components/layout/layout.js +9 -24
- package/components/layout/styles.js +2 -13
- package/components/layout/template.vdt.js +2 -4
- package/components/layout/useParse.js +0 -7
- package/components/menu/index.spec.js +189 -242
- package/components/menu/item.js +3 -16
- package/components/menu/item.vdt.js +20 -32
- package/components/menu/menu.js +2 -11
- package/components/menu/menu.vdt.js +6 -12
- package/components/menu/styles.js +0 -18
- package/components/menu/useDropdown.js +4 -9
- package/components/menu/useExpanded.js +0 -14
- package/components/menu/useHighlight.js +26 -36
- package/components/message/index.spec.js +58 -73
- package/components/message/message.js +0 -19
- package/components/message/message.vdt.js +5 -8
- package/components/message/messages.js +0 -12
- package/components/message/messages.vdt.js +0 -1
- package/components/message/styles.js +0 -9
- package/components/pagination/index.d.ts +1 -1
- package/components/pagination/index.js +10 -46
- package/components/pagination/index.spec.js +133 -173
- package/components/pagination/index.vdt.js +14 -34
- package/components/pagination/styles.js +0 -4
- package/components/portal.d.ts +1 -1
- package/components/portal.js +13 -28
- package/components/position.d.ts +12 -12
- package/components/position.js +32 -88
- package/components/progress/index.d.ts +6 -6
- package/components/progress/index.js +0 -12
- package/components/progress/index.spec.js +143 -191
- package/components/progress/index.vdt.js +8 -11
- package/components/progress/styles.js +0 -6
- package/components/progress/useColor.js +2 -7
- package/components/progress/useStatus.d.ts +1 -1
- package/components/progress/useStatus.js +2 -5
- package/components/radio/index.js +3 -18
- package/components/radio/index.spec.js +111 -149
- package/components/radio/index.vdt.js +14 -17
- package/components/radio/styles.js +0 -10
- package/components/rate/index.js +0 -7
- package/components/rate/index.spec.js +64 -79
- package/components/rate/index.vdt.js +8 -21
- package/components/rate/styles.js +0 -3
- package/components/rate/useActiveValue.js +2 -7
- package/components/scrollSelect/index.d.ts +2 -2
- package/components/scrollSelect/index.js +0 -7
- package/components/scrollSelect/index.spec.js +100 -131
- package/components/scrollSelect/index.vdt.js +6 -11
- package/components/scrollSelect/styles.js +0 -7
- package/components/scrollSelect/useList.js +3 -17
- package/components/scrollSelect/useMouseEvents.js +31 -49
- package/components/scrollSelect/useTranslate.js +1 -11
- package/components/select/base.js +5 -35
- package/components/select/base.vdt.js +23 -38
- package/components/select/group.js +0 -5
- package/components/select/group.vdt.js +4 -10
- package/components/select/index.spec.js +361 -452
- package/components/select/menu.js +0 -5
- package/components/select/menu.vdt.js +18 -33
- package/components/select/option.js +2 -16
- package/components/select/option.vdt.js +7 -14
- package/components/select/select.js +3 -20
- package/components/select/select.vdt.js +9 -17
- package/components/select/styles.js +0 -33
- package/components/select/useBaseLabel.d.ts +1 -1
- package/components/select/useBaseLabel.js +4 -17
- package/components/select/useCard.js +0 -4
- package/components/select/useEqualWidth.js +0 -1
- package/components/select/useFilterable.js +5 -27
- package/components/select/useFocusout.d.ts +1 -1
- package/components/select/useFocusout.js +1 -9
- package/components/select/useInput.js +6 -10
- package/components/select/useLabel.js +3 -13
- package/components/select/useSearchable.js +0 -10
- package/components/skeleton/item.d.ts +1 -1
- package/components/skeleton/item.js +0 -4
- package/components/skeleton/item.vdt.js +1 -6
- package/components/skeleton/skeleton.js +0 -4
- package/components/skeleton/skeleton.vdt.js +6 -12
- package/components/skeleton/style.d.ts +1 -1
- package/components/skeleton/style.js +0 -1
- package/components/slider/index.d.ts +1 -1
- package/components/slider/index.js +0 -7
- package/components/slider/index.spec.js +467 -585
- package/components/slider/index.vdt.js +32 -45
- package/components/slider/styles.js +0 -14
- package/components/slider/useClick.js +2 -11
- package/components/slider/useDraggable.js +23 -34
- package/components/slider/useKeyboard.js +7 -18
- package/components/slider/useMarks.d.ts +5 -5
- package/components/slider/useMarks.js +5 -13
- package/components/slider/usePoints.d.ts +2 -2
- package/components/slider/usePoints.js +7 -21
- package/components/slider/useStyles.d.ts +1 -1
- package/components/slider/useStyles.js +5 -10
- package/components/slider/useTooltip.js +2 -10
- package/components/slider/useValue.d.ts +1 -1
- package/components/slider/useValue.js +7 -22
- package/components/spin/index.js +0 -4
- package/components/spin/index.vdt.js +4 -11
- package/components/spin/styles.js +0 -2
- package/components/spinner/index.d.ts +4 -4
- package/components/spinner/index.js +9 -24
- package/components/spinner/index.spec.js +359 -460
- package/components/spinner/index.vdt.js +10 -13
- package/components/spinner/styles.js +0 -3
- package/components/spinner/useChange.js +4 -16
- package/components/spinner/useFormatter.js +6 -16
- package/components/spinner/useStep.d.ts +3 -3
- package/components/spinner/useStep.js +2 -20
- package/components/spinner/useValue.js +11 -26
- package/components/split/index.js +0 -7
- package/components/split/index.spec.js +223 -267
- package/components/split/index.vdt.js +8 -17
- package/components/split/style.d.ts +1 -1
- package/components/split/style.js +0 -8
- package/components/split/useDraggable.js +11 -35
- package/components/split/useSize.js +2 -5
- package/components/steps/context.d.ts +2 -2
- package/components/steps/index.js +2 -10
- package/components/steps/index.spec.js +21 -27
- package/components/steps/index.vdt.js +8 -10
- package/components/steps/step.js +0 -2
- package/components/steps/step.vdt.js +8 -12
- package/components/steps/styles.js +0 -27
- package/components/switch/index.js +2 -23
- package/components/switch/index.spec.js +188 -224
- package/components/switch/index.vdt.js +16 -32
- package/components/switch/styles.js +3 -14
- package/components/switch/useDraggable.js +10 -18
- package/components/table/cell.js +0 -6
- package/components/table/cell.vdt.js +14 -21
- package/components/table/column.d.ts +1 -1
- package/components/table/column.js +0 -5
- package/components/table/column.vdt.js +19 -30
- package/components/table/exportTable.js +45 -56
- package/components/table/index.spec.js +780 -984
- package/components/table/row.d.ts +1 -1
- package/components/table/row.js +18 -40
- package/components/table/row.vdt.js +27 -39
- package/components/table/styles.js +0 -11
- package/components/table/table.d.ts +5 -5
- package/components/table/table.js +18 -50
- package/components/table/table.vdt.js +61 -85
- package/components/table/useChecked.d.ts +1 -1
- package/components/table/useChecked.js +20 -61
- package/components/table/useColumns.js +3 -16
- package/components/table/useDisableRow.js +2 -12
- package/components/table/useDraggable.js +4 -12
- package/components/table/useExpandable.js +2 -5
- package/components/table/useFixedColumns.d.ts +1 -1
- package/components/table/useFixedColumns.js +4 -23
- package/components/table/useGroup.d.ts +1 -1
- package/components/table/useGroup.js +7 -24
- package/components/table/useMerge.d.ts +4 -4
- package/components/table/useMerge.js +2 -14
- package/components/table/usePagination.js +4 -18
- package/components/table/useResizable.js +2 -10
- package/components/table/useRestRowStatus.js +2 -6
- package/components/table/useScroll.d.ts +1 -1
- package/components/table/useScroll.js +0 -3
- package/components/table/useSelected.js +2 -5
- package/components/table/useSortable.js +2 -8
- package/components/table/useStickyHeader.js +3 -7
- package/components/table/useStickyScrollbar.js +6 -16
- package/components/table/useTree.js +1 -12
- package/components/table/useWidth.js +14 -30
- package/components/tabs/index.js +29 -51
- package/components/tabs/index.spec.js +56 -74
- package/components/tabs/index.vdt.js +13 -16
- package/components/tabs/styles.js +0 -16
- package/components/tabs/tab.js +0 -10
- package/components/tabs/tab.vdt.js +6 -10
- package/components/tabs/useActiveBar.js +2 -11
- package/components/tabs/useScroll.js +4 -20
- package/components/tag/base.js +0 -8
- package/components/tag/index.js +2 -4
- package/components/tag/index.spec.js +19 -25
- package/components/tag/index.vdt.js +8 -15
- package/components/tag/styles.js +0 -9
- package/components/timeline/item.js +0 -4
- package/components/timeline/item.vdt.js +4 -9
- package/components/timeline/styles.d.ts +2 -2
- package/components/timeline/styles.js +0 -4
- package/components/timeline/timeline.js +0 -2
- package/components/timeline/timeline.vdt.js +2 -5
- package/components/timepicker/index.js +2 -7
- package/components/timepicker/index.spec.js +293 -368
- package/components/timepicker/panelPicker.js +2 -11
- package/components/timepicker/panelPicker.vdt.js +14 -24
- package/components/timepicker/selectPicker.js +0 -5
- package/components/timepicker/selectPicker.vdt.js +5 -10
- package/components/timepicker/styles.js +0 -1
- package/components/timepicker/useDisabled.js +2 -4
- package/components/timepicker/useFormats.js +4 -13
- package/components/timepicker/useStep.d.ts +1 -1
- package/components/timepicker/useStep.js +8 -17
- package/components/timepicker/useValue.js +16 -21
- package/components/tip/index.js +0 -2
- package/components/tip/index.vdt.js +5 -17
- package/components/tip/styles.js +0 -3
- package/components/tooltip/content.js +0 -28
- package/components/tooltip/content.vdt.js +15 -25
- package/components/tooltip/index.js +3 -7
- package/components/tooltip/index.spec.js +434 -572
- package/components/tooltip/styles.d.ts +1 -1
- package/components/tooltip/styles.js +2 -10
- package/components/tooltip/tooltip.js +2 -15
- package/components/tooltip/useArrow.js +11 -14
- package/components/transfer/index.d.ts +1 -1
- package/components/transfer/index.js +1 -13
- package/components/transfer/index.spec.js +159 -194
- package/components/transfer/index.vdt.js +16 -34
- package/components/transfer/styles.js +0 -10
- package/components/transfer/useCheck.d.ts +1 -1
- package/components/transfer/useCheck.js +1 -15
- package/components/transfer/useFilter.d.ts +1 -1
- package/components/transfer/useFilter.js +9 -30
- package/components/transfer/useTransfer.js +10 -26
- package/components/tree/index.d.ts +3 -3
- package/components/tree/index.js +4 -22
- package/components/tree/index.spec.js +285 -355
- package/components/tree/index.vdt.js +12 -23
- package/components/tree/styles.js +2 -16
- package/components/tree/useChecked.js +3 -26
- package/components/tree/useDraggable.js +12 -42
- package/components/tree/useExpanded.js +26 -43
- package/components/tree/useFilter.js +3 -10
- package/components/tree/useNodes.d.ts +1 -1
- package/components/tree/useNodes.js +0 -4
- package/components/tree/useSelected.js +21 -38
- package/components/tree/useTransitionEvent.js +3 -5
- package/components/treeSelect/index.js +9 -36
- package/components/treeSelect/index.spec.js +123 -160
- package/components/treeSelect/index.vdt.js +14 -20
- package/components/treeSelect/styles.js +0 -1
- package/components/treeSelect/useValue.js +0 -11
- package/components/types.d.ts +3 -3
- package/components/upload/ajaxUploader.d.ts +1 -1
- package/components/upload/ajaxUploader.js +0 -17
- package/components/upload/index.d.ts +4 -4
- package/components/upload/index.js +0 -14
- package/components/upload/index.spec.js +142 -249
- package/components/upload/index.vdt.js +12 -27
- package/components/upload/styles.js +0 -30
- package/components/upload/useAccept.js +2 -10
- package/components/upload/useDrag.js +0 -7
- package/components/upload/useFiles.js +103 -145
- package/components/upload/useShowImage.js +0 -3
- package/components/upload/useUpload.js +47 -69
- package/components/utils.d.ts +4 -3
- package/components/utils.js +24 -43
- package/components/virtual.js +14 -39
- package/components/wave/index.js +5 -31
- package/hooks/useDelayClose.js +2 -6
- package/hooks/useDocumentClick.js +8 -16
- package/hooks/useDraggable.d.ts +1 -1
- package/hooks/useDraggable.js +0 -9
- package/hooks/useKeyboard.d.ts +3 -3
- package/hooks/useKeyboard.js +0 -10
- package/hooks/useMouseOutsidable.js +0 -8
- package/hooks/useReceive.d.ts +1 -1
- package/hooks/useReceive.js +0 -4
- package/hooks/useRecordComponent.js +0 -6
- package/hooks/useRouter.js +7 -18
- package/hooks/useShowHideEvents.js +0 -3
- package/hooks/useState.d.ts +2 -2
- package/hooks/useState.js +2 -6
- package/i18n/en-US.js +0 -1
- package/i18n/index.d.ts +1 -1
- package/i18n/index.js +0 -7
- package/index.d.ts +2 -2
- package/index.js +2 -3
- package/package.json +2 -2
- package/styles/global.js +2 -3
- package/styles/keyframes.js +0 -1
- package/styles/theme.d.ts +1 -1
- package/styles/theme.js +4 -7
- package/styles/utils.d.ts +1 -1
- package/styles/utils.js +3 -17
- package/yarn-error.log +1013 -0
- package/components/cascader/index.d.ts +0 -45
- package/components/datepicker/index.d.ts +0 -63
- package/components/select/select.d.ts +0 -33
- package/components/timepicker/panelPicker.d.ts +0 -54
- package/components/treeSelect/index.d.ts +0 -27
|
@@ -7,10 +7,9 @@ import mx from '../mxgraph';
|
|
|
7
7
|
import { DBase } from './base';
|
|
8
8
|
import { isNullOrUndefined } from 'intact-shared';
|
|
9
9
|
var mxCell = mx.mxCell,
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
mxGeometry = mx.mxGeometry,
|
|
11
|
+
mxPoint = mx.mxPoint;
|
|
12
12
|
var arrows = ['none', 'classic', 'classicThin', 'block', 'blockThin', 'open', 'openThin', 'oval', 'diamond', 'diamondThin'];
|
|
13
|
-
|
|
14
13
|
var typeDefs = _extends({}, DBase.typeDefs, {
|
|
15
14
|
type: ['rounded', 'sharp', 'curved', 'straight'],
|
|
16
15
|
startArrow: arrows,
|
|
@@ -22,7 +21,6 @@ var typeDefs = _extends({}, DBase.typeDefs, {
|
|
|
22
21
|
from: [String, Number],
|
|
23
22
|
to: [String, Number]
|
|
24
23
|
});
|
|
25
|
-
|
|
26
24
|
var defaults = function defaults() {
|
|
27
25
|
return _extends({}, DBase.defaults(), {
|
|
28
26
|
startArrow: 'none',
|
|
@@ -32,16 +30,12 @@ var defaults = function defaults() {
|
|
|
32
30
|
type: 'straight'
|
|
33
31
|
});
|
|
34
32
|
};
|
|
35
|
-
|
|
36
33
|
export var DLine = /*#__PURE__*/function (_DBase) {
|
|
37
34
|
_inheritsLoose(DLine, _DBase);
|
|
38
|
-
|
|
39
35
|
function DLine() {
|
|
40
36
|
return _DBase.apply(this, arguments) || this;
|
|
41
37
|
}
|
|
42
|
-
|
|
43
38
|
var _proto = DLine.prototype;
|
|
44
|
-
|
|
45
39
|
_proto.startDraw = function startDraw() {
|
|
46
40
|
var graph = this.diagram.graph;
|
|
47
41
|
var cell = this.cell;
|
|
@@ -50,28 +44,24 @@ export var DLine = /*#__PURE__*/function (_DBase) {
|
|
|
50
44
|
this.setTerminal();
|
|
51
45
|
graph.addCell(cell);
|
|
52
46
|
};
|
|
53
|
-
|
|
54
47
|
_proto.setTerminal = function setTerminal() {
|
|
55
48
|
var _this$get = this.get(),
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
49
|
+
from = _this$get.from,
|
|
50
|
+
to = _this$get.to,
|
|
51
|
+
startPoint = _this$get.startPoint,
|
|
52
|
+
endPoint = _this$get.endPoint;
|
|
61
53
|
var diagram = this.diagram;
|
|
62
54
|
var graph = diagram.graph;
|
|
63
55
|
var shapes = diagram.shapes;
|
|
64
56
|
var cell = this.cell;
|
|
65
57
|
var geo = cell.getGeometry();
|
|
66
58
|
var tmp;
|
|
67
|
-
|
|
68
59
|
if (isNullOrUndefined(from) || !(tmp = shapes.get(from))) {
|
|
69
60
|
cell.setTerminal(null, true);
|
|
70
61
|
geo.setTerminalPoint(_construct(mxPoint, startPoint), true);
|
|
71
62
|
} else {
|
|
72
63
|
cell.setTerminal(tmp.cell, true);
|
|
73
64
|
}
|
|
74
|
-
|
|
75
65
|
if (isNullOrUndefined(to) || !(tmp = shapes.get(to))) {
|
|
76
66
|
cell.setTerminal(null, false);
|
|
77
67
|
geo.setTerminalPoint(_construct(mxPoint, endPoint), false);
|
|
@@ -79,38 +69,29 @@ export var DLine = /*#__PURE__*/function (_DBase) {
|
|
|
79
69
|
cell.setTerminal(tmp.cell, false);
|
|
80
70
|
}
|
|
81
71
|
};
|
|
82
|
-
|
|
83
72
|
_proto.addToDigram = function addToDigram() {
|
|
84
73
|
this.diagram.addLine(this);
|
|
85
74
|
};
|
|
86
|
-
|
|
87
75
|
_proto.deleteFromDiagram = function deleteFromDiagram() {
|
|
88
76
|
this.diagram.deleteLine(this);
|
|
89
77
|
};
|
|
90
|
-
|
|
91
78
|
_proto.getStylesheet = function getStylesheet() {
|
|
92
79
|
var _this$get2 = this.get(),
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
80
|
+
startArrow = _this$get2.startArrow,
|
|
81
|
+
endArrow = _this$get2.endArrow;
|
|
96
82
|
return "startArrow=" + startArrow + ";endArrow=" + endArrow + ";html=1;fontSize=12;";
|
|
97
83
|
};
|
|
98
|
-
|
|
99
84
|
_proto.getGeometry = function getGeometry() {
|
|
100
85
|
var geo = new mxGeometry(0, 0, 0, 0);
|
|
101
86
|
geo.relative = true;
|
|
102
87
|
return geo;
|
|
103
88
|
};
|
|
104
|
-
|
|
105
89
|
_proto.genStyles = function genStyles() {
|
|
106
90
|
return _extends({}, this.genStylesForExitAndEntry(), this.genStylesForType(), _DBase.prototype.genStyles.call(this));
|
|
107
91
|
};
|
|
108
|
-
|
|
109
92
|
_proto.updateProps = function updateProps(model, lastProps, nextProps) {
|
|
110
93
|
var _context;
|
|
111
|
-
|
|
112
94
|
_DBase.prototype.updateProps.call(this, model, lastProps, nextProps);
|
|
113
|
-
|
|
114
95
|
if (_findInstanceProperty(_context = ['from', 'to', 'startPoint', 'endPoint']).call(_context, function (key) {
|
|
115
96
|
return lastProps[key] !== nextProps[key];
|
|
116
97
|
})) {
|
|
@@ -118,73 +99,57 @@ export var DLine = /*#__PURE__*/function (_DBase) {
|
|
|
118
99
|
this.setTerminal();
|
|
119
100
|
}
|
|
120
101
|
};
|
|
121
|
-
|
|
122
102
|
_proto.genStylesForExitAndEntry = function genStylesForExitAndEntry() {
|
|
123
103
|
var styles = {};
|
|
124
|
-
|
|
125
104
|
var _this$get3 = this.get(),
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
105
|
+
from = _this$get3.from,
|
|
106
|
+
exit = _this$get3.exit,
|
|
107
|
+
to = _this$get3.to,
|
|
108
|
+
entry = _this$get3.entry;
|
|
131
109
|
if (!isNullOrUndefined(from) && exit) {
|
|
132
110
|
styles.exitX = exit[0];
|
|
133
111
|
styles.exitY = exit[1];
|
|
134
112
|
styles.perimeter = 0;
|
|
135
113
|
}
|
|
136
|
-
|
|
137
114
|
if (!isNullOrUndefined(to) && entry) {
|
|
138
115
|
styles.entryX = entry[0];
|
|
139
116
|
styles.entryY = entry[1];
|
|
140
117
|
styles.perimeter = 0;
|
|
141
118
|
}
|
|
142
|
-
|
|
143
119
|
return styles;
|
|
144
120
|
};
|
|
145
|
-
|
|
146
121
|
_proto.genStylesForType = function genStylesForType() {
|
|
147
122
|
var styles = {};
|
|
148
|
-
|
|
149
123
|
var _this$get4 = this.get(),
|
|
150
|
-
|
|
151
|
-
|
|
124
|
+
type = _this$get4.type;
|
|
152
125
|
if (type !== 'straight') {
|
|
153
126
|
styles.edgeStyle = 'orthogonalEdgeStyle';
|
|
154
127
|
}
|
|
155
|
-
|
|
156
128
|
switch (type) {
|
|
157
129
|
case 'rounded':
|
|
158
130
|
styles.rounded = 1;
|
|
159
131
|
styles.curved = null;
|
|
160
132
|
break;
|
|
161
|
-
|
|
162
133
|
case 'curved':
|
|
163
134
|
styles.rounded = 0;
|
|
164
135
|
styles.curved = 1;
|
|
165
136
|
break;
|
|
166
|
-
|
|
167
137
|
case 'sharp':
|
|
168
138
|
styles.rounded = 0;
|
|
169
139
|
styles.curved = null;
|
|
170
140
|
break;
|
|
171
|
-
|
|
172
141
|
default:
|
|
173
142
|
styles.edgeStyle = 'straight';
|
|
174
143
|
styles.curved = null;
|
|
175
144
|
styles.noEdgeStyle = null;
|
|
176
145
|
break;
|
|
177
146
|
}
|
|
178
|
-
|
|
179
147
|
return styles;
|
|
180
148
|
};
|
|
181
|
-
|
|
182
149
|
return DLine;
|
|
183
150
|
}(DBase);
|
|
184
|
-
|
|
185
151
|
DLine.template = function () {
|
|
186
152
|
return h('dline', null, this.get('children'));
|
|
187
153
|
};
|
|
188
|
-
|
|
189
154
|
DLine.typeDefs = typeDefs;
|
|
190
155
|
DLine.defaults = defaults;
|
|
@@ -4,68 +4,56 @@ import { DShape } from './shape';
|
|
|
4
4
|
import mx from '../mxgraph';
|
|
5
5
|
import { hasDocumentAvailable } from 'intact-shared';
|
|
6
6
|
var mxActor = mx.mxActor,
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
7
|
+
mxUtils = mx.mxUtils,
|
|
8
|
+
mxCellRenderer = mx.mxCellRenderer,
|
|
9
|
+
mxConstants = mx.mxConstants,
|
|
10
|
+
mxPoint = mx.mxPoint,
|
|
11
|
+
mxRectangleShape = mx.mxRectangleShape,
|
|
12
|
+
mxPerimeter = mx.mxPerimeter,
|
|
13
|
+
mxStyleRegistry = mx.mxStyleRegistry;
|
|
14
14
|
export var DParallelogram = /*#__PURE__*/function (_DShape) {
|
|
15
15
|
_inheritsLoose(DParallelogram, _DShape);
|
|
16
|
-
|
|
17
16
|
function DParallelogram() {
|
|
18
17
|
return _DShape.apply(this, arguments) || this;
|
|
19
18
|
}
|
|
20
|
-
|
|
21
19
|
DParallelogram.defaults = function defaults() {
|
|
22
20
|
return _extends({}, DShape.defaults(), {
|
|
23
21
|
width: 120,
|
|
24
22
|
height: 60
|
|
25
23
|
});
|
|
26
24
|
};
|
|
27
|
-
|
|
28
25
|
var _proto = DParallelogram.prototype;
|
|
29
|
-
|
|
30
26
|
_proto.getStylesheet = function getStylesheet() {
|
|
31
27
|
return 'shape=parallelogram;perimeter=parallelogramPerimeter;whiteSpace=wrap;html=1;';
|
|
32
28
|
};
|
|
33
|
-
|
|
34
29
|
return DParallelogram;
|
|
35
30
|
}(DShape);
|
|
36
31
|
DParallelogram.displayName = 'DParallelogram';
|
|
37
|
-
|
|
38
32
|
if (hasDocumentAvailable) {
|
|
39
33
|
// Parallelogram shape
|
|
40
34
|
var ParallelogramShape = function ParallelogramShape() {
|
|
41
35
|
mxActor.call(this);
|
|
42
36
|
};
|
|
43
|
-
|
|
44
37
|
mxUtils.extend(ParallelogramShape, mxActor);
|
|
45
38
|
ParallelogramShape.prototype.size = 0.2;
|
|
46
39
|
/* istanbul ignore next */
|
|
47
|
-
|
|
48
40
|
ParallelogramShape.prototype.isRoundable = function () {
|
|
49
41
|
return true;
|
|
50
42
|
};
|
|
51
|
-
|
|
52
43
|
ParallelogramShape.prototype.redrawPath = function (c, x, y, w, h) {
|
|
53
44
|
var dx = w * Math.max(0, Math.min(1, parseFloat(mxUtils.getValue(this.style, 'size', this.size))));
|
|
54
45
|
var arcSize = mxUtils.getValue(this.style, mxConstants.STYLE_ARCSIZE, mxConstants.LINE_ARCSIZE) / 2;
|
|
55
46
|
this.addPoints(c, [new mxPoint(0, h), new mxPoint(dx, 0), new mxPoint(w, 0), new mxPoint(w - dx, h)], this.isRounded, arcSize, true);
|
|
56
47
|
c.end();
|
|
57
48
|
};
|
|
58
|
-
|
|
59
49
|
mxCellRenderer.registerShape('parallelogram', ParallelogramShape);
|
|
60
|
-
ParallelogramShape.prototype.constraints = mxRectangleShape.prototype.constraints;
|
|
61
|
-
|
|
50
|
+
ParallelogramShape.prototype.constraints = mxRectangleShape.prototype.constraints;
|
|
51
|
+
// Parallelogram Perimeter
|
|
62
52
|
mxPerimeter.ParallelogramPerimeter = function (bounds, vertex, next, orthogonal) {
|
|
63
53
|
var size = ParallelogramShape.prototype.size;
|
|
64
|
-
|
|
65
54
|
if (vertex != null) {
|
|
66
55
|
size = mxUtils.getValue(vertex.style, 'size', size);
|
|
67
56
|
}
|
|
68
|
-
|
|
69
57
|
var x = bounds.x;
|
|
70
58
|
var y = bounds.y;
|
|
71
59
|
var w = bounds.width;
|
|
@@ -73,7 +61,6 @@ if (hasDocumentAvailable) {
|
|
|
73
61
|
var direction = vertex != null ? mxUtils.getValue(vertex.style, mxConstants.STYLE_DIRECTION, mxConstants.DIRECTION_EAST) : mxConstants.DIRECTION_EAST;
|
|
74
62
|
var vertical = direction == mxConstants.DIRECTION_NORTH || direction == mxConstants.DIRECTION_SOUTH;
|
|
75
63
|
var points;
|
|
76
|
-
|
|
77
64
|
if (vertical) {
|
|
78
65
|
var dy = h * Math.max(0, Math.min(1, size));
|
|
79
66
|
points = [new mxPoint(x, y), new mxPoint(x + w, y + dy), new mxPoint(x + w, y + h), new mxPoint(x, y + h - dy), new mxPoint(x, y)];
|
|
@@ -81,11 +68,9 @@ if (hasDocumentAvailable) {
|
|
|
81
68
|
var dx = w * Math.max(0, Math.min(1, size));
|
|
82
69
|
points = [new mxPoint(x + dx, y), new mxPoint(x + w, y), new mxPoint(x + w - dx, y + h), new mxPoint(x, y + h), new mxPoint(x + dx, y)];
|
|
83
70
|
}
|
|
84
|
-
|
|
85
71
|
var cx = bounds.getCenterX();
|
|
86
72
|
var cy = bounds.getCenterY();
|
|
87
73
|
var p1 = new mxPoint(cx, cy);
|
|
88
|
-
|
|
89
74
|
if (orthogonal) {
|
|
90
75
|
if (next.x < x || next.x > x + w) {
|
|
91
76
|
p1.y = next.y;
|
|
@@ -93,9 +78,7 @@ if (hasDocumentAvailable) {
|
|
|
93
78
|
p1.x = next.x;
|
|
94
79
|
}
|
|
95
80
|
}
|
|
96
|
-
|
|
97
81
|
return mxUtils.getPerimeterPoint(points, p1, next);
|
|
98
82
|
};
|
|
99
|
-
|
|
100
83
|
mxStyleRegistry.putValue('parallelogramPerimeter', mxPerimeter.ParallelogramPerimeter);
|
|
101
84
|
}
|
|
@@ -1,18 +1,14 @@
|
|
|
1
1
|
import _inheritsLoose from "@babel/runtime-corejs3/helpers/inheritsLoose";
|
|
2
2
|
import _extends from "@babel/runtime-corejs3/helpers/extends";
|
|
3
3
|
import { DShape } from './shape';
|
|
4
|
-
|
|
5
4
|
var typeDefs = _extends({}, DShape.typeDefs, {
|
|
6
5
|
rounded: [Number, String]
|
|
7
6
|
});
|
|
8
|
-
|
|
9
7
|
export var DRectangle = /*#__PURE__*/function (_DShape) {
|
|
10
8
|
_inheritsLoose(DRectangle, _DShape);
|
|
11
|
-
|
|
12
9
|
function DRectangle() {
|
|
13
10
|
return _DShape.apply(this, arguments) || this;
|
|
14
11
|
}
|
|
15
|
-
|
|
16
12
|
DRectangle.defaults = function defaults() {
|
|
17
13
|
return _extends({}, DShape.defaults(), {
|
|
18
14
|
width: 120,
|
|
@@ -20,16 +16,12 @@ export var DRectangle = /*#__PURE__*/function (_DShape) {
|
|
|
20
16
|
rounded: 0
|
|
21
17
|
});
|
|
22
18
|
};
|
|
23
|
-
|
|
24
19
|
var _proto = DRectangle.prototype;
|
|
25
|
-
|
|
26
20
|
_proto.getStylesheet = function getStylesheet() {
|
|
27
21
|
var _this$get = this.get(),
|
|
28
|
-
|
|
29
|
-
|
|
22
|
+
rounded = _this$get.rounded;
|
|
30
23
|
return "rounded=" + (+rounded ? 1 : 0) + ";whiteSpace=wrap;html=1;arcSize=" + rounded;
|
|
31
24
|
};
|
|
32
|
-
|
|
33
25
|
return DRectangle;
|
|
34
26
|
}(DShape);
|
|
35
27
|
DRectangle.displayName = 'DRectangle';
|
|
@@ -8,9 +8,8 @@ import { isStringOrNumber, isNullOrUndefined } from 'intact-shared';
|
|
|
8
8
|
import { SHAPE } from '../constants';
|
|
9
9
|
import { DBase } from './base';
|
|
10
10
|
var mxCell = mx.mxCell,
|
|
11
|
-
|
|
11
|
+
mxGeometry = mx.mxGeometry;
|
|
12
12
|
var strOrNum = [String, Number];
|
|
13
|
-
|
|
14
13
|
var typeDefs = _extends({}, DBase.typeDefs, {
|
|
15
14
|
left: strOrNum,
|
|
16
15
|
top: strOrNum,
|
|
@@ -23,7 +22,6 @@ var typeDefs = _extends({}, DBase.typeDefs, {
|
|
|
23
22
|
editable: Boolean,
|
|
24
23
|
connectable: Boolean
|
|
25
24
|
});
|
|
26
|
-
|
|
27
25
|
var defaults = function defaults() {
|
|
28
26
|
return _extends({}, DBase.defaults(), {
|
|
29
27
|
left: 0,
|
|
@@ -32,19 +30,14 @@ var defaults = function defaults() {
|
|
|
32
30
|
height: 0
|
|
33
31
|
});
|
|
34
32
|
};
|
|
35
|
-
|
|
36
33
|
export var DShape = /*#__PURE__*/function (_DBase) {
|
|
37
34
|
_inheritsLoose(DShape, _DBase);
|
|
38
|
-
|
|
39
35
|
function DShape() {
|
|
40
36
|
var _context;
|
|
41
|
-
|
|
42
37
|
var _this;
|
|
43
|
-
|
|
44
38
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
45
39
|
args[_key] = arguments[_key];
|
|
46
40
|
}
|
|
47
|
-
|
|
48
41
|
_this = _DBase.call.apply(_DBase, _concatInstanceProperty(_context = [this]).call(_context, args)) || this;
|
|
49
42
|
_this.wrapperRef = createRef();
|
|
50
43
|
_this.hasElement = false;
|
|
@@ -52,44 +45,35 @@ export var DShape = /*#__PURE__*/function (_DBase) {
|
|
|
52
45
|
_this.parent = inject(SHAPE, null);
|
|
53
46
|
return _this;
|
|
54
47
|
}
|
|
55
|
-
|
|
56
48
|
var _proto = DShape.prototype;
|
|
57
|
-
|
|
58
49
|
_proto.init = function init() {
|
|
59
50
|
var _this2 = this;
|
|
60
|
-
|
|
61
51
|
// shape can nest
|
|
62
52
|
provide(SHAPE, this);
|
|
63
53
|
this.on('$receive:children', function (children) {
|
|
64
54
|
_this2.children = mapChildren(children, function (vNode) {
|
|
65
55
|
if (isStringOrNumber(vNode)) return vNode;
|
|
66
|
-
|
|
67
56
|
if (isComponentClass(vNode)) {
|
|
68
57
|
var proto = vNode.tag.prototype;
|
|
69
|
-
|
|
70
58
|
if (proto instanceof DShape) {
|
|
71
59
|
return vNode;
|
|
72
60
|
}
|
|
73
61
|
}
|
|
74
|
-
|
|
75
62
|
_this2.hasElement = true;
|
|
76
63
|
return vNode;
|
|
77
64
|
});
|
|
78
65
|
});
|
|
79
66
|
};
|
|
80
|
-
|
|
81
67
|
_proto.updated = function updated() {
|
|
82
68
|
var model = this.diagram.graph.model;
|
|
83
69
|
var geo = this.getGeometry();
|
|
84
70
|
model.setGeometry(this.cell, geo);
|
|
85
71
|
};
|
|
86
|
-
|
|
87
72
|
_proto.beforeUnmount = function beforeUnmount() {
|
|
88
73
|
var graph = this.diagram.graph;
|
|
89
74
|
this.deleteFromDiagram();
|
|
90
75
|
graph.removeCells([this.cell], false);
|
|
91
76
|
};
|
|
92
|
-
|
|
93
77
|
_proto.startDraw = function startDraw() {
|
|
94
78
|
var diagram = this.diagram;
|
|
95
79
|
var cell = this.cell;
|
|
@@ -98,54 +82,41 @@ export var DShape = /*#__PURE__*/function (_DBase) {
|
|
|
98
82
|
this.setStyle();
|
|
99
83
|
diagram.graph.addCell(cell, parentCell);
|
|
100
84
|
};
|
|
101
|
-
|
|
102
85
|
_proto.addToDigram = function addToDigram() {
|
|
103
86
|
this.diagram.addShape(this);
|
|
104
87
|
};
|
|
105
|
-
|
|
106
88
|
_proto.deleteFromDiagram = function deleteFromDiagram() {
|
|
107
89
|
this.diagram.deleteShape(this);
|
|
108
90
|
};
|
|
109
|
-
|
|
110
91
|
_proto.getGeometry = function getGeometry() {
|
|
111
92
|
var _this$get = this.get(),
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
93
|
+
width = _this$get.width,
|
|
94
|
+
height = _this$get.height,
|
|
95
|
+
top = _this$get.top,
|
|
96
|
+
left = _this$get.left;
|
|
117
97
|
return new mxGeometry(+left, +top, +width, +height);
|
|
118
98
|
};
|
|
119
|
-
|
|
120
99
|
_proto.getValue = function getValue() {
|
|
121
100
|
var _this$get2 = this.get(),
|
|
122
|
-
|
|
123
|
-
|
|
101
|
+
label = _this$get2.label;
|
|
124
102
|
return isNullOrUndefined(label) ? this.hasElement && this.wrapperRef.value || null : String(label);
|
|
125
103
|
};
|
|
126
|
-
|
|
127
104
|
_proto.setStyle = function setStyle() {
|
|
128
105
|
// if hasElement, disable edit
|
|
129
106
|
this.diagram.graph.setCellStyles('editable', this.hasElement ? 0 : 1, [this.cell]);
|
|
130
|
-
|
|
131
107
|
_DBase.prototype.setStyle.call(this);
|
|
132
108
|
};
|
|
133
|
-
|
|
134
109
|
return DShape;
|
|
135
110
|
}(DBase);
|
|
136
|
-
|
|
137
111
|
DShape.template = function () {
|
|
138
112
|
var children = this.children;
|
|
139
|
-
|
|
140
113
|
if (children && children.length) {
|
|
141
114
|
children = h('div', {
|
|
142
115
|
ref: this.wrapperRef
|
|
143
116
|
}, children);
|
|
144
117
|
}
|
|
145
|
-
|
|
146
118
|
var Ctor = this.constructor;
|
|
147
119
|
return h(Ctor.displayName || Ctor.name, null, children);
|
|
148
120
|
};
|
|
149
|
-
|
|
150
121
|
DShape.typeDefs = typeDefs;
|
|
151
122
|
DShape.defaults = defaults;
|
|
@@ -5,34 +5,26 @@ import mx from '../mxgraph';
|
|
|
5
5
|
var mxGeometry = mx.mxGeometry;
|
|
6
6
|
export var DSquare = /*#__PURE__*/function (_DRectangle) {
|
|
7
7
|
_inheritsLoose(DSquare, _DRectangle);
|
|
8
|
-
|
|
9
8
|
function DSquare() {
|
|
10
9
|
return _DRectangle.apply(this, arguments) || this;
|
|
11
10
|
}
|
|
12
|
-
|
|
13
11
|
DSquare.defaults = function defaults() {
|
|
14
12
|
return _extends({}, DRectangle.defaults(), {
|
|
15
13
|
width: 80
|
|
16
14
|
});
|
|
17
15
|
};
|
|
18
|
-
|
|
19
16
|
var _proto = DSquare.prototype;
|
|
20
|
-
|
|
21
17
|
_proto.getStylesheet = function getStylesheet() {
|
|
22
18
|
var stylesheet = _DRectangle.prototype.getStylesheet.call(this);
|
|
23
|
-
|
|
24
19
|
return stylesheet + "aspect=fixed;";
|
|
25
20
|
};
|
|
26
|
-
|
|
27
21
|
_proto.getGeometry = function getGeometry() {
|
|
28
22
|
var _this$get = this.get(),
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
23
|
+
width = _this$get.width,
|
|
24
|
+
left = _this$get.left,
|
|
25
|
+
top = _this$get.top;
|
|
33
26
|
return new mxGeometry(+left, +top, +width, +width);
|
|
34
27
|
};
|
|
35
|
-
|
|
36
28
|
return DSquare;
|
|
37
29
|
}(DRectangle);
|
|
38
30
|
DSquare.displayName = 'DSquare';
|
|
@@ -3,24 +3,19 @@ import _inheritsLoose from "@babel/runtime-corejs3/helpers/inheritsLoose";
|
|
|
3
3
|
import { DShape } from './shape';
|
|
4
4
|
export var DText = /*#__PURE__*/function (_DShape) {
|
|
5
5
|
_inheritsLoose(DText, _DShape);
|
|
6
|
-
|
|
7
6
|
function DText() {
|
|
8
7
|
return _DShape.apply(this, arguments) || this;
|
|
9
8
|
}
|
|
10
|
-
|
|
11
9
|
DText.defaults = function defaults() {
|
|
12
10
|
return _extends({}, DShape.defaults(), {
|
|
13
11
|
width: 40,
|
|
14
12
|
height: 20
|
|
15
13
|
});
|
|
16
14
|
};
|
|
17
|
-
|
|
18
15
|
var _proto = DText.prototype;
|
|
19
|
-
|
|
20
16
|
_proto.getStylesheet = function getStylesheet() {
|
|
21
17
|
return "text;html=1;strokeColor=none;fillColor=none;align=center;verticalAlign=middle;whiteSpace=wrap;rounded=0;";
|
|
22
18
|
};
|
|
23
|
-
|
|
24
19
|
return DText;
|
|
25
20
|
}(DShape);
|
|
26
21
|
DText.displayName = 'DText';
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
2
|
-
|
|
3
2
|
import { css } from '@emotion/css';
|
|
4
3
|
import '../../styles/global';
|
|
5
4
|
export function makeStyles() {
|
|
@@ -4,21 +4,18 @@ import { Button } from '../button';
|
|
|
4
4
|
import { makeAlertStyles } from './styles';
|
|
5
5
|
export default function ($props, $blocks, $__proto__) {
|
|
6
6
|
var _classNameObj;
|
|
7
|
-
|
|
8
7
|
$blocks || ($blocks = {});
|
|
9
8
|
$props || ($props = {});
|
|
10
9
|
var $this = this;
|
|
11
|
-
|
|
12
10
|
var _this$get = this.get(),
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
11
|
+
type = _this$get.type,
|
|
12
|
+
content = _this$get.content,
|
|
13
|
+
hideIcon = _this$get.hideIcon,
|
|
14
|
+
hideFooter = _this$get.hideFooter,
|
|
15
|
+
hideClose = _this$get.hideClose,
|
|
16
|
+
title = _this$get.title,
|
|
17
|
+
iconClassName = _this$get.iconClassName,
|
|
18
|
+
icon = _this$get.icon;
|
|
22
19
|
var classNameObj = (_classNameObj = {
|
|
23
20
|
'k-alert-dialog': true
|
|
24
21
|
}, _classNameObj["k-" + type] = true, _classNameObj['k-with-title'] = title, _classNameObj[makeAlertStyles()] = true, _classNameObj);
|
|
@@ -26,17 +23,14 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
26
23
|
'className': _$cn(classNameObj)
|
|
27
24
|
}, function ($blocks) {
|
|
28
25
|
var _$blocks = {},
|
|
29
|
-
|
|
30
|
-
|
|
26
|
+
__$blocks = _$ex({}, $blocks);
|
|
31
27
|
return (_$blocks['header'] = function ($super) {
|
|
32
28
|
return null;
|
|
33
29
|
}, __$blocks['header'] = function ($super, data) {
|
|
34
30
|
var block = $blocks['header'];
|
|
35
|
-
|
|
36
31
|
var callBlock = function callBlock() {
|
|
37
32
|
return _$blocks['header'].call($this, $super, data);
|
|
38
33
|
};
|
|
39
|
-
|
|
40
34
|
return block ? block.call($this, callBlock, data) : callBlock();
|
|
41
35
|
}), (_$blocks['body'] = function ($super) {
|
|
42
36
|
return [_$ce(2, 'div', [!hideIcon && !icon ? _$cc(Icon, {
|
|
@@ -49,21 +43,17 @@ export default function ($props, $blocks, $__proto__) {
|
|
|
49
43
|
}) : undefined, icon], 0, 'k-dialog-tip-icon'), _$ce(2, 'div', [title ? _$ce(2, 'div', title, 0, 'k-alert-dialog-title') : undefined, content], 0, 'k-alert-dialog-wrapper')];
|
|
50
44
|
}, __$blocks['body'] = function ($super, data) {
|
|
51
45
|
var block = $blocks['body'];
|
|
52
|
-
|
|
53
46
|
var callBlock = function callBlock() {
|
|
54
47
|
return _$blocks['body'].call($this, $super, data);
|
|
55
48
|
};
|
|
56
|
-
|
|
57
49
|
return block ? block.call($this, callBlock, data) : callBlock();
|
|
58
50
|
}), (_$blocks['footer'] = function ($super) {
|
|
59
51
|
return hideFooter ? null : $super();
|
|
60
52
|
}, __$blocks['footer'] = function ($super, data) {
|
|
61
53
|
var block = $blocks['footer'];
|
|
62
|
-
|
|
63
54
|
var callBlock = function callBlock() {
|
|
64
55
|
return _$blocks['footer'].call($this, $super, data);
|
|
65
56
|
};
|
|
66
|
-
|
|
67
57
|
return block ? block.call($this, callBlock, data) : callBlock();
|
|
68
58
|
}), __$blocks;
|
|
69
59
|
}.call($this, $blocks), $__proto__);
|