@apple-pie/slice 0.1.24 → 0.1.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/dist/cjs/chunks/{AudioBubble-C8HdYBY8.js → AudioBubble-Bqb2Jexf.js} +1 -0
- package/dist/cjs/chunks/{Avatar-CUaQ3kN1.js → Avatar-Dg8ZHnw6.js} +1 -0
- package/dist/cjs/chunks/{AvatarGroup-B3M7o4Hh.js → AvatarGroup-F8eSiMwn.js} +2 -1
- package/dist/cjs/chunks/{Badge-CY_DG6cD.js → Badge-DjPJ_iJX.js} +1 -0
- package/dist/cjs/chunks/{Button-DmWbooXb.js → Button-D3wZtdtj.js} +2 -1
- package/dist/cjs/chunks/{ButtonBar-RSBwFaU-.js → ButtonBar-EH8fHFhS.js} +6 -5
- package/dist/cjs/chunks/{Camera-CLm3aQR8.js → Camera-BnsGhOrt.js} +2 -1
- package/dist/cjs/chunks/{CheckBox-DDINn56u.js → CheckBox-CEWLxffo.js} +2 -1
- package/dist/cjs/chunks/{Chip-DRSg6kLh.js → Chip-BrQgOmJc.js} +2 -1
- package/dist/cjs/chunks/{DivInput-DO3Dgbjp.js → DivInput-DWPwVUs_.js} +1 -0
- package/dist/cjs/chunks/{Dot-_HCJ3qxd.js → Dot-fKIwhjYA.js} +1 -0
- package/dist/cjs/chunks/{DrggablePanel-CERavfv3.js → DrggablePanel-Duv0nmOm.js} +22 -16
- package/dist/cjs/chunks/{DropDown-Cy2o78yw.js → DropDown-Bf_pm-Go.js} +2 -1
- package/dist/cjs/chunks/{ErrorSummary-BfVHS893.js → ErrorSummary-K_rPxGWK.js} +1 -0
- package/dist/cjs/chunks/{FileIcon-xoD-xIme.js → FileIcon-DgRlhqzv.js} +1 -0
- package/dist/cjs/chunks/{FileList-DjTXjXnK.js → FileList-DobAcOSH.js} +2 -1
- package/dist/cjs/chunks/{_types-Sa2RAJ2U.js → FlexDiv-C-3ahI-j.js} +79 -9
- package/dist/cjs/chunks/{Grouper-RYRxazG9.js → Grouper-D9G8PKoM.js} +2 -1
- package/dist/cjs/chunks/{Icon-BB-t50Yt.js → Icon-fRM3E0N6.js} +20 -3
- package/dist/cjs/chunks/{IconButton-BUw3YUsI.js → IconButton-Cf2RBUKA.js} +7 -6
- package/dist/cjs/chunks/{Label-NzMpkZo2.js → Label-Bxp2pCXf.js} +1 -0
- package/dist/cjs/chunks/{Overlay-BX6vXX9F.js → Overlay-DDOvMM6L.js} +1 -0
- package/dist/cjs/chunks/{Pager-BN37VYEC.js → Pager-DO197OyC.js} +1 -0
- package/dist/cjs/chunks/{ProgressIndicator-8QZwTSyY.js → ProgressIndicator-t-jv4OhI.js} +2 -1
- package/dist/cjs/chunks/{PromptInput-D1wP5-uN.js → PromptInput-B1WG22xz.js} +2 -1
- package/dist/cjs/chunks/{RadioButton-Cvqum7dU.js → RadioButton-BAIMCshV.js} +2 -1
- package/dist/cjs/chunks/{RadioButtonList-CPHTioGa.js → RadioButtonList-Bsg5oFaC.js} +2 -1
- package/dist/cjs/chunks/{Slider-CnXBacf-.js → Slider-BAcaZUs2.js} +1 -0
- package/dist/cjs/chunks/{Spacer-CtxV2Pww.js → Spacer-CyZAUR5N.js} +1 -0
- package/dist/cjs/chunks/{Switch-Cbn0ql3B.js → Switch-Crm-nHYI.js} +1 -0
- package/dist/cjs/chunks/{TabBar-CnD3E-qa.js → TabBar-BfyfjmPQ.js} +2 -1
- package/dist/cjs/chunks/{TextArea-CtJi771p.js → TextArea-CHNWsfWH.js} +2 -1
- package/dist/cjs/chunks/{TextField-B2u_CZKk.js → TextField-2xzSdIx3.js} +2 -1
- package/dist/cjs/chunks/{Tip-DAxoyMyA.js → Tip-DceuNR6k.js} +1 -0
- package/dist/cjs/chunks/{Toast-D2fpwdjF.js → Toast-C8Hc9ZKI.js} +2 -1
- package/dist/cjs/chunks/{UploadArea-BS2BPuhZ.js → UploadArea-UFWRQ-nW.js} +2 -1
- package/dist/cjs/chunks/{_types-BD6txsj1.js → _types-VoADvwjb.js} +1 -0
- package/dist/cjs/components/AudioBubble/index.js +1 -1
- package/dist/cjs/components/Avatar/index.js +1 -1
- package/dist/cjs/components/AvatarGroup/index.js +2 -2
- package/dist/cjs/components/Badge/index.js +1 -1
- package/dist/cjs/components/Button/index.js +4 -4
- package/dist/cjs/components/ButtonBar/index.js +2 -2
- package/dist/cjs/components/Camera/index.js +3 -3
- package/dist/cjs/components/CheckBox/index.js +2 -2
- package/dist/cjs/components/Chip/index.js +2 -2
- package/dist/cjs/components/DivInput/index.js +1 -1
- package/dist/cjs/components/Dot/index.js +1 -1
- package/dist/cjs/components/DraggablePanel/index.js +1 -1
- package/dist/cjs/components/DropDown/index.js +2 -2
- package/dist/cjs/components/ErrorSummary/index.js +1 -1
- package/dist/cjs/components/FileIcon/index.js +1 -1
- package/dist/cjs/components/FileList/index.js +4 -4
- package/dist/cjs/components/FlexDiv/index.js +9 -4
- package/dist/cjs/components/Grouper/index.js +3 -3
- package/dist/cjs/components/Icon/index.js +1 -1
- package/dist/cjs/components/IconButton/index.js +3 -3
- package/dist/cjs/components/Label/index.js +1 -1
- package/dist/cjs/components/Overlay/index.js +1 -1
- package/dist/cjs/components/Pager/index.js +1 -1
- package/dist/cjs/components/Progress/index.js +2 -2
- package/dist/cjs/components/PromptInput/index.js +7 -7
- package/dist/cjs/components/RadioButton/index.js +2 -2
- package/dist/cjs/components/RadioButtonList/index.js +3 -3
- package/dist/cjs/components/Slider/index.js +1 -1
- package/dist/cjs/components/Spacer/index.js +1 -1
- package/dist/cjs/components/Switch/index.js +1 -1
- package/dist/cjs/components/TabBar/index.js +4 -4
- package/dist/cjs/components/TextArea/index.js +5 -5
- package/dist/cjs/components/Textfield/index.js +6 -6
- package/dist/cjs/components/Tip/index.js +1 -1
- package/dist/cjs/components/Toast/index.js +2 -2
- package/dist/cjs/components/UploadArea/index.js +5 -5
- package/dist/cjs/hooks/useAudioRecorder.js +1 -0
- package/dist/cjs/hooks/useDoubleClick.js +1 -0
- package/dist/cjs/hooks/useKeyboardShortcuts.js +1 -0
- package/dist/cjs/hooks/useLastUpdated.js +1 -0
- package/dist/cjs/hooks/useLocalStore.js +1 -0
- package/dist/cjs/hooks/useMdStreamBuffer.js +1 -0
- package/dist/cjs/hooks/useMicrophone.js +1 -0
- package/dist/cjs/hooks/useObserveResize.js +1 -0
- package/dist/cjs/hooks/useObserveTheme.js +1 -0
- package/dist/cjs/hooks/useTheme.js +1 -0
- package/dist/cjs/hooks/useToolTip.js +1 -0
- package/dist/cjs/hooks/useTrackRenders.js +1 -0
- package/dist/cjs/hooks/useWindow.js +2 -0
- package/dist/cjs/index.js +11 -6
- package/dist/cjs/providers/ThemeProvider.js +11 -9
- package/dist/cjs/providers/themeServer.js +24 -0
- package/dist/cjs/providers.js +3 -2
- package/dist/esm/chunks/{AudioBubble-DFh3Vxl6.mjs → AudioBubble-DZfzkdlq.mjs} +1 -0
- package/dist/esm/chunks/{Avatar-C8uV7ROZ.mjs → Avatar-m5-zleDk.mjs} +1 -0
- package/dist/esm/chunks/{AvatarGroup-Bt1Lkn5S.mjs → AvatarGroup-DlgP4lTS.mjs} +2 -1
- package/dist/esm/chunks/{Badge-D-U1jomY.mjs → Badge-CC0zSLMf.mjs} +1 -0
- package/dist/esm/chunks/{Button-sEYjFcR2.mjs → Button-YER9dCLE.mjs} +5 -4
- package/dist/esm/chunks/{ButtonBar-DSR2lhhN.mjs → ButtonBar-BH4pcEpN.mjs} +6 -5
- package/dist/esm/chunks/{Camera-DSSiOeJd.mjs → Camera-BJJpDuuA.mjs} +3 -2
- package/dist/esm/chunks/{CheckBox-B6zWSySW.mjs → CheckBox-Cf2l3-D9.mjs} +2 -1
- package/dist/esm/chunks/{Chip-BBKJ6wG4.mjs → Chip-DWp7p2BF.mjs} +2 -1
- package/dist/esm/chunks/{DivInput-cIMIH07H.mjs → DivInput-WJltaCra.mjs} +1 -0
- package/dist/esm/chunks/{Dot-Cj6gWj4_.mjs → Dot-DZE134mJ.mjs} +1 -0
- package/dist/esm/chunks/{DrggablePanel-CQcIbxpX.mjs → DrggablePanel-DA7pYWg6.mjs} +22 -16
- package/dist/esm/chunks/{DropDown-DFUc_rjP.mjs → DropDown-BQ2tNN3_.mjs} +2 -1
- package/dist/esm/chunks/{ErrorSummary-Mz9siVxm.mjs → ErrorSummary-EzCqVifm.mjs} +1 -0
- package/dist/esm/chunks/{FileIcon-DeW-ZBiv.mjs → FileIcon-Cufsp1gn.mjs} +1 -0
- package/dist/esm/chunks/{FileList-0Dzx15hl.mjs → FileList-BQ9X5YnB.mjs} +4 -3
- package/dist/esm/chunks/{_types-DOQAaLqq.mjs → FlexDiv-BFrVoFhC.mjs} +82 -13
- package/dist/esm/chunks/{Grouper-B04WxD6K.mjs → Grouper-CvPYEsF_.mjs} +3 -2
- package/dist/esm/chunks/{Icon-KDwlMXzH.mjs → Icon-DI32kOA1.mjs} +20 -3
- package/dist/esm/chunks/{IconButton-oAB8ZFTf.mjs → IconButton-Dciw5CLn.mjs} +9 -8
- package/dist/esm/chunks/{Label-BD7VlTDw.mjs → Label-CvCDAg1y.mjs} +1 -0
- package/dist/esm/chunks/{Overlay-3KkyDm1f.mjs → Overlay-DiSvgIQP.mjs} +1 -0
- package/dist/esm/chunks/{Pager-DmiwYLl5.mjs → Pager-BoDLaKFh.mjs} +1 -0
- package/dist/esm/chunks/{ProgressIndicator-CxsZm_As.mjs → ProgressIndicator-CB_oazMD.mjs} +2 -1
- package/dist/esm/chunks/{PromptInput-D4Q-DWjz.mjs → PromptInput-plgRiAb7.mjs} +3 -2
- package/dist/esm/chunks/{RadioButton-B0jvM5VW.mjs → RadioButton-B6ImCUYY.mjs} +2 -1
- package/dist/esm/chunks/{RadioButtonList-DBRAv87_.mjs → RadioButtonList-Cf6gk8yp.mjs} +2 -1
- package/dist/esm/chunks/{Slider-CONGTXUE.mjs → Slider-Cav86rU6.mjs} +1 -0
- package/dist/esm/chunks/{Spacer-C5fcJYq-.mjs → Spacer-C5651N0N.mjs} +1 -0
- package/dist/esm/chunks/{Switch-CyoaJwSX.mjs → Switch-RfA431T4.mjs} +1 -0
- package/dist/esm/chunks/{TabBar-DmO1ixBz.mjs → TabBar-0zpJ9GtN.mjs} +4 -3
- package/dist/esm/chunks/{TextArea-DaB8g-fZ.mjs → TextArea-B64bIPHm.mjs} +2 -1
- package/dist/esm/chunks/{TextField-BGeEJXUJ.mjs → TextField-BZeoN_ye.mjs} +4 -3
- package/dist/esm/chunks/{Tip-DrQvxDsH.mjs → Tip-C5LB54J9.mjs} +1 -0
- package/dist/esm/chunks/{Toast-C5XSDgno.mjs → Toast-Bl4s4tRo.mjs} +2 -1
- package/dist/esm/chunks/{UploadArea-Gpq-MhqB.mjs → UploadArea-D3g2g1LK.mjs} +4 -3
- package/dist/esm/chunks/{_types-C2C2Zwd0.mjs → _types-DeEhv4Y5.mjs} +1 -0
- package/dist/esm/components/AudioBubble/index.mjs +1 -1
- package/dist/esm/components/Avatar/index.mjs +1 -1
- package/dist/esm/components/AvatarGroup/index.mjs +2 -2
- package/dist/esm/components/Badge/index.mjs +1 -1
- package/dist/esm/components/Button/index.mjs +5 -5
- package/dist/esm/components/ButtonBar/index.mjs +2 -2
- package/dist/esm/components/Camera/index.mjs +3 -3
- package/dist/esm/components/CheckBox/index.mjs +2 -2
- package/dist/esm/components/Chip/index.mjs +2 -2
- package/dist/esm/components/DivInput/index.mjs +1 -1
- package/dist/esm/components/Dot/index.mjs +1 -1
- package/dist/esm/components/DraggablePanel/index.mjs +1 -1
- package/dist/esm/components/DropDown/index.mjs +2 -2
- package/dist/esm/components/ErrorSummary/index.mjs +1 -1
- package/dist/esm/components/FileIcon/index.mjs +1 -1
- package/dist/esm/components/FileList/index.mjs +4 -4
- package/dist/esm/components/FlexDiv/index.mjs +1 -1
- package/dist/esm/components/Grouper/index.mjs +3 -3
- package/dist/esm/components/Icon/index.mjs +2 -2
- package/dist/esm/components/IconButton/index.mjs +4 -4
- package/dist/esm/components/Label/index.mjs +1 -1
- package/dist/esm/components/Overlay/index.mjs +1 -1
- package/dist/esm/components/Pager/index.mjs +1 -1
- package/dist/esm/components/Progress/index.mjs +2 -2
- package/dist/esm/components/PromptInput/index.mjs +8 -8
- package/dist/esm/components/RadioButton/index.mjs +2 -2
- package/dist/esm/components/RadioButtonList/index.mjs +3 -3
- package/dist/esm/components/Slider/index.mjs +1 -1
- package/dist/esm/components/Spacer/index.mjs +1 -1
- package/dist/esm/components/Switch/index.mjs +1 -1
- package/dist/esm/components/TabBar/index.mjs +5 -5
- package/dist/esm/components/TextArea/index.mjs +6 -6
- package/dist/esm/components/Textfield/index.mjs +7 -7
- package/dist/esm/components/Tip/index.mjs +1 -1
- package/dist/esm/components/Toast/index.mjs +2 -2
- package/dist/esm/components/UploadArea/index.mjs +5 -5
- package/dist/esm/hooks/useAudioRecorder.mjs +1 -0
- package/dist/esm/hooks/useDoubleClick.mjs +1 -0
- package/dist/esm/hooks/useKeyboardShortcuts.mjs +1 -0
- package/dist/esm/hooks/useLastUpdated.mjs +1 -0
- package/dist/esm/hooks/useLocalStore.mjs +1 -0
- package/dist/esm/hooks/useMdStreamBuffer.mjs +1 -0
- package/dist/esm/hooks/useMicrophone.mjs +1 -0
- package/dist/esm/hooks/useObserveResize.mjs +1 -0
- package/dist/esm/hooks/useObserveTheme.mjs +1 -0
- package/dist/esm/hooks/useTheme.mjs +1 -0
- package/dist/esm/hooks/useToolTip.mjs +1 -0
- package/dist/esm/hooks/useTrackRenders.mjs +1 -0
- package/dist/esm/hooks/useWindow.mjs +2 -0
- package/dist/esm/index.mjs +37 -37
- package/dist/esm/providers/ThemeProvider.mjs +12 -9
- package/dist/esm/providers/themeServer.mjs +24 -0
- package/dist/esm/providers.mjs +2 -0
- package/dist/types/components/ButtonBar/_types.d.ts +2 -1
- package/dist/types/components/FlexDiv/FlexDiv.d.ts +2 -0
- package/dist/types/components/FlexDiv/_types.d.ts +77 -0
- package/dist/types/components/FlexDiv/index.d.ts +1 -1
- package/dist/types/components/Icon/_types.d.ts +2 -1
- package/dist/types/components/Icon/iconRegistry.d.ts +1 -1
- package/dist/types/components/IconButton/_types.d.ts +3 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/providers/ThemeProvider.d.ts +1 -0
- package/dist/types/providers/index.d.ts +1 -0
- package/dist/types/providers/themeServer.d.ts +19 -0
- package/package.json +2 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
@@ -20,6 +21,21 @@ var css_panel = "DraggablePanel-module_panel__vuq2R flexBox-module_columnStart__
|
|
|
20
21
|
|
|
21
22
|
styleInject(".flexBox-module_row__z24tF {\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_rowBetween__5FEvi {\n\tdisplay: flex;\n\tjustify-content: space-between;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_rowStart__4tcxS {\n\tdisplay: flex;\n\tjustify-content: flex-start;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_rowEnd__rVdVm {\n\tdisplay: flex;\n\tjustify-content: flex-end;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_column__ezvMq {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: center;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnStart__C7P44 {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: flex-start;\n\talign-items: flex-start;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnStartCenter__PKcrG {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: flex-start;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnBetween__ERfp7 {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: space-between;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnEnd__lLJuc {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: flex-end;\n\talign-items: flex-end;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}\n\n.DraggablePanel-module_panel__vuq2R {\n\tposition: relative;\n\tbackground-color: var(--panel-bg);\n}\n\n.DraggablePanel-module_content__SBL0T {\n\twidth: 100%;\n\theight: 100%;\n\toverflow: hidden;\n}\n\n.DraggablePanel-module_handle__LPZw8 {\n\twidth: var(--drag-handle-width);\n\theight: var(--drag-handle-height);\n\tmin-width: var(--drag-handle-width);\n\tmin-height: var(--drag-handle-height);\n\tborder-radius: var(--drag-handle-radius);\n\tborder: var(--drag-handle-border) solid var(--drag-handle-border-color);\n\tbackground: var(--drag-handle-bg);\n\tposition: absolute;\n\ttop: 50%;\n\tleft: 50%;\n\ttransform: translateX(-50%) translateY(-50%);\n\tz-index: 15000;\n}\n");
|
|
22
23
|
|
|
24
|
+
function normalizeConstraintValue(value, containerWidth, fallback) {
|
|
25
|
+
let normalized = value;
|
|
26
|
+
return normalized <= 1 && normalized >= 0 && (normalized = containerWidth ? containerWidth * normalized : fallback),
|
|
27
|
+
normalized > 1 && normalized < 50 && (normalized = 50), normalized;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function resolveConstraints(sizeConstraints, containerWidth) {
|
|
31
|
+
const initial = normalizeConstraintValue(sizeConstraints.initial, containerWidth, 50), min = normalizeConstraintValue(sizeConstraints.min, containerWidth, initial);
|
|
32
|
+
return {
|
|
33
|
+
initial: min > initial ? min : initial,
|
|
34
|
+
min: min,
|
|
35
|
+
max: normalizeConstraintValue(sizeConstraints.max, containerWidth, initial)
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
|
|
23
39
|
const DraggablePanel = React.memo(props => {
|
|
24
40
|
const theme = useTheme(), {children: children, sizeConstraints: sizeConstraints = {
|
|
25
41
|
initial: 250,
|
|
@@ -29,7 +45,7 @@ const DraggablePanel = React.memo(props => {
|
|
|
29
45
|
width: 10,
|
|
30
46
|
color: "transparent",
|
|
31
47
|
offsetX: !0
|
|
32
|
-
}, borderRight: borderRight = "1px solid var(--core-outline-primary)", borderLeft: borderLeft = null, bgColor: bgColor = "transparent", drags: drags = !0, isTouchDevice: isTouchDevice = !1, disableOnContext: disableOnContext = !0, dragHandle: dragHandle = !0, dragHandleStyle: dragHandleStyle, containerRef: containerRef, onResize: onResize = () => null, onResizeStart: onResizeStart = () => null, onResizeEnd: onResizeEnd = () => null} = props, divAttributes = __rest(props, [ "children", "sizeConstraints", "dragsRight", "isClosed", "resizeHandle", "borderRight", "borderLeft", "bgColor", "drags", "isTouchDevice", "disableOnContext", "dragHandle", "dragHandleStyle", "containerRef", "onResize", "onResizeStart", "onResizeEnd" ]), {id: divId, className: className, style: style} = divAttributes, rest = __rest(divAttributes, [ "id", "className", "style" ]), divStyle = null != style ? style : {}, divClass = className ? ` ${className}` : "", handle = useRef(null), div = useRef(null), [isDragging, setIsDragging] = useState(!1), isOver = useRef(!1), gripper = Object.assign({}, resizeHandle), containerSize = useObserveResize(containerRef), [handleHighlight, setHandleHighlight] = useState(!1), [lastWidth, setLastWidth] = useState(null), [panelClosed, setPanelClosed] = useState(isClosed), [constraints, setConstraints] = useState(sizeConstraints), [contWidth, setContWidth] = useState(void 0), timer = useRef(null), startX = useRef(0), startWidth = useRef(0), divWidth = useRef(0), divHeight = useRef(0), deltaWidth = useRef(0), handleWindowResize = useCallback(() => {
|
|
48
|
+
}, borderRight: borderRight = "1px solid var(--core-outline-primary)", borderLeft: borderLeft = null, bgColor: bgColor = "transparent", drags: drags = !0, isTouchDevice: isTouchDevice = !1, disableOnContext: disableOnContext = !0, dragHandle: dragHandle = !0, dragHandleStyle: dragHandleStyle, containerRef: containerRef, onResize: onResize = () => null, onResizeStart: onResizeStart = () => null, onResizeEnd: onResizeEnd = () => null} = props, divAttributes = __rest(props, [ "children", "sizeConstraints", "dragsRight", "isClosed", "resizeHandle", "borderRight", "borderLeft", "bgColor", "drags", "isTouchDevice", "disableOnContext", "dragHandle", "dragHandleStyle", "containerRef", "onResize", "onResizeStart", "onResizeEnd" ]), {id: divId, className: className, style: style} = divAttributes, rest = __rest(divAttributes, [ "id", "className", "style" ]), divStyle = null != style ? style : {}, divClass = className ? ` ${className}` : "", handle = useRef(null), div = useRef(null), [isDragging, setIsDragging] = useState(!1), isOver = useRef(!1), gripper = Object.assign({}, resizeHandle), containerSize = useObserveResize(containerRef), panelSize = useObserveResize(div), [handleHighlight, setHandleHighlight] = useState(!1), [lastWidth, setLastWidth] = useState(null), [panelClosed, setPanelClosed] = useState(isClosed), [constraints, setConstraints] = useState(() => resolveConstraints(sizeConstraints)), [contWidth, setContWidth] = useState(void 0), timer = useRef(null), closed = panelSize.width <= 1, startX = useRef(0), startWidth = useRef(0), divWidth = useRef(0), divHeight = useRef(0), deltaWidth = useRef(0), handleWindowResize = useCallback(() => {
|
|
33
49
|
(null == containerRef ? void 0 : containerRef.current) || setContWidth(window.innerWidth);
|
|
34
50
|
}, [ containerRef ]), handleMouseOver = useCallback(() => {
|
|
35
51
|
isOver.current = !0, setHighlight(!0);
|
|
@@ -57,17 +73,7 @@ const DraggablePanel = React.memo(props => {
|
|
|
57
73
|
}, []);
|
|
58
74
|
useEffect(() => {
|
|
59
75
|
if (!contWidth) return;
|
|
60
|
-
const
|
|
61
|
-
min: min,
|
|
62
|
-
max: max,
|
|
63
|
-
initial: initial
|
|
64
|
-
};
|
|
65
|
-
for (const [key, value] of Object.entries(sizeConstraints)) {
|
|
66
|
-
let calc = value;
|
|
67
|
-
calc <= 1 && calc >= 0 && (calc = contWidth * value), calc > 1 && calc < 50 && (calc = 50),
|
|
68
|
-
relativeConstraints[key] = calc;
|
|
69
|
-
}
|
|
70
|
-
relativeConstraints.min < relativeConstraints.initial && (relativeConstraints.initial = relativeConstraints.min),
|
|
76
|
+
const relativeConstraints = resolveConstraints(sizeConstraints, contWidth);
|
|
71
77
|
setConstraints(relativeConstraints), adjustCurrentWidth(relativeConstraints);
|
|
72
78
|
}, [ sizeConstraints, contWidth, adjustCurrentWidth ]);
|
|
73
79
|
const setHighlight = useCallback(state => {
|
|
@@ -154,8 +160,8 @@ const DraggablePanel = React.memo(props => {
|
|
|
154
160
|
height: "100%",
|
|
155
161
|
maxWidth: drags ? constraints.max : "unset",
|
|
156
162
|
transition: isDragging ? "" : transition,
|
|
157
|
-
borderRight: !
|
|
158
|
-
borderLeft: !
|
|
163
|
+
borderRight: !closed && borderRight && drags ? borderRight : "none",
|
|
164
|
+
borderLeft: !closed && borderLeft && drags ? borderLeft : "none"
|
|
159
165
|
})
|
|
160
166
|
}, rest, {
|
|
161
167
|
children: [ jsxs("div", {
|
|
@@ -163,7 +169,7 @@ const DraggablePanel = React.memo(props => {
|
|
|
163
169
|
style: Object.assign(Object.assign({
|
|
164
170
|
position: "absolute",
|
|
165
171
|
boxSizing: "border-box",
|
|
166
|
-
display:
|
|
172
|
+
display: closed || !drags ? "none" : "flex",
|
|
167
173
|
alignItems: "center",
|
|
168
174
|
justifyContent: "center",
|
|
169
175
|
zIndex: 1,
|
|
@@ -181,7 +187,7 @@ const DraggablePanel = React.memo(props => {
|
|
|
181
187
|
onBlur: handleBlur,
|
|
182
188
|
onTouchStart: handleTouchStart,
|
|
183
189
|
onTouchEnd: handleTouchEnd,
|
|
184
|
-
children: [ dragHandle && !
|
|
190
|
+
children: [ dragHandle && !closed && jsx(DragHandle, Object.assign({}, null != dragHandleStyle ? dragHandleStyle : {})), jsx("div", {
|
|
185
191
|
style: {
|
|
186
192
|
backgroundColor: handleHighlight ? theme.current.colors["core-outline-primary"] : "transparent",
|
|
187
193
|
flex: 1,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -6,7 +7,7 @@ import React, { useState, useRef, useEffect, useCallback, useMemo } from "react"
|
|
|
6
7
|
|
|
7
8
|
import { s as setStyle } from "./misc-BeEWwOaJ.mjs";
|
|
8
9
|
|
|
9
|
-
import { I as Icon } from "./Icon-
|
|
10
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
10
11
|
|
|
11
12
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
12
13
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -6,11 +7,11 @@ import React, { useCallback, useMemo } from "react";
|
|
|
6
7
|
|
|
7
8
|
import { s as setStyle, a as accessibleKeyDown } from "./misc-BeEWwOaJ.mjs";
|
|
8
9
|
|
|
9
|
-
import { F as FileIcon } from "./FileIcon-
|
|
10
|
+
import { F as FileIcon } from "./FileIcon-Cufsp1gn.mjs";
|
|
10
11
|
|
|
11
|
-
import { I as Icon } from "./Icon-
|
|
12
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
12
13
|
|
|
13
|
-
import { P as ProgressIndicator } from "./ProgressIndicator-
|
|
14
|
+
import { P as ProgressIndicator } from "./ProgressIndicator-CB_oazMD.mjs";
|
|
14
15
|
|
|
15
16
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
16
17
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsx } from "react/jsx-runtime";
|
|
@@ -8,7 +9,84 @@ import React, { useMemo } from "react";
|
|
|
8
9
|
|
|
9
10
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
10
11
|
|
|
11
|
-
var css_flexDiv = "FlexDiv-module_flexDiv__EY5A- type-module_body-m-regular__LuQBA";
|
|
12
|
+
var Size, Preset, css_flexDiv = "FlexDiv-module_flexDiv__EY5A- type-module_body-m-regular__LuQBA";
|
|
13
|
+
|
|
14
|
+
styleInject(".type-module_body-xs-regular__ZAFft {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-xs-medium__s3KvF {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-xs-bold__Lhqqq {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.25px;\n}.type-module_body-s-regular__vRHSP {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-s-medium__tjdFc {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-s-bold__Iy-VX {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-m-regular__LuQBA {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-m-medium__uW1on {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-m-bold__UBcvQ {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-l-regular__lOYbg {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-l-medium__BqRC7 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-l-bold__Fh2dt {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-xl-regular__pF2kC {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-xl-medium__BeyrH {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-xl-bold__Ruknj {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_heading-s-medium__z8L3G {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 20px;\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-s-bold__0O3g6 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 20px;\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-m-bold__KXxEB {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 24px;\n\tline-height: 116.67%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-m-medium__cJeEA {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 24px;\n\tline-height: 116.67%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-l-medium__eRe05 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 30px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-l-bold__Xmwtf {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 30px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-xl-medium__5q1m3 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 36px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-xl-bold__k9VFV {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 36px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.FlexDiv-module_flexDiv__EY5A- {\n\t&::-webkit-scrollbar {\n\t\tbackground-color: var(--flex-div-bg);\n\t\twidth: 14px;\n\t}\n\n\t&::-webkit-scrollbar-track {\n\t\tbackground-color: var(--flex-div-scroll-border);\n\t}\n\n\t&::-webkit-scrollbar-thumb {\n\t\tbackground-color: var(--flex-div-scroll-handle);\n\t\tborder-radius: 20px;\n\t\tborder: 4px solid var(--flex-div-scroll-border);\n\t}\n\n\t&::-webkit-scrollbar-thumb:hover {\n\t\tbackground-color: var(--flex-div-scroll-handle-hover);\n\t\tborder-radius: 20px;\n\t\tborder: 4px solid var(--flex-div-scroll-border);\n\t\tcursor: default;\n\t}\n}\n"),
|
|
15
|
+
function(Size) {
|
|
16
|
+
Size.Grow = "grow", Size.Fill = "fill", Size.Fit = "fit", Size.Viewport = "viewport",
|
|
17
|
+
Size.Auto = "auto";
|
|
18
|
+
}(Size || (Size = {})), function(Preset) {
|
|
19
|
+
Preset.FillScroll = "fill-scroll", Preset.FillCenter = "fill-center", Preset.Window = "window",
|
|
20
|
+
Preset.Row = "row", Preset.RowBetween = "row-between", Preset.Column = "fill-column",
|
|
21
|
+
Preset.Default = "default", Preset.Draggable = "draggable";
|
|
22
|
+
}(Preset || (Preset = {}));
|
|
23
|
+
|
|
24
|
+
const layoutSets = {
|
|
25
|
+
[Preset.FillScroll]: {
|
|
26
|
+
width: "fill",
|
|
27
|
+
height: "fill",
|
|
28
|
+
justify: "start",
|
|
29
|
+
align: "start",
|
|
30
|
+
scrollY: !0,
|
|
31
|
+
direction: "column"
|
|
32
|
+
},
|
|
33
|
+
[Preset.FillCenter]: {
|
|
34
|
+
width: "fill",
|
|
35
|
+
height: "fill",
|
|
36
|
+
justify: "center",
|
|
37
|
+
align: "center",
|
|
38
|
+
scrollY: !1,
|
|
39
|
+
direction: "column"
|
|
40
|
+
},
|
|
41
|
+
[Preset.Window]: {
|
|
42
|
+
width: "viewport",
|
|
43
|
+
height: "viewport",
|
|
44
|
+
justify: "start",
|
|
45
|
+
align: "start",
|
|
46
|
+
scrollY: !1,
|
|
47
|
+
direction: "row"
|
|
48
|
+
},
|
|
49
|
+
[Preset.Row]: {
|
|
50
|
+
width: "fill",
|
|
51
|
+
height: "fit",
|
|
52
|
+
justify: "start",
|
|
53
|
+
align: "center",
|
|
54
|
+
scrollY: !1,
|
|
55
|
+
direction: "row"
|
|
56
|
+
},
|
|
57
|
+
[Preset.RowBetween]: {
|
|
58
|
+
width: "fill",
|
|
59
|
+
height: "fit",
|
|
60
|
+
justify: "between",
|
|
61
|
+
align: "center",
|
|
62
|
+
scrollY: !1,
|
|
63
|
+
direction: "row"
|
|
64
|
+
},
|
|
65
|
+
[Preset.Column]: {
|
|
66
|
+
width: "fill",
|
|
67
|
+
height: "fit",
|
|
68
|
+
justify: "start",
|
|
69
|
+
align: "center",
|
|
70
|
+
scrollY: !1,
|
|
71
|
+
direction: "column"
|
|
72
|
+
},
|
|
73
|
+
[Preset.Default]: {
|
|
74
|
+
width: "fill",
|
|
75
|
+
height: "fit",
|
|
76
|
+
justify: "start",
|
|
77
|
+
align: "start",
|
|
78
|
+
scrollY: !1,
|
|
79
|
+
direction: "column"
|
|
80
|
+
},
|
|
81
|
+
[Preset.Draggable]: {
|
|
82
|
+
width: "auto",
|
|
83
|
+
height: "fill",
|
|
84
|
+
justify: "start",
|
|
85
|
+
align: "start",
|
|
86
|
+
scrollY: !1,
|
|
87
|
+
direction: "column"
|
|
88
|
+
}
|
|
89
|
+
};
|
|
12
90
|
|
|
13
91
|
function setSize(style, isHeight) {
|
|
14
92
|
return "number" == typeof style ? `${style}px` : "grow" === style ? "unset" : "fill" === style ? "100%" : "fit" === style ? "auto" : "viewport" === style ? isHeight ? "100vh" : "100vw" : style;
|
|
@@ -22,10 +100,8 @@ function setFlex(style) {
|
|
|
22
100
|
return "start" === style || "top" === style ? "flex-start" : "end" === style || "bottom" === style ? "flex-end" : "between" === style ? "space-between" : style;
|
|
23
101
|
}
|
|
24
102
|
|
|
25
|
-
styleInject(".type-module_body-xs-regular__ZAFft {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-xs-medium__s3KvF {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-xs-bold__Lhqqq {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.25px;\n}.type-module_body-s-regular__vRHSP {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-s-medium__tjdFc {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-s-bold__Iy-VX {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-m-regular__LuQBA {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-m-medium__uW1on {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-m-bold__UBcvQ {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-l-regular__lOYbg {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-l-medium__BqRC7 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-l-bold__Fh2dt {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-xl-regular__pF2kC {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-xl-medium__BeyrH {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-xl-bold__Ruknj {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_heading-s-medium__z8L3G {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 20px;\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-s-bold__0O3g6 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 20px;\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-m-bold__KXxEB {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 24px;\n\tline-height: 116.67%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-m-medium__cJeEA {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 24px;\n\tline-height: 116.67%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-l-medium__eRe05 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 30px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-l-bold__Xmwtf {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 30px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-xl-medium__5q1m3 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 36px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-xl-bold__k9VFV {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 36px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.FlexDiv-module_flexDiv__EY5A- {\n\t&::-webkit-scrollbar {\n\t\tbackground-color: var(--flex-div-bg);\n\t\twidth: 14px;\n\t}\n\n\t&::-webkit-scrollbar-track {\n\t\tbackground-color: var(--flex-div-scroll-border);\n\t}\n\n\t&::-webkit-scrollbar-thumb {\n\t\tbackground-color: var(--flex-div-scroll-handle);\n\t\tborder-radius: 20px;\n\t\tborder: 4px solid var(--flex-div-scroll-border);\n\t}\n\n\t&::-webkit-scrollbar-thumb:hover {\n\t\tbackground-color: var(--flex-div-scroll-handle-hover);\n\t\tborder-radius: 20px;\n\t\tborder: 4px solid var(--flex-div-scroll-border);\n\t\tcursor: default;\n\t}\n}\n");
|
|
26
|
-
|
|
27
103
|
const FlexDiv = React.memo(React.forwardRef((props, ref) => {
|
|
28
|
-
const {children: children, scrollY: scrollY =
|
|
104
|
+
const {children: children, preset: preset = "default", scrollY: scrollY = layoutSets[preset].scrollY, scrollX: scrollX = !1, background: background = "var(--core-surface-primary)", direction: direction = layoutSets[preset].direction, align: align = layoutSets[preset].align, justify: justify = layoutSets[preset].justify, height: height = layoutSets[preset].height, width: width = layoutSets[preset].width, maxWidth: maxWidth, centerSelf: centerSelf, wrap: wrap = !1, reverse: reverse = !1, padding: padding = 0, margin: margin = 0, absolute: absolute = !1, flex: flex, gap: gap, variants: variants, transition: transition, animate: animate, enter: enter, exit: exit, border: border, borderRadius: borderRadius, className: className, scrollHandle: scrollHandle, scrollHandleHover: scrollHandleHover} = props, divAttributes = __rest(props, [ "children", "preset", "scrollY", "scrollX", "background", "direction", "align", "justify", "height", "width", "maxWidth", "centerSelf", "wrap", "reverse", "padding", "margin", "absolute", "flex", "gap", "variants", "transition", "animate", "enter", "exit", "border", "borderRadius", "className", "scrollHandle", "scrollHandleHover" ]), {id: divId, style: userStyle} = divAttributes, rest = __rest(divAttributes, [ "id", "style" ]), wrapperStyle = null != userStyle ? userStyle : {}, style = useMemo(() => ({
|
|
29
105
|
display: "flex",
|
|
30
106
|
position: "" + (absolute ? "absolute" : "relative"),
|
|
31
107
|
flexDirection: `${direction}${reverse ? "-reverse" : ""}`,
|
|
@@ -59,7 +135,7 @@ const FlexDiv = React.memo(React.forwardRef((props, ref) => {
|
|
|
59
135
|
id: divId,
|
|
60
136
|
ref: ref,
|
|
61
137
|
className: `${css_flexDiv} ${null != className ? className : ""}`,
|
|
62
|
-
style: Object.assign(Object.assign({},
|
|
138
|
+
style: Object.assign(Object.assign({}, style), wrapperStyle),
|
|
63
139
|
transition: transition,
|
|
64
140
|
variants: variants,
|
|
65
141
|
initial: enter,
|
|
@@ -70,11 +146,4 @@ const FlexDiv = React.memo(React.forwardRef((props, ref) => {
|
|
|
70
146
|
}));
|
|
71
147
|
}));
|
|
72
148
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
!function(Size) {
|
|
76
|
-
Size.Grow = "grow", Size.Fill = "fill", Size.Fit = "fit", Size.Viewport = "viewport",
|
|
77
|
-
Size.Auto = "auto";
|
|
78
|
-
}(Size || (Size = {}));
|
|
79
|
-
|
|
80
|
-
export { FlexDiv as F, Size as S };
|
|
149
|
+
export { FlexDiv as F, Preset as P, Size as S };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -12,9 +13,9 @@ import "../theme/colors.mjs";
|
|
|
12
13
|
|
|
13
14
|
import "../hooks/useWindow.mjs";
|
|
14
15
|
|
|
15
|
-
import { B as Badge } from "./Badge-
|
|
16
|
+
import { B as Badge } from "./Badge-CC0zSLMf.mjs";
|
|
16
17
|
|
|
17
|
-
import { I as Icon } from "./Icon-
|
|
18
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
18
19
|
|
|
19
20
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
20
21
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
@@ -22,7 +23,23 @@ styleInject(".Icon-module_icon__szG-X {\n\tcursor: var(--cursor);\n\tuser-select
|
|
|
22
23
|
* Static icon registry created once at module load.
|
|
23
24
|
* Each entry stores only icon line content renderers.
|
|
24
25
|
*/
|
|
25
|
-
const STATIC_ICON_REGISTRY = new Map([ [ "
|
|
26
|
+
const STATIC_ICON_REGISTRY = new Map([ [ "sidebar", {
|
|
27
|
+
line: ({strokeColor: strokeColor, fillColor: fillColor}) => jsxs(Fragment, {
|
|
28
|
+
children: [ jsx("rect", {
|
|
29
|
+
x: "10",
|
|
30
|
+
y: "4.5",
|
|
31
|
+
width: "8",
|
|
32
|
+
height: "11",
|
|
33
|
+
rx: "1",
|
|
34
|
+
ry: "1",
|
|
35
|
+
opacity: fillColor,
|
|
36
|
+
fill: strokeColor
|
|
37
|
+
}), jsx("path", {
|
|
38
|
+
d: "M17,3.75H3c-.96,0-1.75.78-1.75,1.75v9c0,.96.78,1.75,1.75,1.75h14c.96,0,1.75-.78,1.75-1.75V5.5c0-.96-.78-1.75-1.75-1.75ZM2.75,14.5V5.5c0-.14.11-.25.25-.25h6.25v9.5H3c-.14,0-.25-.11-.25-.25ZM17.25,14.5c0,.14-.11.25-.25.25h-6.25V5.25h6.25c.14,0,.25.11.25.25v9Z",
|
|
39
|
+
fill: strokeColor
|
|
40
|
+
}) ]
|
|
41
|
+
})
|
|
42
|
+
} ], [ "target", {
|
|
26
43
|
line: ({strokeColor: strokeColor}) => jsxs(Fragment, {
|
|
27
44
|
children: [ jsx("circle", {
|
|
28
45
|
cx: "10",
|
|
@@ -1086,7 +1103,7 @@ const STATIC_ICON_REGISTRY = new Map([ [ "target", {
|
|
|
1086
1103
|
})
|
|
1087
1104
|
} ] ]), Icon = React.memo(props => {
|
|
1088
1105
|
var _a;
|
|
1089
|
-
const theme = useTheme(), {name: name = "home", size: size = 20, stroke: stroke = 1.5, strokeColor: strokeColor = theme.current.colors["core-icon-primary"], fillColor: fillColor =
|
|
1106
|
+
const theme = useTheme(), {name: name = "home", size: size = 20, stroke: stroke = 1.5, strokeColor: strokeColor = theme.current.colors["core-icon-primary"], fillColor: fillColor = .2, coverUp: coverUp = theme.current.colors["core-surface-primary"], toggle: toggle = !1, pointer: pointer = !1, disabled: disabled = !1, onClick: onClick} = props, svgAttributes = __rest(props, [ "name", "size", "stroke", "strokeColor", "fillColor", "coverUp", "toggle", "pointer", "disabled", "onClick" ]), {id: svgId, className: className, style: style} = svgAttributes, rest = __rest(svgAttributes, [ "id", "className", "style" ]), svgStyle = null != style ? style : {}, variantKey = toggle ? "lineOn" : "line", iconVariant = STATIC_ICON_REGISTRY.get(name), shape = null !== (_a = null == iconVariant ? void 0 : iconVariant[variantKey]) && void 0 !== _a ? _a : null == iconVariant ? void 0 : iconVariant.line, cursor = useMemo(() => disabled ? "default" : pointer ? "pointer" : "inherit", [ disabled, pointer ]), iconStyle = useMemo(() => ({
|
|
1090
1107
|
"--cursor": cursor,
|
|
1091
1108
|
"--pointer-events": onClick ? "auto" : "none"
|
|
1092
1109
|
}), [ cursor, onClick ]), handleKeyActivate = useMemo(() => () => null == onClick ? void 0 : onClick(void 0), [ onClick ]);
|
|
@@ -1099,7 +1116,7 @@ const STATIC_ICON_REGISTRY = new Map([ [ "target", {
|
|
|
1099
1116
|
viewBox: "0 0 20 20",
|
|
1100
1117
|
style: Object.assign(Object.assign({}, svgStyle), iconStyle),
|
|
1101
1118
|
onClick: e => null == onClick ? void 0 : onClick(e),
|
|
1102
|
-
fill:
|
|
1119
|
+
fill: "transparent",
|
|
1103
1120
|
role: "img",
|
|
1104
1121
|
"aria-label": `${name} icon`,
|
|
1105
1122
|
tabIndex: pointer && !disabled ? 0 : -1,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
@@ -6,11 +7,11 @@ import { motion } from "motion/react";
|
|
|
6
7
|
|
|
7
8
|
import React, { useRef, useState, useEffect, useCallback, useMemo } from "react";
|
|
8
9
|
|
|
9
|
-
import { B as Badge } from "./Badge-
|
|
10
|
+
import { B as Badge } from "./Badge-CC0zSLMf.mjs";
|
|
10
11
|
|
|
11
|
-
import { D as Dot } from "./Dot-
|
|
12
|
+
import { D as Dot } from "./Dot-DZE134mJ.mjs";
|
|
12
13
|
|
|
13
|
-
import { I as Icon } from "./Icon-
|
|
14
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
14
15
|
|
|
15
16
|
import { T as ToolTipType } from "./sharedTypes-tn9-uJvb.mjs";
|
|
16
17
|
|
|
@@ -21,7 +22,7 @@ var css_button = "IconButton-module_button__rziqa flexBox-module_row__z24tF", cs
|
|
|
21
22
|
styleInject(".flexBox-module_row__z24tF {\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_rowBetween__5FEvi {\n\tdisplay: flex;\n\tjustify-content: space-between;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_rowStart__4tcxS {\n\tdisplay: flex;\n\tjustify-content: flex-start;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_rowEnd__rVdVm {\n\tdisplay: flex;\n\tjustify-content: flex-end;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_column__ezvMq {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: center;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnStart__C7P44 {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: flex-start;\n\talign-items: flex-start;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnStartCenter__PKcrG {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: flex-start;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnBetween__ERfp7 {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: space-between;\n\talign-items: center;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.flexBox-module_columnEnd__lLJuc {\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: flex-end;\n\talign-items: flex-end;\n\tbox-sizing: border-box;\n\tpadding: 0;\n\tmargin: 0;\n}.type-module_body-xs-regular__ZAFft {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-xs-medium__s3KvF {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-xs-bold__Lhqqq {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-xs);\n\tline-height: 133.33%;\n\ttext-decoration: none;\n\tletter-spacing: 0.25px;\n}.type-module_body-s-regular__vRHSP {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-s-medium__tjdFc {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-s-bold__Iy-VX {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-s);\n\tline-height: 142.86%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-m-regular__LuQBA {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-m-medium__uW1on {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-m-bold__UBcvQ {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-m);\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_body-l-regular__lOYbg {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-l-medium__BqRC7 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-l-bold__Fh2dt {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-l);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_body-xl-regular__pF2kC {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-regular);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-xl-medium__BeyrH {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-medium);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.1px;\n}.type-module_body-xl-bold__Ruknj {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: var(--font-weight-bold);\n\tfont-size: var(--font-size-xl);\n\tline-height: 162.5%;\n\ttext-decoration: none;\n\tletter-spacing: 0.15px;\n}.type-module_heading-s-medium__z8L3G {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 20px;\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-s-bold__0O3g6 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 20px;\n\tline-height: 140%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-m-bold__KXxEB {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 24px;\n\tline-height: 116.67%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-m-medium__cJeEA {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 24px;\n\tline-height: 116.67%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-l-medium__eRe05 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 30px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-l-bold__Xmwtf {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 30px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-xl-medium__5q1m3 {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 500;\n\tfont-size: 36px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}.type-module_heading-xl-bold__k9VFV {\n\tfont-family: var(--font-family), sans-serif;\n\tfont-weight: 600;\n\tfont-size: 36px;\n\tline-height: 128.57%;\n\ttext-decoration: none;\n\tletter-spacing: 0.2px;\n}\n\n.IconButton-module_button__rziqa {\n\tposition: relative;\n\tbackground: var(--ib-bg-color);\n\tborder-radius: var(--ib-border-radius);\n\tborder: var(--ib-border) solid var(--core-outline-primary);\n\tgap: 6px;\n\tcursor: pointer;\n\tappearance: none;\n\t-webkit-appearance: none;\n\tbackground-image: none;\n\toutline: none;\n\t&:hover {\n\t\tbackground: var(--ib-bg-color-hover);\n\t}\n}\n\n.IconButton-module_label__qWGFD {\n\tcolor: var(--ib-color);\n\ttext-overflow: ellipsis;\n\toverflow: hidden;\n\tword-break: break-all;\n\tdisplay: -webkit-box;\n\t-webkit-line-clamp: 1;\n\t-webkit-box-orient: vertical;\n}\n\n.IconButton-module_icon__2DDWy {\n\tmin-height: var(--ib-icon-size);\n\theight: var(--ib-icon-size);\n\tmin-width: var(--ib-icon-size);\n\twidth: var(--ib-icon-size);\n}\n\n.IconButton-module_count__6r373 {\n\tposition: absolute;\n\ttop: 0;\n\tright: 0;\n\ttransform: translateX(5px) translateY(-2px);\n}\n");
|
|
22
23
|
|
|
23
24
|
const IconButton = React.memo(props => {
|
|
24
|
-
const {frameSize: frameSize = 36, iconSize: iconSize = 20, icon: icon = "more", borderRadius: borderRadius = 4, border: border = !1, tooltip: tooltip, color: color, colorOn: colorOn, bgColor: bgColor = "var(--core-surface-secondary)", bgColorHover: bgColorHover = "var(--core-outline-primary)", bgColorOn: bgColorOn = "var(--core-outline-primary)", iconColor: iconColor = "var(--core-text-primary)", iconColorOn: iconColorOn = "var(--core-text-primary)", iconColorHover: iconColorHover = "var(--core-text-primary)", transition: transition, variants: variants, initial: initial, animate: animate, exit: exit, fillColor: fillColor, label: label, hover: hover = !0, count: count = 0, toggle: toggle = !1, toggleIcon: toggleIcon = !1, isToggled: isToggled = !1, disabled: disabled = !1, showDot: showDot = !1, onClick: onClick = () => null, onToolTip: onToolTip = () => null} = props, divAttributes = __rest(props, [ "frameSize", "iconSize", "icon", "borderRadius", "border", "tooltip", "color", "colorOn", "bgColor", "bgColorHover", "bgColorOn", "iconColor", "iconColorOn", "iconColorHover", "transition", "variants", "initial", "animate", "exit", "fillColor", "label", "hover", "count", "toggle", "toggleIcon", "isToggled", "disabled", "showDot", "onClick", "onToolTip" ]), {id: divId, className: className, style: style} = divAttributes, rest = __rest(divAttributes, [ "id", "className", "style" ]), divStyle = null != style ? style : {}, divClass = className ? ` ${className}` : "", ref = useRef(null), [on, setOn] = useState(isToggled), [hovered, setHovered] = useState(!1);
|
|
25
|
+
const {frameSize: frameSize = 36, iconSize: iconSize = 20, round: round = !0, icon: icon = "more", borderRadius: borderRadius = 4, border: border = !1, tooltip: tooltip, color: color, colorOn: colorOn, bgColor: bgColor = "var(--core-surface-secondary)", bgColorHover: bgColorHover = "var(--core-outline-primary)", bgColorOn: bgColorOn = "var(--core-outline-primary)", iconColor: iconColor = "var(--core-text-primary)", iconColorOn: iconColorOn = "var(--core-text-primary)", iconColorHover: iconColorHover = "var(--core-text-primary)", transition: transition, variants: variants, initial: initial, animate: animate, exit: exit, fillColor: fillColor, label: label, hover: hover = !0, count: count = 0, toggle: toggle = !1, toggleIcon: toggleIcon = !1, isToggled: isToggled = !1, disabled: disabled = !1, showDot: showDot = !1, buttonSize: buttonSize = "m", onClick: onClick = () => null, onToolTip: onToolTip = () => null} = props, divAttributes = __rest(props, [ "frameSize", "iconSize", "round", "icon", "borderRadius", "border", "tooltip", "color", "colorOn", "bgColor", "bgColorHover", "bgColorOn", "iconColor", "iconColorOn", "iconColorHover", "transition", "variants", "initial", "animate", "exit", "fillColor", "label", "hover", "count", "toggle", "toggleIcon", "isToggled", "disabled", "showDot", "buttonSize", "onClick", "onToolTip" ]), {id: divId, className: className, style: style} = divAttributes, rest = __rest(divAttributes, [ "id", "className", "style" ]), divStyle = null != style ? style : {}, divClass = className ? ` ${className}` : "", ref = useRef(null), [on, setOn] = useState(isToggled), [hovered, setHovered] = useState(!1);
|
|
25
26
|
useEffect(() => setOn(isToggled), [ isToggled ]);
|
|
26
27
|
const handleClick = useCallback(e => {
|
|
27
28
|
disabled || (tooltip && onToolTip(null), toggle && setOn(!on), onClick(e));
|
|
@@ -38,14 +39,14 @@ const IconButton = React.memo(props => {
|
|
|
38
39
|
onToolTip(tip);
|
|
39
40
|
}, [ tooltip, onToolTip ]), handleMouseLeave = useCallback(() => {
|
|
40
41
|
setHovered(!1), tooltip && onToolTip(null);
|
|
41
|
-
}, [ tooltip, onToolTip ]), bgColorNormal = useMemo(() => on && toggle ? bgColorOn : null != bgColor ? bgColor : "var(--core-surface-secondary)", [ toggle, bgColorOn, bgColor, on ]), bgHoverColor = useMemo(() => hover && on ? bgColorOn : hover ? bgColorHover : null != bgColor ? bgColor : "transparent", [ hover, bgColor, bgColorOn, bgColorHover, on ]), textColor = useMemo(() => toggle && on ? colorOn : null != color ? color : "var(--core-text-primary)", [ toggle, on, colorOn, color ]), setIconColor = useMemo(() => toggle && on ? iconColorOn : hovered ? iconColorHover : null != iconColor ? iconColor : "var(--core-text-primary)", [ toggle, on, iconColorOn, iconColor, iconColorHover, hovered ]), cssVars = useMemo(() => ({
|
|
42
|
+
}, [ tooltip, onToolTip ]), bgColorNormal = useMemo(() => on && toggle ? bgColorOn : null != bgColor ? bgColor : "var(--core-surface-secondary)", [ toggle, bgColorOn, bgColor, on ]), bgHoverColor = useMemo(() => hover && on ? bgColorOn : hover ? bgColorHover : null != bgColor ? bgColor : "transparent", [ hover, bgColor, bgColorOn, bgColorHover, on ]), textColor = useMemo(() => toggle && on ? colorOn : null != color ? color : "var(--core-text-primary)", [ toggle, on, colorOn, color ]), setIconColor = useMemo(() => toggle && on ? iconColorOn : hovered ? iconColorHover : null != iconColor ? iconColor : "var(--core-text-primary)", [ toggle, on, iconColorOn, iconColor, iconColorHover, hovered ]), size = useMemo(() => buttonSize ? "s" === buttonSize ? 24 : "m" === buttonSize ? 36 : "l" === buttonSize ? 44 : "xl" === buttonSize ? 56 : void 0 : frameSize, [ frameSize, buttonSize ]), cssVars = useMemo(() => ({
|
|
42
43
|
"--ib-bg-color": bgColorNormal,
|
|
43
44
|
"--ib-bg-color-hover": bgHoverColor,
|
|
44
|
-
"--ib-icon-size": `${null !=
|
|
45
|
-
"--ib-border-radius": `${null != borderRadius ? borderRadius : 0}px`,
|
|
45
|
+
"--ib-icon-size": `${null != size ? size : 0}px`,
|
|
46
|
+
"--ib-border-radius": round ? "100%" : `${null != borderRadius ? borderRadius : 0}px`,
|
|
46
47
|
"--ib-border": border ? "1px" : 0,
|
|
47
48
|
"--ib-color": textColor
|
|
48
|
-
}), [ bgColorNormal, bgHoverColor, textColor, border,
|
|
49
|
+
}), [ bgColorNormal, bgHoverColor, textColor, border, size, borderRadius, round ]);
|
|
49
50
|
return jsxs(motion.button, Object.assign({
|
|
50
51
|
id: divId,
|
|
51
52
|
type: "button",
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
3
|
|
|
3
4
|
import React, { useState, useEffect, useMemo, useRef } from "react";
|
|
@@ -10,7 +11,7 @@ import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
|
10
11
|
|
|
11
12
|
import "../hooks/useWindow.mjs";
|
|
12
13
|
|
|
13
|
-
import { I as Icon } from "./Icon-
|
|
14
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
14
15
|
|
|
15
16
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
16
17
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
3
|
|
|
3
4
|
import React, { useState, useRef, useCallback, useMemo, useEffect } from "react";
|
|
@@ -10,9 +11,9 @@ import "./tslib.es6-C-olHjXV.mjs";
|
|
|
10
11
|
|
|
11
12
|
import "../hooks/useWindow.mjs";
|
|
12
13
|
|
|
13
|
-
import { B as Button } from "./Button-
|
|
14
|
+
import { B as Button } from "./Button-YER9dCLE.mjs";
|
|
14
15
|
|
|
15
|
-
import { F as FileList } from "./FileList-
|
|
16
|
+
import { F as FileList } from "./FileList-BQ9X5YnB.mjs";
|
|
16
17
|
|
|
17
18
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
18
19
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
@@ -6,7 +7,7 @@ import React, { useState, useEffect, useCallback, useMemo } from "react";
|
|
|
6
7
|
|
|
7
8
|
import { s as setStyle } from "./misc-BeEWwOaJ.mjs";
|
|
8
9
|
|
|
9
|
-
import { I as Icon } from "./Icon-
|
|
10
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
10
11
|
|
|
11
12
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
12
13
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -6,7 +7,7 @@ import React, { useId, useState, useEffect, useCallback, useMemo } from "react";
|
|
|
6
7
|
|
|
7
8
|
import { s as setStyle } from "./misc-BeEWwOaJ.mjs";
|
|
8
9
|
|
|
9
|
-
import { R as RadioButton } from "./RadioButton-
|
|
10
|
+
import { R as RadioButton } from "./RadioButton-B6ImCUYY.mjs";
|
|
10
11
|
|
|
11
12
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
12
13
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -10,11 +11,11 @@ import "../theme/colors.mjs";
|
|
|
10
11
|
|
|
11
12
|
import "../hooks/useWindow.mjs";
|
|
12
13
|
|
|
13
|
-
import { B as Badge } from "./Badge-
|
|
14
|
+
import { B as Badge } from "./Badge-CC0zSLMf.mjs";
|
|
14
15
|
|
|
15
|
-
import { I as Icon } from "./Icon-
|
|
16
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
16
17
|
|
|
17
|
-
import { I as IconButton } from "./IconButton-
|
|
18
|
+
import { I as IconButton } from "./IconButton-Dciw5CLn.mjs";
|
|
18
19
|
|
|
19
20
|
import { T as ToolTipType } from "./sharedTypes-tn9-uJvb.mjs";
|
|
20
21
|
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
4
5
|
|
|
5
6
|
import React, { useState, useRef, useCallback, useEffect, useMemo } from "react";
|
|
6
7
|
|
|
7
|
-
import { B as Button } from "./Button-
|
|
8
|
+
import { B as Button } from "./Button-YER9dCLE.mjs";
|
|
8
9
|
|
|
9
10
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
10
11
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
@@ -14,11 +15,11 @@ import { s as setStyle } from "./misc-BeEWwOaJ.mjs";
|
|
|
14
15
|
|
|
15
16
|
import "../hooks/useWindow.mjs";
|
|
16
17
|
|
|
17
|
-
import { B as Button } from "./Button-
|
|
18
|
+
import { B as Button } from "./Button-YER9dCLE.mjs";
|
|
18
19
|
|
|
19
|
-
import { I as Icon } from "./Icon-
|
|
20
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
20
21
|
|
|
21
|
-
import { I as IconButton } from "./IconButton-
|
|
22
|
+
import { I as IconButton } from "./IconButton-Dciw5CLn.mjs";
|
|
22
23
|
|
|
23
24
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
24
25
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
'use client';
|
|
1
2
|
import { a as __rest } from "./tslib.es6-C-olHjXV.mjs";
|
|
2
3
|
|
|
3
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -14,7 +15,7 @@ import { s as setStyle, f as filterClasses, a as accessibleKeyDown } from "./mis
|
|
|
14
15
|
|
|
15
16
|
import "../hooks/useWindow.mjs";
|
|
16
17
|
|
|
17
|
-
import { I as Icon } from "./Icon-
|
|
18
|
+
import { I as Icon } from "./Icon-DI32kOA1.mjs";
|
|
18
19
|
|
|
19
20
|
import { s as styleInject } from "./style-inject.es-D0BjEaN8.mjs";
|
|
20
21
|
|