fan-standard-comp 3.2.1 → 4.0.1
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/LICENSE +21 -0
- package/README.md +15 -0
- package/dist/fan-standard-comp.min.css +1 -0
- package/dist/fan-standard-comp.min.js +1 -0
- package/es/ButtonGroup/PopConfirmTitle.d.ts +1 -1
- package/es/ButtonGroup/PopConfirmTitle.js +2 -2
- package/es/ButtonGroup/index.d.ts +5 -3
- package/es/ButtonGroup/index.js +259 -189
- package/es/ButtonGroup/styles/index.d.ts +8 -0
- package/es/ButtonGroup/styles/index.js +61 -0
- package/es/ButtonGroup/testStyles/index(antd-style).d.ts +11 -0
- package/es/ButtonGroup/testStyles/index(antd-style).js +28 -0
- package/es/ButtonGroup/testStyles/index(cssinjs).js +133 -0
- package/es/ButtonGroup/testStyles/index.d.ts +11 -0
- package/es/ButtonGroup/testStyles/index.js +23 -0
- package/es/CalendarCoordPicker/CalendarMonthPicker.d.ts +5 -0
- package/es/CalendarCoordPicker/CalendarMonthPicker.js +32 -0
- package/es/CalendarCoordPicker/index.d.ts +7 -0
- package/es/CalendarCoordPicker/index.js +314 -0
- package/es/CalendarCoordPicker/styles/index.d.ts +6 -0
- package/es/CalendarCoordPicker/styles/index.js +28 -0
- package/es/CalendarCoordPicker/styles/index.less +37 -0
- package/es/ConfigContext/index.d.ts +7 -0
- package/es/ConfigContext/index.js +20 -0
- package/es/DragContent/DragBar.d.ts +3 -0
- package/es/DragContent/DragBar.js +0 -1
- package/es/DragContent/index.d.ts +1 -1
- package/es/DragContent/index.js +20 -6
- package/es/DragContent/styles/index.d.ts +6 -0
- package/es/DragContent/styles/index.js +52 -0
- package/es/FormComp/ChunkUploader/api.js +11 -11
- package/es/FormComp/ChunkUploader/index.js +125 -132
- package/es/FormComp/ChunkUploader/lib.js +19 -19
- package/es/FormComp/ChunkUploader/upload-queue.class.js +51 -51
- package/es/FormComp/EditButton/index.d.ts +1 -1
- package/es/FormComp/EditButton/index.js +18 -17
- package/es/FormComp/FieldComponent/ReUpload.d.ts +1 -1
- package/es/FormComp/FieldComponent/ReUpload.js +45 -37
- package/es/FormComp/FieldComponent/RefactorTreeSelect.js +28 -19
- package/es/FormComp/FieldComponent/TitleNode.d.ts +2 -1
- package/es/FormComp/FieldComponent/UploaderViewer.d.ts +2 -0
- package/es/FormComp/FieldComponent/UploaderViewer.js +92 -0
- package/es/FormComp/FieldComponent/index.d.ts +1 -1
- package/es/FormComp/FieldComponent/index.js +88 -109
- package/es/FormComp/FieldComponent/setReadonlyValues.js +21 -15
- package/es/FormComp/FieldComponent/style/TreeSelect.d.ts +6 -0
- package/es/FormComp/FieldComponent/style/TreeSelect.js +42 -0
- package/es/FormComp/FieldComponent/style/UploaderStyle.d.ts +6 -0
- package/es/FormComp/FieldComponent/style/UploaderStyle.js +25 -0
- package/es/FormComp/FieldComponent/style/index.less +26 -21
- package/es/FormComp/RenderItemGroup/index.d.ts +4 -0
- package/es/FormComp/RenderItemGroup/index.js +183 -66
- package/es/FormComp/RenderItemGroup/style/index.d.ts +6 -0
- package/es/FormComp/RenderItemGroup/style/index.js +40 -0
- package/es/FormComp/Uploader/index.js +94 -75
- package/es/FormComp/Uploader/style/index.less +14 -14
- package/es/FormComp/Uploader/util.d.ts +2 -2
- package/es/FormComp/VarTemplate/index.js +32 -40
- package/es/FormComp/index.js +1 -1
- package/es/NavLeafScroll/Main.js +443 -0
- package/es/NavLeafScroll/index.d.ts +2 -0
- package/es/NavLeafScroll/index.js +21 -395
- package/es/NavLeafScroll/style/index.d.ts +6 -0
- package/es/NavLeafScroll/style/index.js +56 -0
- package/es/NavLeafScroll/style/index.less +22 -22
- package/es/RefactorTree/index.d.ts +1 -1
- package/es/RefactorTree/index.js +21 -19
- package/es/RefactorTree/style/index.js +1 -1
- package/es/RefactorTree/style/index.less +22 -22
- package/es/RefactorTree/util.d.ts +2 -2
- package/es/RefactorTree/util.js +30 -15
- package/es/SpecIcon/fonts/demo_index.html +559 -5
- package/es/SpecIcon/fonts/iconfont.css +101 -3
- package/es/SpecIcon/fonts/iconfont.js +34 -27
- package/es/SpecIcon/fonts/iconfont.json +168 -0
- package/es/SpecIcon/fonts/iconfont.svg +163 -171
- package/es/SpecIcon/fonts/iconfont.ttf +0 -0
- package/es/SpecIcon/fonts/iconfont.woff +0 -0
- package/es/SpecIcon/fonts/iconfont.woff2 +0 -0
- package/es/SpecIcon/index.d.ts +0 -1
- package/es/SpecIcon/index.js +33 -12
- package/es/SpecIcon/styles/index(antd-style).d.ts +6 -0
- package/es/SpecIcon/styles/index(antd-style).js +13 -0
- package/es/SpecIcon/styles/index.d.ts +6 -0
- package/es/SpecIcon/styles/index.js +93 -0
- package/es/StandardContent/SplitterLayout/Pane.js +3 -3
- package/es/StandardContent/SplitterLayout/index.js +7 -6
- package/es/StandardContent/SplitterLayout/index.less +0 -1
- package/es/StandardContent/SubfieldContent.d.ts +3 -2
- package/es/StandardContent/SubfieldContent.js +24 -12
- package/es/StandardContent/WrapperContent.d.ts +2 -2
- package/es/StandardContent/WrapperContent.js +22 -11
- package/es/StandardContent/styles/Subfield.d.ts +6 -0
- package/es/StandardContent/styles/Subfield.js +30 -0
- package/es/StandardContent/styles/Wrapper.d.ts +6 -0
- package/es/StandardContent/styles/Wrapper.js +28 -0
- package/es/StandardContent/styles/index.less +67 -0
- package/es/StandardDragModal/ChangeStandardModal.d.ts +2 -2
- package/es/StandardDragModal/ChangeStandardModal.js +84 -71
- package/es/StandardDragModal/DraggableModal.js +7 -4
- package/es/StandardDragModal/DraggableModalContext.d.ts +1 -1
- package/es/StandardDragModal/DraggableModalInner.d.ts +2 -2
- package/es/StandardDragModal/DraggableModalInner.js +31 -21
- package/es/StandardDragModal/DraggableModalProvider.js +5 -5
- package/es/StandardDragModal/Modal.d.ts +1 -1
- package/es/StandardDragModal/Modal.js +8 -5
- package/es/StandardDragModal/ResizeHandle.js +2 -1
- package/es/StandardDragModal/draggableModalReducer.d.ts +4 -4
- package/es/StandardDragModal/draggableModalReducer.js +31 -22
- package/es/StandardDragModal/index.js +3 -3
- package/es/StandardDragModal/useDrag.js +2 -2
- package/es/StandardDragModal/useResize.js +2 -2
- package/es/StandardFilter/index.d.ts +8 -17
- package/es/StandardFilter/index.js +279 -206
- package/es/StandardFilter/style/FilterStyle.d.ts +6 -0
- package/es/StandardFilter/style/FilterStyle.js +50 -0
- package/es/StandardFilter/style/index.less +85 -36
- package/es/StandardForm/ActionList.d.ts +9 -0
- package/es/StandardForm/ActionList.js +5 -5
- package/es/StandardForm/StepForm.d.ts +1 -1
- package/es/StandardForm/StepForm.js +47 -40
- package/es/StandardForm/TabForm.d.ts +2 -1
- package/es/StandardForm/TabForm.js +50 -41
- package/es/StandardForm/index.d.ts +2 -1
- package/es/StandardForm/index.js +40 -22
- package/es/StandardForm/style/index.d.ts +6 -0
- package/es/StandardForm/style/index.js +49 -0
- package/es/StandardForm/style/index.less +23 -12
- package/es/StandardModal/UpdateFormRef.js +0 -1
- package/es/StandardModal/index.d.ts +4 -3
- package/es/StandardModal/index.js +153 -133
- package/es/StandardModal/style/index.d.ts +6 -0
- package/es/StandardModal/style/index.js +46 -0
- package/es/StandardModal/style/index.less +29 -29
- package/es/StandardPanel/index.d.ts +1 -1
- package/es/StandardPanel/index.js +28 -17
- package/es/StandardPanel/style/index.d.ts +6 -0
- package/es/StandardPanel/style/index.js +87 -0
- package/es/StandardPanel/style/index.less +30 -32
- package/es/StandardTable/index.d.ts +6 -1
- package/es/StandardTable/index.js +92 -40
- package/es/StandardTable/style/index.d.ts +6 -1
- package/es/StandardTable/style/index.js +113 -1
- package/es/StandardTable/style/index.less +89 -80
- package/es/components/IconNode/index.d.ts +1 -1
- package/es/components/IconNode/index.js +12 -1
- package/es/components/index.js +1 -1
- package/es/data/func.code.d.ts +16 -0
- package/es/data/general.config.d.ts +191 -0
- package/es/data/general.config.js +32 -1
- package/es/data/index.d.ts +3 -0
- package/es/data/index.js +2 -2
- package/es/index.d.ts +7 -6
- package/es/index.js +32 -26
- package/es/theme/index.d.ts +27 -0
- package/es/theme/index.js +29 -0
- package/es/theme/utils/genStyleHook.d.ts +1 -0
- package/es/theme/utils/genStyleHook.js +32 -0
- package/es/utils/ValueFormat.d.ts +3 -0
- package/es/utils/ValueFormat.js +17 -4
- package/es/utils/dictSelectUtil.d.ts +36 -0
- package/es/utils/dictSelectUtil.js +3 -3
- package/es/utils/filterPermission.d.ts +5 -0
- package/es/utils/filterPermission.js +4 -6
- package/es/utils/getParentNodes.d.ts +79 -0
- package/es/utils/getParentNodes.js +89 -13
- package/es/utils/index.d.ts +5 -0
- package/es/utils/index.js +5 -4
- package/es/utils/transferFile.d.ts +4 -0
- package/es/utils/transferFile.js +56 -0
- package/es/utils/urlUtils.d.ts +14 -0
- package/es/utils/urlUtils.js +77 -0
- package/lib/ButtonGroup/PopConfirmTitle.d.ts +1 -1
- package/lib/ButtonGroup/PopConfirmTitle.js +3 -4
- package/lib/ButtonGroup/index.d.ts +5 -3
- package/lib/ButtonGroup/index.js +261 -194
- package/lib/ButtonGroup/styles/index.d.ts +8 -0
- package/lib/ButtonGroup/styles/index.js +68 -0
- package/lib/ButtonGroup/testStyles/index(antd-style).d.ts +11 -0
- package/lib/ButtonGroup/testStyles/index(antd-style).js +34 -0
- package/lib/ButtonGroup/testStyles/index(cssinjs).js +134 -0
- package/lib/ButtonGroup/testStyles/index.d.ts +11 -0
- package/lib/ButtonGroup/testStyles/index.js +29 -0
- package/lib/CalendarCoordPicker/CalendarMonthPicker.d.ts +5 -0
- package/lib/CalendarCoordPicker/CalendarMonthPicker.js +41 -0
- package/lib/CalendarCoordPicker/index.d.ts +7 -0
- package/lib/CalendarCoordPicker/index.js +323 -0
- package/lib/CalendarCoordPicker/styles/index.d.ts +6 -0
- package/lib/CalendarCoordPicker/styles/index.js +34 -0
- package/lib/CalendarCoordPicker/styles/index.less +37 -0
- package/lib/ConfigContext/index.d.ts +7 -0
- package/lib/ConfigContext/index.js +25 -0
- package/lib/DragContent/DragBar.d.ts +3 -0
- package/lib/DragContent/DragBar.js +1 -3
- package/lib/DragContent/index.d.ts +1 -1
- package/lib/DragContent/index.js +22 -9
- package/lib/DragContent/styles/index.d.ts +6 -0
- package/lib/DragContent/styles/index.js +58 -0
- package/lib/FormComp/ChunkUploader/api.js +11 -11
- package/lib/FormComp/ChunkUploader/index.js +123 -130
- package/lib/FormComp/ChunkUploader/lib.js +19 -19
- package/lib/FormComp/ChunkUploader/upload-queue.class.js +52 -53
- package/lib/FormComp/EditButton/index.d.ts +1 -1
- package/lib/FormComp/EditButton/index.js +22 -22
- package/lib/FormComp/FieldComponent/ReUpload.d.ts +1 -1
- package/lib/FormComp/FieldComponent/ReUpload.js +47 -41
- package/lib/FormComp/FieldComponent/RefactorTreeSelect.js +29 -21
- package/lib/FormComp/FieldComponent/TitleNode.d.ts +2 -1
- package/lib/FormComp/FieldComponent/TitleNode.js +1 -2
- package/lib/FormComp/FieldComponent/UploaderViewer.d.ts +2 -0
- package/lib/FormComp/FieldComponent/UploaderViewer.js +102 -0
- package/lib/FormComp/FieldComponent/index.d.ts +1 -1
- package/lib/FormComp/FieldComponent/index.js +83 -107
- package/lib/FormComp/FieldComponent/setReadonlyValues.js +29 -28
- package/lib/FormComp/FieldComponent/style/TreeSelect.d.ts +6 -0
- package/lib/FormComp/FieldComponent/style/TreeSelect.js +48 -0
- package/lib/FormComp/FieldComponent/style/UploaderStyle.d.ts +6 -0
- package/lib/FormComp/FieldComponent/style/UploaderStyle.js +31 -0
- package/lib/FormComp/FieldComponent/style/index.less +26 -21
- package/lib/FormComp/RenderItemGroup/index.d.ts +4 -0
- package/lib/FormComp/RenderItemGroup/index.js +182 -65
- package/lib/FormComp/RenderItemGroup/style/index.d.ts +6 -0
- package/lib/FormComp/RenderItemGroup/style/index.js +46 -0
- package/lib/FormComp/Uploader/index.js +95 -80
- package/lib/FormComp/Uploader/style/index.less +14 -14
- package/lib/FormComp/Uploader/util.d.ts +2 -2
- package/lib/FormComp/VarTemplate/index.js +38 -48
- package/lib/NavLeafScroll/Main.js +451 -0
- package/lib/NavLeafScroll/index.d.ts +2 -0
- package/lib/NavLeafScroll/index.js +21 -398
- package/lib/NavLeafScroll/style/index.d.ts +6 -0
- package/lib/NavLeafScroll/style/index.js +62 -0
- package/lib/NavLeafScroll/style/index.less +22 -22
- package/lib/RefactorTree/index.d.ts +1 -1
- package/lib/RefactorTree/index.js +21 -21
- package/lib/RefactorTree/style/index.less +22 -22
- package/lib/RefactorTree/util.d.ts +2 -2
- package/lib/RefactorTree/util.js +30 -15
- package/lib/SpecIcon/fonts/demo_index.html +559 -5
- package/lib/SpecIcon/fonts/iconfont.css +101 -3
- package/lib/SpecIcon/fonts/iconfont.js +34 -27
- package/lib/SpecIcon/fonts/iconfont.json +168 -0
- package/lib/SpecIcon/fonts/iconfont.svg +163 -171
- package/lib/SpecIcon/fonts/iconfont.ttf +0 -0
- package/lib/SpecIcon/fonts/iconfont.woff +0 -0
- package/lib/SpecIcon/fonts/iconfont.woff2 +0 -0
- package/lib/SpecIcon/index.d.ts +0 -1
- package/lib/SpecIcon/index.js +34 -14
- package/lib/SpecIcon/styles/index(antd-style).d.ts +6 -0
- package/lib/SpecIcon/styles/index(antd-style).js +19 -0
- package/lib/SpecIcon/styles/index.d.ts +6 -0
- package/lib/SpecIcon/styles/index.js +100 -0
- package/lib/StandardContent/SplitterLayout/Pane.js +3 -4
- package/lib/StandardContent/SplitterLayout/index.js +6 -6
- package/lib/StandardContent/SplitterLayout/index.less +0 -1
- package/lib/StandardContent/SubfieldContent.d.ts +3 -2
- package/lib/StandardContent/SubfieldContent.js +24 -13
- package/lib/StandardContent/WrapperContent.d.ts +2 -2
- package/lib/StandardContent/WrapperContent.js +23 -13
- package/lib/StandardContent/styles/Subfield.d.ts +6 -0
- package/lib/StandardContent/styles/Subfield.js +36 -0
- package/lib/StandardContent/styles/Wrapper.d.ts +6 -0
- package/lib/StandardContent/styles/Wrapper.js +34 -0
- package/lib/StandardContent/styles/index.less +67 -0
- package/lib/StandardDragModal/ChangeStandardModal.d.ts +2 -2
- package/lib/StandardDragModal/ChangeStandardModal.js +85 -72
- package/lib/StandardDragModal/DraggableModal.js +11 -8
- package/lib/StandardDragModal/DraggableModalContext.d.ts +1 -1
- package/lib/StandardDragModal/DraggableModalContext.js +3 -4
- package/lib/StandardDragModal/DraggableModalInner.d.ts +2 -2
- package/lib/StandardDragModal/DraggableModalInner.js +38 -30
- package/lib/StandardDragModal/DraggableModalProvider.js +10 -10
- package/lib/StandardDragModal/Modal.d.ts +1 -1
- package/lib/StandardDragModal/Modal.js +7 -5
- package/lib/StandardDragModal/ResizeHandle.js +6 -6
- package/lib/StandardDragModal/clamp.js +2 -3
- package/lib/StandardDragModal/draggableModalReducer.d.ts +4 -4
- package/lib/StandardDragModal/draggableModalReducer.js +34 -29
- package/lib/StandardDragModal/getWindowSize.js +2 -3
- package/lib/StandardDragModal/useDrag.js +4 -5
- package/lib/StandardDragModal/usePrevious.js +2 -3
- package/lib/StandardDragModal/useResize.js +4 -5
- package/lib/StandardFilter/index.d.ts +8 -17
- package/lib/StandardFilter/index.js +281 -207
- package/lib/StandardFilter/style/FilterStyle.d.ts +6 -0
- package/lib/StandardFilter/style/FilterStyle.js +56 -0
- package/lib/StandardFilter/style/index.less +85 -36
- package/lib/StandardForm/ActionList.d.ts +9 -0
- package/lib/StandardForm/ActionList.js +6 -7
- package/lib/StandardForm/StepForm.d.ts +1 -1
- package/lib/StandardForm/StepForm.js +46 -41
- package/lib/StandardForm/TabForm.d.ts +2 -1
- package/lib/StandardForm/TabForm.js +48 -41
- package/lib/StandardForm/index.d.ts +2 -1
- package/lib/StandardForm/index.js +39 -23
- package/lib/StandardForm/style/index.d.ts +6 -0
- package/lib/StandardForm/style/index.js +55 -0
- package/lib/StandardForm/style/index.less +23 -12
- package/lib/StandardModal/UpdateFormRef.js +3 -4
- package/lib/StandardModal/index.d.ts +4 -3
- package/lib/StandardModal/index.js +152 -133
- package/lib/StandardModal/style/index.d.ts +6 -0
- package/lib/StandardModal/style/index.js +52 -0
- package/lib/StandardModal/style/index.less +29 -29
- package/lib/StandardPanel/index.d.ts +1 -1
- package/lib/StandardPanel/index.js +29 -20
- package/lib/StandardPanel/style/index.d.ts +6 -0
- package/lib/StandardPanel/style/index.js +93 -0
- package/lib/StandardPanel/style/index.less +30 -32
- package/lib/StandardTable/index.d.ts +6 -1
- package/lib/StandardTable/index.js +93 -40
- package/lib/StandardTable/style/index.d.ts +6 -1
- package/lib/StandardTable/style/index.js +117 -1
- package/lib/StandardTable/style/index.less +89 -80
- package/lib/components/IconNode/index.d.ts +1 -1
- package/lib/components/IconNode/index.js +13 -3
- package/lib/data/func.code.d.ts +16 -0
- package/lib/data/func.code.js +2 -3
- package/lib/data/general.config.d.ts +191 -0
- package/lib/data/general.config.js +34 -4
- package/lib/data/index.d.ts +3 -0
- package/lib/index.d.ts +7 -6
- package/lib/index.js +24 -12
- package/lib/theme/index.d.ts +27 -0
- package/lib/theme/index.js +35 -0
- package/lib/theme/utils/genStyleHook.d.ts +1 -0
- package/lib/theme/utils/genStyleHook.js +38 -0
- package/lib/utils/ValueFormat.d.ts +3 -0
- package/lib/utils/ValueFormat.js +20 -6
- package/lib/utils/dictSelectUtil.d.ts +36 -0
- package/lib/utils/dictSelectUtil.js +3 -3
- package/lib/utils/filterPermission.d.ts +5 -0
- package/lib/utils/filterPermission.js +9 -16
- package/lib/utils/getParentNodes.d.ts +79 -0
- package/lib/utils/getParentNodes.js +91 -16
- package/lib/utils/index.d.ts +5 -0
- package/lib/utils/index.js +42 -32
- package/lib/utils/transferFile.d.ts +4 -0
- package/lib/utils/transferFile.js +63 -0
- package/lib/utils/urlUtils.d.ts +14 -0
- package/lib/utils/urlUtils.js +84 -0
- package/package.json +80 -33
- package/Readme.md +0 -49
- package/dist/f26952c118ab6cdcd23dc0028ee98c11.svg +0 -173
- package/dist/fan-standard-comp.umd.js +0 -602
- package/dist/fonts/iconfont.eot +0 -0
- package/dist/fonts/iconfont.ttf +0 -0
- package/dist/fonts/iconfont.woff +0 -0
- package/es/ButtonGroup/ButtonList.d.ts +0 -2
- package/es/ButtonGroup/ButtonList.js +0 -34
- package/es/ButtonGroup/ButtonMenu.d.ts +0 -2
- package/es/ButtonGroup/ButtonMenu.js +0 -35
- package/es/ButtonGroup/style/index.less +0 -36
- package/es/RefactorTree/indexTreeNode.d.ts +0 -39
- package/es/RefactorTree/indexTreeNode.js +0 -204
- package/es/SpecIcon/style/iconfont.less +0 -213
- package/es/SpecIcon/style/index.less +0 -98
- package/es/SplitterLayout/Pane.d.ts +0 -13
- package/es/SplitterLayout/Pane.js +0 -33
- package/es/SplitterLayout/index.js +0 -325
- package/es/SplitterLayout/index.less +0 -58
- package/es/StandardContent/style/index.less +0 -80
- package/es/theme/spec-variable.less +0 -48
- package/lib/ButtonGroup/ButtonList.d.ts +0 -2
- package/lib/ButtonGroup/ButtonList.js +0 -43
- package/lib/ButtonGroup/ButtonMenu.d.ts +0 -2
- package/lib/ButtonGroup/ButtonMenu.js +0 -44
- package/lib/ButtonGroup/style/index.less +0 -36
- package/lib/RefactorTree/indexTreeNode.d.ts +0 -39
- package/lib/RefactorTree/indexTreeNode.js +0 -214
- package/lib/SpecIcon/style/iconfont.less +0 -213
- package/lib/SpecIcon/style/index.less +0 -98
- package/lib/SplitterLayout/Pane.d.ts +0 -13
- package/lib/SplitterLayout/Pane.js +0 -41
- package/lib/SplitterLayout/index.js +0 -332
- package/lib/SplitterLayout/index.less +0 -58
- package/lib/StandardContent/style/index.less +0 -80
- package/lib/theme/spec-variable.less +0 -48
- /package/es/{styles/index.less → ButtonGroup/testStyles/index(cssinjs).d.ts} +0 -0
- /package/lib/{styles/index.less → ButtonGroup/testStyles/index(cssinjs).d.ts} +0 -0
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/es/SpecIcon/index.d.ts
CHANGED
package/es/SpecIcon/index.js
CHANGED
|
@@ -1,8 +1,23 @@
|
|
|
1
|
-
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
var _excluded = ["type", "name", "size", "status", "round", "title", "onClick", "style", "prefix", "noPrefix", "className"];
|
|
3
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
6
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
7
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
8
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
9
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
10
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
11
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
12
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
13
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
14
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
15
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
16
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
2
17
|
import React from 'react';
|
|
3
18
|
import classNames from 'classnames';
|
|
4
|
-
import
|
|
5
|
-
require(
|
|
19
|
+
import useStyle from "./styles";
|
|
20
|
+
require("./fonts/iconfont");
|
|
6
21
|
var SpecIcon = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
7
22
|
var _props$type = props.type,
|
|
8
23
|
type = _props$type === void 0 ? "colour" : _props$type,
|
|
@@ -18,7 +33,12 @@ var SpecIcon = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
18
33
|
_props$noPrefix = props.noPrefix,
|
|
19
34
|
noPrefix = _props$noPrefix === void 0 ? false : _props$noPrefix,
|
|
20
35
|
className = props.className,
|
|
21
|
-
otherProps =
|
|
36
|
+
otherProps = _objectWithoutProperties(props, _excluded);
|
|
37
|
+
var componentName = 'spec-icon';
|
|
38
|
+
var _useStyle = useStyle(componentName),
|
|
39
|
+
_useStyle2 = _slicedToArray(_useStyle, 2),
|
|
40
|
+
wrapSSR = _useStyle2[0],
|
|
41
|
+
hashId = _useStyle2[1];
|
|
22
42
|
var extraClassName = '';
|
|
23
43
|
if (status) extraClassName += " is-".concat(status);
|
|
24
44
|
var fontStyle = {};
|
|
@@ -29,19 +49,19 @@ var SpecIcon = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
29
49
|
}
|
|
30
50
|
var renderIconFont = function renderIconFont() {
|
|
31
51
|
if (round) extraClassName += " is-round";
|
|
32
|
-
return /*#__PURE__*/React.createElement("i",
|
|
33
|
-
className: classNames("specicon", "specicon-font", noPrefix ? '' : "".concat(prefix, "font"), noPrefix ? "".concat(name) : "".concat(prefix ? prefix + '-' : '').concat(name), extraClassName, name === 'loading' ? 'anticon-spin' : '', className),
|
|
52
|
+
return /*#__PURE__*/React.createElement("i", _extends({
|
|
53
|
+
className: classNames(componentName, hashId, "specicon", "specicon-font", noPrefix ? '' : "".concat(prefix, "font"), noPrefix ? "".concat(name) : "".concat(prefix ? prefix + '-' : '').concat(name), extraClassName, name === 'loading' ? 'anticon-spin' : '', className),
|
|
34
54
|
title: title,
|
|
35
55
|
onClick: onClick,
|
|
36
|
-
style:
|
|
56
|
+
style: _objectSpread(_objectSpread({}, fontStyle), style),
|
|
37
57
|
ref: ref
|
|
38
58
|
}, otherProps));
|
|
39
59
|
};
|
|
40
60
|
var renderIconSvg = function renderIconSvg() {
|
|
41
61
|
var baseElement = function baseElement() {
|
|
42
|
-
return /*#__PURE__*/React.createElement("i",
|
|
43
|
-
className: classNames("specicon", 'anticon', noPrefix ? "".concat(name, "-svg") : "".concat(prefix ? prefix + '-' : '').concat(name, "-svg"), !round && extraClassName, className),
|
|
44
|
-
style:
|
|
62
|
+
return /*#__PURE__*/React.createElement("i", _extends({
|
|
63
|
+
className: classNames(componentName, hashId, "specicon", 'anticon', noPrefix ? "".concat(name, "-svg") : "".concat(prefix ? prefix + '-' : '').concat(name, "-svg"), !round && extraClassName, className),
|
|
64
|
+
style: _objectSpread(_objectSpread({}, fontStyle), style),
|
|
45
65
|
title: title,
|
|
46
66
|
onClick: onClick,
|
|
47
67
|
ref: ref
|
|
@@ -59,10 +79,11 @@ var SpecIcon = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
59
79
|
})));
|
|
60
80
|
};
|
|
61
81
|
return round ? /*#__PURE__*/React.createElement("span", {
|
|
62
|
-
className: classNames('
|
|
82
|
+
className: classNames('spec-icon-round', hashId, status && "is-".concat(status))
|
|
63
83
|
}, baseElement()) : baseElement();
|
|
64
84
|
};
|
|
85
|
+
|
|
65
86
|
// 去除引入 font图标
|
|
66
|
-
return type === 'colour' ? renderIconSvg() : renderIconFont();
|
|
87
|
+
return wrapSSR( /*#__PURE__*/React.createElement(React.Fragment, null, type === 'colour' ? renderIconSvg() : renderIconFont()));
|
|
67
88
|
});
|
|
68
89
|
export default SpecIcon;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export declare const useStyles: (props?: unknown) => import("antd-style").ReturnStyles<{
|
|
2
|
+
[x: string]: import("antd-style").SerializedStyles;
|
|
3
|
+
"spec-icon-CSS": import("antd-style").SerializedStyles;
|
|
4
|
+
SpecButtonGroupCSS: import("antd-style").SerializedStyles;
|
|
5
|
+
SpecButtonGroupTextCSS: import("antd-style").SerializedStyles;
|
|
6
|
+
}>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
3
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
4
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
5
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
6
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
7
|
+
import { createStyles } from 'antd-style';
|
|
8
|
+
export var useStyles = createStyles(function (_ref) {
|
|
9
|
+
var token = _ref.token,
|
|
10
|
+
css = _ref.css,
|
|
11
|
+
prefixCls = _ref.prefixCls;
|
|
12
|
+
return _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, 'specicon' + prefixCls, css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n color: ", ";\n display: inline-block;\n color: inherit;\n font-size: 16px;\n font-style: normal;\n //line-height: 0;\n text-align: center;\n text-transform: none;\n vertical-align: -0.125em;\n text-rendering: optimizeLegibility;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n "])), token.colorText)), 'spec-icon-CSS', css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n color: ", ";\n display: inline-block;\n font-size: 16px;\n font-style: normal;\n //line-height: 0;\n text-align: center;\n text-transform: none;\n vertical-align: -0.125em;\n text-rendering: optimizeLegibility;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n "])), token.colorText)), "SpecButtonGroupCSS", css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n display: inline-block;\n vertical-align: middle;\n .ant-btn + .ant-btn {\n margin-left: ", "px;\n }\n "])), token.paddingSM)), "SpecButtonGroupTextCSS", css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n position: relative;\n display: inline-block;\n cursor: pointer;\n color: ", ";\n\n &[disabled] { \n cursor: not-allowed;\n color: ", ";\n }\n\n & + .spec-button-group-text {\n position: relative;\n margin-left: ", "px;\n\n &:before {\n position: absolute;\n content: '';\n top: 50%;\n left: calc(-", "px / 2);\n transform: translate(0, -50%);\n display: inline-block;\n height: .9em;\n vertical-align: middle;\n border-left: 1px solid ", ";\n\n }\n }\n "])), token.colorPrimary, token.colorTextDisabled, token.paddingSM, token.paddingSM, token.colorBorder));
|
|
13
|
+
});
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
|
+
import { createStyleHook } from "../../theme/utils/genStyleHook";
|
|
8
|
+
import _ from "lodash";
|
|
9
|
+
// 图形外部圆角样式
|
|
10
|
+
var mixinSvgRound = function mixinSvgRound(status, statusColor) {
|
|
11
|
+
return _defineProperty({}, "&.is-".concat(status), {
|
|
12
|
+
borderColor: statusColor,
|
|
13
|
+
'> i': {
|
|
14
|
+
background: statusColor
|
|
15
|
+
}
|
|
16
|
+
});
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
// 图形填充色
|
|
20
|
+
var mixinSvgFill = function mixinSvgFill(status, statusColor) {
|
|
21
|
+
return _defineProperty({}, "&.is-".concat(status), {
|
|
22
|
+
color: statusColor,
|
|
23
|
+
'> svg': {
|
|
24
|
+
// background: statusColor
|
|
25
|
+
}
|
|
26
|
+
});
|
|
27
|
+
};
|
|
28
|
+
//
|
|
29
|
+
// const genNormalStyle = () => {
|
|
30
|
+
// return {}
|
|
31
|
+
// }
|
|
32
|
+
//
|
|
33
|
+
// const genErrorStyle = () => {
|
|
34
|
+
// return {}
|
|
35
|
+
//
|
|
36
|
+
// }
|
|
37
|
+
// const genOfflineStyle = () => {
|
|
38
|
+
// return {}
|
|
39
|
+
//
|
|
40
|
+
// }
|
|
41
|
+
// const genStatusStyle = (prefixCls: string, token: SpecIconTokenType) => {
|
|
42
|
+
// return {
|
|
43
|
+
// [`.is-normal`]: genNormalStyle(token),
|
|
44
|
+
// [`.is-error`]: genErrorStyle(token),
|
|
45
|
+
// [`.is-offline`]: genOfflineStyle(token),
|
|
46
|
+
// };
|
|
47
|
+
// };
|
|
48
|
+
|
|
49
|
+
var SpecIconStyleFunc = function SpecIconStyleFunc(prefix) {
|
|
50
|
+
var prepareComponentToken = function prepareComponentToken(token) {
|
|
51
|
+
return {
|
|
52
|
+
fontWeight: 400
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
return createStyleHook(prefix, function (token) {
|
|
56
|
+
var SpecIconToken = _.merge(token, {
|
|
57
|
+
// testButtonSmallSize: token.paddingXS,
|
|
58
|
+
// testButtonMiddleSize: token.padding,
|
|
59
|
+
// testButtonLargeSize: token.paddingLG,
|
|
60
|
+
});
|
|
61
|
+
var prefixCls = ".".concat(prefix);
|
|
62
|
+
return [_defineProperty({}, prefixCls, _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({
|
|
63
|
+
// color: token.colorText,
|
|
64
|
+
display: 'inline-block',
|
|
65
|
+
fontSize: '16px',
|
|
66
|
+
fontStyle: 'normal',
|
|
67
|
+
//line-height: 0,
|
|
68
|
+
textAlign: 'center',
|
|
69
|
+
textTransform: 'none',
|
|
70
|
+
verticalAlign: '-0.125em',
|
|
71
|
+
textRendering: 'optimizeLegibility',
|
|
72
|
+
'-webkit-font-smoothing': 'antialiased',
|
|
73
|
+
'-moz-osx-font-smoothing': 'grayscale'
|
|
74
|
+
}, mixinSvgFill('normal', token.colorInfo)), mixinSvgFill('success', token.colorSuccess)), mixinSvgFill('error', token.colorError)), mixinSvgFill('warning', token.colorWarning)), mixinSvgFill('offline', '#6F8FC2')), mixinSvgFill('disabled', token.colorTextDisabled))), _defineProperty({}, '.spec-icon-round', _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_defineProperty({
|
|
75
|
+
display: 'inline-block',
|
|
76
|
+
padding: '2px',
|
|
77
|
+
verticalAlign: 'middle',
|
|
78
|
+
border: '1px solid transparent',
|
|
79
|
+
borderRadius: '50%',
|
|
80
|
+
lineHeight: 0
|
|
81
|
+
}, '>' + prefixCls, {
|
|
82
|
+
borderRadius: ' 50%',
|
|
83
|
+
//box-shadow: 0px 0px 3px 1px rgba(6, 36, 95, 0.46);
|
|
84
|
+
'svg': {
|
|
85
|
+
padding: '.2em',
|
|
86
|
+
fill: '#fff'
|
|
87
|
+
}
|
|
88
|
+
}), mixinSvgRound('normal', token.colorInfo)), mixinSvgRound('success', token.colorSuccess)), mixinSvgRound('error', token.colorError)), mixinSvgRound('warning', token.colorWarning)), mixinSvgRound('offline', '#6F8FC2')), mixinSvgRound('disabled', token.colorTextDisabled))) // ...genStatusStyle(prefixCls, SpecIconToken)
|
|
89
|
+
];
|
|
90
|
+
}, prepareComponentToken // 当前组件扩展的变量
|
|
91
|
+
);
|
|
92
|
+
};
|
|
93
|
+
export default SpecIconStyleFunc;
|
|
@@ -2,11 +2,11 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
2
2
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
-
function _toPropertyKey(
|
|
6
|
-
function _toPrimitive(
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
7
|
import React from 'react';
|
|
8
8
|
import PropTypes from 'prop-types';
|
|
9
|
-
import
|
|
9
|
+
import "./index.less";
|
|
10
10
|
function Pane(props) {
|
|
11
11
|
var size = props.size || 0;
|
|
12
12
|
var unit = props.percentage ? '%' : 'px';
|
|
@@ -2,8 +2,8 @@ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" ==
|
|
|
2
2
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
3
3
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
4
4
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
5
|
-
function _toPropertyKey(
|
|
6
|
-
function _toPrimitive(
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
7
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
8
8
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
9
9
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -13,8 +13,8 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
13
13
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
14
14
|
import React from 'react';
|
|
15
15
|
import PropTypes from 'prop-types';
|
|
16
|
-
import Pane from
|
|
17
|
-
import
|
|
16
|
+
import Pane from "./Pane";
|
|
17
|
+
import "./index.less";
|
|
18
18
|
function clearSelection() {
|
|
19
19
|
if (document.body.createTextRange) {
|
|
20
20
|
// https://github.com/zesik/react-splitter-layout/issues/16
|
|
@@ -123,7 +123,9 @@ var SplitterLayout = /*#__PURE__*/function (_React$Component) {
|
|
|
123
123
|
document.removeEventListener('mousemove', this.handleMouseMove);
|
|
124
124
|
document.removeEventListener('touchend', this.handleMouseUp);
|
|
125
125
|
document.removeEventListener('touchmove', this.handleTouchMove);
|
|
126
|
-
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
//获取第二块内容宽度or高度
|
|
127
129
|
}, {
|
|
128
130
|
key: "getSecondaryPaneSize",
|
|
129
131
|
value: function getSecondaryPaneSize(containerRect, splitterRect, clientPosition, offsetMouse) {
|
|
@@ -141,7 +143,6 @@ var SplitterLayout = /*#__PURE__*/function (_React$Component) {
|
|
|
141
143
|
splitterSize = splitterRect.width; //划分条宽度
|
|
142
144
|
offset = clientPosition.left - containerRect.left; //移动位置减去原始位置
|
|
143
145
|
}
|
|
144
|
-
|
|
145
146
|
if (offsetMouse) {
|
|
146
147
|
//移动
|
|
147
148
|
offset -= splitterSize / 2;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import './
|
|
2
|
+
import './styles/index.less';
|
|
3
3
|
interface SubfieldContentProps {
|
|
4
4
|
leftSiderWidth?: number;
|
|
5
5
|
className?: string;
|
|
@@ -12,6 +12,7 @@ interface SubfieldContentProps {
|
|
|
12
12
|
leftSiderDragDirection?: string[];
|
|
13
13
|
leftSiderMoveMaxWidth?: number;
|
|
14
14
|
leftSiderMoveMaxHeight?: number;
|
|
15
|
+
[k: string]: any;
|
|
15
16
|
}
|
|
16
|
-
declare const SubfieldContent: (props: SubfieldContentProps) =>
|
|
17
|
+
declare const SubfieldContent: (props: SubfieldContentProps) => any;
|
|
17
18
|
export default SubfieldContent;
|
|
@@ -1,9 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
2
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
3
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
4
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
5
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
6
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
3
7
|
import React from 'react';
|
|
4
8
|
import classNames from 'classnames';
|
|
5
|
-
import
|
|
6
|
-
import
|
|
9
|
+
import { Spin } from 'antd';
|
|
10
|
+
import DragContent from "../DragContent";
|
|
11
|
+
import useStyle from "./styles/Subfield";
|
|
12
|
+
import "./styles/index.less";
|
|
7
13
|
var SubfieldContent = function SubfieldContent(props) {
|
|
8
14
|
var _props$leftSiderWidth = props.leftSiderWidth,
|
|
9
15
|
leftSiderWidth = _props$leftSiderWidth === void 0 ? 180 : _props$leftSiderWidth,
|
|
@@ -18,13 +24,19 @@ var SubfieldContent = function SubfieldContent(props) {
|
|
|
18
24
|
leftSiderDragDirection = props.leftSiderDragDirection,
|
|
19
25
|
leftSiderMoveMaxWidth = props.leftSiderMoveMaxWidth,
|
|
20
26
|
leftSiderMoveMaxHeight = props.leftSiderMoveMaxHeight;
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
27
|
+
var componentName = 'spec-grid-content';
|
|
28
|
+
var _useStyle = useStyle(componentName),
|
|
29
|
+
_useStyle2 = _slicedToArray(_useStyle, 2),
|
|
30
|
+
wrapSSR = _useStyle2[0],
|
|
31
|
+
hashId = _useStyle2[1];
|
|
32
|
+
return wrapSSR( /*#__PURE__*/React.createElement(Spin, {
|
|
25
33
|
spinning: loading,
|
|
26
|
-
tip: loadingTip
|
|
27
|
-
|
|
34
|
+
tip: loadingTip,
|
|
35
|
+
wrapperClassName: 'spec-grid-content-spinning'
|
|
36
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
37
|
+
className: classNames(componentName, className, hashId),
|
|
38
|
+
style: style
|
|
39
|
+
}, /*#__PURE__*/React.createElement(DragContent, {
|
|
28
40
|
direction: leftSiderDragDirection,
|
|
29
41
|
className: classNames('spec-grid-left', leftSiderClassName),
|
|
30
42
|
style: {
|
|
@@ -33,7 +45,7 @@ var SubfieldContent = function SubfieldContent(props) {
|
|
|
33
45
|
moveMaxWidth: leftSiderMoveMaxWidth,
|
|
34
46
|
moveMaxHeight: leftSiderMoveMaxHeight
|
|
35
47
|
}, leftSiderNode), /*#__PURE__*/React.createElement("div", {
|
|
36
|
-
className:
|
|
37
|
-
}, children));
|
|
48
|
+
className: "spec-grid-right"
|
|
49
|
+
}, children))));
|
|
38
50
|
};
|
|
39
51
|
export default SubfieldContent;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import './style/index.less';
|
|
2
1
|
import React from 'react';
|
|
2
|
+
import './styles/index.less';
|
|
3
3
|
interface WrapperContentProps {
|
|
4
4
|
className?: string;
|
|
5
5
|
loading?: boolean;
|
|
@@ -9,5 +9,5 @@ interface WrapperContentProps {
|
|
|
9
9
|
noMargin?: boolean;
|
|
10
10
|
light?: boolean;
|
|
11
11
|
}
|
|
12
|
-
declare const WrapperContent: (props: WrapperContentProps) =>
|
|
12
|
+
declare const WrapperContent: (props: WrapperContentProps) => any;
|
|
13
13
|
export default WrapperContent;
|
|
@@ -1,8 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
2
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
3
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
4
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
5
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
6
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
4
7
|
import React from 'react';
|
|
5
8
|
import classNames from 'classnames';
|
|
9
|
+
import { Spin } from 'antd';
|
|
10
|
+
import "./styles/index.less";
|
|
11
|
+
import useStyle from "./styles/Wrapper";
|
|
6
12
|
var WrapperContent = function WrapperContent(props) {
|
|
7
13
|
var children = props.children,
|
|
8
14
|
light = props.light,
|
|
@@ -13,15 +19,20 @@ var WrapperContent = function WrapperContent(props) {
|
|
|
13
19
|
_props$loading = props.loading,
|
|
14
20
|
loading = _props$loading === void 0 ? false : _props$loading,
|
|
15
21
|
loadingTip = props.loadingTip;
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
22
|
+
var componentName = 'spec-wrapper-content';
|
|
23
|
+
var _useStyle = useStyle(componentName),
|
|
24
|
+
_useStyle2 = _slicedToArray(_useStyle, 2),
|
|
25
|
+
wrapSSR = _useStyle2[0],
|
|
26
|
+
hashId = _useStyle2[1];
|
|
27
|
+
return wrapSSR( /*#__PURE__*/React.createElement(Spin, {
|
|
21
28
|
spinning: loading,
|
|
22
|
-
tip: loadingTip
|
|
23
|
-
|
|
29
|
+
tip: loadingTip,
|
|
30
|
+
wrapperClassName: 'spec-wrapper-content-spinning'
|
|
31
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
32
|
+
className: classNames(componentName, className, noMargin ? 'has-margin' : '', hashId),
|
|
33
|
+
style: style
|
|
34
|
+
}, light ? /*#__PURE__*/React.createElement("div", {
|
|
24
35
|
className: "light-block"
|
|
25
|
-
}, " ", children) : children);
|
|
36
|
+
}, " ", children) : children)));
|
|
26
37
|
};
|
|
27
38
|
export default WrapperContent;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
|
+
import { createStyleHook } from "../../theme/utils/genStyleHook";
|
|
8
|
+
import { scrollBar } from "../../theme/index";
|
|
9
|
+
var SubfieldContentStyleFunc = function SubfieldContentStyleFunc(prefix) {
|
|
10
|
+
var prepareComponentToken = function prepareComponentToken(token) {
|
|
11
|
+
return {
|
|
12
|
+
// fontWeight: 400,
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
return createStyleHook(prefix, function (token) {
|
|
16
|
+
var prefixCls = ".".concat(prefix);
|
|
17
|
+
// console.log(' new TinyColor(token.colorPrimary).setAlpha(0.1)' ,new TinyColor(token.colorPrimary).setAlpha(0.1).toRgbString(), )
|
|
18
|
+
return [_defineProperty({}, prefixCls, {
|
|
19
|
+
'& .spec-grid-left': _objectSpread({
|
|
20
|
+
padding: token.paddingMD,
|
|
21
|
+
background: token.colorBgBase
|
|
22
|
+
}, scrollBar(token)),
|
|
23
|
+
'& .spec-grid-right': _objectSpread({
|
|
24
|
+
padding: token.paddingMD
|
|
25
|
+
}, scrollBar(token))
|
|
26
|
+
})];
|
|
27
|
+
}, prepareComponentToken // 当前组件扩展的变量
|
|
28
|
+
);
|
|
29
|
+
};
|
|
30
|
+
export default SubfieldContentStyleFunc;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
3
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
4
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
5
|
+
import { createStyleHook } from "../../theme/utils/genStyleHook";
|
|
6
|
+
var WrapperContentStyleFunc = function WrapperContentStyleFunc(prefix) {
|
|
7
|
+
var prepareComponentToken = function prepareComponentToken(token) {
|
|
8
|
+
return {
|
|
9
|
+
// fontWeight: 400,
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
return createStyleHook(prefix, function (token) {
|
|
13
|
+
var prefixCls = ".".concat(prefix);
|
|
14
|
+
return [_defineProperty({}, prefixCls, {
|
|
15
|
+
position: 'relative',
|
|
16
|
+
padding: token.paddingMD,
|
|
17
|
+
background: token.colorBgLayout,
|
|
18
|
+
height: '100%',
|
|
19
|
+
overflow: 'auto',
|
|
20
|
+
'& .light-block': {
|
|
21
|
+
padding: token.paddingMD,
|
|
22
|
+
background: token.colorBgBase
|
|
23
|
+
}
|
|
24
|
+
})];
|
|
25
|
+
}, prepareComponentToken // 当前组件扩展的变量
|
|
26
|
+
);
|
|
27
|
+
};
|
|
28
|
+
export default WrapperContentStyleFunc;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
//
|
|
2
|
+
//
|
|
3
|
+
//.scroll-bar(){
|
|
4
|
+
// &::-webkit-scrollbar-track-piece {
|
|
5
|
+
// background: fade(@primary-color, 10%);
|
|
6
|
+
// }
|
|
7
|
+
// &::-webkit-scrollbar {
|
|
8
|
+
// width: 6px;
|
|
9
|
+
// height: 6px;
|
|
10
|
+
// }
|
|
11
|
+
// &::-webkit-scrollbar-thumb {
|
|
12
|
+
// background: fade(@primary-color, 50%);
|
|
13
|
+
// border-radius: 20px;
|
|
14
|
+
// }
|
|
15
|
+
//}
|
|
16
|
+
.spec-wrapper-content {
|
|
17
|
+
position: relative;
|
|
18
|
+
//padding: @padding-lg;
|
|
19
|
+
//background: @background-color-base;
|
|
20
|
+
height: 100%;
|
|
21
|
+
overflow: auto;
|
|
22
|
+
box-sizing: border-box;
|
|
23
|
+
|
|
24
|
+
& * {
|
|
25
|
+
box-sizing: border-box;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
& .light-block {
|
|
29
|
+
//padding: @padding-lg;
|
|
30
|
+
//background: @layout-body-background;
|
|
31
|
+
height: 100%;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.spec-grid-content {
|
|
36
|
+
position: relative;
|
|
37
|
+
display: flex;
|
|
38
|
+
//height: calc(100vh - @layout-header-height);
|
|
39
|
+
height: 100%;
|
|
40
|
+
background: transparent; // @background-color-base;
|
|
41
|
+
box-sizing: border-box;
|
|
42
|
+
|
|
43
|
+
& * {
|
|
44
|
+
box-sizing: border-box;
|
|
45
|
+
}
|
|
46
|
+
.spec-grid-left {
|
|
47
|
+
//height: calc(100vh - @layout-header-height);
|
|
48
|
+
height: 100%;
|
|
49
|
+
//padding: @padding-md @padding-sm;
|
|
50
|
+
//background: @layout-body-background;
|
|
51
|
+
overflow-y: auto;
|
|
52
|
+
//.scroll-bar();
|
|
53
|
+
.ant-tree-list,
|
|
54
|
+
.ant-tree {
|
|
55
|
+
max-height: 100%;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.spec-grid-right {
|
|
60
|
+
flex: 1;
|
|
61
|
+
height: 100%;
|
|
62
|
+
//height: calc(100vh - @layout-header-height);
|
|
63
|
+
//padding: @padding-lg;
|
|
64
|
+
overflow-y: auto;
|
|
65
|
+
//margin-left: 200px
|
|
66
|
+
}
|
|
67
|
+
}
|
|
@@ -25,7 +25,7 @@ export interface StandardModalProps extends ModalProps {
|
|
|
25
25
|
stepsConfig?: any;
|
|
26
26
|
className?: string;
|
|
27
27
|
style?: React.CSSProperties;
|
|
28
|
-
visible
|
|
28
|
+
visible: boolean;
|
|
29
29
|
bodyStyle?: React.CSSProperties;
|
|
30
30
|
hideRequiredMark?: boolean;
|
|
31
31
|
hideFooter?: Boolean;
|
|
@@ -40,5 +40,5 @@ export interface StandardModalProps extends ModalProps {
|
|
|
40
40
|
dragAble?: boolean;
|
|
41
41
|
[k: string]: any;
|
|
42
42
|
}
|
|
43
|
-
declare const StandardModal: (props: StandardModalProps) => JSX.Element;
|
|
43
|
+
declare const StandardModal: (props: StandardModalProps) => React.JSX.Element;
|
|
44
44
|
export default StandardModal;
|