@vygruppen/spor-react 12.7.1 → 12.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +12 -12
- package/.turbo/turbo-postinstall.log +1 -1
- package/CHANGELOG.md +13 -0
- package/dist/index.cjs +174 -172
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +15 -13
- package/dist/index.d.ts +15 -13
- package/dist/index.mjs +61 -59
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/input/CheckboxGroup.tsx +17 -28
- package/src/input/Combobox.tsx +5 -4
- package/src/input/CountryCodeSelect.tsx +1 -1
- package/src/input/Field.tsx +5 -2
- package/src/input/Select.tsx +3 -2
- package/src/theme/slot-recipes/field.ts +1 -1
- package/src/theme/slot-recipes/select.ts +2 -0
package/dist/index.cjs
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
var react = require('@chakra-ui/react');
|
4
4
|
var sporIconReact = require('@vygruppen/spor-icon-react');
|
5
|
-
var
|
5
|
+
var React27 = require('react');
|
6
6
|
var jsxRuntime = require('react/jsx-runtime');
|
7
7
|
var sporLoader = require('@vygruppen/spor-loader');
|
8
8
|
var ReactLottie = require('lottie-react');
|
@@ -40,7 +40,7 @@ function _interopNamespace(e) {
|
|
40
40
|
return Object.freeze(n);
|
41
41
|
}
|
42
42
|
|
43
|
-
var
|
43
|
+
var React27__namespace = /*#__PURE__*/_interopNamespace(React27);
|
44
44
|
var ReactLottie__default = /*#__PURE__*/_interopDefault(ReactLottie);
|
45
45
|
var tokens23__namespace = /*#__PURE__*/_interopNamespace(tokens23);
|
46
46
|
var tokens4__default = /*#__PURE__*/_interopDefault(tokens4);
|
@@ -76,7 +76,7 @@ var warnAboutMismatchingIcon = ({
|
|
76
76
|
}
|
77
77
|
}
|
78
78
|
};
|
79
|
-
var Accordion =
|
79
|
+
var Accordion = React27.forwardRef(
|
80
80
|
(props, ref) => {
|
81
81
|
const { variant = "core", children, gap = 2, ...rest } = props;
|
82
82
|
const recipe = react.useSlotRecipe({ key: "accordion" });
|
@@ -93,7 +93,7 @@ var Accordion = React28.forwardRef(
|
|
93
93
|
);
|
94
94
|
}
|
95
95
|
);
|
96
|
-
var AccordionItemTrigger =
|
96
|
+
var AccordionItemTrigger = React27.forwardRef(function AccordionItemTrigger2(props, ref) {
|
97
97
|
const {
|
98
98
|
startElement,
|
99
99
|
children,
|
@@ -112,7 +112,7 @@ var AccordionItemTrigger = React28.forwardRef(function AccordionItemTrigger2(pro
|
|
112
112
|
showChevron && /* @__PURE__ */ jsxRuntime.jsx(react.Accordion.ItemIndicator, { children: /* @__PURE__ */ jsxRuntime.jsx(sporIconReact.DropdownDownFill24Icon, {}) })
|
113
113
|
] }) });
|
114
114
|
});
|
115
|
-
var AccordionItemContent =
|
115
|
+
var AccordionItemContent = React27.forwardRef(function AccordionItemContent2(props, ref) {
|
116
116
|
const { children } = props;
|
117
117
|
const recipe = react.useSlotRecipe({ key: "accordion" });
|
118
118
|
const styles = recipe();
|
@@ -120,7 +120,7 @@ var AccordionItemContent = React28.forwardRef(function AccordionItemContent2(pro
|
|
120
120
|
});
|
121
121
|
Accordion.displayName = "Accordion";
|
122
122
|
var AccordionItem = react.Accordion.Item;
|
123
|
-
var Expandable =
|
123
|
+
var Expandable = React27.forwardRef(
|
124
124
|
(props, ref) => {
|
125
125
|
const { title, children, headingLevel, startElement, ...rest } = props;
|
126
126
|
return /* @__PURE__ */ jsxRuntime.jsx(Accordion, { ref, ...rest, children: /* @__PURE__ */ jsxRuntime.jsx(
|
@@ -165,7 +165,7 @@ var Language = /* @__PURE__ */ ((Language3) => {
|
|
165
165
|
Language3["English"] = "en";
|
166
166
|
return Language3;
|
167
167
|
})(Language || {});
|
168
|
-
var LanguageContext =
|
168
|
+
var LanguageContext = React27.createContext(void 0);
|
169
169
|
function LanguageProvider({
|
170
170
|
language,
|
171
171
|
children
|
@@ -173,7 +173,7 @@ function LanguageProvider({
|
|
173
173
|
return /* @__PURE__ */ jsxRuntime.jsx(LanguageContext.Provider, { value: language, children });
|
174
174
|
}
|
175
175
|
function useLanguage() {
|
176
|
-
const language =
|
176
|
+
const language = React27.useContext(LanguageContext);
|
177
177
|
if (!language) {
|
178
178
|
throw new Error("Please wrap your application in a LanguageProvider");
|
179
179
|
}
|
@@ -191,8 +191,8 @@ function createTexts(texts27) {
|
|
191
191
|
}
|
192
192
|
var hydrating = true;
|
193
193
|
function useHydrated() {
|
194
|
-
const [hydrated, setHydrated] =
|
195
|
-
|
194
|
+
const [hydrated, setHydrated] = React27.useState(() => !hydrating);
|
195
|
+
React27.useEffect(function hydrate() {
|
196
196
|
hydrating = false;
|
197
197
|
setHydrated(true);
|
198
198
|
}, []);
|
@@ -335,11 +335,11 @@ var LightSpinner = ({
|
|
335
335
|
] });
|
336
336
|
};
|
337
337
|
var useRotatingLabel = ({ label, delay }) => {
|
338
|
-
const loadingTextArray =
|
338
|
+
const loadingTextArray = React27.useMemo(
|
339
339
|
() => Array.isArray(label) ? label : [label],
|
340
340
|
[label]
|
341
341
|
);
|
342
|
-
const [currentLoadingTextIndex, setCurrentLoadingTextIndex] =
|
342
|
+
const [currentLoadingTextIndex, setCurrentLoadingTextIndex] = React27.useState(0);
|
343
343
|
usehooksTs.useInterval(() => {
|
344
344
|
setCurrentLoadingTextIndex(
|
345
345
|
(prevIndex) => (prevIndex + 1) % loadingTextArray.length
|
@@ -347,7 +347,7 @@ var useRotatingLabel = ({ label, delay }) => {
|
|
347
347
|
}, delay);
|
348
348
|
return loadingTextArray[currentLoadingTextIndex];
|
349
349
|
};
|
350
|
-
var ProgressBar =
|
350
|
+
var ProgressBar = React27.forwardRef(
|
351
351
|
({
|
352
352
|
value,
|
353
353
|
label,
|
@@ -393,9 +393,9 @@ var progressLoaderRecipe = react.defineRecipe({
|
|
393
393
|
}
|
394
394
|
});
|
395
395
|
var usePathLength = (value) => {
|
396
|
-
const pathRef =
|
397
|
-
const [pathLength, setPathLength] =
|
398
|
-
|
396
|
+
const pathRef = React27.useRef(null);
|
397
|
+
const [pathLength, setPathLength] = React27.useState(0);
|
398
|
+
React27.useEffect(() => {
|
399
399
|
if (pathRef.current) {
|
400
400
|
const totalLength = pathRef.current.getTotalLength();
|
401
401
|
setPathLength(totalLength);
|
@@ -405,7 +405,7 @@ var usePathLength = (value) => {
|
|
405
405
|
return { pathRef, pathLength, progressOffset };
|
406
406
|
};
|
407
407
|
var ProgressLoaderWrapper = react.chakra("div", progressLoaderRecipe);
|
408
|
-
var ProgressLoader =
|
408
|
+
var ProgressLoader = React27.forwardRef(
|
409
409
|
({
|
410
410
|
value,
|
411
411
|
label,
|
@@ -429,7 +429,7 @@ var ProgressLoader = React28.forwardRef(
|
|
429
429
|
pathLength: progressPathLength,
|
430
430
|
progressOffset
|
431
431
|
} = usePathLength(value);
|
432
|
-
const id =
|
432
|
+
const id = React27.useId();
|
433
433
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
434
434
|
ProgressLoaderWrapper,
|
435
435
|
{
|
@@ -509,7 +509,7 @@ var texts = createTexts({
|
|
509
509
|
en: `${value}% done`
|
510
510
|
})
|
511
511
|
});
|
512
|
-
var SkeletonCircle =
|
512
|
+
var SkeletonCircle = React27__namespace.forwardRef(function SkeletonCircle2(props, ref) {
|
513
513
|
const recipe = react.useRecipe({ key: "skeleton" });
|
514
514
|
const [recipeProps, restProps] = recipe.splitVariantProps({
|
515
515
|
loading: true,
|
@@ -519,7 +519,7 @@ var SkeletonCircle = React28__namespace.forwardRef(function SkeletonCircle2(prop
|
|
519
519
|
const { size, css, ...rest } = restProps;
|
520
520
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Circle, { size, asChild: true, ref, children: /* @__PURE__ */ jsxRuntime.jsx(react.Skeleton, { css: { ...recipe(recipeProps), ...css }, ...rest }) });
|
521
521
|
});
|
522
|
-
var SkeletonText =
|
522
|
+
var SkeletonText = React27.forwardRef(
|
523
523
|
function SkeletonText2(props, ref) {
|
524
524
|
const recipe = react.useRecipe({ key: "skeleton" });
|
525
525
|
const [recipeProps, restProps] = recipe.splitVariantProps({
|
@@ -540,7 +540,7 @@ var SkeletonText = React28.forwardRef(
|
|
540
540
|
)) });
|
541
541
|
}
|
542
542
|
);
|
543
|
-
var Skeleton =
|
543
|
+
var Skeleton = React27.forwardRef(
|
544
544
|
function SkeletonText3(props, ref) {
|
545
545
|
const recipe = react.useRecipe({ key: "skeleton" });
|
546
546
|
const [recipeProps, restProps] = recipe.splitVariantProps({
|
@@ -578,7 +578,7 @@ var LoadingContent = ({
|
|
578
578
|
loadingText && /* @__PURE__ */ jsxRuntime.jsx(react.Box, { children: loadingText })
|
579
579
|
] })
|
580
580
|
] });
|
581
|
-
var Button =
|
581
|
+
var Button = React27.forwardRef(
|
582
582
|
({
|
583
583
|
loading,
|
584
584
|
disabled,
|
@@ -611,7 +611,7 @@ var Button = React28.forwardRef(
|
|
611
611
|
variant,
|
612
612
|
size,
|
613
613
|
...rest,
|
614
|
-
children: rest.asChild ?
|
614
|
+
children: rest.asChild ? React27.cloneElement(children, {
|
615
615
|
children: renderContent()
|
616
616
|
}) : renderContent()
|
617
617
|
}
|
@@ -627,7 +627,7 @@ var texts2 = createTexts({
|
|
627
627
|
sv: "Laddar\u2026"
|
628
628
|
}
|
629
629
|
});
|
630
|
-
var ButtonGroup =
|
630
|
+
var ButtonGroup = React27.forwardRef(
|
631
631
|
(props, ref) => {
|
632
632
|
const recipe = react.useRecipe({ key: "buttonGroup" });
|
633
633
|
const [recipeProps, restProps] = recipe.splitVariantProps(props);
|
@@ -636,7 +636,7 @@ var ButtonGroup = React28.forwardRef(
|
|
636
636
|
}
|
637
637
|
);
|
638
638
|
ButtonGroup.displayName = "ButtonGroup";
|
639
|
-
var Badge =
|
639
|
+
var Badge = React27.forwardRef(function Badge2({ icon, children, ...props }, ref) {
|
640
640
|
return /* @__PURE__ */ jsxRuntime.jsxs(react.Badge, { ref, ...props, children: [
|
641
641
|
children,
|
642
642
|
icon && /* @__PURE__ */ jsxRuntime.jsx(react.Box, { as: icon })
|
@@ -759,12 +759,12 @@ var codeRecipie = react.defineRecipe({
|
|
759
759
|
}
|
760
760
|
});
|
761
761
|
var StyledCode = react.chakra(react.Code, codeRecipie);
|
762
|
-
var Code =
|
762
|
+
var Code = React27__namespace.default.forwardRef(
|
763
763
|
function Code2(props, ref) {
|
764
764
|
return /* @__PURE__ */ jsxRuntime.jsx(StyledCode, { ...props, ref });
|
765
765
|
}
|
766
766
|
);
|
767
|
-
var Heading =
|
767
|
+
var Heading = React27.forwardRef(
|
768
768
|
function Heading2(props, ref) {
|
769
769
|
const {
|
770
770
|
as,
|
@@ -792,14 +792,14 @@ function resolveTextProps({
|
|
792
792
|
return { fontSize };
|
793
793
|
return { fontSize, lineHeight };
|
794
794
|
}
|
795
|
-
var Text3 =
|
795
|
+
var Text3 = React27.forwardRef(
|
796
796
|
function Text4(props, ref) {
|
797
797
|
const { variant, lineHeight, fontSize, ...rest } = props;
|
798
798
|
const resolvedProps = resolveTextProps({ variant, fontSize, lineHeight });
|
799
799
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Text, { ...resolvedProps, ...rest, ref });
|
800
800
|
}
|
801
801
|
);
|
802
|
-
var ClipboardIcon =
|
802
|
+
var ClipboardIcon = React27__namespace.forwardRef((props, ref) => {
|
803
803
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
804
804
|
react.Clipboard.Indicator,
|
805
805
|
{
|
@@ -811,7 +811,7 @@ var ClipboardIcon = React28__namespace.forwardRef((props, ref) => {
|
|
811
811
|
);
|
812
812
|
});
|
813
813
|
ClipboardIcon.displayName = "ClipboardIcon";
|
814
|
-
var ClipboardCopyText =
|
814
|
+
var ClipboardCopyText = React27__namespace.forwardRef((props, ref) => {
|
815
815
|
const { t } = useTranslation();
|
816
816
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
817
817
|
react.Clipboard.Indicator,
|
@@ -824,7 +824,7 @@ var ClipboardCopyText = React28__namespace.forwardRef((props, ref) => {
|
|
824
824
|
);
|
825
825
|
});
|
826
826
|
ClipboardCopyText.displayName = "ClipboardCopyText";
|
827
|
-
var ClipboardButton =
|
827
|
+
var ClipboardButton = React27__namespace.forwardRef((props, ref) => {
|
828
828
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Clipboard.Trigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(Button, { ref, size: "xs", leftIcon: /* @__PURE__ */ jsxRuntime.jsx(ClipboardIcon, {}), ...props, children: /* @__PURE__ */ jsxRuntime.jsx(ClipboardCopyText, {}) }) });
|
829
829
|
});
|
830
830
|
ClipboardButton.displayName = "ClipboardButton";
|
@@ -843,7 +843,7 @@ var texts3 = createTexts({
|
|
843
843
|
sv: "Kopierad"
|
844
844
|
}
|
845
845
|
});
|
846
|
-
var IconButton =
|
846
|
+
var IconButton = React27.forwardRef(
|
847
847
|
(props, ref) => {
|
848
848
|
const { icon, size = "sm", loading = false, ...rest } = props;
|
849
849
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
@@ -860,7 +860,7 @@ var IconButton = React28.forwardRef(
|
|
860
860
|
}
|
861
861
|
);
|
862
862
|
IconButton.displayName = "IconButton";
|
863
|
-
var CloseButton =
|
863
|
+
var CloseButton = React27.forwardRef(
|
864
864
|
({ size = "sm", ...props }, ref) => {
|
865
865
|
const { t } = useTranslation();
|
866
866
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
@@ -902,7 +902,7 @@ var texts4 = createTexts({
|
|
902
902
|
sv: "St\xE4ng"
|
903
903
|
}
|
904
904
|
});
|
905
|
-
var FloatingActionButton =
|
905
|
+
var FloatingActionButton = React27.forwardRef(
|
906
906
|
({
|
907
907
|
children,
|
908
908
|
icon,
|
@@ -911,11 +911,11 @@ var FloatingActionButton = React28.forwardRef(
|
|
911
911
|
placement = "bottom right",
|
912
912
|
...props
|
913
913
|
}, ref) => {
|
914
|
-
const [isTextVisible, setIsTextVisible] =
|
914
|
+
const [isTextVisible, setIsTextVisible] = React27__namespace.default.useState(
|
915
915
|
externalIsTextVisible === void 0 ? false : externalIsTextVisible
|
916
916
|
);
|
917
917
|
const scrollDirection = useScrollDirection();
|
918
|
-
|
918
|
+
React27.useEffect(() => {
|
919
919
|
if (externalIsTextVisible !== void 0) {
|
920
920
|
return;
|
921
921
|
}
|
@@ -925,7 +925,7 @@ var FloatingActionButton = React28.forwardRef(
|
|
925
925
|
);
|
926
926
|
return () => globalThis.clearTimeout(id);
|
927
927
|
}, [scrollDirection, externalIsTextVisible]);
|
928
|
-
|
928
|
+
React27.useEffect(() => {
|
929
929
|
setIsTextVisible(!!externalIsTextVisible);
|
930
930
|
}, [externalIsTextVisible]);
|
931
931
|
const recipe = react.useSlotRecipe({ key: "floatingActionButton" });
|
@@ -952,11 +952,11 @@ var FloatingActionButton = React28.forwardRef(
|
|
952
952
|
);
|
953
953
|
FloatingActionButton.displayName = "FloatingActionButton";
|
954
954
|
var useScrollDirection = () => {
|
955
|
-
const [scrollDirection, setScrollDirection] =
|
956
|
-
const lastScrollPosition =
|
955
|
+
const [scrollDirection, setScrollDirection] = React27__namespace.default.useState(null);
|
956
|
+
const lastScrollPosition = React27__namespace.default.useRef(
|
957
957
|
globalThis.window === void 0 ? 0 : window.scrollY
|
958
958
|
);
|
959
|
-
|
959
|
+
React27__namespace.default.useEffect(() => {
|
960
960
|
const onScroll = () => {
|
961
961
|
const delta = window.scrollY - lastScrollPosition.current;
|
962
962
|
if (delta === 0) {
|
@@ -972,7 +972,7 @@ var useScrollDirection = () => {
|
|
972
972
|
}, [scrollDirection]);
|
973
973
|
return scrollDirection;
|
974
974
|
};
|
975
|
-
var AlertIcon =
|
975
|
+
var AlertIcon = React27.forwardRef(
|
976
976
|
({ variant, customIcon }, ref) => {
|
977
977
|
const { t } = useTranslation();
|
978
978
|
const Icon2 = customIcon ?? getIcon(variant);
|
@@ -1066,7 +1066,7 @@ var texts5 = createTexts({
|
|
1066
1066
|
en: "Service"
|
1067
1067
|
}
|
1068
1068
|
});
|
1069
|
-
var Alert =
|
1069
|
+
var Alert = React27.forwardRef((props, ref) => {
|
1070
1070
|
const {
|
1071
1071
|
title,
|
1072
1072
|
showIndicator = true,
|
@@ -1113,7 +1113,7 @@ var Alert = React28.forwardRef((props, ref) => {
|
|
1113
1113
|
] });
|
1114
1114
|
});
|
1115
1115
|
Alert.displayName = "Alert";
|
1116
|
-
var ExpandableAlert =
|
1116
|
+
var ExpandableAlert = React27.forwardRef(
|
1117
1117
|
(props, ref) => {
|
1118
1118
|
const {
|
1119
1119
|
variant = "info",
|
@@ -1174,7 +1174,7 @@ var ExpandableAlert = React28.forwardRef(
|
|
1174
1174
|
}
|
1175
1175
|
);
|
1176
1176
|
ExpandableAlert.displayName = "ExpandableAlert";
|
1177
|
-
var ServiceAlert =
|
1177
|
+
var ServiceAlert = React27.forwardRef(
|
1178
1178
|
(props, ref) => {
|
1179
1179
|
const {
|
1180
1180
|
variant = "service",
|
@@ -1276,14 +1276,14 @@ var texts6 = createTexts({
|
|
1276
1276
|
en: "Traffic announcement"
|
1277
1277
|
}
|
1278
1278
|
});
|
1279
|
-
var Breadcrumb =
|
1279
|
+
var Breadcrumb = React27.forwardRef(
|
1280
1280
|
({ children, ...props }, ref) => {
|
1281
|
-
const validChildren =
|
1282
|
-
(element) =>
|
1281
|
+
const validChildren = React27__namespace.default.Children.toArray(children).filter(
|
1282
|
+
(element) => React27__namespace.default.isValidElement(element)
|
1283
1283
|
);
|
1284
1284
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Breadcrumb.Root, { ref, ...props, children: /* @__PURE__ */ jsxRuntime.jsx(react.Breadcrumb.List, { children: validChildren.map((child, index) => {
|
1285
1285
|
const isLast = index === validChildren.length - 1;
|
1286
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
1286
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(React27__namespace.default.Fragment, { children: [
|
1287
1287
|
/* @__PURE__ */ jsxRuntime.jsx(react.Breadcrumb.Item, { children: child }),
|
1288
1288
|
!isLast && /* @__PURE__ */ jsxRuntime.jsx(react.Breadcrumb.Separator, { "aria-hidden": "true", children: /* @__PURE__ */ jsxRuntime.jsx(sporIconReact.DropdownRightFill18Icon, {}) })
|
1289
1289
|
] }, index);
|
@@ -1313,7 +1313,7 @@ function ColorModeIcon() {
|
|
1313
1313
|
const { colorMode } = useColorMode();
|
1314
1314
|
return colorMode === "dark" ? /* @__PURE__ */ jsxRuntime.jsx(lu.LuMoon, {}) : /* @__PURE__ */ jsxRuntime.jsx(lu.LuSun, {});
|
1315
1315
|
}
|
1316
|
-
var ColorModeButton =
|
1316
|
+
var ColorModeButton = React27__namespace.forwardRef(function ColorModeButton2(props, ref) {
|
1317
1317
|
const { toggleColorMode } = useColorMode();
|
1318
1318
|
return /* @__PURE__ */ jsxRuntime.jsx(react.ClientOnly, { fallback: /* @__PURE__ */ jsxRuntime.jsx(react.Skeleton, { boxSize: "8" }), children: /* @__PURE__ */ jsxRuntime.jsx(
|
1319
1319
|
react.IconButton,
|
@@ -1334,7 +1334,7 @@ var ColorModeButton = React28__namespace.forwardRef(function ColorModeButton2(pr
|
|
1334
1334
|
}
|
1335
1335
|
) });
|
1336
1336
|
});
|
1337
|
-
var FloatingLabel =
|
1337
|
+
var FloatingLabel = React27.forwardRef(
|
1338
1338
|
(props, ref) => /* @__PURE__ */ jsxRuntime.jsx(react.Field.Label, { ref, ...props, css: floatingLabelStyles })
|
1339
1339
|
);
|
1340
1340
|
FloatingLabel.displayName = "FloatingLabel";
|
@@ -1377,7 +1377,7 @@ var labelStyles = react.defineStyle({
|
|
1377
1377
|
opacity: 0.4
|
1378
1378
|
}
|
1379
1379
|
});
|
1380
|
-
var Field3 =
|
1380
|
+
var Field3 = React27__namespace.forwardRef(
|
1381
1381
|
(props, ref) => {
|
1382
1382
|
const {
|
1383
1383
|
label,
|
@@ -1394,7 +1394,7 @@ var Field3 = React28__namespace.forwardRef(
|
|
1394
1394
|
} = props;
|
1395
1395
|
const recipe = react.useSlotRecipe({ key: "field" });
|
1396
1396
|
const styles = recipe();
|
1397
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(react.Stack, { gap: "2", ref, ...rest, children: [
|
1397
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(react.Stack, { gap: "2", ref, width: "100%", ...rest, children: [
|
1398
1398
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
1399
1399
|
react.Field.Root,
|
1400
1400
|
{
|
@@ -1417,7 +1417,7 @@ var Field3 = React28__namespace.forwardRef(
|
|
1417
1417
|
}
|
1418
1418
|
);
|
1419
1419
|
Field3.displayName = "Field";
|
1420
|
-
var FieldErrorText =
|
1420
|
+
var FieldErrorText = React27__namespace.forwardRef((props, ref) => {
|
1421
1421
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Field.ErrorText, { ref, children: props.children });
|
1422
1422
|
});
|
1423
1423
|
FieldErrorText.displayName = "FieldErrorText";
|
@@ -1428,7 +1428,7 @@ function CalendarCell({
|
|
1428
1428
|
currentMonth,
|
1429
1429
|
variant
|
1430
1430
|
}) {
|
1431
|
-
const ref =
|
1431
|
+
const ref = React27.useRef(null);
|
1432
1432
|
const {
|
1433
1433
|
cellProps,
|
1434
1434
|
buttonProps,
|
@@ -1455,7 +1455,7 @@ function CalendarCell({
|
|
1455
1455
|
if (isOutsideMonth) {
|
1456
1456
|
stateProps["data-unavailable"] = true;
|
1457
1457
|
}
|
1458
|
-
|
1458
|
+
React27.useEffect(() => {
|
1459
1459
|
var _a5;
|
1460
1460
|
(_a5 = ref.current) == null ? void 0 : _a5.addEventListener(
|
1461
1461
|
"touchend",
|
@@ -1565,7 +1565,7 @@ function CalendarNavigationButton({
|
|
1565
1565
|
"aria-label": ariaLabel,
|
1566
1566
|
...rest
|
1567
1567
|
}) {
|
1568
|
-
const ref =
|
1568
|
+
const ref = React27.useRef(null);
|
1569
1569
|
const { buttonProps } = reactAria.useButton(rest, ref);
|
1570
1570
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
1571
1571
|
IconButton,
|
@@ -1725,7 +1725,7 @@ var texts8 = createTexts({
|
|
1725
1725
|
en: "Calendar"
|
1726
1726
|
}
|
1727
1727
|
});
|
1728
|
-
var CalendarTriggerButton =
|
1728
|
+
var CalendarTriggerButton = React27.forwardRef(({ variant, disabled, ariaLabelledby, ...buttonProps }, ref) => {
|
1729
1729
|
const { t } = useTranslation();
|
1730
1730
|
const recipe = react.useSlotRecipe({
|
1731
1731
|
key: "datePicker"
|
@@ -1752,9 +1752,9 @@ var texts9 = createTexts({
|
|
1752
1752
|
en: "Open calendar"
|
1753
1753
|
}
|
1754
1754
|
});
|
1755
|
-
var DateTimeSegment =
|
1755
|
+
var DateTimeSegment = React27.forwardRef(
|
1756
1756
|
({ segment, state, ariaLabel, ariaDescription }, externalRef) => {
|
1757
|
-
const internalRef =
|
1757
|
+
const internalRef = React27.useRef(null);
|
1758
1758
|
const ref = externalRef ?? internalRef;
|
1759
1759
|
const { segmentProps } = reactAria.useDateSegment(
|
1760
1760
|
segment,
|
@@ -1801,7 +1801,7 @@ function createCalendar2(identifier) {
|
|
1801
1801
|
}
|
1802
1802
|
}
|
1803
1803
|
}
|
1804
|
-
var DateField =
|
1804
|
+
var DateField = React27.forwardRef(
|
1805
1805
|
({ labelId, ...props }, externalRef) => {
|
1806
1806
|
var _a5;
|
1807
1807
|
const locale = useCurrentLocale();
|
@@ -1815,7 +1815,7 @@ var DateField = React28.forwardRef(
|
|
1815
1815
|
createCalendar: createCalendar2
|
1816
1816
|
});
|
1817
1817
|
const { t } = useTranslation();
|
1818
|
-
const internalRef =
|
1818
|
+
const internalRef = React27.useRef(null);
|
1819
1819
|
const ref = externalRef ?? internalRef;
|
1820
1820
|
const { fieldProps } = reactAria.useDateField(
|
1821
1821
|
props,
|
@@ -1892,7 +1892,7 @@ var getAriaLabel = (segmentType) => {
|
|
1892
1892
|
}
|
1893
1893
|
}
|
1894
1894
|
};
|
1895
|
-
var StyledField =
|
1895
|
+
var StyledField = React27.forwardRef(
|
1896
1896
|
function StyledField2(props, ref) {
|
1897
1897
|
const { children, variant, isDisabled, ariaLabelledby, ...otherProps } = props;
|
1898
1898
|
const { invalid } = react.useFieldContext() ?? {
|
@@ -1915,7 +1915,7 @@ var StyledField = React28.forwardRef(
|
|
1915
1915
|
);
|
1916
1916
|
}
|
1917
1917
|
);
|
1918
|
-
var DatePicker =
|
1918
|
+
var DatePicker = React27.forwardRef(
|
1919
1919
|
({
|
1920
1920
|
variant,
|
1921
1921
|
errorText,
|
@@ -1936,15 +1936,15 @@ var DatePicker = React28.forwardRef(
|
|
1936
1936
|
isRequired: props.isRequired ?? (chakraFieldProps == null ? void 0 : chakraFieldProps.required),
|
1937
1937
|
validationState: (chakraFieldProps == null ? void 0 : chakraFieldProps.invalid) ? "invalid" : "valid"
|
1938
1938
|
});
|
1939
|
-
const internalRef =
|
1939
|
+
const internalRef = React27.useRef(null);
|
1940
1940
|
const ref = externalRef ?? internalRef;
|
1941
1941
|
const { labelProps, fieldProps, buttonProps, dialogProps, calendarProps } = reactAria.useDatePicker(
|
1942
1942
|
props,
|
1943
1943
|
state,
|
1944
1944
|
ref
|
1945
1945
|
);
|
1946
|
-
const labelId = `label-${
|
1947
|
-
const inputGroupId = `input-group-${
|
1946
|
+
const labelId = `label-${React27.useId()}`;
|
1947
|
+
const inputGroupId = `input-group-${React27.useId()}`;
|
1948
1948
|
const recipe = react.useSlotRecipe({
|
1949
1949
|
key: "datePicker"
|
1950
1950
|
});
|
@@ -2033,7 +2033,7 @@ function RangeCalendar(props) {
|
|
2033
2033
|
key: "datePicker"
|
2034
2034
|
});
|
2035
2035
|
const styles = recipe({});
|
2036
|
-
const ref =
|
2036
|
+
const ref = React27.useRef(null);
|
2037
2037
|
const { calendarProps, title } = reactAria.useRangeCalendar(props, state, ref);
|
2038
2038
|
return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { ...calendarProps, ref, css: styles.rangeCalendarPopover, children: [
|
2039
2039
|
/* @__PURE__ */ jsxRuntime.jsx(CalendarHeader, { state, title }),
|
@@ -2071,7 +2071,7 @@ function DateRangePicker({
|
|
2071
2071
|
isRequired: props.required ?? (fieldContextPRops == null ? void 0 : fieldContextPRops.required),
|
2072
2072
|
validationState: (fieldContextPRops == null ? void 0 : fieldContextPRops.invalid) ? "invalid" : "valid"
|
2073
2073
|
});
|
2074
|
-
const ref =
|
2074
|
+
const ref = React27.useRef(null);
|
2075
2075
|
const uniqueId = reactAria.useId();
|
2076
2076
|
const datePickerId = `date-range-picker-${uniqueId}`;
|
2077
2077
|
const {
|
@@ -2159,7 +2159,7 @@ function DateRangePicker({
|
|
2159
2159
|
] }) });
|
2160
2160
|
}
|
2161
2161
|
var TimeField = ({ state, ...props }) => {
|
2162
|
-
const ref =
|
2162
|
+
const ref = React27.useRef(null);
|
2163
2163
|
const { labelProps, fieldProps } = reactAria.useTimeField(props, state, ref);
|
2164
2164
|
return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { children: [
|
2165
2165
|
/* @__PURE__ */ jsxRuntime.jsx(
|
@@ -2326,7 +2326,7 @@ var texts11 = createTexts({
|
|
2326
2326
|
sv: "minuter"
|
2327
2327
|
}
|
2328
2328
|
});
|
2329
|
-
var DialogContent =
|
2329
|
+
var DialogContent = React27__namespace.forwardRef((props, ref) => {
|
2330
2330
|
const {
|
2331
2331
|
children,
|
2332
2332
|
portalled = true,
|
@@ -2340,7 +2340,7 @@ var DialogContent = React28__namespace.forwardRef((props, ref) => {
|
|
2340
2340
|
] });
|
2341
2341
|
});
|
2342
2342
|
DialogContent.displayName = "DialogContent";
|
2343
|
-
var DialogCloseTrigger =
|
2343
|
+
var DialogCloseTrigger = React27__namespace.forwardRef(function DialogCloseTrigger2(props, ref) {
|
2344
2344
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Dialog.CloseTrigger, { ref, position: "absolute", ...props, asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { size: "md" }) });
|
2345
2345
|
});
|
2346
2346
|
var DialogRoot = react.Dialog.Root;
|
@@ -2355,7 +2355,7 @@ var DialogActionTrigger = react.Dialog.ActionTrigger;
|
|
2355
2355
|
var [RootDrawerProvider, useRootDrawerProps] = react.createContext({
|
2356
2356
|
name: "RootDrawerProvider"
|
2357
2357
|
});
|
2358
|
-
var DrawerContent =
|
2358
|
+
var DrawerContent = React27.forwardRef(
|
2359
2359
|
(props, ref) => {
|
2360
2360
|
const { children, portalled = true, portalRef, ...rest } = props;
|
2361
2361
|
const { size, placement } = useRootDrawerProps();
|
@@ -2368,7 +2368,7 @@ var DrawerContent = React28.forwardRef(
|
|
2368
2368
|
}
|
2369
2369
|
);
|
2370
2370
|
DrawerContent.displayName = "DrawerContent";
|
2371
|
-
var CloseDrawerLine =
|
2371
|
+
var CloseDrawerLine = React27.forwardRef((props, ref) => {
|
2372
2372
|
const { t } = useTranslation();
|
2373
2373
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
2374
2374
|
react.Drawer.CloseTrigger,
|
@@ -2395,17 +2395,17 @@ var CloseDrawerLine = React28.forwardRef((props, ref) => {
|
|
2395
2395
|
);
|
2396
2396
|
});
|
2397
2397
|
CloseDrawerLine.displayName = "CloseDrawerLine";
|
2398
|
-
var DrawerCloseTrigger =
|
2398
|
+
var DrawerCloseTrigger = React27.forwardRef(function DrawerCloseTrigger2(props, ref) {
|
2399
2399
|
const { size } = useRootDrawerProps();
|
2400
2400
|
const { t } = useTranslation();
|
2401
2401
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Drawer.CloseTrigger, { ref, ...props, asChild: true, children: size === "full" ? /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "ghost", leftIcon: /* @__PURE__ */ jsxRuntime.jsx(sporIconReact.CloseFill24Icon, {}), children: t(texts12.close) }) : /* @__PURE__ */ jsxRuntime.jsx(CloseButton, { size: "md" }) });
|
2402
2402
|
});
|
2403
|
-
var DrawerBackTrigger =
|
2403
|
+
var DrawerBackTrigger = React27.forwardRef((props, ref) => {
|
2404
2404
|
const { t } = useTranslation();
|
2405
2405
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Drawer.CloseTrigger, { asChild: true, ...props, ref, top: "0", children: /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "ghost", leftIcon: /* @__PURE__ */ jsxRuntime.jsx(sporIconReact.ArrowLeftFill24Icon, {}), children: t(texts12.back) }) });
|
2406
2406
|
});
|
2407
2407
|
DrawerBackTrigger.displayName = "DrawerBackTrigger";
|
2408
|
-
var DrawerFullScreenHeader =
|
2408
|
+
var DrawerFullScreenHeader = React27.forwardRef((props, ref) => {
|
2409
2409
|
const { backTrigger = true, title } = props;
|
2410
2410
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Drawer.Header, { ...props, ref, asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(react.Grid, { templateColumns: "1fr auto 1fr", height: "auto", paddingX: "8", children: [
|
2411
2411
|
/* @__PURE__ */ jsxRuntime.jsx(react.GridItem, { width: "full", alignSelf: "center", children: backTrigger && /* @__PURE__ */ jsxRuntime.jsx(DrawerBackTrigger, {}) }),
|
@@ -2442,7 +2442,7 @@ var texts12 = createTexts({
|
|
2442
2442
|
sv: "St\xE4ng"
|
2443
2443
|
}
|
2444
2444
|
});
|
2445
|
-
var AttachedInputs =
|
2445
|
+
var AttachedInputs = React27.forwardRef(
|
2446
2446
|
(props, ref) => {
|
2447
2447
|
const recipe = react.useRecipe({ key: "attachedInputs" });
|
2448
2448
|
const [recipeProps, restProps] = recipe.splitVariantProps(props);
|
@@ -2454,7 +2454,7 @@ AttachedInputs.displayName = "AttachedInputs";
|
|
2454
2454
|
var CardSelect = ({ size = "md", ...props }) => {
|
2455
2455
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Popover.Root, { size, ...props });
|
2456
2456
|
};
|
2457
|
-
var CardSelectContent =
|
2457
|
+
var CardSelectContent = React27.forwardRef(
|
2458
2458
|
({ children, ...props }, ref) => {
|
2459
2459
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(react.Popover.Positioner, { children: /* @__PURE__ */ jsxRuntime.jsx(react.Popover.Content, { ref, padding: 0, bg: "none", children: /* @__PURE__ */ jsxRuntime.jsx(react.Popover.Body, { ...props, children: /* @__PURE__ */ jsxRuntime.jsx(
|
2460
2460
|
StaticCard,
|
@@ -2475,7 +2475,7 @@ var bgActiveStyleMap = {
|
|
2475
2475
|
ghost: "ghost.surface.active",
|
2476
2476
|
floating: "floating.surface.active"
|
2477
2477
|
};
|
2478
|
-
var CardSelectTrigger =
|
2478
|
+
var CardSelectTrigger = React27.forwardRef(
|
2479
2479
|
({ icon, variant = "core", withChevron = true, size, children, ...props }, ref) => {
|
2480
2480
|
const ChevronIcon = size === "sm" ? sporIconReact.DropdownDownFill18Icon : sporIconReact.DropdownDownFill24Icon;
|
2481
2481
|
const { open } = react.usePopoverContext();
|
@@ -2500,7 +2500,7 @@ var CardSelectTrigger = React28.forwardRef(
|
|
2500
2500
|
}
|
2501
2501
|
);
|
2502
2502
|
CardSelectTrigger.displayName = "CardSelectTrigger";
|
2503
|
-
var Checkbox =
|
2503
|
+
var Checkbox = React27__namespace.forwardRef(
|
2504
2504
|
(props, ref) => {
|
2505
2505
|
const { children, inputProps, rootRef, ...rest } = props;
|
2506
2506
|
return /* @__PURE__ */ jsxRuntime.jsxs(react.Checkbox.Root, { ref: rootRef, ...rest, children: [
|
@@ -2511,14 +2511,12 @@ var Checkbox = React28__namespace.forwardRef(
|
|
2511
2511
|
}
|
2512
2512
|
);
|
2513
2513
|
Checkbox.displayName = "Checkbox";
|
2514
|
-
var CheckboxGroup =
|
2515
|
-
|
2516
|
-
|
2517
|
-
|
2518
|
-
}
|
2519
|
-
);
|
2514
|
+
var CheckboxGroup = (props) => {
|
2515
|
+
const { direction = "row", children, gap = 1, ...rest } = props;
|
2516
|
+
return /* @__PURE__ */ jsxRuntime.jsx(react.CheckboxGroup, { ...rest, children: /* @__PURE__ */ jsxRuntime.jsx(react.Stack, { direction, gap, children }) });
|
2517
|
+
};
|
2520
2518
|
CheckboxGroup.displayName = "CheckboxGroup";
|
2521
|
-
var ChoiceChip =
|
2519
|
+
var ChoiceChip = React27.forwardRef(
|
2522
2520
|
({ children, icon, onCheckedChange, ...rootProps }, ref) => {
|
2523
2521
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
2524
2522
|
react.CheckboxCard.Root,
|
@@ -2540,7 +2538,7 @@ var ChoiceChip = React28.forwardRef(
|
|
2540
2538
|
}
|
2541
2539
|
);
|
2542
2540
|
ChoiceChip.displayName = "ChoiceChip";
|
2543
|
-
var Popover =
|
2541
|
+
var Popover = React27.forwardRef(
|
2544
2542
|
({
|
2545
2543
|
children,
|
2546
2544
|
state,
|
@@ -2554,7 +2552,7 @@ var Popover = React28.forwardRef(
|
|
2554
2552
|
containerPadding = 12
|
2555
2553
|
}, ref) => {
|
2556
2554
|
var _a5;
|
2557
|
-
const internalRef =
|
2555
|
+
const internalRef = React27.useRef(null);
|
2558
2556
|
const popoverRef = ref ?? internalRef;
|
2559
2557
|
const { popoverProps, underlayProps } = reactAria.usePopover(
|
2560
2558
|
{
|
@@ -2598,10 +2596,10 @@ var Combobox = (props) => {
|
|
2598
2596
|
loading,
|
2599
2597
|
leftIcon,
|
2600
2598
|
rightIcon,
|
2601
|
-
borderBottomLeftRadius
|
2602
|
-
borderBottomRightRadius
|
2603
|
-
borderTopLeftRadius
|
2604
|
-
borderTopRightRadius
|
2599
|
+
borderBottomLeftRadius,
|
2600
|
+
borderBottomRightRadius,
|
2601
|
+
borderTopLeftRadius,
|
2602
|
+
borderTopRightRadius,
|
2605
2603
|
marginBottom,
|
2606
2604
|
marginTop,
|
2607
2605
|
marginX,
|
@@ -2621,11 +2619,11 @@ var Combobox = (props) => {
|
|
2621
2619
|
...restProps
|
2622
2620
|
} = props;
|
2623
2621
|
const { contains } = reactAria.useFilter({ sensitivity: "base" });
|
2624
|
-
const fallbackInputRef =
|
2622
|
+
const fallbackInputRef = React27.useRef(null);
|
2625
2623
|
const inputRef = externalInputRef ?? fallbackInputRef;
|
2626
|
-
const listBoxRef =
|
2627
|
-
const popoverRef =
|
2628
|
-
const listboxId = `${
|
2624
|
+
const listBoxRef = React27.useRef(null);
|
2625
|
+
const popoverRef = React27.useRef(null);
|
2626
|
+
const listboxId = `${React27.useId()}-listbox`;
|
2629
2627
|
const inputWidth = useInputWidth(inputRef);
|
2630
2628
|
const state = reactStately.useComboBoxState({
|
2631
2629
|
defaultFilter: contains,
|
@@ -2700,7 +2698,8 @@ var Combobox = (props) => {
|
|
2700
2698
|
}
|
2701
2699
|
}
|
2702
2700
|
) : rightIcon,
|
2703
|
-
placeholder: ""
|
2701
|
+
placeholder: "",
|
2702
|
+
"data-attachable": true
|
2704
2703
|
}
|
2705
2704
|
),
|
2706
2705
|
/* @__PURE__ */ jsxRuntime.jsx("span", { "aria-hidden": "true", "data-trigger": "multiselect" }),
|
@@ -2737,8 +2736,8 @@ var Combobox = (props) => {
|
|
2737
2736
|
};
|
2738
2737
|
Combobox.displayName = "Combobox";
|
2739
2738
|
var useInputWidth = (inputRef) => {
|
2740
|
-
const [inputWidth, setInputWidth] =
|
2741
|
-
|
2739
|
+
const [inputWidth, setInputWidth] = React27.useState("auto");
|
2740
|
+
React27.useEffect(() => {
|
2742
2741
|
const onResize = debounce(() => {
|
2743
2742
|
if (inputRef.current) {
|
2744
2743
|
setInputWidth(`${inputRef.current.offsetWidth}px`);
|
@@ -2769,7 +2768,7 @@ var FieldsetLegend = react.Fieldset.Legend;
|
|
2769
2768
|
var FieldsetContent = react.Fieldset.Content;
|
2770
2769
|
var FieldsetHelperText = react.Fieldset.HelperText;
|
2771
2770
|
var FieldsetErrorText = react.Fieldset.ErrorText;
|
2772
|
-
var Input =
|
2771
|
+
var Input = React27.forwardRef(
|
2773
2772
|
({
|
2774
2773
|
startElement,
|
2775
2774
|
endElement,
|
@@ -2855,7 +2854,7 @@ function ItemDescription({ children }) {
|
|
2855
2854
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Box, { ...descriptionProps, css: styles, fontSize: "xs", children });
|
2856
2855
|
}
|
2857
2856
|
function Option({ item, state }) {
|
2858
|
-
const ref =
|
2857
|
+
const ref = React27.useRef(null);
|
2859
2858
|
const {
|
2860
2859
|
optionProps,
|
2861
2860
|
isSelected,
|
@@ -2880,7 +2879,7 @@ function Option({ item, state }) {
|
|
2880
2879
|
if (isFocusVisible) {
|
2881
2880
|
dataFields["data-focus-visible"] = true;
|
2882
2881
|
}
|
2883
|
-
|
2882
|
+
React27.useEffect(() => {
|
2884
2883
|
var _a5;
|
2885
2884
|
(_a5 = ref == null ? void 0 : ref.current) == null ? void 0 : _a5.addEventListener(
|
2886
2885
|
"touchend",
|
@@ -2892,12 +2891,12 @@ function Option({ item, state }) {
|
|
2892
2891
|
}, []);
|
2893
2892
|
return /* @__PURE__ */ jsxRuntime.jsx(OptionContext.Provider, { value: { labelProps, descriptionProps }, children: /* @__PURE__ */ jsxRuntime.jsx(react.ListItem, { ...optionProps, ...dataFields, ref, css: styles.item, children: item.rendered }) });
|
2894
2893
|
}
|
2895
|
-
var OptionContext =
|
2894
|
+
var OptionContext = React27__namespace.default.createContext({
|
2896
2895
|
labelProps: {},
|
2897
2896
|
descriptionProps: {}
|
2898
2897
|
});
|
2899
2898
|
var useOptionContext = () => {
|
2900
|
-
return
|
2899
|
+
return React27.useContext(OptionContext);
|
2901
2900
|
};
|
2902
2901
|
function ListBoxSection({ section, state }) {
|
2903
2902
|
var _a5, _b4;
|
@@ -2927,7 +2926,7 @@ function ListBoxSection({ section, state }) {
|
|
2927
2926
|
) })
|
2928
2927
|
] }) });
|
2929
2928
|
}
|
2930
|
-
var NativeSelect =
|
2929
|
+
var NativeSelect = React27__namespace.forwardRef(function NativeSelect2(props, ref) {
|
2931
2930
|
const {
|
2932
2931
|
children,
|
2933
2932
|
variant = "core",
|
@@ -2974,7 +2973,7 @@ var NativeSelect = React28__namespace.forwardRef(function NativeSelect2(props, r
|
|
2974
2973
|
}
|
2975
2974
|
);
|
2976
2975
|
});
|
2977
|
-
var NumericStepper =
|
2976
|
+
var NumericStepper = React27__namespace.default.forwardRef((props, ref) => {
|
2978
2977
|
const {
|
2979
2978
|
name: nameProp,
|
2980
2979
|
id: idProp,
|
@@ -2990,7 +2989,7 @@ var NumericStepper = React28__namespace.default.forwardRef((props, ref) => {
|
|
2990
2989
|
ariaLabelContext = { singular: "", plural: "" },
|
2991
2990
|
...rest
|
2992
2991
|
} = props;
|
2993
|
-
const addButtonRef =
|
2992
|
+
const addButtonRef = React27.useRef(null);
|
2994
2993
|
const { t } = useTranslation();
|
2995
2994
|
const recipe = react.useSlotRecipe({ key: "numericStepper" });
|
2996
2995
|
const styles = recipe();
|
@@ -3081,7 +3080,7 @@ var NumericStepper = React28__namespace.default.forwardRef((props, ref) => {
|
|
3081
3080
|
] });
|
3082
3081
|
});
|
3083
3082
|
NumericStepper.displayName = "NumericStepper";
|
3084
|
-
var VerySmallButton =
|
3083
|
+
var VerySmallButton = React27__namespace.default.forwardRef((props, ref) => {
|
3085
3084
|
const recipe = react.useSlotRecipe({ key: "numericStepper" });
|
3086
3085
|
const styles = recipe({ colorPalette: "default" });
|
3087
3086
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
@@ -3164,7 +3163,7 @@ var texts13 = createTexts({
|
|
3164
3163
|
};
|
3165
3164
|
}
|
3166
3165
|
});
|
3167
|
-
var PasswordInput =
|
3166
|
+
var PasswordInput = React27.forwardRef(
|
3168
3167
|
(props, ref) => {
|
3169
3168
|
const {
|
3170
3169
|
defaultVisible,
|
@@ -3209,7 +3208,7 @@ var PasswordInput = React28.forwardRef(
|
|
3209
3208
|
}
|
3210
3209
|
);
|
3211
3210
|
PasswordInput.displayName = "PasswordInput";
|
3212
|
-
var VisibilityTrigger =
|
3211
|
+
var VisibilityTrigger = React27__namespace.default.forwardRef(
|
3213
3212
|
(props, ref) => {
|
3214
3213
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
3215
3214
|
react.Button,
|
@@ -3255,7 +3254,7 @@ var sortedCallingCodes = awesomePhonenumber.getSupportedCallingCodes().sort((a,
|
|
3255
3254
|
var callingCodes = react.createListCollection({
|
3256
3255
|
items: [...prioritizedCountryCodes, ...sortedCallingCodes]
|
3257
3256
|
});
|
3258
|
-
var CountryCodeSelect =
|
3257
|
+
var CountryCodeSelect = React27.forwardRef((props, ref) => {
|
3259
3258
|
const { t } = useTranslation();
|
3260
3259
|
if (props.allowedCountryCodes) {
|
3261
3260
|
callingCodes.items = callingCodes.items.filter(
|
@@ -3274,7 +3273,7 @@ var CountryCodeSelect = React28.forwardRef((props, ref) => {
|
|
3274
3273
|
collection: callingCodes,
|
3275
3274
|
lazyMount: true,
|
3276
3275
|
"aria-label": t(texts15.countryCode),
|
3277
|
-
|
3276
|
+
sideRadiusVariant: "rightSideSquare",
|
3278
3277
|
children: callingCodes.items.map((code) => /* @__PURE__ */ jsxRuntime.jsx(SelectItem, { as: "option", item: code, children: code.label }, code.label))
|
3279
3278
|
}
|
3280
3279
|
);
|
@@ -3288,7 +3287,7 @@ var texts15 = createTexts({
|
|
3288
3287
|
sv: "Landskod"
|
3289
3288
|
}
|
3290
3289
|
});
|
3291
|
-
var PhoneNumberInput =
|
3290
|
+
var PhoneNumberInput = React27.forwardRef((props, ref) => {
|
3292
3291
|
const {
|
3293
3292
|
label: externalLabel,
|
3294
3293
|
value: externalValue,
|
@@ -3386,7 +3385,7 @@ var texts16 = createTexts({
|
|
3386
3385
|
sv: "Landskod"
|
3387
3386
|
}
|
3388
3387
|
});
|
3389
|
-
var Radio =
|
3388
|
+
var Radio = React27.forwardRef((props, ref) => {
|
3390
3389
|
const { children, inputProps, rootRef, ...rest } = props;
|
3391
3390
|
return /* @__PURE__ */ jsxRuntime.jsxs(react.RadioGroup.Item, { ref: rootRef, ...rest, children: [
|
3392
3391
|
/* @__PURE__ */ jsxRuntime.jsx(react.RadioGroup.ItemHiddenInput, { ref, ...inputProps }),
|
@@ -3395,13 +3394,13 @@ var Radio = React28.forwardRef((props, ref) => {
|
|
3395
3394
|
] });
|
3396
3395
|
});
|
3397
3396
|
Radio.displayName = "Radio";
|
3398
|
-
var RadioGroup =
|
3397
|
+
var RadioGroup = React27.forwardRef(
|
3399
3398
|
(props, ref) => {
|
3400
3399
|
return /* @__PURE__ */ jsxRuntime.jsx(react.RadioGroup.Root, { ref, ...props, "aria-labelledby": "" });
|
3401
3400
|
}
|
3402
3401
|
);
|
3403
3402
|
RadioGroup.displayName = "RadioGroup";
|
3404
|
-
var SearchInput =
|
3403
|
+
var SearchInput = React27.forwardRef(
|
3405
3404
|
(props, ref) => {
|
3406
3405
|
const { t } = useTranslation();
|
3407
3406
|
const { variant = "core", onReset, label, value } = props;
|
@@ -3445,7 +3444,7 @@ var texts17 = createTexts({
|
|
3445
3444
|
en: "Reset search field"
|
3446
3445
|
}
|
3447
3446
|
});
|
3448
|
-
var Select =
|
3447
|
+
var Select = React27__namespace.forwardRef(
|
3449
3448
|
(props, ref) => {
|
3450
3449
|
const {
|
3451
3450
|
variant = "core",
|
@@ -3488,7 +3487,7 @@ var SelectLabel = (props) => {
|
|
3488
3487
|
);
|
3489
3488
|
};
|
3490
3489
|
Select.displayName = "Select";
|
3491
|
-
var SelectItem =
|
3490
|
+
var SelectItem = React27__namespace.forwardRef(
|
3492
3491
|
(props, ref) => {
|
3493
3492
|
const { item, children, description, ...rest } = props;
|
3494
3493
|
const recipe = react.useSlotRecipe({ key: "select" });
|
@@ -3503,14 +3502,14 @@ var SelectItem = React28__namespace.forwardRef(
|
|
3503
3502
|
}
|
3504
3503
|
);
|
3505
3504
|
SelectItem.displayName = "SelectItem";
|
3506
|
-
var SelectItemGroup =
|
3505
|
+
var SelectItemGroup = React27__namespace.forwardRef(function SelectItemGroup2(props, ref) {
|
3507
3506
|
const { children, label, ...rest } = props;
|
3508
3507
|
return /* @__PURE__ */ jsxRuntime.jsxs(react.Select.ItemGroup, { ...rest, ref, children: [
|
3509
3508
|
/* @__PURE__ */ jsxRuntime.jsx(react.Select.ItemGroupLabel, { children: label }),
|
3510
3509
|
children
|
3511
3510
|
] });
|
3512
3511
|
});
|
3513
|
-
var SelectTrigger =
|
3512
|
+
var SelectTrigger = React27__namespace.forwardRef(function SelectTrigger2(props, ref) {
|
3514
3513
|
const { children, clearable, ...rest } = props;
|
3515
3514
|
const recipe = react.useSlotRecipe({ key: "select" });
|
3516
3515
|
const styles = recipe();
|
@@ -3522,7 +3521,7 @@ var SelectTrigger = React28__namespace.forwardRef(function SelectTrigger2(props,
|
|
3522
3521
|
] })
|
3523
3522
|
] });
|
3524
3523
|
});
|
3525
|
-
var SelectClearTrigger =
|
3524
|
+
var SelectClearTrigger = React27__namespace.forwardRef(function SelectClearTrigger2(props, ref) {
|
3526
3525
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Select.ClearTrigger, { asChild: true, ...props, ref, children: /* @__PURE__ */ jsxRuntime.jsx(
|
3527
3526
|
CloseButton,
|
3528
3527
|
{
|
@@ -3533,11 +3532,11 @@ var SelectClearTrigger = React28__namespace.forwardRef(function SelectClearTrigg
|
|
3533
3532
|
}
|
3534
3533
|
) });
|
3535
3534
|
});
|
3536
|
-
var SelectContent =
|
3535
|
+
var SelectContent = React27__namespace.forwardRef(function SelectContent2(props, ref) {
|
3537
3536
|
const { portalled = true, portalRef, ...rest } = props;
|
3538
3537
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Portal, { disabled: !portalled, container: portalRef, children: /* @__PURE__ */ jsxRuntime.jsx(react.Select.Positioner, { children: /* @__PURE__ */ jsxRuntime.jsx(react.Select.Content, { ...rest, ref }) }) });
|
3539
3538
|
});
|
3540
|
-
var SelectValueText =
|
3539
|
+
var SelectValueText = React27__namespace.forwardRef(function SelectValueText2(props, ref) {
|
3541
3540
|
const { children, withPlaceholder, placeholder, ...rest } = props;
|
3542
3541
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
3543
3542
|
react.Select.ValueText,
|
@@ -3561,7 +3560,7 @@ var SelectValueText = React28__namespace.forwardRef(function SelectValueText2(pr
|
|
3561
3560
|
});
|
3562
3561
|
var SelectItemText = react.Select.ItemText;
|
3563
3562
|
var SelectRoot = react.Select.Root;
|
3564
|
-
var Switch =
|
3563
|
+
var Switch = React27.forwardRef(
|
3565
3564
|
(props, ref) => {
|
3566
3565
|
const {
|
3567
3566
|
rootRef,
|
@@ -3601,9 +3600,9 @@ var Switch = React28.forwardRef(
|
|
3601
3600
|
);
|
3602
3601
|
Switch.displayName = "Switch";
|
3603
3602
|
var useLabelHeight = (label) => {
|
3604
|
-
const labelRef =
|
3605
|
-
const [labelHeight, setLabelHeight] =
|
3606
|
-
|
3603
|
+
const labelRef = React27.useRef(null);
|
3604
|
+
const [labelHeight, setLabelHeight] = React27.useState(0);
|
3605
|
+
React27.useLayoutEffect(() => {
|
3607
3606
|
const updateLabelHeight = () => {
|
3608
3607
|
if (labelRef.current) {
|
3609
3608
|
setLabelHeight(labelRef.current.offsetHeight);
|
@@ -3623,7 +3622,7 @@ var useLabelHeight = (label) => {
|
|
3623
3622
|
}, [label]);
|
3624
3623
|
return { labelRef, labelHeight };
|
3625
3624
|
};
|
3626
|
-
var Textarea =
|
3625
|
+
var Textarea = React27.forwardRef(
|
3627
3626
|
(props, ref) => {
|
3628
3627
|
const { label, variant = "core", ...fieldProps } = props;
|
3629
3628
|
const recipe = react.useRecipe({ key: "textarea" });
|
@@ -3646,7 +3645,7 @@ var Textarea = React28.forwardRef(
|
|
3646
3645
|
}
|
3647
3646
|
);
|
3648
3647
|
Textarea.displayName = "Textarea";
|
3649
|
-
var PressableCard =
|
3648
|
+
var PressableCard = React27.forwardRef(
|
3650
3649
|
(props, ref) => {
|
3651
3650
|
const recipe = react.useRecipe({ key: "pressableCard" });
|
3652
3651
|
const [recipeProps, restProps] = recipe.splitVariantProps(props);
|
@@ -3655,7 +3654,7 @@ var PressableCard = React28.forwardRef(
|
|
3655
3654
|
}
|
3656
3655
|
);
|
3657
3656
|
PressableCard.displayName = "PressableCard";
|
3658
|
-
var RadioCard =
|
3657
|
+
var RadioCard = React27.forwardRef(
|
3659
3658
|
(props, ref) => {
|
3660
3659
|
const { inputProps, children, value, ariaLabel } = props;
|
3661
3660
|
return /* @__PURE__ */ jsxRuntime.jsxs(react.RadioCard.Item, { ...props, children: [
|
@@ -3672,7 +3671,7 @@ var RadioCard = React28.forwardRef(
|
|
3672
3671
|
}
|
3673
3672
|
);
|
3674
3673
|
RadioCard.displayName = "RadioCard";
|
3675
|
-
var RadioCardGroup =
|
3674
|
+
var RadioCardGroup = React27.forwardRef(
|
3676
3675
|
(props, ref) => {
|
3677
3676
|
const {
|
3678
3677
|
children,
|
@@ -3701,7 +3700,7 @@ var RadioCardGroup = React28.forwardRef(
|
|
3701
3700
|
);
|
3702
3701
|
RadioCardGroup.displayName = "RadioCardGroup";
|
3703
3702
|
var RadioCardLabel = react.RadioCard.Label;
|
3704
|
-
var Separator =
|
3703
|
+
var Separator = React27.forwardRef(
|
3705
3704
|
(props, ref) => {
|
3706
3705
|
const {
|
3707
3706
|
size = "md",
|
@@ -3714,7 +3713,7 @@ var Separator = React28.forwardRef(
|
|
3714
3713
|
}
|
3715
3714
|
);
|
3716
3715
|
Separator.displayName = "Separator";
|
3717
|
-
var StaticCard =
|
3716
|
+
var StaticCard = React27.forwardRef(
|
3718
3717
|
(props, ref) => {
|
3719
3718
|
const recipe = react.useRecipe({ key: "staticCard" });
|
3720
3719
|
const [recipeProps, restProps] = recipe.splitVariantProps(props);
|
@@ -3769,7 +3768,7 @@ var getCorrectIcon = ({ variant, size }) => {
|
|
3769
3768
|
var _a5;
|
3770
3769
|
return ((_a5 = icons[variant]) == null ? void 0 : _a5[size]) ?? react.Box;
|
3771
3770
|
};
|
3772
|
-
var LineIcon =
|
3771
|
+
var LineIcon = React27.forwardRef(
|
3773
3772
|
function LineIcon2({
|
3774
3773
|
variant,
|
3775
3774
|
size = "md",
|
@@ -3844,7 +3843,7 @@ var InfoTag = ({
|
|
3844
3843
|
] })
|
3845
3844
|
] });
|
3846
3845
|
};
|
3847
|
-
var TravelTag =
|
3846
|
+
var TravelTag = React27.forwardRef(
|
3848
3847
|
function TravelTag2({
|
3849
3848
|
variant,
|
3850
3849
|
size = "md",
|
@@ -3924,13 +3923,13 @@ var ExternalIcon = ({
|
|
3924
3923
|
size === "lg" || size === "md" ? /* @__PURE__ */ jsxRuntime.jsx(sporIconReact.LinkOutOutline24Icon, { "aria-hidden": true }) : /* @__PURE__ */ jsxRuntime.jsx(sporIconReact.LinkOutOutline18Icon, { "aria-hidden": true }),
|
3925
3924
|
/* @__PURE__ */ jsxRuntime.jsx(react.VisuallyHidden, { children: label })
|
3926
3925
|
] });
|
3927
|
-
var TextLink =
|
3926
|
+
var TextLink = React27.forwardRef(
|
3928
3927
|
({ children, external, href, ...props }, ref) => {
|
3929
3928
|
const { t } = useTranslation();
|
3930
3929
|
const isExternal = external ?? Boolean((href == null ? void 0 : href.startsWith("http://")) || (href == null ? void 0 : href.startsWith("https://")));
|
3931
3930
|
const externalLabel = t ? t(texts18.externalLink) : texts18.externalLink.en;
|
3932
|
-
if (props.asChild &&
|
3933
|
-
return /* @__PURE__ */ jsxRuntime.jsx(react.Link, { href, ...props, ref, children:
|
3931
|
+
if (props.asChild && React27.isValidElement(children)) {
|
3932
|
+
return /* @__PURE__ */ jsxRuntime.jsx(react.Link, { href, ...props, ref, children: React27.cloneElement(children, {
|
3934
3933
|
...children.props,
|
3935
3934
|
children: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
3936
3935
|
children.props.children,
|
@@ -3956,7 +3955,7 @@ var texts18 = createTexts({
|
|
3956
3955
|
var List = react.List.Root;
|
3957
3956
|
var ListItem2 = react.List.Item;
|
3958
3957
|
var ListIndicator = react.List.Indicator;
|
3959
|
-
var CargonetLogo =
|
3958
|
+
var CargonetLogo = React27.forwardRef(
|
3960
3959
|
(props, ref) => {
|
3961
3960
|
const { colorPalette } = props;
|
3962
3961
|
const mainColor = "#DF8200";
|
@@ -4115,8 +4114,8 @@ var fillRecipe = {
|
|
4115
4114
|
};
|
4116
4115
|
var Path = react.chakra("path", fillRecipe);
|
4117
4116
|
var SVGGroup = react.chakra("g", fillRecipe);
|
4118
|
-
var VyLogo =
|
4119
|
-
const id =
|
4117
|
+
var VyLogo = React27.forwardRef((props, ref) => {
|
4118
|
+
const id = React27.useId();
|
4120
4119
|
return /* @__PURE__ */ jsxRuntime.jsxs(SvgBox, { ref, viewBox: "0 0 107 54", ...props, children: [
|
4121
4120
|
/* @__PURE__ */ jsxRuntime.jsx("title", { children: "Vy logo" }),
|
4122
4121
|
/* @__PURE__ */ jsxRuntime.jsx(
|
@@ -4236,7 +4235,7 @@ var VyLogo = React28.forwardRef((props, ref) => {
|
|
4236
4235
|
] });
|
4237
4236
|
});
|
4238
4237
|
VyLogo.displayName = "VyLogo";
|
4239
|
-
var VyLogoPride =
|
4238
|
+
var VyLogoPride = React27.forwardRef(
|
4240
4239
|
(props, ref) => {
|
4241
4240
|
const pinkColor = "#ED6F99";
|
4242
4241
|
const purpleColor = "#C06CF7";
|
@@ -4247,7 +4246,7 @@ var VyLogoPride = React28.forwardRef(
|
|
4247
4246
|
const redColor = "#EA3323";
|
4248
4247
|
const orangeColor = "#F09436";
|
4249
4248
|
const yellowColor = "#FFFF54";
|
4250
|
-
const id =
|
4249
|
+
const id = React27.useId();
|
4251
4250
|
return (
|
4252
4251
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
4253
4252
|
/* @__PURE__ */ jsxRuntime.jsxs(SvgBox, { ref, viewBox: "0 0 107 54", ...props, children: [
|
@@ -4450,7 +4449,7 @@ var VyLogoPride = React28.forwardRef(
|
|
4450
4449
|
}
|
4451
4450
|
);
|
4452
4451
|
VyLogoPride.displayName = "VyLogoPride";
|
4453
|
-
var JumpButton =
|
4452
|
+
var JumpButton = React27.forwardRef(
|
4454
4453
|
(props, ref) => {
|
4455
4454
|
const { direction, disabled, size = "sm" } = props;
|
4456
4455
|
const { t } = useTranslation();
|
@@ -4485,7 +4484,7 @@ var texts19 = createTexts({
|
|
4485
4484
|
en: "15 seconds backward"
|
4486
4485
|
}
|
4487
4486
|
});
|
4488
|
-
var PlayPauseButton =
|
4487
|
+
var PlayPauseButton = React27.forwardRef((props, ref) => {
|
4489
4488
|
const { playing, disabled, size = "sm" } = props;
|
4490
4489
|
const { t } = useTranslation();
|
4491
4490
|
const recipe = react.useSlotRecipe({ key: "mediaControllerButton" });
|
@@ -4518,7 +4517,7 @@ var texts20 = createTexts({
|
|
4518
4517
|
en: "Play"
|
4519
4518
|
}
|
4520
4519
|
});
|
4521
|
-
var SkipButton =
|
4520
|
+
var SkipButton = React27.forwardRef(
|
4522
4521
|
(props, ref) => {
|
4523
4522
|
const { direction, disabled, size = "sm" } = props;
|
4524
4523
|
const { t } = useTranslation();
|
@@ -4574,23 +4573,23 @@ var Nudge = (props) => {
|
|
4574
4573
|
}
|
4575
4574
|
return /* @__PURE__ */ jsxRuntime.jsx(Popover2, { defaultOpen: true, size, ...rest });
|
4576
4575
|
};
|
4577
|
-
var NudgeTrigger =
|
4576
|
+
var NudgeTrigger = React27.forwardRef(({ ...props }, ref) => {
|
4578
4577
|
return /* @__PURE__ */ jsxRuntime.jsx(PopoverTrigger, { ...props, ref });
|
4579
4578
|
});
|
4580
4579
|
NudgeTrigger.displayName = "NudgeTrigger";
|
4581
|
-
var NudgeContent =
|
4580
|
+
var NudgeContent = React27.forwardRef(
|
4582
4581
|
({ showCloseButton = true, children, ...props }, ref) => {
|
4583
|
-
const [currentStep, setCurrentStep] =
|
4584
|
-
const childrenArray =
|
4582
|
+
const [currentStep, setCurrentStep] = React27.useState(1);
|
4583
|
+
const childrenArray = React27__namespace.default.Children.toArray(children);
|
4585
4584
|
const { open } = react.usePopoverContext();
|
4586
|
-
|
4585
|
+
React27.useEffect(() => {
|
4587
4586
|
setCurrentStep(1);
|
4588
4587
|
}, [children, open]);
|
4589
4588
|
const wizardPages = childrenArray.filter(
|
4590
|
-
(child) =>
|
4589
|
+
(child) => React27__namespace.default.isValidElement(child) && child.type.displayName === "NudgeWizardStep"
|
4591
4590
|
);
|
4592
4591
|
const restChildren = childrenArray.filter(
|
4593
|
-
(child) => !
|
4592
|
+
(child) => !React27__namespace.default.isValidElement(child) || child.type.displayName !== "NudgeWizardStep"
|
4594
4593
|
);
|
4595
4594
|
const totalSteps = wizardPages.length;
|
4596
4595
|
const isLastStep = totalSteps === currentStep;
|
@@ -4671,7 +4670,7 @@ var NudgeWizardStep = ({ children }) => {
|
|
4671
4670
|
return /* @__PURE__ */ jsxRuntime.jsx(react.chakra.div, { display: "flex", flexDirection: "column", gap: "1rem", width: "100%", children });
|
4672
4671
|
};
|
4673
4672
|
NudgeWizardStep.displayName = "NudgeWizardStep";
|
4674
|
-
var NudgeCloseTrigger =
|
4673
|
+
var NudgeCloseTrigger = React27.forwardRef(({ children, ...props }, ref) => {
|
4675
4674
|
const isStringChild = typeof children === "string";
|
4676
4675
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Popover.CloseTrigger, { ...props, ref, asChild: !isStringChild, children });
|
4677
4676
|
});
|
@@ -4679,7 +4678,7 @@ NudgeCloseTrigger.displayName = "NudgeCloseTrigger";
|
|
4679
4678
|
var [RootPropsProvider, useRootProps] = react.createContext({
|
4680
4679
|
name: "RootPropsProvider"
|
4681
4680
|
});
|
4682
|
-
var Pagination =
|
4681
|
+
var Pagination = React27__namespace.forwardRef(
|
4683
4682
|
(props, ref) => {
|
4684
4683
|
const { getHref, children, ...rest } = props;
|
4685
4684
|
const recipe = react.useSlotRecipe({ key: "pagination" });
|
@@ -4704,11 +4703,11 @@ var Pagination = React28__namespace.forwardRef(
|
|
4704
4703
|
}
|
4705
4704
|
);
|
4706
4705
|
Pagination.displayName = "Pagination";
|
4707
|
-
var PaginationEllipsis =
|
4706
|
+
var PaginationEllipsis = React27__namespace.forwardRef((props, ref) => {
|
4708
4707
|
return /* @__PURE__ */ jsxRuntime.jsx(ListItem2, { children: /* @__PURE__ */ jsxRuntime.jsx(react.Pagination.Ellipsis, { ref, ...props, asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(react.Box, { cursor: "default", children: "..." }) }) });
|
4709
4708
|
});
|
4710
4709
|
PaginationEllipsis.displayName = "PaginationEllipsis";
|
4711
|
-
var PaginationItem =
|
4710
|
+
var PaginationItem = React27__namespace.forwardRef((props, ref) => {
|
4712
4711
|
const rootProps = useRootProps();
|
4713
4712
|
const { t } = useTranslation();
|
4714
4713
|
const { page, totalPages } = react.usePaginationContext();
|
@@ -4741,7 +4740,7 @@ var PaginationItem = React28__namespace.forwardRef((props, ref) => {
|
|
4741
4740
|
) });
|
4742
4741
|
});
|
4743
4742
|
PaginationItem.displayName = "PaginationItem";
|
4744
|
-
var PaginationPrevTrigger =
|
4743
|
+
var PaginationPrevTrigger = React27__namespace.forwardRef((props, ref) => {
|
4745
4744
|
const { page } = react.usePaginationContext();
|
4746
4745
|
const recipe = react.useSlotRecipe({ key: "pagination" });
|
4747
4746
|
const styles = recipe();
|
@@ -4781,7 +4780,7 @@ var PaginationPrevTrigger = React28__namespace.forwardRef((props, ref) => {
|
|
4781
4780
|
) });
|
4782
4781
|
});
|
4783
4782
|
PaginationPrevTrigger.displayName = "PaginationPrevTrigger";
|
4784
|
-
var PaginationNextTrigger =
|
4783
|
+
var PaginationNextTrigger = React27__namespace.forwardRef((props, ref) => {
|
4785
4784
|
const { page, totalPages } = react.usePaginationContext();
|
4786
4785
|
const recipe = react.useSlotRecipe({ key: "pagination" });
|
4787
4786
|
const styles = recipe();
|
@@ -4861,17 +4860,17 @@ var texts23 = createTexts({
|
|
4861
4860
|
}
|
4862
4861
|
});
|
4863
4862
|
var Popover2 = react.Popover.Root;
|
4864
|
-
var PopoverTrigger =
|
4863
|
+
var PopoverTrigger = React27.forwardRef(({ children, ...props }, ref) => {
|
4865
4864
|
const isStringChild = typeof children === "string";
|
4866
4865
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Popover.Trigger, { ...props, ref, asChild: !isStringChild, children });
|
4867
4866
|
});
|
4868
4867
|
PopoverTrigger.displayName = "PopoverTrigger";
|
4869
|
-
var PopoverContent =
|
4868
|
+
var PopoverContent = React27.forwardRef(
|
4870
4869
|
({ children, showCloseButton = false, ...props }, ref) => {
|
4871
4870
|
const { colorMode } = useColorMode();
|
4872
|
-
const closeButtonRef =
|
4871
|
+
const closeButtonRef = React27__namespace.default.useRef(null);
|
4873
4872
|
const { open } = react.usePopoverContext();
|
4874
|
-
|
4873
|
+
React27.useEffect(() => {
|
4875
4874
|
if (showCloseButton && open && closeButtonRef.current) {
|
4876
4875
|
closeButtonRef.current.focus();
|
4877
4876
|
}
|
@@ -4905,7 +4904,7 @@ var ProgressDot = ({ isActive }) => {
|
|
4905
4904
|
}
|
4906
4905
|
);
|
4907
4906
|
};
|
4908
|
-
var ProgressIndicator =
|
4907
|
+
var ProgressIndicator = React27.forwardRef(({ numberOfSteps, activeStep }, ref) => {
|
4909
4908
|
const { t } = useTranslation();
|
4910
4909
|
const recipe = react.useSlotRecipe({
|
4911
4910
|
key: "progressIndicator"
|
@@ -5080,7 +5079,7 @@ var SporProvider = ({
|
|
5080
5079
|
children
|
5081
5080
|
] }) }) });
|
5082
5081
|
};
|
5083
|
-
var StepperContext =
|
5082
|
+
var StepperContext = React27__namespace.default.createContext(null);
|
5084
5083
|
var StepperProvider = ({
|
5085
5084
|
activeStep,
|
5086
5085
|
children,
|
@@ -5097,7 +5096,7 @@ var StepperProvider = ({
|
|
5097
5096
|
);
|
5098
5097
|
};
|
5099
5098
|
var useStepper = () => {
|
5100
|
-
const context =
|
5099
|
+
const context = React27__namespace.default.useContext(StepperContext);
|
5101
5100
|
if (!context) {
|
5102
5101
|
throw new Error(
|
5103
5102
|
"useStepper must be used within a StepperProvider. Most likely, you forgot to wrap your StepperStep in a Stepper component"
|
@@ -5105,7 +5104,7 @@ var useStepper = () => {
|
|
5105
5104
|
}
|
5106
5105
|
return context;
|
5107
5106
|
};
|
5108
|
-
var Stepper =
|
5107
|
+
var Stepper = React27.forwardRef(
|
5109
5108
|
function Stepper2(props, ref) {
|
5110
5109
|
const {
|
5111
5110
|
onClick = () => {
|
@@ -5253,7 +5252,7 @@ var getState = (stepNumber, activeStep) => {
|
|
5253
5252
|
}
|
5254
5253
|
return "disabled";
|
5255
5254
|
};
|
5256
|
-
var Tabs =
|
5255
|
+
var Tabs = React27.forwardRef((props, ref) => {
|
5257
5256
|
const { variant = "core", size = "sm" } = props;
|
5258
5257
|
return /* @__PURE__ */ jsxRuntime.jsx(react.Tabs.Root, { ...props, ref, variant, size });
|
5259
5258
|
});
|
@@ -5262,7 +5261,7 @@ var TabsList = react.Tabs.List;
|
|
5262
5261
|
var TabsTrigger = react.Tabs.Trigger;
|
5263
5262
|
var TabsIndicator = react.Tabs.Indicator;
|
5264
5263
|
var TabsContent = react.Tabs.Content;
|
5265
|
-
var Table =
|
5264
|
+
var Table = React27.forwardRef((props, ref) => {
|
5266
5265
|
const { variant = "ghost", size, colorPalette = "green", children } = props;
|
5267
5266
|
const recipe = react.useSlotRecipe({ key: "table" });
|
5268
5267
|
const styles = recipe({ variant, size });
|
@@ -7624,7 +7623,8 @@ var fieldSlotRecipe = react.defineSlotRecipe({
|
|
7624
7623
|
textStyle: "xs",
|
7625
7624
|
width: "fit-content",
|
7626
7625
|
position: "absolute",
|
7627
|
-
|
7626
|
+
top: "100%",
|
7627
|
+
// position below parent
|
7628
7628
|
left: 3,
|
7629
7629
|
zIndex: "dropdown",
|
7630
7630
|
maxWidth: "50ch",
|
@@ -9061,7 +9061,9 @@ var selectSlotRecipe = react.defineSlotRecipe({
|
|
9061
9061
|
outline: "1px solid",
|
9062
9062
|
outlineColor: "floating.outline"
|
9063
9063
|
}
|
9064
|
-
}
|
9064
|
+
}
|
9065
|
+
},
|
9066
|
+
sideRadiusVariant: {
|
9065
9067
|
rightSideSquare: {
|
9066
9068
|
control: {
|
9067
9069
|
outline: "1px solid",
|