@app-studio/web 0.8.72 → 0.8.74
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/components/Accordion/Accordion/Accordion.props.d.ts +91 -0
- package/dist/components/Accordion/Accordion/Accordion.state.d.ts +5 -0
- package/dist/components/Accordion/Accordion/Accordion.style.d.ts +4 -0
- package/dist/components/Accordion/Accordion/Accordion.type.d.ts +15 -0
- package/dist/components/Accordion/Accordion/Accordion.view.d.ts +22 -0
- package/dist/components/Accordion/Accordion.d.ts +2 -0
- package/dist/components/Accordion/examples/default.d.ts +2 -0
- package/dist/components/Accordion/examples/disabled.d.ts +2 -0
- package/dist/components/Accordion/examples/index.d.ts +4 -0
- package/dist/components/Accordion/examples/multiple.d.ts +2 -0
- package/dist/components/Accordion/examples/variants.d.ts +2 -0
- package/dist/components/ContextMenu/ContextMenu/ContextMenu.props.d.ts +120 -0
- package/dist/components/ContextMenu/ContextMenu/ContextMenu.state.d.ts +15 -0
- package/dist/components/ContextMenu/ContextMenu/ContextMenu.style.d.ts +20 -0
- package/dist/components/ContextMenu/ContextMenu/ContextMenu.type.d.ts +41 -0
- package/dist/components/ContextMenu/ContextMenu/ContextMenu.view.d.ts +20 -0
- package/dist/components/ContextMenu/ContextMenu.d.ts +2 -0
- package/dist/components/ContextMenu/examples/custom.d.ts +2 -0
- package/dist/components/ContextMenu/examples/default.d.ts +2 -0
- package/dist/components/ContextMenu/examples/index.d.ts +4 -0
- package/dist/components/ContextMenu/examples/sizes.d.ts +2 -0
- package/dist/components/ContextMenu/examples/variants.d.ts +2 -0
- package/dist/components/DropdownMenu/DropdownMenu/DropdownMenu.props.d.ts +117 -0
- package/dist/components/DropdownMenu/DropdownMenu/DropdownMenu.state.d.ts +7 -0
- package/dist/components/DropdownMenu/DropdownMenu/DropdownMenu.style.d.ts +17 -0
- package/dist/components/DropdownMenu/DropdownMenu/DropdownMenu.type.d.ts +34 -0
- package/dist/components/DropdownMenu/DropdownMenu/DropdownMenu.view.d.ts +19 -0
- package/dist/components/DropdownMenu/DropdownMenu.d.ts +2 -0
- package/dist/components/DropdownMenu/examples/custom.d.ts +2 -0
- package/dist/components/DropdownMenu/examples/default.d.ts +2 -0
- package/dist/components/DropdownMenu/examples/index.d.ts +5 -0
- package/dist/components/DropdownMenu/examples/positions.d.ts +2 -0
- package/dist/components/DropdownMenu/examples/sizes.d.ts +2 -0
- package/dist/components/DropdownMenu/examples/variants.d.ts +2 -0
- package/dist/components/Form/Password/Password/Password.state.d.ts +1 -1
- package/dist/components/Formik/Formik.Slider.d.ts +7 -0
- package/dist/components/Formik/examples/FormikSlider.d.ts +2 -0
- package/dist/components/Formik/examples/index.d.ts +1 -0
- package/dist/components/Formik/index.d.ts +1 -0
- package/dist/components/HoverCard/HoverCard/HoverCard.props.d.ts +65 -0
- package/dist/components/HoverCard/HoverCard/HoverCard.state.d.ts +5 -0
- package/dist/components/HoverCard/HoverCard/HoverCard.style.d.ts +3 -0
- package/dist/components/HoverCard/HoverCard/HoverCard.type.d.ts +6 -0
- package/dist/components/HoverCard/HoverCard/HoverCard.view.d.ts +10 -0
- package/dist/components/HoverCard/HoverCard.d.ts +2 -0
- package/dist/components/HoverCard/examples/default.d.ts +2 -0
- package/dist/components/HoverCard/examples/index.d.ts +1 -0
- package/dist/components/Icon/Icon.d.ts +3 -0
- package/dist/components/NavigationMenu/NavigationMenu/NavigationMenu.props.d.ts +126 -0
- package/dist/components/NavigationMenu/NavigationMenu/NavigationMenu.state.d.ts +8 -0
- package/dist/components/NavigationMenu/NavigationMenu/NavigationMenu.style.d.ts +18 -0
- package/dist/components/NavigationMenu/NavigationMenu/NavigationMenu.type.d.ts +34 -0
- package/dist/components/NavigationMenu/NavigationMenu/NavigationMenu.view.d.ts +19 -0
- package/dist/components/NavigationMenu/NavigationMenu.d.ts +2 -0
- package/dist/components/NavigationMenu/examples/default.d.ts +2 -0
- package/dist/components/NavigationMenu/examples/horizontal.d.ts +2 -0
- package/dist/components/NavigationMenu/examples/index.d.ts +4 -0
- package/dist/components/NavigationMenu/examples/sizes.d.ts +2 -0
- package/dist/components/NavigationMenu/examples/variants.d.ts +2 -0
- package/dist/components/Slider/Slider/Slider.props.d.ts +112 -0
- package/dist/components/Slider/Slider/Slider.state.d.ts +14 -0
- package/dist/components/Slider/Slider/Slider.style.d.ts +11 -0
- package/dist/components/Slider/Slider/Slider.type.d.ts +18 -0
- package/dist/components/Slider/Slider/Slider.view.d.ts +3 -0
- package/dist/components/Slider/Slider.d.ts +6 -0
- package/dist/components/Slider/examples/controlled.d.ts +2 -0
- package/dist/components/Slider/examples/custom.d.ts +2 -0
- package/dist/components/Slider/examples/default.d.ts +2 -0
- package/dist/components/Slider/examples/disabled.d.ts +2 -0
- package/dist/components/Slider/examples/range.d.ts +2 -0
- package/dist/components/Slider/examples/shapes.d.ts +2 -0
- package/dist/components/Slider/examples/sizes.d.ts +2 -0
- package/dist/components/Slider/examples/stepValues.d.ts +3 -0
- package/dist/components/Slider/examples/tooltip.d.ts +2 -0
- package/dist/components/Slider/examples/variants.d.ts +2 -0
- package/dist/components/Slider/examples/vertical.d.ts +2 -0
- package/dist/components/Slider/index.d.ts +1 -0
- package/dist/components/Table/Table.d.ts +8 -8
- package/dist/components/index.d.ts +11 -0
- package/dist/pages/accordion.page.d.ts +3 -0
- package/dist/pages/components.page.d.ts +5 -0
- package/dist/pages/contextMenu.page.d.ts +3 -0
- package/dist/pages/dropdownMenu.page.d.ts +3 -0
- package/dist/pages/hoverCard.page.d.ts +3 -0
- package/dist/pages/navigationMenu.page.d.ts +3 -0
- package/dist/pages/slider.page.d.ts +3 -0
- package/dist/web.cjs.development.js +2546 -384
- package/dist/web.cjs.development.js.map +1 -1
- package/dist/web.cjs.production.min.js +1 -1
- package/dist/web.cjs.production.min.js.map +1 -1
- package/dist/web.esm.js +2539 -387
- package/dist/web.esm.js.map +1 -1
- package/dist/web.umd.development.js +2594 -433
- package/dist/web.umd.development.js.map +1 -1
- package/dist/web.umd.production.min.js +1 -1
- package/dist/web.umd.production.min.js.map +1 -1
- package/package.json +1 -1
- package/dist/utils/componentsPageImports.d.ts +0 -6
package/dist/web.esm.js
CHANGED
|
@@ -1,22 +1,241 @@
|
|
|
1
|
-
import '
|
|
2
|
-
import
|
|
3
|
-
import 'core-js/modules/es.object.assign.js';
|
|
4
|
-
import { View as View$1, Element, Typography, Image, useTheme, Vertical as Vertical$1, Input, Form, Text as Text$1, Horizontal as Horizontal$1 } from 'app-studio';
|
|
1
|
+
import React, { useState, useContext, createContext, useRef, useEffect, useCallback, useMemo, Fragment } from 'react';
|
|
2
|
+
import 'core-js/modules/es.array.includes.js';
|
|
5
3
|
import 'core-js/modules/es.array.iterator.js';
|
|
6
|
-
import 'core-js/modules/es.
|
|
4
|
+
import 'core-js/modules/es.string.includes.js';
|
|
7
5
|
import 'core-js/modules/web.dom-collections.iterator.js';
|
|
8
|
-
import 'core-js/modules/es.
|
|
6
|
+
import 'core-js/modules/es.object.assign.js';
|
|
7
|
+
import { View as View$1, Horizontal as Horizontal$1, Vertical as Vertical$1, Element, Typography, Image, useTheme, Input, Form, Text as Text$1 } from 'app-studio';
|
|
8
|
+
import 'core-js/modules/es.symbol.description.js';
|
|
9
|
+
import 'core-js/modules/es.parse-float.js';
|
|
9
10
|
import { Link as Link$1 } from 'react-router-dom';
|
|
10
|
-
import 'core-js/modules/es.string.includes.js';
|
|
11
11
|
import 'core-js/modules/es.string.starts-with.js';
|
|
12
12
|
import format from 'date-fns/format';
|
|
13
13
|
import { useFormikContext, getIn } from 'formik';
|
|
14
|
+
import 'core-js/modules/es.number.to-fixed.js';
|
|
14
15
|
import 'core-js/modules/web.url.js';
|
|
15
16
|
import 'core-js/modules/web.url.to-json.js';
|
|
16
17
|
import 'core-js/modules/web.url-search-params.js';
|
|
17
18
|
import { create } from 'zustand';
|
|
18
19
|
import { Center as Center$1 } from 'src/components/Layout';
|
|
19
20
|
|
|
21
|
+
var useAccordionState = function useAccordionState(defaultExpandedItems, allowMultiple) {
|
|
22
|
+
if (defaultExpandedItems === void 0) {
|
|
23
|
+
defaultExpandedItems = [];
|
|
24
|
+
}
|
|
25
|
+
if (allowMultiple === void 0) {
|
|
26
|
+
allowMultiple = false;
|
|
27
|
+
}
|
|
28
|
+
var [expandedItems, setExpandedItems] = useState(defaultExpandedItems);
|
|
29
|
+
var toggleItem = itemId => {
|
|
30
|
+
setExpandedItems(prevExpandedItems => {
|
|
31
|
+
// Check if the item is already expanded
|
|
32
|
+
var isExpanded = prevExpandedItems.includes(itemId);
|
|
33
|
+
if (isExpanded) {
|
|
34
|
+
// If expanded, remove it from the list
|
|
35
|
+
return prevExpandedItems.filter(id => id !== itemId);
|
|
36
|
+
} else {
|
|
37
|
+
// If not expanded, add it to the list
|
|
38
|
+
// If allowMultiple is false, replace the current expanded item
|
|
39
|
+
return allowMultiple ? [...prevExpandedItems, itemId] : [itemId];
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
};
|
|
43
|
+
var isItemExpanded = itemId => {
|
|
44
|
+
return expandedItems.includes(itemId);
|
|
45
|
+
};
|
|
46
|
+
return {
|
|
47
|
+
expandedItems,
|
|
48
|
+
toggleItem,
|
|
49
|
+
isItemExpanded
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
var AccordionShapes = {
|
|
54
|
+
sharp: {
|
|
55
|
+
borderRadius: 0
|
|
56
|
+
},
|
|
57
|
+
rounded: {
|
|
58
|
+
borderRadius: 8
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
var AccordionVariants = {
|
|
62
|
+
default: {
|
|
63
|
+
backgroundColor: 'transparent',
|
|
64
|
+
borderWidth: 0
|
|
65
|
+
},
|
|
66
|
+
outline: {
|
|
67
|
+
borderWidth: 1,
|
|
68
|
+
borderStyle: 'solid',
|
|
69
|
+
borderColor: 'color.gray.200'
|
|
70
|
+
},
|
|
71
|
+
filled: {
|
|
72
|
+
backgroundColor: 'color.gray.50'
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
|
|
76
|
+
// Create context for the Accordion
|
|
77
|
+
var AccordionContext = /*#__PURE__*/createContext({
|
|
78
|
+
expandedItems: [],
|
|
79
|
+
toggleItem: () => {},
|
|
80
|
+
isItemExpanded: () => false
|
|
81
|
+
});
|
|
82
|
+
// Provider component for the Accordion context
|
|
83
|
+
var AccordionProvider = _ref => {
|
|
84
|
+
var {
|
|
85
|
+
children,
|
|
86
|
+
value
|
|
87
|
+
} = _ref;
|
|
88
|
+
return /*#__PURE__*/React.createElement(AccordionContext.Provider, {
|
|
89
|
+
value: value
|
|
90
|
+
}, children);
|
|
91
|
+
};
|
|
92
|
+
// Hook to use the Accordion context
|
|
93
|
+
var useAccordionContext = () => {
|
|
94
|
+
var context = useContext(AccordionContext);
|
|
95
|
+
if (!context) {
|
|
96
|
+
throw new Error('useAccordionContext must be used within an AccordionProvider');
|
|
97
|
+
}
|
|
98
|
+
return context;
|
|
99
|
+
};
|
|
100
|
+
// Accordion Item component
|
|
101
|
+
var AccordionItem = _ref2 => {
|
|
102
|
+
var {
|
|
103
|
+
id,
|
|
104
|
+
children,
|
|
105
|
+
isDisabled = false,
|
|
106
|
+
views
|
|
107
|
+
} = _ref2;
|
|
108
|
+
var {
|
|
109
|
+
isItemExpanded
|
|
110
|
+
} = useAccordionContext();
|
|
111
|
+
var isExpanded = isItemExpanded(id);
|
|
112
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
113
|
+
borderWidth: 1,
|
|
114
|
+
borderStyle: "solid",
|
|
115
|
+
borderColor: "color.gray.200",
|
|
116
|
+
marginBottom: 8,
|
|
117
|
+
overflow: "hidden",
|
|
118
|
+
opacity: isDisabled ? 0.5 : 1,
|
|
119
|
+
pointerEvents: isDisabled ? 'none' : 'auto'
|
|
120
|
+
}, views == null ? void 0 : views.item), React.Children.map(children, child => {
|
|
121
|
+
if (/*#__PURE__*/React.isValidElement(child)) {
|
|
122
|
+
// Pass the id and isExpanded props to AccordionHeader and AccordionContent
|
|
123
|
+
return /*#__PURE__*/React.cloneElement(child, Object.assign({}, child.props, {
|
|
124
|
+
id,
|
|
125
|
+
isExpanded
|
|
126
|
+
}));
|
|
127
|
+
}
|
|
128
|
+
return child;
|
|
129
|
+
}));
|
|
130
|
+
};
|
|
131
|
+
// Accordion Header component
|
|
132
|
+
var AccordionHeader = _ref3 => {
|
|
133
|
+
var {
|
|
134
|
+
children,
|
|
135
|
+
id,
|
|
136
|
+
isExpanded,
|
|
137
|
+
views
|
|
138
|
+
} = _ref3;
|
|
139
|
+
var {
|
|
140
|
+
toggleItem
|
|
141
|
+
} = useAccordionContext();
|
|
142
|
+
var handleClick = () => {
|
|
143
|
+
if (id) {
|
|
144
|
+
toggleItem(id);
|
|
145
|
+
}
|
|
146
|
+
};
|
|
147
|
+
return /*#__PURE__*/React.createElement(Horizontal$1, Object.assign({
|
|
148
|
+
padding: 16,
|
|
149
|
+
cursor: "pointer",
|
|
150
|
+
alignItems: "center",
|
|
151
|
+
justifyContent: "space-between",
|
|
152
|
+
backgroundColor: "color.white",
|
|
153
|
+
onClick: handleClick
|
|
154
|
+
}, views == null ? void 0 : views.container), children, /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
155
|
+
width: 24,
|
|
156
|
+
height: 24,
|
|
157
|
+
display: "flex",
|
|
158
|
+
alignItems: "center",
|
|
159
|
+
justifyContent: "center",
|
|
160
|
+
transition: "transform 0.2s ease",
|
|
161
|
+
transform: isExpanded ? 'rotate(180deg)' : 'rotate(0deg)'
|
|
162
|
+
}, views == null ? void 0 : views.icon), /*#__PURE__*/React.createElement("svg", {
|
|
163
|
+
width: "16",
|
|
164
|
+
height: "16",
|
|
165
|
+
viewBox: "0 0 24 24",
|
|
166
|
+
fill: "none",
|
|
167
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
168
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
169
|
+
d: "M16.59 8.59L12 13.17L7.41 8.59L6 10L12 16L18 10L16.59 8.59Z",
|
|
170
|
+
fill: "currentColor"
|
|
171
|
+
}))));
|
|
172
|
+
};
|
|
173
|
+
// Accordion Content component
|
|
174
|
+
var AccordionContent = _ref4 => {
|
|
175
|
+
var {
|
|
176
|
+
children,
|
|
177
|
+
isExpanded,
|
|
178
|
+
views
|
|
179
|
+
} = _ref4;
|
|
180
|
+
if (!isExpanded) {
|
|
181
|
+
return null;
|
|
182
|
+
}
|
|
183
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
184
|
+
padding: 16,
|
|
185
|
+
backgroundColor: "color.white",
|
|
186
|
+
maxHeight: isExpanded ? '1000px' : '0',
|
|
187
|
+
transition: "max-height 0.3s ease-in-out",
|
|
188
|
+
overflow: "hidden"
|
|
189
|
+
}, views == null ? void 0 : views.container), children);
|
|
190
|
+
};
|
|
191
|
+
// Main Accordion View component
|
|
192
|
+
var AccordionView = _ref5 => {
|
|
193
|
+
var {
|
|
194
|
+
children,
|
|
195
|
+
shape = 'rounded',
|
|
196
|
+
variant = 'default',
|
|
197
|
+
views
|
|
198
|
+
} = _ref5;
|
|
199
|
+
return /*#__PURE__*/React.createElement(Vertical$1, Object.assign({
|
|
200
|
+
width: "100%"
|
|
201
|
+
}, AccordionShapes[shape], AccordionVariants[variant], views == null ? void 0 : views.container), children);
|
|
202
|
+
};
|
|
203
|
+
|
|
204
|
+
/**
|
|
205
|
+
* Accordion component for displaying collapsible content panels.
|
|
206
|
+
*/
|
|
207
|
+
var AccordionComponent = _ref => {
|
|
208
|
+
var {
|
|
209
|
+
children,
|
|
210
|
+
allowMultiple = false,
|
|
211
|
+
defaultExpandedItems = [],
|
|
212
|
+
shape = 'rounded',
|
|
213
|
+
variant = 'default',
|
|
214
|
+
views
|
|
215
|
+
} = _ref;
|
|
216
|
+
var {
|
|
217
|
+
expandedItems,
|
|
218
|
+
toggleItem,
|
|
219
|
+
isItemExpanded
|
|
220
|
+
} = useAccordionState(defaultExpandedItems, allowMultiple);
|
|
221
|
+
return /*#__PURE__*/React.createElement(AccordionProvider, {
|
|
222
|
+
value: {
|
|
223
|
+
expandedItems,
|
|
224
|
+
toggleItem,
|
|
225
|
+
isItemExpanded
|
|
226
|
+
}
|
|
227
|
+
}, /*#__PURE__*/React.createElement(AccordionView, {
|
|
228
|
+
shape: shape,
|
|
229
|
+
variant: variant,
|
|
230
|
+
views: views
|
|
231
|
+
}, children));
|
|
232
|
+
};
|
|
233
|
+
var Accordion = AccordionComponent;
|
|
234
|
+
// Assign the sub-components to the main component
|
|
235
|
+
Accordion.Item = AccordionItem;
|
|
236
|
+
Accordion.Header = AccordionHeader;
|
|
237
|
+
Accordion.Content = AccordionContent;
|
|
238
|
+
|
|
20
239
|
var Top = props => (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
21
240
|
marginBottom: "auto"
|
|
22
241
|
}, props)));
|
|
@@ -255,17 +474,17 @@ var _excluded$4 = ["widthHeight", "color", "transform", "orientation", "children
|
|
|
255
474
|
_excluded27 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
256
475
|
_excluded28 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
257
476
|
_excluded29 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
258
|
-
_excluded30 = ["widthHeight", "color", "
|
|
477
|
+
_excluded30 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
259
478
|
_excluded31 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
260
479
|
_excluded32 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
261
480
|
_excluded33 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
262
481
|
_excluded34 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
263
482
|
_excluded35 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
264
483
|
_excluded36 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
265
|
-
_excluded37 = ["widthHeight", "color", "
|
|
484
|
+
_excluded37 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
266
485
|
_excluded38 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
267
|
-
_excluded39 = ["widthHeight", "color", "
|
|
268
|
-
_excluded40 = ["widthHeight", "color", "
|
|
486
|
+
_excluded39 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
487
|
+
_excluded40 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
269
488
|
_excluded41 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
270
489
|
_excluded42 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
271
490
|
_excluded43 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
@@ -276,10 +495,10 @@ var _excluded$4 = ["widthHeight", "color", "transform", "orientation", "children
|
|
|
276
495
|
_excluded48 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
277
496
|
_excluded49 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
278
497
|
_excluded50 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
279
|
-
_excluded51 = ["widthHeight", "color", "
|
|
280
|
-
_excluded52 = ["widthHeight", "color", "
|
|
281
|
-
_excluded53 = ["widthHeight", "color", "
|
|
282
|
-
_excluded54 = ["widthHeight", "color", "
|
|
498
|
+
_excluded51 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
499
|
+
_excluded52 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
500
|
+
_excluded53 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
501
|
+
_excluded54 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
283
502
|
_excluded55 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
284
503
|
_excluded56 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
285
504
|
_excluded57 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
@@ -291,14 +510,16 @@ var _excluded$4 = ["widthHeight", "color", "transform", "orientation", "children
|
|
|
291
510
|
_excluded63 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
292
511
|
_excluded64 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
293
512
|
_excluded65 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
294
|
-
_excluded66 = ["widthHeight", "color", "
|
|
295
|
-
_excluded67 = ["widthHeight", "color", "
|
|
513
|
+
_excluded66 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
514
|
+
_excluded67 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
296
515
|
_excluded68 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
297
516
|
_excluded69 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
298
517
|
_excluded70 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
299
518
|
_excluded71 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
300
519
|
_excluded72 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
301
|
-
_excluded73 = ["widthHeight", "color", "strokeWidth", "filled"]
|
|
520
|
+
_excluded73 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
521
|
+
_excluded74 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
522
|
+
_excluded75 = ["widthHeight", "color", "strokeWidth", "filled"];
|
|
302
523
|
// Default wrapper component for consistent sizing and styling
|
|
303
524
|
var IconWrapper = _ref => {
|
|
304
525
|
var {
|
|
@@ -327,8 +548,7 @@ var getSvgProps = (filled, color, strokeWidth) => {
|
|
|
327
548
|
strokeLinejoin: 'round'
|
|
328
549
|
};
|
|
329
550
|
};
|
|
330
|
-
|
|
331
|
-
var ChevronIcon = _ref2 => {
|
|
551
|
+
var UserIcon = _ref2 => {
|
|
332
552
|
var {
|
|
333
553
|
widthHeight = 24,
|
|
334
554
|
color = 'currentColor',
|
|
@@ -344,10 +564,10 @@ var ChevronIcon = _ref2 => {
|
|
|
344
564
|
"aria-hidden": "true",
|
|
345
565
|
focusable: "false"
|
|
346
566
|
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React.createElement("path", {
|
|
347
|
-
d: "M12.
|
|
567
|
+
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"
|
|
348
568
|
})));
|
|
349
569
|
};
|
|
350
|
-
var
|
|
570
|
+
var HelpIcon = _ref3 => {
|
|
351
571
|
var {
|
|
352
572
|
widthHeight = 24,
|
|
353
573
|
color = 'currentColor',
|
|
@@ -362,6 +582,45 @@ var DragHandleIcon = _ref3 => {
|
|
|
362
582
|
viewBox: "0 0 24 24",
|
|
363
583
|
"aria-hidden": "true",
|
|
364
584
|
focusable: "false"
|
|
585
|
+
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React.createElement("path", {
|
|
586
|
+
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"
|
|
587
|
+
})));
|
|
588
|
+
};
|
|
589
|
+
// Example Icon Component: ChevronIcon
|
|
590
|
+
var ChevronIcon = _ref4 => {
|
|
591
|
+
var {
|
|
592
|
+
widthHeight = 24,
|
|
593
|
+
color = 'currentColor',
|
|
594
|
+
filled = true,
|
|
595
|
+
strokeWidth = 1
|
|
596
|
+
} = _ref4,
|
|
597
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded4);
|
|
598
|
+
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
599
|
+
widthHeight: widthHeight,
|
|
600
|
+
color: color
|
|
601
|
+
}, props), /*#__PURE__*/React.createElement("svg", Object.assign({
|
|
602
|
+
viewBox: "0 0 24 24",
|
|
603
|
+
"aria-hidden": "true",
|
|
604
|
+
focusable: "false"
|
|
605
|
+
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React.createElement("path", {
|
|
606
|
+
d: "M12.771 7.115a.829.829 0 0 0-1.2 0L3 15.686l1.2 1.2 7.971-7.971 7.972 7.971 1.2-1.2-8.572-8.571Z"
|
|
607
|
+
})));
|
|
608
|
+
};
|
|
609
|
+
var DragHandleIcon = _ref5 => {
|
|
610
|
+
var {
|
|
611
|
+
widthHeight = 24,
|
|
612
|
+
color = 'currentColor',
|
|
613
|
+
filled = true,
|
|
614
|
+
strokeWidth = 1
|
|
615
|
+
} = _ref5,
|
|
616
|
+
props = _objectWithoutPropertiesLoose(_ref5, _excluded5);
|
|
617
|
+
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
618
|
+
widthHeight: widthHeight,
|
|
619
|
+
color: color
|
|
620
|
+
}, props), /*#__PURE__*/React.createElement("svg", Object.assign({
|
|
621
|
+
viewBox: "0 0 24 24",
|
|
622
|
+
"aria-hidden": "true",
|
|
623
|
+
focusable: "false"
|
|
365
624
|
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React.createElement("g", null, /*#__PURE__*/React.createElement("circle", {
|
|
366
625
|
cx: "9",
|
|
367
626
|
cy: "6",
|
|
@@ -389,14 +648,14 @@ var DragHandleIcon = _ref3 => {
|
|
|
389
648
|
}))));
|
|
390
649
|
};
|
|
391
650
|
// File Icon Component
|
|
392
|
-
var FileIcon =
|
|
651
|
+
var FileIcon = _ref6 => {
|
|
393
652
|
var {
|
|
394
653
|
widthHeight = 24,
|
|
395
654
|
color = 'currentColor',
|
|
396
655
|
filled = true,
|
|
397
656
|
strokeWidth = 1
|
|
398
|
-
} =
|
|
399
|
-
props = _objectWithoutPropertiesLoose(
|
|
657
|
+
} = _ref6,
|
|
658
|
+
props = _objectWithoutPropertiesLoose(_ref6, _excluded6);
|
|
400
659
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
401
660
|
widthHeight: widthHeight,
|
|
402
661
|
color: color
|
|
@@ -417,14 +676,14 @@ var FileIcon = _ref4 => {
|
|
|
417
676
|
})));
|
|
418
677
|
};
|
|
419
678
|
// Video Icon Component
|
|
420
|
-
var VideoIcon =
|
|
679
|
+
var VideoIcon = _ref7 => {
|
|
421
680
|
var {
|
|
422
681
|
widthHeight = 24,
|
|
423
682
|
color = 'currentColor',
|
|
424
683
|
filled = true,
|
|
425
684
|
strokeWidth = 1
|
|
426
|
-
} =
|
|
427
|
-
props = _objectWithoutPropertiesLoose(
|
|
685
|
+
} = _ref7,
|
|
686
|
+
props = _objectWithoutPropertiesLoose(_ref7, _excluded7);
|
|
428
687
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
429
688
|
widthHeight: widthHeight,
|
|
430
689
|
color: color
|
|
@@ -450,14 +709,14 @@ var VideoIcon = _ref5 => {
|
|
|
450
709
|
})));
|
|
451
710
|
};
|
|
452
711
|
// Image Icon Component
|
|
453
|
-
var ImageIcon =
|
|
712
|
+
var ImageIcon = _ref8 => {
|
|
454
713
|
var {
|
|
455
714
|
widthHeight = 24,
|
|
456
715
|
color = 'currentColor',
|
|
457
716
|
filled = true,
|
|
458
717
|
strokeWidth = 1
|
|
459
|
-
} =
|
|
460
|
-
props = _objectWithoutPropertiesLoose(
|
|
718
|
+
} = _ref8,
|
|
719
|
+
props = _objectWithoutPropertiesLoose(_ref8, _excluded8);
|
|
461
720
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
462
721
|
widthHeight: widthHeight,
|
|
463
722
|
color: color
|
|
@@ -489,14 +748,14 @@ var ImageIcon = _ref6 => {
|
|
|
489
748
|
strokeWidth: strokeWidth
|
|
490
749
|
})));
|
|
491
750
|
};
|
|
492
|
-
var TwitterIcon =
|
|
751
|
+
var TwitterIcon = _ref9 => {
|
|
493
752
|
var {
|
|
494
753
|
widthHeight = 24,
|
|
495
754
|
color = 'currentColor',
|
|
496
755
|
filled = true,
|
|
497
756
|
strokeWidth = 1
|
|
498
|
-
} =
|
|
499
|
-
props = _objectWithoutPropertiesLoose(
|
|
757
|
+
} = _ref9,
|
|
758
|
+
props = _objectWithoutPropertiesLoose(_ref9, _excluded9);
|
|
500
759
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
501
760
|
widthHeight: widthHeight,
|
|
502
761
|
color: color
|
|
@@ -511,14 +770,14 @@ var TwitterIcon = _ref7 => {
|
|
|
511
770
|
strokeWidth: filled ? 0 : strokeWidth
|
|
512
771
|
})));
|
|
513
772
|
};
|
|
514
|
-
var XIcon =
|
|
773
|
+
var XIcon = _ref10 => {
|
|
515
774
|
var {
|
|
516
775
|
widthHeight = 24,
|
|
517
776
|
color = 'currentColor',
|
|
518
777
|
filled = true,
|
|
519
778
|
strokeWidth = 1
|
|
520
|
-
} =
|
|
521
|
-
props = _objectWithoutPropertiesLoose(
|
|
779
|
+
} = _ref10,
|
|
780
|
+
props = _objectWithoutPropertiesLoose(_ref10, _excluded10);
|
|
522
781
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
523
782
|
widthHeight: widthHeight,
|
|
524
783
|
color: color
|
|
@@ -534,14 +793,14 @@ var XIcon = _ref8 => {
|
|
|
534
793
|
})));
|
|
535
794
|
};
|
|
536
795
|
// Example of a Twitch Icon
|
|
537
|
-
var TwitchIcon =
|
|
796
|
+
var TwitchIcon = _ref11 => {
|
|
538
797
|
var {
|
|
539
798
|
widthHeight = 24,
|
|
540
799
|
color = 'currentColor',
|
|
541
800
|
filled = true,
|
|
542
801
|
strokeWidth = 1
|
|
543
|
-
} =
|
|
544
|
-
props = _objectWithoutPropertiesLoose(
|
|
802
|
+
} = _ref11,
|
|
803
|
+
props = _objectWithoutPropertiesLoose(_ref11, _excluded11);
|
|
545
804
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
546
805
|
widthHeight: widthHeight,
|
|
547
806
|
color: color
|
|
@@ -562,14 +821,14 @@ var TwitchIcon = _ref9 => {
|
|
|
562
821
|
})));
|
|
563
822
|
};
|
|
564
823
|
// Example of another Icon: CloseIcon
|
|
565
|
-
var CloseIcon =
|
|
824
|
+
var CloseIcon = _ref12 => {
|
|
566
825
|
var {
|
|
567
826
|
widthHeight = 24,
|
|
568
827
|
color = 'currentColor',
|
|
569
828
|
filled = false,
|
|
570
829
|
strokeWidth = 1
|
|
571
|
-
} =
|
|
572
|
-
props = _objectWithoutPropertiesLoose(
|
|
830
|
+
} = _ref12,
|
|
831
|
+
props = _objectWithoutPropertiesLoose(_ref12, _excluded12);
|
|
573
832
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
574
833
|
widthHeight: widthHeight,
|
|
575
834
|
color: color
|
|
@@ -591,14 +850,14 @@ var CloseIcon = _ref10 => {
|
|
|
591
850
|
y2: "18"
|
|
592
851
|
})));
|
|
593
852
|
};
|
|
594
|
-
var InstagramIcon =
|
|
853
|
+
var InstagramIcon = _ref13 => {
|
|
595
854
|
var {
|
|
596
855
|
widthHeight = 24,
|
|
597
856
|
color = 'currentColor',
|
|
598
857
|
filled = false,
|
|
599
858
|
strokeWidth = 1
|
|
600
|
-
} =
|
|
601
|
-
props = _objectWithoutPropertiesLoose(
|
|
859
|
+
} = _ref13,
|
|
860
|
+
props = _objectWithoutPropertiesLoose(_ref13, _excluded13);
|
|
602
861
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
603
862
|
widthHeight: widthHeight,
|
|
604
863
|
color: color
|
|
@@ -622,14 +881,14 @@ var InstagramIcon = _ref11 => {
|
|
|
622
881
|
y2: "6.5"
|
|
623
882
|
})));
|
|
624
883
|
};
|
|
625
|
-
var YoutubeIcon =
|
|
884
|
+
var YoutubeIcon = _ref14 => {
|
|
626
885
|
var {
|
|
627
886
|
widthHeight = 24,
|
|
628
887
|
color = 'currentColor',
|
|
629
888
|
filled = true,
|
|
630
889
|
strokeWidth = 1
|
|
631
|
-
} =
|
|
632
|
-
props = _objectWithoutPropertiesLoose(
|
|
890
|
+
} = _ref14,
|
|
891
|
+
props = _objectWithoutPropertiesLoose(_ref14, _excluded14);
|
|
633
892
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
634
893
|
widthHeight: widthHeight,
|
|
635
894
|
color: color
|
|
@@ -650,14 +909,14 @@ var YoutubeIcon = _ref12 => {
|
|
|
650
909
|
strokeWidth: strokeWidth
|
|
651
910
|
})));
|
|
652
911
|
};
|
|
653
|
-
var FacebookIcon =
|
|
912
|
+
var FacebookIcon = _ref15 => {
|
|
654
913
|
var {
|
|
655
914
|
widthHeight = 24,
|
|
656
915
|
color = 'currentColor',
|
|
657
916
|
filled = true,
|
|
658
917
|
strokeWidth = 1
|
|
659
|
-
} =
|
|
660
|
-
props = _objectWithoutPropertiesLoose(
|
|
918
|
+
} = _ref15,
|
|
919
|
+
props = _objectWithoutPropertiesLoose(_ref15, _excluded15);
|
|
661
920
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
662
921
|
widthHeight: widthHeight,
|
|
663
922
|
color: color
|
|
@@ -672,14 +931,14 @@ var FacebookIcon = _ref13 => {
|
|
|
672
931
|
strokeWidth: filled ? 0 : strokeWidth
|
|
673
932
|
})));
|
|
674
933
|
};
|
|
675
|
-
var LinkedinIcon =
|
|
934
|
+
var LinkedinIcon = _ref16 => {
|
|
676
935
|
var {
|
|
677
936
|
widthHeight = 24,
|
|
678
937
|
color = 'currentColor',
|
|
679
938
|
filled = true,
|
|
680
939
|
strokeWidth = 1
|
|
681
|
-
} =
|
|
682
|
-
props = _objectWithoutPropertiesLoose(
|
|
940
|
+
} = _ref16,
|
|
941
|
+
props = _objectWithoutPropertiesLoose(_ref16, _excluded16);
|
|
683
942
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
684
943
|
widthHeight: widthHeight,
|
|
685
944
|
color: color
|
|
@@ -698,14 +957,14 @@ var LinkedinIcon = _ref14 => {
|
|
|
698
957
|
r: "2"
|
|
699
958
|
})));
|
|
700
959
|
};
|
|
701
|
-
var ThreadsIcon =
|
|
960
|
+
var ThreadsIcon = _ref17 => {
|
|
702
961
|
var {
|
|
703
962
|
widthHeight = 24,
|
|
704
963
|
color = 'currentColor',
|
|
705
964
|
filled = false,
|
|
706
965
|
strokeWidth = 1
|
|
707
|
-
} =
|
|
708
|
-
props = _objectWithoutPropertiesLoose(
|
|
966
|
+
} = _ref17,
|
|
967
|
+
props = _objectWithoutPropertiesLoose(_ref17, _excluded17);
|
|
709
968
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
710
969
|
widthHeight: widthHeight,
|
|
711
970
|
color: color
|
|
@@ -716,19 +975,19 @@ var ThreadsIcon = _ref15 => {
|
|
|
716
975
|
d: "M0 0h24v24H0z",
|
|
717
976
|
fill: "none"
|
|
718
977
|
}), /*#__PURE__*/React.createElement("path", {
|
|
719
|
-
d: "M19 7.5c-1.333 -3 -3.667 -4.5 -7 -4.5c-5 0 -8 2.5 -8 9s3.5 9 8 9s7 -3 7\n -5s-1 -5 -7 -5c-2.5 0 -3 1.25 -3 2.5c0 1.5 1 2.5 2.5 2.5c2.5 0 3.5 -1.5
|
|
978
|
+
d: "M19 7.5c-1.333 -3 -3.667 -4.5 -7 -4.5c-5 0 -8 2.5 -8 9s3.5 9 8 9s7 -3 7\n -5s-1 -5 -7 -5c-2.5 0 -3 1.25 -3 2.5c0 1.5 1 2.5 2.5 2.5c2.5 0 3.5 -1.5\n 3.5 -5s-2 -4 -3 -4s-1.833 .333 -2.5 1"
|
|
720
979
|
})));
|
|
721
980
|
};
|
|
722
981
|
// Example Refactored Icon: MinusIcon without undefined 'padding' prop
|
|
723
|
-
var MinusIcon =
|
|
982
|
+
var MinusIcon = _ref18 => {
|
|
724
983
|
var {
|
|
725
984
|
widthHeight = 24,
|
|
726
985
|
color = 'currentColor',
|
|
727
986
|
filled = false,
|
|
728
987
|
// Assuming minus can be filled; adjust as needed
|
|
729
988
|
strokeWidth = 1
|
|
730
|
-
} =
|
|
731
|
-
props = _objectWithoutPropertiesLoose(
|
|
989
|
+
} = _ref18,
|
|
990
|
+
props = _objectWithoutPropertiesLoose(_ref18, _excluded18);
|
|
732
991
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
733
992
|
widthHeight: widthHeight,
|
|
734
993
|
color: color
|
|
@@ -745,14 +1004,14 @@ var MinusIcon = _ref16 => {
|
|
|
745
1004
|
})));
|
|
746
1005
|
};
|
|
747
1006
|
// Example Refactored Icon: InfoIcon with accessibility enhancements
|
|
748
|
-
var InfoIcon =
|
|
1007
|
+
var InfoIcon = _ref19 => {
|
|
749
1008
|
var {
|
|
750
1009
|
widthHeight = 24,
|
|
751
1010
|
color = 'currentColor',
|
|
752
1011
|
filled = false,
|
|
753
1012
|
strokeWidth = 1
|
|
754
|
-
} =
|
|
755
|
-
props = _objectWithoutPropertiesLoose(
|
|
1013
|
+
} = _ref19,
|
|
1014
|
+
props = _objectWithoutPropertiesLoose(_ref19, _excluded19);
|
|
756
1015
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
757
1016
|
widthHeight: widthHeight,
|
|
758
1017
|
color: color
|
|
@@ -766,14 +1025,14 @@ var InfoIcon = _ref17 => {
|
|
|
766
1025
|
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"
|
|
767
1026
|
})));
|
|
768
1027
|
};
|
|
769
|
-
var PlayIcon =
|
|
1028
|
+
var PlayIcon = _ref20 => {
|
|
770
1029
|
var {
|
|
771
1030
|
widthHeight = 24,
|
|
772
1031
|
color = 'currentColor',
|
|
773
1032
|
filled = true,
|
|
774
1033
|
strokeWidth = 1
|
|
775
|
-
} =
|
|
776
|
-
props = _objectWithoutPropertiesLoose(
|
|
1034
|
+
} = _ref20,
|
|
1035
|
+
props = _objectWithoutPropertiesLoose(_ref20, _excluded20);
|
|
777
1036
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
778
1037
|
widthHeight: widthHeight,
|
|
779
1038
|
color: color
|
|
@@ -785,14 +1044,14 @@ var PlayIcon = _ref18 => {
|
|
|
785
1044
|
d: "M8 5v14l11-7z"
|
|
786
1045
|
})));
|
|
787
1046
|
};
|
|
788
|
-
var PauseIcon =
|
|
1047
|
+
var PauseIcon = _ref21 => {
|
|
789
1048
|
var {
|
|
790
1049
|
widthHeight = 24,
|
|
791
1050
|
color = 'currentColor',
|
|
792
1051
|
filled = true,
|
|
793
1052
|
strokeWidth = 1
|
|
794
|
-
} =
|
|
795
|
-
props = _objectWithoutPropertiesLoose(
|
|
1053
|
+
} = _ref21,
|
|
1054
|
+
props = _objectWithoutPropertiesLoose(_ref21, _excluded21);
|
|
796
1055
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
797
1056
|
widthHeight: widthHeight,
|
|
798
1057
|
color: color
|
|
@@ -804,14 +1063,14 @@ var PauseIcon = _ref19 => {
|
|
|
804
1063
|
d: "M6 4h4v16H6V4zm8 0h4v16h-4V4z"
|
|
805
1064
|
})));
|
|
806
1065
|
};
|
|
807
|
-
var HeartIcon =
|
|
1066
|
+
var HeartIcon = _ref22 => {
|
|
808
1067
|
var {
|
|
809
1068
|
widthHeight = 24,
|
|
810
1069
|
color = 'currentColor',
|
|
811
1070
|
filled = true,
|
|
812
1071
|
strokeWidth = 1
|
|
813
|
-
} =
|
|
814
|
-
props = _objectWithoutPropertiesLoose(
|
|
1072
|
+
} = _ref22,
|
|
1073
|
+
props = _objectWithoutPropertiesLoose(_ref22, _excluded22);
|
|
815
1074
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
816
1075
|
widthHeight: widthHeight,
|
|
817
1076
|
color: color
|
|
@@ -823,14 +1082,14 @@ var HeartIcon = _ref20 => {
|
|
|
823
1082
|
d: "M20.84 4.61c-1.54-1.56-4.04-1.56-5.59 0l-.7.72-.7-.72a3.95 3.95 0 0 0-5.59 0c-1.56 1.56-1.56 4.09 0 5.66l6.29 6.36 6.29-6.36c1.56-1.56 1.56-4.09 0-5.66z"
|
|
824
1083
|
})));
|
|
825
1084
|
};
|
|
826
|
-
var StarIcon =
|
|
1085
|
+
var StarIcon = _ref23 => {
|
|
827
1086
|
var {
|
|
828
1087
|
widthHeight = 24,
|
|
829
1088
|
color = 'currentColor',
|
|
830
1089
|
filled = true,
|
|
831
1090
|
strokeWidth = 1
|
|
832
|
-
} =
|
|
833
|
-
props = _objectWithoutPropertiesLoose(
|
|
1091
|
+
} = _ref23,
|
|
1092
|
+
props = _objectWithoutPropertiesLoose(_ref23, _excluded23);
|
|
834
1093
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
835
1094
|
widthHeight: widthHeight,
|
|
836
1095
|
color: color
|
|
@@ -842,14 +1101,14 @@ var StarIcon = _ref21 => {
|
|
|
842
1101
|
points: "12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"
|
|
843
1102
|
})));
|
|
844
1103
|
};
|
|
845
|
-
var SaveIcon =
|
|
1104
|
+
var SaveIcon = _ref24 => {
|
|
846
1105
|
var {
|
|
847
1106
|
widthHeight = 24,
|
|
848
1107
|
color = 'currentColor',
|
|
849
1108
|
filled = false,
|
|
850
1109
|
strokeWidth = 1
|
|
851
|
-
} =
|
|
852
|
-
props = _objectWithoutPropertiesLoose(
|
|
1110
|
+
} = _ref24,
|
|
1111
|
+
props = _objectWithoutPropertiesLoose(_ref24, _excluded24);
|
|
853
1112
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
854
1113
|
widthHeight: widthHeight,
|
|
855
1114
|
color: color
|
|
@@ -865,14 +1124,14 @@ var SaveIcon = _ref22 => {
|
|
|
865
1124
|
points: "7 3 7 8 15 8"
|
|
866
1125
|
})));
|
|
867
1126
|
};
|
|
868
|
-
var WarningIcon =
|
|
1127
|
+
var WarningIcon = _ref25 => {
|
|
869
1128
|
var {
|
|
870
1129
|
widthHeight = 24,
|
|
871
1130
|
color = 'currentColor',
|
|
872
1131
|
filled = false,
|
|
873
1132
|
strokeWidth = 1
|
|
874
|
-
} =
|
|
875
|
-
props = _objectWithoutPropertiesLoose(
|
|
1133
|
+
} = _ref25,
|
|
1134
|
+
props = _objectWithoutPropertiesLoose(_ref25, _excluded25);
|
|
876
1135
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
877
1136
|
widthHeight: widthHeight,
|
|
878
1137
|
color: color
|
|
@@ -896,14 +1155,14 @@ var WarningIcon = _ref23 => {
|
|
|
896
1155
|
y2: "15"
|
|
897
1156
|
})));
|
|
898
1157
|
};
|
|
899
|
-
var BatteryIcon =
|
|
1158
|
+
var BatteryIcon = _ref26 => {
|
|
900
1159
|
var {
|
|
901
1160
|
widthHeight = 24,
|
|
902
1161
|
color = 'currentColor',
|
|
903
1162
|
filled = true,
|
|
904
1163
|
strokeWidth = 1
|
|
905
|
-
} =
|
|
906
|
-
props = _objectWithoutPropertiesLoose(
|
|
1164
|
+
} = _ref26,
|
|
1165
|
+
props = _objectWithoutPropertiesLoose(_ref26, _excluded26);
|
|
907
1166
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
908
1167
|
widthHeight: widthHeight,
|
|
909
1168
|
color: color
|
|
@@ -915,14 +1174,14 @@ var BatteryIcon = _ref24 => {
|
|
|
915
1174
|
d: "M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z"
|
|
916
1175
|
})));
|
|
917
1176
|
};
|
|
918
|
-
var BookmarkIcon =
|
|
1177
|
+
var BookmarkIcon = _ref27 => {
|
|
919
1178
|
var {
|
|
920
1179
|
widthHeight = 24,
|
|
921
1180
|
color = 'currentColor',
|
|
922
1181
|
filled = false,
|
|
923
1182
|
strokeWidth = 1
|
|
924
|
-
} =
|
|
925
|
-
props = _objectWithoutPropertiesLoose(
|
|
1183
|
+
} = _ref27,
|
|
1184
|
+
props = _objectWithoutPropertiesLoose(_ref27, _excluded27);
|
|
926
1185
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
927
1186
|
widthHeight: widthHeight,
|
|
928
1187
|
color: color
|
|
@@ -934,14 +1193,14 @@ var BookmarkIcon = _ref25 => {
|
|
|
934
1193
|
d: "M17 3H7c-1.1 0-2 .9-2 2v16l7-3 7 3V5c0-1.1-.9-2-2-2z"
|
|
935
1194
|
})));
|
|
936
1195
|
};
|
|
937
|
-
var CloudIcon =
|
|
1196
|
+
var CloudIcon = _ref28 => {
|
|
938
1197
|
var {
|
|
939
1198
|
widthHeight = 24,
|
|
940
1199
|
color = 'currentColor',
|
|
941
1200
|
filled = true,
|
|
942
1201
|
strokeWidth = 1
|
|
943
|
-
} =
|
|
944
|
-
props = _objectWithoutPropertiesLoose(
|
|
1202
|
+
} = _ref28,
|
|
1203
|
+
props = _objectWithoutPropertiesLoose(_ref28, _excluded28);
|
|
945
1204
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
946
1205
|
widthHeight: widthHeight,
|
|
947
1206
|
color: color
|
|
@@ -953,14 +1212,14 @@ var CloudIcon = _ref26 => {
|
|
|
953
1212
|
d: "M18 10h-1.26A8 8 0 109 20h9a5 5 0 000-10z"
|
|
954
1213
|
})));
|
|
955
1214
|
};
|
|
956
|
-
var CopyIcon =
|
|
1215
|
+
var CopyIcon = _ref29 => {
|
|
957
1216
|
var {
|
|
958
1217
|
widthHeight = 24,
|
|
959
1218
|
color = 'currentColor',
|
|
960
1219
|
filled = false,
|
|
961
1220
|
strokeWidth = 1
|
|
962
|
-
} =
|
|
963
|
-
props = _objectWithoutPropertiesLoose(
|
|
1221
|
+
} = _ref29,
|
|
1222
|
+
props = _objectWithoutPropertiesLoose(_ref29, _excluded29);
|
|
964
1223
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
965
1224
|
widthHeight: widthHeight,
|
|
966
1225
|
color: color
|
|
@@ -979,14 +1238,14 @@ var CopyIcon = _ref27 => {
|
|
|
979
1238
|
d: "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"
|
|
980
1239
|
})));
|
|
981
1240
|
};
|
|
982
|
-
var DustBinIcon =
|
|
1241
|
+
var DustBinIcon = _ref30 => {
|
|
983
1242
|
var {
|
|
984
1243
|
widthHeight = 24,
|
|
985
1244
|
color = 'currentColor',
|
|
986
1245
|
filled = false,
|
|
987
1246
|
strokeWidth = 1
|
|
988
|
-
} =
|
|
989
|
-
props = _objectWithoutPropertiesLoose(
|
|
1247
|
+
} = _ref30,
|
|
1248
|
+
props = _objectWithoutPropertiesLoose(_ref30, _excluded30);
|
|
990
1249
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
991
1250
|
widthHeight: widthHeight,
|
|
992
1251
|
color: color
|
|
@@ -998,14 +1257,15 @@ var DustBinIcon = _ref28 => {
|
|
|
998
1257
|
d: "M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"
|
|
999
1258
|
})));
|
|
1000
1259
|
};
|
|
1001
|
-
var
|
|
1260
|
+
var DeleteIcon = DustBinIcon;
|
|
1261
|
+
var EditIcon = _ref31 => {
|
|
1002
1262
|
var {
|
|
1003
1263
|
widthHeight = 24,
|
|
1004
1264
|
color = 'currentColor',
|
|
1005
1265
|
filled = false,
|
|
1006
1266
|
strokeWidth = 1
|
|
1007
|
-
} =
|
|
1008
|
-
props = _objectWithoutPropertiesLoose(
|
|
1267
|
+
} = _ref31,
|
|
1268
|
+
props = _objectWithoutPropertiesLoose(_ref31, _excluded31);
|
|
1009
1269
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1010
1270
|
widthHeight: widthHeight,
|
|
1011
1271
|
color: color
|
|
@@ -1017,14 +1277,14 @@ var EditIcon = _ref29 => {
|
|
|
1017
1277
|
d: "M18.3785 8.44975L8.9636 17.8648C8.6844 18.144 8.3288 18.3343 7.94161 18.4117L4.99988 19.0001L5.58823 16.0583C5.66566 15.6711 5.85597 15.3155 6.13517 15.0363L15.5501 5.62132M18.3785 8.44975L19.7927 7.03553C20.1832 6.64501 20.1832 6.01184 19.7927 5.62132L18.3785 4.20711C17.988 3.81658 17.3548 3.81658 16.9643 4.20711L15.5501 5.62132M18.3785 8.44975L15.5501 5.62132"
|
|
1018
1278
|
})));
|
|
1019
1279
|
};
|
|
1020
|
-
var ErrorIcon =
|
|
1280
|
+
var ErrorIcon = _ref32 => {
|
|
1021
1281
|
var {
|
|
1022
1282
|
widthHeight = 24,
|
|
1023
1283
|
color = 'currentColor',
|
|
1024
1284
|
strokeWidth = 1,
|
|
1025
1285
|
filled = true
|
|
1026
|
-
} =
|
|
1027
|
-
props = _objectWithoutPropertiesLoose(
|
|
1286
|
+
} = _ref32,
|
|
1287
|
+
props = _objectWithoutPropertiesLoose(_ref32, _excluded32);
|
|
1028
1288
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1029
1289
|
widthHeight: widthHeight,
|
|
1030
1290
|
color: color
|
|
@@ -1050,14 +1310,14 @@ var ErrorIcon = _ref30 => {
|
|
|
1050
1310
|
stroke: filled ? 'white' : color
|
|
1051
1311
|
})));
|
|
1052
1312
|
};
|
|
1053
|
-
var DownloadIcon =
|
|
1313
|
+
var DownloadIcon = _ref33 => {
|
|
1054
1314
|
var {
|
|
1055
1315
|
widthHeight = 24,
|
|
1056
1316
|
color = 'currentColor',
|
|
1057
1317
|
filled = true,
|
|
1058
1318
|
strokeWidth = 1
|
|
1059
|
-
} =
|
|
1060
|
-
props = _objectWithoutPropertiesLoose(
|
|
1319
|
+
} = _ref33,
|
|
1320
|
+
props = _objectWithoutPropertiesLoose(_ref33, _excluded33);
|
|
1061
1321
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1062
1322
|
widthHeight: widthHeight,
|
|
1063
1323
|
color: color
|
|
@@ -1069,14 +1329,14 @@ var DownloadIcon = _ref31 => {
|
|
|
1069
1329
|
d: "M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"
|
|
1070
1330
|
})));
|
|
1071
1331
|
};
|
|
1072
|
-
var MenuIcon =
|
|
1332
|
+
var MenuIcon = _ref34 => {
|
|
1073
1333
|
var {
|
|
1074
1334
|
widthHeight = 24,
|
|
1075
1335
|
color = 'currentColor',
|
|
1076
1336
|
strokeWidth = 1,
|
|
1077
1337
|
filled = false
|
|
1078
|
-
} =
|
|
1079
|
-
props = _objectWithoutPropertiesLoose(
|
|
1338
|
+
} = _ref34,
|
|
1339
|
+
props = _objectWithoutPropertiesLoose(_ref34, _excluded34);
|
|
1080
1340
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1081
1341
|
widthHeight: widthHeight,
|
|
1082
1342
|
color: color
|
|
@@ -1104,14 +1364,14 @@ var MenuIcon = _ref32 => {
|
|
|
1104
1364
|
y2: "18"
|
|
1105
1365
|
})));
|
|
1106
1366
|
};
|
|
1107
|
-
var ShareIcon =
|
|
1367
|
+
var ShareIcon = _ref35 => {
|
|
1108
1368
|
var {
|
|
1109
1369
|
widthHeight = 24,
|
|
1110
1370
|
color = 'currentColor',
|
|
1111
1371
|
filled = false,
|
|
1112
1372
|
strokeWidth = 1
|
|
1113
|
-
} =
|
|
1114
|
-
props = _objectWithoutPropertiesLoose(
|
|
1373
|
+
} = _ref35,
|
|
1374
|
+
props = _objectWithoutPropertiesLoose(_ref35, _excluded35);
|
|
1115
1375
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1116
1376
|
widthHeight: widthHeight,
|
|
1117
1377
|
color: color
|
|
@@ -1145,14 +1405,14 @@ var ShareIcon = _ref33 => {
|
|
|
1145
1405
|
y2: "10.49"
|
|
1146
1406
|
})));
|
|
1147
1407
|
};
|
|
1148
|
-
var RefreshIcon =
|
|
1408
|
+
var RefreshIcon = _ref36 => {
|
|
1149
1409
|
var {
|
|
1150
1410
|
widthHeight = 24,
|
|
1151
1411
|
color = 'currentColor',
|
|
1152
1412
|
strokeWidth = 1,
|
|
1153
1413
|
filled = false
|
|
1154
|
-
} =
|
|
1155
|
-
props = _objectWithoutPropertiesLoose(
|
|
1414
|
+
} = _ref36,
|
|
1415
|
+
props = _objectWithoutPropertiesLoose(_ref36, _excluded36);
|
|
1156
1416
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1157
1417
|
widthHeight: widthHeight,
|
|
1158
1418
|
color: color
|
|
@@ -1166,14 +1426,14 @@ var RefreshIcon = _ref34 => {
|
|
|
1166
1426
|
d: "M20.49 15a9 9 0 1 1-2.13-9.36L23 10"
|
|
1167
1427
|
})));
|
|
1168
1428
|
};
|
|
1169
|
-
var PrintIcon =
|
|
1429
|
+
var PrintIcon = _ref37 => {
|
|
1170
1430
|
var {
|
|
1171
1431
|
widthHeight = 24,
|
|
1172
1432
|
color = 'currentColor',
|
|
1173
1433
|
filled = true,
|
|
1174
1434
|
strokeWidth = 1
|
|
1175
|
-
} =
|
|
1176
|
-
props = _objectWithoutPropertiesLoose(
|
|
1435
|
+
} = _ref37,
|
|
1436
|
+
props = _objectWithoutPropertiesLoose(_ref37, _excluded37);
|
|
1177
1437
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1178
1438
|
widthHeight: widthHeight,
|
|
1179
1439
|
color: color
|
|
@@ -1186,14 +1446,14 @@ var PrintIcon = _ref35 => {
|
|
|
1186
1446
|
d: "M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"
|
|
1187
1447
|
})));
|
|
1188
1448
|
};
|
|
1189
|
-
var MagicWandIcon =
|
|
1449
|
+
var MagicWandIcon = _ref38 => {
|
|
1190
1450
|
var {
|
|
1191
1451
|
widthHeight = 24,
|
|
1192
1452
|
color = 'currentColor',
|
|
1193
1453
|
strokeWidth = 1,
|
|
1194
1454
|
filled = true
|
|
1195
|
-
} =
|
|
1196
|
-
props = _objectWithoutPropertiesLoose(
|
|
1455
|
+
} = _ref38,
|
|
1456
|
+
props = _objectWithoutPropertiesLoose(_ref38, _excluded38);
|
|
1197
1457
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1198
1458
|
widthHeight: widthHeight,
|
|
1199
1459
|
color: color
|
|
@@ -1216,14 +1476,14 @@ var MagicWandIcon = _ref36 => {
|
|
|
1216
1476
|
d: "M16 15L16.7 16.5L18 17L16.7 17.5L16 19L15.3 17.5L14 17L15.3 16.5L16 15Z"
|
|
1217
1477
|
})));
|
|
1218
1478
|
};
|
|
1219
|
-
var SliderVerticalIcon =
|
|
1479
|
+
var SliderVerticalIcon = _ref39 => {
|
|
1220
1480
|
var {
|
|
1221
1481
|
widthHeight = 24,
|
|
1222
1482
|
color = 'currentColor',
|
|
1223
1483
|
strokeWidth = 1,
|
|
1224
1484
|
filled = false
|
|
1225
|
-
} =
|
|
1226
|
-
props = _objectWithoutPropertiesLoose(
|
|
1485
|
+
} = _ref39,
|
|
1486
|
+
props = _objectWithoutPropertiesLoose(_ref39, _excluded39);
|
|
1227
1487
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1228
1488
|
widthHeight: widthHeight,
|
|
1229
1489
|
color: color
|
|
@@ -1287,14 +1547,14 @@ var SliderVerticalIcon = _ref37 => {
|
|
|
1287
1547
|
y2: "16"
|
|
1288
1548
|
})));
|
|
1289
1549
|
};
|
|
1290
|
-
var PanelIcon =
|
|
1550
|
+
var PanelIcon = _ref40 => {
|
|
1291
1551
|
var {
|
|
1292
1552
|
widthHeight = 24,
|
|
1293
1553
|
color = 'currentColor',
|
|
1294
1554
|
strokeWidth = 1,
|
|
1295
1555
|
filled = false
|
|
1296
|
-
} =
|
|
1297
|
-
props = _objectWithoutPropertiesLoose(
|
|
1556
|
+
} = _ref40,
|
|
1557
|
+
props = _objectWithoutPropertiesLoose(_ref40, _excluded40);
|
|
1298
1558
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1299
1559
|
widthHeight: widthHeight,
|
|
1300
1560
|
color: color
|
|
@@ -1330,14 +1590,14 @@ var PanelIcon = _ref38 => {
|
|
|
1330
1590
|
y2: "15"
|
|
1331
1591
|
})));
|
|
1332
1592
|
};
|
|
1333
|
-
var FilterIcon =
|
|
1593
|
+
var FilterIcon = _ref41 => {
|
|
1334
1594
|
var {
|
|
1335
1595
|
widthHeight = 24,
|
|
1336
1596
|
color = 'currentColor',
|
|
1337
1597
|
filled = false,
|
|
1338
1598
|
strokeWidth = 1
|
|
1339
|
-
} =
|
|
1340
|
-
props = _objectWithoutPropertiesLoose(
|
|
1599
|
+
} = _ref41,
|
|
1600
|
+
props = _objectWithoutPropertiesLoose(_ref41, _excluded41);
|
|
1341
1601
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1342
1602
|
widthHeight: widthHeight,
|
|
1343
1603
|
color: color
|
|
@@ -1349,14 +1609,14 @@ var FilterIcon = _ref39 => {
|
|
|
1349
1609
|
d: "M3 4h18l-7 10v5l-4 2v-7L3 4z"
|
|
1350
1610
|
})));
|
|
1351
1611
|
};
|
|
1352
|
-
var HomeIcon =
|
|
1612
|
+
var HomeIcon = _ref42 => {
|
|
1353
1613
|
var {
|
|
1354
1614
|
widthHeight = 24,
|
|
1355
1615
|
color = 'currentColor',
|
|
1356
1616
|
filled = true,
|
|
1357
1617
|
strokeWidth = 1
|
|
1358
|
-
} =
|
|
1359
|
-
props = _objectWithoutPropertiesLoose(
|
|
1618
|
+
} = _ref42,
|
|
1619
|
+
props = _objectWithoutPropertiesLoose(_ref42, _excluded42);
|
|
1360
1620
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1361
1621
|
widthHeight: widthHeight,
|
|
1362
1622
|
color: color
|
|
@@ -1368,14 +1628,14 @@ var HomeIcon = _ref40 => {
|
|
|
1368
1628
|
d: "M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8h5z"
|
|
1369
1629
|
})));
|
|
1370
1630
|
};
|
|
1371
|
-
var LocationIcon =
|
|
1631
|
+
var LocationIcon = _ref43 => {
|
|
1372
1632
|
var {
|
|
1373
1633
|
widthHeight = 24,
|
|
1374
1634
|
color = 'currentColor',
|
|
1375
1635
|
filled = true,
|
|
1376
1636
|
strokeWidth = 1
|
|
1377
|
-
} =
|
|
1378
|
-
props = _objectWithoutPropertiesLoose(
|
|
1637
|
+
} = _ref43,
|
|
1638
|
+
props = _objectWithoutPropertiesLoose(_ref43, _excluded43);
|
|
1379
1639
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1380
1640
|
widthHeight: widthHeight,
|
|
1381
1641
|
color: color
|
|
@@ -1387,14 +1647,14 @@ var LocationIcon = _ref41 => {
|
|
|
1387
1647
|
d: "M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"
|
|
1388
1648
|
})));
|
|
1389
1649
|
};
|
|
1390
|
-
var LockIcon =
|
|
1650
|
+
var LockIcon = _ref44 => {
|
|
1391
1651
|
var {
|
|
1392
1652
|
widthHeight = 24,
|
|
1393
1653
|
color = 'currentColor',
|
|
1394
1654
|
filled = false,
|
|
1395
1655
|
strokeWidth = 1
|
|
1396
|
-
} =
|
|
1397
|
-
props = _objectWithoutPropertiesLoose(
|
|
1656
|
+
} = _ref44,
|
|
1657
|
+
props = _objectWithoutPropertiesLoose(_ref44, _excluded44);
|
|
1398
1658
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1399
1659
|
widthHeight: widthHeight,
|
|
1400
1660
|
color: color
|
|
@@ -1402,7 +1662,9 @@ var LockIcon = _ref42 => {
|
|
|
1402
1662
|
viewBox: "0 0 24 24",
|
|
1403
1663
|
"aria-hidden": "false",
|
|
1404
1664
|
focusable: "false"
|
|
1405
|
-
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React.createElement("
|
|
1665
|
+
}, getSvgProps(filled, color, strokeWidth)), filled ? (/*#__PURE__*/React.createElement("path", {
|
|
1666
|
+
d: "M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"
|
|
1667
|
+
})) : (/*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("rect", {
|
|
1406
1668
|
x: "3",
|
|
1407
1669
|
y: "11",
|
|
1408
1670
|
width: "18",
|
|
@@ -1411,16 +1673,20 @@ var LockIcon = _ref42 => {
|
|
|
1411
1673
|
ry: "2"
|
|
1412
1674
|
}), /*#__PURE__*/React.createElement("path", {
|
|
1413
1675
|
d: "M7 11V7a5 5 0 0 1 10 0v4"
|
|
1414
|
-
})
|
|
1676
|
+
}), /*#__PURE__*/React.createElement("circle", {
|
|
1677
|
+
cx: "12",
|
|
1678
|
+
cy: "16",
|
|
1679
|
+
r: "1.5"
|
|
1680
|
+
})))));
|
|
1415
1681
|
};
|
|
1416
|
-
var MicrophoneIcon =
|
|
1682
|
+
var MicrophoneIcon = _ref45 => {
|
|
1417
1683
|
var {
|
|
1418
1684
|
widthHeight = 24,
|
|
1419
1685
|
color = 'currentColor',
|
|
1420
1686
|
filled = false,
|
|
1421
1687
|
strokeWidth = 1
|
|
1422
|
-
} =
|
|
1423
|
-
props = _objectWithoutPropertiesLoose(
|
|
1688
|
+
} = _ref45,
|
|
1689
|
+
props = _objectWithoutPropertiesLoose(_ref45, _excluded45);
|
|
1424
1690
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1425
1691
|
widthHeight: widthHeight,
|
|
1426
1692
|
color: color
|
|
@@ -1446,14 +1712,14 @@ var MicrophoneIcon = _ref43 => {
|
|
|
1446
1712
|
y2: "23"
|
|
1447
1713
|
})));
|
|
1448
1714
|
};
|
|
1449
|
-
var MoonIcon =
|
|
1715
|
+
var MoonIcon = _ref46 => {
|
|
1450
1716
|
var {
|
|
1451
1717
|
widthHeight = 24,
|
|
1452
1718
|
color = 'currentColor',
|
|
1453
1719
|
filled = true,
|
|
1454
1720
|
strokeWidth = 1
|
|
1455
|
-
} =
|
|
1456
|
-
props = _objectWithoutPropertiesLoose(
|
|
1721
|
+
} = _ref46,
|
|
1722
|
+
props = _objectWithoutPropertiesLoose(_ref46, _excluded46);
|
|
1457
1723
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1458
1724
|
widthHeight: widthHeight,
|
|
1459
1725
|
color: color
|
|
@@ -1465,14 +1731,14 @@ var MoonIcon = _ref44 => {
|
|
|
1465
1731
|
d: "M21 12.79A9 9 0 1111.21 3 7 7 0 0021 12.79z"
|
|
1466
1732
|
})));
|
|
1467
1733
|
};
|
|
1468
|
-
var NotificationIcon =
|
|
1734
|
+
var NotificationIcon = _ref47 => {
|
|
1469
1735
|
var {
|
|
1470
1736
|
widthHeight = 24,
|
|
1471
1737
|
color = 'currentColor',
|
|
1472
1738
|
filled = false,
|
|
1473
1739
|
strokeWidth = 1
|
|
1474
|
-
} =
|
|
1475
|
-
props = _objectWithoutPropertiesLoose(
|
|
1740
|
+
} = _ref47,
|
|
1741
|
+
props = _objectWithoutPropertiesLoose(_ref47, _excluded47);
|
|
1476
1742
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1477
1743
|
widthHeight: widthHeight,
|
|
1478
1744
|
color: color
|
|
@@ -1486,14 +1752,14 @@ var NotificationIcon = _ref45 => {
|
|
|
1486
1752
|
d: "M13.73 21a2 2 0 0 1-3.46 0"
|
|
1487
1753
|
})));
|
|
1488
1754
|
};
|
|
1489
|
-
var OpenEyeIcon =
|
|
1755
|
+
var OpenEyeIcon = _ref48 => {
|
|
1490
1756
|
var {
|
|
1491
1757
|
widthHeight = 24,
|
|
1492
1758
|
color = 'currentColor',
|
|
1493
1759
|
filled = true,
|
|
1494
1760
|
strokeWidth = 1
|
|
1495
|
-
} =
|
|
1496
|
-
props = _objectWithoutPropertiesLoose(
|
|
1761
|
+
} = _ref48,
|
|
1762
|
+
props = _objectWithoutPropertiesLoose(_ref48, _excluded48);
|
|
1497
1763
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1498
1764
|
widthHeight: widthHeight,
|
|
1499
1765
|
color: color
|
|
@@ -1505,14 +1771,14 @@ var OpenEyeIcon = _ref46 => {
|
|
|
1505
1771
|
d: "M12 4C7 4 2.73 7.11 1 12c1.73 4.89 6 8 11 8s9.27-3.11 11-8c-1.73-4.89-6-8-11-8zm0 12.5c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"
|
|
1506
1772
|
})));
|
|
1507
1773
|
};
|
|
1508
|
-
var ProfileIcon =
|
|
1774
|
+
var ProfileIcon = _ref49 => {
|
|
1509
1775
|
var {
|
|
1510
1776
|
widthHeight = 24,
|
|
1511
1777
|
color = 'currentColor',
|
|
1512
1778
|
filled = true,
|
|
1513
1779
|
strokeWidth = 1
|
|
1514
|
-
} =
|
|
1515
|
-
props = _objectWithoutPropertiesLoose(
|
|
1780
|
+
} = _ref49,
|
|
1781
|
+
props = _objectWithoutPropertiesLoose(_ref49, _excluded49);
|
|
1516
1782
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1517
1783
|
widthHeight: widthHeight,
|
|
1518
1784
|
color: color
|
|
@@ -1525,14 +1791,14 @@ var ProfileIcon = _ref47 => {
|
|
|
1525
1791
|
d: "M12 13c-2.67 0-8 1.34-8 4v2c0 .55.45 1 1 1h14c.55 0 1-.45 1-1v-2c0-2.66-5.33-4-8-4zm0-9c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z M12 2C9.79 2 8 3.79 8 6s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4z M12 13c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z"
|
|
1526
1792
|
}), ' '));
|
|
1527
1793
|
};
|
|
1528
|
-
var SettingsIcon =
|
|
1794
|
+
var SettingsIcon = _ref50 => {
|
|
1529
1795
|
var {
|
|
1530
1796
|
widthHeight = 24,
|
|
1531
1797
|
color = 'currentColor',
|
|
1532
1798
|
filled = false,
|
|
1533
1799
|
strokeWidth = 1
|
|
1534
|
-
} =
|
|
1535
|
-
props = _objectWithoutPropertiesLoose(
|
|
1800
|
+
} = _ref50,
|
|
1801
|
+
props = _objectWithoutPropertiesLoose(_ref50, _excluded50);
|
|
1536
1802
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1537
1803
|
widthHeight: widthHeight,
|
|
1538
1804
|
color: color
|
|
@@ -1544,14 +1810,14 @@ var SettingsIcon = _ref48 => {
|
|
|
1544
1810
|
d: "M19.4 13c0-.3.1-.6.1-1s0-.7-.1-1l2.1-1.6c.2-.2.2-.4.1-.6l-2-3.5c-.1-.2-.4-.3-.6-.2l-2.5 1c-.5-.4-1.1-.7-1.7-.9l-.4-2.6c0-.2-.3-.4-.5-.4h-4c-.2 0-.5.2-.5.4l-.4 2.6c-.6.2-1.2.5-1.7.9l-2.5-1c-.2-.1-.5 0-.6.2l-2 3.5c-.1.2-.1.4.1.6L4.6 11c0 .3-.1.6-.1 1s0 .7.1 1l-2.1 1.6c-.2.2-.2.4-.1.6l2 3.5c.1.2.4.3.6.2l2.5-1c.5.4 1.1.7 1.7.9l.4 2.6c0 .2.3.4.5.4h4c.2 0 .5-.2.5-.4l.4-2.6c.6-.2 1.2-.5 1.7-.9l2.5 1c.2.1.5 0 .6-.2l2-3.5c.1-.2.1-.4-.1-.6L19.4 13zM12 15.5c-1.9 0-3.5-1.6-3.5-3.5s1.6-3.5 3.5-3.5 3.5 1.6 3.5 3.5-1.6 3.5-3.5 3.5z"
|
|
1545
1811
|
})));
|
|
1546
1812
|
};
|
|
1547
|
-
var SuccessIcon =
|
|
1813
|
+
var SuccessIcon = _ref51 => {
|
|
1548
1814
|
var {
|
|
1549
1815
|
widthHeight = 24,
|
|
1550
1816
|
color = 'currentColor',
|
|
1551
1817
|
filled = true,
|
|
1552
1818
|
strokeWidth = 1
|
|
1553
|
-
} =
|
|
1554
|
-
props = _objectWithoutPropertiesLoose(
|
|
1819
|
+
} = _ref51,
|
|
1820
|
+
props = _objectWithoutPropertiesLoose(_ref51, _excluded51);
|
|
1555
1821
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1556
1822
|
widthHeight: widthHeight,
|
|
1557
1823
|
color: color
|
|
@@ -1563,14 +1829,14 @@ var SuccessIcon = _ref49 => {
|
|
|
1563
1829
|
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"
|
|
1564
1830
|
})));
|
|
1565
1831
|
};
|
|
1566
|
-
var UnLikeIcon =
|
|
1832
|
+
var UnLikeIcon = _ref52 => {
|
|
1567
1833
|
var {
|
|
1568
1834
|
widthHeight = 24,
|
|
1569
1835
|
color = 'currentColor',
|
|
1570
1836
|
filled = true,
|
|
1571
1837
|
strokeWidth = 1
|
|
1572
|
-
} =
|
|
1573
|
-
props = _objectWithoutPropertiesLoose(
|
|
1838
|
+
} = _ref52,
|
|
1839
|
+
props = _objectWithoutPropertiesLoose(_ref52, _excluded52);
|
|
1574
1840
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1575
1841
|
widthHeight: widthHeight,
|
|
1576
1842
|
color: color
|
|
@@ -1582,14 +1848,14 @@ var UnLikeIcon = _ref50 => {
|
|
|
1582
1848
|
d: "M15 3H6c-.83 0-1.54.5-1.84 1.22l-3.02 7.05c-.09.23-.14.47-.14.73v2c0 1.1.9 2 2 2h6.31l-.95 4.57-.03.32c0 .41.17.79.44 1.06L9.83 23l6.59-6.59c.36-.36.58-.86.58-1.41V5c0-1.1-.9-2-2-2zm4 0v12h4V3h-4z"
|
|
1583
1849
|
})));
|
|
1584
1850
|
};
|
|
1585
|
-
var ClockIcon =
|
|
1851
|
+
var ClockIcon = _ref53 => {
|
|
1586
1852
|
var {
|
|
1587
1853
|
widthHeight = 24,
|
|
1588
1854
|
color = 'currentColor',
|
|
1589
1855
|
strokeWidth = 1,
|
|
1590
1856
|
filled = false
|
|
1591
|
-
} =
|
|
1592
|
-
props = _objectWithoutPropertiesLoose(
|
|
1857
|
+
} = _ref53,
|
|
1858
|
+
props = _objectWithoutPropertiesLoose(_ref53, _excluded53);
|
|
1593
1859
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1594
1860
|
widthHeight: widthHeight,
|
|
1595
1861
|
color: color
|
|
@@ -1605,14 +1871,14 @@ var ClockIcon = _ref51 => {
|
|
|
1605
1871
|
points: "12 6 12 12 16 14"
|
|
1606
1872
|
})));
|
|
1607
1873
|
};
|
|
1608
|
-
var CameraIcon =
|
|
1874
|
+
var CameraIcon = _ref54 => {
|
|
1609
1875
|
var {
|
|
1610
1876
|
widthHeight = 24,
|
|
1611
1877
|
color = 'currentColor',
|
|
1612
1878
|
strokeWidth = 1,
|
|
1613
1879
|
filled = false
|
|
1614
|
-
} =
|
|
1615
|
-
props = _objectWithoutPropertiesLoose(
|
|
1880
|
+
} = _ref54,
|
|
1881
|
+
props = _objectWithoutPropertiesLoose(_ref54, _excluded54);
|
|
1616
1882
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1617
1883
|
widthHeight: widthHeight,
|
|
1618
1884
|
color: color
|
|
@@ -1628,14 +1894,14 @@ var CameraIcon = _ref52 => {
|
|
|
1628
1894
|
r: "4"
|
|
1629
1895
|
})));
|
|
1630
1896
|
};
|
|
1631
|
-
var BluetoothIcon =
|
|
1897
|
+
var BluetoothIcon = _ref55 => {
|
|
1632
1898
|
var {
|
|
1633
1899
|
widthHeight = 24,
|
|
1634
1900
|
color = 'currentColor',
|
|
1635
1901
|
filled = true,
|
|
1636
1902
|
strokeWidth = 1
|
|
1637
|
-
} =
|
|
1638
|
-
props = _objectWithoutPropertiesLoose(
|
|
1903
|
+
} = _ref55,
|
|
1904
|
+
props = _objectWithoutPropertiesLoose(_ref55, _excluded55);
|
|
1639
1905
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1640
1906
|
widthHeight: widthHeight,
|
|
1641
1907
|
color: color
|
|
@@ -1647,14 +1913,14 @@ var BluetoothIcon = _ref53 => {
|
|
|
1647
1913
|
d: "M17.71 7.71L12 2h-1v7.59L6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 11 14.41V22h1l5.71-5.71-4.3-4.29 4.3-4.29zM13 5.83l1.88 1.88L13 9.59V5.83zm1.88 10.46L13 18.17v-3.76l1.88 1.88z"
|
|
1648
1914
|
})));
|
|
1649
1915
|
};
|
|
1650
|
-
var LikeIcon =
|
|
1916
|
+
var LikeIcon = _ref56 => {
|
|
1651
1917
|
var {
|
|
1652
1918
|
widthHeight = 24,
|
|
1653
1919
|
color = 'currentColor',
|
|
1654
1920
|
filled = true,
|
|
1655
1921
|
strokeWidth = 1
|
|
1656
|
-
} =
|
|
1657
|
-
props = _objectWithoutPropertiesLoose(
|
|
1922
|
+
} = _ref56,
|
|
1923
|
+
props = _objectWithoutPropertiesLoose(_ref56, _excluded56);
|
|
1658
1924
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1659
1925
|
widthHeight: widthHeight,
|
|
1660
1926
|
color: color
|
|
@@ -1666,14 +1932,14 @@ var LikeIcon = _ref54 => {
|
|
|
1666
1932
|
d: "M1 21h4V9H1v12zm22-11c0-1.1-.9-2-2-2h-6.31l.95-4.57.03-.32c0-.41-.17-.79-.44-1.06L14.17 1 7.59 7.59C7.22 7.95 7 8.45 7 9v10c0 1.1.9 2 2 2h9c.83 0 1.54-.5 1.84-1.22l3.02-7.05c.09-.23.14-.47.14-.73v-2z"
|
|
1667
1933
|
})));
|
|
1668
1934
|
};
|
|
1669
|
-
var UnlockIcon =
|
|
1935
|
+
var UnlockIcon = _ref57 => {
|
|
1670
1936
|
var {
|
|
1671
1937
|
widthHeight = 24,
|
|
1672
1938
|
color = 'currentColor',
|
|
1673
1939
|
filled = false,
|
|
1674
1940
|
strokeWidth = 1
|
|
1675
|
-
} =
|
|
1676
|
-
props = _objectWithoutPropertiesLoose(
|
|
1941
|
+
} = _ref57,
|
|
1942
|
+
props = _objectWithoutPropertiesLoose(_ref57, _excluded57);
|
|
1677
1943
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1678
1944
|
widthHeight: widthHeight,
|
|
1679
1945
|
color: color
|
|
@@ -1681,7 +1947,9 @@ var UnlockIcon = _ref55 => {
|
|
|
1681
1947
|
viewBox: "0 0 24 24",
|
|
1682
1948
|
"aria-hidden": "false",
|
|
1683
1949
|
focusable: "false"
|
|
1684
|
-
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React.createElement("
|
|
1950
|
+
}, getSvgProps(filled, color, strokeWidth)), filled ? (/*#__PURE__*/React.createElement("path", {
|
|
1951
|
+
d: "M12 17c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm6-9h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6h1.9c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2z"
|
|
1952
|
+
})) : (/*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("rect", {
|
|
1685
1953
|
x: "3",
|
|
1686
1954
|
y: "11",
|
|
1687
1955
|
width: "18",
|
|
@@ -1690,16 +1958,20 @@ var UnlockIcon = _ref55 => {
|
|
|
1690
1958
|
ry: "2"
|
|
1691
1959
|
}), /*#__PURE__*/React.createElement("path", {
|
|
1692
1960
|
d: "M7 11V7a5 5 0 0 1 9.9-1"
|
|
1693
|
-
})
|
|
1961
|
+
}), /*#__PURE__*/React.createElement("circle", {
|
|
1962
|
+
cx: "12",
|
|
1963
|
+
cy: "16",
|
|
1964
|
+
r: "1.5"
|
|
1965
|
+
})))));
|
|
1694
1966
|
};
|
|
1695
|
-
var WifiIcon =
|
|
1967
|
+
var WifiIcon = _ref58 => {
|
|
1696
1968
|
var {
|
|
1697
1969
|
widthHeight = 24,
|
|
1698
1970
|
color = 'currentColor',
|
|
1699
1971
|
filled = false,
|
|
1700
1972
|
strokeWidth = 1
|
|
1701
|
-
} =
|
|
1702
|
-
props = _objectWithoutPropertiesLoose(
|
|
1973
|
+
} = _ref58,
|
|
1974
|
+
props = _objectWithoutPropertiesLoose(_ref58, _excluded58);
|
|
1703
1975
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1704
1976
|
widthHeight: widthHeight,
|
|
1705
1977
|
color: color
|
|
@@ -1711,14 +1983,14 @@ var WifiIcon = _ref56 => {
|
|
|
1711
1983
|
d: "M1 9l2 2c4.97-4.97 13.03-4.97 18 0l2-2C16.93 2.93 7.08 2.93 1 9zm8 8l3 3 3-3c-1.65-1.66-4.34-1.66-6 0zm-4-4l2 2c2.76-2.76 7.24-2.76 10 0l2-2C15.14 9.14 8.87 9.14 5 13z"
|
|
1712
1984
|
})));
|
|
1713
1985
|
};
|
|
1714
|
-
var UploadIcon =
|
|
1986
|
+
var UploadIcon = _ref59 => {
|
|
1715
1987
|
var {
|
|
1716
1988
|
widthHeight = 24,
|
|
1717
1989
|
color = 'currentColor',
|
|
1718
1990
|
filled = false,
|
|
1719
1991
|
strokeWidth = 1
|
|
1720
|
-
} =
|
|
1721
|
-
props = _objectWithoutPropertiesLoose(
|
|
1992
|
+
} = _ref59,
|
|
1993
|
+
props = _objectWithoutPropertiesLoose(_ref59, _excluded59);
|
|
1722
1994
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1723
1995
|
widthHeight: widthHeight,
|
|
1724
1996
|
color: color
|
|
@@ -1734,14 +2006,14 @@ var UploadIcon = _ref57 => {
|
|
|
1734
2006
|
d: "M12 12l0 9"
|
|
1735
2007
|
})));
|
|
1736
2008
|
};
|
|
1737
|
-
var SearchIcon =
|
|
2009
|
+
var SearchIcon = _ref60 => {
|
|
1738
2010
|
var {
|
|
1739
2011
|
widthHeight = 24,
|
|
1740
2012
|
color = 'currentColor',
|
|
1741
2013
|
filled = true,
|
|
1742
2014
|
strokeWidth = 1
|
|
1743
|
-
} =
|
|
1744
|
-
props = _objectWithoutPropertiesLoose(
|
|
2015
|
+
} = _ref60,
|
|
2016
|
+
props = _objectWithoutPropertiesLoose(_ref60, _excluded60);
|
|
1745
2017
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1746
2018
|
widthHeight: widthHeight,
|
|
1747
2019
|
color: color
|
|
@@ -1753,14 +2025,14 @@ var SearchIcon = _ref58 => {
|
|
|
1753
2025
|
d: "M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"
|
|
1754
2026
|
})));
|
|
1755
2027
|
};
|
|
1756
|
-
var CloseEyeIcon =
|
|
2028
|
+
var CloseEyeIcon = _ref61 => {
|
|
1757
2029
|
var {
|
|
1758
2030
|
widthHeight = 24,
|
|
1759
2031
|
color = 'currentColor',
|
|
1760
2032
|
filled = true,
|
|
1761
2033
|
strokeWidth = 1
|
|
1762
|
-
} =
|
|
1763
|
-
props = _objectWithoutPropertiesLoose(
|
|
2034
|
+
} = _ref61,
|
|
2035
|
+
props = _objectWithoutPropertiesLoose(_ref61, _excluded61);
|
|
1764
2036
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1765
2037
|
widthHeight: widthHeight,
|
|
1766
2038
|
color: color
|
|
@@ -1773,14 +2045,14 @@ var CloseEyeIcon = _ref59 => {
|
|
|
1773
2045
|
fill: "currentColor"
|
|
1774
2046
|
})));
|
|
1775
2047
|
};
|
|
1776
|
-
var ExternalLinkIcon =
|
|
2048
|
+
var ExternalLinkIcon = _ref62 => {
|
|
1777
2049
|
var {
|
|
1778
2050
|
widthHeight = 24,
|
|
1779
2051
|
color = 'currentColor',
|
|
1780
2052
|
filled = true,
|
|
1781
2053
|
strokeWidth = 1
|
|
1782
|
-
} =
|
|
1783
|
-
props = _objectWithoutPropertiesLoose(
|
|
2054
|
+
} = _ref62,
|
|
2055
|
+
props = _objectWithoutPropertiesLoose(_ref62, _excluded62);
|
|
1784
2056
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1785
2057
|
widthHeight: widthHeight,
|
|
1786
2058
|
color: color
|
|
@@ -1792,14 +2064,14 @@ var ExternalLinkIcon = _ref60 => {
|
|
|
1792
2064
|
d: "M14 3h7v7h-2V5.41l-9.29 9.3-1.42-1.42 9.3-9.29H14V3ZM5 5h5v2H6v11h11v-4h2v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V6a1 1 0 0 1 1-1Z"
|
|
1793
2065
|
})));
|
|
1794
2066
|
};
|
|
1795
|
-
var PlusIcon =
|
|
2067
|
+
var PlusIcon = _ref63 => {
|
|
1796
2068
|
var {
|
|
1797
2069
|
widthHeight = 24,
|
|
1798
2070
|
color = 'currentColor',
|
|
1799
2071
|
filled = false,
|
|
1800
2072
|
strokeWidth = 1
|
|
1801
|
-
} =
|
|
1802
|
-
props = _objectWithoutPropertiesLoose(
|
|
2073
|
+
} = _ref63,
|
|
2074
|
+
props = _objectWithoutPropertiesLoose(_ref63, _excluded63);
|
|
1803
2075
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1804
2076
|
widthHeight: widthHeight,
|
|
1805
2077
|
color: color
|
|
@@ -1821,14 +2093,14 @@ var PlusIcon = _ref61 => {
|
|
|
1821
2093
|
y2: "12"
|
|
1822
2094
|
})));
|
|
1823
2095
|
};
|
|
1824
|
-
var TickIcon =
|
|
2096
|
+
var TickIcon = _ref64 => {
|
|
1825
2097
|
var {
|
|
1826
2098
|
widthHeight = 24,
|
|
1827
2099
|
color = 'currentColor',
|
|
1828
2100
|
filled = false,
|
|
1829
2101
|
strokeWidth = 1
|
|
1830
|
-
} =
|
|
1831
|
-
props = _objectWithoutPropertiesLoose(
|
|
2102
|
+
} = _ref64,
|
|
2103
|
+
props = _objectWithoutPropertiesLoose(_ref64, _excluded64);
|
|
1832
2104
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1833
2105
|
widthHeight: widthHeight,
|
|
1834
2106
|
color: color
|
|
@@ -1842,14 +2114,14 @@ var TickIcon = _ref62 => {
|
|
|
1842
2114
|
strokeLinejoin: "round"
|
|
1843
2115
|
})));
|
|
1844
2116
|
};
|
|
1845
|
-
var BoldArrowIcon =
|
|
2117
|
+
var BoldArrowIcon = _ref65 => {
|
|
1846
2118
|
var {
|
|
1847
2119
|
widthHeight = 24,
|
|
1848
2120
|
color = 'currentColor',
|
|
1849
2121
|
filled = true,
|
|
1850
2122
|
strokeWidth = 1
|
|
1851
|
-
} =
|
|
1852
|
-
props = _objectWithoutPropertiesLoose(
|
|
2123
|
+
} = _ref65,
|
|
2124
|
+
props = _objectWithoutPropertiesLoose(_ref65, _excluded65);
|
|
1853
2125
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1854
2126
|
widthHeight: widthHeight,
|
|
1855
2127
|
color: color
|
|
@@ -1861,14 +2133,14 @@ var BoldArrowIcon = _ref63 => {
|
|
|
1861
2133
|
d: "M12 4l7 7h-4v7h-6v-7H5l7-7z"
|
|
1862
2134
|
})));
|
|
1863
2135
|
};
|
|
1864
|
-
var ArrowIcon =
|
|
2136
|
+
var ArrowIcon = _ref66 => {
|
|
1865
2137
|
var {
|
|
1866
2138
|
widthHeight = 24,
|
|
1867
2139
|
color = 'currentColor',
|
|
1868
2140
|
filled = false,
|
|
1869
2141
|
strokeWidth = 1
|
|
1870
|
-
} =
|
|
1871
|
-
props = _objectWithoutPropertiesLoose(
|
|
2142
|
+
} = _ref66,
|
|
2143
|
+
props = _objectWithoutPropertiesLoose(_ref66, _excluded66);
|
|
1872
2144
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1873
2145
|
widthHeight: widthHeight,
|
|
1874
2146
|
color: color
|
|
@@ -1886,14 +2158,14 @@ var ArrowIcon = _ref64 => {
|
|
|
1886
2158
|
points: "6 12 12 6 18 12"
|
|
1887
2159
|
})));
|
|
1888
2160
|
};
|
|
1889
|
-
var SpinnerIcon =
|
|
2161
|
+
var SpinnerIcon = _ref67 => {
|
|
1890
2162
|
var {
|
|
1891
2163
|
widthHeight = 24,
|
|
1892
2164
|
color = 'currentColor',
|
|
1893
2165
|
filled = false,
|
|
1894
2166
|
strokeWidth = 1
|
|
1895
|
-
} =
|
|
1896
|
-
props = _objectWithoutPropertiesLoose(
|
|
2167
|
+
} = _ref67,
|
|
2168
|
+
props = _objectWithoutPropertiesLoose(_ref67, _excluded67);
|
|
1897
2169
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1898
2170
|
widthHeight: widthHeight,
|
|
1899
2171
|
color: color
|
|
@@ -1911,14 +2183,14 @@ var SpinnerIcon = _ref65 => {
|
|
|
1911
2183
|
strokeOpacity: "1"
|
|
1912
2184
|
})));
|
|
1913
2185
|
};
|
|
1914
|
-
var CalendarIcon =
|
|
2186
|
+
var CalendarIcon = _ref68 => {
|
|
1915
2187
|
var {
|
|
1916
2188
|
widthHeight = 24,
|
|
1917
2189
|
color = 'currentColor',
|
|
1918
2190
|
strokeWidth = 1,
|
|
1919
2191
|
filled = false
|
|
1920
|
-
} =
|
|
1921
|
-
props = _objectWithoutPropertiesLoose(
|
|
2192
|
+
} = _ref68,
|
|
2193
|
+
props = _objectWithoutPropertiesLoose(_ref68, _excluded68);
|
|
1922
2194
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1923
2195
|
widthHeight: widthHeight,
|
|
1924
2196
|
color: color
|
|
@@ -1953,14 +2225,14 @@ var CalendarIcon = _ref66 => {
|
|
|
1953
2225
|
y2: "10"
|
|
1954
2226
|
})));
|
|
1955
2227
|
};
|
|
1956
|
-
var SliderIcon =
|
|
2228
|
+
var SliderIcon = _ref69 => {
|
|
1957
2229
|
var {
|
|
1958
2230
|
widthHeight = 24,
|
|
1959
2231
|
color = 'currentColor',
|
|
1960
2232
|
strokeWidth = 1,
|
|
1961
2233
|
filled = false
|
|
1962
|
-
} =
|
|
1963
|
-
props = _objectWithoutPropertiesLoose(
|
|
2234
|
+
} = _ref69,
|
|
2235
|
+
props = _objectWithoutPropertiesLoose(_ref69, _excluded69);
|
|
1964
2236
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
1965
2237
|
widthHeight: widthHeight,
|
|
1966
2238
|
color: color
|
|
@@ -2015,14 +2287,14 @@ var SliderIcon = _ref67 => {
|
|
|
2015
2287
|
y2: "23"
|
|
2016
2288
|
})));
|
|
2017
2289
|
};
|
|
2018
|
-
var CropIcon =
|
|
2290
|
+
var CropIcon = _ref70 => {
|
|
2019
2291
|
var {
|
|
2020
2292
|
widthHeight = 24,
|
|
2021
2293
|
color = 'currentColor',
|
|
2022
2294
|
strokeWidth = 1,
|
|
2023
2295
|
filled = false
|
|
2024
|
-
} =
|
|
2025
|
-
props = _objectWithoutPropertiesLoose(
|
|
2296
|
+
} = _ref70,
|
|
2297
|
+
props = _objectWithoutPropertiesLoose(_ref70, _excluded70);
|
|
2026
2298
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
2027
2299
|
widthHeight: widthHeight,
|
|
2028
2300
|
color: color
|
|
@@ -2036,14 +2308,14 @@ var CropIcon = _ref68 => {
|
|
|
2036
2308
|
d: "M18 22V8a2 2 0 0 0-2-2H2"
|
|
2037
2309
|
})));
|
|
2038
2310
|
};
|
|
2039
|
-
var ZoomInIcon =
|
|
2311
|
+
var ZoomInIcon = _ref71 => {
|
|
2040
2312
|
var {
|
|
2041
2313
|
widthHeight = 24,
|
|
2042
2314
|
color = 'currentColor',
|
|
2043
2315
|
strokeWidth = 1,
|
|
2044
2316
|
filled = false
|
|
2045
|
-
} =
|
|
2046
|
-
props = _objectWithoutPropertiesLoose(
|
|
2317
|
+
} = _ref71,
|
|
2318
|
+
props = _objectWithoutPropertiesLoose(_ref71, _excluded71);
|
|
2047
2319
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
2048
2320
|
widthHeight: widthHeight,
|
|
2049
2321
|
color: color
|
|
@@ -2072,14 +2344,14 @@ var ZoomInIcon = _ref69 => {
|
|
|
2072
2344
|
y2: "11"
|
|
2073
2345
|
})));
|
|
2074
2346
|
};
|
|
2075
|
-
var ZoomOutIcon =
|
|
2347
|
+
var ZoomOutIcon = _ref72 => {
|
|
2076
2348
|
var {
|
|
2077
2349
|
widthHeight = 24,
|
|
2078
2350
|
color = 'currentColor',
|
|
2079
2351
|
strokeWidth = 1,
|
|
2080
2352
|
filled = false
|
|
2081
|
-
} =
|
|
2082
|
-
props = _objectWithoutPropertiesLoose(
|
|
2353
|
+
} = _ref72,
|
|
2354
|
+
props = _objectWithoutPropertiesLoose(_ref72, _excluded72);
|
|
2083
2355
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
2084
2356
|
widthHeight: widthHeight,
|
|
2085
2357
|
color: color
|
|
@@ -2103,14 +2375,14 @@ var ZoomOutIcon = _ref70 => {
|
|
|
2103
2375
|
y2: "11"
|
|
2104
2376
|
})));
|
|
2105
2377
|
};
|
|
2106
|
-
var TextIcon =
|
|
2378
|
+
var TextIcon = _ref73 => {
|
|
2107
2379
|
var {
|
|
2108
2380
|
widthHeight = 24,
|
|
2109
2381
|
color = 'currentColor',
|
|
2110
2382
|
strokeWidth = 1,
|
|
2111
2383
|
filled = false
|
|
2112
|
-
} =
|
|
2113
|
-
props = _objectWithoutPropertiesLoose(
|
|
2384
|
+
} = _ref73,
|
|
2385
|
+
props = _objectWithoutPropertiesLoose(_ref73, _excluded73);
|
|
2114
2386
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
2115
2387
|
widthHeight: widthHeight,
|
|
2116
2388
|
color: color
|
|
@@ -2135,14 +2407,14 @@ var TextIcon = _ref71 => {
|
|
|
2135
2407
|
y2: "18"
|
|
2136
2408
|
})));
|
|
2137
2409
|
};
|
|
2138
|
-
var ShapeIcon =
|
|
2410
|
+
var ShapeIcon = _ref74 => {
|
|
2139
2411
|
var {
|
|
2140
2412
|
widthHeight = 24,
|
|
2141
2413
|
color = 'currentColor',
|
|
2142
2414
|
strokeWidth = 1,
|
|
2143
2415
|
filled = false
|
|
2144
|
-
} =
|
|
2145
|
-
props = _objectWithoutPropertiesLoose(
|
|
2416
|
+
} = _ref74,
|
|
2417
|
+
props = _objectWithoutPropertiesLoose(_ref74, _excluded74);
|
|
2146
2418
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
2147
2419
|
widthHeight: widthHeight,
|
|
2148
2420
|
color: color
|
|
@@ -2163,14 +2435,14 @@ var ShapeIcon = _ref72 => {
|
|
|
2163
2435
|
points: "16,4 19,8 13,8"
|
|
2164
2436
|
})));
|
|
2165
2437
|
};
|
|
2166
|
-
var RotateIcon =
|
|
2438
|
+
var RotateIcon = _ref75 => {
|
|
2167
2439
|
var {
|
|
2168
2440
|
widthHeight = 24,
|
|
2169
2441
|
color = 'currentColor',
|
|
2170
2442
|
strokeWidth = 1,
|
|
2171
2443
|
filled = false
|
|
2172
|
-
} =
|
|
2173
|
-
props = _objectWithoutPropertiesLoose(
|
|
2444
|
+
} = _ref75,
|
|
2445
|
+
props = _objectWithoutPropertiesLoose(_ref75, _excluded75);
|
|
2174
2446
|
return /*#__PURE__*/React.createElement(IconWrapper, Object.assign({
|
|
2175
2447
|
widthHeight: widthHeight,
|
|
2176
2448
|
color: color
|
|
@@ -2187,6 +2459,8 @@ var RotateIcon = _ref73 => {
|
|
|
2187
2459
|
|
|
2188
2460
|
var Icon = {
|
|
2189
2461
|
__proto__: null,
|
|
2462
|
+
UserIcon: UserIcon,
|
|
2463
|
+
HelpIcon: HelpIcon,
|
|
2190
2464
|
ChevronIcon: ChevronIcon,
|
|
2191
2465
|
DragHandleIcon: DragHandleIcon,
|
|
2192
2466
|
FileIcon: FileIcon,
|
|
@@ -2214,6 +2488,7 @@ var Icon = {
|
|
|
2214
2488
|
CloudIcon: CloudIcon,
|
|
2215
2489
|
CopyIcon: CopyIcon,
|
|
2216
2490
|
DustBinIcon: DustBinIcon,
|
|
2491
|
+
DeleteIcon: DeleteIcon,
|
|
2217
2492
|
EditIcon: EditIcon,
|
|
2218
2493
|
ErrorIcon: ErrorIcon,
|
|
2219
2494
|
DownloadIcon: DownloadIcon,
|
|
@@ -3174,60 +3449,498 @@ var ButtonComponent = props => {
|
|
|
3174
3449
|
};
|
|
3175
3450
|
var Button = ButtonComponent;
|
|
3176
3451
|
|
|
3177
|
-
var
|
|
3178
|
-
|
|
3179
|
-
var
|
|
3180
|
-
|
|
3181
|
-
|
|
3182
|
-
|
|
3183
|
-
|
|
3184
|
-
|
|
3185
|
-
|
|
3186
|
-
|
|
3187
|
-
|
|
3188
|
-
|
|
3189
|
-
|
|
3190
|
-
|
|
3191
|
-
|
|
3192
|
-
|
|
3193
|
-
}
|
|
3194
|
-
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
|
|
3205
|
-
|
|
3206
|
-
|
|
3207
|
-
}
|
|
3208
|
-
|
|
3209
|
-
|
|
3210
|
-
|
|
3211
|
-
|
|
3452
|
+
var useContextMenuState = () => {
|
|
3453
|
+
var [isOpen, setIsOpen] = useState(false);
|
|
3454
|
+
var [position, setPosition] = useState({
|
|
3455
|
+
x: 0,
|
|
3456
|
+
y: 0
|
|
3457
|
+
});
|
|
3458
|
+
var [activeSubmenuId, setActiveSubmenuId] = useState(null);
|
|
3459
|
+
// Close the context menu when clicking outside
|
|
3460
|
+
useEffect(() => {
|
|
3461
|
+
var handleClickOutside = event => {
|
|
3462
|
+
var path = event.composedPath();
|
|
3463
|
+
var isOutside = !path.some(element => (element == null ? void 0 : element.id) === 'context-menu');
|
|
3464
|
+
if (isOutside && isOpen) {
|
|
3465
|
+
setIsOpen(false);
|
|
3466
|
+
setActiveSubmenuId(null);
|
|
3467
|
+
}
|
|
3468
|
+
};
|
|
3469
|
+
// Close the context menu when the window is resized
|
|
3470
|
+
var handleResize = () => {
|
|
3471
|
+
if (isOpen) {
|
|
3472
|
+
setIsOpen(false);
|
|
3473
|
+
setActiveSubmenuId(null);
|
|
3474
|
+
}
|
|
3475
|
+
};
|
|
3476
|
+
// Close the context menu when the escape key is pressed
|
|
3477
|
+
var handleKeyDown = event => {
|
|
3478
|
+
if (event.key === 'Escape' && isOpen) {
|
|
3479
|
+
setIsOpen(false);
|
|
3480
|
+
setActiveSubmenuId(null);
|
|
3481
|
+
}
|
|
3482
|
+
};
|
|
3483
|
+
document.addEventListener('mousedown', handleClickOutside);
|
|
3484
|
+
window.addEventListener('resize', handleResize);
|
|
3485
|
+
document.addEventListener('keydown', handleKeyDown);
|
|
3486
|
+
return () => {
|
|
3487
|
+
document.removeEventListener('mousedown', handleClickOutside);
|
|
3488
|
+
window.removeEventListener('resize', handleResize);
|
|
3489
|
+
document.removeEventListener('keydown', handleKeyDown);
|
|
3490
|
+
};
|
|
3491
|
+
}, [isOpen]);
|
|
3492
|
+
return {
|
|
3493
|
+
isOpen,
|
|
3494
|
+
setIsOpen,
|
|
3495
|
+
position,
|
|
3496
|
+
setPosition,
|
|
3497
|
+
activeSubmenuId,
|
|
3498
|
+
setActiveSubmenuId
|
|
3499
|
+
};
|
|
3212
3500
|
};
|
|
3213
3501
|
|
|
3214
|
-
|
|
3215
|
-
|
|
3216
|
-
|
|
3217
|
-
|
|
3218
|
-
|
|
3219
|
-
|
|
3220
|
-
|
|
3221
|
-
|
|
3222
|
-
|
|
3223
|
-
|
|
3224
|
-
|
|
3225
|
-
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
3502
|
+
var ContextMenuSizes = {
|
|
3503
|
+
sm: {
|
|
3504
|
+
padding: '6px 8px',
|
|
3505
|
+
fontSize: '14px',
|
|
3506
|
+
minWidth: '160px'
|
|
3507
|
+
},
|
|
3508
|
+
md: {
|
|
3509
|
+
padding: '8px 12px',
|
|
3510
|
+
fontSize: '16px',
|
|
3511
|
+
minWidth: '180px'
|
|
3512
|
+
},
|
|
3513
|
+
lg: {
|
|
3514
|
+
padding: '10px 16px',
|
|
3515
|
+
fontSize: '18px',
|
|
3516
|
+
minWidth: '200px'
|
|
3517
|
+
}
|
|
3518
|
+
};
|
|
3519
|
+
var ContextMenuVariants = {
|
|
3520
|
+
default: {
|
|
3521
|
+
backgroundColor: 'white',
|
|
3522
|
+
color: 'color.gray.800'
|
|
3523
|
+
},
|
|
3524
|
+
filled: {
|
|
3525
|
+
backgroundColor: 'color.gray.100',
|
|
3526
|
+
color: 'color.gray.800'
|
|
3527
|
+
},
|
|
3528
|
+
outline: {
|
|
3529
|
+
backgroundColor: 'white',
|
|
3530
|
+
borderWidth: '1px',
|
|
3531
|
+
borderStyle: 'solid',
|
|
3532
|
+
borderColor: 'color.gray.200',
|
|
3533
|
+
color: 'color.gray.800'
|
|
3534
|
+
}
|
|
3535
|
+
};
|
|
3536
|
+
var ContextMenuItemStates = {
|
|
3537
|
+
hover: {
|
|
3538
|
+
backgroundColor: 'color.gray.100'
|
|
3539
|
+
},
|
|
3540
|
+
active: {
|
|
3541
|
+
backgroundColor: 'color.gray.200'
|
|
3542
|
+
},
|
|
3543
|
+
disabled: {
|
|
3544
|
+
opacity: 0.5,
|
|
3545
|
+
cursor: 'not-allowed'
|
|
3546
|
+
}
|
|
3547
|
+
};
|
|
3548
|
+
// Helper function to calculate position based on available space
|
|
3549
|
+
var calculateMenuPosition = function calculateMenuPosition(x, y, menuWidth, menuHeight, windowWidth, windowHeight, side, align) {
|
|
3550
|
+
if (side === void 0) {
|
|
3551
|
+
side = 'right';
|
|
3552
|
+
}
|
|
3553
|
+
if (align === void 0) {
|
|
3554
|
+
align = 'start';
|
|
3555
|
+
}
|
|
3556
|
+
var posX = x;
|
|
3557
|
+
var posY = y;
|
|
3558
|
+
// Adjust horizontal position based on side
|
|
3559
|
+
if (side === 'left') {
|
|
3560
|
+
posX = x - menuWidth;
|
|
3561
|
+
} else if (side === 'right') {
|
|
3562
|
+
posX = x;
|
|
3563
|
+
} else if (side === 'top' || side === 'bottom') {
|
|
3564
|
+
// Adjust horizontal position based on alignment for top/bottom
|
|
3565
|
+
if (align === 'center') {
|
|
3566
|
+
posX = x - menuWidth / 2;
|
|
3567
|
+
} else if (align === 'end') {
|
|
3568
|
+
posX = x - menuWidth;
|
|
3569
|
+
}
|
|
3570
|
+
}
|
|
3571
|
+
// Adjust vertical position based on side
|
|
3572
|
+
if (side === 'top') {
|
|
3573
|
+
posY = y - menuHeight;
|
|
3574
|
+
} else if (side === 'bottom') {
|
|
3575
|
+
posY = y;
|
|
3576
|
+
} else if (side === 'left' || side === 'right') {
|
|
3577
|
+
// Adjust vertical position based on alignment for left/right
|
|
3578
|
+
if (align === 'center') {
|
|
3579
|
+
posY = y - menuHeight / 2;
|
|
3580
|
+
} else if (align === 'end') {
|
|
3581
|
+
posY = y - menuHeight;
|
|
3582
|
+
}
|
|
3583
|
+
}
|
|
3584
|
+
// Ensure menu stays within window bounds
|
|
3585
|
+
if (posX + menuWidth > windowWidth) {
|
|
3586
|
+
posX = windowWidth - menuWidth;
|
|
3587
|
+
}
|
|
3588
|
+
if (posX < 0) {
|
|
3589
|
+
posX = 0;
|
|
3590
|
+
}
|
|
3591
|
+
if (posY + menuHeight > windowHeight) {
|
|
3592
|
+
posY = windowHeight - menuHeight;
|
|
3593
|
+
}
|
|
3594
|
+
if (posY < 0) {
|
|
3595
|
+
posY = 0;
|
|
3596
|
+
}
|
|
3597
|
+
return {
|
|
3598
|
+
x: posX,
|
|
3599
|
+
y: posY
|
|
3600
|
+
};
|
|
3601
|
+
};
|
|
3602
|
+
|
|
3603
|
+
var _excluded$a = ["children", "disableNativeContextMenu", "views"],
|
|
3604
|
+
_excluded2$2 = ["items", "position", "side", "align", "views"],
|
|
3605
|
+
_excluded3$2 = ["item", "views"],
|
|
3606
|
+
_excluded4$2 = ["views"],
|
|
3607
|
+
_excluded5$1 = ["children", "items", "size", "variant", "disableNativeContextMenu", "views"];
|
|
3608
|
+
// Create context for the ContextMenu
|
|
3609
|
+
var ContextMenuContext = /*#__PURE__*/createContext({
|
|
3610
|
+
isOpen: false,
|
|
3611
|
+
setIsOpen: () => {},
|
|
3612
|
+
position: {
|
|
3613
|
+
x: 0,
|
|
3614
|
+
y: 0
|
|
3615
|
+
},
|
|
3616
|
+
setPosition: () => {},
|
|
3617
|
+
activeSubmenuId: null,
|
|
3618
|
+
setActiveSubmenuId: () => {},
|
|
3619
|
+
size: 'md',
|
|
3620
|
+
variant: 'default'
|
|
3621
|
+
});
|
|
3622
|
+
// Provider component for the ContextMenu context
|
|
3623
|
+
var ContextMenuProvider = _ref => {
|
|
3624
|
+
var {
|
|
3625
|
+
children,
|
|
3626
|
+
value
|
|
3627
|
+
} = _ref;
|
|
3628
|
+
return /*#__PURE__*/React.createElement(ContextMenuContext.Provider, {
|
|
3629
|
+
value: value
|
|
3630
|
+
}, children);
|
|
3631
|
+
};
|
|
3632
|
+
// Hook to use the ContextMenu context
|
|
3633
|
+
var useContextMenuContext = () => {
|
|
3634
|
+
var context = useContext(ContextMenuContext);
|
|
3635
|
+
if (!context) {
|
|
3636
|
+
throw new Error('useContextMenuContext must be used within a ContextMenuProvider');
|
|
3637
|
+
}
|
|
3638
|
+
return context;
|
|
3639
|
+
};
|
|
3640
|
+
// ContextMenu Trigger component
|
|
3641
|
+
var ContextMenuTrigger = _ref2 => {
|
|
3642
|
+
var {
|
|
3643
|
+
children,
|
|
3644
|
+
disableNativeContextMenu = true,
|
|
3645
|
+
views
|
|
3646
|
+
} = _ref2,
|
|
3647
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$a);
|
|
3648
|
+
var {
|
|
3649
|
+
setIsOpen,
|
|
3650
|
+
setPosition
|
|
3651
|
+
} = useContextMenuContext();
|
|
3652
|
+
var handleContextMenu = e => {
|
|
3653
|
+
if (disableNativeContextMenu) {
|
|
3654
|
+
e.preventDefault();
|
|
3655
|
+
}
|
|
3656
|
+
setPosition({
|
|
3657
|
+
x: e.clientX,
|
|
3658
|
+
y: e.clientY
|
|
3659
|
+
});
|
|
3660
|
+
setIsOpen(true);
|
|
3661
|
+
};
|
|
3662
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
3663
|
+
onContextMenu: handleContextMenu
|
|
3664
|
+
}, views == null ? void 0 : views.container, props), children);
|
|
3665
|
+
};
|
|
3666
|
+
// ContextMenu Content component
|
|
3667
|
+
var ContextMenuContent = _ref3 => {
|
|
3668
|
+
var {
|
|
3669
|
+
items,
|
|
3670
|
+
position,
|
|
3671
|
+
side = 'right',
|
|
3672
|
+
align = 'start',
|
|
3673
|
+
views
|
|
3674
|
+
} = _ref3,
|
|
3675
|
+
props = _objectWithoutPropertiesLoose(_ref3, _excluded2$2);
|
|
3676
|
+
var {
|
|
3677
|
+
isOpen,
|
|
3678
|
+
position: contextPosition,
|
|
3679
|
+
// activeSubmenuId,
|
|
3680
|
+
// setActiveSubmenuId,
|
|
3681
|
+
// size,
|
|
3682
|
+
variant
|
|
3683
|
+
} = useContextMenuContext();
|
|
3684
|
+
var menuRef = useRef(null);
|
|
3685
|
+
var [menuPosition, setMenuPosition] = useState({
|
|
3686
|
+
x: 0,
|
|
3687
|
+
y: 0
|
|
3688
|
+
});
|
|
3689
|
+
// Calculate the position of the menu
|
|
3690
|
+
useEffect(() => {
|
|
3691
|
+
if (isOpen && menuRef.current) {
|
|
3692
|
+
var menuWidth = menuRef.current.offsetWidth;
|
|
3693
|
+
var menuHeight = menuRef.current.offsetHeight;
|
|
3694
|
+
var windowWidth = window.innerWidth;
|
|
3695
|
+
var windowHeight = window.innerHeight;
|
|
3696
|
+
var pos = position || contextPosition;
|
|
3697
|
+
var calculatedPosition = calculateMenuPosition(pos.x, pos.y, menuWidth, menuHeight, windowWidth, windowHeight, side, align);
|
|
3698
|
+
setMenuPosition(calculatedPosition);
|
|
3699
|
+
}
|
|
3700
|
+
}, [isOpen, contextPosition, position, side, align]);
|
|
3701
|
+
if (!isOpen) {
|
|
3702
|
+
return null;
|
|
3703
|
+
}
|
|
3704
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
3705
|
+
id: "context-menu",
|
|
3706
|
+
ref: menuRef,
|
|
3707
|
+
position: "fixed",
|
|
3708
|
+
top: menuPosition.y,
|
|
3709
|
+
left: menuPosition.x,
|
|
3710
|
+
zIndex: 1000,
|
|
3711
|
+
borderRadius: 4,
|
|
3712
|
+
boxShadow: "0px 2px 8px rgba(0, 0, 0, 0.15)",
|
|
3713
|
+
overflow: "hidden"
|
|
3714
|
+
}, ContextMenuVariants[variant], views == null ? void 0 : views.menu, props), items.map((item, index) => {
|
|
3715
|
+
if (item.divider) {
|
|
3716
|
+
return /*#__PURE__*/React.createElement(ContextMenuDivider, {
|
|
3717
|
+
key: "divider-" + index,
|
|
3718
|
+
views: views
|
|
3719
|
+
});
|
|
3720
|
+
}
|
|
3721
|
+
return /*#__PURE__*/React.createElement(ContextMenuItem, {
|
|
3722
|
+
key: item.id,
|
|
3723
|
+
item: item,
|
|
3724
|
+
views: views
|
|
3725
|
+
});
|
|
3726
|
+
}));
|
|
3727
|
+
};
|
|
3728
|
+
// ContextMenu Item component
|
|
3729
|
+
var ContextMenuItem = _ref4 => {
|
|
3730
|
+
var {
|
|
3731
|
+
item,
|
|
3732
|
+
views
|
|
3733
|
+
} = _ref4,
|
|
3734
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded3$2);
|
|
3735
|
+
var {
|
|
3736
|
+
activeSubmenuId,
|
|
3737
|
+
setActiveSubmenuId,
|
|
3738
|
+
size
|
|
3739
|
+
} = useContextMenuContext();
|
|
3740
|
+
var [isHovered, setIsHovered] = useState(false);
|
|
3741
|
+
var hasSubmenu = item.items && item.items.length > 0;
|
|
3742
|
+
var isSubmenuActive = activeSubmenuId === item.id;
|
|
3743
|
+
var itemRef = useRef(null);
|
|
3744
|
+
var [submenuPosition, setSubmenuPosition] = useState({
|
|
3745
|
+
x: 0,
|
|
3746
|
+
y: 0
|
|
3747
|
+
});
|
|
3748
|
+
// Handle mouse enter event
|
|
3749
|
+
var handleMouseEnter = () => {
|
|
3750
|
+
setIsHovered(true);
|
|
3751
|
+
if (hasSubmenu) {
|
|
3752
|
+
setActiveSubmenuId(item.id);
|
|
3753
|
+
}
|
|
3754
|
+
};
|
|
3755
|
+
// Handle mouse leave event
|
|
3756
|
+
var handleMouseLeave = () => {
|
|
3757
|
+
setIsHovered(false);
|
|
3758
|
+
};
|
|
3759
|
+
// Handle click event
|
|
3760
|
+
var handleClick = () => {
|
|
3761
|
+
if (item.disabled) return;
|
|
3762
|
+
if (!hasSubmenu && item.onClick) {
|
|
3763
|
+
item.onClick();
|
|
3764
|
+
}
|
|
3765
|
+
};
|
|
3766
|
+
// Calculate the position of the submenu
|
|
3767
|
+
useEffect(() => {
|
|
3768
|
+
if (isSubmenuActive && itemRef.current) {
|
|
3769
|
+
var rect = itemRef.current.getBoundingClientRect();
|
|
3770
|
+
setSubmenuPosition({
|
|
3771
|
+
x: rect.right,
|
|
3772
|
+
y: rect.top
|
|
3773
|
+
});
|
|
3774
|
+
}
|
|
3775
|
+
}, [isSubmenuActive]);
|
|
3776
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
3777
|
+
ref: itemRef,
|
|
3778
|
+
display: "flex",
|
|
3779
|
+
alignItems: "center",
|
|
3780
|
+
cursor: item.disabled ? 'not-allowed' : 'pointer',
|
|
3781
|
+
opacity: item.disabled ? 0.5 : 1,
|
|
3782
|
+
position: "relative"
|
|
3783
|
+
}, ContextMenuSizes[size], {
|
|
3784
|
+
_hover: !item.disabled ? ContextMenuItemStates.hover : {},
|
|
3785
|
+
backgroundColor: isHovered && !item.disabled ? 'color.gray.100' : 'transparent',
|
|
3786
|
+
onMouseEnter: handleMouseEnter,
|
|
3787
|
+
onMouseLeave: handleMouseLeave,
|
|
3788
|
+
onClick: handleClick
|
|
3789
|
+
}, views == null ? void 0 : views.item, props), item.icon && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
3790
|
+
marginRight: 8
|
|
3791
|
+
}, views == null ? void 0 : views.icon), item.icon)), /*#__PURE__*/React.createElement(View$1, {
|
|
3792
|
+
flexGrow: 1
|
|
3793
|
+
}, item.label), hasSubmenu && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
3794
|
+
marginLeft: 8
|
|
3795
|
+
}, views == null ? void 0 : views.submenuIndicator), /*#__PURE__*/React.createElement("svg", {
|
|
3796
|
+
width: "16",
|
|
3797
|
+
height: "16",
|
|
3798
|
+
viewBox: "0 0 24 24",
|
|
3799
|
+
fill: "none",
|
|
3800
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
3801
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
3802
|
+
d: "M8.59 16.59L13.17 12L8.59 7.41L10 6L16 12L10 18L8.59 16.59Z",
|
|
3803
|
+
fill: "currentColor"
|
|
3804
|
+
})))), isSubmenuActive && hasSubmenu && (/*#__PURE__*/React.createElement(ContextMenuContent, {
|
|
3805
|
+
items: item.items || [],
|
|
3806
|
+
position: submenuPosition,
|
|
3807
|
+
side: "right",
|
|
3808
|
+
align: "start",
|
|
3809
|
+
views: views
|
|
3810
|
+
})));
|
|
3811
|
+
};
|
|
3812
|
+
// ContextMenu Divider component
|
|
3813
|
+
var ContextMenuDivider = _ref5 => {
|
|
3814
|
+
var {
|
|
3815
|
+
views
|
|
3816
|
+
} = _ref5,
|
|
3817
|
+
props = _objectWithoutPropertiesLoose(_ref5, _excluded4$2);
|
|
3818
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
3819
|
+
height: "1px",
|
|
3820
|
+
backgroundColor: "color.gray.200",
|
|
3821
|
+
margin: "4px 0"
|
|
3822
|
+
}, views == null ? void 0 : views.divider, props));
|
|
3823
|
+
};
|
|
3824
|
+
// Main ContextMenu View component
|
|
3825
|
+
var ContextMenuView = _ref6 => {
|
|
3826
|
+
var {
|
|
3827
|
+
children,
|
|
3828
|
+
items,
|
|
3829
|
+
disableNativeContextMenu = true,
|
|
3830
|
+
views
|
|
3831
|
+
} = _ref6,
|
|
3832
|
+
props = _objectWithoutPropertiesLoose(_ref6, _excluded5$1);
|
|
3833
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ContextMenuTrigger, Object.assign({
|
|
3834
|
+
disableNativeContextMenu: disableNativeContextMenu,
|
|
3835
|
+
views: views
|
|
3836
|
+
}, props), children), /*#__PURE__*/React.createElement(ContextMenuContent, {
|
|
3837
|
+
items: items,
|
|
3838
|
+
views: views
|
|
3839
|
+
}));
|
|
3840
|
+
};
|
|
3841
|
+
|
|
3842
|
+
var _excluded$b = ["children", "items", "size", "variant", "disableNativeContextMenu", "views"];
|
|
3843
|
+
/**
|
|
3844
|
+
* ContextMenu component for displaying a custom context menu on right-click.
|
|
3845
|
+
*/
|
|
3846
|
+
var ContextMenuComponent = _ref => {
|
|
3847
|
+
var {
|
|
3848
|
+
children,
|
|
3849
|
+
items,
|
|
3850
|
+
size = 'md',
|
|
3851
|
+
variant = 'default',
|
|
3852
|
+
disableNativeContextMenu = true,
|
|
3853
|
+
views
|
|
3854
|
+
} = _ref,
|
|
3855
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$b);
|
|
3856
|
+
var {
|
|
3857
|
+
isOpen,
|
|
3858
|
+
setIsOpen,
|
|
3859
|
+
position,
|
|
3860
|
+
setPosition,
|
|
3861
|
+
activeSubmenuId,
|
|
3862
|
+
setActiveSubmenuId
|
|
3863
|
+
} = useContextMenuState();
|
|
3864
|
+
return /*#__PURE__*/React.createElement(ContextMenuProvider, {
|
|
3865
|
+
value: {
|
|
3866
|
+
isOpen,
|
|
3867
|
+
setIsOpen,
|
|
3868
|
+
position,
|
|
3869
|
+
setPosition,
|
|
3870
|
+
activeSubmenuId,
|
|
3871
|
+
setActiveSubmenuId,
|
|
3872
|
+
size,
|
|
3873
|
+
variant
|
|
3874
|
+
}
|
|
3875
|
+
}, /*#__PURE__*/React.createElement(ContextMenuView, Object.assign({
|
|
3876
|
+
items: items,
|
|
3877
|
+
size: size,
|
|
3878
|
+
variant: variant,
|
|
3879
|
+
disableNativeContextMenu: disableNativeContextMenu,
|
|
3880
|
+
views: views
|
|
3881
|
+
}, props), children));
|
|
3882
|
+
};
|
|
3883
|
+
var ContextMenu = ContextMenuComponent;
|
|
3884
|
+
// Assign the sub-components to the main component
|
|
3885
|
+
ContextMenu.Trigger = ContextMenuTrigger;
|
|
3886
|
+
ContextMenu.Content = ContextMenuContent;
|
|
3887
|
+
ContextMenu.Item = ContextMenuItem;
|
|
3888
|
+
ContextMenu.Divider = ContextMenuDivider;
|
|
3889
|
+
|
|
3890
|
+
var _excluded$c = ["src", "color", "views", "themeMode"],
|
|
3891
|
+
_excluded2$3 = ["path"];
|
|
3892
|
+
var FileSVG = _ref => {
|
|
3893
|
+
var {
|
|
3894
|
+
src,
|
|
3895
|
+
color,
|
|
3896
|
+
views
|
|
3897
|
+
} = _ref,
|
|
3898
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$c);
|
|
3899
|
+
var {
|
|
3900
|
+
getColor,
|
|
3901
|
+
themeMode
|
|
3902
|
+
} = useTheme();
|
|
3903
|
+
var Colorprops = color ? {
|
|
3904
|
+
fill: getColor(color, {
|
|
3905
|
+
themeMode
|
|
3906
|
+
}),
|
|
3907
|
+
stroke: getColor(color, {
|
|
3908
|
+
themeMode
|
|
3909
|
+
})
|
|
3910
|
+
} : {};
|
|
3911
|
+
return /*#__PURE__*/React.createElement(Center, Object.assign({}, props, views == null ? void 0 : views.container), /*#__PURE__*/React.createElement(Image, Object.assign({}, Colorprops, {
|
|
3912
|
+
content: 'url("' + src + '")',
|
|
3913
|
+
width: "100%",
|
|
3914
|
+
height: "100%"
|
|
3915
|
+
}, views == null ? void 0 : views.image)));
|
|
3916
|
+
};
|
|
3917
|
+
var FileImage = _ref2 => {
|
|
3918
|
+
var {
|
|
3919
|
+
path
|
|
3920
|
+
} = _ref2,
|
|
3921
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded2$3);
|
|
3922
|
+
return /*#__PURE__*/React.createElement(Image, Object.assign({
|
|
3923
|
+
src: path
|
|
3924
|
+
}, props));
|
|
3925
|
+
};
|
|
3926
|
+
|
|
3927
|
+
// Initializes the custom hook 'useSelectState' for managing the state of the Select component
|
|
3928
|
+
var useSelectState = _ref => {
|
|
3929
|
+
var {
|
|
3930
|
+
placeholder,
|
|
3931
|
+
isMulti,
|
|
3932
|
+
options
|
|
3933
|
+
} = _ref;
|
|
3934
|
+
// Determines the default value based on the 'placeholder' and 'isMulti' props, setting to an empty array for multi-select or an empty string/single default option
|
|
3935
|
+
var defaultValue = placeholder ? isMulti ? [] : '' // If there's a placeholder, set default to empty array for multi-select or empty string for single select
|
|
3936
|
+
: Array.isArray(options) && options.length > 0 ? options[0].value : ''; // If no placeholder, use the first option value if available, otherwise undefined
|
|
3937
|
+
// State hook for managing visibility of the Select dropdown, initially set to hidden
|
|
3938
|
+
var [hide, setHide] = React.useState(true);
|
|
3939
|
+
// State hook for tracking mouse hover status over the Select component
|
|
3940
|
+
var [isHovered, setIsHovered] = React.useState(false);
|
|
3941
|
+
// State hook for tracking focus status of the Select input field
|
|
3942
|
+
var [isFocused, setIsFocused] = React.useState(false);
|
|
3943
|
+
// State hook for managing the value(s) selected by the user, initialized with the default value
|
|
3231
3944
|
var [value, setValue] = React.useState(defaultValue);
|
|
3232
3945
|
// State hook for keeping track of the currently highlighted index in the options list
|
|
3233
3946
|
var [highlightedIndex, setHighlightedIndex] = React.useState(0);
|
|
@@ -3256,7 +3969,7 @@ var useItemState = () => {
|
|
|
3256
3969
|
};
|
|
3257
3970
|
};
|
|
3258
3971
|
|
|
3259
|
-
var _excluded$
|
|
3972
|
+
var _excluded$d = ["children", "views"];
|
|
3260
3973
|
var HelperText = _ref => {
|
|
3261
3974
|
var {
|
|
3262
3975
|
children,
|
|
@@ -3264,7 +3977,7 @@ var HelperText = _ref => {
|
|
|
3264
3977
|
helperText: {}
|
|
3265
3978
|
}
|
|
3266
3979
|
} = _ref,
|
|
3267
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
3980
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$d);
|
|
3268
3981
|
return /*#__PURE__*/React.createElement(Text, Object.assign({
|
|
3269
3982
|
size: "xs",
|
|
3270
3983
|
marginVertical: 0,
|
|
@@ -3273,7 +3986,7 @@ var HelperText = _ref => {
|
|
|
3273
3986
|
}, views['helperText'], props), children);
|
|
3274
3987
|
};
|
|
3275
3988
|
|
|
3276
|
-
var _excluded$
|
|
3989
|
+
var _excluded$e = ["children", "helperText", "error", "views"];
|
|
3277
3990
|
var FieldContainer = _ref => {
|
|
3278
3991
|
var {
|
|
3279
3992
|
children,
|
|
@@ -3281,7 +3994,7 @@ var FieldContainer = _ref => {
|
|
|
3281
3994
|
error = false,
|
|
3282
3995
|
views
|
|
3283
3996
|
} = _ref,
|
|
3284
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
3997
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$e);
|
|
3285
3998
|
return /*#__PURE__*/React.createElement(Vertical, Object.assign({
|
|
3286
3999
|
gap: 5,
|
|
3287
4000
|
position: "relative"
|
|
@@ -3340,7 +4053,7 @@ var PaddingWithoutLabel = {
|
|
|
3340
4053
|
paddingRight: 16
|
|
3341
4054
|
};
|
|
3342
4055
|
|
|
3343
|
-
var _excluded$
|
|
4056
|
+
var _excluded$f = ["label", "shadow", "children", "value", "size", "shape", "variant", "error", "isWithLabel", "isFocused", "isHovered", "isDisabled", "isReadOnly", "views"];
|
|
3344
4057
|
var FieldContent = _ref => {
|
|
3345
4058
|
var {
|
|
3346
4059
|
shadow,
|
|
@@ -3358,7 +4071,7 @@ var FieldContent = _ref => {
|
|
|
3358
4071
|
pickerBox: {}
|
|
3359
4072
|
}
|
|
3360
4073
|
} = _ref,
|
|
3361
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4074
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$f);
|
|
3362
4075
|
var isInteractive = (isHovered || isFocused) && !isDisabled;
|
|
3363
4076
|
var color = error ? 'error' : isInteractive ? 'theme.primary' : 'midgray';
|
|
3364
4077
|
return /*#__PURE__*/React.createElement(Horizontal, Object.assign({
|
|
@@ -3379,12 +4092,12 @@ var FieldContent = _ref => {
|
|
|
3379
4092
|
}, isWithLabel ? PadddingWithLabel : PaddingWithoutLabel, shadow, Shapes[shape], InputVariants[variant], views['box'], props), children);
|
|
3380
4093
|
};
|
|
3381
4094
|
|
|
3382
|
-
var _excluded$
|
|
4095
|
+
var _excluded$g = ["children"];
|
|
3383
4096
|
var FieldIcons = _ref => {
|
|
3384
4097
|
var {
|
|
3385
4098
|
children
|
|
3386
4099
|
} = _ref,
|
|
3387
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4100
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$g);
|
|
3388
4101
|
return /*#__PURE__*/React.createElement(Center, Object.assign({
|
|
3389
4102
|
gap: 10,
|
|
3390
4103
|
right: 16,
|
|
@@ -3436,7 +4149,7 @@ var HeadingSizes$1 = {
|
|
|
3436
4149
|
}
|
|
3437
4150
|
};
|
|
3438
4151
|
|
|
3439
|
-
var _excluded$
|
|
4152
|
+
var _excluded$h = ["children", "heading", "isItalic", "isUnderlined", "isStriked", "weight", "size"];
|
|
3440
4153
|
var LabelView = _ref => {
|
|
3441
4154
|
var {
|
|
3442
4155
|
children,
|
|
@@ -3452,7 +4165,7 @@ var LabelView = _ref => {
|
|
|
3452
4165
|
size = 'sm'
|
|
3453
4166
|
// The fontSize prop for the Element is determined by the 'size' prop passed to LabelView.
|
|
3454
4167
|
} = _ref,
|
|
3455
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4168
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$h);
|
|
3456
4169
|
// The fontStyle prop toggles between 'italic' and 'normal' based on the 'isItalic' boolean prop.
|
|
3457
4170
|
var headingStyles = heading ? HeadingSizes$1[heading] : {};
|
|
3458
4171
|
// fontWeight is derived from the Typography module, ensuring consistent font weighting across the app.
|
|
@@ -3484,7 +4197,7 @@ React.createElement(LabelView, Object.assign({}, props))
|
|
|
3484
4197
|
var Label = LabelComponent;
|
|
3485
4198
|
// Export the 'LabelComponent' as 'Label' to be reused throughout the project.
|
|
3486
4199
|
|
|
3487
|
-
var _excluded$
|
|
4200
|
+
var _excluded$i = ["children", "size", "error", "color", "views", "helperText"];
|
|
3488
4201
|
var FieldLabel = _ref => {
|
|
3489
4202
|
var {
|
|
3490
4203
|
children,
|
|
@@ -3495,7 +4208,7 @@ var FieldLabel = _ref => {
|
|
|
3495
4208
|
label: {}
|
|
3496
4209
|
}
|
|
3497
4210
|
} = _ref,
|
|
3498
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4211
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$i);
|
|
3499
4212
|
return /*#__PURE__*/React.createElement(Label, Object.assign({
|
|
3500
4213
|
top: 6,
|
|
3501
4214
|
zIndex: 1000,
|
|
@@ -3508,12 +4221,12 @@ var FieldLabel = _ref => {
|
|
|
3508
4221
|
}, views['label'], props), children);
|
|
3509
4222
|
};
|
|
3510
4223
|
|
|
3511
|
-
var _excluded$
|
|
4224
|
+
var _excluded$j = ["children"];
|
|
3512
4225
|
var FieldWrapper = _ref => {
|
|
3513
4226
|
var {
|
|
3514
4227
|
children
|
|
3515
4228
|
} = _ref,
|
|
3516
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4229
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$j);
|
|
3517
4230
|
return /*#__PURE__*/React.createElement(Vertical, Object.assign({
|
|
3518
4231
|
width: "100%",
|
|
3519
4232
|
maxWidth: '100%'
|
|
@@ -3530,10 +4243,10 @@ var IconSizes$2 = {
|
|
|
3530
4243
|
xl: 16
|
|
3531
4244
|
};
|
|
3532
4245
|
|
|
3533
|
-
var _excluded$
|
|
3534
|
-
_excluded2$
|
|
3535
|
-
_excluded3$
|
|
3536
|
-
_excluded4$
|
|
4246
|
+
var _excluded$k = ["isHovered", "setIsHovered", "option", "size", "callback", "style"],
|
|
4247
|
+
_excluded2$4 = ["id", "name", "value", "onChange", "isMulti", "isDisabled", "isReadOnly", "options"],
|
|
4248
|
+
_excluded3$3 = ["option", "size", "removeOption"],
|
|
4249
|
+
_excluded4$3 = ["id", "name", "label", "value", "placeholder", "helperText", "hide", "error", "isMulti", "isFocused", "isHovered", "isDisabled", "isReadOnly", "options", "shadow", "size", "shape", "variant", "views", "onChange", "setHide", "setValue", "setIsHovered", "setIsFocused", "setHighlightedIndex", "highlightedIndex"];
|
|
3537
4250
|
// Defines a component to render individual selection items within a list.
|
|
3538
4251
|
var Item = _ref => {
|
|
3539
4252
|
var {
|
|
@@ -3544,7 +4257,7 @@ var Item = _ref => {
|
|
|
3544
4257
|
callback = () => {},
|
|
3545
4258
|
style
|
|
3546
4259
|
} = _ref,
|
|
3547
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4260
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$k);
|
|
3548
4261
|
// Handles the click event on an option by invoking the callback with the selected option's value.
|
|
3549
4262
|
var handleOptionClick = option => callback(option);
|
|
3550
4263
|
// Toggles the hover state on the item.
|
|
@@ -3614,7 +4327,7 @@ var HiddenSelect = _ref4 => {
|
|
|
3614
4327
|
isReadOnly = false,
|
|
3615
4328
|
options = []
|
|
3616
4329
|
} = _ref4,
|
|
3617
|
-
props = _objectWithoutPropertiesLoose(_ref4, _excluded2$
|
|
4330
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded2$4);
|
|
3618
4331
|
var handleChange = event => {
|
|
3619
4332
|
if (onChange) onChange(event);
|
|
3620
4333
|
};
|
|
@@ -3704,7 +4417,7 @@ var MultiSelect = _ref6 => {
|
|
|
3704
4417
|
size = 'md',
|
|
3705
4418
|
removeOption = () => {}
|
|
3706
4419
|
} = _ref6,
|
|
3707
|
-
props = _objectWithoutPropertiesLoose(_ref6, _excluded3$
|
|
4420
|
+
props = _objectWithoutPropertiesLoose(_ref6, _excluded3$3);
|
|
3708
4421
|
var handleClick = () => removeOption(option);
|
|
3709
4422
|
return /*#__PURE__*/React.createElement(Horizontal, Object.assign({
|
|
3710
4423
|
gap: 10,
|
|
@@ -3759,7 +4472,7 @@ var SelectView = _ref7 => {
|
|
|
3759
4472
|
setHighlightedIndex,
|
|
3760
4473
|
highlightedIndex
|
|
3761
4474
|
} = _ref7,
|
|
3762
|
-
props = _objectWithoutPropertiesLoose(_ref7, _excluded4$
|
|
4475
|
+
props = _objectWithoutPropertiesLoose(_ref7, _excluded4$3);
|
|
3763
4476
|
var isWithLabel = !!(isFocused && label);
|
|
3764
4477
|
var handleHover = () => setIsHovered(!isHovered);
|
|
3765
4478
|
var handleFocus = () => setIsFocused(true);
|
|
@@ -4004,7 +4717,7 @@ var SliderPadding = {
|
|
|
4004
4717
|
}
|
|
4005
4718
|
};
|
|
4006
4719
|
|
|
4007
|
-
var _excluded$
|
|
4720
|
+
var _excluded$l = ["id", "name", "label", "inActiveChild", "activeChild", "labelPosition", "shadow", "size", "value", "isHovered", "isDisabled", "isReadOnly", "on", "setOn", "onChange", "setValue", "setIsHovered", "helperText", "views"];
|
|
4008
4721
|
var SwitchContent = props => /*#__PURE__*/React.createElement(Input, Object.assign({
|
|
4009
4722
|
type: "checkbox"
|
|
4010
4723
|
}, props));
|
|
@@ -4033,7 +4746,7 @@ var SwitchView = _ref => {
|
|
|
4033
4746
|
label: {}
|
|
4034
4747
|
}
|
|
4035
4748
|
} = _ref,
|
|
4036
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4749
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$l);
|
|
4037
4750
|
var handleToggle = event => {
|
|
4038
4751
|
if (!isReadOnly) {
|
|
4039
4752
|
setValue(!value);
|
|
@@ -4123,7 +4836,7 @@ var useTextAreaState = _ref => {
|
|
|
4123
4836
|
// Export of the useTextAreaState hook for external usage.
|
|
4124
4837
|
};
|
|
4125
4838
|
|
|
4126
|
-
var _excluded$
|
|
4839
|
+
var _excluded$m = ["id", "name", "hint", "error", "value", "label", "shadow", "helperText", "placeholder", "size", "shape", "variant", "isHovered", "isFocused", "isEditable", "isReadOnly", "isDisabled", "isAutoFocus", "isMultiline", "maxRows", "maxCols", "onBlur", "onChange", "onFocus", "onChangeText", "setHint", "setValue", "setIsFocused", "setIsHovered", "views"];
|
|
4127
4840
|
var TextAreaView = _ref => {
|
|
4128
4841
|
var {
|
|
4129
4842
|
id,
|
|
@@ -4162,7 +4875,7 @@ var TextAreaView = _ref => {
|
|
|
4162
4875
|
field: {}
|
|
4163
4876
|
}
|
|
4164
4877
|
} = _ref,
|
|
4165
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
4878
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$m);
|
|
4166
4879
|
var isWithLabel = !!(isFocused && label);
|
|
4167
4880
|
var fieldStyles = Object.assign({
|
|
4168
4881
|
margin: 0,
|
|
@@ -4291,7 +5004,7 @@ var useTextFieldState = _ref => {
|
|
|
4291
5004
|
};
|
|
4292
5005
|
};
|
|
4293
5006
|
|
|
4294
|
-
var _excluded$
|
|
5007
|
+
var _excluded$n = ["id", "name", "label", "hint", "value", "onChange", "left", "right", "helperText", "placeholder", "onChangeText", "shadow", "views", "size", "shape", "variant", "error", "isFocused", "isHovered", "isDisabled", "isReadOnly", "isClearable", "isAutoFocus", "setHint", "setIsFocused", "setIsHovered", "setValue", "onClick", "onFocus", "onBlur", "themeMode"];
|
|
4295
5008
|
var TextFieldInput = props => /*#__PURE__*/React.createElement(Input, Object.assign({
|
|
4296
5009
|
type: "text"
|
|
4297
5010
|
}, props));
|
|
@@ -4334,7 +5047,7 @@ var TextFieldView = _ref => {
|
|
|
4334
5047
|
onBlur = () => {},
|
|
4335
5048
|
themeMode: elementMode
|
|
4336
5049
|
} = _ref,
|
|
4337
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
5050
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$n);
|
|
4338
5051
|
var {
|
|
4339
5052
|
getColor,
|
|
4340
5053
|
themeMode
|
|
@@ -4515,7 +5228,7 @@ var IconSizes$3 = {
|
|
|
4515
5228
|
'6xl': 60
|
|
4516
5229
|
};
|
|
4517
5230
|
|
|
4518
|
-
var _excluded$
|
|
5231
|
+
var _excluded$o = ["id", "icon", "name", "label", "isChecked", "onChange", "onValueChange", "shadow", "labelPosition", "size", "error", "isSelected", "isHovered", "isDisabled", "isReadOnly", "isIndeterminate", "defaultIsSelected", "setIsSelected", "setIsHovered", "views", "infoText", "helperText"];
|
|
4519
5232
|
var CheckboxView = _ref => {
|
|
4520
5233
|
var {
|
|
4521
5234
|
id,
|
|
@@ -4542,7 +5255,7 @@ var CheckboxView = _ref => {
|
|
|
4542
5255
|
},
|
|
4543
5256
|
infoText
|
|
4544
5257
|
} = _ref,
|
|
4545
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
5258
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$o);
|
|
4546
5259
|
var handleHover = () => setIsHovered(!isHovered);
|
|
4547
5260
|
var handleChange = () => {
|
|
4548
5261
|
if (!isReadOnly && !isDisabled) {
|
|
@@ -6106,11 +6819,11 @@ var IconSizes$4 = {
|
|
|
6106
6819
|
xl: 16
|
|
6107
6820
|
};
|
|
6108
6821
|
|
|
6109
|
-
var _excluded$
|
|
6110
|
-
_excluded2$
|
|
6111
|
-
_excluded3$
|
|
6822
|
+
var _excluded$p = ["size"],
|
|
6823
|
+
_excluded2$5 = ["size"],
|
|
6824
|
+
_excluded3$4 = ["id", "name", "label", "value", "placeholder", "helperText", "hide", "error", "isHovered", "isFocused", "isAutoFocus", "isDisabled", "isReadOnly", "shadow", "newOptions", "size", "variant", "shape", "onChange", "onBlur", "setHide", "setNewOptions", "setIsHovered", "setIsFocused", "setValue", "views", "themeMode"];
|
|
6112
6825
|
var CountryList = _ref => {
|
|
6113
|
-
var props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6826
|
+
var props = _objectWithoutPropertiesLoose(_ref, _excluded$p);
|
|
6114
6827
|
return /*#__PURE__*/React.createElement(Element, Object.assign({
|
|
6115
6828
|
as: "ul"
|
|
6116
6829
|
}, props));
|
|
@@ -6119,7 +6832,7 @@ var CountrySelector = props => (/*#__PURE__*/React.createElement(Input, Object.a
|
|
|
6119
6832
|
type: "country"
|
|
6120
6833
|
}, props)));
|
|
6121
6834
|
var CountryItem = _ref2 => {
|
|
6122
|
-
var props = _objectWithoutPropertiesLoose(_ref2, _excluded2$
|
|
6835
|
+
var props = _objectWithoutPropertiesLoose(_ref2, _excluded2$5);
|
|
6123
6836
|
return /*#__PURE__*/React.createElement(Element, Object.assign({
|
|
6124
6837
|
as: "li"
|
|
6125
6838
|
}, props));
|
|
@@ -6222,7 +6935,7 @@ var CountryPickerView = _ref5 => {
|
|
|
6222
6935
|
},
|
|
6223
6936
|
themeMode: elementMode
|
|
6224
6937
|
} = _ref5,
|
|
6225
|
-
props = _objectWithoutPropertiesLoose(_ref5, _excluded3$
|
|
6938
|
+
props = _objectWithoutPropertiesLoose(_ref5, _excluded3$4);
|
|
6226
6939
|
var {
|
|
6227
6940
|
getColor,
|
|
6228
6941
|
themeMode
|
|
@@ -6349,7 +7062,7 @@ var useDatePickerState = () => {
|
|
|
6349
7062
|
};
|
|
6350
7063
|
};
|
|
6351
7064
|
|
|
6352
|
-
var _excluded$
|
|
7065
|
+
var _excluded$q = ["id", "icon", "name", "label", "date", "children", "helperText", "shadow", "size", "variant", "shape", "views", "error", "isHovered", "isFocused", "isDisabled", "isReadOnly", "setDate", "setIsFocused", "setIsHovered", "onChange", "onChangeText"];
|
|
6353
7066
|
var DatePickerContent = props => /*#__PURE__*/React.createElement(Input, Object.assign({
|
|
6354
7067
|
type: "date"
|
|
6355
7068
|
}, props));
|
|
@@ -6382,7 +7095,7 @@ var DatePickerView = _ref => {
|
|
|
6382
7095
|
onChange,
|
|
6383
7096
|
onChangeText
|
|
6384
7097
|
} = _ref,
|
|
6385
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7098
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$q);
|
|
6386
7099
|
var isWithLabel = !!(isFocused && label);
|
|
6387
7100
|
var handleHover = () => setIsHovered(!isHovered);
|
|
6388
7101
|
var handleFocus = () => setIsFocused(true);
|
|
@@ -6469,8 +7182,8 @@ var usePasswordState = props => {
|
|
|
6469
7182
|
}, props, textFieldStates);
|
|
6470
7183
|
};
|
|
6471
7184
|
|
|
6472
|
-
var _excluded$
|
|
6473
|
-
_excluded2$
|
|
7185
|
+
var _excluded$r = ["visibleIcon", "hiddenIcon"],
|
|
7186
|
+
_excluded2$6 = ["isVisible", "setIsVisible"];
|
|
6474
7187
|
var PasswordComponent = _ref => {
|
|
6475
7188
|
var {
|
|
6476
7189
|
visibleIcon = /*#__PURE__*/React.createElement(OpenEyeIcon, {
|
|
@@ -6480,13 +7193,13 @@ var PasswordComponent = _ref => {
|
|
|
6480
7193
|
widthHeight: 14
|
|
6481
7194
|
})
|
|
6482
7195
|
} = _ref,
|
|
6483
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7196
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$r);
|
|
6484
7197
|
var _usePasswordState = usePasswordState(props),
|
|
6485
7198
|
{
|
|
6486
7199
|
isVisible,
|
|
6487
7200
|
setIsVisible
|
|
6488
7201
|
} = _usePasswordState,
|
|
6489
|
-
passwordProps = _objectWithoutPropertiesLoose(_usePasswordState, _excluded2$
|
|
7202
|
+
passwordProps = _objectWithoutPropertiesLoose(_usePasswordState, _excluded2$6);
|
|
6490
7203
|
return /*#__PURE__*/React.createElement(TextFieldView, Object.assign({}, passwordProps, {
|
|
6491
7204
|
type: isVisible ? 'text' : 'password',
|
|
6492
7205
|
isClearable: false,
|
|
@@ -6534,7 +7247,7 @@ var useComboBoxState = (items, placeholder, searchPlaceholder) => {
|
|
|
6534
7247
|
};
|
|
6535
7248
|
};
|
|
6536
7249
|
|
|
6537
|
-
var _excluded$
|
|
7250
|
+
var _excluded$s = ["placeholder", "items", "showTick", "onSelect", "searchEnabled", "left", "right", "label", "filteredItems", "setSelectedItem", "selectedItem", "highlightedIndex", "setHighlightedIndex", "searchQuery", "setSearchQuery", "setFilteredItems", "views", "isDropdownVisible", "setIsDropdownVisible"];
|
|
6538
7251
|
// Defines the functional component 'ComboBoxView' with destructured props.
|
|
6539
7252
|
var ComboBoxView = _ref => {
|
|
6540
7253
|
var {
|
|
@@ -6559,7 +7272,7 @@ var ComboBoxView = _ref => {
|
|
|
6559
7272
|
setIsDropdownVisible
|
|
6560
7273
|
// Collects all further props not destructured explicitly.
|
|
6561
7274
|
} = _ref,
|
|
6562
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7275
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$s);
|
|
6563
7276
|
// Sets up an effect to handle clicking outside the dropdown to close it.
|
|
6564
7277
|
useEffect(() => {
|
|
6565
7278
|
var handleClickOutside = event => {
|
|
@@ -6670,7 +7383,7 @@ var ComboBoxView = _ref => {
|
|
|
6670
7383
|
}))))))))))));
|
|
6671
7384
|
};
|
|
6672
7385
|
|
|
6673
|
-
var _excluded$
|
|
7386
|
+
var _excluded$t = ["id", "name", "items", "placeholder", "searchPlaceholder"];
|
|
6674
7387
|
// Defines the ComboBoxComponent functional component with ComboBoxProps
|
|
6675
7388
|
var ComboBoxComponent = _ref => {
|
|
6676
7389
|
var {
|
|
@@ -6686,7 +7399,7 @@ var ComboBoxComponent = _ref => {
|
|
|
6686
7399
|
searchPlaceholder
|
|
6687
7400
|
// Destructures the rest of the props not explicitly defined
|
|
6688
7401
|
} = _ref,
|
|
6689
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7402
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$t);
|
|
6690
7403
|
// Initializes ComboBox state using custom hook with items and placeholders
|
|
6691
7404
|
var state = useComboBoxState(items, placeholder, searchPlaceholder);
|
|
6692
7405
|
return (
|
|
@@ -6702,7 +7415,7 @@ var ComboBoxComponent = _ref => {
|
|
|
6702
7415
|
// Exports the ComboBoxComponent as ComboBox
|
|
6703
7416
|
var ComboBox = ComboBoxComponent;
|
|
6704
7417
|
|
|
6705
|
-
var _excluded$
|
|
7418
|
+
var _excluded$u = ["children", "autoFocus", "initFocus", "onChange"];
|
|
6706
7419
|
var FocusContext = /*#__PURE__*/createContext({
|
|
6707
7420
|
active: false,
|
|
6708
7421
|
focusNextInput: () => {},
|
|
@@ -6718,7 +7431,7 @@ var FormikForm = _ref => {
|
|
|
6718
7431
|
initFocus,
|
|
6719
7432
|
onChange = () => {}
|
|
6720
7433
|
} = _ref,
|
|
6721
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7434
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$u);
|
|
6722
7435
|
var formik = useFormikContext();
|
|
6723
7436
|
useEffect(() => {
|
|
6724
7437
|
onChange(formik.values);
|
|
@@ -6766,7 +7479,7 @@ var FormikForm = _ref => {
|
|
|
6766
7479
|
}, /*#__PURE__*/React.createElement(Form, Object.assign({}, props), children));
|
|
6767
7480
|
};
|
|
6768
7481
|
|
|
6769
|
-
var _excluded$
|
|
7482
|
+
var _excluded$v = ["name", "type"];
|
|
6770
7483
|
var getInputTypeProps = type => {
|
|
6771
7484
|
switch (type) {
|
|
6772
7485
|
case 'email':
|
|
@@ -6805,7 +7518,7 @@ var useFormikInput = _ref => {
|
|
|
6805
7518
|
name,
|
|
6806
7519
|
type
|
|
6807
7520
|
} = _ref,
|
|
6808
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7521
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$v);
|
|
6809
7522
|
var focus = useFormFocus();
|
|
6810
7523
|
var {
|
|
6811
7524
|
touched,
|
|
@@ -6849,13 +7562,13 @@ var useFormikInput = _ref => {
|
|
|
6849
7562
|
} : {});
|
|
6850
7563
|
};
|
|
6851
7564
|
|
|
6852
|
-
var _excluded$
|
|
7565
|
+
var _excluded$w = ["value"];
|
|
6853
7566
|
var CheckboxComponent$1 = props => {
|
|
6854
7567
|
var _useFormikInput = useFormikInput(props),
|
|
6855
7568
|
{
|
|
6856
7569
|
value
|
|
6857
7570
|
} = _useFormikInput,
|
|
6858
|
-
formProps = _objectWithoutPropertiesLoose(_useFormikInput, _excluded$
|
|
7571
|
+
formProps = _objectWithoutPropertiesLoose(_useFormikInput, _excluded$w);
|
|
6859
7572
|
formProps.isChecked = value;
|
|
6860
7573
|
var checkboxStates = useCheckboxState(props);
|
|
6861
7574
|
return /*#__PURE__*/React.createElement(CheckboxView, Object.assign({}, checkboxStates, formProps));
|
|
@@ -6913,11 +7626,11 @@ var TextAreaComponent$1 = props => {
|
|
|
6913
7626
|
*/
|
|
6914
7627
|
var FormikTextArea = TextAreaComponent$1;
|
|
6915
7628
|
|
|
6916
|
-
var _excluded$
|
|
7629
|
+
var _excluded$x = ["value"];
|
|
6917
7630
|
var TextFieldComponent$1 = props => {
|
|
6918
7631
|
var formProps = useFormikInput(props);
|
|
6919
7632
|
var _useTextFieldState = useTextFieldState(props),
|
|
6920
|
-
textFieldStates = _objectWithoutPropertiesLoose(_useTextFieldState, _excluded$
|
|
7633
|
+
textFieldStates = _objectWithoutPropertiesLoose(_useTextFieldState, _excluded$x);
|
|
6921
7634
|
return /*#__PURE__*/React.createElement(TextFieldView, Object.assign({}, textFieldStates, formProps));
|
|
6922
7635
|
};
|
|
6923
7636
|
/**
|
|
@@ -6925,8 +7638,8 @@ var TextFieldComponent$1 = props => {
|
|
|
6925
7638
|
*/
|
|
6926
7639
|
var FormikTextField = TextFieldComponent$1;
|
|
6927
7640
|
|
|
6928
|
-
var _excluded$
|
|
6929
|
-
_excluded2$
|
|
7641
|
+
var _excluded$y = ["visibleIcon", "hiddenIcon"],
|
|
7642
|
+
_excluded2$7 = ["isVisible", "setIsVisible"];
|
|
6930
7643
|
var PasswordComponent$1 = _ref => {
|
|
6931
7644
|
var {
|
|
6932
7645
|
visibleIcon = /*#__PURE__*/React.createElement(OpenEyeIcon, {
|
|
@@ -6936,14 +7649,14 @@ var PasswordComponent$1 = _ref => {
|
|
|
6936
7649
|
widthHeight: 14
|
|
6937
7650
|
})
|
|
6938
7651
|
} = _ref,
|
|
6939
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7652
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$y);
|
|
6940
7653
|
var formProps = useFormikInput(props);
|
|
6941
7654
|
var _usePasswordState = usePasswordState(formProps),
|
|
6942
7655
|
{
|
|
6943
7656
|
isVisible,
|
|
6944
7657
|
setIsVisible
|
|
6945
7658
|
} = _usePasswordState,
|
|
6946
|
-
passwordProps = _objectWithoutPropertiesLoose(_usePasswordState, _excluded2$
|
|
7659
|
+
passwordProps = _objectWithoutPropertiesLoose(_usePasswordState, _excluded2$7);
|
|
6947
7660
|
return /*#__PURE__*/React.createElement(TextFieldView, Object.assign({}, passwordProps, {
|
|
6948
7661
|
type: isVisible ? 'text' : 'password',
|
|
6949
7662
|
isClearable: false,
|
|
@@ -6961,14 +7674,14 @@ var PasswordComponent$1 = _ref => {
|
|
|
6961
7674
|
*/
|
|
6962
7675
|
var FormikPassword = PasswordComponent$1;
|
|
6963
7676
|
|
|
6964
|
-
var _excluded$
|
|
7677
|
+
var _excluded$z = ["items", "placeholder", "searchPlaceholder"];
|
|
6965
7678
|
var ComboBoxComponent$1 = _ref => {
|
|
6966
7679
|
var {
|
|
6967
7680
|
items,
|
|
6968
7681
|
placeholder,
|
|
6969
7682
|
searchPlaceholder
|
|
6970
7683
|
} = _ref,
|
|
6971
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7684
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$z);
|
|
6972
7685
|
var formProps = useFormikInput(props);
|
|
6973
7686
|
var ComboBoxStates = useComboBoxState(items, placeholder, searchPlaceholder);
|
|
6974
7687
|
// Ensure the onChange function from formProps is being called when an item is selected
|
|
@@ -6984,28 +7697,584 @@ var ComboBoxComponent$1 = _ref => {
|
|
|
6984
7697
|
*/
|
|
6985
7698
|
var FormikComboBox = ComboBoxComponent$1;
|
|
6986
7699
|
|
|
6987
|
-
//
|
|
6988
|
-
var
|
|
6989
|
-
|
|
6990
|
-
|
|
6991
|
-
|
|
6992
|
-
|
|
6993
|
-
|
|
6994
|
-
|
|
6995
|
-
|
|
6996
|
-
|
|
6997
|
-
|
|
6998
|
-
|
|
6999
|
-
|
|
7000
|
-
|
|
7001
|
-
|
|
7002
|
-
|
|
7003
|
-
|
|
7004
|
-
|
|
7005
|
-
|
|
7700
|
+
// Clamp value between min and max
|
|
7701
|
+
var clamp = (value, min, max) => Math.min(Math.max(value, min), max);
|
|
7702
|
+
// Calculate value based on position, track dimensions, min, max, step
|
|
7703
|
+
var calculateValue = (position, trackRect, min, max, step, orientation, stepValues) => {
|
|
7704
|
+
var range = max - min;
|
|
7705
|
+
var percentage;
|
|
7706
|
+
if (orientation === 'horizontal') {
|
|
7707
|
+
var trackLength = trackRect.width;
|
|
7708
|
+
var relativePosition = position - trackRect.left;
|
|
7709
|
+
percentage = clamp(relativePosition / trackLength, 0, 1);
|
|
7710
|
+
} else {
|
|
7711
|
+
// Vertical: top is max, bottom is min (reversed from the provided code)
|
|
7712
|
+
var _trackLength = trackRect.height;
|
|
7713
|
+
var _relativePosition = trackRect.bottom - position; // Y position relative to track bottom
|
|
7714
|
+
percentage = clamp(_relativePosition / _trackLength, 0, 1);
|
|
7715
|
+
}
|
|
7716
|
+
// If stepValues are provided, find the closest value in the array
|
|
7717
|
+
if (stepValues && stepValues.length > 0) {
|
|
7718
|
+
var rawValue = min + percentage * range;
|
|
7719
|
+
// Find the closest value in stepValues
|
|
7720
|
+
var closestValue = stepValues[0];
|
|
7721
|
+
var minDistance = Math.abs(rawValue - closestValue);
|
|
7722
|
+
for (var i = 1; i < stepValues.length; i++) {
|
|
7723
|
+
var distance = Math.abs(rawValue - stepValues[i]);
|
|
7724
|
+
if (distance < minDistance) {
|
|
7725
|
+
minDistance = distance;
|
|
7726
|
+
closestValue = stepValues[i];
|
|
7727
|
+
}
|
|
7006
7728
|
}
|
|
7007
|
-
return
|
|
7008
|
-
|
|
7729
|
+
return closestValue;
|
|
7730
|
+
} else {
|
|
7731
|
+
// Use regular step logic
|
|
7732
|
+
var _rawValue = min + percentage * range;
|
|
7733
|
+
var steppedValue = Math.round(_rawValue / step) * step;
|
|
7734
|
+
// Final clamp to ensure step rounding doesn't exceed bounds
|
|
7735
|
+
return clamp(steppedValue, min, max);
|
|
7736
|
+
}
|
|
7737
|
+
};
|
|
7738
|
+
var useSliderState = _ref => {
|
|
7739
|
+
var _ref2;
|
|
7740
|
+
var {
|
|
7741
|
+
min = 0,
|
|
7742
|
+
max = 100,
|
|
7743
|
+
step = 1,
|
|
7744
|
+
value: controlledValue = 0,
|
|
7745
|
+
defaultValue,
|
|
7746
|
+
onChange,
|
|
7747
|
+
onDrag,
|
|
7748
|
+
orientation = 'horizontal',
|
|
7749
|
+
isDisabled = false,
|
|
7750
|
+
stepValues
|
|
7751
|
+
} = _ref;
|
|
7752
|
+
var initialValue = clamp((_ref2 = controlledValue != null ? controlledValue : defaultValue) != null ? _ref2 : min, min, max);
|
|
7753
|
+
var [internalValue, setInternalValue] = useState(initialValue);
|
|
7754
|
+
var [isDragging, setIsDragging] = useState(false);
|
|
7755
|
+
var [isHovered, setIsHovered] = useState(false);
|
|
7756
|
+
var trackRef = useRef(null);
|
|
7757
|
+
var thumbRef = useRef(null);
|
|
7758
|
+
var isControlled = controlledValue !== undefined;
|
|
7759
|
+
var currentValue = isControlled ? controlledValue : internalValue;
|
|
7760
|
+
// Update internal state if controlled value changes
|
|
7761
|
+
useEffect(() => {
|
|
7762
|
+
if (isControlled) {
|
|
7763
|
+
setInternalValue(clamp(controlledValue, min, max));
|
|
7764
|
+
}
|
|
7765
|
+
}, [controlledValue, isControlled, min, max]);
|
|
7766
|
+
var updateValue = useCallback(newValue => {
|
|
7767
|
+
var clampedValue = clamp(newValue, min, max);
|
|
7768
|
+
if (!isControlled) {
|
|
7769
|
+
setInternalValue(clampedValue);
|
|
7770
|
+
}
|
|
7771
|
+
if (onChange && clampedValue !== currentValue) {
|
|
7772
|
+
onChange(clampedValue);
|
|
7773
|
+
}
|
|
7774
|
+
if (isDragging && onDrag) {
|
|
7775
|
+
onDrag(clampedValue);
|
|
7776
|
+
}
|
|
7777
|
+
}, [isControlled, min, max, onChange, currentValue, isDragging, onDrag]);
|
|
7778
|
+
var handleInteraction = useCallback(event => {
|
|
7779
|
+
if (isDisabled || !trackRef.current) return;
|
|
7780
|
+
var trackRect = trackRef.current.getBoundingClientRect();
|
|
7781
|
+
var position;
|
|
7782
|
+
if ('touches' in event) {
|
|
7783
|
+
position = orientation === 'horizontal' ? event.touches[0].clientX : event.touches[0].clientY;
|
|
7784
|
+
} else {
|
|
7785
|
+
position = orientation === 'horizontal' ? event.clientX : event.clientY;
|
|
7786
|
+
}
|
|
7787
|
+
var newValue = calculateValue(position, trackRect, min, max, step, orientation, stepValues);
|
|
7788
|
+
updateValue(newValue);
|
|
7789
|
+
}, [min, max, step, orientation, updateValue, isDisabled, stepValues]);
|
|
7790
|
+
var handleMouseDown = useCallback(event => {
|
|
7791
|
+
if (isDisabled) return;
|
|
7792
|
+
event.preventDefault(); // Prevent text selection during drag
|
|
7793
|
+
setIsDragging(true);
|
|
7794
|
+
handleInteraction(event); // Update value immediately on click/touch
|
|
7795
|
+
var handleMouseMove = moveEvent => {
|
|
7796
|
+
handleInteraction(moveEvent);
|
|
7797
|
+
};
|
|
7798
|
+
var handleMouseUp = () => {
|
|
7799
|
+
setIsDragging(false);
|
|
7800
|
+
document.removeEventListener('mousemove', handleMouseMove);
|
|
7801
|
+
document.removeEventListener('mouseup', handleMouseUp);
|
|
7802
|
+
document.removeEventListener('touchmove', handleMouseMove);
|
|
7803
|
+
document.removeEventListener('touchend', handleMouseUp);
|
|
7804
|
+
};
|
|
7805
|
+
document.addEventListener('mousemove', handleMouseMove);
|
|
7806
|
+
document.addEventListener('mouseup', handleMouseUp);
|
|
7807
|
+
document.addEventListener('touchmove', handleMouseMove);
|
|
7808
|
+
document.addEventListener('touchend', handleMouseUp);
|
|
7809
|
+
}, [handleInteraction, isDisabled]);
|
|
7810
|
+
// Allow clicking directly on the track
|
|
7811
|
+
var handleTrackMouseDown = useCallback(event => {
|
|
7812
|
+
// Prevent triggering if click is on the thumb itself
|
|
7813
|
+
if (thumbRef.current && thumbRef.current.contains(event.target)) {
|
|
7814
|
+
return;
|
|
7815
|
+
}
|
|
7816
|
+
handleMouseDown(event);
|
|
7817
|
+
}, [handleMouseDown]);
|
|
7818
|
+
var handleKeyDown = useCallback(event => {
|
|
7819
|
+
if (isDisabled) return;
|
|
7820
|
+
var newValue = currentValue;
|
|
7821
|
+
switch (event.key) {
|
|
7822
|
+
case 'ArrowLeft':
|
|
7823
|
+
case 'ArrowDown':
|
|
7824
|
+
newValue = currentValue - step;
|
|
7825
|
+
break;
|
|
7826
|
+
case 'ArrowRight':
|
|
7827
|
+
case 'ArrowUp':
|
|
7828
|
+
newValue = currentValue + step;
|
|
7829
|
+
break;
|
|
7830
|
+
case 'Home':
|
|
7831
|
+
newValue = min;
|
|
7832
|
+
break;
|
|
7833
|
+
case 'End':
|
|
7834
|
+
newValue = max;
|
|
7835
|
+
break;
|
|
7836
|
+
default:
|
|
7837
|
+
return;
|
|
7838
|
+
// Exit if key is not handled
|
|
7839
|
+
}
|
|
7840
|
+
event.preventDefault(); // Prevent page scroll
|
|
7841
|
+
updateValue(newValue);
|
|
7842
|
+
}, [currentValue, min, max, step, updateValue, isDisabled]);
|
|
7843
|
+
var range = max - min;
|
|
7844
|
+
var thumbPositionPercent = range === 0 ? 0 : (currentValue - min) / range * 100;
|
|
7845
|
+
return {
|
|
7846
|
+
currentValue,
|
|
7847
|
+
isDragging,
|
|
7848
|
+
isHovered,
|
|
7849
|
+
setIsHovered,
|
|
7850
|
+
trackRef,
|
|
7851
|
+
thumbRef,
|
|
7852
|
+
handleThumbMouseDown: handleMouseDown,
|
|
7853
|
+
handleTrackMouseDown,
|
|
7854
|
+
handleKeyDown,
|
|
7855
|
+
thumbPositionPercent
|
|
7856
|
+
};
|
|
7857
|
+
};
|
|
7858
|
+
|
|
7859
|
+
var SliderSizes$1 = {
|
|
7860
|
+
xs: {
|
|
7861
|
+
height: 4,
|
|
7862
|
+
width: '100%'
|
|
7863
|
+
},
|
|
7864
|
+
sm: {
|
|
7865
|
+
height: 6,
|
|
7866
|
+
width: '100%'
|
|
7867
|
+
},
|
|
7868
|
+
md: {
|
|
7869
|
+
height: 8,
|
|
7870
|
+
width: '100%'
|
|
7871
|
+
},
|
|
7872
|
+
lg: {
|
|
7873
|
+
height: 10,
|
|
7874
|
+
width: '100%'
|
|
7875
|
+
},
|
|
7876
|
+
xl: {
|
|
7877
|
+
height: 12,
|
|
7878
|
+
width: '100%'
|
|
7879
|
+
}
|
|
7880
|
+
};
|
|
7881
|
+
var ThumbSizes = {
|
|
7882
|
+
xs: {
|
|
7883
|
+
width: 12,
|
|
7884
|
+
height: 12
|
|
7885
|
+
},
|
|
7886
|
+
sm: {
|
|
7887
|
+
width: 16,
|
|
7888
|
+
height: 16
|
|
7889
|
+
},
|
|
7890
|
+
md: {
|
|
7891
|
+
width: 20,
|
|
7892
|
+
height: 20
|
|
7893
|
+
},
|
|
7894
|
+
lg: {
|
|
7895
|
+
width: 24,
|
|
7896
|
+
height: 24
|
|
7897
|
+
},
|
|
7898
|
+
xl: {
|
|
7899
|
+
width: 28,
|
|
7900
|
+
height: 28
|
|
7901
|
+
}
|
|
7902
|
+
};
|
|
7903
|
+
var SliderShapes = {
|
|
7904
|
+
sharp: 0,
|
|
7905
|
+
rounded: 4,
|
|
7906
|
+
pillShaped: 24
|
|
7907
|
+
};
|
|
7908
|
+
var SliderVariants = {
|
|
7909
|
+
default: {
|
|
7910
|
+
backgroundColor: 'color.blueGray.200'
|
|
7911
|
+
},
|
|
7912
|
+
outline: {
|
|
7913
|
+
backgroundColor: 'transparent',
|
|
7914
|
+
borderWidth: 1,
|
|
7915
|
+
borderStyle: 'solid',
|
|
7916
|
+
borderColor: 'color.blueGray.300'
|
|
7917
|
+
}
|
|
7918
|
+
};
|
|
7919
|
+
// Maps Size enum to track height/width and thumb size for the new implementation
|
|
7920
|
+
var EnhancedSliderSizes = {
|
|
7921
|
+
xs: {
|
|
7922
|
+
trackCrossAxisSize: 4,
|
|
7923
|
+
thumbSize: 12
|
|
7924
|
+
},
|
|
7925
|
+
sm: {
|
|
7926
|
+
trackCrossAxisSize: 6,
|
|
7927
|
+
thumbSize: 16
|
|
7928
|
+
},
|
|
7929
|
+
md: {
|
|
7930
|
+
trackCrossAxisSize: 8,
|
|
7931
|
+
thumbSize: 20
|
|
7932
|
+
},
|
|
7933
|
+
lg: {
|
|
7934
|
+
trackCrossAxisSize: 10,
|
|
7935
|
+
thumbSize: 24
|
|
7936
|
+
},
|
|
7937
|
+
xl: {
|
|
7938
|
+
trackCrossAxisSize: 12,
|
|
7939
|
+
thumbSize: 28
|
|
7940
|
+
}
|
|
7941
|
+
};
|
|
7942
|
+
// Basic styles for horizontal and vertical orientation
|
|
7943
|
+
var OrientationStyles = {
|
|
7944
|
+
horizontal: {
|
|
7945
|
+
width: '100%',
|
|
7946
|
+
minWidth: '120px',
|
|
7947
|
+
height: 'auto',
|
|
7948
|
+
flexDirection: 'row',
|
|
7949
|
+
paddingVertical: 8
|
|
7950
|
+
},
|
|
7951
|
+
vertical: {
|
|
7952
|
+
height: '100%',
|
|
7953
|
+
minHeight: '120px',
|
|
7954
|
+
width: 'auto',
|
|
7955
|
+
flexDirection: 'column-reverse',
|
|
7956
|
+
paddingHorizontal: 8
|
|
7957
|
+
}
|
|
7958
|
+
};
|
|
7959
|
+
|
|
7960
|
+
var _excluded$A = ["min", "max", "step", "currentValue", "stepValues", "shape", "size", "variant", "orientation", "isDisabled", "showValue", "showTooltip", "colorScheme", "label", "helperText", "themeMode", "shadow", "isDragging", "isHovered", "setIsHovered", "trackRef", "thumbRef", "handleThumbMouseDown", "handleTrackMouseDown", "handleKeyDown", "thumbPositionPercent", "ariaLabel", "views"];
|
|
7961
|
+
var SliderView = _ref => {
|
|
7962
|
+
var _views$tooltip, _views$tooltip2;
|
|
7963
|
+
var {
|
|
7964
|
+
min = 0,
|
|
7965
|
+
max = 100,
|
|
7966
|
+
step = 1,
|
|
7967
|
+
currentValue,
|
|
7968
|
+
stepValues,
|
|
7969
|
+
shape = 'rounded',
|
|
7970
|
+
size = 'md',
|
|
7971
|
+
variant = 'default',
|
|
7972
|
+
orientation = 'horizontal',
|
|
7973
|
+
isDisabled = false,
|
|
7974
|
+
showValue = false,
|
|
7975
|
+
showTooltip = false,
|
|
7976
|
+
colorScheme = 'theme.primary',
|
|
7977
|
+
label,
|
|
7978
|
+
helperText,
|
|
7979
|
+
themeMode: elementMode,
|
|
7980
|
+
shadow = {},
|
|
7981
|
+
isDragging,
|
|
7982
|
+
isHovered,
|
|
7983
|
+
setIsHovered,
|
|
7984
|
+
trackRef,
|
|
7985
|
+
thumbRef,
|
|
7986
|
+
handleThumbMouseDown,
|
|
7987
|
+
handleTrackMouseDown,
|
|
7988
|
+
handleKeyDown,
|
|
7989
|
+
thumbPositionPercent,
|
|
7990
|
+
ariaLabel = 'Slider',
|
|
7991
|
+
views = {
|
|
7992
|
+
container: {},
|
|
7993
|
+
track: {},
|
|
7994
|
+
progress: {},
|
|
7995
|
+
filledTrack: {},
|
|
7996
|
+
thumb: {},
|
|
7997
|
+
label: {},
|
|
7998
|
+
valueLabel: {},
|
|
7999
|
+
stepMarks: {},
|
|
8000
|
+
tooltip: {}
|
|
8001
|
+
}
|
|
8002
|
+
} = _ref,
|
|
8003
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$A);
|
|
8004
|
+
var {
|
|
8005
|
+
getColor,
|
|
8006
|
+
themeMode
|
|
8007
|
+
} = useTheme();
|
|
8008
|
+
var themeColor = getColor(colorScheme, elementMode || themeMode);
|
|
8009
|
+
var disabledColor = getColor('theme.disabled', elementMode || themeMode);
|
|
8010
|
+
var trackColor = getColor(SliderVariants[variant].backgroundColor, elementMode || themeMode);
|
|
8011
|
+
var isVertical = orientation === 'vertical';
|
|
8012
|
+
var {
|
|
8013
|
+
trackCrossAxisSize,
|
|
8014
|
+
thumbSize
|
|
8015
|
+
} = EnhancedSliderSizes[size] || {
|
|
8016
|
+
trackCrossAxisSize: SliderSizes$1[size].height,
|
|
8017
|
+
thumbSize: ThumbSizes[size].width || 16
|
|
8018
|
+
};
|
|
8019
|
+
// For backward compatibility with the old implementation
|
|
8020
|
+
var legacyView = /*#__PURE__*/React.createElement(Vertical, Object.assign({
|
|
8021
|
+
width: "100%",
|
|
8022
|
+
gap: 8
|
|
8023
|
+
}, views.container, props), label && (/*#__PURE__*/React.createElement(Horizontal, {
|
|
8024
|
+
justifyContent: "space-between",
|
|
8025
|
+
alignItems: "center"
|
|
8026
|
+
}, /*#__PURE__*/React.createElement(Text$1, Object.assign({
|
|
8027
|
+
fontSize: 14,
|
|
8028
|
+
fontWeight: 500
|
|
8029
|
+
}, views.label), label), showValue && (/*#__PURE__*/React.createElement(Text$1, Object.assign({
|
|
8030
|
+
fontSize: 14,
|
|
8031
|
+
color: "color.blueGray.500"
|
|
8032
|
+
}, views.valueLabel), currentValue)))), /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8033
|
+
ref: trackRef,
|
|
8034
|
+
position: "relative",
|
|
8035
|
+
cursor: isDisabled ? 'not-allowed' : 'pointer',
|
|
8036
|
+
opacity: isDisabled ? 0.6 : 1,
|
|
8037
|
+
onMouseDown: handleTrackMouseDown,
|
|
8038
|
+
onMouseEnter: () => setIsHovered(true),
|
|
8039
|
+
onMouseLeave: () => setIsHovered(false)
|
|
8040
|
+
}, SliderSizes$1[size], {
|
|
8041
|
+
borderRadius: SliderShapes[shape],
|
|
8042
|
+
backgroundColor: trackColor
|
|
8043
|
+
}, SliderVariants[variant], shadow, views.track), stepValues && stepValues.length > 0 && (/*#__PURE__*/React.createElement(React.Fragment, null, stepValues.map(stepValue => {
|
|
8044
|
+
var stepPercentage = (stepValue - min) / (max - min) * 100;
|
|
8045
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8046
|
+
key: stepValue,
|
|
8047
|
+
position: "absolute",
|
|
8048
|
+
top: "50%",
|
|
8049
|
+
left: stepPercentage + "%",
|
|
8050
|
+
transform: "translate(-50%, -50%)",
|
|
8051
|
+
width: 4,
|
|
8052
|
+
height: 4,
|
|
8053
|
+
borderRadius: "50%",
|
|
8054
|
+
backgroundColor: isDisabled ? disabledColor : themeColor,
|
|
8055
|
+
zIndex: 1
|
|
8056
|
+
}, views.stepMarks));
|
|
8057
|
+
}))), /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8058
|
+
position: "absolute",
|
|
8059
|
+
top: 0,
|
|
8060
|
+
left: 0,
|
|
8061
|
+
height: "100%",
|
|
8062
|
+
width: thumbPositionPercent + "%",
|
|
8063
|
+
backgroundColor: isDisabled ? disabledColor : themeColor,
|
|
8064
|
+
borderRadius: SliderShapes[shape],
|
|
8065
|
+
transition: "width 0.1s ease-in-out"
|
|
8066
|
+
}, views.progress, views.filledTrack)), /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8067
|
+
ref: thumbRef,
|
|
8068
|
+
role: "slider",
|
|
8069
|
+
tabIndex: isDisabled ? -1 : 0,
|
|
8070
|
+
"aria-valuemin": min,
|
|
8071
|
+
"aria-valuemax": max,
|
|
8072
|
+
"aria-valuenow": currentValue,
|
|
8073
|
+
"aria-orientation": orientation,
|
|
8074
|
+
"aria-disabled": isDisabled,
|
|
8075
|
+
"aria-label": ariaLabel,
|
|
8076
|
+
position: "absolute",
|
|
8077
|
+
top: "50%",
|
|
8078
|
+
left: thumbPositionPercent + "%",
|
|
8079
|
+
borderRadius: "50%",
|
|
8080
|
+
backgroundColor: "white",
|
|
8081
|
+
boxShadow: "0 2px 4px rgba(0, 0, 0, 0.2)",
|
|
8082
|
+
border: "2px solid " + (isDisabled ? disabledColor : themeColor),
|
|
8083
|
+
transition: isDragging ? 'none' : 'transform 0.1s ease-in-out',
|
|
8084
|
+
transform: isHovered ? 'translate(-50%, -50%) scale(1.1)' : 'translate(-50%, -50%)',
|
|
8085
|
+
zIndex: 2,
|
|
8086
|
+
onMouseDown: handleThumbMouseDown,
|
|
8087
|
+
onTouchStart: handleThumbMouseDown,
|
|
8088
|
+
onKeyDown: handleKeyDown
|
|
8089
|
+
}, ThumbSizes[size], views.thumb), showTooltip && (isHovered || isDragging) && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8090
|
+
position: "absolute",
|
|
8091
|
+
bottom: "100%",
|
|
8092
|
+
left: "50%",
|
|
8093
|
+
transform: "translateX(-50%)",
|
|
8094
|
+
marginBottom: 8,
|
|
8095
|
+
padding: "4px 8px",
|
|
8096
|
+
backgroundColor: "color.black",
|
|
8097
|
+
color: "color.white",
|
|
8098
|
+
borderRadius: 4,
|
|
8099
|
+
fontSize: 12,
|
|
8100
|
+
whiteSpace: "nowrap",
|
|
8101
|
+
zIndex: 3
|
|
8102
|
+
}, views.tooltip), /*#__PURE__*/React.createElement(Text$1, Object.assign({}, (_views$tooltip = views.tooltip) == null ? void 0 : _views$tooltip.text), currentValue == null ? void 0 : currentValue.toFixed(step < 1 ? 1 : 0)))))), helperText && /*#__PURE__*/React.createElement(HelperText, null, helperText));
|
|
8103
|
+
// Enhanced view with vertical support and other features
|
|
8104
|
+
var enhancedView = /*#__PURE__*/React.createElement(Center
|
|
8105
|
+
// Use Center to easily manage orientation layout
|
|
8106
|
+
, Object.assign({}, OrientationStyles[orientation], {
|
|
8107
|
+
position: "relative" // Needed for absolute positioning of thumb/tooltip
|
|
8108
|
+
,
|
|
8109
|
+
onMouseEnter: () => !isDisabled && setIsHovered(true),
|
|
8110
|
+
onMouseLeave: () => !isDisabled && setIsHovered(false)
|
|
8111
|
+
}, props, views == null ? void 0 : views.container), label && (/*#__PURE__*/React.createElement(Horizontal, {
|
|
8112
|
+
justifyContent: "space-between",
|
|
8113
|
+
alignItems: "center",
|
|
8114
|
+
marginBottom: 8,
|
|
8115
|
+
width: "100%"
|
|
8116
|
+
}, /*#__PURE__*/React.createElement(Text$1, Object.assign({
|
|
8117
|
+
fontSize: 14,
|
|
8118
|
+
fontWeight: 500
|
|
8119
|
+
}, views.label), label), showValue && (/*#__PURE__*/React.createElement(Text$1, Object.assign({
|
|
8120
|
+
fontSize: 14,
|
|
8121
|
+
color: "color.blueGray.500"
|
|
8122
|
+
}, views.valueLabel), currentValue)))), /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8123
|
+
ref: trackRef,
|
|
8124
|
+
position: "relative",
|
|
8125
|
+
borderRadius: trackCrossAxisSize / 2,
|
|
8126
|
+
backgroundColor: isDisabled ? disabledColor : trackColor,
|
|
8127
|
+
cursor: isDisabled ? 'not-allowed' : 'pointer',
|
|
8128
|
+
width: isVertical ? trackCrossAxisSize + "px" : '100%',
|
|
8129
|
+
height: isVertical ? '100%' : trackCrossAxisSize + "px",
|
|
8130
|
+
onMouseDown: handleTrackMouseDown,
|
|
8131
|
+
onTouchStart: handleTrackMouseDown
|
|
8132
|
+
}, views == null ? void 0 : views.track), stepValues && stepValues.length > 0 && (/*#__PURE__*/React.createElement(React.Fragment, null, stepValues.map(stepValue => {
|
|
8133
|
+
var stepPercentage = (stepValue - min) / (max - min) * 100;
|
|
8134
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8135
|
+
key: stepValue,
|
|
8136
|
+
position: "absolute",
|
|
8137
|
+
width: 4,
|
|
8138
|
+
height: 4,
|
|
8139
|
+
borderRadius: "50%",
|
|
8140
|
+
backgroundColor: isDisabled ? disabledColor : themeColor,
|
|
8141
|
+
zIndex: 1
|
|
8142
|
+
}, isVertical ? {
|
|
8143
|
+
bottom: stepPercentage + "%",
|
|
8144
|
+
left: '50%',
|
|
8145
|
+
transform: 'translate(-50%, 50%)'
|
|
8146
|
+
} : {
|
|
8147
|
+
left: stepPercentage + "%",
|
|
8148
|
+
top: '50%',
|
|
8149
|
+
transform: 'translate(-50%, -50%)'
|
|
8150
|
+
}, views.stepMarks));
|
|
8151
|
+
}))), /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8152
|
+
position: "absolute",
|
|
8153
|
+
borderRadius: trackCrossAxisSize / 2,
|
|
8154
|
+
backgroundColor: isDisabled ? disabledColor : themeColor
|
|
8155
|
+
}, isVertical ? {
|
|
8156
|
+
bottom: 0,
|
|
8157
|
+
left: 0,
|
|
8158
|
+
width: '100%',
|
|
8159
|
+
height: thumbPositionPercent + "%"
|
|
8160
|
+
} : {
|
|
8161
|
+
top: 0,
|
|
8162
|
+
left: 0,
|
|
8163
|
+
height: '100%',
|
|
8164
|
+
width: thumbPositionPercent + "%"
|
|
8165
|
+
}, views == null ? void 0 : views.filledTrack, views == null ? void 0 : views.progress)), /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8166
|
+
ref: thumbRef,
|
|
8167
|
+
role: "slider",
|
|
8168
|
+
tabIndex: isDisabled ? -1 : 0,
|
|
8169
|
+
"aria-valuemin": min,
|
|
8170
|
+
"aria-valuemax": max,
|
|
8171
|
+
"aria-valuenow": currentValue,
|
|
8172
|
+
"aria-orientation": orientation,
|
|
8173
|
+
"aria-disabled": isDisabled,
|
|
8174
|
+
"aria-label": ariaLabel,
|
|
8175
|
+
position: "absolute",
|
|
8176
|
+
width: thumbSize + "px",
|
|
8177
|
+
height: thumbSize + "px",
|
|
8178
|
+
borderRadius: "50%",
|
|
8179
|
+
backgroundColor: isDisabled ? disabledColor : themeColor,
|
|
8180
|
+
border: "2px solid " + getColor('color.white'),
|
|
8181
|
+
boxShadow: "0 1px 3px rgba(0, 0, 0, 0.2)",
|
|
8182
|
+
cursor: isDisabled ? 'not-allowed' : 'grab',
|
|
8183
|
+
transform: isVertical ? 'translateX(-50%)' : 'translateY(-50%)',
|
|
8184
|
+
zIndex: 2,
|
|
8185
|
+
transition: isDragging ? 'none' : 'left 0.1s, bottom 0.1s'
|
|
8186
|
+
}, isVertical ? {
|
|
8187
|
+
left: '50%',
|
|
8188
|
+
bottom: thumbPositionPercent + "%"
|
|
8189
|
+
} : {
|
|
8190
|
+
top: '50%',
|
|
8191
|
+
left: thumbPositionPercent + "%"
|
|
8192
|
+
}, {
|
|
8193
|
+
onMouseDown: handleThumbMouseDown,
|
|
8194
|
+
onTouchStart: handleThumbMouseDown,
|
|
8195
|
+
onKeyDown: handleKeyDown
|
|
8196
|
+
}, views == null ? void 0 : views.thumb), showTooltip && (isHovered || isDragging) && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
8197
|
+
position: "absolute",
|
|
8198
|
+
padding: "4px 8px",
|
|
8199
|
+
backgroundColor: getColor('color.black'),
|
|
8200
|
+
color: getColor('color.white'),
|
|
8201
|
+
borderRadius: "4px",
|
|
8202
|
+
fontSize: "12px",
|
|
8203
|
+
whiteSpace: "nowrap",
|
|
8204
|
+
zIndex: 3
|
|
8205
|
+
}, isVertical ? {
|
|
8206
|
+
left: '100%',
|
|
8207
|
+
marginLeft: '8px',
|
|
8208
|
+
bottom: '0',
|
|
8209
|
+
transform: 'translateY(50%)'
|
|
8210
|
+
} : {
|
|
8211
|
+
bottom: '100%',
|
|
8212
|
+
left: '50%',
|
|
8213
|
+
marginBottom: '8px',
|
|
8214
|
+
transform: 'translateX(-50%)'
|
|
8215
|
+
}, views == null ? void 0 : views.tooltip), /*#__PURE__*/React.createElement(Text$1, Object.assign({}, views == null || (_views$tooltip2 = views.tooltip) == null ? void 0 : _views$tooltip2.text), currentValue == null ? void 0 : currentValue.toFixed(step < 1 ? 1 : 0)))))), helperText && /*#__PURE__*/React.createElement(HelperText, {
|
|
8216
|
+
marginTop: 8
|
|
8217
|
+
}, helperText));
|
|
8218
|
+
// Use the enhanced view if orientation is vertical or showTooltip is true
|
|
8219
|
+
// Otherwise use the legacy view for backward compatibility
|
|
8220
|
+
return isVertical || showTooltip ? enhancedView : legacyView;
|
|
8221
|
+
};
|
|
8222
|
+
|
|
8223
|
+
var SliderComponent = props => {
|
|
8224
|
+
// Get Formik props (value, onChange, etc.)
|
|
8225
|
+
var formProps = useFormikInput(props);
|
|
8226
|
+
// Get slider state and handlers
|
|
8227
|
+
var sliderState = useSliderState(Object.assign({}, props, {
|
|
8228
|
+
value: formProps.value !== undefined ? Number(formProps.value) : undefined,
|
|
8229
|
+
onChange: value => {
|
|
8230
|
+
// Call Formik's onChange
|
|
8231
|
+
formProps.onChange(value);
|
|
8232
|
+
// Call the original onChange if provided
|
|
8233
|
+
props.onChange == null || props.onChange(value);
|
|
8234
|
+
}
|
|
8235
|
+
}));
|
|
8236
|
+
// Render the slider with both Formik props and slider state
|
|
8237
|
+
return /*#__PURE__*/React.createElement(SliderView, Object.assign({}, props, sliderState, formProps));
|
|
8238
|
+
};
|
|
8239
|
+
/**
|
|
8240
|
+
* Slider component integrated with Formik for form state management.
|
|
8241
|
+
* Allows users to select a value from a range by moving a handle.
|
|
8242
|
+
*/
|
|
8243
|
+
var FormikSlider = SliderComponent;
|
|
8244
|
+
|
|
8245
|
+
var SliderComponent$1 = props => {
|
|
8246
|
+
// Get state and handlers from the custom hook
|
|
8247
|
+
var sliderState = useSliderState(props);
|
|
8248
|
+
// Render the view component, passing down props and state
|
|
8249
|
+
return /*#__PURE__*/React.createElement(SliderView, Object.assign({}, props, sliderState));
|
|
8250
|
+
};
|
|
8251
|
+
/**
|
|
8252
|
+
* Slider allows users to select a value from a range by moving a handle.
|
|
8253
|
+
*/
|
|
8254
|
+
var Slider = SliderComponent$1;
|
|
8255
|
+
|
|
8256
|
+
// Create your store with the initial state and actions.
|
|
8257
|
+
var useMessageStore = /*#__PURE__*/create(set => ({
|
|
8258
|
+
// initial state
|
|
8259
|
+
visible: false,
|
|
8260
|
+
title: '',
|
|
8261
|
+
subtitle: '',
|
|
8262
|
+
variant: 'info',
|
|
8263
|
+
isClosable: false,
|
|
8264
|
+
views: {},
|
|
8265
|
+
action: () => {},
|
|
8266
|
+
actionText: '',
|
|
8267
|
+
showIcon: false,
|
|
8268
|
+
timeout: 3000,
|
|
8269
|
+
show: function show(variant, title, subtitle, isClosable, views, action, actionText, showIcon, timeout) {
|
|
8270
|
+
if (title === void 0) {
|
|
8271
|
+
title = '';
|
|
8272
|
+
}
|
|
8273
|
+
if (subtitle === void 0) {
|
|
8274
|
+
subtitle = '';
|
|
8275
|
+
}
|
|
8276
|
+
return set({
|
|
8277
|
+
visible: true,
|
|
7009
8278
|
variant,
|
|
7010
8279
|
title,
|
|
7011
8280
|
subtitle,
|
|
@@ -7516,7 +8785,7 @@ var UploadView = _ref => {
|
|
|
7516
8785
|
}, views == null ? void 0 : views.view)));
|
|
7517
8786
|
};
|
|
7518
8787
|
|
|
7519
|
-
var _excluded$
|
|
8788
|
+
var _excluded$B = ["accept", "icon", "text", "maxSize", "onFileSelect", "validateFile", "isLoading", "progress"];
|
|
7520
8789
|
var Uploader = _ref => {
|
|
7521
8790
|
var {
|
|
7522
8791
|
accept = '*/*',
|
|
@@ -7528,7 +8797,7 @@ var Uploader = _ref => {
|
|
|
7528
8797
|
isLoading = false,
|
|
7529
8798
|
progress = 0
|
|
7530
8799
|
} = _ref,
|
|
7531
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
8800
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$B);
|
|
7532
8801
|
var {
|
|
7533
8802
|
previewUrl,
|
|
7534
8803
|
thumbnailUrl,
|
|
@@ -7665,11 +8934,11 @@ var HeaderIconSizes = {
|
|
|
7665
8934
|
xl: 28
|
|
7666
8935
|
};
|
|
7667
8936
|
|
|
7668
|
-
var _excluded$
|
|
7669
|
-
_excluded2$
|
|
7670
|
-
_excluded3$
|
|
7671
|
-
_excluded4$
|
|
7672
|
-
_excluded5$
|
|
8937
|
+
var _excluded$C = ["children", "blur", "isOpen", "isClosePrevented", "onClose", "position", "views"],
|
|
8938
|
+
_excluded2$8 = ["children", "shadow", "isFullScreen", "shape", "views"],
|
|
8939
|
+
_excluded3$5 = ["children", "buttonColor", "iconSize", "buttonPosition", "views"],
|
|
8940
|
+
_excluded4$4 = ["children", "views"],
|
|
8941
|
+
_excluded5$2 = ["children", "views"];
|
|
7673
8942
|
var ModalOverlay = _ref => {
|
|
7674
8943
|
var {
|
|
7675
8944
|
children,
|
|
@@ -7680,7 +8949,7 @@ var ModalOverlay = _ref => {
|
|
|
7680
8949
|
position = 'center',
|
|
7681
8950
|
views
|
|
7682
8951
|
} = _ref,
|
|
7683
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
8952
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$C);
|
|
7684
8953
|
var handleClick = () => {
|
|
7685
8954
|
if (!isClosePrevented) onClose();
|
|
7686
8955
|
};
|
|
@@ -7714,7 +8983,7 @@ var ModalContainer = _ref2 => {
|
|
|
7714
8983
|
shape = 'rounded',
|
|
7715
8984
|
views
|
|
7716
8985
|
} = _ref2,
|
|
7717
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded2$
|
|
8986
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded2$8);
|
|
7718
8987
|
var defaultShadow = typeof document !== undefined ? {
|
|
7719
8988
|
boxShadow: '0px 2px 8px rgba(0, 0, 0, 0.3)'
|
|
7720
8989
|
} : {
|
|
@@ -7746,7 +9015,7 @@ var ModalHeader = _ref3 => {
|
|
|
7746
9015
|
buttonPosition = 'right',
|
|
7747
9016
|
views
|
|
7748
9017
|
} = _ref3,
|
|
7749
|
-
props = _objectWithoutPropertiesLoose(_ref3, _excluded3$
|
|
9018
|
+
props = _objectWithoutPropertiesLoose(_ref3, _excluded3$5);
|
|
7750
9019
|
var onClose = props.onClose ? props.onClose : hideModal;
|
|
7751
9020
|
var buttonIcon = /*#__PURE__*/React.createElement(Button, {
|
|
7752
9021
|
onClick: onClose,
|
|
@@ -7771,7 +9040,7 @@ var ModalBody = _ref4 => {
|
|
|
7771
9040
|
children,
|
|
7772
9041
|
views
|
|
7773
9042
|
} = _ref4,
|
|
7774
|
-
props = _objectWithoutPropertiesLoose(_ref4, _excluded4$
|
|
9043
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded4$4);
|
|
7775
9044
|
var defaultBorder = {
|
|
7776
9045
|
borderBottomWidth: 2,
|
|
7777
9046
|
borderTopWidth: 2,
|
|
@@ -7788,7 +9057,7 @@ var ModalFooter = _ref5 => {
|
|
|
7788
9057
|
children,
|
|
7789
9058
|
views
|
|
7790
9059
|
} = _ref5,
|
|
7791
|
-
props = _objectWithoutPropertiesLoose(_ref5, _excluded5$
|
|
9060
|
+
props = _objectWithoutPropertiesLoose(_ref5, _excluded5$2);
|
|
7792
9061
|
return /*#__PURE__*/React.createElement(Horizontal$1, Object.assign({
|
|
7793
9062
|
marginTop: "auto",
|
|
7794
9063
|
alignItems: "center",
|
|
@@ -7850,6 +9119,344 @@ Modal.Body = ModalBody;
|
|
|
7850
9119
|
Modal.Footer = ModalFooter;
|
|
7851
9120
|
Modal.Layout = ModalLayout;
|
|
7852
9121
|
|
|
9122
|
+
var useNavigationMenuState = function useNavigationMenuState(defaultActiveItemId, defaultExpandedItemIds) {
|
|
9123
|
+
if (defaultActiveItemId === void 0) {
|
|
9124
|
+
defaultActiveItemId = null;
|
|
9125
|
+
}
|
|
9126
|
+
if (defaultExpandedItemIds === void 0) {
|
|
9127
|
+
defaultExpandedItemIds = [];
|
|
9128
|
+
}
|
|
9129
|
+
var [activeItemId, setActiveItemId] = useState(defaultActiveItemId);
|
|
9130
|
+
var [expandedItemIds, setExpandedItemIds] = useState(defaultExpandedItemIds);
|
|
9131
|
+
var toggleExpandedItem = itemId => {
|
|
9132
|
+
setExpandedItemIds(prevExpandedItemIds => {
|
|
9133
|
+
// Check if the item is already expanded
|
|
9134
|
+
var isExpanded = prevExpandedItemIds.includes(itemId);
|
|
9135
|
+
if (isExpanded) {
|
|
9136
|
+
// If expanded, remove it from the list
|
|
9137
|
+
return prevExpandedItemIds.filter(id => id !== itemId);
|
|
9138
|
+
} else {
|
|
9139
|
+
// If not expanded, add it to the list
|
|
9140
|
+
return [...prevExpandedItemIds, itemId];
|
|
9141
|
+
}
|
|
9142
|
+
});
|
|
9143
|
+
};
|
|
9144
|
+
var isItemExpanded = itemId => {
|
|
9145
|
+
return expandedItemIds.includes(itemId);
|
|
9146
|
+
};
|
|
9147
|
+
return {
|
|
9148
|
+
activeItemId,
|
|
9149
|
+
setActiveItemId,
|
|
9150
|
+
expandedItemIds,
|
|
9151
|
+
toggleExpandedItem,
|
|
9152
|
+
isItemExpanded
|
|
9153
|
+
};
|
|
9154
|
+
};
|
|
9155
|
+
|
|
9156
|
+
var NavigationMenuSizes = {
|
|
9157
|
+
sm: {
|
|
9158
|
+
padding: '8px 12px',
|
|
9159
|
+
fontSize: '14px'
|
|
9160
|
+
},
|
|
9161
|
+
md: {
|
|
9162
|
+
padding: '10px 16px',
|
|
9163
|
+
fontSize: '16px'
|
|
9164
|
+
},
|
|
9165
|
+
lg: {
|
|
9166
|
+
padding: '12px 20px',
|
|
9167
|
+
fontSize: '18px'
|
|
9168
|
+
}
|
|
9169
|
+
};
|
|
9170
|
+
var NavigationMenuVariants = {
|
|
9171
|
+
default: {
|
|
9172
|
+
backgroundColor: 'transparent',
|
|
9173
|
+
color: 'color.gray.800'
|
|
9174
|
+
},
|
|
9175
|
+
filled: {
|
|
9176
|
+
backgroundColor: 'color.gray.100',
|
|
9177
|
+
color: 'color.gray.800'
|
|
9178
|
+
},
|
|
9179
|
+
outline: {
|
|
9180
|
+
backgroundColor: 'transparent',
|
|
9181
|
+
borderWidth: '1px',
|
|
9182
|
+
borderStyle: 'solid',
|
|
9183
|
+
borderColor: 'color.gray.200',
|
|
9184
|
+
color: 'color.gray.800'
|
|
9185
|
+
}
|
|
9186
|
+
};
|
|
9187
|
+
var NavigationMenuOrientations = {
|
|
9188
|
+
horizontal: {
|
|
9189
|
+
flexDirection: 'row'
|
|
9190
|
+
},
|
|
9191
|
+
vertical: {
|
|
9192
|
+
flexDirection: 'column'
|
|
9193
|
+
}
|
|
9194
|
+
};
|
|
9195
|
+
var NavigationMenuItemStates = {
|
|
9196
|
+
active: {
|
|
9197
|
+
backgroundColor: 'color.gray.200',
|
|
9198
|
+
fontWeight: 'bold'
|
|
9199
|
+
},
|
|
9200
|
+
hover: {
|
|
9201
|
+
backgroundColor: 'color.gray.100'
|
|
9202
|
+
},
|
|
9203
|
+
disabled: {
|
|
9204
|
+
opacity: 0.5,
|
|
9205
|
+
cursor: 'not-allowed'
|
|
9206
|
+
}
|
|
9207
|
+
};
|
|
9208
|
+
|
|
9209
|
+
// Create context for the NavigationMenu
|
|
9210
|
+
var NavigationMenuContext = /*#__PURE__*/createContext({
|
|
9211
|
+
activeItemId: null,
|
|
9212
|
+
setActiveItemId: () => {},
|
|
9213
|
+
expandedItemIds: [],
|
|
9214
|
+
toggleExpandedItem: () => {},
|
|
9215
|
+
isItemExpanded: () => false,
|
|
9216
|
+
orientation: 'vertical',
|
|
9217
|
+
size: 'md',
|
|
9218
|
+
variant: 'default'
|
|
9219
|
+
});
|
|
9220
|
+
// Provider component for the NavigationMenu context
|
|
9221
|
+
var NavigationMenuProvider = _ref => {
|
|
9222
|
+
var {
|
|
9223
|
+
children,
|
|
9224
|
+
value
|
|
9225
|
+
} = _ref;
|
|
9226
|
+
return /*#__PURE__*/React.createElement(NavigationMenuContext.Provider, {
|
|
9227
|
+
value: value
|
|
9228
|
+
}, children);
|
|
9229
|
+
};
|
|
9230
|
+
// Hook to use the NavigationMenu context
|
|
9231
|
+
var useNavigationMenuContext = () => {
|
|
9232
|
+
var context = useContext(NavigationMenuContext);
|
|
9233
|
+
if (!context) {
|
|
9234
|
+
throw new Error('useNavigationMenuContext must be used within a NavigationMenuProvider');
|
|
9235
|
+
}
|
|
9236
|
+
return context;
|
|
9237
|
+
};
|
|
9238
|
+
// NavigationMenu List component
|
|
9239
|
+
var NavigationMenuList = _ref2 => {
|
|
9240
|
+
var {
|
|
9241
|
+
children,
|
|
9242
|
+
views
|
|
9243
|
+
} = _ref2;
|
|
9244
|
+
var {
|
|
9245
|
+
orientation
|
|
9246
|
+
} = useNavigationMenuContext();
|
|
9247
|
+
var Container = orientation === 'horizontal' ? Horizontal$1 : Vertical$1;
|
|
9248
|
+
return /*#__PURE__*/React.createElement(Container, Object.assign({
|
|
9249
|
+
width: "100%",
|
|
9250
|
+
gap: 2
|
|
9251
|
+
}, NavigationMenuOrientations[orientation], views == null ? void 0 : views.container), children);
|
|
9252
|
+
};
|
|
9253
|
+
// NavigationMenu Item component
|
|
9254
|
+
var NavigationMenuItem = _ref3 => {
|
|
9255
|
+
var {
|
|
9256
|
+
item,
|
|
9257
|
+
views
|
|
9258
|
+
} = _ref3;
|
|
9259
|
+
var {
|
|
9260
|
+
activeItemId,
|
|
9261
|
+
setActiveItemId,
|
|
9262
|
+
// isItemExpanded,
|
|
9263
|
+
orientation,
|
|
9264
|
+
size,
|
|
9265
|
+
variant,
|
|
9266
|
+
onItemActivate
|
|
9267
|
+
} = useNavigationMenuContext();
|
|
9268
|
+
var isActive = activeItemId === item.id;
|
|
9269
|
+
var hasSubItems = item.items && item.items.length > 0;
|
|
9270
|
+
// const isExpanded = hasSubItems && isItemExpanded(item.id);
|
|
9271
|
+
var handleClick = () => {
|
|
9272
|
+
if (item.disabled) return;
|
|
9273
|
+
setActiveItemId(item.id);
|
|
9274
|
+
if (onItemActivate) {
|
|
9275
|
+
onItemActivate(item.id);
|
|
9276
|
+
}
|
|
9277
|
+
};
|
|
9278
|
+
var Container = orientation === 'horizontal' ? Horizontal$1 : Vertical$1;
|
|
9279
|
+
// Render item with sub-items
|
|
9280
|
+
if (hasSubItems) {
|
|
9281
|
+
var _item$items;
|
|
9282
|
+
return /*#__PURE__*/React.createElement(Container, Object.assign({
|
|
9283
|
+
width: "100%",
|
|
9284
|
+
flexDirection: orientation === 'horizontal' ? 'column' : 'column',
|
|
9285
|
+
position: "relative"
|
|
9286
|
+
}, views == null ? void 0 : views.item), /*#__PURE__*/React.createElement(NavigationMenuTrigger, {
|
|
9287
|
+
itemId: item.id,
|
|
9288
|
+
disabled: item.disabled,
|
|
9289
|
+
views: views
|
|
9290
|
+
}, item.icon && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
9291
|
+
marginRight: 8
|
|
9292
|
+
}, views == null ? void 0 : views.icon), item.icon)), item.label), /*#__PURE__*/React.createElement(NavigationMenuContent, {
|
|
9293
|
+
itemId: item.id
|
|
9294
|
+
}, /*#__PURE__*/React.createElement(NavigationMenuList, null, (_item$items = item.items) == null ? void 0 : _item$items.map(subItem => (/*#__PURE__*/React.createElement(NavigationMenuItem, {
|
|
9295
|
+
key: subItem.id,
|
|
9296
|
+
item: subItem
|
|
9297
|
+
}))))));
|
|
9298
|
+
}
|
|
9299
|
+
// Render regular item (no sub-items)
|
|
9300
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
9301
|
+
as: item.href ? 'a' : 'div',
|
|
9302
|
+
to: item.href,
|
|
9303
|
+
onClick: handleClick,
|
|
9304
|
+
cursor: item.disabled ? 'not-allowed' : 'pointer',
|
|
9305
|
+
opacity: item.disabled ? 0.5 : 1,
|
|
9306
|
+
width: "100%",
|
|
9307
|
+
display: "flex",
|
|
9308
|
+
alignItems: "center",
|
|
9309
|
+
borderRadius: 4,
|
|
9310
|
+
transition: "background-color 0.2s ease"
|
|
9311
|
+
}, NavigationMenuSizes[size], NavigationMenuVariants[variant], isActive ? NavigationMenuItemStates.active : {}, {
|
|
9312
|
+
_hover: !item.disabled ? NavigationMenuItemStates.hover : {}
|
|
9313
|
+
}, views == null ? void 0 : views.item), item.icon && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
9314
|
+
marginRight: 8
|
|
9315
|
+
}, views == null ? void 0 : views.icon), item.icon)), item.label);
|
|
9316
|
+
};
|
|
9317
|
+
// NavigationMenu Trigger component
|
|
9318
|
+
var NavigationMenuTrigger = _ref4 => {
|
|
9319
|
+
var {
|
|
9320
|
+
children,
|
|
9321
|
+
itemId,
|
|
9322
|
+
disabled,
|
|
9323
|
+
views
|
|
9324
|
+
} = _ref4;
|
|
9325
|
+
var {
|
|
9326
|
+
activeItemId,
|
|
9327
|
+
toggleExpandedItem,
|
|
9328
|
+
isItemExpanded,
|
|
9329
|
+
size,
|
|
9330
|
+
variant
|
|
9331
|
+
} = useNavigationMenuContext();
|
|
9332
|
+
var isActive = activeItemId === itemId;
|
|
9333
|
+
var isExpanded = isItemExpanded(itemId);
|
|
9334
|
+
var handleClick = e => {
|
|
9335
|
+
e.preventDefault();
|
|
9336
|
+
if (disabled) return;
|
|
9337
|
+
toggleExpandedItem(itemId);
|
|
9338
|
+
};
|
|
9339
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
9340
|
+
onClick: handleClick,
|
|
9341
|
+
cursor: disabled ? 'not-allowed' : 'pointer',
|
|
9342
|
+
opacity: disabled ? 0.5 : 1,
|
|
9343
|
+
width: "100%",
|
|
9344
|
+
display: "flex",
|
|
9345
|
+
alignItems: "center",
|
|
9346
|
+
justifyContent: "space-between",
|
|
9347
|
+
borderRadius: 4,
|
|
9348
|
+
transition: "background-color 0.2s ease"
|
|
9349
|
+
}, NavigationMenuSizes[size], NavigationMenuVariants[variant], isActive ? NavigationMenuItemStates.active : {}, {
|
|
9350
|
+
_hover: !disabled ? NavigationMenuItemStates.hover : {}
|
|
9351
|
+
}, views == null ? void 0 : views.trigger), /*#__PURE__*/React.createElement(View$1, {
|
|
9352
|
+
display: "flex",
|
|
9353
|
+
alignItems: "center"
|
|
9354
|
+
}, children), /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
9355
|
+
transition: "transform 0.2s ease",
|
|
9356
|
+
transform: isExpanded ? 'rotate(180deg)' : 'rotate(0deg)'
|
|
9357
|
+
}, views == null ? void 0 : views.indicator), /*#__PURE__*/React.createElement("svg", {
|
|
9358
|
+
width: "16",
|
|
9359
|
+
height: "16",
|
|
9360
|
+
viewBox: "0 0 24 24",
|
|
9361
|
+
fill: "none",
|
|
9362
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
9363
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
9364
|
+
d: "M16.59 8.59L12 13.17L7.41 8.59L6 10L12 16L18 10L16.59 8.59Z",
|
|
9365
|
+
fill: "currentColor"
|
|
9366
|
+
}))));
|
|
9367
|
+
};
|
|
9368
|
+
// NavigationMenu Content component
|
|
9369
|
+
var NavigationMenuContent = _ref5 => {
|
|
9370
|
+
var {
|
|
9371
|
+
children,
|
|
9372
|
+
itemId,
|
|
9373
|
+
views
|
|
9374
|
+
} = _ref5;
|
|
9375
|
+
var {
|
|
9376
|
+
isItemExpanded,
|
|
9377
|
+
orientation
|
|
9378
|
+
} = useNavigationMenuContext();
|
|
9379
|
+
var isExpanded = isItemExpanded(itemId);
|
|
9380
|
+
if (!isExpanded) {
|
|
9381
|
+
return null;
|
|
9382
|
+
}
|
|
9383
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
9384
|
+
paddingLeft: orientation === 'vertical' ? 16 : 0,
|
|
9385
|
+
paddingTop: orientation === 'horizontal' ? 8 : 0,
|
|
9386
|
+
overflow: "hidden",
|
|
9387
|
+
width: "100%"
|
|
9388
|
+
}, views == null ? void 0 : views.container), children);
|
|
9389
|
+
};
|
|
9390
|
+
// Main NavigationMenu View component
|
|
9391
|
+
var NavigationMenuView = _ref6 => {
|
|
9392
|
+
var {
|
|
9393
|
+
items,
|
|
9394
|
+
orientation,
|
|
9395
|
+
//size, variant,
|
|
9396
|
+
views
|
|
9397
|
+
} = _ref6;
|
|
9398
|
+
var Container = orientation === 'horizontal' ? Horizontal$1 : Vertical$1;
|
|
9399
|
+
return /*#__PURE__*/React.createElement(Container, Object.assign({
|
|
9400
|
+
width: "100%"
|
|
9401
|
+
}, NavigationMenuOrientations[orientation], views == null ? void 0 : views.container), /*#__PURE__*/React.createElement(NavigationMenuList, {
|
|
9402
|
+
views: views
|
|
9403
|
+
}, items.map(item => (/*#__PURE__*/React.createElement(NavigationMenuItem, {
|
|
9404
|
+
key: item.id,
|
|
9405
|
+
item: item,
|
|
9406
|
+
views: views
|
|
9407
|
+
})))));
|
|
9408
|
+
};
|
|
9409
|
+
|
|
9410
|
+
var _excluded$D = ["items", "orientation", "size", "variant", "defaultActiveItemId", "defaultExpandedItemIds", "onItemActivate", "views"];
|
|
9411
|
+
/**
|
|
9412
|
+
* NavigationMenu component for creating navigation menus with optional nested items.
|
|
9413
|
+
*/
|
|
9414
|
+
var NavigationMenuComponent = _ref => {
|
|
9415
|
+
var {
|
|
9416
|
+
items,
|
|
9417
|
+
orientation = 'vertical',
|
|
9418
|
+
size = 'md',
|
|
9419
|
+
variant = 'default',
|
|
9420
|
+
defaultActiveItemId = null,
|
|
9421
|
+
defaultExpandedItemIds = [],
|
|
9422
|
+
onItemActivate,
|
|
9423
|
+
views
|
|
9424
|
+
} = _ref,
|
|
9425
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$D);
|
|
9426
|
+
var {
|
|
9427
|
+
activeItemId,
|
|
9428
|
+
setActiveItemId,
|
|
9429
|
+
expandedItemIds,
|
|
9430
|
+
toggleExpandedItem,
|
|
9431
|
+
isItemExpanded
|
|
9432
|
+
} = useNavigationMenuState(defaultActiveItemId, defaultExpandedItemIds);
|
|
9433
|
+
return /*#__PURE__*/React.createElement(NavigationMenuProvider, {
|
|
9434
|
+
value: {
|
|
9435
|
+
activeItemId,
|
|
9436
|
+
setActiveItemId,
|
|
9437
|
+
expandedItemIds,
|
|
9438
|
+
toggleExpandedItem,
|
|
9439
|
+
isItemExpanded,
|
|
9440
|
+
orientation,
|
|
9441
|
+
size,
|
|
9442
|
+
variant,
|
|
9443
|
+
onItemActivate
|
|
9444
|
+
}
|
|
9445
|
+
}, /*#__PURE__*/React.createElement(NavigationMenuView, Object.assign({
|
|
9446
|
+
items: items,
|
|
9447
|
+
orientation: orientation,
|
|
9448
|
+
size: size,
|
|
9449
|
+
variant: variant,
|
|
9450
|
+
views: views
|
|
9451
|
+
}, props)));
|
|
9452
|
+
};
|
|
9453
|
+
var NavigationMenu = NavigationMenuComponent;
|
|
9454
|
+
// Assign the sub-components to the main component
|
|
9455
|
+
NavigationMenu.List = NavigationMenuList;
|
|
9456
|
+
NavigationMenu.Item = NavigationMenuItem;
|
|
9457
|
+
NavigationMenu.Trigger = NavigationMenuTrigger;
|
|
9458
|
+
NavigationMenu.Content = NavigationMenuContent;
|
|
9459
|
+
|
|
7853
9460
|
var defaultStyles = {};
|
|
7854
9461
|
// Create a context that includes both styles and the onClick function
|
|
7855
9462
|
var TableContext = /*#__PURE__*/createContext({
|
|
@@ -8159,7 +9766,7 @@ var useToggleState = defaultToggled => {
|
|
|
8159
9766
|
};
|
|
8160
9767
|
};
|
|
8161
9768
|
|
|
8162
|
-
var _excluded$
|
|
9769
|
+
var _excluded$E = ["children", "shape", "variant", "isHovered", "setIsHovered", "isDisabled", "isToggle", "setIsToggled", "onToggle", "views"];
|
|
8163
9770
|
var ToggleView = _ref => {
|
|
8164
9771
|
var {
|
|
8165
9772
|
children,
|
|
@@ -8173,7 +9780,7 @@ var ToggleView = _ref => {
|
|
|
8173
9780
|
onToggle,
|
|
8174
9781
|
views
|
|
8175
9782
|
} = _ref,
|
|
8176
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
9783
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$E);
|
|
8177
9784
|
var toggleColor = !isDisabled ? 'color.trueGray.400' : 'theme.disabled';
|
|
8178
9785
|
var isActive = !!(isToggle || isHovered);
|
|
8179
9786
|
var toggleVariants = {
|
|
@@ -8216,7 +9823,7 @@ var ToggleView = _ref => {
|
|
|
8216
9823
|
}, toggleVariants[variant], props, views == null ? void 0 : views.container), children);
|
|
8217
9824
|
};
|
|
8218
9825
|
|
|
8219
|
-
var _excluded$
|
|
9826
|
+
var _excluded$F = ["children", "shape", "variant", "isDisabled", "isToggled", "onToggle"];
|
|
8220
9827
|
// Destructuring properties from ToggleProps to be used within the ToggleComponent.
|
|
8221
9828
|
var ToggleComponent = _ref => {
|
|
8222
9829
|
var {
|
|
@@ -8228,7 +9835,7 @@ var ToggleComponent = _ref => {
|
|
|
8228
9835
|
isToggled = false,
|
|
8229
9836
|
onToggle
|
|
8230
9837
|
} = _ref,
|
|
8231
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
9838
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$F);
|
|
8232
9839
|
// Initializing toggle state and set state functions using the custom hook useToggleState.
|
|
8233
9840
|
var {
|
|
8234
9841
|
isHovered,
|
|
@@ -8468,5 +10075,550 @@ var DragAndDropComponent = props => {
|
|
|
8468
10075
|
};
|
|
8469
10076
|
var DragAndDrop = DragAndDropComponent;
|
|
8470
10077
|
|
|
8471
|
-
|
|
10078
|
+
var useDropdownMenuState = function useDropdownMenuState(defaultOpen) {
|
|
10079
|
+
if (defaultOpen === void 0) {
|
|
10080
|
+
defaultOpen = false;
|
|
10081
|
+
}
|
|
10082
|
+
var [isOpen, setIsOpen] = useState(defaultOpen);
|
|
10083
|
+
var [activeSubmenuId, setActiveSubmenuId] = useState(null);
|
|
10084
|
+
// Close the dropdown menu when clicking outside
|
|
10085
|
+
useEffect(() => {
|
|
10086
|
+
var handleClickOutside = event => {
|
|
10087
|
+
var path = event.composedPath();
|
|
10088
|
+
var isOutside = !path.some(element => (element == null ? void 0 : element.id) === 'dropdown-menu' || (element == null ? void 0 : element.id) === 'dropdown-trigger');
|
|
10089
|
+
if (isOutside && isOpen) {
|
|
10090
|
+
setIsOpen(false);
|
|
10091
|
+
setActiveSubmenuId(null);
|
|
10092
|
+
}
|
|
10093
|
+
};
|
|
10094
|
+
// Close the dropdown menu when the window is resized
|
|
10095
|
+
var handleResize = () => {
|
|
10096
|
+
if (isOpen) {
|
|
10097
|
+
setIsOpen(false);
|
|
10098
|
+
setActiveSubmenuId(null);
|
|
10099
|
+
}
|
|
10100
|
+
};
|
|
10101
|
+
// Close the dropdown menu when the escape key is pressed
|
|
10102
|
+
var handleKeyDown = event => {
|
|
10103
|
+
if (event.key === 'Escape' && isOpen) {
|
|
10104
|
+
setIsOpen(false);
|
|
10105
|
+
setActiveSubmenuId(null);
|
|
10106
|
+
}
|
|
10107
|
+
};
|
|
10108
|
+
document.addEventListener('mousedown', handleClickOutside);
|
|
10109
|
+
window.addEventListener('resize', handleResize);
|
|
10110
|
+
document.addEventListener('keydown', handleKeyDown);
|
|
10111
|
+
return () => {
|
|
10112
|
+
document.removeEventListener('mousedown', handleClickOutside);
|
|
10113
|
+
window.removeEventListener('resize', handleResize);
|
|
10114
|
+
document.removeEventListener('keydown', handleKeyDown);
|
|
10115
|
+
};
|
|
10116
|
+
}, [isOpen]);
|
|
10117
|
+
return {
|
|
10118
|
+
isOpen,
|
|
10119
|
+
setIsOpen,
|
|
10120
|
+
activeSubmenuId,
|
|
10121
|
+
setActiveSubmenuId
|
|
10122
|
+
};
|
|
10123
|
+
};
|
|
10124
|
+
|
|
10125
|
+
var DropdownMenuSizes = {
|
|
10126
|
+
sm: {
|
|
10127
|
+
padding: '6px 8px',
|
|
10128
|
+
fontSize: '14px',
|
|
10129
|
+
minWidth: '160px'
|
|
10130
|
+
},
|
|
10131
|
+
md: {
|
|
10132
|
+
padding: '8px 12px',
|
|
10133
|
+
fontSize: '16px',
|
|
10134
|
+
minWidth: '180px'
|
|
10135
|
+
},
|
|
10136
|
+
lg: {
|
|
10137
|
+
padding: '10px 16px',
|
|
10138
|
+
fontSize: '18px',
|
|
10139
|
+
minWidth: '200px'
|
|
10140
|
+
}
|
|
10141
|
+
};
|
|
10142
|
+
var DropdownMenuVariants = {
|
|
10143
|
+
default: {
|
|
10144
|
+
backgroundColor: 'white',
|
|
10145
|
+
color: 'color.gray.800'
|
|
10146
|
+
},
|
|
10147
|
+
filled: {
|
|
10148
|
+
backgroundColor: 'color.gray.100',
|
|
10149
|
+
color: 'color.gray.800'
|
|
10150
|
+
},
|
|
10151
|
+
outline: {
|
|
10152
|
+
backgroundColor: 'white',
|
|
10153
|
+
borderWidth: '1px',
|
|
10154
|
+
borderStyle: 'solid',
|
|
10155
|
+
borderColor: 'color.gray.200',
|
|
10156
|
+
color: 'color.gray.800'
|
|
10157
|
+
}
|
|
10158
|
+
};
|
|
10159
|
+
var DropdownMenuItemStates = {
|
|
10160
|
+
hover: {
|
|
10161
|
+
backgroundColor: 'color.gray.100'
|
|
10162
|
+
},
|
|
10163
|
+
active: {
|
|
10164
|
+
backgroundColor: 'color.gray.200'
|
|
10165
|
+
},
|
|
10166
|
+
disabled: {
|
|
10167
|
+
opacity: 0.5,
|
|
10168
|
+
cursor: 'not-allowed'
|
|
10169
|
+
}
|
|
10170
|
+
};
|
|
10171
|
+
// Helper function to calculate position based on side and alignment
|
|
10172
|
+
var getDropdownPosition = function getDropdownPosition(side, align) {
|
|
10173
|
+
if (side === void 0) {
|
|
10174
|
+
side = 'bottom';
|
|
10175
|
+
}
|
|
10176
|
+
if (align === void 0) {
|
|
10177
|
+
align = 'start';
|
|
10178
|
+
}
|
|
10179
|
+
var positions = {
|
|
10180
|
+
top: Object.assign({
|
|
10181
|
+
bottom: '100%',
|
|
10182
|
+
marginBottom: '8px'
|
|
10183
|
+
}, align === 'start' && {
|
|
10184
|
+
left: 0
|
|
10185
|
+
}, align === 'center' && {
|
|
10186
|
+
left: '50%',
|
|
10187
|
+
transform: 'translateX(-50%)'
|
|
10188
|
+
}, align === 'end' && {
|
|
10189
|
+
right: 0
|
|
10190
|
+
}),
|
|
10191
|
+
right: Object.assign({
|
|
10192
|
+
left: '100%',
|
|
10193
|
+
marginLeft: '8px'
|
|
10194
|
+
}, align === 'start' && {
|
|
10195
|
+
top: 0
|
|
10196
|
+
}, align === 'center' && {
|
|
10197
|
+
top: '50%',
|
|
10198
|
+
transform: 'translateY(-50%)'
|
|
10199
|
+
}, align === 'end' && {
|
|
10200
|
+
bottom: 0
|
|
10201
|
+
}),
|
|
10202
|
+
bottom: Object.assign({
|
|
10203
|
+
top: '100%',
|
|
10204
|
+
marginTop: '8px'
|
|
10205
|
+
}, align === 'start' && {
|
|
10206
|
+
left: 0
|
|
10207
|
+
}, align === 'center' && {
|
|
10208
|
+
left: '50%',
|
|
10209
|
+
transform: 'translateX(-50%)'
|
|
10210
|
+
}, align === 'end' && {
|
|
10211
|
+
right: 0
|
|
10212
|
+
}),
|
|
10213
|
+
left: Object.assign({
|
|
10214
|
+
right: '100%',
|
|
10215
|
+
marginRight: '8px'
|
|
10216
|
+
}, align === 'start' && {
|
|
10217
|
+
top: 0
|
|
10218
|
+
}, align === 'center' && {
|
|
10219
|
+
top: '50%',
|
|
10220
|
+
transform: 'translateY(-50%)'
|
|
10221
|
+
}, align === 'end' && {
|
|
10222
|
+
bottom: 0
|
|
10223
|
+
})
|
|
10224
|
+
};
|
|
10225
|
+
return positions[side];
|
|
10226
|
+
};
|
|
10227
|
+
|
|
10228
|
+
var _excluded$G = ["children", "views"],
|
|
10229
|
+
_excluded2$9 = ["items", "side", "align", "views"],
|
|
10230
|
+
_excluded3$6 = ["item", "views"],
|
|
10231
|
+
_excluded4$5 = ["views"],
|
|
10232
|
+
_excluded5$3 = ["trigger", "items", "side", "align", "views"];
|
|
10233
|
+
// Create context for the DropdownMenu
|
|
10234
|
+
var DropdownMenuContext = /*#__PURE__*/createContext({
|
|
10235
|
+
isOpen: false,
|
|
10236
|
+
setIsOpen: () => {},
|
|
10237
|
+
activeSubmenuId: null,
|
|
10238
|
+
setActiveSubmenuId: () => {},
|
|
10239
|
+
size: 'md',
|
|
10240
|
+
variant: 'default'
|
|
10241
|
+
});
|
|
10242
|
+
// Provider component for the DropdownMenu context
|
|
10243
|
+
var DropdownMenuProvider = _ref => {
|
|
10244
|
+
var {
|
|
10245
|
+
children,
|
|
10246
|
+
value
|
|
10247
|
+
} = _ref;
|
|
10248
|
+
return /*#__PURE__*/React.createElement(DropdownMenuContext.Provider, {
|
|
10249
|
+
value: value
|
|
10250
|
+
}, children);
|
|
10251
|
+
};
|
|
10252
|
+
// Hook to use the DropdownMenu context
|
|
10253
|
+
var useDropdownMenuContext = () => {
|
|
10254
|
+
var context = useContext(DropdownMenuContext);
|
|
10255
|
+
if (!context) {
|
|
10256
|
+
throw new Error('useDropdownMenuContext must be used within a DropdownMenuProvider');
|
|
10257
|
+
}
|
|
10258
|
+
return context;
|
|
10259
|
+
};
|
|
10260
|
+
// DropdownMenu Trigger component
|
|
10261
|
+
var DropdownMenuTrigger = _ref2 => {
|
|
10262
|
+
var {
|
|
10263
|
+
children,
|
|
10264
|
+
views
|
|
10265
|
+
} = _ref2,
|
|
10266
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$G);
|
|
10267
|
+
var {
|
|
10268
|
+
isOpen,
|
|
10269
|
+
setIsOpen
|
|
10270
|
+
} = useDropdownMenuContext();
|
|
10271
|
+
var handleClick = e => {
|
|
10272
|
+
e.stopPropagation();
|
|
10273
|
+
setIsOpen(!isOpen);
|
|
10274
|
+
};
|
|
10275
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10276
|
+
id: "dropdown-trigger",
|
|
10277
|
+
onClick: handleClick,
|
|
10278
|
+
cursor: "pointer",
|
|
10279
|
+
position: "relative",
|
|
10280
|
+
display: "inline-block"
|
|
10281
|
+
}, views == null ? void 0 : views.container, props), children);
|
|
10282
|
+
};
|
|
10283
|
+
// DropdownMenu Content component
|
|
10284
|
+
var DropdownMenuContent = _ref3 => {
|
|
10285
|
+
var {
|
|
10286
|
+
items,
|
|
10287
|
+
side = 'bottom',
|
|
10288
|
+
align = 'start',
|
|
10289
|
+
views
|
|
10290
|
+
} = _ref3,
|
|
10291
|
+
props = _objectWithoutPropertiesLoose(_ref3, _excluded2$9);
|
|
10292
|
+
var {
|
|
10293
|
+
isOpen,
|
|
10294
|
+
//activeSubmenuId, setActiveSubmenuId, size,
|
|
10295
|
+
variant
|
|
10296
|
+
} = useDropdownMenuContext();
|
|
10297
|
+
if (!isOpen) {
|
|
10298
|
+
return null;
|
|
10299
|
+
}
|
|
10300
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10301
|
+
id: "dropdown-menu",
|
|
10302
|
+
position: "absolute",
|
|
10303
|
+
zIndex: 1000,
|
|
10304
|
+
borderRadius: 4,
|
|
10305
|
+
boxShadow: "0px 2px 8px rgba(0, 0, 0, 0.15)",
|
|
10306
|
+
overflow: "hidden"
|
|
10307
|
+
}, getDropdownPosition(side, align), DropdownMenuVariants[variant], views == null ? void 0 : views.menu, props), items.map((item, index) => {
|
|
10308
|
+
if (item.divider) {
|
|
10309
|
+
return /*#__PURE__*/React.createElement(DropdownMenuDivider, {
|
|
10310
|
+
key: "divider-" + index,
|
|
10311
|
+
views: views
|
|
10312
|
+
});
|
|
10313
|
+
}
|
|
10314
|
+
return /*#__PURE__*/React.createElement(DropdownMenuItem, {
|
|
10315
|
+
key: item.id,
|
|
10316
|
+
item: item,
|
|
10317
|
+
views: views
|
|
10318
|
+
});
|
|
10319
|
+
}));
|
|
10320
|
+
};
|
|
10321
|
+
// DropdownMenu Item component
|
|
10322
|
+
var DropdownMenuItem = _ref4 => {
|
|
10323
|
+
var {
|
|
10324
|
+
item,
|
|
10325
|
+
views
|
|
10326
|
+
} = _ref4,
|
|
10327
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded3$6);
|
|
10328
|
+
var {
|
|
10329
|
+
activeSubmenuId,
|
|
10330
|
+
setActiveSubmenuId,
|
|
10331
|
+
size
|
|
10332
|
+
} = useDropdownMenuContext();
|
|
10333
|
+
var [isHovered, setIsHovered] = useState(false);
|
|
10334
|
+
var hasSubmenu = item.items && item.items.length > 0;
|
|
10335
|
+
var isSubmenuActive = activeSubmenuId === item.id;
|
|
10336
|
+
var itemRef = useRef(null);
|
|
10337
|
+
// Handle mouse enter event
|
|
10338
|
+
var handleMouseEnter = () => {
|
|
10339
|
+
setIsHovered(true);
|
|
10340
|
+
if (hasSubmenu) {
|
|
10341
|
+
setActiveSubmenuId(item.id);
|
|
10342
|
+
}
|
|
10343
|
+
};
|
|
10344
|
+
// Handle mouse leave event
|
|
10345
|
+
var handleMouseLeave = () => {
|
|
10346
|
+
setIsHovered(false);
|
|
10347
|
+
};
|
|
10348
|
+
// Handle click event
|
|
10349
|
+
var handleClick = e => {
|
|
10350
|
+
e.stopPropagation();
|
|
10351
|
+
if (item.disabled) return;
|
|
10352
|
+
if (!hasSubmenu && item.onClick) {
|
|
10353
|
+
item.onClick();
|
|
10354
|
+
}
|
|
10355
|
+
};
|
|
10356
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10357
|
+
ref: itemRef,
|
|
10358
|
+
display: "flex",
|
|
10359
|
+
alignItems: "center",
|
|
10360
|
+
cursor: item.disabled ? 'not-allowed' : 'pointer',
|
|
10361
|
+
opacity: item.disabled ? 0.5 : 1,
|
|
10362
|
+
position: "relative"
|
|
10363
|
+
}, DropdownMenuSizes[size], {
|
|
10364
|
+
_hover: !item.disabled ? DropdownMenuItemStates.hover : {},
|
|
10365
|
+
backgroundColor: isHovered && !item.disabled ? 'color.gray.100' : 'transparent',
|
|
10366
|
+
onMouseEnter: handleMouseEnter,
|
|
10367
|
+
onMouseLeave: handleMouseLeave,
|
|
10368
|
+
onClick: handleClick
|
|
10369
|
+
}, views == null ? void 0 : views.item, props), item.icon && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10370
|
+
marginRight: 8
|
|
10371
|
+
}, views == null ? void 0 : views.icon), item.icon)), /*#__PURE__*/React.createElement(View$1, {
|
|
10372
|
+
flexGrow: 1
|
|
10373
|
+
}, item.label), hasSubmenu && (/*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10374
|
+
marginLeft: 8
|
|
10375
|
+
}, views == null ? void 0 : views.submenuIndicator), /*#__PURE__*/React.createElement("svg", {
|
|
10376
|
+
width: "16",
|
|
10377
|
+
height: "16",
|
|
10378
|
+
viewBox: "0 0 24 24",
|
|
10379
|
+
fill: "none",
|
|
10380
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
10381
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
10382
|
+
d: "M8.59 16.59L13.17 12L8.59 7.41L10 6L16 12L10 18L8.59 16.59Z",
|
|
10383
|
+
fill: "currentColor"
|
|
10384
|
+
})))), isSubmenuActive && hasSubmenu && (/*#__PURE__*/React.createElement(DropdownMenuContent, {
|
|
10385
|
+
items: item.items || [],
|
|
10386
|
+
side: "right",
|
|
10387
|
+
align: "start",
|
|
10388
|
+
views: views
|
|
10389
|
+
})));
|
|
10390
|
+
};
|
|
10391
|
+
// DropdownMenu Divider component
|
|
10392
|
+
var DropdownMenuDivider = _ref5 => {
|
|
10393
|
+
var {
|
|
10394
|
+
views
|
|
10395
|
+
} = _ref5,
|
|
10396
|
+
props = _objectWithoutPropertiesLoose(_ref5, _excluded4$5);
|
|
10397
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10398
|
+
height: "1px",
|
|
10399
|
+
backgroundColor: "color.gray.200",
|
|
10400
|
+
margin: "4px 0"
|
|
10401
|
+
}, views == null ? void 0 : views.divider, props));
|
|
10402
|
+
};
|
|
10403
|
+
// Main DropdownMenu View component
|
|
10404
|
+
var DropdownMenuView = _ref6 => {
|
|
10405
|
+
var {
|
|
10406
|
+
trigger,
|
|
10407
|
+
items,
|
|
10408
|
+
side = 'bottom',
|
|
10409
|
+
align = 'start',
|
|
10410
|
+
views
|
|
10411
|
+
} = _ref6,
|
|
10412
|
+
props = _objectWithoutPropertiesLoose(_ref6, _excluded5$3);
|
|
10413
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10414
|
+
position: "relative",
|
|
10415
|
+
display: "inline-block"
|
|
10416
|
+
}, views == null ? void 0 : views.container, props), /*#__PURE__*/React.createElement(DropdownMenuTrigger, {
|
|
10417
|
+
views: views
|
|
10418
|
+
}, trigger), /*#__PURE__*/React.createElement(DropdownMenuContent, {
|
|
10419
|
+
items: items,
|
|
10420
|
+
side: side,
|
|
10421
|
+
align: align,
|
|
10422
|
+
views: views
|
|
10423
|
+
}));
|
|
10424
|
+
};
|
|
10425
|
+
|
|
10426
|
+
var _excluded$H = ["trigger", "items", "size", "variant", "side", "align", "defaultOpen", "views"];
|
|
10427
|
+
/**
|
|
10428
|
+
* DropdownMenu component for displaying a menu when clicking on a trigger element.
|
|
10429
|
+
*/
|
|
10430
|
+
var DropdownMenuComponent = _ref => {
|
|
10431
|
+
var {
|
|
10432
|
+
trigger,
|
|
10433
|
+
items,
|
|
10434
|
+
size = 'md',
|
|
10435
|
+
variant = 'default',
|
|
10436
|
+
side = 'bottom',
|
|
10437
|
+
align = 'start',
|
|
10438
|
+
defaultOpen = false,
|
|
10439
|
+
views
|
|
10440
|
+
} = _ref,
|
|
10441
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$H);
|
|
10442
|
+
var {
|
|
10443
|
+
isOpen,
|
|
10444
|
+
setIsOpen,
|
|
10445
|
+
activeSubmenuId,
|
|
10446
|
+
setActiveSubmenuId
|
|
10447
|
+
} = useDropdownMenuState(defaultOpen);
|
|
10448
|
+
return /*#__PURE__*/React.createElement(DropdownMenuProvider, {
|
|
10449
|
+
value: {
|
|
10450
|
+
isOpen,
|
|
10451
|
+
setIsOpen,
|
|
10452
|
+
activeSubmenuId,
|
|
10453
|
+
setActiveSubmenuId,
|
|
10454
|
+
size,
|
|
10455
|
+
variant
|
|
10456
|
+
}
|
|
10457
|
+
}, /*#__PURE__*/React.createElement(DropdownMenuView, Object.assign({
|
|
10458
|
+
trigger: trigger,
|
|
10459
|
+
items: items,
|
|
10460
|
+
side: side,
|
|
10461
|
+
align: align,
|
|
10462
|
+
views: views
|
|
10463
|
+
}, props)));
|
|
10464
|
+
};
|
|
10465
|
+
var DropdownMenu = DropdownMenuComponent;
|
|
10466
|
+
// Assign the sub-components to the main component
|
|
10467
|
+
DropdownMenu.Trigger = DropdownMenuTrigger;
|
|
10468
|
+
DropdownMenu.Content = DropdownMenuContent;
|
|
10469
|
+
DropdownMenu.Item = DropdownMenuItem;
|
|
10470
|
+
DropdownMenu.Divider = DropdownMenuDivider;
|
|
10471
|
+
|
|
10472
|
+
var useHoverCardState = () => {
|
|
10473
|
+
var [isOpen, setIsOpen] = useState(false);
|
|
10474
|
+
return {
|
|
10475
|
+
isOpen,
|
|
10476
|
+
setIsOpen
|
|
10477
|
+
};
|
|
10478
|
+
};
|
|
10479
|
+
|
|
10480
|
+
var ContentPositions = {
|
|
10481
|
+
top: align => Object.assign({
|
|
10482
|
+
position: 'absolute',
|
|
10483
|
+
bottom: '100%',
|
|
10484
|
+
marginBottom: '8px'
|
|
10485
|
+
}, align === 'start' && {
|
|
10486
|
+
left: 0
|
|
10487
|
+
}, align === 'center' && {
|
|
10488
|
+
left: '50%',
|
|
10489
|
+
transform: 'translateX(-50%)'
|
|
10490
|
+
}, align === 'end' && {
|
|
10491
|
+
right: 0
|
|
10492
|
+
}),
|
|
10493
|
+
right: align => Object.assign({
|
|
10494
|
+
position: 'absolute',
|
|
10495
|
+
left: '100%',
|
|
10496
|
+
marginLeft: '8px'
|
|
10497
|
+
}, align === 'start' && {
|
|
10498
|
+
top: 0
|
|
10499
|
+
}, align === 'center' && {
|
|
10500
|
+
top: '50%',
|
|
10501
|
+
transform: 'translateY(-50%)'
|
|
10502
|
+
}, align === 'end' && {
|
|
10503
|
+
bottom: 0
|
|
10504
|
+
}),
|
|
10505
|
+
bottom: align => Object.assign({
|
|
10506
|
+
position: 'absolute',
|
|
10507
|
+
top: '100%',
|
|
10508
|
+
marginTop: '8px'
|
|
10509
|
+
}, align === 'start' && {
|
|
10510
|
+
left: 0
|
|
10511
|
+
}, align === 'center' && {
|
|
10512
|
+
left: '50%',
|
|
10513
|
+
transform: 'translateX(-50%)'
|
|
10514
|
+
}, align === 'end' && {
|
|
10515
|
+
right: 0
|
|
10516
|
+
}),
|
|
10517
|
+
left: align => Object.assign({
|
|
10518
|
+
position: 'absolute',
|
|
10519
|
+
right: '100%',
|
|
10520
|
+
marginRight: '8px'
|
|
10521
|
+
}, align === 'start' && {
|
|
10522
|
+
top: 0
|
|
10523
|
+
}, align === 'center' && {
|
|
10524
|
+
top: '50%',
|
|
10525
|
+
transform: 'translateY(-50%)'
|
|
10526
|
+
}, align === 'end' && {
|
|
10527
|
+
bottom: 0
|
|
10528
|
+
})
|
|
10529
|
+
};
|
|
10530
|
+
|
|
10531
|
+
var _excluded$I = ["children", "views"],
|
|
10532
|
+
_excluded2$a = ["children", "views", "side", "align"];
|
|
10533
|
+
// Create context for the HoverCard
|
|
10534
|
+
var HoverCardContext = /*#__PURE__*/createContext({
|
|
10535
|
+
isOpen: false,
|
|
10536
|
+
setIsOpen: () => {}
|
|
10537
|
+
});
|
|
10538
|
+
var HoverCardProvider = _ref => {
|
|
10539
|
+
var {
|
|
10540
|
+
children,
|
|
10541
|
+
value
|
|
10542
|
+
} = _ref;
|
|
10543
|
+
return /*#__PURE__*/React.createElement(HoverCardContext.Provider, {
|
|
10544
|
+
value: value
|
|
10545
|
+
}, children);
|
|
10546
|
+
};
|
|
10547
|
+
var useHoverCardContext = () => {
|
|
10548
|
+
var context = useContext(HoverCardContext);
|
|
10549
|
+
if (!context) {
|
|
10550
|
+
throw new Error('useHoverCardContext must be used within a HoverCardProvider');
|
|
10551
|
+
}
|
|
10552
|
+
return context;
|
|
10553
|
+
};
|
|
10554
|
+
var HoverCardTrigger = _ref2 => {
|
|
10555
|
+
var {
|
|
10556
|
+
children,
|
|
10557
|
+
views
|
|
10558
|
+
} = _ref2,
|
|
10559
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$I);
|
|
10560
|
+
var {
|
|
10561
|
+
setIsOpen
|
|
10562
|
+
} = useHoverCardContext();
|
|
10563
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10564
|
+
position: "relative",
|
|
10565
|
+
display: "inline-block",
|
|
10566
|
+
onMouseEnter: () => setIsOpen(true),
|
|
10567
|
+
onMouseLeave: () => setIsOpen(false)
|
|
10568
|
+
}, views == null ? void 0 : views.container, props), children);
|
|
10569
|
+
};
|
|
10570
|
+
var HoverCardContent = _ref3 => {
|
|
10571
|
+
var {
|
|
10572
|
+
children,
|
|
10573
|
+
views,
|
|
10574
|
+
side = 'bottom',
|
|
10575
|
+
align = 'center'
|
|
10576
|
+
} = _ref3,
|
|
10577
|
+
props = _objectWithoutPropertiesLoose(_ref3, _excluded2$a);
|
|
10578
|
+
var {
|
|
10579
|
+
isOpen
|
|
10580
|
+
} = useHoverCardContext();
|
|
10581
|
+
if (!isOpen) {
|
|
10582
|
+
return null;
|
|
10583
|
+
}
|
|
10584
|
+
return /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10585
|
+
backgroundColor: "white",
|
|
10586
|
+
borderRadius: "4px",
|
|
10587
|
+
boxShadow: "0px 2px 8px rgba(0, 0, 0, 0.15)",
|
|
10588
|
+
padding: "12px",
|
|
10589
|
+
minWidth: "200px",
|
|
10590
|
+
maxWidth: "300px",
|
|
10591
|
+
zIndex: 1000
|
|
10592
|
+
}, ContentPositions[side](align), views == null ? void 0 : views.container, props), children);
|
|
10593
|
+
};
|
|
10594
|
+
|
|
10595
|
+
var _excluded$J = ["children", "views"];
|
|
10596
|
+
/**
|
|
10597
|
+
* HoverCard component displays floating content when hovering over a trigger element.
|
|
10598
|
+
*/
|
|
10599
|
+
var HoverCardComponent = _ref => {
|
|
10600
|
+
var {
|
|
10601
|
+
children,
|
|
10602
|
+
views
|
|
10603
|
+
} = _ref,
|
|
10604
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$J);
|
|
10605
|
+
var {
|
|
10606
|
+
isOpen,
|
|
10607
|
+
setIsOpen
|
|
10608
|
+
} = useHoverCardState();
|
|
10609
|
+
return /*#__PURE__*/React.createElement(HoverCardProvider, {
|
|
10610
|
+
value: {
|
|
10611
|
+
isOpen,
|
|
10612
|
+
setIsOpen
|
|
10613
|
+
}
|
|
10614
|
+
}, /*#__PURE__*/React.createElement(View$1, Object.assign({
|
|
10615
|
+
position: "relative",
|
|
10616
|
+
display: "inline-block"
|
|
10617
|
+
}, views == null ? void 0 : views.container, props), children));
|
|
10618
|
+
};
|
|
10619
|
+
var HoverCard = HoverCardComponent;
|
|
10620
|
+
HoverCard.Trigger = HoverCardTrigger;
|
|
10621
|
+
HoverCard.Content = HoverCardContent;
|
|
10622
|
+
|
|
10623
|
+
export { Accordion, Alert, ArrowIcon, AspectRatio, Avatar, Badge, BatteryIcon, BluetoothIcon, BoldArrowIcon, BookmarkIcon, Bottom, Button, CalendarIcon, CameraIcon, Center, CenterBase, Checkbox, ChevronIcon, ClockIcon, CloseEyeIcon, CloseIcon, CloudIcon, ComboBox, ContextMenu, CopyIcon, CountryPicker, CropIcon, DatePicker, DeleteIcon, DownloadIcon, DragAndDrop, DragAndDropComponent, DragHandleIcon, DropdownMenu, DustBinIcon, EditIcon, ErrorIcon, ExternalLinkIcon, FacebookIcon, FileIcon, FileImage, FileSVG, FilterIcon, FormikCheckbox, FormikComboBox, FormikCountryPicker, FormikDatePicker, FormikForm, FormikPassword, FormikSelect, FormikSlider, FormikSwitch, FormikTextArea, FormikTextField, HeartIcon, HelpIcon, HomeIcon, Horizontal, HorizontalBase, HoverCard, Icon, ImageIcon, InfoIcon, Inline, InstagramIcon, Left, LikeIcon, Link, LinkedinIcon, Loader, LocationIcon, LockIcon, MagicWandIcon, MenuIcon, MessageLayout, MessageView, MicrophoneIcon, MinusIcon, Modal, MoonIcon, NavigationMenu, NotificationIcon, OpenEyeIcon, PanelIcon, Password, PauseIcon, PlayIcon, PlusIcon, PrintIcon, ProfileIcon, RefreshIcon, Right, RotateIcon, SaveIcon, SearchIcon, Select, SettingsIcon, ShapeIcon, ShareIcon, Slider, SliderIcon, SliderVerticalIcon, SpinnerIcon, StarIcon, SuccessIcon, Switch, Table, Tabs, Text, TextArea, TextField, TextIcon, ThreadsIcon, TickIcon, Toggle, ToggleGroup, Top, TwitchIcon, TwitterIcon, UnLikeIcon, UnlockIcon, UploadIcon, Uploader, UserIcon, Vertical, VerticalBase, VideoIcon, View, WarningIcon, WifiIcon, XIcon, YoutubeIcon, ZoomInIcon, ZoomOutIcon, hideMessage, hideModal, showMessage, showModal, useMessageStore, useModalStore };
|
|
8472
10624
|
//# sourceMappingURL=web.esm.js.map
|