@gingkoo/pandora-explorer 0.0.1-alpha.24 → 0.0.1-alpha.25

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/lib/es/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @gingkoo/pandora-explorer v0.0.1-alpha.24
2
+ * @gingkoo/pandora-explorer v0.0.1-alpha.25
3
3
  */
4
4
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
5
5
  import cx$1 from 'classnames';
@@ -877,6 +877,17 @@ function SuffixIcon({
877
877
  })
878
878
  });
879
879
  }
880
+ function UploadSvg() {
881
+ return jsx("svg", {
882
+ className: 'icon',
883
+ viewBox: '0 0 1024 1024',
884
+ version: '1.1',
885
+ xmlns: 'http://www.w3.org/2000/svg',
886
+ children: jsx("path", {
887
+ d: 'M768 640v128H256V640h-85.333v128c0 46.933 38.4 85.333 85.333 85.333h512c46.933 0 85.333-38.4 85.333-85.333V640H768zM298.667 384l60.16 60.16 110.506-110.08v348.587h85.334V334.08l110.506 110.08 60.16-60.16L512 170.667 298.667 384z'
888
+ })
889
+ });
890
+ }
880
891
 
881
892
  var css_248z$b = ".app-wrapper {\n height: 100%;\n}\n.frame-explorer-main {\n width: 100%;\n height: 100%;\n overflow: hidden;\n}\n.frame-left {\n position: relative;\n border-right: 1px solid rgba(100, 100, 100, 0.1);\n height: 100%;\n}\n.frame-left::after {\n position: absolute;\n content: ' ';\n top: 50%;\n right: 1px;\n width: 1px;\n height: 18px;\n margin-left: -1px;\n margin-top: -9px;\n border: 1px solid #ddd;\n border-top: none;\n border-bottom: none;\n backdrop-filter: none;\n border-radius: 0;\n background: transparent;\n box-sizing: content-box;\n -webkit-backdrop-filter: blur(10px);\n z-index: 2;\n}\n.frame-right {\n border-right: 1px solid #f5f5f5;\n height: 100%;\n}\n.frame-right .frame-header {\n width: 100%;\n height: 85px;\n min-width: 400px;\n position: relative;\n background: #fff;\n}\n.frame-right .frame-main {\n position: relative;\n height: 100%;\n}\n.box {\n display: flex;\n}\n.box .item {\n position: relative;\n width: 100px;\n height: 100px;\n background: red;\n margin-left: 20px;\n transition: 0.3s;\n top: 0;\n left: 0;\n}\n.explorer-label-icon {\n display: inline-block;\n position: relative;\n box-sizing: border-box !important;\n}\n.explorer-label-icon > div {\n position: relative;\n width: 100%;\n height: 100%;\n border-radius: 50% !important;\n}\n.explorer-label-icon > div::after {\n width: 40%;\n height: 40%;\n border-radius: 50%;\n content: ' ';\n background: linear-gradient(45deg, #ffffff7d, #ffffff00);\n margin-top: 4px;\n position: absolute;\n right: 15%;\n top: 15%;\n}\n";
882
893
  styleInject(css_248z$b);
@@ -1910,7 +1921,7 @@ function Slider(props) {
1910
1921
  var css_248z$7 = ".explorer-menu {\n height: 100%;\n}\n";
1911
1922
  styleInject(css_248z$7);
1912
1923
 
1913
- var css_248z$6 = ".explorer-tree {\n width: 100%;\n height: 100%;\n}\n.explorer-tree-switch {\n height: 31px;\n width: 24px;\n display: flex;\n justify-content: center;\n align-items: center;\n vertical-align: top !important;\n color: #aaa;\n border-radius: 2px;\n}\n.explorer-tree-switch:hover {\n color: #1890ff;\n background-color: rgba(0, 0, 0, 0.03);\n}\n.explorer-tree-switch.open {\n color: #1890ff;\n}\n.explorer-tree-switch.open > svg {\n transform: rotate(90deg);\n}\n.explorer-tree-switch.loading {\n background: transparent;\n animation: rotate 1s linear infinite;\n}\n.explorer-tree-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n margin: 6px 0px;\n background-repeat: no-repeat;\n background-position: center;\n background-size: cover;\n border-radius: 5px;\n font-style: normal;\n pointer-events: none;\n vertical-align: top;\n}\n.explorer-tree-node {\n display: flex;\n height: 100%;\n align-items: center;\n}\n.explorer-tree-node .node-title {\n flex: 1;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n}\n.explorer-tree-node .node-menu {\n display: none;\n flex-shrink: 0;\n width: 30px;\n justify-content: center;\n align-items: center;\n}\n.explorer-tree-node .node-menu .node-menu-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n width: 14px;\n height: 14px;\n border: 1px solid #ccc;\n border-radius: 2px;\n cursor: pointer;\n z-index: 50;\n background: #fff;\n color: #ccc;\n font-size: 7px;\n transition: 0.3s;\n}\n.explorer-tree-node .node-menu .node-menu-icon > svg {\n transform: rotate(90deg);\n}\n.explorer-tree-node .node-menu .node-menu-icon:hover {\n border: 1px solid #1890ff;\n color: #1890ff;\n}\n.explorer-tree-node .node-input {\n display: inline-block;\n width: 100%;\n height: 24px;\n outline: 0;\n border: 1px solid #eee;\n border-radius: 3px;\n transition: 0.3s;\n padding: 0 5px;\n}\n.explorer-tree-node .node-input:hover {\n border: 1px solid #1890ff;\n}\n.explorer-tree-node .node-input:focus {\n border: 1px solid #1890ff;\n}\n.explorer-tree-node:hover .node-menu {\n display: flex;\n}\n.explorer-tree-row {\n display: flex;\n width: 100%;\n height: 100%;\n align-items: center;\n}\n.explorer-tree-row .row-item {\n display: flex;\n padding: 0 10px;\n flex: 1 0 0;\n user-select: none;\n}\n.explorer-tree-row .row-item .row-item-content {\n flex: 1 0 0;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n}\n.explorer-tree-row .row-item .row-item-content > input {\n height: 24px;\n outline: none;\n width: 100%;\n outline: 0;\n border: 0;\n}\n.explorer-tree-row .row-item-check {\n display: flex;\n width: 19px;\n align-items: center;\n box-sizing: border-box;\n pointer-events: all;\n}\n.explorer-tree-row .row-item-check .btn-check {\n display: inline-block;\n height: 19px;\n width: 19px;\n flex-shrink: 0;\n z-index: 11;\n font-size: 20px;\n text-align: center;\n border-radius: 50%;\n background: rgba(0, 0, 0, 0.05);\n color: #fff;\n line-height: 0;\n opacity: 0;\n cursor: pointer;\n transition: opacity 0.3s;\n margin: 2px;\n}\n.explorer-tree-row .row-item-check .btn-check > svg {\n position: relative;\n width: 23px;\n height: 23px;\n left: -2px;\n top: -2px;\n}\n.explorer-tree-row .row-item-check.active .btn-check {\n opacity: 1;\n background: #3b8cff;\n}\n.explorer-tree.table .tree-scroll-x {\n width: 100%;\n overflow: hidden;\n overflow-x: auto;\n}\n.explorer-tree.table .tree-scroll-x::-webkit-scrollbar {\n display: none;\n}\n.explorer-tree.table .tree-scroll {\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n z-index: 10;\n overflow: auto;\n}\n.explorer-tree.table .rc-tree {\n height: calc(100% - 26px);\n}\n.explorer-tree.table .rc-tree-list-holder-inner {\n overflow: auto;\n}\n.explorer-tree.table .rc-tree-list {\n height: 100%;\n}\n.explorer-tree.table .rc-tree-checkbox {\n display: none !important;\n}\n.explorer-tree.table .rc-tree-treenode {\n border-radius: 2px;\n width: fit-content;\n opacity: 0.8;\n z-index: 100;\n pointer-events: all;\n}\n.explorer-tree.table .rc-tree-treenode:nth-child(odd) {\n background: #4664780d;\n}\n.explorer-tree.table .rc-tree-list-holder-inner {\n padding: 8px 0 0 8px;\n}\n.explorer-tree.table .rc-tree-treenode-leaf-last:last-child {\n height: 200px;\n width: 1px;\n}\n.explorer-tree.table .rc-tree-treenode-checkbox-checked {\n background: #cce8ff !important;\n border: 1px solid #99d1ff;\n}\n.explorer-tree .rc-tree-iconEle {\n height: 31px !important;\n vertical-align: top !important;\n width: auto !important;\n}\n.explorer-tree .rc-tree-treenode {\n position: relative;\n height: 31px;\n line-height: 31px;\n border: 1px solid transparent;\n display: flex;\n}\n.explorer-tree .rc-tree-treenode > .rc-tree-node-content-wrapper {\n height: 31px !important;\n display: flex !important;\n flex: 1;\n margin-left: calc(24px - 20px);\n}\n.explorer-tree .rc-tree-treenode > .rc-tree-node-selected {\n background-color: transparent;\n box-shadow: none;\n opacity: 1;\n}\n.explorer-tree .rc-tree-treenode.rc-tree-treenode-selected {\n background-color: #cce8ff !important;\n border: 1px solid #1890ff;\n opacity: 0.8;\n}\n.explorer-tree .rc-tree-treenode.rc-tree-treenode-selected .node-menu {\n display: flex;\n}\n.explorer-tree .rc-tree-treenode:hover {\n background: #e5f3ff !important;\n box-shadow: 0 0 0 1px transparent;\n}\n.explorer-tree .rc-tree-switcher {\n flex-shrink: 0;\n width: 20px !important;\n height: 31px !important;\n vertical-align: top !important;\n background-image: none !important;\n}\n.explorer-tree .rc-tree-title {\n display: inline-block;\n height: 31px;\n width: 100%;\n}\n.explorer-tree.showLine .rc-tree-indent {\n height: 31px;\n}\n.explorer-tree.showLine .rc-tree-indent > .rc-tree-indent-unit {\n position: relative;\n}\n.explorer-tree.showLine .rc-tree-indent > .rc-tree-indent-unit::after {\n display: inline-block;\n position: absolute;\n content: '';\n width: 1px;\n left: 10px;\n height: 31px;\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.showLine .rc-tree-indent-unit {\n width: 20px;\n height: 31px;\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:last-child {\n position: relative;\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:last-child::before {\n content: '';\n display: inline-block;\n position: absolute;\n width: 8px;\n top: calc(31px / 2);\n left: 10px;\n height: 1px;\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:last-child::after {\n display: inline-block;\n position: absolute;\n content: '';\n width: 1px;\n left: 10px;\n top: 0;\n height: calc(31px / 2);\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:first-child {\n position: relative;\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:first-child::before {\n display: none;\n content: '';\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:first-child::after {\n display: inline-block;\n position: absolute;\n content: '';\n width: 1px;\n left: 10px;\n height: 31px;\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.explorer-checks .rc-tree-treenode:hover .row-item-check .btn-check {\n opacity: 1;\n}\n.explorer-tree .rc-tree-list-scrollbar-thumb {\n background: #bbb !important;\n}\n.explorer-tree .rc-tree-list-scrollbar {\n width: 5px !important;\n}\n.explorer-tree .node-motion {\n transition: all 0.3s;\n overflow-y: hidden;\n}\n.explorer-tree .rc-tree-child-tree {\n display: block;\n}\n.explorer-table-header {\n display: flex;\n width: fit-content;\n min-width: 100%;\n height: 25px;\n line-height: 25px;\n color: #448;\n border-bottom: 1px solid #e3e3e3;\n box-shadow: 0 6px 10px rgba(0, 0, 0, 0.05);\n background: #fff;\n}\n.explorer-table-header .item {\n padding: 0 10px 0 0;\n flex: 1 0 0;\n margin-left: -10px;\n border-right: 1px solid #eee;\n user-select: none;\n min-width: 80px;\n}\n.explorer-table-header .item:first-child {\n padding-left: 20px;\n}\n.explorer-table-header .resize {\n position: relative;\n flex: 0 0 20px;\n width: 20px;\n z-index: 10;\n cursor: col-resize;\n left: -10px;\n transition: background 0.2s;\n}\n.explorer-table-header .resize::before {\n content: '';\n position: fixed;\n width: 1px;\n height: 2000px;\n z-index: 10;\n margin-left: 10px;\n visibility: hidden;\n opacity: 0;\n transition: all 0.2s;\n}\n.explorer-table-header .resize:hover {\n background: #1890ff30;\n}\n.explorer-table-header .resize.resize-focus {\n z-index: 9999;\n}\n.explorer-table-header .resize.resize-focus:before {\n opacity: 1;\n background: #1890ff;\n visibility: visible;\n}\n.explorer-table-header .resize:last-child {\n flex: 0 0 10px;\n width: 10px;\n}\n.explorer-table-header.item-resize {\n z-index: 10;\n}\n@keyframes rotate {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n}\n";
1924
+ var css_248z$6 = ".explorer-tree {\n width: 100%;\n height: 100%;\n}\n.explorer-tree-switch {\n height: 31px;\n width: 24px;\n display: flex;\n justify-content: center;\n align-items: center;\n vertical-align: top !important;\n color: #aaa;\n border-radius: 2px;\n}\n.explorer-tree-switch:hover {\n color: #1890ff;\n background-color: rgba(0, 0, 0, 0.03);\n}\n.explorer-tree-switch.open {\n color: #1890ff;\n}\n.explorer-tree-switch.open > svg {\n transform: rotate(90deg);\n}\n.explorer-tree-switch.loading {\n background: transparent;\n animation: rotate 1s linear infinite;\n}\n.explorer-tree-icon {\n display: inline-block;\n width: 20px;\n height: 20px;\n margin: 6px 0px;\n background-repeat: no-repeat;\n background-position: center;\n background-size: cover;\n border-radius: 5px;\n font-style: normal;\n pointer-events: none;\n vertical-align: top;\n}\n.explorer-tree-node {\n display: flex;\n height: 100%;\n align-items: center;\n}\n.explorer-tree-node .node-title {\n flex: 1;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n}\n.explorer-tree-node .node-menu {\n display: none;\n flex-shrink: 0;\n width: 30px;\n justify-content: center;\n align-items: center;\n}\n.explorer-tree-node .node-menu .node-menu-icon {\n display: flex;\n justify-content: center;\n align-items: center;\n width: 14px;\n height: 14px;\n border: 1px solid #ccc;\n border-radius: 2px;\n cursor: pointer;\n z-index: 50;\n background: #fff;\n color: #ccc;\n font-size: 7px;\n transition: 0.3s;\n}\n.explorer-tree-node .node-menu .node-menu-icon > svg {\n transform: rotate(90deg);\n}\n.explorer-tree-node .node-menu .node-menu-icon:hover {\n border: 1px solid #1890ff;\n color: #1890ff;\n}\n.explorer-tree-node .node-input {\n display: inline-block;\n width: 100%;\n height: 24px;\n outline: 0;\n border: 1px solid #eee;\n border-radius: 3px;\n transition: 0.3s;\n padding: 0 5px;\n}\n.explorer-tree-node .node-input:hover {\n border: 1px solid #1890ff;\n}\n.explorer-tree-node .node-input:focus {\n border: 1px solid #1890ff;\n}\n.explorer-tree-node:hover .node-menu {\n display: flex;\n}\n.explorer-tree-row {\n display: flex;\n width: 100%;\n height: 100%;\n align-items: center;\n}\n.explorer-tree-row .row-item {\n display: flex;\n padding: 0 10px;\n flex: 1 0 0;\n user-select: none;\n}\n.explorer-tree-row .row-item .row-item-content {\n flex: 1 0 0;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n}\n.explorer-tree-row .row-item .row-item-content > input {\n height: 24px;\n outline: none;\n width: 100%;\n outline: 0;\n border: 0;\n}\n.explorer-tree-row .row-item-check {\n display: flex;\n width: 19px;\n align-items: center;\n box-sizing: border-box;\n pointer-events: all;\n}\n.explorer-tree-row .row-item-check .btn-check {\n display: inline-block;\n height: 19px;\n width: 19px;\n flex-shrink: 0;\n z-index: 11;\n font-size: 20px;\n text-align: center;\n border-radius: 50%;\n background: rgba(0, 0, 0, 0.05);\n color: #fff;\n line-height: 0;\n opacity: 0;\n cursor: pointer;\n transition: opacity 0.3s;\n margin: 2px;\n}\n.explorer-tree-row .row-item-check .btn-check > svg {\n position: relative;\n width: 23px;\n height: 23px;\n left: -2px;\n top: -2px;\n}\n.explorer-tree-row .row-item-check.active .btn-check {\n opacity: 1;\n background: #3b8cff;\n}\n.explorer-tree.table .tree-scroll-x {\n width: 100%;\n overflow: hidden;\n overflow-x: auto;\n}\n.explorer-tree.table .tree-scroll-x::-webkit-scrollbar {\n display: none;\n}\n.explorer-tree.table .tree-scroll {\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n z-index: 10;\n overflow: auto;\n}\n.explorer-tree.table .rc-tree {\n height: calc(100% - 26px);\n}\n.explorer-tree.table .rc-tree-list-holder-inner {\n overflow: auto;\n}\n.explorer-tree.table .rc-tree-list {\n height: 100%;\n}\n.explorer-tree.table .rc-tree-checkbox {\n display: none !important;\n}\n.explorer-tree.table .rc-tree-treenode {\n border-radius: 2px;\n width: fit-content;\n opacity: 0.8;\n z-index: 100;\n pointer-events: all;\n}\n.explorer-tree.table .rc-tree-treenode:nth-child(odd) {\n background: #4664780d;\n}\n.explorer-tree.table .rc-tree-list-holder-inner {\n padding: 8px 0 0 8px;\n}\n.explorer-tree.table .rc-tree-treenode-leaf-last:last-child {\n height: 200px;\n width: 1px;\n}\n.explorer-tree.table .rc-tree-treenode-checkbox-checked {\n background: #cce8ff !important;\n border: 1px solid #99d1ff;\n}\n.explorer-tree .rc-tree-iconEle {\n height: 31px !important;\n vertical-align: top !important;\n width: auto !important;\n}\n.explorer-tree .rc-tree-treenode {\n position: relative;\n height: 31px;\n line-height: 31px;\n border: 1px solid transparent;\n display: flex;\n}\n.explorer-tree .rc-tree-treenode > .rc-tree-node-content-wrapper {\n height: 31px !important;\n display: flex !important;\n flex: 1;\n margin-left: calc(24px - 20px);\n}\n.explorer-tree .rc-tree-treenode > .rc-tree-node-selected {\n background-color: transparent;\n box-shadow: none;\n opacity: 1;\n}\n.explorer-tree .rc-tree-treenode.rc-tree-treenode-selected {\n background-color: #cce8ff !important;\n border: 1px solid #1890ff;\n opacity: 0.8;\n}\n.explorer-tree .rc-tree-treenode.rc-tree-treenode-selected .node-menu {\n display: flex;\n}\n.explorer-tree .rc-tree-treenode:hover {\n background: #e5f3ff !important;\n box-shadow: 0 0 0 1px transparent;\n}\n.explorer-tree .rc-tree-treenode.hover {\n background: #e5f3ff !important;\n}\n.explorer-tree .rc-tree-switcher {\n flex-shrink: 0;\n width: 20px !important;\n height: 31px !important;\n vertical-align: top !important;\n background-image: none !important;\n}\n.explorer-tree .rc-tree-title {\n display: inline-block;\n height: 31px;\n width: 100%;\n}\n.explorer-tree.showLine .rc-tree-indent {\n height: 31px;\n}\n.explorer-tree.showLine .rc-tree-indent > .rc-tree-indent-unit {\n position: relative;\n}\n.explorer-tree.showLine .rc-tree-indent > .rc-tree-indent-unit::after {\n display: inline-block;\n position: absolute;\n content: '';\n width: 1px;\n left: 10px;\n height: 31px;\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.showLine .rc-tree-indent-unit {\n width: 20px;\n height: 31px;\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:last-child {\n position: relative;\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:last-child::before {\n content: '';\n display: inline-block;\n position: absolute;\n width: 8px;\n top: calc(31px / 2);\n left: 10px;\n height: 1px;\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:last-child::after {\n display: inline-block;\n position: absolute;\n content: '';\n width: 1px;\n left: 10px;\n top: 0;\n height: calc(31px / 2);\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:first-child {\n position: relative;\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:first-child::before {\n display: none;\n content: '';\n}\n.explorer-tree.showLine .rc-tree-treenode-leaf-last .rc-tree-indent > .rc-tree-indent-unit:first-child::after {\n display: inline-block;\n position: absolute;\n content: '';\n width: 1px;\n left: 10px;\n height: 31px;\n background-color: rgba(0, 0, 0, 0.075);\n}\n.explorer-tree.explorer-checks .rc-tree-treenode:hover .row-item-check .btn-check {\n opacity: 1;\n}\n.explorer-tree .rc-tree-list-scrollbar-thumb {\n background: #bbb !important;\n}\n.explorer-tree .rc-tree-list-scrollbar {\n width: 5px !important;\n}\n.explorer-tree .node-motion {\n transition: all 0.3s;\n overflow-y: hidden;\n}\n.explorer-tree .rc-tree-child-tree {\n display: block;\n}\n.explorer-table-header {\n display: flex;\n width: fit-content;\n min-width: 100%;\n height: 25px;\n line-height: 25px;\n color: #448;\n border-bottom: 1px solid #e3e3e3;\n box-shadow: 0 6px 10px rgba(0, 0, 0, 0.05);\n background: #fff;\n}\n.explorer-table-header .item {\n padding: 0 10px 0 0;\n flex: 1 0 0;\n margin-left: -10px;\n border-right: 1px solid #eee;\n user-select: none;\n min-width: 80px;\n}\n.explorer-table-header .item:first-child {\n padding-left: 20px;\n}\n.explorer-table-header .resize {\n position: relative;\n flex: 0 0 20px;\n width: 20px;\n z-index: 10;\n cursor: col-resize;\n left: -10px;\n transition: background 0.2s;\n}\n.explorer-table-header .resize::before {\n content: '';\n position: fixed;\n width: 1px;\n height: 2000px;\n z-index: 10;\n margin-left: 10px;\n visibility: hidden;\n opacity: 0;\n transition: all 0.2s;\n}\n.explorer-table-header .resize:hover {\n background: #1890ff30;\n}\n.explorer-table-header .resize.resize-focus {\n z-index: 9999;\n}\n.explorer-table-header .resize.resize-focus:before {\n opacity: 1;\n background: #1890ff;\n visibility: visible;\n}\n.explorer-table-header .resize:last-child {\n flex: 0 0 10px;\n width: 10px;\n}\n.explorer-table-header.item-resize {\n z-index: 10;\n}\n@keyframes rotate {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n}\n";
1914
1925
  styleInject(css_248z$6);
1915
1926
 
1916
1927
  /**
@@ -5838,13 +5849,14 @@ const ExplorerMenu = props => {
5838
5849
  } = props;
5839
5850
  const store = useContext(ExampleContext);
5840
5851
  const [eventKey, setEventKey] = useState([]);
5841
- if (!store) return;
5852
+ const [loadKey, setLoadKey] = useState([]);
5842
5853
  return jsx("div", {
5843
5854
  className: 'frame-left',
5844
5855
  children: jsx(Tree, {
5845
5856
  isload: true,
5846
5857
  treeData: data,
5847
5858
  height: height,
5859
+ loadedKeys: loadKey,
5848
5860
  expandedKeys: eventKey,
5849
5861
  icon: (v, className) => {
5850
5862
  if (v.icon == false) return jsx(Fragment, {});
@@ -5855,17 +5867,16 @@ const ExplorerMenu = props => {
5855
5867
  onChange: onChange,
5856
5868
  onSelect: v => {
5857
5869
  store.setPathDisplay(v?.pathDisplay);
5858
- // if (Array.isArray(v?.children)) {
5859
- // store.setCurInfo(v);
5860
- // store.setCurList(v?.children || []);
5861
- // } else {
5862
5870
  loadData(v.key);
5863
- // }
5864
5871
  },
5865
5872
  filterData: v => {
5866
5873
  if (v.type == 'file') return false;
5867
5874
  return true;
5868
5875
  },
5876
+ onLoad: key => {
5877
+ setLoadKey(key);
5878
+ },
5879
+ setLoadKey: setLoadKey,
5869
5880
  onExpand: v => {
5870
5881
  setEventKey(v);
5871
5882
  }
@@ -6093,6 +6104,9 @@ function Tile(props) {
6093
6104
  });
6094
6105
  }
6095
6106
 
6107
+ var css_248z$2 = ".explorer-drop-tip {\n position: absolute;\n display: inline-block;\n padding: 3px 5px;\n background: #00000044;\n color: #fff;\n border-radius: 3px;\n white-space: nowrap;\n}\n.explorer-drop-tip.select {\n background: #1677ff;\n}\n.explorer-drop-tip .drop-tip-content {\n font-size: 14px;\n margin-right: 5px;\n}\n.explorer-drop-tip .drop-tip-content .content-icon {\n display: inline-block;\n height: 20px;\n width: 20px;\n border-radius: 50%;\n background: #52c41a;\n color: #fff;\n text-align: center;\n line-height: 20px;\n margin-right: 5px;\n}\n.explorer-drop-tip .drop-tip-title {\n font-size: 14px;\n display: inline-block;\n padding: 2px;\n background: rgba(0, 0, 0, 0.2);\n font-weight: 500;\n padding: 3px 5px;\n line-height: 1;\n border-right: 4px;\n}\n.file-select-box {\n width: 100%;\n border: 2px solid transparent;\n}\n";
6108
+ styleInject(css_248z$2);
6109
+
6096
6110
  var time = null;
6097
6111
  const SelectBox = props => {
6098
6112
  let {
@@ -6101,12 +6115,14 @@ const SelectBox = props => {
6101
6115
  dataClass,
6102
6116
  selectClass = '',
6103
6117
  regionClass,
6118
+ getContainer = '',
6104
6119
  isDrag = true,
6105
6120
  isSelectBoxes = true,
6106
6121
  checkType = '',
6107
6122
  checkMode,
6108
6123
  action = 'stack',
6109
- onChange
6124
+ onChange,
6125
+ onUpload
6110
6126
  } = props;
6111
6127
  const selectionRef = useRef(null);
6112
6128
  const clickRef = useRef(true);
@@ -6120,8 +6136,12 @@ const SelectBox = props => {
6120
6136
  const box = useRef(null);
6121
6137
  //当前
6122
6138
  const cur = useRef([]);
6139
+ //文案
6140
+ const text = useRef(null);
6123
6141
  //判断单机还双击
6124
6142
  const isDclick = useRef(null);
6143
+ const store = useContext(ExampleContext);
6144
+ const [isDragfile, setIsDragFile] = useState(false);
6125
6145
  const [selects, setSelect] = useState([]);
6126
6146
  const [stageClickInfo, setStageClickInfo] = useState({
6127
6147
  show: false
@@ -6129,6 +6149,29 @@ const SelectBox = props => {
6129
6149
  useEffect(() => {
6130
6150
  setSelect(checks);
6131
6151
  }, [checks]);
6152
+ useEffect(() => {
6153
+ if (isDragfile) {
6154
+ createText();
6155
+ } else {
6156
+ box.current?.remove();
6157
+ text.current = null;
6158
+ box.current = null;
6159
+ }
6160
+ }, [isDragfile]);
6161
+ useEffect(() => {
6162
+ // 在这里执行需要操作 DOM 的代码
6163
+ document.querySelector(getContainer)?.addEventListener('dragenter', bodyDragEnter);
6164
+ document.addEventListener('dragover', handleDragOver, false);
6165
+ document.addEventListener('dragleave', handleDragLeave, false);
6166
+ document?.addEventListener('dragenter', handleDragEnter);
6167
+ document?.addEventListener('drop', handleDrop);
6168
+ return () => {
6169
+ document.removeEventListener('dragenter', bodyDragEnter);
6170
+ document.removeEventListener('dragover', handleDragOver);
6171
+ document.removeEventListener('dragleave', handleDragLeave);
6172
+ document?.addEventListener('drop', handleDrop);
6173
+ };
6174
+ }, []);
6132
6175
  useEffect(() => {
6133
6176
  document.addEventListener('mousemove', handleBodyMousemove);
6134
6177
  document.addEventListener('mouseup', handleBodyMouseup);
@@ -6138,22 +6181,32 @@ const SelectBox = props => {
6138
6181
  };
6139
6182
  }, [stageClickInfo, checkMode]);
6140
6183
  //判断鼠标点击位置 是否为目标区域
6141
- function isSelectTarget(e) {
6184
+ function isSelectTarget(e, checkType, status) {
6142
6185
  let idx = [];
6143
6186
  Array.from(document.querySelectorAll(selectClass)).filter(v => {
6144
6187
  if (v.contains(e.target)) {
6145
6188
  let dataDom = v;
6146
6189
  if (dataClass) {
6147
6190
  dataDom = v.querySelector(dataClass);
6148
- let id = dataDom.getAttribute('data-id');
6191
+ let id = dataDom?.getAttribute('data-id');
6149
6192
  if (checkType) {
6150
- let type = dataDom.getAttribute('data-type');
6193
+ let type = dataDom?.getAttribute('data-type');
6151
6194
  if (type !== checkType) return;
6195
+ if (status == 'select') {
6196
+ v.classList.add('hover');
6197
+ }
6152
6198
  }
6153
6199
  if (id) {
6154
6200
  idx.push(id);
6155
6201
  }
6156
6202
  }
6203
+ } else {
6204
+ if (status == 'select') {
6205
+ v.classList.remove('hover');
6206
+ }
6207
+ }
6208
+ if (status == 'remove') {
6209
+ v.classList.remove('hover');
6157
6210
  }
6158
6211
  });
6159
6212
  if (idx.length) {
@@ -6219,6 +6272,111 @@ const SelectBox = props => {
6219
6272
  }, 300);
6220
6273
  }
6221
6274
  }
6275
+ //拖动时
6276
+ const handleDragOver = e => {
6277
+ e.preventDefault();
6278
+ const {
6279
+ clientX: x,
6280
+ clientY: y
6281
+ } = e;
6282
+ if (text.current) {
6283
+ const data = isSelectTarget(e, 'folder', 'select');
6284
+ let param = {};
6285
+ let is = false;
6286
+ if (ref.current.contains(e.target)) {
6287
+ param = store.curInfo;
6288
+ is = true;
6289
+ }
6290
+ if (typeof data?.[0] == 'string' && store?.dataMap?.[data?.[0]]) {
6291
+ param = store?.dataMap?.[data?.[0]];
6292
+ is = false;
6293
+ }
6294
+ if (is) {
6295
+ ref.current.style.cssText = `
6296
+ border:2px solid #1677ff;
6297
+ `;
6298
+ } else {
6299
+ ref.current.style.cssText = `
6300
+ border:2px solid transparent;
6301
+ `;
6302
+ }
6303
+ let element = renderDragtext({
6304
+ x: x + 20,
6305
+ y: y + 20,
6306
+ ...param
6307
+ });
6308
+ text.current.render(element);
6309
+ }
6310
+ };
6311
+ const handleDrop = e => {
6312
+ setIsDragFile(false);
6313
+ e.preventDefault();
6314
+ e.stopPropagation();
6315
+ const files = [...e.dataTransfer.files];
6316
+ let data = isSelectTarget(e, 'folder', 'remove');
6317
+ let key = null;
6318
+ if (ref.current.contains(e.target)) {
6319
+ key = store.curInfo;
6320
+ ref.current.style.cssText = `
6321
+ border:2px solid transparent;
6322
+ `;
6323
+ }
6324
+ if (typeof data?.[0] == 'string' && store?.dataMap?.[data?.[0]]) {
6325
+ key = store?.dataMap?.[data?.[0]];
6326
+ }
6327
+ if (!key) return;
6328
+ typeof onUpload === 'function' && onUpload(files, key);
6329
+ };
6330
+ function handleDragEnter(e) {
6331
+ e.preventDefault();
6332
+ e.stopPropagation();
6333
+ }
6334
+ //退出当前区域
6335
+ function handleDragLeave(e) {
6336
+ let cont = document.querySelector(getContainer);
6337
+ e.preventDefault();
6338
+ e.stopPropagation();
6339
+ if (!cont?.contains(e.target) || e.clientX <= 0 || e.clientY <= 0) {
6340
+ setIsDragFile(false);
6341
+ }
6342
+ }
6343
+ //拖入div
6344
+ function bodyDragEnter(e) {
6345
+ e?.preventDefault();
6346
+ e?.stopPropagation();
6347
+ if (e?.dataTransfer?.types && !e?.dataTransfer?.types.includes('Files')) {
6348
+ return;
6349
+ }
6350
+ setIsDragFile(true);
6351
+ }
6352
+ //创建文案
6353
+ function createText() {
6354
+ let _box = null;
6355
+ let body = null;
6356
+ let _text = null;
6357
+ _text = document.createElement('div');
6358
+ text.current = createRoot(_text);
6359
+ if (box.current) {
6360
+ box.current?.appendChild(text);
6361
+ } else {
6362
+ body = document.querySelector('body');
6363
+ _box = document.createElement('div');
6364
+ _box.className = `_selectbox ${className}`;
6365
+ _box.style.cssText = `
6366
+ position: absolute;
6367
+ top:1px;
6368
+ left: 1px;
6369
+ width: 0px;
6370
+ height: 0px;
6371
+ pointer-events: none;
6372
+ overflow: visible !important;
6373
+ z-index: 999;
6374
+ `;
6375
+ box.current = _box;
6376
+ _box?.appendChild(_text);
6377
+ body?.appendChild(_box);
6378
+ }
6379
+ }
6222
6380
  //创建选框
6223
6381
  function createBox(e) {
6224
6382
  if (stageClickInfo.show) {
@@ -6414,17 +6572,51 @@ const SelectBox = props => {
6414
6572
  box.current = null;
6415
6573
  clickRef.current = false;
6416
6574
  }
6575
+ function renderDragtext({
6576
+ x,
6577
+ y,
6578
+ ...props
6579
+ }) {
6580
+ return jsx("div", {
6581
+ className: cx$1('explorer-drop-tip', {
6582
+ select: props?.title
6583
+ }),
6584
+ style: {
6585
+ top: y,
6586
+ left: x
6587
+ },
6588
+ children: props?.title ? jsxs(Fragment, {
6589
+ children: [jsxs("span", {
6590
+ className: 'drop-tip-content',
6591
+ children: [jsx("span", {
6592
+ className: 'content-icon',
6593
+ children: jsx(UploadSvg, {})
6594
+ }), jsx(Fragment, {
6595
+ children: " \u4E0A\u4F20\u81F3:"
6596
+ })]
6597
+ }), jsx("span", {
6598
+ className: 'drop-tip-title',
6599
+ children: props?.title
6600
+ })]
6601
+ }) : jsx(Fragment, {
6602
+ children: "\u62D6\u5230\u6587\u4EF6\u5939\u4E0A\u4F20"
6603
+ })
6604
+ });
6605
+ }
6417
6606
  return jsxs("div", {
6418
6607
  ref: ref,
6419
- className: cx$1(`${className}`),
6420
- onClick: e => {},
6608
+ className: cx$1(`file-select-box ${className}`),
6609
+ onDragLeave: e => {
6610
+ e.preventDefault();
6611
+ e.stopPropagation();
6612
+ },
6421
6613
  onMouseDown: e => {
6422
6614
  if (e.button === 2) return;
6423
6615
  if (isDclick.current) {
6424
6616
  clearTimeout(isDclick.current);
6425
6617
  isDclick.current = null;
6426
6618
  } else {
6427
- let type = isSelectTarget(e);
6619
+ let type = isSelectTarget(e, checkType);
6428
6620
  //选中
6429
6621
  //在区域未选中
6430
6622
  isDclick.current = setTimeout(() => {
@@ -6474,8 +6666,8 @@ const SelectBox = props => {
6474
6666
  });
6475
6667
  };
6476
6668
 
6477
- var css_248z$2 = ".explorer-columns {\n width: 100%;\n height: 100%;\n display: flex;\n position: relative;\n}\n.explorer-columns .layer {\n position: relative;\n flex: 1 0 0;\n border-right: 1px solid #f5f5f5;\n}\n.explorer-columns .layer.select_col {\n box-shadow: 0 0 20px #e9f5ff inset;\n}\n.explorer-columns .layer.select_col::after {\n content: '';\n position: absolute;\n height: 4px;\n bottom: 0px;\n background: #50afff;\n left: 0;\n right: 0;\n}\n.explorer-columns .layer.list {\n min-width: 200px;\n}\n.explorer-columns .layer.list::before {\n position: absolute;\n content: '';\n top: 50%;\n right: 1px;\n width: 1px;\n height: 18px;\n margin-left: -1px;\n margin-top: -9px;\n border: 1px solid #ddd;\n border-top: none;\n border-bottom: none;\n backdrop-filter: none;\n border-radius: 0;\n background: transparent;\n box-sizing: content-box;\n -webkit-backdrop-filter: blur(10px);\n}\n.explorer-columns .layer.list .list-main {\n width: 100%;\n height: 100%;\n transition: 0.3s;\n padding-top: 5px;\n}\n.explorer-columns .layer.list .list-main .list-scroll::-webkit-scrollbar {\n width: 6px;\n}\n.explorer-columns .layer.list .list-main .list-scroll::-webkit-scrollbar-thumb {\n background-color: transparent;\n border-radius: 6px;\n transition: 0.3s;\n}\n.explorer-columns .layer.list .list-main:hover .list-scroll::-webkit-scrollbar-thumb {\n background-color: #00000030;\n}\n.explorer-columns .layer.list .drag {\n position: absolute;\n width: 8px;\n border-right: 1px solid #f5f5f5;\n right: -3px;\n top: 0;\n bottom: 0;\n cursor: col-resize;\n z-index: 10;\n}\n.explorer-columns .layer.list .drag:hover {\n background: #40a9ff4d;\n}\n.explorer-columns .layer.empty {\n display: flex;\n justify-content: center;\n padding-top: 100px;\n}\n.explorer-columns .layer.empty .empty-is-null {\n width: 200px;\n}\n.explorer-columns .layer.empty .empty-icon {\n height: 140px;\n}\n.explorer-columns .layer.empty .empty-desc {\n display: flex;\n justify-content: center;\n}\n.explorer-columns .layer.empty .empty-desc > span {\n display: inline-block;\n padding: 3px 10px;\n border-radius: 10px;\n line-height: 1;\n background: #a0a0a01a;\n color: #bbb;\n font-size: 0.9em;\n}\n.explorer-columns-list {\n padding-left: 10px;\n display: flex;\n height: 30px;\n margin-bottom: 2px;\n margin: 0 5px 3px 5px;\n align-items: center;\n border: 1px solid transparent;\n user-select: none;\n}\n.explorer-columns-list .columns-list-icon {\n display: flex;\n width: 18px;\n height: 18px;\n margin-right: 10px;\n flex-shrink: 0;\n}\n.explorer-columns-list .columns-list-title {\n flex: 1;\n display: flex;\n}\n.explorer-columns-list .columns-list-title .title {\n display: flex;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.explorer-columns-list .columns-list-title .edit {\n display: inline-block;\n width: 20px;\n line-height: 20px;\n font-size: 10px;\n text-align: center;\n border-radius: 3px;\n margin-left: 5px;\n color: #666;\n opacity: 0;\n transition: 0.3s;\n}\n.explorer-columns-list .columns-list-title .edit:hover {\n color: #50afff;\n background: #ffffff8a;\n cursor: pointer;\n}\n.explorer-columns-list .columns-list-tool {\n min-width: 30px;\n}\n.explorer-columns-list .columns-list-input {\n flex: 1;\n height: 100%;\n outline: 0;\n border: 0;\n margin-right: 10px;\n background: #fff;\n}\n.explorer-columns-list.acitve {\n background: #e3f0ff;\n}\n.explorer-columns-list.last {\n margin-bottom: 100px;\n}\n.explorer-columns-list.checks {\n background: #cce8ff;\n border-color: #a8d8ff !important;\n}\n.explorer-columns-list:hover {\n background: #e3f0ff;\n border-color: #c9e2ff;\n}\n.explorer-columns-list:hover .edit {\n opacity: 1;\n}\n.explorer-columns-loading {\n position: absolute;\n display: flex;\n justify-content: center;\n align-items: center;\n z-index: 999;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n}\n.explorer-columns-loading .loading-content {\n width: 100px;\n height: 106px;\n border-radius: 6px;\n background: rgba(255, 255, 255, 0.7);\n box-shadow: 2px 4px 10px rgba(0, 0, 0, 0.07);\n color: #888;\n}\n.explorer-columns-loading .loading-content-icon {\n display: flex;\n justify-content: center;\n margin: 25px auto 6px auto;\n font-size: 30px;\n}\n.explorer-columns-loading .loading-content-icon > i {\n animation: rotate 1.5s linear infinite;\n}\n.explorer-columns-loading .loading-content-title {\n padding-top: 15px;\n text-align: center;\n}\n@keyframes rotate {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n}\n";
6478
- styleInject(css_248z$2);
6669
+ var css_248z$1 = ".explorer-columns {\n width: 100%;\n height: 100%;\n display: flex;\n position: relative;\n}\n.explorer-columns .layer {\n position: relative;\n flex: 1 0 0;\n border-right: 1px solid #f5f5f5;\n}\n.explorer-columns .layer.select_col {\n box-shadow: 0 0 20px #e9f5ff inset;\n}\n.explorer-columns .layer.select_col::after {\n content: '';\n position: absolute;\n height: 4px;\n bottom: 0px;\n background: #50afff;\n left: 0;\n right: 0;\n}\n.explorer-columns .layer.list {\n min-width: 200px;\n}\n.explorer-columns .layer.list::before {\n position: absolute;\n content: '';\n top: 50%;\n right: 1px;\n width: 1px;\n height: 18px;\n margin-left: -1px;\n margin-top: -9px;\n border: 1px solid #ddd;\n border-top: none;\n border-bottom: none;\n backdrop-filter: none;\n border-radius: 0;\n background: transparent;\n box-sizing: content-box;\n -webkit-backdrop-filter: blur(10px);\n}\n.explorer-columns .layer.list .list-main {\n width: 100%;\n height: 100%;\n transition: 0.3s;\n padding-top: 5px;\n}\n.explorer-columns .layer.list .list-main .list-scroll::-webkit-scrollbar {\n width: 6px;\n}\n.explorer-columns .layer.list .list-main .list-scroll::-webkit-scrollbar-thumb {\n background-color: transparent;\n border-radius: 6px;\n transition: 0.3s;\n}\n.explorer-columns .layer.list .list-main:hover .list-scroll::-webkit-scrollbar-thumb {\n background-color: #00000030;\n}\n.explorer-columns .layer.list .drag {\n position: absolute;\n width: 8px;\n border-right: 1px solid #f5f5f5;\n right: -3px;\n top: 0;\n bottom: 0;\n cursor: col-resize;\n z-index: 10;\n}\n.explorer-columns .layer.list .drag:hover {\n background: #40a9ff4d;\n}\n.explorer-columns .layer.empty {\n display: flex;\n justify-content: center;\n padding-top: 100px;\n}\n.explorer-columns .layer.empty .empty-is-null {\n width: 200px;\n}\n.explorer-columns .layer.empty .empty-icon {\n height: 140px;\n}\n.explorer-columns .layer.empty .empty-desc {\n display: flex;\n justify-content: center;\n}\n.explorer-columns .layer.empty .empty-desc > span {\n display: inline-block;\n padding: 3px 10px;\n border-radius: 10px;\n line-height: 1;\n background: #a0a0a01a;\n color: #bbb;\n font-size: 0.9em;\n}\n.explorer-columns-list {\n padding-left: 10px;\n display: flex;\n height: 30px;\n margin-bottom: 2px;\n margin: 0 5px 3px 5px;\n align-items: center;\n border: 1px solid transparent;\n user-select: none;\n}\n.explorer-columns-list .columns-list-icon {\n display: flex;\n width: 18px;\n height: 18px;\n margin-right: 10px;\n flex-shrink: 0;\n}\n.explorer-columns-list .columns-list-title {\n flex: 1;\n display: flex;\n}\n.explorer-columns-list .columns-list-title .title {\n display: flex;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.explorer-columns-list .columns-list-title .edit {\n display: inline-block;\n width: 20px;\n line-height: 20px;\n font-size: 10px;\n text-align: center;\n border-radius: 3px;\n margin-left: 5px;\n color: #666;\n opacity: 0;\n transition: 0.3s;\n}\n.explorer-columns-list .columns-list-title .edit:hover {\n color: #50afff;\n background: #ffffff8a;\n cursor: pointer;\n}\n.explorer-columns-list .columns-list-tool {\n min-width: 30px;\n}\n.explorer-columns-list .columns-list-input {\n flex: 1;\n height: 100%;\n outline: 0;\n border: 0;\n margin-right: 10px;\n background: #fff;\n}\n.explorer-columns-list.acitve {\n background: #e3f0ff;\n}\n.explorer-columns-list.last {\n margin-bottom: 100px;\n}\n.explorer-columns-list.checks {\n background: #cce8ff;\n border-color: #a8d8ff !important;\n}\n.explorer-columns-list:hover {\n background: #e3f0ff;\n border-color: #c9e2ff;\n}\n.explorer-columns-list:hover .edit {\n opacity: 1;\n}\n.explorer-columns-loading {\n position: absolute;\n display: flex;\n justify-content: center;\n align-items: center;\n z-index: 999;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n}\n.explorer-columns-loading .loading-content {\n width: 100px;\n height: 106px;\n border-radius: 6px;\n background: rgba(255, 255, 255, 0.7);\n box-shadow: 2px 4px 10px rgba(0, 0, 0, 0.07);\n color: #888;\n}\n.explorer-columns-loading .loading-content-icon {\n display: flex;\n justify-content: center;\n margin: 25px auto 6px auto;\n font-size: 30px;\n}\n.explorer-columns-loading .loading-content-icon > i {\n animation: rotate 1.5s linear infinite;\n}\n.explorer-columns-loading .loading-content-title {\n padding-top: 15px;\n text-align: center;\n}\n@keyframes rotate {\n from {\n transform: rotate(0deg);\n }\n to {\n transform: rotate(360deg);\n }\n}\n";
6670
+ styleInject(css_248z$1);
6479
6671
 
6480
6672
  function Item(props) {
6481
6673
  const {
@@ -6713,286 +6905,6 @@ function Columns(props) {
6713
6905
  });
6714
6906
  }
6715
6907
 
6716
- var css_248z$1 = "._modal {\n position: absolute;\n justify-content: center;\n display: flex;\n top: 0;\n left: 0;\n right: 0;\n z-index: 100;\n}\n._modal-content {\n position: absolute;\n width: 800px;\n height: 400px;\n top: 100px;\n background-color: #fff;\n background-clip: padding-box;\n border: 0;\n border-radius: 8px;\n border: 1px solid #eee;\n transition: box-shadow 0.2s;\n box-shadow: 0 6px 8px 0 rgba(0, 0, 0, 0.04), 0 3px 6px -4px rgba(0, 0, 0, 0.08), 0 0 8px 8px rgba(0, 0, 0, 0.03);\n pointer-events: auto;\n}\n._modal-content.focus {\n box-shadow: 0 6px 16px 0 rgba(0, 0, 0, 0.12), 0 3px 6px -4px rgba(0, 0, 0, 0.16), 0 9px 28px 8px rgba(0, 0, 0, 0.03);\n}\n._modal-content.maximize {\n width: 100% !important;\n height: 100% !important;\n top: 0 !important;\n left: 0 !important;\n bottom: 0 !important;\n right: 0 !important;\n}\n._modal-content.maximize .header-title {\n cursor: default;\n}\n._modal-content.minimize {\n animation: _modal_minimize 0.3s forwards;\n}\n._modal-content.minimize-out {\n transition: 0.3s;\n}\n._modal-content.animation {\n transition: 0.3s;\n}\n._modal-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n height: 30px;\n padding: 0 10px;\n border-bottom: 1px solid #f1f1f1;\n}\n._modal-header .header-title {\n flex: 1;\n cursor: move;\n}\n._modal-header .header-toolbar {\n display: flex;\n}\n._modal-header .header-toolbar .tool {\n width: 30px;\n height: 30px;\n vertical-align: top;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 10px;\n cursor: pointer;\n}\n._modal-header .header-toolbar .tool > svg {\n top: 0;\n}\n._modal-header .header-toolbar .tool.close {\n font-size: 12px;\n}\n._modal-header .header-toolbar .tool.close:hover {\n background: #ff0000d0;\n color: #fff;\n}\n._modal-header .header-toolbar .tool:hover {\n background: #e5e5e5;\n}\n._modal-navbar {\n height: 30px;\n width: 100%;\n padding: 0px 10px;\n}\n._modal-navbar ._modal-navbar-item {\n position: relative;\n display: inline-block;\n z-index: 100;\n height: 30px;\n line-height: 30px;\n padding: 0 10px;\n background-color: #fff3;\n border: 1px solid #f1f1f1;\n border-radius: 4px 4px 0 0;\n transition: 0.3s;\n margin-right: 2px;\n cursor: pointer;\n}\n._modal-navbar ._modal-navbar-item.acitve {\n z-index: 10;\n box-shadow: 0 0 5px rgba(0, 0, 0, 0.4);\n}\n._modal-navbar ._modal-navbar-item:hover {\n box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);\n}\n@keyframes _modal_minimize {\n 0% {\n opacity: 1;\n transform: translateY(0px);\n }\n 90% {\n opacity: 0;\n transform: translateY(30px);\n }\n 100% {\n opacity: 0;\n display: none;\n }\n}\n";
6717
- styleInject(css_248z$1);
6718
-
6719
- function Modal(props) {
6720
- const {
6721
- id,
6722
- show,
6723
- title,
6724
- onBlur,
6725
- onFocus,
6726
- isfocus,
6727
- onMinimize: onMin,
6728
- onMaximize: onMax,
6729
- minimize
6730
- } = props;
6731
- const content = useRef(null);
6732
- const mask = useRef(null);
6733
- const root = useRef(null);
6734
- const [drag, setDrag] = useState(false);
6735
- const [d_value, D_value] = useState([0, 0]); //点击时的差值
6736
- const [win_size, setWinsize] = useState(getSize);
6737
- const [focus, setFocus] = useState(false);
6738
- const [ismax, setMax] = useState(false);
6739
- useLayoutEffect(() => {
6740
- window.addEventListener('resize', handleResize);
6741
- return () => window.removeEventListener('resize', handleResize);
6742
- }, []);
6743
- //拖动监听
6744
- useLayoutEffect(() => {
6745
- document.addEventListener('mousemove', lie);
6746
- return () => {
6747
- document.removeEventListener('mousemove', lie);
6748
- };
6749
- }, [drag]);
6750
- //创建
6751
- useEffect(() => {
6752
- if (show) {
6753
- let box = null;
6754
- let body = document.querySelector('body');
6755
- box = document.createElement('div');
6756
- box.className = '_modal';
6757
- mask.current = box;
6758
- body?.appendChild(box);
6759
- let roots = createRoot(box);
6760
- roots.render( /*#__PURE__*/React__default.cloneElement(render()));
6761
- root.current = roots;
6762
- } else {
6763
- onClose();
6764
- }
6765
- }, [show]);
6766
- //重新渲染
6767
- useEffect(() => {
6768
- if (root.current) {
6769
- root.current.render( /*#__PURE__*/React__default.cloneElement(render()));
6770
- }
6771
- }, [root.current, ismax, minimize]);
6772
- useEffect(() => {
6773
- if (typeof minimize !== 'boolean') return;
6774
- onMinimize();
6775
- }, [minimize]);
6776
- //切换
6777
- useEffect(() => {
6778
- if (!mask?.current) return;
6779
- if (focus) {
6780
- mask.current.style.zIndex = 200;
6781
- content.current?.classList.add('focus');
6782
- } else {
6783
- mask.current.style.zIndex = '';
6784
- content.current?.classList.remove('focus');
6785
- }
6786
- }, [mask.current, focus]);
6787
- //焦点控制
6788
- useEffect(() => {
6789
- if (typeof isfocus == 'boolean') {
6790
- setFocus(isfocus);
6791
- }
6792
- }, [isfocus]);
6793
- //头
6794
- const header = useMemo(() => {
6795
- if (title === false) {
6796
- return jsx(Fragment, {});
6797
- }
6798
- if ( /*#__PURE__*/React__default.isValidElement(title)) {
6799
- return title;
6800
- }
6801
- return jsxs("div", {
6802
- className: '_modal-header',
6803
- onMouseDown: e => {
6804
- D_value([e.nativeEvent?.layerX || 0, e.nativeEvent?.layerY || 0]);
6805
- setDrag(true);
6806
- },
6807
- onMouseUp: () => {
6808
- setDrag(false);
6809
- },
6810
- children: [jsx("div", {
6811
- className: 'header-title',
6812
- children: title
6813
- }), jsxs("div", {
6814
- className: 'header-toolbar',
6815
- children: [jsx("span", {
6816
- className: 'tool',
6817
- onClick: () => {
6818
- onMin && onMin();
6819
- }
6820
- }), jsx("span", {
6821
- className: 'tool',
6822
- onClick: () => {
6823
- setMax(!ismax);
6824
- onMaximize();
6825
- }
6826
- }), jsx("span", {
6827
- className: 'tool close',
6828
- onClick: () => {
6829
- props.onClose && props.onClose();
6830
- }
6831
- })]
6832
- })]
6833
- });
6834
- }, [drag, title, ismax]);
6835
- function handleResize() {
6836
- setWinsize(getSize());
6837
- }
6838
- //最小化
6839
- function onMinimize() {
6840
- if (!minimize) {
6841
- content.current?.classList.add('animation');
6842
- content.current?.classList.add('minimize');
6843
- } else {
6844
- content.current?.classList.remove('minimize');
6845
- content.current?.classList.remove('animation');
6846
- }
6847
- }
6848
- //最大化
6849
- function onMaximize() {
6850
- if (!ismax) {
6851
- if (mask?.current) {
6852
- mask.current.style.bottom = '0px';
6853
- mask.current.style.zIndex = 300;
6854
- }
6855
- content.current?.classList.add('animation');
6856
- content.current?.classList.add('maximize');
6857
- } else {
6858
- content.current?.classList.remove('animation');
6859
- content.current?.classList.remove('maximize');
6860
- mask.current.style.bottom = '';
6861
- mask.current.style.zIndex = '';
6862
- }
6863
- }
6864
- function onClose() {
6865
- mask?.current?.remove();
6866
- mask.current == null;
6867
- content?.current?.remove();
6868
- content.current == null;
6869
- }
6870
- function getSize() {
6871
- return {
6872
- width: window?.innerWidth || 0,
6873
- height: window?.innerHeight || 0
6874
- };
6875
- }
6876
- const lie = e => {
6877
- if (ismax) return;
6878
- if (!drag) return;
6879
- let x = (e.x || 0) - d_value[0];
6880
- let y = (e.y || 0) - d_value[1];
6881
- if (!content?.current) return;
6882
- let c_lie = content.current.getBoundingClientRect();
6883
- if (x < 0) x = 0;
6884
- if (y < 0) y = 0;
6885
- if (y + c_lie.height > win_size.height) {
6886
- y = win_size.height - c_lie.height;
6887
- }
6888
- if (x + c_lie.width > win_size.width) {
6889
- x = win_size.width - c_lie.width;
6890
- }
6891
- content.current.style.top = y + 'px';
6892
- content.current.style.left = x + 'px';
6893
- return {
6894
- x,
6895
- y
6896
- };
6897
- };
6898
- function render() {
6899
- return jsxs("div", {
6900
- ref: content,
6901
- className: cx$1('_modal-content', {
6902
- minimize: minimize,
6903
- animation: minimize
6904
- }),
6905
- tabIndex: 0,
6906
- onFocus: () => {
6907
- onFocus && onFocus();
6908
- typeof isfocus == 'boolean' ? null : setFocus(true);
6909
- },
6910
- onBlur: () => {
6911
- typeof isfocus == 'boolean' ? null : setFocus(false);
6912
- onBlur && onBlur();
6913
- },
6914
- children: [props?.title && header, props.children]
6915
- });
6916
- }
6917
- return jsx(Fragment, {});
6918
- }
6919
-
6920
- function ModalTab(props) {
6921
- const {
6922
- items,
6923
- onClone,
6924
- showKey,
6925
- className
6926
- } = props;
6927
- const shrink = useRef(null);
6928
- const [show, setShow] = useState([]);
6929
- const [select, setSelect] = useState('');
6930
- const [_shrink, setShink] = useState([]);
6931
- useEffect(() => {
6932
- if (typeof showKey[0] == 'string') {
6933
- setSelect(showKey[0]);
6934
- }
6935
- }, []);
6936
- useEffect(() => {
6937
- setShow(showKey);
6938
- }, [showKey]);
6939
- return jsxs("div", {
6940
- className: cx$1('_modal-navbar', {
6941
- [className || '']: className
6942
- }),
6943
- children: [items.map((v, index) => {
6944
- return jsx(React__default.Fragment, {
6945
- children: jsx(Modal, {
6946
- tabIndex: index,
6947
- show: show.includes(v.key),
6948
- title: v.title,
6949
- onClose: () => {
6950
- onClone && onClone?.(v.key, v);
6951
- },
6952
- minimize: shrink.current?.includes(v.key),
6953
- onMinimize: () => {
6954
- let arr = [...(shrink.current || []), v.key];
6955
- shrink.current = arr;
6956
- setShink(arr);
6957
- },
6958
- isfocus: v.key == select,
6959
- onFocus: () => {
6960
- setSelect(v.key);
6961
- },
6962
- children: v.content
6963
- }, index)
6964
- }, index);
6965
- }), items.map((v, index) => {
6966
- return jsx("div", {
6967
- className: cx$1('_modal-navbar-item', {
6968
- acitve: select == v.key
6969
- }),
6970
- onClick: () => {
6971
- if (shrink.current?.includes(v.key)) {
6972
- let arr = shrink.current.filter(item => item !== v.key);
6973
- shrink.current = arr;
6974
- setShink(arr);
6975
- setSelect(v.key);
6976
- return;
6977
- }
6978
- if (select == v.key) {
6979
- let arr = [...(shrink.current || []), v.key];
6980
- shrink.current = arr;
6981
- setShink(arr);
6982
- setSelect('');
6983
- return;
6984
- }
6985
- if (!show.includes(v.key)) {
6986
- setShow([...show, v.key]);
6987
- }
6988
- setSelect(v.key);
6989
- },
6990
- children: v.title
6991
- }, index);
6992
- })]
6993
- });
6994
- }
6995
-
6996
6908
  const template = {
6997
6909
  tile: {
6998
6910
  action: 'rotate',
@@ -7025,7 +6937,8 @@ const Layout$1 = props => {
7025
6937
  onCheck,
7026
6938
  onDblclick,
7027
6939
  onRename,
7028
- onMenuClick
6940
+ onMenuClick,
6941
+ onUpload
7029
6942
  } = props;
7030
6943
  const store = useContext(ExampleContext);
7031
6944
  const [expandkey, setExpandkey] = useState([]);
@@ -7062,6 +6975,7 @@ const Layout$1 = props => {
7062
6975
  return jsxs("div", {
7063
6976
  className: 'file-continer-main',
7064
6977
  children: [store?.loading == ApiStatusEnum.LOADING && jsx(Loading, {}), jsxs(SelectBox, {
6978
+ getContainer: '.explorer-container',
7065
6979
  checks: checks,
7066
6980
  checkType: store.checkType,
7067
6981
  checkMode: store.checkMode,
@@ -7070,6 +6984,10 @@ const Layout$1 = props => {
7070
6984
  }),
7071
6985
  isDrag: isDrag,
7072
6986
  isSelectBoxes: isSelectBoxes,
6987
+ dataClass: template?.[store.menutype]?.dataClass,
6988
+ selectClass: template?.[store.menutype]?.selectClass,
6989
+ action: template?.[store.menutype]?.action,
6990
+ regionClass: template?.[store.menutype]?.regionClass,
7073
6991
  onChange: v => {
7074
6992
  let map = store.dataMap || {};
7075
6993
  let param = [];
@@ -7080,13 +6998,10 @@ const Layout$1 = props => {
7080
6998
  });
7081
6999
  onCheck?.(v, param);
7082
7000
  },
7001
+ onUpload: onUpload,
7083
7002
  onDrag: () => {},
7084
7003
  onEndDrag: () => {},
7085
7004
  onStartDrag: () => {},
7086
- dataClass: template?.[store.menutype]?.dataClass,
7087
- selectClass: template?.[store.menutype]?.selectClass,
7088
- action: template?.[store.menutype]?.action,
7089
- regionClass: template?.[store.menutype]?.regionClass,
7090
7005
  children: [store?.menutype == 'column' && jsx(Columns, {
7091
7006
  icons: store.getIcons,
7092
7007
  data: store.curlist,
@@ -7155,9 +7070,6 @@ const Layout$1 = props => {
7155
7070
  onMenuClick: onMenuClick,
7156
7071
  loadData: loadData
7157
7072
  })]
7158
- }), jsx(ModalTab, {
7159
- items: [],
7160
- showKey: []
7161
7073
  })]
7162
7074
  });
7163
7075
  };
@@ -7535,14 +7447,14 @@ const Explorer = props => {
7535
7447
  setCurSelect,
7536
7448
  setLoadKey
7537
7449
  },
7538
- children: jsxs("div", {
7450
+ children: jsx("div", {
7539
7451
  className: 'explorer-container',
7540
- children: [jsx(Layout, {
7452
+ children: jsx(Layout, {
7541
7453
  ...props,
7542
7454
  loadData: loadData,
7543
7455
  loadNode: loadNode,
7544
7456
  onRename: onRename
7545
- }), ";"]
7457
+ })
7546
7458
  })
7547
7459
  });
7548
7460
  };