@northlight/ui 2.36.7 → 2.36.8
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/es/northlight.d.ts +4 -3
- package/dist/es/northlight.js +249 -178
- package/dist/es/northlight.js.map +1 -1
- package/dist/umd/northlight.cjs +247 -175
- package/dist/umd/northlight.cjs.map +1 -1
- package/dist/umd/northlight.min.cjs +3 -3
- package/dist/umd/northlight.min.cjs.map +1 -1
- package/package.json +3 -3
package/dist/es/northlight.js
CHANGED
|
@@ -3,12 +3,12 @@ export { AbsoluteCenter, AccordionIcon, AlertDescription, AlertDialog, AlertDial
|
|
|
3
3
|
import React, { useState, useEffect, useRef, isValidElement, cloneElement, Children, createContext, useContext, forwardRef as forwardRef$1, useImperativeHandle, memo, useMemo, useCallback } from 'react';
|
|
4
4
|
import { CreatableSelect, chakraComponents, AsyncSelect, Select as Select$3 } from 'chakra-react-select';
|
|
5
5
|
export { AsyncCreatableSelect, AsyncSelect, Select as ChakraReactSelect, CreatableSelect, chakraComponents as selectChakraComponents } from 'chakra-react-select';
|
|
6
|
-
import { isNil, last, map, prop, difference, replace, split, path, T, keys, omit, merge, isEmpty, identity, any, ifElse, gt, always,
|
|
6
|
+
import { isNil, last, map, prop, difference, replace, split, path, T, keys, omit, defaultTo, merge, isEmpty, identity, any, ifElse, gt, always, take, inc, dec, forEach, is, trim, values, equals, mergeAll, toLower, find, times, has, not, all, filter, test, indexOf, remove, insert, intersection, findIndex, concat, head, match, length, propEq } from 'ramda';
|
|
7
7
|
import { useFocusManager, FocusScope, useFocusRing } from '@react-aria/focus';
|
|
8
8
|
import { useForm, FormProvider, useFormContext, Controller } from 'react-hook-form';
|
|
9
9
|
export { useController, useFieldArray, useForm, useFormContext, useFormState, useWatch } from 'react-hook-form';
|
|
10
10
|
import { useToken, useMultiStyleConfig as useMultiStyleConfig$1, chakra as chakra$1 } from '@chakra-ui/system';
|
|
11
|
-
import { palette, WebappComponentsTokensSet, WebappSystemTokensSet, typography, TottComponentsTokensSet, TottSystemTokensSet, coreZIndex, coreSizing, coreSpacing, coreFontWeight, coreBoxShadow, coreFontSize, coreLineHeight, coreBorderRadius } from '@northlight/tokens';
|
|
11
|
+
import { palette, WebappComponentsTokensSet, WebappSystemTokensSet, typography, TottComponentsTokensSet, TottSystemTokensSet, CamphouseLightComponentsTokensSet, CamphouseLightSystemTokensSet, coreZIndex, coreSizing, coreSpacing, coreFontWeight, coreBoxShadow, coreFontSize, coreLineHeight, coreBorderRadius } from '@northlight/tokens';
|
|
12
12
|
import { keyframes } from '@emotion/react';
|
|
13
13
|
export { keyframes } from '@emotion/react';
|
|
14
14
|
import { randomColor, cssVar, mode } from '@chakra-ui/theme-tools';
|
|
@@ -45,6 +45,24 @@ import { NumericFormat, numericFormatter } from 'react-number-format';
|
|
|
45
45
|
import InputMask from 'react-input-mask';
|
|
46
46
|
import { uniqBy } from 'yafu';
|
|
47
47
|
|
|
48
|
+
var __defProp$2u = Object.defineProperty;
|
|
49
|
+
var __getOwnPropSymbols$2u = Object.getOwnPropertySymbols;
|
|
50
|
+
var __hasOwnProp$2u = Object.prototype.hasOwnProperty;
|
|
51
|
+
var __propIsEnum$2u = Object.prototype.propertyIsEnumerable;
|
|
52
|
+
var __defNormalProp$2u = (obj, key, value) => key in obj ? __defProp$2u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
53
|
+
var __spreadValues$2u = (a, b) => {
|
|
54
|
+
for (var prop in b || (b = {}))
|
|
55
|
+
if (__hasOwnProp$2u.call(b, prop))
|
|
56
|
+
__defNormalProp$2u(a, prop, b[prop]);
|
|
57
|
+
if (__getOwnPropSymbols$2u)
|
|
58
|
+
for (var prop of __getOwnPropSymbols$2u(b)) {
|
|
59
|
+
if (__propIsEnum$2u.call(b, prop))
|
|
60
|
+
__defNormalProp$2u(a, prop, b[prop]);
|
|
61
|
+
}
|
|
62
|
+
return a;
|
|
63
|
+
};
|
|
64
|
+
const Accordion = (props) => /* @__PURE__ */ React.createElement(Accordion$1, __spreadValues$2u({}, props));
|
|
65
|
+
|
|
48
66
|
var __defProp$2t = Object.defineProperty;
|
|
49
67
|
var __getOwnPropSymbols$2t = Object.getOwnPropertySymbols;
|
|
50
68
|
var __hasOwnProp$2t = Object.prototype.hasOwnProperty;
|
|
@@ -61,7 +79,7 @@ var __spreadValues$2t = (a, b) => {
|
|
|
61
79
|
}
|
|
62
80
|
return a;
|
|
63
81
|
};
|
|
64
|
-
const
|
|
82
|
+
const AccordionButton = (props) => /* @__PURE__ */ React.createElement(AccordionButton$1, __spreadValues$2t({}, props));
|
|
65
83
|
|
|
66
84
|
var __defProp$2s = Object.defineProperty;
|
|
67
85
|
var __getOwnPropSymbols$2s = Object.getOwnPropertySymbols;
|
|
@@ -79,7 +97,7 @@ var __spreadValues$2s = (a, b) => {
|
|
|
79
97
|
}
|
|
80
98
|
return a;
|
|
81
99
|
};
|
|
82
|
-
const
|
|
100
|
+
const AccordionPanel = (props) => /* @__PURE__ */ React.createElement(AccordionPanel$1, __spreadValues$2s({}, props));
|
|
83
101
|
|
|
84
102
|
var __defProp$2r = Object.defineProperty;
|
|
85
103
|
var __getOwnPropSymbols$2r = Object.getOwnPropertySymbols;
|
|
@@ -97,25 +115,7 @@ var __spreadValues$2r = (a, b) => {
|
|
|
97
115
|
}
|
|
98
116
|
return a;
|
|
99
117
|
};
|
|
100
|
-
const
|
|
101
|
-
|
|
102
|
-
var __defProp$2q = Object.defineProperty;
|
|
103
|
-
var __getOwnPropSymbols$2q = Object.getOwnPropertySymbols;
|
|
104
|
-
var __hasOwnProp$2q = Object.prototype.hasOwnProperty;
|
|
105
|
-
var __propIsEnum$2q = Object.prototype.propertyIsEnumerable;
|
|
106
|
-
var __defNormalProp$2q = (obj, key, value) => key in obj ? __defProp$2q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
107
|
-
var __spreadValues$2q = (a, b) => {
|
|
108
|
-
for (var prop in b || (b = {}))
|
|
109
|
-
if (__hasOwnProp$2q.call(b, prop))
|
|
110
|
-
__defNormalProp$2q(a, prop, b[prop]);
|
|
111
|
-
if (__getOwnPropSymbols$2q)
|
|
112
|
-
for (var prop of __getOwnPropSymbols$2q(b)) {
|
|
113
|
-
if (__propIsEnum$2q.call(b, prop))
|
|
114
|
-
__defNormalProp$2q(a, prop, b[prop]);
|
|
115
|
-
}
|
|
116
|
-
return a;
|
|
117
|
-
};
|
|
118
|
-
const AccordionItem = (props) => /* @__PURE__ */ React.createElement(AccordionItem$1, __spreadValues$2q({}, props));
|
|
118
|
+
const AccordionItem = (props) => /* @__PURE__ */ React.createElement(AccordionItem$1, __spreadValues$2r({}, props));
|
|
119
119
|
|
|
120
120
|
const useDebounce = (value, delay) => {
|
|
121
121
|
const [debouncedValue, setDebouncedValue] = useState(value);
|
|
@@ -267,55 +267,65 @@ const useSelectCallbacks = ({
|
|
|
267
267
|
};
|
|
268
268
|
|
|
269
269
|
const isBetween = (point, min, max) => point >= min && point <= max;
|
|
270
|
+
const isEventInsideRect = (ref, event) => {
|
|
271
|
+
let clientX;
|
|
272
|
+
let clientY;
|
|
273
|
+
if (event instanceof MouseEvent) {
|
|
274
|
+
clientX = event.clientX;
|
|
275
|
+
clientY = event.clientY;
|
|
276
|
+
} else if (event instanceof TouchEvent && event.changedTouches[0]) {
|
|
277
|
+
clientX = event.changedTouches[0].clientX;
|
|
278
|
+
clientY = event.changedTouches[0].clientY;
|
|
279
|
+
}
|
|
280
|
+
if (isNil(clientX) || isNil(clientY))
|
|
281
|
+
return true;
|
|
282
|
+
const {
|
|
283
|
+
top,
|
|
284
|
+
right,
|
|
285
|
+
left,
|
|
286
|
+
bottom
|
|
287
|
+
} = ref.current.getBoundingClientRect();
|
|
288
|
+
return isBetween(clientX, left, right) && isBetween(clientY, top, bottom);
|
|
289
|
+
};
|
|
290
|
+
const isHtmlElementRef = (ref) => !isNil(ref.current);
|
|
270
291
|
const useOutsideRectClick = (ref, callback) => {
|
|
271
292
|
const stateRef = useRef({
|
|
272
|
-
|
|
293
|
+
isPointerDownOutsideRect: false,
|
|
273
294
|
ignoreEmulatedMouseEvents: false
|
|
274
295
|
});
|
|
275
296
|
const state = stateRef.current;
|
|
276
297
|
useEffect(() => {
|
|
277
298
|
const handleMouseClick = (event) => {
|
|
278
|
-
|
|
279
|
-
let clientY;
|
|
280
|
-
if (event instanceof MouseEvent) {
|
|
281
|
-
clientX = event.clientX;
|
|
282
|
-
clientY = event.clientY;
|
|
283
|
-
} else if (event instanceof TouchEvent && event.changedTouches[0]) {
|
|
284
|
-
clientX = event.changedTouches[0].clientX;
|
|
285
|
-
clientY = event.changedTouches[0].clientY;
|
|
286
|
-
}
|
|
287
|
-
if (isNil(clientX) || isNil(clientY))
|
|
288
|
-
return;
|
|
289
|
-
if (isNil(ref == null ? void 0 : ref.current))
|
|
299
|
+
if (!isHtmlElementRef(ref)) {
|
|
290
300
|
return;
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
right,
|
|
294
|
-
left,
|
|
295
|
-
bottom
|
|
296
|
-
} = ref.current.getBoundingClientRect();
|
|
297
|
-
const isInBound = isBetween(clientX, left, right) && isBetween(clientY, top, bottom);
|
|
301
|
+
}
|
|
302
|
+
const isInBound = isEventInsideRect(ref, event);
|
|
298
303
|
if (isInBound)
|
|
299
304
|
return;
|
|
300
305
|
callback(event);
|
|
301
306
|
};
|
|
302
|
-
const onPointerDown = () => {
|
|
303
|
-
|
|
307
|
+
const onPointerDown = (event) => {
|
|
308
|
+
if (!isHtmlElementRef(ref)) {
|
|
309
|
+
return;
|
|
310
|
+
}
|
|
311
|
+
if (!isEventInsideRect(ref, event)) {
|
|
312
|
+
state.isPointerDownOutsideRect = true;
|
|
313
|
+
}
|
|
304
314
|
};
|
|
305
315
|
const onMouseUp = (event) => {
|
|
306
316
|
if (state.ignoreEmulatedMouseEvents) {
|
|
307
317
|
state.ignoreEmulatedMouseEvents = false;
|
|
308
318
|
return;
|
|
309
319
|
}
|
|
310
|
-
if (state.
|
|
311
|
-
state.
|
|
320
|
+
if (state.isPointerDownOutsideRect) {
|
|
321
|
+
state.isPointerDownOutsideRect = false;
|
|
312
322
|
handleMouseClick(event);
|
|
313
323
|
}
|
|
314
324
|
};
|
|
315
325
|
const onTouchEnd = (event) => {
|
|
316
326
|
state.ignoreEmulatedMouseEvents = true;
|
|
317
|
-
if (state.
|
|
318
|
-
state.
|
|
327
|
+
if (state.isPointerDownOutsideRect) {
|
|
328
|
+
state.isPointerDownOutsideRect = false;
|
|
319
329
|
handleMouseClick(event);
|
|
320
330
|
}
|
|
321
331
|
};
|
|
@@ -434,6 +444,24 @@ function getFieldError(name, errors) {
|
|
|
434
444
|
return fieldError;
|
|
435
445
|
}
|
|
436
446
|
|
|
447
|
+
var __defProp$2q = Object.defineProperty;
|
|
448
|
+
var __getOwnPropSymbols$2q = Object.getOwnPropertySymbols;
|
|
449
|
+
var __hasOwnProp$2q = Object.prototype.hasOwnProperty;
|
|
450
|
+
var __propIsEnum$2q = Object.prototype.propertyIsEnumerable;
|
|
451
|
+
var __defNormalProp$2q = (obj, key, value) => key in obj ? __defProp$2q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
452
|
+
var __spreadValues$2q = (a, b) => {
|
|
453
|
+
for (var prop in b || (b = {}))
|
|
454
|
+
if (__hasOwnProp$2q.call(b, prop))
|
|
455
|
+
__defNormalProp$2q(a, prop, b[prop]);
|
|
456
|
+
if (__getOwnPropSymbols$2q)
|
|
457
|
+
for (var prop of __getOwnPropSymbols$2q(b)) {
|
|
458
|
+
if (__propIsEnum$2q.call(b, prop))
|
|
459
|
+
__defNormalProp$2q(a, prop, b[prop]);
|
|
460
|
+
}
|
|
461
|
+
return a;
|
|
462
|
+
};
|
|
463
|
+
const passPropsToChild = (child, styles) => isValidElement(child) ? cloneElement(child, __spreadValues$2q({}, styles)) : child;
|
|
464
|
+
|
|
437
465
|
var __defProp$2p = Object.defineProperty;
|
|
438
466
|
var __getOwnPropSymbols$2p = Object.getOwnPropertySymbols;
|
|
439
467
|
var __hasOwnProp$2p = Object.prototype.hasOwnProperty;
|
|
@@ -450,27 +478,9 @@ var __spreadValues$2p = (a, b) => {
|
|
|
450
478
|
}
|
|
451
479
|
return a;
|
|
452
480
|
};
|
|
453
|
-
const passPropsToChild = (child, styles) => isValidElement(child) ? cloneElement(child, __spreadValues$2p({}, styles)) : child;
|
|
454
|
-
|
|
455
|
-
var __defProp$2o = Object.defineProperty;
|
|
456
|
-
var __getOwnPropSymbols$2o = Object.getOwnPropertySymbols;
|
|
457
|
-
var __hasOwnProp$2o = Object.prototype.hasOwnProperty;
|
|
458
|
-
var __propIsEnum$2o = Object.prototype.propertyIsEnumerable;
|
|
459
|
-
var __defNormalProp$2o = (obj, key, value) => key in obj ? __defProp$2o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
460
|
-
var __spreadValues$2o = (a, b) => {
|
|
461
|
-
for (var prop in b || (b = {}))
|
|
462
|
-
if (__hasOwnProp$2o.call(b, prop))
|
|
463
|
-
__defNormalProp$2o(a, prop, b[prop]);
|
|
464
|
-
if (__getOwnPropSymbols$2o)
|
|
465
|
-
for (var prop of __getOwnPropSymbols$2o(b)) {
|
|
466
|
-
if (__propIsEnum$2o.call(b, prop))
|
|
467
|
-
__defNormalProp$2o(a, prop, b[prop]);
|
|
468
|
-
}
|
|
469
|
-
return a;
|
|
470
|
-
};
|
|
471
481
|
const getChildrenWithProps = (children, styles, predicate = T) => {
|
|
472
482
|
const childrenAsArr = Children.toArray(children);
|
|
473
|
-
const childrenWithoutFocus = childrenAsArr.map((child, i) => predicate(child, i) ? passPropsToChild(child, __spreadValues$
|
|
483
|
+
const childrenWithoutFocus = childrenAsArr.map((child, i) => predicate(child, i) ? passPropsToChild(child, __spreadValues$2p({}, styles)) : child);
|
|
474
484
|
return childrenWithoutFocus;
|
|
475
485
|
};
|
|
476
486
|
|
|
@@ -544,80 +554,80 @@ const useResizeWidth = ({
|
|
|
544
554
|
};
|
|
545
555
|
};
|
|
546
556
|
|
|
547
|
-
var __defProp$
|
|
548
|
-
var __defProps$
|
|
549
|
-
var __getOwnPropDescs$
|
|
550
|
-
var __getOwnPropSymbols$
|
|
551
|
-
var __hasOwnProp$
|
|
552
|
-
var __propIsEnum$
|
|
553
|
-
var __defNormalProp$
|
|
554
|
-
var __spreadValues$
|
|
557
|
+
var __defProp$2o = Object.defineProperty;
|
|
558
|
+
var __defProps$y = Object.defineProperties;
|
|
559
|
+
var __getOwnPropDescs$y = Object.getOwnPropertyDescriptors;
|
|
560
|
+
var __getOwnPropSymbols$2o = Object.getOwnPropertySymbols;
|
|
561
|
+
var __hasOwnProp$2o = Object.prototype.hasOwnProperty;
|
|
562
|
+
var __propIsEnum$2o = Object.prototype.propertyIsEnumerable;
|
|
563
|
+
var __defNormalProp$2o = (obj, key, value) => key in obj ? __defProp$2o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
564
|
+
var __spreadValues$2o = (a, b) => {
|
|
555
565
|
for (var prop in b || (b = {}))
|
|
556
|
-
if (__hasOwnProp$
|
|
557
|
-
__defNormalProp$
|
|
558
|
-
if (__getOwnPropSymbols$
|
|
559
|
-
for (var prop of __getOwnPropSymbols$
|
|
560
|
-
if (__propIsEnum$
|
|
561
|
-
__defNormalProp$
|
|
566
|
+
if (__hasOwnProp$2o.call(b, prop))
|
|
567
|
+
__defNormalProp$2o(a, prop, b[prop]);
|
|
568
|
+
if (__getOwnPropSymbols$2o)
|
|
569
|
+
for (var prop of __getOwnPropSymbols$2o(b)) {
|
|
570
|
+
if (__propIsEnum$2o.call(b, prop))
|
|
571
|
+
__defNormalProp$2o(a, prop, b[prop]);
|
|
562
572
|
}
|
|
563
573
|
return a;
|
|
564
574
|
};
|
|
565
|
-
var __spreadProps$
|
|
575
|
+
var __spreadProps$y = (a, b) => __defProps$y(a, __getOwnPropDescs$y(b));
|
|
566
576
|
const customSelectStyles = {
|
|
567
|
-
container: (provided) => __spreadProps$
|
|
577
|
+
container: (provided) => __spreadProps$y(__spreadValues$2o({}, provided), {
|
|
568
578
|
width: "100%",
|
|
569
579
|
color: "text.default"
|
|
570
580
|
}),
|
|
571
|
-
option: (provided, state) => __spreadProps$
|
|
581
|
+
option: (provided, state) => __spreadProps$y(__spreadValues$2o({}, provided), {
|
|
572
582
|
background: state.isFocused && "background.select.option-focus",
|
|
573
583
|
overflowWrap: "anywhere",
|
|
574
584
|
_active: {
|
|
575
585
|
background: "background.select.option-active"
|
|
576
586
|
}
|
|
577
587
|
}),
|
|
578
|
-
valueContainer: (provided) => __spreadProps$
|
|
588
|
+
valueContainer: (provided) => __spreadProps$y(__spreadValues$2o({}, provided), {
|
|
579
589
|
paddingInlineStart: "padding-inline.select.default"
|
|
580
590
|
}),
|
|
581
|
-
downChevron: (provided) => __spreadProps$
|
|
591
|
+
downChevron: (provided) => __spreadProps$y(__spreadValues$2o({}, provided), {
|
|
582
592
|
color: "icon.select.default"
|
|
583
593
|
}),
|
|
584
|
-
placeholder: (provided) => __spreadProps$
|
|
594
|
+
placeholder: (provided) => __spreadProps$y(__spreadValues$2o({}, provided), {
|
|
585
595
|
color: "text.select.placeholder"
|
|
586
596
|
}),
|
|
587
597
|
multiValue: (provided, state) => {
|
|
588
598
|
var _a;
|
|
589
599
|
const background = state.data.isFixed ? "background.select.option-disabled" : (_a = state.data.color) != null ? _a : provided.bgColor;
|
|
590
|
-
return __spreadProps$
|
|
600
|
+
return __spreadProps$y(__spreadValues$2o({}, provided), {
|
|
591
601
|
bgColor: background,
|
|
592
602
|
color: getContrastColor(background)
|
|
593
603
|
});
|
|
594
604
|
},
|
|
595
|
-
menuList: (provided) => __spreadProps$
|
|
605
|
+
menuList: (provided) => __spreadProps$y(__spreadValues$2o({}, provided), {
|
|
596
606
|
bgColor: "background.default"
|
|
597
607
|
})
|
|
598
608
|
};
|
|
599
609
|
|
|
600
|
-
var __defProp$
|
|
601
|
-
var __defProps$
|
|
602
|
-
var __getOwnPropDescs$
|
|
603
|
-
var __getOwnPropSymbols$
|
|
604
|
-
var __hasOwnProp$
|
|
605
|
-
var __propIsEnum$
|
|
606
|
-
var __defNormalProp$
|
|
607
|
-
var __spreadValues$
|
|
610
|
+
var __defProp$2n = Object.defineProperty;
|
|
611
|
+
var __defProps$x = Object.defineProperties;
|
|
612
|
+
var __getOwnPropDescs$x = Object.getOwnPropertyDescriptors;
|
|
613
|
+
var __getOwnPropSymbols$2n = Object.getOwnPropertySymbols;
|
|
614
|
+
var __hasOwnProp$2n = Object.prototype.hasOwnProperty;
|
|
615
|
+
var __propIsEnum$2n = Object.prototype.propertyIsEnumerable;
|
|
616
|
+
var __defNormalProp$2n = (obj, key, value) => key in obj ? __defProp$2n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
617
|
+
var __spreadValues$2n = (a, b) => {
|
|
608
618
|
for (var prop in b || (b = {}))
|
|
609
|
-
if (__hasOwnProp$
|
|
610
|
-
__defNormalProp$
|
|
611
|
-
if (__getOwnPropSymbols$
|
|
612
|
-
for (var prop of __getOwnPropSymbols$
|
|
613
|
-
if (__propIsEnum$
|
|
614
|
-
__defNormalProp$
|
|
619
|
+
if (__hasOwnProp$2n.call(b, prop))
|
|
620
|
+
__defNormalProp$2n(a, prop, b[prop]);
|
|
621
|
+
if (__getOwnPropSymbols$2n)
|
|
622
|
+
for (var prop of __getOwnPropSymbols$2n(b)) {
|
|
623
|
+
if (__propIsEnum$2n.call(b, prop))
|
|
624
|
+
__defNormalProp$2n(a, prop, b[prop]);
|
|
615
625
|
}
|
|
616
626
|
return a;
|
|
617
627
|
};
|
|
618
|
-
var __spreadProps$
|
|
619
|
-
const tagsInputStyles = (isFocused, borderColor) => __spreadProps$
|
|
620
|
-
container: (provided) => __spreadProps$
|
|
628
|
+
var __spreadProps$x = (a, b) => __defProps$x(a, __getOwnPropDescs$x(b));
|
|
629
|
+
const tagsInputStyles = (isFocused, borderColor) => __spreadProps$x(__spreadValues$2n({}, customSelectStyles), {
|
|
630
|
+
container: (provided) => __spreadProps$x(__spreadValues$2n({}, provided), {
|
|
621
631
|
w: "full",
|
|
622
632
|
height: "100%",
|
|
623
633
|
resize: "vertical",
|
|
@@ -630,12 +640,12 @@ const tagsInputStyles = (isFocused, borderColor) => __spreadProps$w(__spreadValu
|
|
|
630
640
|
color: "text.default",
|
|
631
641
|
boxShadow: isFocused ? `0 0 0 1px ${borderColor}` : "none"
|
|
632
642
|
}),
|
|
633
|
-
control: (provided) => __spreadProps$
|
|
643
|
+
control: (provided) => __spreadProps$x(__spreadValues$2n({}, provided), {
|
|
634
644
|
minHeight: "20",
|
|
635
645
|
height: "100%",
|
|
636
646
|
alignItems: "start"
|
|
637
647
|
}),
|
|
638
|
-
valueContainer: (provided) => __spreadProps$
|
|
648
|
+
valueContainer: (provided) => __spreadProps$x(__spreadValues$2n({}, provided), {
|
|
639
649
|
paddingInlineStart: "padding-inline.select.default",
|
|
640
650
|
overflowY: "auto",
|
|
641
651
|
maxH: "100%"
|
|
@@ -1253,7 +1263,9 @@ const PinInput$1 = {
|
|
|
1253
1263
|
},
|
|
1254
1264
|
_focus: {
|
|
1255
1265
|
borderColor: color.border.input.focus,
|
|
1256
|
-
bg: color.background.input["outline-focus"]
|
|
1266
|
+
bg: color.background.input["outline-focus"],
|
|
1267
|
+
boxShadow: "none",
|
|
1268
|
+
borderWidth: borderWidth.sm
|
|
1257
1269
|
},
|
|
1258
1270
|
_invalid: {
|
|
1259
1271
|
bg: color.background.input["outline-error"],
|
|
@@ -1589,6 +1601,21 @@ const Switch$1 = {
|
|
|
1589
1601
|
})
|
|
1590
1602
|
};
|
|
1591
1603
|
|
|
1604
|
+
const themeMap = {
|
|
1605
|
+
camphouseLightTheme: {
|
|
1606
|
+
green: "moss",
|
|
1607
|
+
pink: "rose",
|
|
1608
|
+
orange: "coral",
|
|
1609
|
+
gray: "smoke"
|
|
1610
|
+
},
|
|
1611
|
+
webappTheme: {},
|
|
1612
|
+
tottTheme: {}
|
|
1613
|
+
};
|
|
1614
|
+
const processColorSchemeBasedOnTheme = ({
|
|
1615
|
+
currentTheme,
|
|
1616
|
+
colorScheme
|
|
1617
|
+
}) => defaultTo(colorScheme, themeMap[currentTheme][colorScheme]);
|
|
1618
|
+
|
|
1592
1619
|
const Tag$1 = {
|
|
1593
1620
|
parts: ["container"],
|
|
1594
1621
|
baseStyle: {
|
|
@@ -1614,8 +1641,9 @@ const Tag$1 = {
|
|
|
1614
1641
|
}
|
|
1615
1642
|
},
|
|
1616
1643
|
variants: {
|
|
1617
|
-
solid: ({ theme: { colors }, bgColor, colorScheme }) => {
|
|
1618
|
-
const
|
|
1644
|
+
solid: ({ theme: { colors }, bgColor, colorScheme, currentTheme }) => {
|
|
1645
|
+
const processedColorScheme = processColorSchemeBasedOnTheme({ currentTheme, colorScheme });
|
|
1646
|
+
const tagBgColor = bgColor != null ? bgColor : colors[processedColorScheme] && colors[processedColorScheme][500] ? colors[processedColorScheme][500] : processedColorScheme;
|
|
1619
1647
|
const tagColor = getContrastColor(useToken$1("colors", tagBgColor));
|
|
1620
1648
|
return {
|
|
1621
1649
|
container: {
|
|
@@ -1624,8 +1652,9 @@ const Tag$1 = {
|
|
|
1624
1652
|
}
|
|
1625
1653
|
};
|
|
1626
1654
|
},
|
|
1627
|
-
subtle: ({ theme: { colors }, colorScheme, bgColor }) => {
|
|
1628
|
-
const
|
|
1655
|
+
subtle: ({ theme: { colors }, colorScheme, bgColor, currentTheme }) => {
|
|
1656
|
+
const processedColorScheme = processColorSchemeBasedOnTheme({ currentTheme, colorScheme });
|
|
1657
|
+
const tagBgColor = bgColor != null ? bgColor : colors[processedColorScheme] && colors[processedColorScheme][100] ? colors[processedColorScheme][100] : processedColorScheme;
|
|
1629
1658
|
const tagColor = getContrastColor(useToken$1("colors", tagBgColor));
|
|
1630
1659
|
return {
|
|
1631
1660
|
container: {
|
|
@@ -1910,19 +1939,19 @@ const NotificationIconButton$1 = {
|
|
|
1910
1939
|
})
|
|
1911
1940
|
};
|
|
1912
1941
|
|
|
1913
|
-
var __defProp$
|
|
1914
|
-
var __getOwnPropSymbols$
|
|
1915
|
-
var __hasOwnProp$
|
|
1916
|
-
var __propIsEnum$
|
|
1917
|
-
var __defNormalProp$
|
|
1918
|
-
var __spreadValues$
|
|
1942
|
+
var __defProp$2m = Object.defineProperty;
|
|
1943
|
+
var __getOwnPropSymbols$2m = Object.getOwnPropertySymbols;
|
|
1944
|
+
var __hasOwnProp$2m = Object.prototype.hasOwnProperty;
|
|
1945
|
+
var __propIsEnum$2m = Object.prototype.propertyIsEnumerable;
|
|
1946
|
+
var __defNormalProp$2m = (obj, key, value) => key in obj ? __defProp$2m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
1947
|
+
var __spreadValues$2m = (a, b) => {
|
|
1919
1948
|
for (var prop in b || (b = {}))
|
|
1920
|
-
if (__hasOwnProp$
|
|
1921
|
-
__defNormalProp$
|
|
1922
|
-
if (__getOwnPropSymbols$
|
|
1923
|
-
for (var prop of __getOwnPropSymbols$
|
|
1924
|
-
if (__propIsEnum$
|
|
1925
|
-
__defNormalProp$
|
|
1949
|
+
if (__hasOwnProp$2m.call(b, prop))
|
|
1950
|
+
__defNormalProp$2m(a, prop, b[prop]);
|
|
1951
|
+
if (__getOwnPropSymbols$2m)
|
|
1952
|
+
for (var prop of __getOwnPropSymbols$2m(b)) {
|
|
1953
|
+
if (__propIsEnum$2m.call(b, prop))
|
|
1954
|
+
__defNormalProp$2m(a, prop, b[prop]);
|
|
1926
1955
|
}
|
|
1927
1956
|
return a;
|
|
1928
1957
|
};
|
|
@@ -1947,7 +1976,7 @@ const Calendar$1 = {
|
|
|
1947
1976
|
bgColor: "background.default",
|
|
1948
1977
|
borderRadius: "input.outline"
|
|
1949
1978
|
},
|
|
1950
|
-
dateSelect: __spreadValues$
|
|
1979
|
+
dateSelect: __spreadValues$2m({
|
|
1951
1980
|
fontWeight: "semibold",
|
|
1952
1981
|
border: "none",
|
|
1953
1982
|
padding: "1",
|
|
@@ -3296,19 +3325,19 @@ const Toolbox$1 = {
|
|
|
3296
3325
|
}
|
|
3297
3326
|
};
|
|
3298
3327
|
|
|
3299
|
-
var __defProp$
|
|
3300
|
-
var __getOwnPropSymbols$
|
|
3301
|
-
var __hasOwnProp$
|
|
3302
|
-
var __propIsEnum$
|
|
3303
|
-
var __defNormalProp$
|
|
3304
|
-
var __spreadValues$
|
|
3328
|
+
var __defProp$2l = Object.defineProperty;
|
|
3329
|
+
var __getOwnPropSymbols$2l = Object.getOwnPropertySymbols;
|
|
3330
|
+
var __hasOwnProp$2l = Object.prototype.hasOwnProperty;
|
|
3331
|
+
var __propIsEnum$2l = Object.prototype.propertyIsEnumerable;
|
|
3332
|
+
var __defNormalProp$2l = (obj, key, value) => key in obj ? __defProp$2l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3333
|
+
var __spreadValues$2l = (a, b) => {
|
|
3305
3334
|
for (var prop in b || (b = {}))
|
|
3306
|
-
if (__hasOwnProp$
|
|
3307
|
-
__defNormalProp$
|
|
3308
|
-
if (__getOwnPropSymbols$
|
|
3309
|
-
for (var prop of __getOwnPropSymbols$
|
|
3310
|
-
if (__propIsEnum$
|
|
3311
|
-
__defNormalProp$
|
|
3335
|
+
if (__hasOwnProp$2l.call(b, prop))
|
|
3336
|
+
__defNormalProp$2l(a, prop, b[prop]);
|
|
3337
|
+
if (__getOwnPropSymbols$2l)
|
|
3338
|
+
for (var prop of __getOwnPropSymbols$2l(b)) {
|
|
3339
|
+
if (__propIsEnum$2l.call(b, prop))
|
|
3340
|
+
__defNormalProp$2l(a, prop, b[prop]);
|
|
3312
3341
|
}
|
|
3313
3342
|
return a;
|
|
3314
3343
|
};
|
|
@@ -3364,7 +3393,7 @@ const getAiColorStyles = (isInvalid, isImage = true) => ({
|
|
|
3364
3393
|
const FilePicker$1 = {
|
|
3365
3394
|
parts: ["filePicker", "fileItem", "multiFilePicker"],
|
|
3366
3395
|
baseStyle: ({ theme: { sizes, colors }, hasLoaded, isImage, isInvalid, currentTheme, sx }) => ({
|
|
3367
|
-
filePicker: merge(__spreadValues$
|
|
3396
|
+
filePicker: merge(__spreadValues$2l(__spreadValues$2l({
|
|
3368
3397
|
display: "flex",
|
|
3369
3398
|
flexDirection: "column",
|
|
3370
3399
|
alignItems: "center",
|
|
@@ -3377,7 +3406,7 @@ const FilePicker$1 = {
|
|
|
3377
3406
|
borderStyle: "dashed",
|
|
3378
3407
|
borderRadius: "lg"
|
|
3379
3408
|
}, getInvalidColorStyles(isInvalid, isImage, currentTheme)), thickRing), sx),
|
|
3380
|
-
multiFilePicker: __spreadValues$
|
|
3409
|
+
multiFilePicker: __spreadValues$2l(__spreadValues$2l({
|
|
3381
3410
|
width: "full",
|
|
3382
3411
|
maxWidth: "inherit",
|
|
3383
3412
|
height: "32",
|
|
@@ -3402,8 +3431,8 @@ const FilePicker$1 = {
|
|
|
3402
3431
|
}),
|
|
3403
3432
|
variants: {
|
|
3404
3433
|
ai: ({ isInvalid }) => ({
|
|
3405
|
-
filePicker: __spreadValues$
|
|
3406
|
-
multiFilePicker: __spreadValues$
|
|
3434
|
+
filePicker: __spreadValues$2l({}, getAiColorStyles(isInvalid)),
|
|
3435
|
+
multiFilePicker: __spreadValues$2l({}, getAiColorStyles(isInvalid))
|
|
3407
3436
|
})
|
|
3408
3437
|
}
|
|
3409
3438
|
};
|
|
@@ -3534,31 +3563,35 @@ const Menu$1 = {
|
|
|
3534
3563
|
};
|
|
3535
3564
|
|
|
3536
3565
|
const Badge$1 = {
|
|
3537
|
-
baseStyle: ({ colorScheme, theme: { colors } }) => {
|
|
3538
|
-
const
|
|
3539
|
-
const
|
|
3566
|
+
baseStyle: ({ colorScheme, theme: { colors }, currentTheme }) => {
|
|
3567
|
+
const processedColorScheme = processColorSchemeBasedOnTheme({ currentTheme, colorScheme });
|
|
3568
|
+
const bgColor = processedColorScheme === "mediatoolBlue" ? colors[processedColorScheme][100] : colors[processedColorScheme] && colors[processedColorScheme][100];
|
|
3569
|
+
const textColor = processedColorScheme === "mediatoolBlue" ? colors[processedColorScheme][800] : colors[processedColorScheme] && colors[processedColorScheme][800];
|
|
3540
3570
|
return {
|
|
3541
3571
|
bgColor,
|
|
3542
3572
|
color: textColor
|
|
3543
3573
|
};
|
|
3544
3574
|
},
|
|
3545
3575
|
variants: {
|
|
3546
|
-
solid: ({ colorScheme, theme: { colors } }) => {
|
|
3547
|
-
const
|
|
3576
|
+
solid: ({ colorScheme, theme: { colors }, currentTheme }) => {
|
|
3577
|
+
const processedColorScheme = processColorSchemeBasedOnTheme({ currentTheme, colorScheme });
|
|
3578
|
+
const bgColor = processedColorScheme === "mediatoolBlue" ? colors[processedColorScheme][500] : colors[processedColorScheme] && colors[processedColorScheme][500];
|
|
3548
3579
|
return {
|
|
3549
3580
|
bgColor,
|
|
3550
|
-
color: getContrastColor(bgColor != null ? bgColor : useToken$1("colors",
|
|
3581
|
+
color: getContrastColor(bgColor != null ? bgColor : useToken$1("colors", processedColorScheme))
|
|
3551
3582
|
};
|
|
3552
3583
|
},
|
|
3553
|
-
outline: ({ colorScheme, theme: { colors } }) => {
|
|
3554
|
-
const
|
|
3584
|
+
outline: ({ colorScheme, theme: { colors }, currentTheme }) => {
|
|
3585
|
+
const processedColorScheme = processColorSchemeBasedOnTheme({ currentTheme, colorScheme });
|
|
3586
|
+
const textColor = processedColorScheme === "mediatoolBlue" ? colors[processedColorScheme][500] : colors[processedColorScheme] && colors[processedColorScheme][700];
|
|
3555
3587
|
return {
|
|
3556
3588
|
bgColor: "mono.transparent",
|
|
3557
3589
|
color: textColor
|
|
3558
3590
|
};
|
|
3559
3591
|
},
|
|
3560
|
-
ghost: ({ colorScheme, theme: { colors } }) => {
|
|
3561
|
-
const
|
|
3592
|
+
ghost: ({ colorScheme, theme: { colors }, currentTheme }) => {
|
|
3593
|
+
const processedColorScheme = processColorSchemeBasedOnTheme({ currentTheme, colorScheme });
|
|
3594
|
+
const textColor = processedColorScheme === "mediatoolBlue" ? colors[processedColorScheme][500] : colors[processedColorScheme] && colors[processedColorScheme][700];
|
|
3562
3595
|
return {
|
|
3563
3596
|
bgColor: "mono.transparent",
|
|
3564
3597
|
color: textColor
|
|
@@ -3663,6 +3696,39 @@ var components = /*#__PURE__*/Object.freeze({
|
|
|
3663
3696
|
Tooltip: Tooltip$1
|
|
3664
3697
|
});
|
|
3665
3698
|
|
|
3699
|
+
var __defProp$2k = Object.defineProperty;
|
|
3700
|
+
var __defProps$w = Object.defineProperties;
|
|
3701
|
+
var __getOwnPropDescs$w = Object.getOwnPropertyDescriptors;
|
|
3702
|
+
var __getOwnPropSymbols$2k = Object.getOwnPropertySymbols;
|
|
3703
|
+
var __hasOwnProp$2k = Object.prototype.hasOwnProperty;
|
|
3704
|
+
var __propIsEnum$2k = Object.prototype.propertyIsEnumerable;
|
|
3705
|
+
var __defNormalProp$2k = (obj, key, value) => key in obj ? __defProp$2k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
3706
|
+
var __spreadValues$2k = (a, b) => {
|
|
3707
|
+
for (var prop in b || (b = {}))
|
|
3708
|
+
if (__hasOwnProp$2k.call(b, prop))
|
|
3709
|
+
__defNormalProp$2k(a, prop, b[prop]);
|
|
3710
|
+
if (__getOwnPropSymbols$2k)
|
|
3711
|
+
for (var prop of __getOwnPropSymbols$2k(b)) {
|
|
3712
|
+
if (__propIsEnum$2k.call(b, prop))
|
|
3713
|
+
__defNormalProp$2k(a, prop, b[prop]);
|
|
3714
|
+
}
|
|
3715
|
+
return a;
|
|
3716
|
+
};
|
|
3717
|
+
var __spreadProps$w = (a, b) => __defProps$w(a, __getOwnPropDescs$w(b));
|
|
3718
|
+
const WebappSkin = {
|
|
3719
|
+
colors: __spreadProps$w(__spreadValues$2k(__spreadValues$2k({}, WebappSystemTokensSet.st.color), WebappComponentsTokensSet.color), {
|
|
3720
|
+
text: __spreadValues$2k(__spreadValues$2k({}, WebappSystemTokensSet.st.color.text), WebappComponentsTokensSet.color.text),
|
|
3721
|
+
border: __spreadValues$2k(__spreadValues$2k({}, WebappSystemTokensSet.st.color.border), WebappComponentsTokensSet.color.border)
|
|
3722
|
+
}),
|
|
3723
|
+
sizes: WebappComponentsTokensSet.sizing,
|
|
3724
|
+
space: WebappComponentsTokensSet.spacing,
|
|
3725
|
+
radii: __spreadValues$2k(__spreadValues$2k({}, WebappSystemTokensSet.st.borderRadius), WebappComponentsTokensSet.borderRadius),
|
|
3726
|
+
borders: __spreadValues$2k(__spreadValues$2k({}, WebappSystemTokensSet.st.borderWidth), WebappComponentsTokensSet.borderWidth),
|
|
3727
|
+
opacity: WebappComponentsTokensSet.opacity,
|
|
3728
|
+
typography,
|
|
3729
|
+
shadows: __spreadValues$2k({}, WebappSystemTokensSet.st.boxShadow)
|
|
3730
|
+
};
|
|
3731
|
+
|
|
3666
3732
|
var __defProp$2j = Object.defineProperty;
|
|
3667
3733
|
var __defProps$v = Object.defineProperties;
|
|
3668
3734
|
var __getOwnPropDescs$v = Object.getOwnPropertyDescriptors;
|
|
@@ -3682,18 +3748,17 @@ var __spreadValues$2j = (a, b) => {
|
|
|
3682
3748
|
return a;
|
|
3683
3749
|
};
|
|
3684
3750
|
var __spreadProps$v = (a, b) => __defProps$v(a, __getOwnPropDescs$v(b));
|
|
3685
|
-
const
|
|
3686
|
-
colors: __spreadProps$v(__spreadValues$2j(__spreadValues$2j({},
|
|
3687
|
-
|
|
3688
|
-
border: __spreadValues$2j(__spreadValues$2j({}, WebappSystemTokensSet.st.color.border), WebappComponentsTokensSet.color.border)
|
|
3751
|
+
const TottSkin = {
|
|
3752
|
+
colors: __spreadProps$v(__spreadValues$2j(__spreadValues$2j({}, TottSystemTokensSet.st.color), TottComponentsTokensSet.color), {
|
|
3753
|
+
border: __spreadValues$2j(__spreadValues$2j({}, TottSystemTokensSet.st.color.border), TottComponentsTokensSet.color.border)
|
|
3689
3754
|
}),
|
|
3690
|
-
sizes:
|
|
3691
|
-
space:
|
|
3692
|
-
radii: __spreadValues$2j(__spreadValues$2j({},
|
|
3693
|
-
borders: __spreadValues$2j(__spreadValues$2j({},
|
|
3694
|
-
opacity:
|
|
3755
|
+
sizes: TottComponentsTokensSet.sizing,
|
|
3756
|
+
space: TottComponentsTokensSet.spacing,
|
|
3757
|
+
radii: __spreadValues$2j(__spreadValues$2j({}, TottSystemTokensSet.st.borderRadius), TottComponentsTokensSet.borderRadius),
|
|
3758
|
+
borders: __spreadValues$2j(__spreadValues$2j({}, TottSystemTokensSet.st.borderWidth), TottComponentsTokensSet.borderWidth),
|
|
3759
|
+
opacity: TottComponentsTokensSet.opacity,
|
|
3695
3760
|
typography,
|
|
3696
|
-
shadows: __spreadValues$2j({},
|
|
3761
|
+
shadows: __spreadValues$2j({}, TottSystemTokensSet.st.boxShadow)
|
|
3697
3762
|
};
|
|
3698
3763
|
|
|
3699
3764
|
var __defProp$2i = Object.defineProperty;
|
|
@@ -3715,17 +3780,18 @@ var __spreadValues$2i = (a, b) => {
|
|
|
3715
3780
|
return a;
|
|
3716
3781
|
};
|
|
3717
3782
|
var __spreadProps$u = (a, b) => __defProps$u(a, __getOwnPropDescs$u(b));
|
|
3718
|
-
const
|
|
3719
|
-
colors: __spreadProps$u(__spreadValues$2i(__spreadValues$2i({},
|
|
3720
|
-
|
|
3783
|
+
const CamphouseLightSkin = {
|
|
3784
|
+
colors: __spreadProps$u(__spreadValues$2i(__spreadValues$2i({}, CamphouseLightSystemTokensSet.st.color), CamphouseLightComponentsTokensSet.color), {
|
|
3785
|
+
text: __spreadValues$2i(__spreadValues$2i({}, CamphouseLightSystemTokensSet.st.color.text), CamphouseLightComponentsTokensSet.color.text),
|
|
3786
|
+
border: __spreadValues$2i(__spreadValues$2i({}, CamphouseLightSystemTokensSet.st.color.border), CamphouseLightComponentsTokensSet.color.border)
|
|
3721
3787
|
}),
|
|
3722
|
-
sizes:
|
|
3723
|
-
space:
|
|
3724
|
-
radii: __spreadValues$2i(__spreadValues$2i({},
|
|
3725
|
-
borders: __spreadValues$2i(__spreadValues$2i({},
|
|
3726
|
-
opacity:
|
|
3788
|
+
sizes: CamphouseLightComponentsTokensSet.sizing,
|
|
3789
|
+
space: CamphouseLightComponentsTokensSet.spacing,
|
|
3790
|
+
radii: __spreadValues$2i(__spreadValues$2i({}, CamphouseLightSystemTokensSet.st.borderRadius), CamphouseLightComponentsTokensSet.borderRadius),
|
|
3791
|
+
borders: __spreadValues$2i(__spreadValues$2i({}, CamphouseLightSystemTokensSet.st.borderWidth), CamphouseLightComponentsTokensSet.borderWidth),
|
|
3792
|
+
opacity: CamphouseLightComponentsTokensSet.opacity,
|
|
3727
3793
|
typography,
|
|
3728
|
-
shadows: __spreadValues$2i({},
|
|
3794
|
+
shadows: __spreadValues$2i({}, CamphouseLightSystemTokensSet.st.boxShadow)
|
|
3729
3795
|
};
|
|
3730
3796
|
|
|
3731
3797
|
var __defProp$2h = Object.defineProperty;
|
|
@@ -3787,6 +3853,7 @@ const overrides = {
|
|
|
3787
3853
|
};
|
|
3788
3854
|
const theme = extendTheme(overrides, WebappSkin);
|
|
3789
3855
|
const tottTheme = extendTheme(overrides, TottSkin);
|
|
3856
|
+
const camphouseLightTheme = extendTheme(overrides, CamphouseLightSkin);
|
|
3790
3857
|
|
|
3791
3858
|
var __defProp$2g = Object.defineProperty;
|
|
3792
3859
|
var __defProps$t = Object.defineProperties;
|
|
@@ -4993,7 +5060,8 @@ const Badge = forwardRef$1((props, ref) => {
|
|
|
4993
5060
|
"iconAs"
|
|
4994
5061
|
]);
|
|
4995
5062
|
const IconComponent = iconAs ? NorthlightIcons[iconAs] : MediatoolLogoSolid;
|
|
4996
|
-
|
|
5063
|
+
const currentTheme = useCurrentTheme();
|
|
5064
|
+
return /* @__PURE__ */ React.createElement(Badge$2, __spreadValues$1X({ ref, currentTheme }, rest), /* @__PURE__ */ React.createElement(Flex, { align: "center", gap: "1" }, withIcon && iconPosition === "left" && IconComponent && /* @__PURE__ */ React.createElement(Icon, { as: IconComponent, boxSize: "3" }), children, withIcon && iconPosition === "right" && IconComponent && /* @__PURE__ */ React.createElement(Icon, { as: IconComponent, boxSize: "3" })));
|
|
4997
5065
|
});
|
|
4998
5066
|
|
|
4999
5067
|
var __defProp$1W = Object.defineProperty;
|
|
@@ -6083,7 +6151,7 @@ var __objRest$1k = (source, exclude) => {
|
|
|
6083
6151
|
}
|
|
6084
6152
|
return target;
|
|
6085
6153
|
};
|
|
6086
|
-
const FlipButton = (props) => {
|
|
6154
|
+
const FlipButton = forwardRef$1((props, wrapperRef) => {
|
|
6087
6155
|
const _a = props, {
|
|
6088
6156
|
children,
|
|
6089
6157
|
size,
|
|
@@ -6146,13 +6214,14 @@ const FlipButton = (props) => {
|
|
|
6146
6214
|
sx: mergeAll([button, isFocused ? focusStyles : {}, { flexDirection: iconPlacement === "left" ? "row" : "row-reverse" }]),
|
|
6147
6215
|
"aria-checked": isSelected,
|
|
6148
6216
|
"aria-disabled": isDisabled,
|
|
6149
|
-
as: "label"
|
|
6217
|
+
as: "label",
|
|
6218
|
+
ref: wrapperRef
|
|
6150
6219
|
},
|
|
6151
6220
|
/* @__PURE__ */ React.createElement("input", __spreadValues$1H({}, flipButtonProps)),
|
|
6152
6221
|
icon && iconPlacement !== "none" ? /* @__PURE__ */ React.createElement(Icon, { as: icon || CheckSolid, sx: buttonIcon }) : isSelected && iconPlacement !== "none" && /* @__PURE__ */ React.createElement(SlideFade$1, { in: isSelected }, /* @__PURE__ */ React.createElement(Icon, { as: icon || CheckSolid, sx: buttonIcon })),
|
|
6153
6222
|
/* @__PURE__ */ React.createElement(Text, { textAlign: "center" }, children)
|
|
6154
6223
|
);
|
|
6155
|
-
};
|
|
6224
|
+
});
|
|
6156
6225
|
|
|
6157
6226
|
var __defProp$1G = Object.defineProperty;
|
|
6158
6227
|
var __defProps$p = Object.defineProperties;
|
|
@@ -9796,13 +9865,15 @@ const Tag = forwardRef$1((_a, ref) => {
|
|
|
9796
9865
|
"bgColor",
|
|
9797
9866
|
"colorScheme"
|
|
9798
9867
|
]);
|
|
9868
|
+
const currentTheme = useCurrentTheme();
|
|
9799
9869
|
return /* @__PURE__ */ React.createElement(
|
|
9800
9870
|
Tag$2,
|
|
9801
9871
|
__spreadValues$$({
|
|
9802
9872
|
bgColor,
|
|
9803
9873
|
colorScheme,
|
|
9804
9874
|
ref,
|
|
9805
|
-
variant
|
|
9875
|
+
variant,
|
|
9876
|
+
currentTheme
|
|
9806
9877
|
}, rest),
|
|
9807
9878
|
children
|
|
9808
9879
|
);
|
|
@@ -14871,5 +14942,5 @@ const ComboPickerField = (_a) => {
|
|
|
14871
14942
|
);
|
|
14872
14943
|
};
|
|
14873
14944
|
|
|
14874
|
-
export { Accordion, AccordionButton, AccordionItem, AccordionPanel, Alert, AspectRatio, AsyncError, Avatar, AvatarGroup, Badge, Blinker, Blockquote, Button, Capitalized, Carousel, Checkbox, CheckboxField, CheckboxGroupField, Clickable, ClipboardInput, Collapse, ColorPicker, ColorPickerField, ComboPicker, ComboPickerField, CreatableSelectDropdown, CustomTheme, DatePicker, DatePickerField, DatePickerLocaleWrapper, DateRangePicker, DateRangePickerField, DragAndDrop, DragHandle, DragItem, Draggable, DropZone, Droppable, EditableText, Fade, FastGrid, FastList, Field, FilePicker, FilePickerField, FlipButton, FlipButtonGroup, FlipButtonGroupField, Form, FormLabel, FormattedNumberInput, FormattedNumberInputField, H1, H2, H3, H4, H5, H6, Icon, IconButton, IntentButton, Label, Lead, LoadingBar, MaskedTextInput, MediatoolThemeProvider, Menu, Modal, ModalBase, ModalBody, MultiFileList, MultiFilePicker, MultiFilePickerField, MultiFileUploader, MultiSort, NotificationIconButton, NumVal, NumberInput, NumberInputField, OrganizationLogo, OverflowGroup, P, PaneDivider, PaneItem, PinInput, Popover, ProgressBar, Radio, RadioGroup, RadioGroupField, ResizeHandle, ScaleFade, SearchBar, SearchBarField, Select, SelectField, Slide, SlideFade, Small, Sortable, SortableContainer, SortableItem, SortableList, Spinner, SplitPane, StatusPin, Step, StepList, StepPanel, StepStack, Steps, Switch, SwitchField, TabPanel, Table, Tabs, Tag, TagGroup, TagsInput, TextField, Textarea, TextareaField, Tiny, Toast, Toolbox, ToolboxContent, ToolboxFooter, ToolboxHeader, Tooltip, addAlpha, advancedParseFloat, clamp, createDebounceFunctionInstance, getChildrenWithProps, getConsistentRandomColorFromString, getContrastColor, getFieldError, getInitials, getMatchingValue, getShades, highlight, luminosity, ring, theme, tottTheme, trimFormValues, useArrowFocus, useCurrentTheme, useDebounce, useDidUpdateEffect, useLoadingMessage, useOutsideRectClick, useOverflowGroup, useResizeWidth, useScreenSize, useScrollToBottom, useSelectCallbacks, useSetValueRefreshed, useToast };
|
|
14945
|
+
export { Accordion, AccordionButton, AccordionItem, AccordionPanel, Alert, AspectRatio, AsyncError, Avatar, AvatarGroup, Badge, Blinker, Blockquote, Button, Capitalized, Carousel, Checkbox, CheckboxField, CheckboxGroupField, Clickable, ClipboardInput, Collapse, ColorPicker, ColorPickerField, ComboPicker, ComboPickerField, CreatableSelectDropdown, CustomTheme, DatePicker, DatePickerField, DatePickerLocaleWrapper, DateRangePicker, DateRangePickerField, DragAndDrop, DragHandle, DragItem, Draggable, DropZone, Droppable, EditableText, Fade, FastGrid, FastList, Field, FilePicker, FilePickerField, FlipButton, FlipButtonGroup, FlipButtonGroupField, Form, FormLabel, FormattedNumberInput, FormattedNumberInputField, H1, H2, H3, H4, H5, H6, Icon, IconButton, IntentButton, Label, Lead, LoadingBar, MaskedTextInput, MediatoolThemeProvider, Menu, Modal, ModalBase, ModalBody, MultiFileList, MultiFilePicker, MultiFilePickerField, MultiFileUploader, MultiSort, NotificationIconButton, NumVal, NumberInput, NumberInputField, OrganizationLogo, OverflowGroup, P, PaneDivider, PaneItem, PinInput, Popover, ProgressBar, Radio, RadioGroup, RadioGroupField, ResizeHandle, ScaleFade, SearchBar, SearchBarField, Select, SelectField, Slide, SlideFade, Small, Sortable, SortableContainer, SortableItem, SortableList, Spinner, SplitPane, StatusPin, Step, StepList, StepPanel, StepStack, Steps, Switch, SwitchField, TabPanel, Table, Tabs, Tag, TagGroup, TagsInput, TextField, Textarea, TextareaField, Tiny, Toast, Toolbox, ToolboxContent, ToolboxFooter, ToolboxHeader, Tooltip, addAlpha, advancedParseFloat, camphouseLightTheme, clamp, createDebounceFunctionInstance, getChildrenWithProps, getConsistentRandomColorFromString, getContrastColor, getFieldError, getInitials, getMatchingValue, getShades, highlight, luminosity, ring, theme, tottTheme, trimFormValues, useArrowFocus, useCurrentTheme, useDebounce, useDidUpdateEffect, useLoadingMessage, useOutsideRectClick, useOverflowGroup, useResizeWidth, useScreenSize, useScrollToBottom, useSelectCallbacks, useSetValueRefreshed, useToast };
|
|
14875
14946
|
//# sourceMappingURL=northlight.js.map
|