@vygruppen/spor-react 9.2.1 → 9.4.0
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 +10 -10
- package/CHANGELOG.md +24 -0
- package/dist/{CountryCodeSelect-FR7IFLQR.mjs → CountryCodeSelect-5QKP6VFT.mjs} +1 -1
- package/dist/{chunk-EVOFJL5T.mjs → chunk-JRXSGTL2.mjs} +611 -435
- package/dist/index.d.mts +143 -64
- package/dist/index.d.ts +143 -64
- package/dist/index.js +690 -491
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/src/alert/AlertIcon.tsx +1 -1
- package/src/card/StaticCard.tsx +25 -0
- package/src/card/index.tsx +1 -0
- package/src/input/CardSelect.tsx +15 -1
- package/src/input/Combobox.tsx +52 -38
- package/src/modal/FullScreenDrawer.tsx +179 -0
- package/src/modal/index.tsx +1 -0
- package/src/theme/components/button.ts +1 -1
- package/src/theme/components/choice-chip.ts +0 -2
- package/src/theme/components/datepicker.ts +2 -1
- package/src/theme/components/index.ts +1 -0
- package/src/theme/components/input.ts +1 -1
- package/src/theme/components/numeric-stepper.ts +1 -1
- package/src/theme/components/select.ts +1 -3
- package/src/theme/components/static-card.ts +66 -0
- package/src/theme/components/switch.ts +2 -2
- package/src/theme/utils/base-utils.ts +1 -1
@@ -1,10 +1,10 @@
|
|
1
|
-
import
|
2
|
-
import * as
|
3
|
-
export {
|
4
|
-
import { forwardRef, Divider as Divider$1, Stack as Stack$1, Accordion as Accordion$1, Skeleton as Skeleton$1, useButtonGroup, useStyleConfig, Box, Center, Flex, ButtonGroup as ButtonGroup$1, IconButton as IconButton$1, useMultiStyleConfig, chakra, Badge as Badge$1, Code as Code$1, Text, PopoverAnchor, FormLabel, useFormControlContext, PopoverContent, PopoverArrow, PopoverBody, FocusLock, Popover, InputGroup, PopoverTrigger, Portal, Checkbox as Checkbox$1, useCheckbox, FormControl as FormControl$1, InputLeftElement, Input as Input$1, InputRightElement, Select, useDisclosure, Button as Button$1, useControllableState, Radio as Radio$1, RadioGroup as RadioGroup$1, Switch as Switch$1, Textarea as Textarea$1, Link, ModalHeader as ModalHeader$1, useModalContext, DrawerContent as DrawerContent$1, Tabs as Tabs$1, Table as Table$1, defineStyleConfig as defineStyleConfig$1, createMultiStyleConfigHelpers as createMultiStyleConfigHelpers$1, AccordionItem, AccordionButton, AccordionIcon, AccordionPanel, useColorMode, SkeletonCircle as SkeletonCircle$1, SkeletonText as SkeletonText$1, useColorModeValue, Breadcrumb as Breadcrumb$1, BreadcrumbItem as BreadcrumbItem$1, BreadcrumbLink as BreadcrumbLink$1, Heading as Heading$1, CheckboxGroup as CheckboxGroup$1, List, ListItem, useFormControlProps, useFormControl, Drawer as Drawer$1, DrawerOverlay,
|
1
|
+
import tokens11__default from '@vygruppen/spor-design-tokens';
|
2
|
+
import * as tokens11 from '@vygruppen/spor-design-tokens';
|
3
|
+
export { tokens11 as tokens };
|
4
|
+
import { forwardRef, Divider as Divider$1, Stack as Stack$1, Accordion as Accordion$1, Skeleton as Skeleton$1, useButtonGroup, useStyleConfig, Box, Center, Flex, ButtonGroup as ButtonGroup$1, IconButton as IconButton$1, useMultiStyleConfig, chakra, Badge as Badge$1, Code as Code$1, Text, PopoverAnchor, FormLabel, useFormControlContext, PopoverContent, PopoverArrow, PopoverBody, FocusLock, Popover, InputGroup, PopoverTrigger, Portal, Checkbox as Checkbox$1, useCheckbox, FormControl as FormControl$1, InputLeftElement, Input as Input$1, InputRightElement, Select, useDisclosure, Button as Button$1, useControllableState, Radio as Radio$1, RadioGroup as RadioGroup$1, Switch as Switch$1, Textarea as Textarea$1, Link, ModalHeader as ModalHeader$1, useModalContext, DrawerContent as DrawerContent$1, Tabs as Tabs$1, Table as Table$1, defineStyleConfig as defineStyleConfig$1, createMultiStyleConfigHelpers as createMultiStyleConfigHelpers$1, AccordionItem, AccordionButton, AccordionIcon, AccordionPanel, useColorMode, SkeletonCircle as SkeletonCircle$1, SkeletonText as SkeletonText$1, useColorModeValue, Breadcrumb as Breadcrumb$1, BreadcrumbItem as BreadcrumbItem$1, BreadcrumbLink as BreadcrumbLink$1, Heading as Heading$1, CheckboxGroup as CheckboxGroup$1, List, ListItem, useFormControlProps, useFormControl, Drawer as Drawer$1, DrawerOverlay, DrawerBody, DrawerHeader, useMediaQuery, DrawerCloseButton, DarkMode, PopoverCloseButton, usePopoverContext, ChakraProvider, useToast as useToast$1, useInterval } from '@chakra-ui/react';
|
5
5
|
export { AccordionButton, AccordionIcon, AccordionItem, AccordionPanel, Box, Center, Collapse, Container, DarkMode, DrawerBody, DrawerCloseButton, DrawerFooter, DrawerOverlay, Fade, Flex, FormHelperText, Grid, GridItem, HStack, Image, Img, InputGroup, LightMode, ListItem, Modal, ModalBody, ModalCloseButton, ModalContent, ModalFooter, ModalOverlay, OrderedList, Portal, ScaleFade, SimpleGrid, Slide, SlideFade, Spacer, Tab, TabList, TabPanel, TabPanels, TableCaption, Tbody, Td, Tfoot, Th, Thead, Tr, UnorderedList, VStack, Wrap, WrapItem, defineStyleConfig, extendTheme, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useTheme, useToken } from '@chakra-ui/react';
|
6
|
-
import * as
|
7
|
-
import
|
6
|
+
import * as React70 from 'react';
|
7
|
+
import React70__default, { createContext, useEffect, forwardRef as forwardRef$1, useRef, useState, useId, Suspense, useContext, useCallback, useMemo, useLayoutEffect } from 'react';
|
8
8
|
import { CloseFill30Icon, CloseFill24Icon, CloseFill18Icon, CalendarOutline24Icon, CloseOutline24Icon, SearchOutline24Icon, InformationFill24Icon, InformationFill18Icon, WarningFill24Icon, WarningFill18Icon, ErrorFill24Icon, ErrorFill18Icon, LinkOutOutline24Icon, DropdownRightFill18Icon, DropdownLeftFill18Icon, DropdownDownFill18Icon, DropdownDownFill24Icon, DropdownUpFill24Icon, ArrowRightFill18Icon, ArrowLeftFill24Icon, ArrowLeftOutline24Icon, ArrowRightOutline24Icon, ErrorOutline24Icon, AltTransportOutline24Icon, WarningOutline24Icon, SuccessOutline24Icon, InformationOutline24Icon, TrainFill18Icon, TrainFill24Icon, TrainFill30Icon, ExpressBusFill18Icon, ExpressBusFill24Icon, ExpressBusFill30Icon, BusFill18Icon, BusFill24Icon, BusFill30Icon, FerryFill18Icon, FerryFill24Icon, FerryFill30Icon, SubwayFill18Icon, SubwayFill24Icon, SubwayFill30Icon, TramFill18Icon, TramFill24Icon, TramFill30Icon, AltTransportFill18Icon, AltTransportFill24Icon, AltTransportFill30Icon, WalkFill18Icon, WalkFill24Icon, WalkFill30Icon } from '@vygruppen/spor-icon-react';
|
9
9
|
import { inlineLoaderColorData, spinnerColorData, contentLoaderData, fullScreenLoaderWhiteData, inlineLoaderDarkData, fullScreenLoaderBlackData, inlineLoaderLightData, spinnerLightData, spinnerDarkData } from '@vygruppen/spor-loader';
|
10
10
|
import { useLottie } from 'lottie-react';
|
@@ -771,22 +771,22 @@ var require_lodash = __commonJS({
|
|
771
771
|
}
|
772
772
|
});
|
773
773
|
var Divider = forwardRef((props, ref) => {
|
774
|
-
return /* @__PURE__ */
|
774
|
+
return /* @__PURE__ */ React70__default.createElement(Divider$1, { ...props, ref });
|
775
775
|
});
|
776
776
|
var Stack = forwardRef(
|
777
777
|
({ flexDirection, ...props }, ref) => {
|
778
|
-
return /* @__PURE__ */
|
778
|
+
return /* @__PURE__ */ React70__default.createElement(Stack$1, { ...props, direction: flexDirection, ref });
|
779
779
|
}
|
780
780
|
);
|
781
|
-
var AccordionContext =
|
781
|
+
var AccordionContext = React70__default.createContext(null);
|
782
782
|
var AccordionProvider = ({
|
783
783
|
size: size2,
|
784
784
|
...props
|
785
785
|
}) => {
|
786
|
-
return /* @__PURE__ */
|
786
|
+
return /* @__PURE__ */ React70__default.createElement(AccordionContext.Provider, { value: { size: size2 }, ...props });
|
787
787
|
};
|
788
788
|
var useAccordionContext = () => {
|
789
|
-
const context =
|
789
|
+
const context = React70__default.useContext(AccordionContext);
|
790
790
|
if (context === null) {
|
791
791
|
throw new Error(
|
792
792
|
"useAccordionContext must be used within AccordionProvider"
|
@@ -797,14 +797,14 @@ var useAccordionContext = () => {
|
|
797
797
|
var Accordion = forwardRef(
|
798
798
|
({ children, spacing: spacing3 = 2, ...props }, ref) => {
|
799
799
|
const defaultIndex = typeof props.defaultIndex === "number" && props.allowMultiple ? [props.defaultIndex] : props.defaultIndex;
|
800
|
-
return /* @__PURE__ */
|
800
|
+
return /* @__PURE__ */ React70__default.createElement(AccordionProvider, { size: props.size }, /* @__PURE__ */ React70__default.createElement(
|
801
801
|
Accordion$1,
|
802
802
|
{
|
803
803
|
...props,
|
804
804
|
ref,
|
805
805
|
defaultIndex
|
806
806
|
},
|
807
|
-
/* @__PURE__ */
|
807
|
+
/* @__PURE__ */ React70__default.createElement(Stack, { spacing: spacing3 }, children)
|
808
808
|
));
|
809
809
|
}
|
810
810
|
);
|
@@ -820,7 +820,7 @@ var Expandable = ({
|
|
820
820
|
},
|
821
821
|
...rest
|
822
822
|
}) => {
|
823
|
-
return /* @__PURE__ */
|
823
|
+
return /* @__PURE__ */ React70__default.createElement(
|
824
824
|
Accordion,
|
825
825
|
{
|
826
826
|
...rest,
|
@@ -830,7 +830,7 @@ var Expandable = ({
|
|
830
830
|
size: size2,
|
831
831
|
onChange: (expandedIndex) => onChange(expandedIndex === 0)
|
832
832
|
},
|
833
|
-
/* @__PURE__ */
|
833
|
+
/* @__PURE__ */ React70__default.createElement(
|
834
834
|
ExpandableItem,
|
835
835
|
{
|
836
836
|
headingLevel,
|
@@ -850,7 +850,7 @@ var ExpandableItem = ({
|
|
850
850
|
}) => {
|
851
851
|
const { size: size2 } = useAccordionContext();
|
852
852
|
warnAboutMismatchingIcon({ icon: leftIcon, size: size2 });
|
853
|
-
return /* @__PURE__ */
|
853
|
+
return /* @__PURE__ */ React70__default.createElement(AccordionItem, { ...rest }, /* @__PURE__ */ React70__default.createElement(Box, { as: headingLevel }, /* @__PURE__ */ React70__default.createElement(AccordionButton, null, /* @__PURE__ */ React70__default.createElement(Flex, { alignItems: "center" }, leftIcon && /* @__PURE__ */ React70__default.createElement(Box, { marginRight: 1 }, leftIcon), title), /* @__PURE__ */ React70__default.createElement(AccordionIcon, null))), /* @__PURE__ */ React70__default.createElement(AccordionPanel, null, children));
|
854
854
|
};
|
855
855
|
var warnAboutMismatchingIcon = ({ icon, size: size2 }) => {
|
856
856
|
var _a6, _b5;
|
@@ -899,7 +899,7 @@ function LanguageProvider({
|
|
899
899
|
language,
|
900
900
|
children
|
901
901
|
}) {
|
902
|
-
return /* @__PURE__ */
|
902
|
+
return /* @__PURE__ */ React70__default.createElement(LanguageContext.Provider, { value: language }, children);
|
903
903
|
}
|
904
904
|
function useLanguage() {
|
905
905
|
const language = useContext(LanguageContext);
|
@@ -915,8 +915,8 @@ function useTranslation() {
|
|
915
915
|
};
|
916
916
|
return { t: t2, language };
|
917
917
|
}
|
918
|
-
function createTexts(
|
919
|
-
return
|
918
|
+
function createTexts(texts27) {
|
919
|
+
return texts27;
|
920
920
|
}
|
921
921
|
var hydrating = true;
|
922
922
|
function useHydrated() {
|
@@ -931,11 +931,11 @@ function useHydrated() {
|
|
931
931
|
// src/loader/ClientOnly.tsx
|
932
932
|
var ClientOnly = ({ children, fallback = null }) => {
|
933
933
|
const isHydrated = useHydrated();
|
934
|
-
return /* @__PURE__ */
|
934
|
+
return /* @__PURE__ */ React70__default.createElement(React70__default.Fragment, null, isHydrated ? children() : fallback);
|
935
935
|
};
|
936
936
|
function Lottie({ animationData }) {
|
937
937
|
const { View } = useLottie({ animationData, loop: true });
|
938
|
-
return /* @__PURE__ */
|
938
|
+
return /* @__PURE__ */ React70__default.createElement(React70__default.Fragment, null, View);
|
939
939
|
}
|
940
940
|
|
941
941
|
// src/loader/ColorInlineLoader.tsx
|
@@ -944,7 +944,7 @@ var ColorInlineLoader = ({
|
|
944
944
|
maxWidth,
|
945
945
|
...props
|
946
946
|
}) => {
|
947
|
-
return /* @__PURE__ */
|
947
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: inlineLoaderColorData }))));
|
948
948
|
};
|
949
949
|
var ColorSpinner = ({
|
950
950
|
children,
|
@@ -952,24 +952,24 @@ var ColorSpinner = ({
|
|
952
952
|
maxWidth,
|
953
953
|
...props
|
954
954
|
}) => {
|
955
|
-
return /* @__PURE__ */
|
955
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { flexDirection: "column", ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: spinnerColorData }))), children && /* @__PURE__ */ React70__default.createElement(Box, { marginTop: 3, fontWeight: "bold" }, children));
|
956
956
|
};
|
957
957
|
var ContentLoader = ({ children, ...props }) => {
|
958
|
-
return /* @__PURE__ */
|
958
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...props }, /* @__PURE__ */ React70__default.createElement(Box, { maxWidth: "140px", marginX: "auto" }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: contentLoaderData }))), children && /* @__PURE__ */ React70__default.createElement(Box, { textAlign: "center", fontWeight: "bold" }, children));
|
959
959
|
};
|
960
960
|
var DarkFullScreenLoader = ({
|
961
961
|
width,
|
962
962
|
maxWidth,
|
963
963
|
...props
|
964
964
|
}) => {
|
965
|
-
return /* @__PURE__ */
|
965
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { height: "100%", background: "darkTeal", ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: fullScreenLoaderWhiteData }))));
|
966
966
|
};
|
967
967
|
var DarkInlineLoader = ({
|
968
968
|
width,
|
969
969
|
maxWidth,
|
970
970
|
...props
|
971
971
|
}) => {
|
972
|
-
return /* @__PURE__ */
|
972
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: inlineLoaderDarkData }))));
|
973
973
|
};
|
974
974
|
var DarkSpinner = ({
|
975
975
|
children,
|
@@ -979,21 +979,21 @@ var DarkSpinner = ({
|
|
979
979
|
}) => {
|
980
980
|
const { colorMode } = useColorMode();
|
981
981
|
const spinnerData = colorMode === "dark" ? spinnerLightData : spinnerDarkData;
|
982
|
-
return /* @__PURE__ */
|
982
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { flexDirection: "column", ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: spinnerData }))), children && /* @__PURE__ */ React70__default.createElement(Box, { marginTop: 3, fontWeight: "bold" }, children));
|
983
983
|
};
|
984
984
|
var LightFullScreenLoader = ({
|
985
985
|
width,
|
986
986
|
maxWidth,
|
987
987
|
...props
|
988
988
|
}) => {
|
989
|
-
return /* @__PURE__ */
|
989
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { height: "100%", background: "white", ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: fullScreenLoaderBlackData }))));
|
990
990
|
};
|
991
991
|
var LightInlineLoader = ({
|
992
992
|
width,
|
993
993
|
maxWidth,
|
994
994
|
...props
|
995
995
|
}) => {
|
996
|
-
return /* @__PURE__ */
|
996
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: inlineLoaderLightData }))));
|
997
997
|
};
|
998
998
|
var LightSpinner = ({
|
999
999
|
children,
|
@@ -1001,7 +1001,7 @@ var LightSpinner = ({
|
|
1001
1001
|
maxWidth,
|
1002
1002
|
...props
|
1003
1003
|
}) => {
|
1004
|
-
return /* @__PURE__ */
|
1004
|
+
return /* @__PURE__ */ React70__default.createElement(Center, { flexDirection: "column", ...props }, /* @__PURE__ */ React70__default.createElement(Box, { width, maxWidth }, /* @__PURE__ */ React70__default.createElement(ClientOnly, null, () => /* @__PURE__ */ React70__default.createElement(Lottie, { animationData: spinnerLightData }))), children && /* @__PURE__ */ React70__default.createElement(Box, { marginTop: 3, fontWeight: "bold" }, children));
|
1005
1005
|
};
|
1006
1006
|
var useRotatingLabel = ({ label, delay }) => {
|
1007
1007
|
const loadingTextArray = useMemo(
|
@@ -1038,7 +1038,7 @@ var ProgressBar = ({
|
|
1038
1038
|
"aria-label": ariaLabel || t2(texts.label(value))
|
1039
1039
|
});
|
1040
1040
|
const styles3 = useMultiStyleConfig("ProgressBar", {});
|
1041
|
-
return /* @__PURE__ */
|
1041
|
+
return /* @__PURE__ */ React70__default.createElement(React70__default.Fragment, null, /* @__PURE__ */ React70__default.createElement(
|
1042
1042
|
Box,
|
1043
1043
|
{
|
1044
1044
|
...progressBarProps,
|
@@ -1046,8 +1046,8 @@ var ProgressBar = ({
|
|
1046
1046
|
__css: styles3.container,
|
1047
1047
|
...rest
|
1048
1048
|
},
|
1049
|
-
/* @__PURE__ */
|
1050
|
-
currentLoadingText && /* @__PURE__ */
|
1049
|
+
/* @__PURE__ */ React70__default.createElement(Box, { width, __css: styles3.background }, /* @__PURE__ */ React70__default.createElement(Box, { __css: styles3.progress, height, width: `${value}%` })),
|
1050
|
+
currentLoadingText && /* @__PURE__ */ React70__default.createElement(Text, { sx: styles3.description, ...labelProps }, currentLoadingText)
|
1051
1051
|
));
|
1052
1052
|
};
|
1053
1053
|
var texts = createTexts({
|
@@ -1081,7 +1081,7 @@ var ProgressLoader = ({
|
|
1081
1081
|
const progressPathLength = ((_a6 = pathRef.current) == null ? void 0 : _a6.getTotalLength()) ?? 0;
|
1082
1082
|
const progress = (value - 100) / 100 * progressPathLength;
|
1083
1083
|
const id = useId();
|
1084
|
-
return /* @__PURE__ */
|
1084
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...progressBarProps, minWidth: "100px", width, ...rest }, /* @__PURE__ */ React70__default.createElement(Box, { as: "svg", viewBox: "0 0 246 78", fill: "none" }, /* @__PURE__ */ React70__default.createElement(
|
1085
1085
|
Box,
|
1086
1086
|
{
|
1087
1087
|
as: "path",
|
@@ -1089,7 +1089,7 @@ var ProgressLoader = ({
|
|
1089
1089
|
d: "M14.0479 44.8251C19.4332 44.8251 23.7988 40.5242 23.7988 35.2187C23.7988 29.9133 19.4332 25.6124 14.0479 25.6124C8.66254 25.6124 4.29688 29.9133 4.29688 35.2187C4.29688 40.5242 8.66254 44.8251 14.0479 44.8251Z",
|
1090
1090
|
fill: "#FFB466"
|
1091
1091
|
}
|
1092
|
-
), /* @__PURE__ */
|
1092
|
+
), /* @__PURE__ */ React70__default.createElement(
|
1093
1093
|
Box,
|
1094
1094
|
{
|
1095
1095
|
as: "path",
|
@@ -1100,7 +1100,7 @@ var ProgressLoader = ({
|
|
1100
1100
|
strokeLinecap: "round",
|
1101
1101
|
strokeLinejoin: "round"
|
1102
1102
|
}
|
1103
|
-
), /* @__PURE__ */
|
1103
|
+
), /* @__PURE__ */ React70__default.createElement(
|
1104
1104
|
Box,
|
1105
1105
|
{
|
1106
1106
|
as: "path",
|
@@ -1115,7 +1115,7 @@ var ProgressLoader = ({
|
|
1115
1115
|
transition: "stroke-dashoffset .2s ease-out",
|
1116
1116
|
ref: pathRef
|
1117
1117
|
}
|
1118
|
-
), /* @__PURE__ */
|
1118
|
+
), /* @__PURE__ */ React70__default.createElement(
|
1119
1119
|
Box,
|
1120
1120
|
{
|
1121
1121
|
as: "path",
|
@@ -1123,7 +1123,7 @@ var ProgressLoader = ({
|
|
1123
1123
|
d: "M226.025 44.8251C231.411 44.8251 235.776 40.5242 235.776 35.2187C235.776 29.9133 231.411 25.6124 226.025 25.6124C220.64 25.6124 216.274 29.9133 216.274 35.2187C216.274 40.5242 220.64 44.8251 226.025 44.8251Z",
|
1124
1124
|
fill: "#688CBA"
|
1125
1125
|
}
|
1126
|
-
)), currentLoadingText && /* @__PURE__ */
|
1126
|
+
)), currentLoadingText && /* @__PURE__ */ React70__default.createElement(
|
1127
1127
|
Text,
|
1128
1128
|
{
|
1129
1129
|
textAlign: "center",
|
@@ -1142,9 +1142,9 @@ var texts2 = createTexts({
|
|
1142
1142
|
en: `${value}% done`
|
1143
1143
|
})
|
1144
1144
|
});
|
1145
|
-
var Skeleton = forwardRef((props, ref) => /* @__PURE__ */
|
1146
|
-
var SkeletonCircle = (props) => /* @__PURE__ */
|
1147
|
-
var SkeletonText = (props) => /* @__PURE__ */
|
1145
|
+
var Skeleton = forwardRef((props, ref) => /* @__PURE__ */ React70__default.createElement(Skeleton$1, { ...props, ref }));
|
1146
|
+
var SkeletonCircle = (props) => /* @__PURE__ */ React70__default.createElement(SkeletonCircle$1, { boxSize: 6, borderRadius: "50%", ...props });
|
1147
|
+
var SkeletonText = (props) => /* @__PURE__ */ React70__default.createElement(SkeletonText$1, { boxSize: 6, ...props });
|
1148
1148
|
|
1149
1149
|
// src/button/Button.tsx
|
1150
1150
|
var Button = forwardRef((props, ref) => {
|
@@ -1174,7 +1174,7 @@ var Button = forwardRef((props, ref) => {
|
|
1174
1174
|
if (fontWeight) {
|
1175
1175
|
styles3.fontWeight = fontWeight;
|
1176
1176
|
}
|
1177
|
-
return /* @__PURE__ */
|
1177
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1178
1178
|
Box,
|
1179
1179
|
{
|
1180
1180
|
...rest,
|
@@ -1187,7 +1187,7 @@ var Button = forwardRef((props, ref) => {
|
|
1187
1187
|
disabled: isDisabled || isLoading,
|
1188
1188
|
position: "relative"
|
1189
1189
|
},
|
1190
|
-
isLoading && /* @__PURE__ */
|
1190
|
+
isLoading && /* @__PURE__ */ React70__default.createElement(Center, { position: "absolute", right: 0, left: 0, top: 1, bottom: 0 }, /* @__PURE__ */ React70__default.createElement(
|
1191
1191
|
ColorInlineLoader,
|
1192
1192
|
{
|
1193
1193
|
maxWidth: getLoaderWidth(finalSize),
|
@@ -1196,7 +1196,7 @@ var Button = forwardRef((props, ref) => {
|
|
1196
1196
|
marginY: 2
|
1197
1197
|
}
|
1198
1198
|
)),
|
1199
|
-
/* @__PURE__ */
|
1199
|
+
/* @__PURE__ */ React70__default.createElement(
|
1200
1200
|
Flex,
|
1201
1201
|
{
|
1202
1202
|
gap: 1,
|
@@ -1206,7 +1206,7 @@ var Button = forwardRef((props, ref) => {
|
|
1206
1206
|
visibility: isLoading ? "hidden" : "visible",
|
1207
1207
|
"aria-hidden": isLoading
|
1208
1208
|
},
|
1209
|
-
/* @__PURE__ */
|
1209
|
+
/* @__PURE__ */ React70__default.createElement(Flex, { gap: 1, alignItems: "center" }, leftIcon, /* @__PURE__ */ React70__default.createElement(
|
1210
1210
|
Box,
|
1211
1211
|
{
|
1212
1212
|
visibility: isLoading ? "hidden" : "visible",
|
@@ -1247,14 +1247,14 @@ var texts3 = createTexts({
|
|
1247
1247
|
sv: "Laddar\u2026"
|
1248
1248
|
}
|
1249
1249
|
});
|
1250
|
-
var ButtonGroup = forwardRef((props, ref) => /* @__PURE__ */
|
1250
|
+
var ButtonGroup = forwardRef((props, ref) => /* @__PURE__ */ React70__default.createElement(ButtonGroup$1, { ...props, ref }));
|
1251
1251
|
var IconButton = forwardRef(
|
1252
|
-
({ ...props }, ref) => /* @__PURE__ */
|
1252
|
+
({ ...props }, ref) => /* @__PURE__ */ React70__default.createElement(
|
1253
1253
|
IconButton$1,
|
1254
1254
|
{
|
1255
1255
|
title: props["aria-label"],
|
1256
1256
|
...props,
|
1257
|
-
spinner: /* @__PURE__ */
|
1257
|
+
spinner: /* @__PURE__ */ React70__default.createElement(ColorSpinner, { width: "80%", height: "80%", marginX: 1, marginTop: 1 }),
|
1258
1258
|
ref
|
1259
1259
|
}
|
1260
1260
|
)
|
@@ -1264,7 +1264,7 @@ var IconButton = forwardRef(
|
|
1264
1264
|
var CloseButton = forwardRef(
|
1265
1265
|
({ size: size2 = "sm", ...props }, ref) => {
|
1266
1266
|
const { t: t2 } = useTranslation();
|
1267
|
-
return /* @__PURE__ */
|
1267
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1268
1268
|
IconButton,
|
1269
1269
|
{
|
1270
1270
|
ref,
|
@@ -1281,11 +1281,11 @@ var getIcon = (size2) => {
|
|
1281
1281
|
switch (size2) {
|
1282
1282
|
case "xs":
|
1283
1283
|
case "sm":
|
1284
|
-
return /* @__PURE__ */
|
1284
|
+
return /* @__PURE__ */ React70__default.createElement(CloseFill18Icon, null);
|
1285
1285
|
case "md":
|
1286
|
-
return /* @__PURE__ */
|
1286
|
+
return /* @__PURE__ */ React70__default.createElement(CloseFill24Icon, null);
|
1287
1287
|
case "lg":
|
1288
|
-
return /* @__PURE__ */
|
1288
|
+
return /* @__PURE__ */ React70__default.createElement(CloseFill30Icon, null);
|
1289
1289
|
}
|
1290
1290
|
};
|
1291
1291
|
var texts4 = createTexts({
|
@@ -1307,7 +1307,7 @@ var FloatingActionButton = forwardRef(
|
|
1307
1307
|
placement = "bottom right",
|
1308
1308
|
...props
|
1309
1309
|
}, ref) => {
|
1310
|
-
const [isTextVisible, setIsTextVisible] =
|
1310
|
+
const [isTextVisible, setIsTextVisible] = React70__default.useState(
|
1311
1311
|
externalIsTextVisible !== void 0 ? externalIsTextVisible : false
|
1312
1312
|
);
|
1313
1313
|
const scrollDirection = useScrollDirection();
|
@@ -1329,7 +1329,7 @@ var FloatingActionButton = forwardRef(
|
|
1329
1329
|
isTextVisible,
|
1330
1330
|
placement
|
1331
1331
|
});
|
1332
|
-
return /* @__PURE__ */
|
1332
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1333
1333
|
MotionBox,
|
1334
1334
|
{
|
1335
1335
|
__css: style.container,
|
@@ -1337,8 +1337,8 @@ var FloatingActionButton = forwardRef(
|
|
1337
1337
|
ref,
|
1338
1338
|
...props
|
1339
1339
|
},
|
1340
|
-
/* @__PURE__ */
|
1341
|
-
/* @__PURE__ */
|
1340
|
+
/* @__PURE__ */ React70__default.createElement(Box, { __css: style.icon }, icon),
|
1341
|
+
/* @__PURE__ */ React70__default.createElement(
|
1342
1342
|
MotionBox,
|
1343
1343
|
{
|
1344
1344
|
animate: isTextVisible ? "show" : "hide",
|
@@ -1363,11 +1363,11 @@ var FloatingActionButton = forwardRef(
|
|
1363
1363
|
}
|
1364
1364
|
);
|
1365
1365
|
var useScrollDirection = () => {
|
1366
|
-
const [scrollDirection, setScrollDirection] =
|
1367
|
-
const lastScrollPosition =
|
1366
|
+
const [scrollDirection, setScrollDirection] = React70__default.useState(null);
|
1367
|
+
const lastScrollPosition = React70__default.useRef(
|
1368
1368
|
typeof window !== "undefined" ? window.scrollY : 0
|
1369
1369
|
);
|
1370
|
-
|
1370
|
+
React70__default.useEffect(() => {
|
1371
1371
|
const onScroll = () => {
|
1372
1372
|
const delta = window.scrollY - lastScrollPosition.current;
|
1373
1373
|
if (delta === 0) {
|
@@ -1386,7 +1386,7 @@ var useScrollDirection = () => {
|
|
1386
1386
|
var AlertIcon = ({ variant }) => {
|
1387
1387
|
const Icon = getIcon2(variant);
|
1388
1388
|
const { t: t2 } = useTranslation();
|
1389
|
-
return /* @__PURE__ */
|
1389
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1390
1390
|
Icon,
|
1391
1391
|
{
|
1392
1392
|
flexShrink: 0,
|
@@ -1448,7 +1448,7 @@ var BaseAlert = ({
|
|
1448
1448
|
...boxProps
|
1449
1449
|
}) => {
|
1450
1450
|
const styles3 = useMultiStyleConfig("Alert", { variant });
|
1451
|
-
return /* @__PURE__ */
|
1451
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { __css: styles3.container, ...boxProps }, children);
|
1452
1452
|
};
|
1453
1453
|
|
1454
1454
|
// src/alert/ClosableAlert.tsx
|
@@ -1468,17 +1468,17 @@ var ClosableAlert = ({
|
|
1468
1468
|
externalOnClose();
|
1469
1469
|
onClose();
|
1470
1470
|
};
|
1471
|
-
return /* @__PURE__ */
|
1471
|
+
return /* @__PURE__ */ React70__default.createElement(BaseAlert, { variant }, /* @__PURE__ */ React70__default.createElement(
|
1472
1472
|
IconButton,
|
1473
1473
|
{
|
1474
1474
|
variant: "ghost",
|
1475
1475
|
size: "sm",
|
1476
1476
|
onClick: handleClose,
|
1477
|
-
icon: /* @__PURE__ */
|
1477
|
+
icon: /* @__PURE__ */ React70__default.createElement(CloseFill18Icon, null),
|
1478
1478
|
"aria-label": t2(texts6.close),
|
1479
1479
|
sx: styles3.closeButton
|
1480
1480
|
}
|
1481
|
-
), /* @__PURE__ */
|
1481
|
+
), /* @__PURE__ */ React70__default.createElement(AlertIcon, { variant }), children);
|
1482
1482
|
};
|
1483
1483
|
var texts6 = createTexts({
|
1484
1484
|
close: {
|
@@ -1499,7 +1499,7 @@ var ExpandableAlert = ({
|
|
1499
1499
|
...boxProps
|
1500
1500
|
}) => {
|
1501
1501
|
const styles3 = useMultiStyleConfig("AlertExpandable", { variant });
|
1502
|
-
return /* @__PURE__ */
|
1502
|
+
return /* @__PURE__ */ React70__default.createElement(BaseAlert, { variant, ...boxProps, paddingX: 0, paddingY: 0 }, /* @__PURE__ */ React70__default.createElement(
|
1503
1503
|
Accordion$1,
|
1504
1504
|
{
|
1505
1505
|
onChange: (expandedIndex) => onToggle(expandedIndex === 0),
|
@@ -1507,14 +1507,14 @@ var ExpandableAlert = ({
|
|
1507
1507
|
allowToggle: true,
|
1508
1508
|
flexGrow: "1"
|
1509
1509
|
},
|
1510
|
-
/* @__PURE__ */
|
1510
|
+
/* @__PURE__ */ React70__default.createElement(AccordionItem, null, /* @__PURE__ */ React70__default.createElement(AccordionButton, { sx: styles3.container }, /* @__PURE__ */ React70__default.createElement(
|
1511
1511
|
Flex,
|
1512
1512
|
{
|
1513
1513
|
justifyContent: "space-between",
|
1514
1514
|
alignItems: "center",
|
1515
1515
|
flexGrow: "1"
|
1516
1516
|
},
|
1517
|
-
/* @__PURE__ */
|
1517
|
+
/* @__PURE__ */ React70__default.createElement(Flex, { as: headingLevel, alignItems: "center" }, /* @__PURE__ */ React70__default.createElement(AlertIcon, { variant }), /* @__PURE__ */ React70__default.createElement(
|
1518
1518
|
Box,
|
1519
1519
|
{
|
1520
1520
|
as: "span",
|
@@ -1528,19 +1528,19 @@ var ExpandableAlert = ({
|
|
1528
1528
|
},
|
1529
1529
|
title
|
1530
1530
|
)),
|
1531
|
-
/* @__PURE__ */
|
1532
|
-
)), /* @__PURE__ */
|
1531
|
+
/* @__PURE__ */ React70__default.createElement(AccordionIcon, null)
|
1532
|
+
)), /* @__PURE__ */ React70__default.createElement(AccordionPanel, null, children))
|
1533
1533
|
));
|
1534
1534
|
};
|
1535
1535
|
var StaticAlert = ({ children, ...props }) => {
|
1536
|
-
return /* @__PURE__ */
|
1536
|
+
return /* @__PURE__ */ React70__default.createElement(BaseAlert, { ...props }, /* @__PURE__ */ React70__default.createElement(AlertIcon, { variant: props.variant }), children);
|
1537
1537
|
};
|
1538
1538
|
var Breadcrumb = (props) => {
|
1539
1539
|
const iconColor = useColorModeValue("blackAlpha.400", "whiteAlpha.400");
|
1540
|
-
return /* @__PURE__ */
|
1540
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1541
1541
|
Breadcrumb$1,
|
1542
1542
|
{
|
1543
|
-
separator: /* @__PURE__ */
|
1543
|
+
separator: /* @__PURE__ */ React70__default.createElement(DropdownRightFill18Icon, { color: iconColor }),
|
1544
1544
|
...props
|
1545
1545
|
}
|
1546
1546
|
);
|
@@ -1553,12 +1553,16 @@ var Card = forwardRef(
|
|
1553
1553
|
colorScheme,
|
1554
1554
|
size: size2
|
1555
1555
|
});
|
1556
|
-
return /* @__PURE__ */
|
1556
|
+
return /* @__PURE__ */ React70__default.createElement(chakra.div, { sx: styles3, ...props, ref }, children);
|
1557
1557
|
}
|
1558
1558
|
);
|
1559
|
+
var StaticCard = ({ colorScheme, ...props }) => {
|
1560
|
+
const styles3 = useStyleConfig("StaticCard", { colorScheme });
|
1561
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { __css: styles3, ...props });
|
1562
|
+
};
|
1559
1563
|
var Badge = forwardRef(
|
1560
1564
|
({ icon, colorScheme = "grey", children, ...props }, ref) => {
|
1561
|
-
return /* @__PURE__ */
|
1565
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1562
1566
|
Badge$1,
|
1563
1567
|
{
|
1564
1568
|
colorScheme,
|
@@ -1566,12 +1570,12 @@ var Badge = forwardRef(
|
|
1566
1570
|
paddingLeft: icon ? 1 : void 0,
|
1567
1571
|
ref
|
1568
1572
|
},
|
1569
|
-
icon &&
|
1573
|
+
icon && React70__default.cloneElement(icon, { marginRight: 1 }),
|
1570
1574
|
children
|
1571
1575
|
);
|
1572
1576
|
}
|
1573
1577
|
);
|
1574
|
-
var Code = forwardRef((props, ref) => /* @__PURE__ */
|
1578
|
+
var Code = forwardRef((props, ref) => /* @__PURE__ */ React70__default.createElement(Code$1, { ...props, ref }));
|
1575
1579
|
var Heading = ({
|
1576
1580
|
as,
|
1577
1581
|
variant = "xl-display",
|
@@ -1581,11 +1585,11 @@ var Heading = ({
|
|
1581
1585
|
}) => {
|
1582
1586
|
const id = externalId ?? (autoId && typeof props.children === "string") ? slugify(props.children) : void 0;
|
1583
1587
|
const color2 = useColorModeValue("text.primary.light", "text.primary.dark");
|
1584
|
-
return /* @__PURE__ */
|
1588
|
+
return /* @__PURE__ */ React70__default.createElement(Text, { as, textStyle: variant, id, color: color2, ...props });
|
1585
1589
|
};
|
1586
1590
|
var Text4 = forwardRef(
|
1587
1591
|
({ variant = "sm", ...props }, ref) => {
|
1588
|
-
return /* @__PURE__ */
|
1592
|
+
return /* @__PURE__ */ React70__default.createElement(Text, { ...props, textStyle: variant, ref });
|
1589
1593
|
}
|
1590
1594
|
);
|
1591
1595
|
function CalendarCell({
|
@@ -1628,7 +1632,7 @@ function CalendarCell({
|
|
1628
1632
|
{ passive: false, once: true }
|
1629
1633
|
);
|
1630
1634
|
}, []);
|
1631
|
-
return /* @__PURE__ */
|
1635
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1632
1636
|
Box,
|
1633
1637
|
{
|
1634
1638
|
as: "td",
|
@@ -1651,7 +1655,7 @@ function CalendarCell({
|
|
1651
1655
|
}
|
1652
1656
|
}
|
1653
1657
|
},
|
1654
|
-
/* @__PURE__ */
|
1658
|
+
/* @__PURE__ */ React70__default.createElement(
|
1655
1659
|
Box,
|
1656
1660
|
{
|
1657
1661
|
as: "button",
|
@@ -1714,8 +1718,8 @@ function CalendarGrid({
|
|
1714
1718
|
const weeksInMonth = getWeeksInMonth(state2.visibleRange.start, locale);
|
1715
1719
|
const weeksInMonthRange = new Array(weeksInMonth).fill(0).map((_, i) => i);
|
1716
1720
|
const styles3 = useMultiStyleConfig("Datepicker", { variant });
|
1717
|
-
return /* @__PURE__ */
|
1718
|
-
return /* @__PURE__ */
|
1721
|
+
return /* @__PURE__ */ React70__default.createElement("table", { ...gridProps }, /* @__PURE__ */ React70__default.createElement("thead", { ...headerProps }, /* @__PURE__ */ React70__default.createElement("tr", null, weekDays[language].map((day, index) => {
|
1722
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1719
1723
|
Text4,
|
1720
1724
|
{
|
1721
1725
|
as: "th",
|
@@ -1725,8 +1729,8 @@ function CalendarGrid({
|
|
1725
1729
|
},
|
1726
1730
|
day
|
1727
1731
|
);
|
1728
|
-
}))), /* @__PURE__ */
|
1729
|
-
(date, dayIndex) => date ? /* @__PURE__ */
|
1732
|
+
}))), /* @__PURE__ */ React70__default.createElement("tbody", null, weeksInMonthRange.map((weekIndex) => /* @__PURE__ */ React70__default.createElement("tr", { key: weekIndex }, state2.getDatesInWeek(weekIndex, startDate).map(
|
1733
|
+
(date, dayIndex) => date ? /* @__PURE__ */ React70__default.createElement(
|
1730
1734
|
CalendarCell,
|
1731
1735
|
{
|
1732
1736
|
variant,
|
@@ -1735,7 +1739,7 @@ function CalendarGrid({
|
|
1735
1739
|
date,
|
1736
1740
|
currentMonth: startDate
|
1737
1741
|
}
|
1738
|
-
) : /* @__PURE__ */
|
1742
|
+
) : /* @__PURE__ */ React70__default.createElement("td", { key: dayIndex })
|
1739
1743
|
)))));
|
1740
1744
|
}
|
1741
1745
|
function CalendarNavigationButton({
|
@@ -1745,7 +1749,7 @@ function CalendarNavigationButton({
|
|
1745
1749
|
}) {
|
1746
1750
|
const ref = useRef(null);
|
1747
1751
|
const { buttonProps } = useButton(rest, ref);
|
1748
|
-
return /* @__PURE__ */
|
1752
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1749
1753
|
IconButton,
|
1750
1754
|
{
|
1751
1755
|
...buttonProps,
|
@@ -1779,7 +1783,7 @@ function CalendarHeader({
|
|
1779
1783
|
);
|
1780
1784
|
const areAllOtherYearsDisabled = isPreviousYearDisabled && isNextYearDisabled;
|
1781
1785
|
const isYearPickerVisible = showYearNavigation && !areAllOtherYearsDisabled;
|
1782
|
-
return /* @__PURE__ */
|
1786
|
+
return /* @__PURE__ */ React70__default.createElement(Flex, { alignItems: "center", paddingBottom: "4", justifyContent: "space-between" }, /* @__PURE__ */ React70__default.createElement(
|
1783
1787
|
CalendarNavigator,
|
1784
1788
|
{
|
1785
1789
|
title: title ? title : isYearPickerVisible ? monthTitle : monthAndYearTitle,
|
@@ -1789,7 +1793,7 @@ function CalendarHeader({
|
|
1789
1793
|
isNextDisabled: !state2.isPreviousVisibleRangeInvalid,
|
1790
1794
|
isPreviousDisabled: !state2.isNextVisibleRangeInvalid
|
1791
1795
|
}
|
1792
|
-
), isYearPickerVisible && /* @__PURE__ */
|
1796
|
+
), isYearPickerVisible && /* @__PURE__ */ React70__default.createElement(
|
1793
1797
|
CalendarNavigator,
|
1794
1798
|
{
|
1795
1799
|
title: jsDate.getFullYear().toString(),
|
@@ -1811,15 +1815,15 @@ var CalendarNavigator = ({
|
|
1811
1815
|
isNextDisabled
|
1812
1816
|
}) => {
|
1813
1817
|
const { t: t2 } = useTranslation();
|
1814
|
-
return /* @__PURE__ */
|
1818
|
+
return /* @__PURE__ */ React70__default.createElement(Flex, { alignItems: "center", flexGrow: 1 }, /* @__PURE__ */ React70__default.createElement(
|
1815
1819
|
CalendarNavigationButton,
|
1816
1820
|
{
|
1817
1821
|
onPress: onPrevious,
|
1818
1822
|
isDisabled: isPreviousDisabled,
|
1819
|
-
icon: /* @__PURE__ */
|
1823
|
+
icon: /* @__PURE__ */ React70__default.createElement(ArrowLeftOutline24Icon, null),
|
1820
1824
|
"aria-label": `${t2(texts7.previous)} ${t2(texts7[unit])}`
|
1821
1825
|
}
|
1822
|
-
), /* @__PURE__ */
|
1826
|
+
), /* @__PURE__ */ React70__default.createElement(
|
1823
1827
|
Heading,
|
1824
1828
|
{
|
1825
1829
|
as: "div",
|
@@ -1830,12 +1834,12 @@ var CalendarNavigator = ({
|
|
1830
1834
|
textAlign: "center"
|
1831
1835
|
},
|
1832
1836
|
capitalize(title)
|
1833
|
-
), /* @__PURE__ */
|
1837
|
+
), /* @__PURE__ */ React70__default.createElement(
|
1834
1838
|
CalendarNavigationButton,
|
1835
1839
|
{
|
1836
1840
|
onPress: onNext,
|
1837
1841
|
isDisabled: isNextDisabled,
|
1838
|
-
icon: /* @__PURE__ */
|
1842
|
+
icon: /* @__PURE__ */ React70__default.createElement(ArrowRightOutline24Icon, null),
|
1839
1843
|
"aria-label": `${t2(texts7.next)} ${t2(texts7[unit])}`
|
1840
1844
|
}
|
1841
1845
|
));
|
@@ -1883,7 +1887,7 @@ function Calendar({
|
|
1883
1887
|
const { calendarProps } = useCalendar(props, state2);
|
1884
1888
|
const calendarAriaLabel = calendarProps["aria-label"];
|
1885
1889
|
const ariaLabel = t2(texts8.calendar) + (calendarAriaLabel ? ` ${calendarAriaLabel}` : "");
|
1886
|
-
return /* @__PURE__ */
|
1890
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...calendarProps, "aria-label": ariaLabel }, /* @__PURE__ */ React70__default.createElement(CalendarHeader, { state: state2, showYearNavigation }), /* @__PURE__ */ React70__default.createElement(CalendarGrid, { variant, state: state2 }));
|
1887
1891
|
}
|
1888
1892
|
var texts8 = createTexts({
|
1889
1893
|
calendar: {
|
@@ -1904,7 +1908,7 @@ var CalendarTriggerButton = forwardRef(
|
|
1904
1908
|
onPress(event);
|
1905
1909
|
}
|
1906
1910
|
};
|
1907
|
-
return /* @__PURE__ */
|
1911
|
+
return /* @__PURE__ */ React70__default.createElement(PopoverAnchor, null, /* @__PURE__ */ React70__default.createElement(
|
1908
1912
|
Box,
|
1909
1913
|
{
|
1910
1914
|
ref,
|
@@ -1915,7 +1919,7 @@ var CalendarTriggerButton = forwardRef(
|
|
1915
1919
|
...filteredButtonProps,
|
1916
1920
|
onKeyUp: handleOnPress
|
1917
1921
|
},
|
1918
|
-
/* @__PURE__ */
|
1922
|
+
/* @__PURE__ */ React70__default.createElement(CalendarOutline24Icon, null)
|
1919
1923
|
));
|
1920
1924
|
}
|
1921
1925
|
);
|
@@ -1940,7 +1944,7 @@ var DateTimeSegment = forwardRef$1(
|
|
1940
1944
|
isPlaceholder: segment.isPlaceholder,
|
1941
1945
|
isEditable: segment.isEditable
|
1942
1946
|
});
|
1943
|
-
return /* @__PURE__ */
|
1947
|
+
return /* @__PURE__ */ React70__default.createElement(
|
1944
1948
|
Box,
|
1945
1949
|
{
|
1946
1950
|
...segmentProps,
|
@@ -1991,7 +1995,7 @@ var DateField = forwardRef$1(
|
|
1991
1995
|
state2,
|
1992
1996
|
ref
|
1993
1997
|
);
|
1994
|
-
return /* @__PURE__ */
|
1998
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { minWidth: "6rem", width: "100%" }, props.label && /* @__PURE__ */ React70__default.createElement(
|
1995
1999
|
FormLabel,
|
1996
2000
|
{
|
1997
2001
|
...props.labelProps,
|
@@ -2001,7 +2005,7 @@ var DateField = forwardRef$1(
|
|
2001
2005
|
paddingTop: "2px"
|
2002
2006
|
},
|
2003
2007
|
props.label
|
2004
|
-
), /* @__PURE__ */
|
2008
|
+
), /* @__PURE__ */ React70__default.createElement(Flex, { ...fieldProps, ref, paddingTop: "3", paddingBottom: "0.5" }, state2.segments.map((segment, i) => /* @__PURE__ */ React70__default.createElement(DateTimeSegment, { key: i, segment, state: state2 }))), /* @__PURE__ */ React70__default.createElement(
|
2005
2009
|
"input",
|
2006
2010
|
{
|
2007
2011
|
type: "hidden",
|
@@ -2017,7 +2021,7 @@ var StyledField = forwardRef(
|
|
2017
2021
|
isInvalid: false
|
2018
2022
|
};
|
2019
2023
|
const styles3 = useMultiStyleConfig("Datepicker", { variant });
|
2020
|
-
return /* @__PURE__ */
|
2024
|
+
return /* @__PURE__ */ React70__default.createElement(
|
2021
2025
|
Box,
|
2022
2026
|
{
|
2023
2027
|
...otherProps,
|
@@ -2069,7 +2073,7 @@ var DatePicker = forwardRef$1(
|
|
2069
2073
|
const onFieldClick = () => {
|
2070
2074
|
state2.setOpen(true);
|
2071
2075
|
};
|
2072
|
-
const popoverContent = /* @__PURE__ */
|
2076
|
+
const popoverContent = /* @__PURE__ */ React70__default.createElement(PopoverContent, { color: "darkGrey", sx: styles3.calendarPopover }, /* @__PURE__ */ React70__default.createElement(PopoverArrow, { sx: styles3.arrow }), /* @__PURE__ */ React70__default.createElement(PopoverBody, null, /* @__PURE__ */ React70__default.createElement(FocusLock, null, /* @__PURE__ */ React70__default.createElement(
|
2073
2077
|
Calendar,
|
2074
2078
|
{
|
2075
2079
|
...calendarProps,
|
@@ -2077,7 +2081,7 @@ var DatePicker = forwardRef$1(
|
|
2077
2081
|
showYearNavigation
|
2078
2082
|
}
|
2079
2083
|
))));
|
2080
|
-
return /* @__PURE__ */
|
2084
|
+
return /* @__PURE__ */ React70__default.createElement(I18nProvider, { locale }, /* @__PURE__ */ React70__default.createElement(
|
2081
2085
|
Box,
|
2082
2086
|
{
|
2083
2087
|
position: "relative",
|
@@ -2085,7 +2089,7 @@ var DatePicker = forwardRef$1(
|
|
2085
2089
|
flexDirection: "column",
|
2086
2090
|
width
|
2087
2091
|
},
|
2088
|
-
/* @__PURE__ */
|
2092
|
+
/* @__PURE__ */ React70__default.createElement(
|
2089
2093
|
Popover,
|
2090
2094
|
{
|
2091
2095
|
...dialogProps,
|
@@ -2094,7 +2098,7 @@ var DatePicker = forwardRef$1(
|
|
2094
2098
|
onClose: state2.close,
|
2095
2099
|
flip: false
|
2096
2100
|
},
|
2097
|
-
/* @__PURE__ */
|
2101
|
+
/* @__PURE__ */ React70__default.createElement(InputGroup, { ...groupProps, display: "inline-flex" }, /* @__PURE__ */ React70__default.createElement(PopoverAnchor, null, /* @__PURE__ */ React70__default.createElement(
|
2098
2102
|
StyledField,
|
2099
2103
|
{
|
2100
2104
|
variant,
|
@@ -2102,7 +2106,7 @@ var DatePicker = forwardRef$1(
|
|
2102
2106
|
paddingX: 3,
|
2103
2107
|
minHeight
|
2104
2108
|
},
|
2105
|
-
/* @__PURE__ */
|
2109
|
+
/* @__PURE__ */ React70__default.createElement(PopoverTrigger, null, /* @__PURE__ */ React70__default.createElement(
|
2106
2110
|
CalendarTriggerButton,
|
2107
2111
|
{
|
2108
2112
|
variant,
|
@@ -2110,7 +2114,7 @@ var DatePicker = forwardRef$1(
|
|
2110
2114
|
...buttonProps
|
2111
2115
|
}
|
2112
2116
|
)),
|
2113
|
-
/* @__PURE__ */
|
2117
|
+
/* @__PURE__ */ React70__default.createElement(
|
2114
2118
|
DateField,
|
2115
2119
|
{
|
2116
2120
|
label: props.label,
|
@@ -2120,8 +2124,8 @@ var DatePicker = forwardRef$1(
|
|
2120
2124
|
}
|
2121
2125
|
)
|
2122
2126
|
))),
|
2123
|
-
/* @__PURE__ */
|
2124
|
-
state2.isOpen && !props.isDisabled && withPortal && /* @__PURE__ */
|
2127
|
+
/* @__PURE__ */ React70__default.createElement(FormErrorMessage, { ...errorMessageProps }, errorMessage),
|
2128
|
+
state2.isOpen && !props.isDisabled && withPortal && /* @__PURE__ */ React70__default.createElement(Portal, null, popoverContent),
|
2125
2129
|
state2.isOpen && !props.isDisabled && !withPortal && popoverContent
|
2126
2130
|
)
|
2127
2131
|
));
|
@@ -2137,7 +2141,7 @@ function RangeCalendar(props) {
|
|
2137
2141
|
});
|
2138
2142
|
const ref = useRef(null);
|
2139
2143
|
const { calendarProps, title } = useRangeCalendar(props, state2, ref);
|
2140
|
-
return /* @__PURE__ */
|
2144
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...calendarProps, ref }, /* @__PURE__ */ React70__default.createElement(CalendarHeader, { state: state2, title }), /* @__PURE__ */ React70__default.createElement(Box, { display: "flex", gap: "8" }, /* @__PURE__ */ React70__default.createElement(CalendarGrid, { variant: props.variant, state: state2 }), /* @__PURE__ */ React70__default.createElement(
|
2141
2145
|
CalendarGrid,
|
2142
2146
|
{
|
2143
2147
|
variant: props.variant,
|
@@ -2184,8 +2188,8 @@ function DateRangePicker({
|
|
2184
2188
|
const onFieldClick = () => {
|
2185
2189
|
state2.setOpen(true);
|
2186
2190
|
};
|
2187
|
-
const popoverContent = /* @__PURE__ */
|
2188
|
-
return /* @__PURE__ */
|
2191
|
+
const popoverContent = /* @__PURE__ */ React70__default.createElement(PopoverContent, { sx: styles3.calendarPopover, maxWidth: "none" }, /* @__PURE__ */ React70__default.createElement(PopoverArrow, { sx: styles3.arrow }), /* @__PURE__ */ React70__default.createElement(PopoverBody, null, /* @__PURE__ */ React70__default.createElement(FocusLock, null, /* @__PURE__ */ React70__default.createElement(RangeCalendar, { variant: "base", ...calendarProps }))));
|
2192
|
+
return /* @__PURE__ */ React70__default.createElement(I18nProvider, { locale }, /* @__PURE__ */ React70__default.createElement(Box, { position: "relative", display: "inline-flex", flexDirection: "column" }, props.label && /* @__PURE__ */ React70__default.createElement(FormLabel, { ...labelProps, sx: styles3.inputLabel }, props.label), /* @__PURE__ */ React70__default.createElement(
|
2189
2193
|
Popover,
|
2190
2194
|
{
|
2191
2195
|
...dialogProps,
|
@@ -2194,7 +2198,7 @@ function DateRangePicker({
|
|
2194
2198
|
onClose: state2.close,
|
2195
2199
|
flip: false
|
2196
2200
|
},
|
2197
|
-
/* @__PURE__ */
|
2201
|
+
/* @__PURE__ */ React70__default.createElement(InputGroup, { ...groupProps, width: "auto", display: "inline-flex" }, /* @__PURE__ */ React70__default.createElement(PopoverAnchor, null, /* @__PURE__ */ React70__default.createElement(
|
2198
2202
|
StyledField,
|
2199
2203
|
{
|
2200
2204
|
alignItems: "center",
|
@@ -2204,7 +2208,7 @@ function DateRangePicker({
|
|
2204
2208
|
onKeyPress: handleEnterClick,
|
2205
2209
|
minHeight
|
2206
2210
|
},
|
2207
|
-
variant && /* @__PURE__ */
|
2211
|
+
variant && /* @__PURE__ */ React70__default.createElement(PopoverTrigger, null, /* @__PURE__ */ React70__default.createElement(
|
2208
2212
|
CalendarTriggerButton,
|
2209
2213
|
{
|
2210
2214
|
paddingLeft: 1,
|
@@ -2214,7 +2218,7 @@ function DateRangePicker({
|
|
2214
2218
|
...buttonProps
|
2215
2219
|
}
|
2216
2220
|
)),
|
2217
|
-
/* @__PURE__ */
|
2221
|
+
/* @__PURE__ */ React70__default.createElement(
|
2218
2222
|
DateField,
|
2219
2223
|
{
|
2220
2224
|
...startFieldProps,
|
@@ -2223,8 +2227,8 @@ function DateRangePicker({
|
|
2223
2227
|
labelProps
|
2224
2228
|
}
|
2225
2229
|
),
|
2226
|
-
/* @__PURE__ */
|
2227
|
-
/* @__PURE__ */
|
2230
|
+
/* @__PURE__ */ React70__default.createElement(Box, { as: "span", "aria-hidden": "true", paddingRight: "2" }, "\u2013"),
|
2231
|
+
/* @__PURE__ */ React70__default.createElement(
|
2228
2232
|
DateField,
|
2229
2233
|
{
|
2230
2234
|
...endFieldProps,
|
@@ -2234,14 +2238,14 @@ function DateRangePicker({
|
|
2234
2238
|
}
|
2235
2239
|
)
|
2236
2240
|
))),
|
2237
|
-
state2.isOpen && withPortal && /* @__PURE__ */
|
2241
|
+
state2.isOpen && withPortal && /* @__PURE__ */ React70__default.createElement(Portal, null, popoverContent),
|
2238
2242
|
state2.isOpen && !withPortal && popoverContent
|
2239
2243
|
)));
|
2240
2244
|
}
|
2241
2245
|
var TimeField = ({ state: state2, ...props }) => {
|
2242
2246
|
const ref = useRef(null);
|
2243
2247
|
const { labelProps, fieldProps } = useTimeField(props, state2, ref);
|
2244
|
-
return /* @__PURE__ */
|
2248
|
+
return /* @__PURE__ */ React70__default.createElement(Box, null, /* @__PURE__ */ React70__default.createElement(
|
2245
2249
|
FormLabel3,
|
2246
2250
|
{
|
2247
2251
|
...labelProps,
|
@@ -2253,7 +2257,7 @@ var TimeField = ({ state: state2, ...props }) => {
|
|
2253
2257
|
paddingTop: "2px"
|
2254
2258
|
},
|
2255
2259
|
props.label
|
2256
|
-
), /* @__PURE__ */
|
2260
|
+
), /* @__PURE__ */ React70__default.createElement(Flex, { ...fieldProps, ref, paddingTop: "3", paddingBottom: "0.5" }, state2.segments.map((segment) => /* @__PURE__ */ React70__default.createElement(DateTimeSegment, { key: segment.type, segment, state: state2 }))), /* @__PURE__ */ React70__default.createElement(
|
2257
2261
|
"input",
|
2258
2262
|
{
|
2259
2263
|
type: "hidden",
|
@@ -2322,7 +2326,7 @@ var TimePicker = ({
|
|
2322
2326
|
const ariaLabel = `${inputLabel} \u2013 ${t2(
|
2323
2327
|
texts10.selectedTimeIs(`${(dateTime == null ? void 0 : dateTime.hour) ?? 0} ${(dateTime == null ? void 0 : dateTime.minute) ?? 0}`)
|
2324
2328
|
)}`;
|
2325
|
-
return /* @__PURE__ */
|
2329
|
+
return /* @__PURE__ */ React70__default.createElement(
|
2326
2330
|
StyledField,
|
2327
2331
|
{
|
2328
2332
|
variant: "base",
|
@@ -2338,7 +2342,7 @@ var TimePicker = ({
|
|
2338
2342
|
"aria-label": ariaLabel,
|
2339
2343
|
...boxProps
|
2340
2344
|
},
|
2341
|
-
/* @__PURE__ */
|
2345
|
+
/* @__PURE__ */ React70__default.createElement(
|
2342
2346
|
IconButton,
|
2343
2347
|
{
|
2344
2348
|
variant: "ghost",
|
@@ -2346,14 +2350,14 @@ var TimePicker = ({
|
|
2346
2350
|
borderRadius: "xs",
|
2347
2351
|
"aria-label": backwardsLabel,
|
2348
2352
|
title: backwardsLabel,
|
2349
|
-
icon: /* @__PURE__ */
|
2353
|
+
icon: /* @__PURE__ */ React70__default.createElement(DropdownLeftFill18Icon, null),
|
2350
2354
|
onClick: handleBackwardsClick,
|
2351
2355
|
isDisabled,
|
2352
2356
|
style: isDisabled ? { backgroundColor: "transparent" } : {}
|
2353
2357
|
}
|
2354
2358
|
),
|
2355
|
-
/* @__PURE__ */
|
2356
|
-
/* @__PURE__ */
|
2359
|
+
/* @__PURE__ */ React70__default.createElement(TimeField, { label, state: state2, name }),
|
2360
|
+
/* @__PURE__ */ React70__default.createElement(
|
2357
2361
|
IconButton,
|
2358
2362
|
{
|
2359
2363
|
variant: "ghost",
|
@@ -2361,7 +2365,7 @@ var TimePicker = ({
|
|
2361
2365
|
borderRadius: "xs",
|
2362
2366
|
"aria-label": forwardsLabel,
|
2363
2367
|
title: forwardsLabel,
|
2364
|
-
icon: /* @__PURE__ */
|
2368
|
+
icon: /* @__PURE__ */ React70__default.createElement(DropdownRightFill18Icon, null),
|
2365
2369
|
onClick: handleForwardClick,
|
2366
2370
|
isDisabled,
|
2367
2371
|
style: isDisabled ? { backgroundColor: "transparent" } : {}
|
@@ -2430,7 +2434,7 @@ var AttachedInputs = ({
|
|
2430
2434
|
}
|
2431
2435
|
};
|
2432
2436
|
const direction2 = flexDirection === "row" ? "horizontal" : "vertical";
|
2433
|
-
return /* @__PURE__ */
|
2437
|
+
return /* @__PURE__ */ React70__default.createElement(
|
2434
2438
|
Flex,
|
2435
2439
|
{
|
2436
2440
|
role: "group",
|
@@ -2444,7 +2448,7 @@ var AttachedInputs = ({
|
|
2444
2448
|
var Dialog = ({ title, children, ...props }) => {
|
2445
2449
|
const ref = useRef(null);
|
2446
2450
|
const { dialogProps, titleProps } = useDialog(props, ref);
|
2447
|
-
return /* @__PURE__ */
|
2451
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...dialogProps, ref, outline: "none" }, title && /* @__PURE__ */ React70__default.createElement(Heading$1, { as: "h3", ...titleProps }, title), children);
|
2448
2452
|
};
|
2449
2453
|
var Popover3 = forwardRef$1(
|
2450
2454
|
({
|
@@ -2475,21 +2479,21 @@ var Popover3 = forwardRef$1(
|
|
2475
2479
|
},
|
2476
2480
|
state2
|
2477
2481
|
);
|
2478
|
-
const popoverBox = /* @__PURE__ */
|
2482
|
+
const popoverBox = /* @__PURE__ */ React70__default.createElement(
|
2479
2483
|
Box,
|
2480
2484
|
{
|
2481
2485
|
...popoverProps,
|
2482
2486
|
ref: popoverRef,
|
2483
2487
|
minWidth: ((_a6 = triggerRef.current) == null ? void 0 : _a6.clientWidth) ?? "auto"
|
2484
2488
|
},
|
2485
|
-
/* @__PURE__ */
|
2489
|
+
/* @__PURE__ */ React70__default.createElement(DismissButton, { onDismiss: state2.close }),
|
2486
2490
|
children,
|
2487
|
-
/* @__PURE__ */
|
2491
|
+
/* @__PURE__ */ React70__default.createElement(DismissButton, { onDismiss: state2.close })
|
2488
2492
|
);
|
2489
2493
|
if (isNonModal) {
|
2490
2494
|
return popoverBox;
|
2491
2495
|
}
|
2492
|
-
return /* @__PURE__ */
|
2496
|
+
return /* @__PURE__ */ React70__default.createElement(Overlay, null, hasBackdrop && /* @__PURE__ */ React70__default.createElement(Box, { ...underlayProps, position: "fixed", inset: "0" }), popoverBox);
|
2493
2497
|
}
|
2494
2498
|
);
|
2495
2499
|
|
@@ -2507,6 +2511,7 @@ var CardSelect = forwardRef(
|
|
2507
2511
|
crossOffset = 0,
|
2508
2512
|
placement = "bottom",
|
2509
2513
|
withChevron = true,
|
2514
|
+
fontWeight = "normal",
|
2510
2515
|
...props
|
2511
2516
|
}, externalRef) => {
|
2512
2517
|
const label = "label" in props ? props.label : props["aria-label"];
|
@@ -2529,24 +2534,25 @@ var CardSelect = forwardRef(
|
|
2529
2534
|
});
|
2530
2535
|
useForceRerender(state2.isOpen);
|
2531
2536
|
const ChevronIcon = size2 === "sm" ? DropdownDownFill18Icon : DropdownDownFill24Icon;
|
2532
|
-
return /* @__PURE__ */
|
2537
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...props }, /* @__PURE__ */ React70__default.createElement(
|
2533
2538
|
chakra.button,
|
2534
2539
|
{
|
2535
2540
|
type: "button",
|
2536
2541
|
ref: triggerRef,
|
2542
|
+
fontWeight: "bold",
|
2537
2543
|
sx: styles3.trigger,
|
2538
2544
|
"aria-label": label,
|
2539
2545
|
...buttonProps,
|
2540
2546
|
width,
|
2541
2547
|
"data-attachable": true
|
2542
2548
|
},
|
2543
|
-
/* @__PURE__ */
|
2549
|
+
/* @__PURE__ */ React70__default.createElement(Flex, { gap: 1.5, alignItems: "center" }, icon, /* @__PURE__ */ React70__default.createElement(Box, { as: "span", display: props["aria-label"] ? "none" : "inline" }, label), withChevron ? /* @__PURE__ */ React70__default.createElement(
|
2544
2550
|
ChevronIcon,
|
2545
2551
|
{
|
2546
2552
|
transform: state2.isOpen ? "rotate(180deg)" : "none"
|
2547
2553
|
}
|
2548
2554
|
) : null)
|
2549
|
-
), state2.isOpen && /* @__PURE__ */
|
2555
|
+
), state2.isOpen && /* @__PURE__ */ React70__default.createElement(
|
2550
2556
|
Popover3,
|
2551
2557
|
{
|
2552
2558
|
state: state2,
|
@@ -2555,7 +2561,7 @@ var CardSelect = forwardRef(
|
|
2555
2561
|
crossOffset,
|
2556
2562
|
placement
|
2557
2563
|
},
|
2558
|
-
/* @__PURE__ */
|
2564
|
+
/* @__PURE__ */ React70__default.createElement(
|
2559
2565
|
Card,
|
2560
2566
|
{
|
2561
2567
|
colorScheme: "white",
|
@@ -2563,7 +2569,7 @@ var CardSelect = forwardRef(
|
|
2563
2569
|
sx: styles3.card,
|
2564
2570
|
...overlayProps
|
2565
2571
|
},
|
2566
|
-
/* @__PURE__ */
|
2572
|
+
/* @__PURE__ */ React70__default.createElement(Dialog, { "aria-label": label }, children)
|
2567
2573
|
)
|
2568
2574
|
));
|
2569
2575
|
}
|
@@ -2577,14 +2583,14 @@ function useForceRerender(shouldRerender) {
|
|
2577
2583
|
}, [shouldRerender]);
|
2578
2584
|
}
|
2579
2585
|
var Checkbox = forwardRef((props, ref) => {
|
2580
|
-
return /* @__PURE__ */
|
2586
|
+
return /* @__PURE__ */ React70__default.createElement(Checkbox$1, { ...props, ref });
|
2581
2587
|
});
|
2582
2588
|
var CheckboxGroup = ({
|
2583
2589
|
direction: direction2 = "row",
|
2584
2590
|
children,
|
2585
2591
|
...props
|
2586
2592
|
}) => {
|
2587
|
-
return /* @__PURE__ */
|
2593
|
+
return /* @__PURE__ */ React70__default.createElement(CheckboxGroup$1, { ...props }, /* @__PURE__ */ React70__default.createElement(Stack$1, { direction: direction2 }, children));
|
2588
2594
|
};
|
2589
2595
|
|
2590
2596
|
// ../../node_modules/@chakra-ui/utils/dist/chunk-O3SWHQEE.mjs
|
@@ -2613,15 +2619,15 @@ var ChoiceChip = forwardRef((props, ref) => {
|
|
2613
2619
|
hasLabel: Boolean(children)
|
2614
2620
|
});
|
2615
2621
|
const id = `choice-chip-${useId()}`;
|
2616
|
-
return /* @__PURE__ */
|
2622
|
+
return /* @__PURE__ */ React70__default.createElement(
|
2617
2623
|
chakra.label,
|
2618
2624
|
{
|
2619
2625
|
htmlFor: id,
|
2620
2626
|
...getRootProps(),
|
2621
2627
|
"aria-label": String(children)
|
2622
2628
|
},
|
2623
|
-
/* @__PURE__ */
|
2624
|
-
/* @__PURE__ */
|
2629
|
+
/* @__PURE__ */ React70__default.createElement(chakra.input, { ...getInputProps({}, ref), id, disabled: isDisabled }),
|
2630
|
+
/* @__PURE__ */ React70__default.createElement(
|
2625
2631
|
chakra.div,
|
2626
2632
|
{
|
2627
2633
|
...getLabelProps(),
|
@@ -2632,9 +2638,9 @@ var ChoiceChip = forwardRef((props, ref) => {
|
|
2632
2638
|
"data-active": dataAttr(state2.isActive),
|
2633
2639
|
"data-disabled": dataAttr(state2.isDisabled)
|
2634
2640
|
},
|
2635
|
-
icon && /* @__PURE__ */
|
2636
|
-
/* @__PURE__ */
|
2637
|
-
chipType === "filter" && state2.isChecked && /* @__PURE__ */
|
2641
|
+
icon && /* @__PURE__ */ React70__default.createElement(chakra.span, { __css: styles3.icon }, state2.isChecked ? icon.checked : icon.default),
|
2642
|
+
/* @__PURE__ */ React70__default.createElement(chakra.span, { __css: styles3.label, ...getCheckboxProps() }, chipType !== "icon" && children),
|
2643
|
+
chipType === "filter" && state2.isChecked && /* @__PURE__ */ React70__default.createElement(CloseOutline24Icon, { marginLeft: 1.5 })
|
2638
2644
|
)
|
2639
2645
|
);
|
2640
2646
|
});
|
@@ -2677,6 +2683,23 @@ function Combobox({
|
|
2677
2683
|
label,
|
2678
2684
|
...rest
|
2679
2685
|
});
|
2686
|
+
const comboBoxProps = {
|
2687
|
+
borderTopLeftRadius,
|
2688
|
+
borderTopRightRadius,
|
2689
|
+
marginBottom,
|
2690
|
+
marginTop,
|
2691
|
+
marginRight,
|
2692
|
+
marginLeft,
|
2693
|
+
marginX,
|
2694
|
+
marginY,
|
2695
|
+
paddingBottom,
|
2696
|
+
paddingRight,
|
2697
|
+
paddingTop,
|
2698
|
+
paddingLeft,
|
2699
|
+
paddingX,
|
2700
|
+
paddingY,
|
2701
|
+
leftIcon
|
2702
|
+
};
|
2680
2703
|
const {
|
2681
2704
|
inputProps: { size: size2, ...inputProps },
|
2682
2705
|
listBoxProps
|
@@ -2689,31 +2712,17 @@ function Combobox({
|
|
2689
2712
|
},
|
2690
2713
|
state2
|
2691
2714
|
);
|
2692
|
-
return /* @__PURE__ */
|
2715
|
+
return /* @__PURE__ */ React70__default.createElement(React70__default.Fragment, null, /* @__PURE__ */ React70__default.createElement(
|
2693
2716
|
Input,
|
2694
2717
|
{
|
2695
|
-
...
|
2718
|
+
...styleProps(comboBoxProps),
|
2696
2719
|
"aria-haspopup": "listbox",
|
2697
2720
|
ref: inputRef,
|
2698
2721
|
label,
|
2699
2722
|
borderBottomLeftRadius: state2.isOpen && !isLoading ? 0 : borderBottomLeftRadius,
|
2700
2723
|
borderBottomRightRadius: state2.isOpen && !isLoading ? 0 : borderBottomRightRadius,
|
2701
|
-
|
2702
|
-
|
2703
|
-
marginBottom,
|
2704
|
-
marginTop,
|
2705
|
-
marginRight,
|
2706
|
-
marginLeft,
|
2707
|
-
marginX,
|
2708
|
-
marginY,
|
2709
|
-
paddingBottom,
|
2710
|
-
paddingRight,
|
2711
|
-
paddingTop,
|
2712
|
-
paddingLeft,
|
2713
|
-
paddingX,
|
2714
|
-
paddingY,
|
2715
|
-
leftIcon,
|
2716
|
-
rightIcon: isLoading ? /* @__PURE__ */ React69__default.createElement(
|
2724
|
+
...inputProps,
|
2725
|
+
rightIcon: isLoading ? /* @__PURE__ */ React70__default.createElement(
|
2717
2726
|
ColorSpinner,
|
2718
2727
|
{
|
2719
2728
|
width: "1.5rem",
|
@@ -2728,7 +2737,7 @@ function Combobox({
|
|
2728
2737
|
}
|
2729
2738
|
) : rightIcon
|
2730
2739
|
}
|
2731
|
-
), state2.isOpen && !isLoading && /* @__PURE__ */
|
2740
|
+
), state2.isOpen && !isLoading && /* @__PURE__ */ React70__default.createElement(
|
2732
2741
|
Popover3,
|
2733
2742
|
{
|
2734
2743
|
state: state2,
|
@@ -2740,7 +2749,7 @@ function Combobox({
|
|
2740
2749
|
hasBackdrop: false,
|
2741
2750
|
containerPadding: 0
|
2742
2751
|
},
|
2743
|
-
/* @__PURE__ */
|
2752
|
+
/* @__PURE__ */ React70__default.createElement(
|
2744
2753
|
ListBox,
|
2745
2754
|
{
|
2746
2755
|
...listBoxProps,
|
@@ -2766,6 +2775,11 @@ var useInputWidth = (inputRef) => {
|
|
2766
2775
|
}, []);
|
2767
2776
|
return inputWidth;
|
2768
2777
|
};
|
2778
|
+
function styleProps(obj) {
|
2779
|
+
return Object.fromEntries(
|
2780
|
+
Object.entries(obj).filter(([, value]) => value !== void 0)
|
2781
|
+
);
|
2782
|
+
}
|
2769
2783
|
var debounce = (fn, ms = 100) => {
|
2770
2784
|
let timer;
|
2771
2785
|
return () => {
|
@@ -2777,7 +2791,7 @@ var debounce = (fn, ms = 100) => {
|
|
2777
2791
|
};
|
2778
2792
|
};
|
2779
2793
|
var FormControl = forwardRef((props, ref) => {
|
2780
|
-
return /* @__PURE__ */
|
2794
|
+
return /* @__PURE__ */ React70__default.createElement(FormControl$1, { ...props, ref });
|
2781
2795
|
});
|
2782
2796
|
var FormErrorMessage = ({
|
2783
2797
|
children,
|
@@ -2793,7 +2807,7 @@ var FormErrorMessage = ({
|
|
2793
2807
|
return null;
|
2794
2808
|
}
|
2795
2809
|
const { ref, ...errorMessageProps } = formControlContext.getErrorMessageProps();
|
2796
|
-
return /* @__PURE__ */
|
2810
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { position: "relative", ref }, /* @__PURE__ */ React70__default.createElement(
|
2797
2811
|
Box,
|
2798
2812
|
{
|
2799
2813
|
borderRadius: "xs",
|
@@ -2811,12 +2825,12 @@ var FormErrorMessage = ({
|
|
2811
2825
|
...errorMessageProps,
|
2812
2826
|
...boxProps
|
2813
2827
|
},
|
2814
|
-
/* @__PURE__ */
|
2828
|
+
/* @__PURE__ */ React70__default.createElement(Arrow, { position: "absolute", top: "-0.25em", left: "1em" }),
|
2815
2829
|
children
|
2816
2830
|
));
|
2817
2831
|
};
|
2818
2832
|
var Arrow = (props) => {
|
2819
|
-
return /* @__PURE__ */
|
2833
|
+
return /* @__PURE__ */ React70__default.createElement(
|
2820
2834
|
Box,
|
2821
2835
|
{
|
2822
2836
|
...props,
|
@@ -2827,7 +2841,7 @@ var Arrow = (props) => {
|
|
2827
2841
|
fill: "none",
|
2828
2842
|
transform: "rotate(45deg)"
|
2829
2843
|
},
|
2830
|
-
/* @__PURE__ */
|
2844
|
+
/* @__PURE__ */ React70__default.createElement(
|
2831
2845
|
Box,
|
2832
2846
|
{
|
2833
2847
|
as: "path",
|
@@ -2838,7 +2852,7 @@ var Arrow = (props) => {
|
|
2838
2852
|
);
|
2839
2853
|
};
|
2840
2854
|
var FormLabel3 = forwardRef((props, ref) => {
|
2841
|
-
return /* @__PURE__ */
|
2855
|
+
return /* @__PURE__ */ React70__default.createElement(FormLabel, { ...props, ref });
|
2842
2856
|
});
|
2843
2857
|
function ListBox({
|
2844
2858
|
isLoading,
|
@@ -2849,7 +2863,7 @@ function ListBox({
|
|
2849
2863
|
}) {
|
2850
2864
|
const { listBoxProps } = useListBox(props, state2, listBoxRef);
|
2851
2865
|
const styles3 = useMultiStyleConfig("ListBox", {});
|
2852
|
-
return /* @__PURE__ */
|
2866
|
+
return /* @__PURE__ */ React70__default.createElement(
|
2853
2867
|
List,
|
2854
2868
|
{
|
2855
2869
|
...listBoxProps,
|
@@ -2860,19 +2874,19 @@ function ListBox({
|
|
2860
2874
|
},
|
2861
2875
|
state2.collection.size === 0 && props.emptyContent,
|
2862
2876
|
Array.from(state2.collection).map(
|
2863
|
-
(item) => item.type === "section" ? /* @__PURE__ */
|
2877
|
+
(item) => item.type === "section" ? /* @__PURE__ */ React70__default.createElement(ListBoxSection, { key: item.key, section: item, state: state2 }) : /* @__PURE__ */ React70__default.createElement(Option, { key: item.key, item, state: state2 })
|
2864
2878
|
)
|
2865
2879
|
);
|
2866
2880
|
}
|
2867
2881
|
function ItemLabel({ children }) {
|
2868
2882
|
let { labelProps } = useOptionContext();
|
2869
2883
|
const styles3 = useMultiStyleConfig("ListBox", {});
|
2870
|
-
return /* @__PURE__ */
|
2884
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...labelProps, sx: styles3.label }, children);
|
2871
2885
|
}
|
2872
2886
|
function ItemDescription({ children }) {
|
2873
2887
|
let { descriptionProps } = useOptionContext();
|
2874
2888
|
const styles3 = useMultiStyleConfig("ListBox", {});
|
2875
|
-
return /* @__PURE__ */
|
2889
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...descriptionProps, sx: styles3.description }, children);
|
2876
2890
|
}
|
2877
2891
|
function Option({ item, state: state2 }) {
|
2878
2892
|
const ref = useRef(null);
|
@@ -2905,9 +2919,9 @@ function Option({ item, state: state2 }) {
|
|
2905
2919
|
{ passive: false, once: true }
|
2906
2920
|
);
|
2907
2921
|
}, []);
|
2908
|
-
return /* @__PURE__ */
|
2922
|
+
return /* @__PURE__ */ React70__default.createElement(OptionContext.Provider, { value: { labelProps, descriptionProps } }, /* @__PURE__ */ React70__default.createElement(ListItem, { ...optionProps, ...dataFields, ref, sx: styles3.item }, item.rendered));
|
2909
2923
|
}
|
2910
|
-
var OptionContext =
|
2924
|
+
var OptionContext = React70__default.createContext({
|
2911
2925
|
labelProps: {},
|
2912
2926
|
descriptionProps: {}
|
2913
2927
|
});
|
@@ -2921,7 +2935,7 @@ function ListBoxSection({ section, state: state2 }) {
|
|
2921
2935
|
});
|
2922
2936
|
const isFirstSection = section.key === state2.collection.getFirstKey();
|
2923
2937
|
const titleColor = useColorModeValue("darkGrey", "white");
|
2924
|
-
return /* @__PURE__ */
|
2938
|
+
return /* @__PURE__ */ React70__default.createElement(ListItem, { ...itemProps }, section.rendered && /* @__PURE__ */ React70__default.createElement(
|
2925
2939
|
Box,
|
2926
2940
|
{
|
2927
2941
|
fontSize: "mobile.xs",
|
@@ -2934,8 +2948,8 @@ function ListBoxSection({ section, state: state2 }) {
|
|
2934
2948
|
...headingProps
|
2935
2949
|
},
|
2936
2950
|
section.rendered
|
2937
|
-
), /* @__PURE__ */
|
2938
|
-
(item) => /* @__PURE__ */
|
2951
|
+
), /* @__PURE__ */ React70__default.createElement(List, { ...groupProps, padding: 0, listStyleType: "none" }, Array.from(state2.collection.getChildren(section.key)).map(
|
2952
|
+
(item) => /* @__PURE__ */ React70__default.createElement(Option, { key: item.key, item, state: state2 })
|
2939
2953
|
)));
|
2940
2954
|
}
|
2941
2955
|
|
@@ -2975,7 +2989,7 @@ function InfoSelect({
|
|
2975
2989
|
const { buttonProps } = useButton(triggerProps, triggerRef);
|
2976
2990
|
const { t: t2 } = useTranslation();
|
2977
2991
|
const formControl = useFormControlProps(props);
|
2978
|
-
return /* @__PURE__ */
|
2992
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { sx: styles3.container }, /* @__PURE__ */ React70__default.createElement(chakra.div, { ...labelProps, sx: styles3.label }, props.label), /* @__PURE__ */ React70__default.createElement(
|
2979
2993
|
HiddenSelect,
|
2980
2994
|
{
|
2981
2995
|
state: state2,
|
@@ -2983,7 +2997,7 @@ function InfoSelect({
|
|
2983
2997
|
label: props.label,
|
2984
2998
|
name: props.name
|
2985
2999
|
}
|
2986
|
-
), /* @__PURE__ */
|
3000
|
+
), /* @__PURE__ */ React70__default.createElement(
|
2987
3001
|
chakra.button,
|
2988
3002
|
{
|
2989
3003
|
type: "button",
|
@@ -2996,16 +3010,16 @@ function InfoSelect({
|
|
2996
3010
|
"aria-invalid": formControl.isInvalid,
|
2997
3011
|
"aria-describedby": formControl["aria-describedby"]
|
2998
3012
|
},
|
2999
|
-
/* @__PURE__ */
|
3000
|
-
/* @__PURE__ */
|
3001
|
-
), state2.isOpen && /* @__PURE__ */
|
3013
|
+
/* @__PURE__ */ React70__default.createElement(Box, { ...valueProps }, state2.selectedItem ? state2.selectedItem.textValue ?? state2.selectedItem.rendered : placeholder ?? t2(texts11.selectAnOption)),
|
3014
|
+
/* @__PURE__ */ React70__default.createElement(Box, { sx: styles3.arrowIcon }, state2.isOpen ? /* @__PURE__ */ React70__default.createElement(DropdownUpFill24Icon, null) : /* @__PURE__ */ React70__default.createElement(DropdownDownFill24Icon, null))
|
3015
|
+
), state2.isOpen && /* @__PURE__ */ React70__default.createElement(
|
3002
3016
|
Popover3,
|
3003
3017
|
{
|
3004
3018
|
state: state2,
|
3005
3019
|
triggerRef,
|
3006
3020
|
containerPadding: 0
|
3007
3021
|
},
|
3008
|
-
/* @__PURE__ */
|
3022
|
+
/* @__PURE__ */ React70__default.createElement(
|
3009
3023
|
ListBox,
|
3010
3024
|
{
|
3011
3025
|
...menuProps,
|
@@ -3030,7 +3044,7 @@ var Input = forwardRef(
|
|
3030
3044
|
const formControlProps = useFormControlContext();
|
3031
3045
|
const fallbackId = `input-${useId()}`;
|
3032
3046
|
const inputId = id ?? (formControlProps == null ? void 0 : formControlProps.id) ?? fallbackId;
|
3033
|
-
return /* @__PURE__ */
|
3047
|
+
return /* @__PURE__ */ React70__default.createElement(InputGroup, { position: "relative" }, leftIcon && /* @__PURE__ */ React70__default.createElement(InputLeftElement, { pointerEvents: "none" }, leftIcon), /* @__PURE__ */ React70__default.createElement(
|
3034
3048
|
Input$1,
|
3035
3049
|
{
|
3036
3050
|
"data-attachable": true,
|
@@ -3041,19 +3055,19 @@ var Input = forwardRef(
|
|
3041
3055
|
ref,
|
3042
3056
|
placeholder: " "
|
3043
3057
|
}
|
3044
|
-
), /* @__PURE__ */
|
3058
|
+
), /* @__PURE__ */ React70__default.createElement(FormLabel, { htmlFor: inputId }, label), rightIcon && /* @__PURE__ */ React70__default.createElement(InputRightElement, { pointerEvents: "none" }, rightIcon));
|
3045
3059
|
}
|
3046
3060
|
);
|
3047
3061
|
var InputLeftElement2 = forwardRef(
|
3048
|
-
(props, ref) => /* @__PURE__ */
|
3062
|
+
(props, ref) => /* @__PURE__ */ React70__default.createElement(InputLeftElement, { ...props, ref })
|
3049
3063
|
);
|
3050
3064
|
var InputRightElement2 = forwardRef(
|
3051
|
-
(props, ref) => /* @__PURE__ */
|
3065
|
+
(props, ref) => /* @__PURE__ */ React70__default.createElement(InputRightElement, { ...props, ref })
|
3052
3066
|
);
|
3053
3067
|
var NativeSelect = forwardRef(
|
3054
3068
|
({ label, ...props }, ref) => {
|
3055
3069
|
const styles3 = useMultiStyleConfig("Select", props);
|
3056
|
-
return /* @__PURE__ */
|
3070
|
+
return /* @__PURE__ */ React70__default.createElement(FormControl, null, /* @__PURE__ */ React70__default.createElement(
|
3057
3071
|
Select,
|
3058
3072
|
{
|
3059
3073
|
"data-attachable": true,
|
@@ -3061,7 +3075,7 @@ var NativeSelect = forwardRef(
|
|
3061
3075
|
rootProps: { __css: styles3.root },
|
3062
3076
|
ref
|
3063
3077
|
}
|
3064
|
-
), label && /* @__PURE__ */
|
3078
|
+
), label && /* @__PURE__ */ React70__default.createElement(FormLabel3, null, label));
|
3065
3079
|
}
|
3066
3080
|
);
|
3067
3081
|
function NumericStepper({
|
@@ -3087,17 +3101,17 @@ function NumericStepper({
|
|
3087
3101
|
});
|
3088
3102
|
const formControlProps = useFormControl({ id: idProp, isDisabled });
|
3089
3103
|
const clampedStepSize = Math.max(Math.min(stepSize, 10), 1);
|
3090
|
-
return /* @__PURE__ */
|
3104
|
+
return /* @__PURE__ */ React70__default.createElement(Flex, { __css: styles3.container, ...boxProps }, /* @__PURE__ */ React70__default.createElement(
|
3091
3105
|
VerySmallButton,
|
3092
3106
|
{
|
3093
|
-
icon: /* @__PURE__ */
|
3107
|
+
icon: /* @__PURE__ */ React70__default.createElement(SubtractIcon, { stepLabel: clampedStepSize }),
|
3094
3108
|
"aria-label": t2(texts12.decrementButtonAriaLabel(clampedStepSize)),
|
3095
3109
|
onClick: () => onChange(Math.max(value - clampedStepSize, minValue)),
|
3096
3110
|
visibility: value <= minValue ? "hidden" : "visible",
|
3097
3111
|
isDisabled: formControlProps.disabled,
|
3098
3112
|
id: value <= minValue ? void 0 : formControlProps.id
|
3099
3113
|
}
|
3100
|
-
), withInput ? /* @__PURE__ */
|
3114
|
+
), withInput ? /* @__PURE__ */ React70__default.createElement(
|
3101
3115
|
chakra.input,
|
3102
3116
|
{
|
3103
3117
|
type: "number",
|
@@ -3120,7 +3134,7 @@ function NumericStepper({
|
|
3120
3134
|
onChange(Math.max(Math.min(numericInput, maxValue), minValue));
|
3121
3135
|
}
|
3122
3136
|
}
|
3123
|
-
) : /* @__PURE__ */
|
3137
|
+
) : /* @__PURE__ */ React70__default.createElement(
|
3124
3138
|
chakra.text,
|
3125
3139
|
{
|
3126
3140
|
sx: styles3.text,
|
@@ -3128,10 +3142,10 @@ function NumericStepper({
|
|
3128
3142
|
"aria-label": value.toString()
|
3129
3143
|
},
|
3130
3144
|
value
|
3131
|
-
), /* @__PURE__ */
|
3145
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3132
3146
|
VerySmallButton,
|
3133
3147
|
{
|
3134
|
-
icon: /* @__PURE__ */
|
3148
|
+
icon: /* @__PURE__ */ React70__default.createElement(AddIcon, { stepLabel: clampedStepSize }),
|
3135
3149
|
"aria-label": t2(texts12.incrementButtonAriaLabel(clampedStepSize)),
|
3136
3150
|
onClick: () => onChange(Math.min(value + clampedStepSize, maxValue)),
|
3137
3151
|
visibility: value >= maxValue ? "hidden" : "visible",
|
@@ -3142,9 +3156,9 @@ function NumericStepper({
|
|
3142
3156
|
}
|
3143
3157
|
var VerySmallButton = (props) => {
|
3144
3158
|
const styles3 = useMultiStyleConfig("NumericStepper", {});
|
3145
|
-
return /* @__PURE__ */
|
3159
|
+
return /* @__PURE__ */ React70__default.createElement(IconButton, { variant: "primary", size: "xs", sx: styles3.button, ...props });
|
3146
3160
|
};
|
3147
|
-
var SubtractIcon = (props) => /* @__PURE__ */
|
3161
|
+
var SubtractIcon = (props) => /* @__PURE__ */ React70__default.createElement(React70__default.Fragment, null, /* @__PURE__ */ React70__default.createElement(
|
3148
3162
|
Box,
|
3149
3163
|
{
|
3150
3164
|
as: "svg",
|
@@ -3154,7 +3168,7 @@ var SubtractIcon = (props) => /* @__PURE__ */ React69__default.createElement(Rea
|
|
3154
3168
|
stroke: "currentColor",
|
3155
3169
|
...props
|
3156
3170
|
},
|
3157
|
-
/* @__PURE__ */
|
3171
|
+
/* @__PURE__ */ React70__default.createElement(
|
3158
3172
|
"line",
|
3159
3173
|
{
|
3160
3174
|
x1: "9",
|
@@ -3165,8 +3179,8 @@ var SubtractIcon = (props) => /* @__PURE__ */ React69__default.createElement(Rea
|
|
3165
3179
|
strokeLinecap: "round"
|
3166
3180
|
}
|
3167
3181
|
)
|
3168
|
-
), props.stepLabel > 1 && /* @__PURE__ */
|
3169
|
-
var AddIcon = (props) => /* @__PURE__ */
|
3182
|
+
), props.stepLabel > 1 && /* @__PURE__ */ React70__default.createElement(chakra.span, { paddingRight: "1" }, props.stepLabel.toString()));
|
3183
|
+
var AddIcon = (props) => /* @__PURE__ */ React70__default.createElement(React70__default.Fragment, null, /* @__PURE__ */ React70__default.createElement(
|
3170
3184
|
Box,
|
3171
3185
|
{
|
3172
3186
|
as: "svg",
|
@@ -3176,7 +3190,7 @@ var AddIcon = (props) => /* @__PURE__ */ React69__default.createElement(React69_
|
|
3176
3190
|
stroke: "currentColor",
|
3177
3191
|
...props
|
3178
3192
|
},
|
3179
|
-
/* @__PURE__ */
|
3193
|
+
/* @__PURE__ */ React70__default.createElement(
|
3180
3194
|
"line",
|
3181
3195
|
{
|
3182
3196
|
x1: "9",
|
@@ -3187,7 +3201,7 @@ var AddIcon = (props) => /* @__PURE__ */ React69__default.createElement(React69_
|
|
3187
3201
|
strokeLinecap: "round"
|
3188
3202
|
}
|
3189
3203
|
),
|
3190
|
-
/* @__PURE__ */
|
3204
|
+
/* @__PURE__ */ React70__default.createElement(
|
3191
3205
|
"line",
|
3192
3206
|
{
|
3193
3207
|
x1: "15",
|
@@ -3198,7 +3212,7 @@ var AddIcon = (props) => /* @__PURE__ */ React69__default.createElement(React69_
|
|
3198
3212
|
strokeLinecap: "round"
|
3199
3213
|
}
|
3200
3214
|
)
|
3201
|
-
), props.stepLabel > 1 && /* @__PURE__ */
|
3215
|
+
), props.stepLabel > 1 && /* @__PURE__ */ React70__default.createElement(chakra.span, { paddingRight: "1" }, props.stepLabel.toString()));
|
3202
3216
|
var texts12 = createTexts({
|
3203
3217
|
decrementButtonAriaLabel(stepSize) {
|
3204
3218
|
return {
|
@@ -3224,7 +3238,7 @@ var PasswordInput = forwardRef(
|
|
3224
3238
|
const formControlProps = useFormControlContext();
|
3225
3239
|
const autoGeneratedId = `password-input-${useId()}`;
|
3226
3240
|
const inputId = id ?? (formControlProps == null ? void 0 : formControlProps.id) ?? autoGeneratedId;
|
3227
|
-
return /* @__PURE__ */
|
3241
|
+
return /* @__PURE__ */ React70__default.createElement(InputGroup, { position: "relative" }, leftIcon && /* @__PURE__ */ React70__default.createElement(InputLeftElement2, null, leftIcon), /* @__PURE__ */ React70__default.createElement(
|
3228
3242
|
Input$1,
|
3229
3243
|
{
|
3230
3244
|
...props,
|
@@ -3236,7 +3250,7 @@ var PasswordInput = forwardRef(
|
|
3236
3250
|
ref,
|
3237
3251
|
"data-attachable": true
|
3238
3252
|
}
|
3239
|
-
), /* @__PURE__ */
|
3253
|
+
), /* @__PURE__ */ React70__default.createElement(FormLabel3, { htmlFor: inputId, pointerEvents: "none" }, label), /* @__PURE__ */ React70__default.createElement(InputRightElement2, { width: "fit-content" }, /* @__PURE__ */ React70__default.createElement(
|
3240
3254
|
Button$1,
|
3241
3255
|
{
|
3242
3256
|
variant: "ghost",
|
@@ -3284,10 +3298,10 @@ var PhoneNumberInput = forwardRef(
|
|
3284
3298
|
nationalNumber: ""
|
3285
3299
|
}
|
3286
3300
|
});
|
3287
|
-
return /* @__PURE__ */
|
3301
|
+
return /* @__PURE__ */ React70__default.createElement(AttachedInputs, { ...boxProps }, /* @__PURE__ */ React70__default.createElement(
|
3288
3302
|
Suspense,
|
3289
3303
|
{
|
3290
|
-
fallback: /* @__PURE__ */
|
3304
|
+
fallback: /* @__PURE__ */ React70__default.createElement(
|
3291
3305
|
InfoSelect,
|
3292
3306
|
{
|
3293
3307
|
isLabelSrOnly: true,
|
@@ -3296,10 +3310,10 @@ var PhoneNumberInput = forwardRef(
|
|
3296
3310
|
height: "100%",
|
3297
3311
|
value: "+47"
|
3298
3312
|
},
|
3299
|
-
/* @__PURE__ */
|
3313
|
+
/* @__PURE__ */ React70__default.createElement(Item, { key: "+47" }, "+47")
|
3300
3314
|
)
|
3301
3315
|
},
|
3302
|
-
/* @__PURE__ */
|
3316
|
+
/* @__PURE__ */ React70__default.createElement(
|
3303
3317
|
LazyCountryCodeSelect,
|
3304
3318
|
{
|
3305
3319
|
value: value.countryCode,
|
@@ -3312,7 +3326,7 @@ var PhoneNumberInput = forwardRef(
|
|
3312
3326
|
width: "6.25rem"
|
3313
3327
|
}
|
3314
3328
|
)
|
3315
|
-
), /* @__PURE__ */
|
3329
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3316
3330
|
Input,
|
3317
3331
|
{
|
3318
3332
|
ref,
|
@@ -3341,13 +3355,13 @@ var texts14 = createTexts({
|
|
3341
3355
|
sv: "Telefonnummer"
|
3342
3356
|
}
|
3343
3357
|
});
|
3344
|
-
var LazyCountryCodeSelect =
|
3358
|
+
var LazyCountryCodeSelect = React70__default.lazy(() => import('./CountryCodeSelect-5QKP6VFT.mjs'));
|
3345
3359
|
var Radio = forwardRef((props, ref) => {
|
3346
|
-
return /* @__PURE__ */
|
3360
|
+
return /* @__PURE__ */ React70__default.createElement(Radio$1, { ...props, ref });
|
3347
3361
|
});
|
3348
3362
|
var RadioGroup = forwardRef(
|
3349
3363
|
({ children, direction: direction2 = "row", ...rest }, ref) => {
|
3350
|
-
return /* @__PURE__ */
|
3364
|
+
return /* @__PURE__ */ React70__default.createElement(RadioGroup$1, { ...rest, ref }, /* @__PURE__ */ React70__default.createElement(Stack$1, { direction: direction2 }, children));
|
3351
3365
|
}
|
3352
3366
|
);
|
3353
3367
|
var SearchInput = forwardRef(
|
@@ -3357,7 +3371,7 @@ var SearchInput = forwardRef(
|
|
3357
3371
|
const formControlProps = useFormControlContext();
|
3358
3372
|
const autoGeneratedId = useId();
|
3359
3373
|
const inputId = props.id ?? (formControlProps == null ? void 0 : formControlProps.id) ?? autoGeneratedId;
|
3360
|
-
return /* @__PURE__ */
|
3374
|
+
return /* @__PURE__ */ React70__default.createElement(InputGroup, { position: "relative" }, /* @__PURE__ */ React70__default.createElement(InputLeftElement2, null, /* @__PURE__ */ React70__default.createElement(SearchOutline24Icon, null)), /* @__PURE__ */ React70__default.createElement(
|
3361
3375
|
Input$1,
|
3362
3376
|
{
|
3363
3377
|
paddingLeft: 7,
|
@@ -3374,7 +3388,7 @@ var SearchInput = forwardRef(
|
|
3374
3388
|
placeholder: " ",
|
3375
3389
|
"data-attachable": true
|
3376
3390
|
}
|
3377
|
-
), /* @__PURE__ */
|
3391
|
+
), /* @__PURE__ */ React70__default.createElement(FormLabel3, { htmlFor: inputId, pointerEvents: "none" }, label ?? t2(texts15.label)), showClearButton && /* @__PURE__ */ React70__default.createElement(InputRightElement2, { width: "fit-content" }, /* @__PURE__ */ React70__default.createElement(
|
3378
3392
|
IconButton$1,
|
3379
3393
|
{
|
3380
3394
|
variant: "ghost",
|
@@ -3382,7 +3396,7 @@ var SearchInput = forwardRef(
|
|
3382
3396
|
size: "sm",
|
3383
3397
|
marginRight: 1,
|
3384
3398
|
"aria-label": t2(texts15.reset),
|
3385
|
-
icon: /* @__PURE__ */
|
3399
|
+
icon: /* @__PURE__ */ React70__default.createElement(CloseOutline24Icon, null),
|
3386
3400
|
onClick: onReset
|
3387
3401
|
}
|
3388
3402
|
)));
|
@@ -3404,7 +3418,7 @@ var texts15 = createTexts({
|
|
3404
3418
|
});
|
3405
3419
|
var Switch = forwardRef(
|
3406
3420
|
({ size: size2 = "md", ...props }, ref) => {
|
3407
|
-
return /* @__PURE__ */
|
3421
|
+
return /* @__PURE__ */ React70__default.createElement(Switch$1, { size: size2, ...props, ref });
|
3408
3422
|
}
|
3409
3423
|
);
|
3410
3424
|
var Textarea = forwardRef((props, ref) => {
|
@@ -3415,7 +3429,7 @@ var Textarea = forwardRef((props, ref) => {
|
|
3415
3429
|
const formControlProps = useFormControlContext();
|
3416
3430
|
const fallbackId = `textarea-${useId()}`;
|
3417
3431
|
const inputId = props.id ?? (formControlProps == null ? void 0 : formControlProps.id) ?? fallbackId;
|
3418
|
-
return /* @__PURE__ */
|
3432
|
+
return /* @__PURE__ */ React70__default.createElement(InputGroup, { position: "relative", ...spacingProps }, /* @__PURE__ */ React70__default.createElement(Textarea$1, { ...rest, id: inputId, ref, placeholder: " " }), label && /* @__PURE__ */ React70__default.createElement(FormLabel, { htmlFor: inputId, id: `${inputId}-label` }, label));
|
3419
3433
|
});
|
3420
3434
|
function getSpacingProps(props) {
|
3421
3435
|
const {
|
@@ -3537,7 +3551,7 @@ var LineIcon = ({
|
|
3537
3551
|
if (!Icon) {
|
3538
3552
|
return null;
|
3539
3553
|
}
|
3540
|
-
return /* @__PURE__ */
|
3554
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { sx: { ...styles3.iconContainer, ...sx }, ...rest }, /* @__PURE__ */ React70__default.createElement(Icon, { sx: styles3.icon }));
|
3541
3555
|
};
|
3542
3556
|
|
3543
3557
|
// src/linjetag/InfoTag.tsx
|
@@ -3553,7 +3567,7 @@ var InfoTag = ({
|
|
3553
3567
|
size: size2,
|
3554
3568
|
...customProps
|
3555
3569
|
});
|
3556
|
-
return /* @__PURE__ */
|
3570
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { sx: styles3.container }, /* @__PURE__ */ React70__default.createElement(
|
3557
3571
|
LineIcon,
|
3558
3572
|
{
|
3559
3573
|
variant,
|
@@ -3561,7 +3575,7 @@ var InfoTag = ({
|
|
3561
3575
|
sx: styles3.iconContainer,
|
3562
3576
|
...customProps
|
3563
3577
|
}
|
3564
|
-
), /* @__PURE__ */
|
3578
|
+
), /* @__PURE__ */ React70__default.createElement(Box, { sx: styles3.textContainer }, title && /* @__PURE__ */ React70__default.createElement(Box, { as: "span", sx: styles3.title }, title), title && description && " ", description && /* @__PURE__ */ React70__default.createElement(Box, { as: "span", sx: styles3.description }, description)));
|
3565
3579
|
};
|
3566
3580
|
var TravelTag = forwardRef(
|
3567
3581
|
({
|
@@ -3581,7 +3595,7 @@ var TravelTag = forwardRef(
|
|
3581
3595
|
backgroundColor: variant === "custom" ? rest.backgroundColor : void 0
|
3582
3596
|
});
|
3583
3597
|
const DeviationLevelIcon = getDeviationLevelIcon({ deviationLevel, size: size2 });
|
3584
|
-
return /* @__PURE__ */
|
3598
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { sx: styles3.container, "aria-disabled": isDisabled, ref, ...rest }, /* @__PURE__ */ React70__default.createElement(
|
3585
3599
|
LineIcon,
|
3586
3600
|
{
|
3587
3601
|
variant,
|
@@ -3589,7 +3603,7 @@ var TravelTag = forwardRef(
|
|
3589
3603
|
sx: styles3.iconContainer,
|
3590
3604
|
...rest
|
3591
3605
|
}
|
3592
|
-
), /* @__PURE__ */
|
3606
|
+
), /* @__PURE__ */ React70__default.createElement(Box, { sx: styles3.textContainer }, title && /* @__PURE__ */ React70__default.createElement(Box, { as: "span", sx: styles3.title }, title), title && description && " ", description && /* @__PURE__ */ React70__default.createElement(Box, { as: "span", sx: styles3.description }, description)), DeviationLevelIcon && /* @__PURE__ */ React70__default.createElement(DeviationLevelIcon, { sx: styles3.deviationIcon }));
|
3593
3607
|
}
|
3594
3608
|
);
|
3595
3609
|
var getDeviationLevelIcon = ({
|
@@ -3613,7 +3627,7 @@ var TextLink = forwardRef(
|
|
3613
3627
|
var _a6;
|
3614
3628
|
const { t: t2 } = useTranslation();
|
3615
3629
|
const isExternal = props.isExternal !== void 0 ? props.isExternal : Boolean((_a6 = props.href) == null ? void 0 : _a6.match(/^https?:\/\//));
|
3616
|
-
return /* @__PURE__ */
|
3630
|
+
return /* @__PURE__ */ React70__default.createElement(Link, { ...props, ref, isExternal }, children, isExternal && /* @__PURE__ */ React70__default.createElement(
|
3617
3631
|
LinkOutOutline24Icon,
|
3618
3632
|
{
|
3619
3633
|
marginLeft: 0.5,
|
@@ -3634,7 +3648,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3634
3648
|
const mainColor = colorScheme === "light" ? "#1d211c" : "#ffffff";
|
3635
3649
|
const accentColor = colorScheme === "light" ? "#138c6e" : "#ffffff";
|
3636
3650
|
const id = useId();
|
3637
|
-
return /* @__PURE__ */
|
3651
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { as: "svg", viewBox: "0 0 107 54", ...boxProps }, /* @__PURE__ */ React70__default.createElement("title", null, "Vy logo"), /* @__PURE__ */ React70__default.createElement(
|
3638
3652
|
"path",
|
3639
3653
|
{
|
3640
3654
|
fillRule: "evenodd",
|
@@ -3642,7 +3656,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3642
3656
|
d: "M79.97 33.44a.04.04 0 0 0 0-.08 5.76 5.76 0 0 1-2.32-.85c-1.56-1-2.79-2.9-3.83-6.07L68.14 7.16c-1.18-4.04-3.42-5.85-5.48-6.6a8.36 8.36 0 0 0-2.88-.52h-1.44a.04.04 0 0 0 0 .08c.57.09 1.18.24 1.8.5 1.92.8 3.92 2.63 5.06 6.54l5.61 19.07c1.06 3.3 2.31 5.27 3.92 6.3 1.01.64 2.17.9 3.5.9h1.74Z",
|
3643
3657
|
fill: mainColor
|
3644
3658
|
}
|
3645
|
-
), /* @__PURE__ */
|
3659
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3646
3660
|
"mask",
|
3647
3661
|
{
|
3648
3662
|
id: `${id}-a`,
|
@@ -3653,7 +3667,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3653
3667
|
width: "94",
|
3654
3668
|
height: "54"
|
3655
3669
|
},
|
3656
|
-
/* @__PURE__ */
|
3670
|
+
/* @__PURE__ */ React70__default.createElement(
|
3657
3671
|
"path",
|
3658
3672
|
{
|
3659
3673
|
fillRule: "evenodd",
|
@@ -3662,7 +3676,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3662
3676
|
fill: mainColor
|
3663
3677
|
}
|
3664
3678
|
)
|
3665
|
-
), /* @__PURE__ */
|
3679
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3666
3680
|
"g",
|
3667
3681
|
{
|
3668
3682
|
mask: `url(#${id}-a)`,
|
@@ -3670,9 +3684,9 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3670
3684
|
clipRule: "evenodd",
|
3671
3685
|
fill: mainColor
|
3672
3686
|
},
|
3673
|
-
/* @__PURE__ */
|
3674
|
-
/* @__PURE__ */
|
3675
|
-
), /* @__PURE__ */
|
3687
|
+
/* @__PURE__ */ React70__default.createElement("path", { d: "M84.57 33.44a.04.04 0 0 0 .01-.08c-2.34-.3-3.85-3.59-4.68-6.38-.88-2.93-4.04-13.63-5.92-19.82C72.08.94 66.2.05 63.54.04a.04.04 0 0 0-.01.08c2.49.34 6.02 1.85 7.55 7.04 1.34 4.55 5.6 19.03 5.76 19.51 1.02 3.03 2.22 4.85 3.73 5.83a6.3 6.3 0 0 0 3.54.94h.46ZM23.28 53.68h-.72c-2.12 0-4.68-1.08-6.09-6.04L3.8 4.37C3.04 1.77 1.93.47.03.15A.04.04 0 0 1 .04.07h1.9c2.54 0 3.92 1.27 4.8 4.3 0 0 11.72 39.78 12.79 43.54.78 2.78 1.7 4.67 3.13 5.43.23.13.42.2.62.26a.04.04 0 0 1 0 .08ZM18.99 5.99C17.77 1.79 15.87.04 12.37.04h-1.71a.04.04 0 0 0 0 .08c2.73.39 4.32 2.19 5.39 5.87 0 0 10.49 35.72 11.85 40.4l1.44-4.87L18.99 6Z" }),
|
3688
|
+
/* @__PURE__ */ React70__default.createElement("path", { d: "M24.26 53.68h1.24c1.57 0 2.69-.41 3.52-1.1 1.37-1.1 1.99-2.93 2.56-4.86.09-.29 11.2-37.95 11.59-39.42 1.32-4.97 4.27-7.13 7.43-7.9a12.2 12.2 0 0 1 1.58-.28.04.04 0 0 0 0-.08h-1.4c-4.15 0-8.8 1.65-10.56 8.26-.63 2.38-11.5 39.13-11.58 39.42-.57 1.93-1.23 3.96-2.59 5.07-.56.45-1.06.7-1.8.81a.04.04 0 0 0 0 .08ZM81.3 27.76l6.53-21.78C88.89 2.3 90.49.5 93.23.11a.04.04 0 0 0-.01-.08H91.5c-3.5 0-5.4 1.76-6.62 5.95l-5.05 16.97s1.33 4.46 1.46 4.8Z" })
|
3689
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3676
3690
|
"path",
|
3677
3691
|
{
|
3678
3692
|
fillRule: "evenodd",
|
@@ -3680,7 +3694,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3680
3694
|
d: "M98.49.07h-1.82c-2.98 0-4.6 1.49-5.63 5.06l-6.52 21.79a18.22 18.22 0 0 1-1.67 3.96c.57.78 1.17 1.26 1.76 1.38 1.13-.96 2.06-2.75 2.89-5.46l6.49-21.67c.9-3.1 2.23-4.63 4.5-4.98a.04.04 0 0 0 0-.08Z",
|
3681
3695
|
fill: accentColor
|
3682
3696
|
}
|
3683
|
-
), /* @__PURE__ */
|
3697
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3684
3698
|
"path",
|
3685
3699
|
{
|
3686
3700
|
fillRule: "evenodd",
|
@@ -3688,7 +3702,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3688
3702
|
d: "M85.25 34.53h-2.93L78.58 46.9c-1.82 6.1 1.05 6.73 2.15 6.73h2.31a.04.04 0 0 0 .01-.09c-1.25-.3-2.96-1.6-1.45-6.64l3.65-12.37ZM102.35.11c.02 0 .03-.02.03-.04a.04.04 0 0 0-.04-.04h-.4c-2.54 0-3.92 1.27-4.8 4.3 0 0-5 16.82-6.57 22.03-1.57 5.2-2.65 6.6-4.78 6.97l-.11.03a.04.04 0 0 0 0 .08h1.45c3.72 0 5.1-2.48 6.41-6.84l7.5-25.07c.19-.6.7-1.23 1.31-1.42Z",
|
3689
3703
|
fill: mainColor
|
3690
3704
|
}
|
3691
|
-
), /* @__PURE__ */
|
3705
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3692
3706
|
"mask",
|
3693
3707
|
{
|
3694
3708
|
id: `${id}-b`,
|
@@ -3699,7 +3713,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3699
3713
|
width: "78",
|
3700
3714
|
height: "54"
|
3701
3715
|
},
|
3702
|
-
/* @__PURE__ */
|
3716
|
+
/* @__PURE__ */ React70__default.createElement(
|
3703
3717
|
"path",
|
3704
3718
|
{
|
3705
3719
|
fillRule: "evenodd",
|
@@ -3708,25 +3722,25 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3708
3722
|
fill: mainColor
|
3709
3723
|
}
|
3710
3724
|
)
|
3711
|
-
), /* @__PURE__ */
|
3725
|
+
), /* @__PURE__ */ React70__default.createElement("g", { mask: `url(#${id}-b)`, fillRule: "evenodd", clipRule: "evenodd" }, /* @__PURE__ */ React70__default.createElement(
|
3712
3726
|
"path",
|
3713
3727
|
{
|
3714
3728
|
d: "m88.2 34.45-3.96 13.46c-1.54 5.18.9 5.72 1.83 5.72h2.26a.04.04 0 0 0 0-.09c-1.05-.27-2.44-1.4-1.18-5.63l4.43-15.02c-.7.71-1.88 1.37-3.38 1.56ZM93.71 53.63c.02 0 .04-.02.04-.05a.04.04 0 0 0-.03-.04c-.9-.25-2.02-1.24-.96-4.77 0 0 12.4-42.2 13.08-44.6a3.1 3.1 0 0 0-2.47-4.1c-.02 0-.06-.02-.07.01-.01.04.03.06.04.06.3.16.63.52.45 1.14L89.84 48.77c-1.32 4.4.76 4.86 1.55 4.86h2.32ZM74.1 33.44a.04.04 0 0 0 0-.08 5.77 5.77 0 0 1-2.3-.83c-1.64-1.04-2.9-3.06-3.98-6.5-.1-.29-5.37-18.25-5.55-18.87-1.12-3.8-2.91-5.63-4.68-6.46a7.06 7.06 0 0 0-3.04-.66H53a.04.04 0 0 0-.02.08c.3.05 4.32.17 6.35 7.04 2.03 6.86 4.46 15.07 5.28 17.97 1.77 6.26 4.07 8.3 7.75 8.3h1.73Z",
|
3715
3729
|
fill: mainColor
|
3716
3730
|
}
|
3717
|
-
), /* @__PURE__ */
|
3731
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3718
3732
|
"path",
|
3719
3733
|
{
|
3720
3734
|
d: "M55.43 2.4c-1.48 1.27-2.7 3.16-3.44 5.9-.07.29-11.08 37.74-11.32 38.55-.93 3.12-1.7 6.21-5.2 6.75a.04.04 0 0 0 0 .08h.7l.6-.01c3.56-.14 5.33-1.66 6.85-6.82L54.94 8.3c.44-1.44.96-3.08 1.7-4.52-.15-.25-.7-.96-1.2-1.38Z",
|
3721
3735
|
fill: mainColor
|
3722
3736
|
}
|
3723
|
-
), /* @__PURE__ */
|
3737
|
+
), /* @__PURE__ */ React70__default.createElement(
|
3724
3738
|
"path",
|
3725
3739
|
{
|
3726
3740
|
d: "M53.78 1.44a4.64 4.64 0 0 0-4.17.93A10.79 10.79 0 0 0 46.19 8L34.53 47.72c-.58 1.93-1.2 3.75-2.56 4.87-.62.5-1.4.86-2.39 1.01a.04.04 0 0 0 0 .08h1.8c1.57 0 2.69-.41 3.53-1.1 1.36-1.1 1.98-2.93 2.56-4.86L49.05 8.3c.73-2.74 1.95-4.63 3.43-5.9.43-.36.88-.68 1.35-.95l-.05-.01Z",
|
3727
3741
|
fill: accentColor
|
3728
3742
|
}
|
3729
|
-
)), /* @__PURE__ */
|
3743
|
+
)), /* @__PURE__ */ React70__default.createElement(
|
3730
3744
|
"path",
|
3731
3745
|
{
|
3732
3746
|
fillRule: "evenodd",
|
@@ -3736,7 +3750,7 @@ var VyLogo = ({ colorScheme, ...boxProps }) => {
|
|
3736
3750
|
}
|
3737
3751
|
));
|
3738
3752
|
};
|
3739
|
-
var JumpForwardIcon = (props) => /* @__PURE__ */
|
3753
|
+
var JumpForwardIcon = (props) => /* @__PURE__ */ React70.createElement(Box, { as: "svg", ...props, viewBox: "0 0 32 30", fill: "none" }, /* @__PURE__ */ React70.createElement(
|
3740
3754
|
"path",
|
3741
3755
|
{
|
3742
3756
|
fillRule: "evenodd",
|
@@ -3744,7 +3758,7 @@ var JumpForwardIcon = (props) => /* @__PURE__ */ React69.createElement(Box, { as
|
|
3744
3758
|
d: "M22.388 7.5C20.567 5.967 18.251 5 15.75 5 9.951 5 5.25 9.701 5.25 15.5S9.951 26 15.75 26s10.5-4.701 10.5-10.5a1 1 0 1 1 2 0c0 6.904-5.596 12.5-12.5 12.5s-12.5-5.596-12.5-12.5S8.846 3 15.75 3c3.206 0 6.11 1.31 8.304 3.3l.206-1.441a1 1 0 0 1 1.98.282L25.617 9.5H21.25a1 1 0 1 1 0-2h1.138Z",
|
3745
3759
|
fill: "currentColor"
|
3746
3760
|
}
|
3747
|
-
), /* @__PURE__ */
|
3761
|
+
), /* @__PURE__ */ React70.createElement(
|
3748
3762
|
"path",
|
3749
3763
|
{
|
3750
3764
|
fillRule: "evenodd",
|
@@ -3753,7 +3767,7 @@ var JumpForwardIcon = (props) => /* @__PURE__ */ React69.createElement(Box, { as
|
|
3753
3767
|
fill: "currentColor"
|
3754
3768
|
}
|
3755
3769
|
));
|
3756
|
-
var JumpBackwardIcon = (props) => /* @__PURE__ */
|
3770
|
+
var JumpBackwardIcon = (props) => /* @__PURE__ */ React70.createElement(Box, { as: "svg", ...props, viewBox: "0 0 32 30", fill: "none" }, /* @__PURE__ */ React70.createElement(
|
3757
3771
|
"path",
|
3758
3772
|
{
|
3759
3773
|
fillRule: "evenodd",
|
@@ -3761,7 +3775,7 @@ var JumpBackwardIcon = (props) => /* @__PURE__ */ React69.createElement(Box, { a
|
|
3761
3775
|
d: "M9.612 7.5C11.433 5.967 13.749 5 16.25 5c5.799 0 10.5 4.701 10.5 10.5S22.049 26 16.25 26s-10.5-4.701-10.5-10.5a1 1 0 1 0-2 0c0 6.904 5.596 12.5 12.5 12.5s12.5-5.596 12.5-12.5S23.154 3 16.25 3c-3.206 0-6.11 1.31-8.304 3.3L7.74 4.86a1 1 0 0 0-1.98.282L6.383 9.5h4.367a1 1 0 1 0 0-2H9.612Z",
|
3762
3776
|
fill: "currentColor"
|
3763
3777
|
}
|
3764
|
-
), /* @__PURE__ */
|
3778
|
+
), /* @__PURE__ */ React70.createElement(
|
3765
3779
|
"path",
|
3766
3780
|
{
|
3767
3781
|
fillRule: "evenodd",
|
@@ -3770,7 +3784,7 @@ var JumpBackwardIcon = (props) => /* @__PURE__ */ React69.createElement(Box, { a
|
|
3770
3784
|
fill: "currentColor"
|
3771
3785
|
}
|
3772
3786
|
));
|
3773
|
-
var PlayIcon = (props) => /* @__PURE__ */
|
3787
|
+
var PlayIcon = (props) => /* @__PURE__ */ React70.createElement(Box, { as: "svg", ...props, fill: "none", viewBox: "0 0 60 60" }, /* @__PURE__ */ React70.createElement(
|
3774
3788
|
"path",
|
3775
3789
|
{
|
3776
3790
|
fillRule: "evenodd",
|
@@ -3779,7 +3793,7 @@ var PlayIcon = (props) => /* @__PURE__ */ React69.createElement(Box, { as: "svg"
|
|
3779
3793
|
fill: "currentColor"
|
3780
3794
|
}
|
3781
3795
|
));
|
3782
|
-
var PauseIcon = (props) => /* @__PURE__ */
|
3796
|
+
var PauseIcon = (props) => /* @__PURE__ */ React70.createElement(Box, { as: "svg", ...props, viewBox: "0 0 60 60", fill: "none" }, /* @__PURE__ */ React70.createElement(
|
3783
3797
|
"path",
|
3784
3798
|
{
|
3785
3799
|
fillRule: "evenodd",
|
@@ -3788,7 +3802,7 @@ var PauseIcon = (props) => /* @__PURE__ */ React69.createElement(Box, { as: "svg
|
|
3788
3802
|
fill: "currentColor"
|
3789
3803
|
}
|
3790
3804
|
));
|
3791
|
-
var SkipNextIcon = (props) => /* @__PURE__ */
|
3805
|
+
var SkipNextIcon = (props) => /* @__PURE__ */ React70.createElement(Box, { as: "svg", ...props, viewBox: "0 0 30 30", fill: "none" }, /* @__PURE__ */ React70.createElement(
|
3792
3806
|
"path",
|
3793
3807
|
{
|
3794
3808
|
fillRule: "evenodd",
|
@@ -3797,7 +3811,7 @@ var SkipNextIcon = (props) => /* @__PURE__ */ React69.createElement(Box, { as: "
|
|
3797
3811
|
fill: "currentColor"
|
3798
3812
|
}
|
3799
3813
|
));
|
3800
|
-
var SkipPreviousIcon = (props) => /* @__PURE__ */
|
3814
|
+
var SkipPreviousIcon = (props) => /* @__PURE__ */ React70.createElement(Box, { as: "svg", ...props, viewBox: "0 0 30 30", fill: "none" }, /* @__PURE__ */ React70.createElement(
|
3801
3815
|
"path",
|
3802
3816
|
{
|
3803
3817
|
fillRule: "evenodd",
|
@@ -3819,7 +3833,7 @@ var JumpButton = ({
|
|
3819
3833
|
variant: "jumpSkip",
|
3820
3834
|
size: size2
|
3821
3835
|
});
|
3822
|
-
return /* @__PURE__ */
|
3836
|
+
return /* @__PURE__ */ React70__default.createElement(
|
3823
3837
|
Center,
|
3824
3838
|
{
|
3825
3839
|
as: "button",
|
@@ -3828,7 +3842,7 @@ var JumpButton = ({
|
|
3828
3842
|
disabled: isDisabled,
|
3829
3843
|
...props
|
3830
3844
|
},
|
3831
|
-
direction2 === "forward" ? /* @__PURE__ */
|
3845
|
+
direction2 === "forward" ? /* @__PURE__ */ React70__default.createElement(JumpForwardIcon, { sx: styles3.icon }) : /* @__PURE__ */ React70__default.createElement(JumpBackwardIcon, { sx: styles3.icon })
|
3832
3846
|
);
|
3833
3847
|
};
|
3834
3848
|
var texts17 = createTexts({
|
@@ -3856,7 +3870,7 @@ var PlayPauseButton = ({
|
|
3856
3870
|
variant: "play",
|
3857
3871
|
size: size2
|
3858
3872
|
});
|
3859
|
-
return /* @__PURE__ */
|
3873
|
+
return /* @__PURE__ */ React70__default.createElement(
|
3860
3874
|
Center,
|
3861
3875
|
{
|
3862
3876
|
as: "button",
|
@@ -3865,7 +3879,7 @@ var PlayPauseButton = ({
|
|
3865
3879
|
disabled: isDisabled,
|
3866
3880
|
...props
|
3867
3881
|
},
|
3868
|
-
isPlaying ? /* @__PURE__ */
|
3882
|
+
isPlaying ? /* @__PURE__ */ React70__default.createElement(PauseIcon, { sx: styles3.icon }) : /* @__PURE__ */ React70__default.createElement(PlayIcon, { sx: styles3.icon })
|
3869
3883
|
);
|
3870
3884
|
};
|
3871
3885
|
var texts18 = createTexts({
|
@@ -3893,7 +3907,7 @@ var SkipButton = ({
|
|
3893
3907
|
variant: "jumpSkip",
|
3894
3908
|
size: size2
|
3895
3909
|
});
|
3896
|
-
return /* @__PURE__ */
|
3910
|
+
return /* @__PURE__ */ React70__default.createElement(
|
3897
3911
|
Center,
|
3898
3912
|
{
|
3899
3913
|
as: "button",
|
@@ -3902,7 +3916,7 @@ var SkipButton = ({
|
|
3902
3916
|
disabled: isDisabled,
|
3903
3917
|
...props
|
3904
3918
|
},
|
3905
|
-
direction2 === "forward" ? /* @__PURE__ */
|
3919
|
+
direction2 === "forward" ? /* @__PURE__ */ React70__default.createElement(SkipNextIcon, { sx: styles3.icon }) : /* @__PURE__ */ React70__default.createElement(SkipPreviousIcon, { sx: styles3.icon })
|
3906
3920
|
);
|
3907
3921
|
};
|
3908
3922
|
var texts19 = createTexts({
|
@@ -3925,13 +3939,13 @@ var ModalHeader = forwardRef(
|
|
3925
3939
|
fontSize: size2 === "lg" ? ["mobile.lg", "desktop.lg"] : ["mobile.md", "desktop.md"],
|
3926
3940
|
textAlign: size2 === "lg" ? "center" : "left"
|
3927
3941
|
};
|
3928
|
-
return /* @__PURE__ */
|
3942
|
+
return /* @__PURE__ */ React70__default.createElement(ModalHeader$1, { ...props, ref, ...styles3 });
|
3929
3943
|
}
|
3930
3944
|
);
|
3931
3945
|
|
3932
3946
|
// src/modal/Drawer.tsx
|
3933
3947
|
var Drawer = (props) => {
|
3934
|
-
return /* @__PURE__ */
|
3948
|
+
return /* @__PURE__ */ React70__default.createElement(DrawerProvider, { placement: props.placement }, /* @__PURE__ */ React70__default.createElement(Drawer$1, { ...props }));
|
3935
3949
|
};
|
3936
3950
|
var DrawerContent = forwardRef(
|
3937
3951
|
({ children, ...props }, ref) => {
|
@@ -3948,7 +3962,7 @@ var DrawerContent = forwardRef(
|
|
3948
3962
|
});
|
3949
3963
|
const isTopOrBottom = placement === "top" || placement === "bottom";
|
3950
3964
|
const widthConstraits = isTopOrBottom ? { width: ["100%", "37.5rem"], mx: "auto" } : {};
|
3951
|
-
return /* @__PURE__ */
|
3965
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...handlers }, /* @__PURE__ */ React70__default.createElement(
|
3952
3966
|
DrawerContent$1,
|
3953
3967
|
{
|
3954
3968
|
...widthConstraits,
|
@@ -3957,13 +3971,13 @@ var DrawerContent = forwardRef(
|
|
3957
3971
|
...props,
|
3958
3972
|
ref
|
3959
3973
|
},
|
3960
|
-
/* @__PURE__ */
|
3974
|
+
/* @__PURE__ */ React70__default.createElement(Box, { position: "relative" }, /* @__PURE__ */ React70__default.createElement(Box, { maxHeight: "100vh", maxWidth: "100vw", overflow: "auto" }, isTopOrBottom && /* @__PURE__ */ React70__default.createElement(Notch, null), /* @__PURE__ */ React70__default.createElement(Box, null, children)))
|
3961
3975
|
));
|
3962
3976
|
}
|
3963
3977
|
);
|
3964
3978
|
var Notch = forwardRef((props, ref) => {
|
3965
3979
|
const placement = useDrawerContext();
|
3966
|
-
return /* @__PURE__ */
|
3980
|
+
return /* @__PURE__ */ React70__default.createElement(
|
3967
3981
|
Box,
|
3968
3982
|
{
|
3969
3983
|
position: "absolute",
|
@@ -3975,14 +3989,14 @@ var Notch = forwardRef((props, ref) => {
|
|
3975
3989
|
...props,
|
3976
3990
|
ref
|
3977
3991
|
},
|
3978
|
-
/* @__PURE__ */
|
3992
|
+
/* @__PURE__ */ React70__default.createElement(
|
3979
3993
|
Center,
|
3980
3994
|
{
|
3981
3995
|
background: placement === "bottom" ? "bottom" : "top",
|
3982
3996
|
padding: 2,
|
3983
3997
|
borderRadius: "md"
|
3984
3998
|
},
|
3985
|
-
/* @__PURE__ */
|
3999
|
+
/* @__PURE__ */ React70__default.createElement(
|
3986
4000
|
Box,
|
3987
4001
|
{
|
3988
4002
|
width: "2.265rem",
|
@@ -3994,18 +4008,137 @@ var Notch = forwardRef((props, ref) => {
|
|
3994
4008
|
)
|
3995
4009
|
);
|
3996
4010
|
});
|
3997
|
-
var DrawerContext =
|
3998
|
-
var DrawerProvider = (props) => /* @__PURE__ */
|
4011
|
+
var DrawerContext = React70__default.createContext(void 0);
|
4012
|
+
var DrawerProvider = (props) => /* @__PURE__ */ React70__default.createElement(DrawerContext.Provider, { value: props.placement }, props.children);
|
3999
4013
|
var useDrawerContext = () => {
|
4000
|
-
return
|
4014
|
+
return React70__default.useContext(DrawerContext);
|
4015
|
+
};
|
4016
|
+
var FullScreenDrawer = ({
|
4017
|
+
children,
|
4018
|
+
title,
|
4019
|
+
placement = "bottom",
|
4020
|
+
leftButton = null,
|
4021
|
+
rightButton = /* @__PURE__ */ React70__default.createElement(DrawerCloseButton2, null),
|
4022
|
+
isOpen,
|
4023
|
+
onClose
|
4024
|
+
}) => {
|
4025
|
+
const [isContentBoxScrolled, setContentBoxScrolled] = useState(false);
|
4026
|
+
const onContentScroll = (e) => {
|
4027
|
+
const target = e.target;
|
4028
|
+
if (target.scrollTop <= 0) {
|
4029
|
+
setContentBoxScrolled(false);
|
4030
|
+
return;
|
4031
|
+
}
|
4032
|
+
setContentBoxScrolled(true);
|
4033
|
+
};
|
4034
|
+
useEffect(() => {
|
4035
|
+
setContentBoxScrolled(false);
|
4036
|
+
}, [isOpen]);
|
4037
|
+
return /* @__PURE__ */ React70__default.createElement(Drawer, { isOpen, onClose, placement, size: "full" }, /* @__PURE__ */ React70__default.createElement(DrawerOverlay, null), /* @__PURE__ */ React70__default.createElement(
|
4038
|
+
DrawerContent$1,
|
4039
|
+
{
|
4040
|
+
height: "100vh",
|
4041
|
+
backgroundSize: "100% 285px, 100%",
|
4042
|
+
backgroundPosition: "top",
|
4043
|
+
backgroundRepeat: "no-repeat"
|
4044
|
+
},
|
4045
|
+
/* @__PURE__ */ React70__default.createElement(
|
4046
|
+
DrawerTopMenu,
|
4047
|
+
{
|
4048
|
+
isScrolled: isContentBoxScrolled,
|
4049
|
+
title,
|
4050
|
+
leftButton,
|
4051
|
+
rightButton
|
4052
|
+
}
|
4053
|
+
),
|
4054
|
+
/* @__PURE__ */ React70__default.createElement(DrawerBody, { overflow: "auto", onScroll: onContentScroll }, children)
|
4055
|
+
));
|
4056
|
+
};
|
4057
|
+
var DrawerTopMenu = ({
|
4058
|
+
title,
|
4059
|
+
leftButton,
|
4060
|
+
rightButton,
|
4061
|
+
isScrolled
|
4062
|
+
}) => {
|
4063
|
+
const backgroundColor = useColorModeValue(
|
4064
|
+
"bg.default.light",
|
4065
|
+
"bg.default.dark"
|
4066
|
+
);
|
4067
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4068
|
+
Flex,
|
4069
|
+
{
|
4070
|
+
width: "100%",
|
4071
|
+
backgroundColor,
|
4072
|
+
position: "static",
|
4073
|
+
paddingTop: [1.5, 2.5, 3, 3],
|
4074
|
+
paddingBottom: [1.5, 2.5, 3, 3],
|
4075
|
+
paddingLeft: [2, 3, 6, 9],
|
4076
|
+
paddingRight: [2, 3, 6, 9],
|
4077
|
+
transition: "box-shadow 0.2s",
|
4078
|
+
boxShadow: isScrolled ? "md" : void 0
|
4079
|
+
},
|
4080
|
+
/* @__PURE__ */ React70__default.createElement(Box, { flex: "1" }, leftButton),
|
4081
|
+
/* @__PURE__ */ React70__default.createElement(
|
4082
|
+
DrawerHeader,
|
4083
|
+
{
|
4084
|
+
as: "h2",
|
4085
|
+
fontSize: "md",
|
4086
|
+
fontWeight: "bold",
|
4087
|
+
textAlign: "center",
|
4088
|
+
flex: "1",
|
4089
|
+
margin: 0,
|
4090
|
+
padding: 0
|
4091
|
+
},
|
4092
|
+
title
|
4093
|
+
),
|
4094
|
+
/* @__PURE__ */ React70__default.createElement(Box, { flex: "1" }, /* @__PURE__ */ React70__default.createElement(Box, { width: "fit-content", marginLeft: "auto" }, rightButton))
|
4095
|
+
);
|
4096
|
+
};
|
4097
|
+
var DrawerCloseButton2 = () => {
|
4098
|
+
const { onClose } = useModalContext();
|
4099
|
+
const { t: t2 } = useTranslation();
|
4100
|
+
const [isScreenSizeMinSm] = useMediaQuery(
|
4101
|
+
`(min-width: ${tokens11__default.size.breakpoint.sm})`
|
4102
|
+
);
|
4103
|
+
if (isScreenSizeMinSm) {
|
4104
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4105
|
+
Button,
|
4106
|
+
{
|
4107
|
+
variant: "ghost",
|
4108
|
+
leftIcon: /* @__PURE__ */ React70__default.createElement(CloseFill24Icon, null),
|
4109
|
+
onClick: onClose,
|
4110
|
+
"aria-label": t2(texts20.close),
|
4111
|
+
width: "fit-content",
|
4112
|
+
marginLeft: "auto"
|
4113
|
+
},
|
4114
|
+
t2(texts20.close)
|
4115
|
+
);
|
4116
|
+
}
|
4117
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4118
|
+
IconButton,
|
4119
|
+
{
|
4120
|
+
variant: "ghost",
|
4121
|
+
icon: /* @__PURE__ */ React70__default.createElement(CloseFill30Icon, null),
|
4122
|
+
onClick: onClose,
|
4123
|
+
"aria-label": t2(texts20.close)
|
4124
|
+
}
|
4125
|
+
);
|
4001
4126
|
};
|
4127
|
+
var texts20 = createTexts({
|
4128
|
+
close: {
|
4129
|
+
nb: "Lukk",
|
4130
|
+
nn: "Lukk",
|
4131
|
+
en: "Close",
|
4132
|
+
sv: "St\xE4ng"
|
4133
|
+
}
|
4134
|
+
});
|
4002
4135
|
var SimpleDrawer = ({
|
4003
4136
|
placement,
|
4004
4137
|
children,
|
4005
4138
|
title,
|
4006
4139
|
...props
|
4007
4140
|
}) => {
|
4008
|
-
return /* @__PURE__ */
|
4141
|
+
return /* @__PURE__ */ React70__default.createElement(Drawer, { placement, ...props }, /* @__PURE__ */ React70__default.createElement(DrawerOverlay, null), /* @__PURE__ */ React70__default.createElement(DrawerContent, null, /* @__PURE__ */ React70__default.createElement(DrawerCloseButton, null), title && /* @__PURE__ */ React70__default.createElement(ModalHeader, null, title), /* @__PURE__ */ React70__default.createElement(DrawerBody, null, children)));
|
4009
4142
|
};
|
4010
4143
|
var EXPIRATION_DELAY = 1e3 * 60 * 60 * 24 * 30;
|
4011
4144
|
var Nudge = ({
|
@@ -4027,7 +4160,7 @@ var Nudge = ({
|
|
4027
4160
|
}
|
4028
4161
|
return null;
|
4029
4162
|
}
|
4030
|
-
return /* @__PURE__ */
|
4163
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4031
4164
|
Popover,
|
4032
4165
|
{
|
4033
4166
|
arrowSize: 12,
|
@@ -4035,11 +4168,11 @@ var Nudge = ({
|
|
4035
4168
|
defaultIsOpen: true,
|
4036
4169
|
...props
|
4037
4170
|
},
|
4038
|
-
/* @__PURE__ */
|
4039
|
-
/* @__PURE__ */
|
4171
|
+
/* @__PURE__ */ React70__default.createElement(PopoverAnchor, null, children),
|
4172
|
+
/* @__PURE__ */ React70__default.createElement(PopoverContent, { borderRadius: "sm" }, /* @__PURE__ */ React70__default.createElement(DarkMode, null, /* @__PURE__ */ React70__default.createElement(PopoverArrow, null), /* @__PURE__ */ React70__default.createElement(PopoverCloseButton, null), /* @__PURE__ */ React70__default.createElement(PopoverBody, { margin: 1 }, /* @__PURE__ */ React70__default.createElement(Box, { marginRight: 4 }, content), /* @__PURE__ */ React70__default.createElement(Box, { marginTop: 1.5 }, actions ?? /* @__PURE__ */ React70__default.createElement(ButtonGroup, null, /* @__PURE__ */ React70__default.createElement(Button, { variant: "tertiary", size: "xs" }, t2(texts21.close)), /* @__PURE__ */ React70__default.createElement(Button, { variant: "secondary", size: "xs", fontWeight: "bold" }, t2(texts21.showMe)))))))
|
4040
4173
|
);
|
4041
4174
|
};
|
4042
|
-
var
|
4175
|
+
var texts21 = createTexts({
|
4043
4176
|
close: {
|
4044
4177
|
nb: "Lukk",
|
4045
4178
|
nn: "Lukk",
|
@@ -4064,19 +4197,19 @@ var WizardNudge = ({
|
|
4064
4197
|
const totalSteps = content.length;
|
4065
4198
|
const isLastStep = totalSteps === currentStep;
|
4066
4199
|
const onNext = () => setCurrentStep((prev) => prev + 1);
|
4067
|
-
return /* @__PURE__ */
|
4200
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4068
4201
|
Nudge,
|
4069
4202
|
{
|
4070
4203
|
onClose,
|
4071
4204
|
name,
|
4072
4205
|
content: content[currentStep - 1],
|
4073
|
-
actions: /* @__PURE__ */
|
4206
|
+
actions: /* @__PURE__ */ React70__default.createElement(Flex, { gap: 3, alignItems: "center" }, /* @__PURE__ */ React70__default.createElement(
|
4074
4207
|
ProgressIndicator,
|
4075
4208
|
{
|
4076
4209
|
activeStep: currentStep,
|
4077
4210
|
numberOfSteps: totalSteps
|
4078
4211
|
}
|
4079
|
-
), /* @__PURE__ */
|
4212
|
+
), /* @__PURE__ */ React70__default.createElement(Box, null, /* @__PURE__ */ React70__default.createElement(NextOrCloseButton, { isLastStep, onNext }))),
|
4080
4213
|
...props
|
4081
4214
|
},
|
4082
4215
|
children
|
@@ -4085,19 +4218,19 @@ var WizardNudge = ({
|
|
4085
4218
|
var NextOrCloseButton = ({ isLastStep, onNext }) => {
|
4086
4219
|
const { onClose } = usePopoverContext();
|
4087
4220
|
const { t: t2 } = useTranslation();
|
4088
|
-
return /* @__PURE__ */
|
4221
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4089
4222
|
Button,
|
4090
4223
|
{
|
4091
4224
|
variant: "tertiary",
|
4092
4225
|
size: "xs",
|
4093
|
-
leftIcon: isLastStep ? void 0 : /* @__PURE__ */
|
4226
|
+
leftIcon: isLastStep ? void 0 : /* @__PURE__ */ React70__default.createElement(ArrowRightFill18Icon, null),
|
4094
4227
|
onClick: isLastStep ? onClose : onNext,
|
4095
4228
|
width: "fit-content"
|
4096
4229
|
},
|
4097
|
-
t2(isLastStep ?
|
4230
|
+
t2(isLastStep ? texts22.finish : texts22.nextStep)
|
4098
4231
|
);
|
4099
4232
|
};
|
4100
|
-
var
|
4233
|
+
var texts22 = createTexts({
|
4101
4234
|
nextStep: {
|
4102
4235
|
nb: "Neste",
|
4103
4236
|
nn: "Neste",
|
@@ -4113,7 +4246,7 @@ var texts21 = createTexts({
|
|
4113
4246
|
});
|
4114
4247
|
var ProgressDot = ({ isActive }) => {
|
4115
4248
|
const style = useMultiStyleConfig("ProgressIndicator");
|
4116
|
-
return /* @__PURE__ */
|
4249
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4117
4250
|
Box,
|
4118
4251
|
{
|
4119
4252
|
as: "svg",
|
@@ -4123,7 +4256,7 @@ var ProgressDot = ({ isActive }) => {
|
|
4123
4256
|
viewBox: "0 0 100 100",
|
4124
4257
|
"aria-current": isActive ? "step" : void 0
|
4125
4258
|
},
|
4126
|
-
/* @__PURE__ */
|
4259
|
+
/* @__PURE__ */ React70__default.createElement(Box, { as: "circle", cx: "50", cy: "50", r: "50" })
|
4127
4260
|
);
|
4128
4261
|
};
|
4129
4262
|
|
@@ -4134,7 +4267,7 @@ var ProgressIndicator = ({
|
|
4134
4267
|
}) => {
|
4135
4268
|
const { t: t2 } = useTranslation();
|
4136
4269
|
const style = useMultiStyleConfig("ProgressIndicator");
|
4137
|
-
return /* @__PURE__ */
|
4270
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4138
4271
|
Box,
|
4139
4272
|
{
|
4140
4273
|
__css: style.root,
|
@@ -4142,9 +4275,9 @@ var ProgressIndicator = ({
|
|
4142
4275
|
"aria-valuemin": 1,
|
4143
4276
|
"aria-valuemax": numberOfSteps,
|
4144
4277
|
"aria-valuenow": activeStep,
|
4145
|
-
"aria-valuetext": t2(
|
4278
|
+
"aria-valuetext": t2(texts23.stepsOf(activeStep, numberOfSteps))
|
4146
4279
|
},
|
4147
|
-
/* @__PURE__ */
|
4280
|
+
/* @__PURE__ */ React70__default.createElement(Box, { __css: style.container }, Array.from({ length: numberOfSteps }, (_, i) => /* @__PURE__ */ React70__default.createElement(
|
4148
4281
|
ProgressDot,
|
4149
4282
|
{
|
4150
4283
|
key: i,
|
@@ -4154,7 +4287,7 @@ var ProgressIndicator = ({
|
|
4154
4287
|
)))
|
4155
4288
|
);
|
4156
4289
|
};
|
4157
|
-
var
|
4290
|
+
var texts23 = createTexts({
|
4158
4291
|
stepsOf: (activeStep, numberOfSteps) => ({
|
4159
4292
|
nb: `Steg ${activeStep} av ${numberOfSteps}`,
|
4160
4293
|
nn: `Steg ${activeStep} av ${numberOfSteps}`,
|
@@ -4171,9 +4304,9 @@ var SporProvider = ({
|
|
4171
4304
|
}) => {
|
4172
4305
|
const brandCustomizations = brandTheme[brand] ?? {};
|
4173
4306
|
const extendedTheme = deepmerge(theme3, brandCustomizations);
|
4174
|
-
return /* @__PURE__ */
|
4307
|
+
return /* @__PURE__ */ React70__default.createElement(LanguageProvider, { language }, /* @__PURE__ */ React70__default.createElement(ChakraProvider, { theme: extendedTheme, ...props }, /* @__PURE__ */ React70__default.createElement(Global, { styles: fontFaces }), children));
|
4175
4308
|
};
|
4176
|
-
var StepperContext =
|
4309
|
+
var StepperContext = React70__default.createContext(null);
|
4177
4310
|
var StepperProvider = ({
|
4178
4311
|
activeStep,
|
4179
4312
|
children,
|
@@ -4181,7 +4314,7 @@ var StepperProvider = ({
|
|
4181
4314
|
numberOfSteps,
|
4182
4315
|
variant
|
4183
4316
|
}) => {
|
4184
|
-
return /* @__PURE__ */
|
4317
|
+
return /* @__PURE__ */ React70__default.createElement(
|
4185
4318
|
StepperContext.Provider,
|
4186
4319
|
{
|
4187
4320
|
value: { activeStep, onClick, numberOfSteps, variant }
|
@@ -4190,7 +4323,7 @@ var StepperProvider = ({
|
|
4190
4323
|
);
|
4191
4324
|
};
|
4192
4325
|
var useStepper = () => {
|
4193
|
-
const context =
|
4326
|
+
const context = React70__default.useContext(StepperContext);
|
4194
4327
|
if (!context) {
|
4195
4328
|
throw new Error(
|
4196
4329
|
"useStepper must be used within a StepperProvider. Most likely, you forgot to wrap your StepperStep in a Stepper component"
|
@@ -4218,7 +4351,7 @@ var Stepper = ({
|
|
4218
4351
|
const { t: t2 } = useTranslation();
|
4219
4352
|
const hideBackButtonOnFirstStep = activeStep === 1 && !onBackButtonClick;
|
4220
4353
|
const shownHeading = heading || title;
|
4221
|
-
return /* @__PURE__ */
|
4354
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { sx: style.root }, /* @__PURE__ */ React70__default.createElement(
|
4222
4355
|
StepperProvider,
|
4223
4356
|
{
|
4224
4357
|
onClick,
|
@@ -4226,7 +4359,7 @@ var Stepper = ({
|
|
4226
4359
|
variant,
|
4227
4360
|
numberOfSteps
|
4228
4361
|
},
|
4229
|
-
/* @__PURE__ */
|
4362
|
+
/* @__PURE__ */ React70__default.createElement(Box, { sx: style.container }, /* @__PURE__ */ React70__default.createElement(Box, { sx: style.innerContainer }, /* @__PURE__ */ React70__default.createElement(
|
4230
4363
|
Flex,
|
4231
4364
|
{
|
4232
4365
|
justifyContent: "space-between",
|
@@ -4234,11 +4367,11 @@ var Stepper = ({
|
|
4234
4367
|
gap: 2,
|
4235
4368
|
flex: 1
|
4236
4369
|
},
|
4237
|
-
/* @__PURE__ */
|
4370
|
+
/* @__PURE__ */ React70__default.createElement(
|
4238
4371
|
IconButton,
|
4239
4372
|
{
|
4240
|
-
"aria-label": t2(
|
4241
|
-
icon: /* @__PURE__ */
|
4373
|
+
"aria-label": t2(texts24.back),
|
4374
|
+
icon: /* @__PURE__ */ React70__default.createElement(ArrowLeftFill24Icon, null),
|
4242
4375
|
variant: "ghost",
|
4243
4376
|
size: "sm",
|
4244
4377
|
visibility: hideBackButtonOnFirstStep ? "hidden" : "visible",
|
@@ -4251,9 +4384,9 @@ var Stepper = ({
|
|
4251
4384
|
}
|
4252
4385
|
}
|
4253
4386
|
),
|
4254
|
-
shownHeading && /* @__PURE__ */
|
4255
|
-
/* @__PURE__ */
|
4256
|
-
)), /* @__PURE__ */
|
4387
|
+
shownHeading && /* @__PURE__ */ React70__default.createElement(Text4, { flex: 1, variant: "sm", as: headingLevel, sx: style.title }, shownHeading),
|
4388
|
+
/* @__PURE__ */ React70__default.createElement(Box, { sx: style.stepCounter }, t2(texts24.stepsOf(activeStep, numberOfSteps)))
|
4389
|
+
)), /* @__PURE__ */ React70__default.createElement(Flex, { justifyContent: "center", display: ["none", null, "flex"] }, steps.map((step, index) => /* @__PURE__ */ React70__default.createElement(
|
4257
4390
|
StepperStep,
|
4258
4391
|
{
|
4259
4392
|
key: index,
|
@@ -4266,7 +4399,7 @@ var Stepper = ({
|
|
4266
4399
|
))))
|
4267
4400
|
));
|
4268
4401
|
};
|
4269
|
-
var
|
4402
|
+
var texts24 = createTexts({
|
4270
4403
|
stepsOf: (activeStep, numberOfSteps) => ({
|
4271
4404
|
nb: `Steg ${activeStep}/${numberOfSteps}`,
|
4272
4405
|
nn: `Steg ${activeStep}/${numberOfSteps}`,
|
@@ -4298,14 +4431,14 @@ var StepperStep = ({
|
|
4298
4431
|
);
|
4299
4432
|
const iconColor = useColorModeValue("blackAlpha.200", "whiteAlpha.200");
|
4300
4433
|
const isDisabled = state2 !== "active" && isDisabledOverride || state2 === "disabled";
|
4301
|
-
return /* @__PURE__ */
|
4434
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { sx: style.stepContainer }, stepNumber > 1 && /* @__PURE__ */ React70__default.createElement(
|
4302
4435
|
DropdownRightFill18Icon,
|
4303
4436
|
{
|
4304
4437
|
marginX: 5,
|
4305
4438
|
display: ["none", null, "block"],
|
4306
4439
|
color: iconColor
|
4307
4440
|
}
|
4308
|
-
), isDisabled ? /* @__PURE__ */
|
4441
|
+
), isDisabled ? /* @__PURE__ */ React70__default.createElement(
|
4309
4442
|
Text4,
|
4310
4443
|
{
|
4311
4444
|
variant: "xs",
|
@@ -4315,7 +4448,7 @@ var StepperStep = ({
|
|
4315
4448
|
paddingX: 2
|
4316
4449
|
},
|
4317
4450
|
children
|
4318
|
-
) : /* @__PURE__ */
|
4451
|
+
) : /* @__PURE__ */ React70__default.createElement(
|
4319
4452
|
Button,
|
4320
4453
|
{
|
4321
4454
|
size: "xs",
|
@@ -4338,11 +4471,11 @@ var getState = (stepNumber, activeStep) => {
|
|
4338
4471
|
return "disabled";
|
4339
4472
|
};
|
4340
4473
|
var Tabs = forwardRef((props, ref) => {
|
4341
|
-
return /* @__PURE__ */
|
4474
|
+
return /* @__PURE__ */ React70.createElement(Tabs$1, { ...props, ref });
|
4342
4475
|
});
|
4343
4476
|
var Table = forwardRef((props, ref) => {
|
4344
4477
|
const { variant, size: size2, colorScheme, children, ...rest } = props;
|
4345
|
-
return /* @__PURE__ */
|
4478
|
+
return /* @__PURE__ */ React70__default.createElement(Box, { ...rest, ...getStyleProps(props) }, /* @__PURE__ */ React70__default.createElement(Box, { overflowX: "auto" }, /* @__PURE__ */ React70__default.createElement(
|
4346
4479
|
Table$1,
|
4347
4480
|
{
|
4348
4481
|
variant,
|
@@ -6158,16 +6291,16 @@ Object.assign({}, space, layout, flexbox, grid, position);
|
|
6158
6291
|
function defineStyle(styles3) {
|
6159
6292
|
return styles3;
|
6160
6293
|
}
|
6161
|
-
function defineStyleConfig(
|
6162
|
-
return
|
6294
|
+
function defineStyleConfig(config42) {
|
6295
|
+
return config42;
|
6163
6296
|
}
|
6164
6297
|
function createMultiStyleConfigHelpers(parts18) {
|
6165
6298
|
return {
|
6166
|
-
definePartsStyle(
|
6167
|
-
return
|
6299
|
+
definePartsStyle(config42) {
|
6300
|
+
return config42;
|
6168
6301
|
},
|
6169
|
-
defineMultiStyleConfig(
|
6170
|
-
return { parts: parts18, ...
|
6302
|
+
defineMultiStyleConfig(config42) {
|
6303
|
+
return { parts: parts18, ...config42 };
|
6171
6304
|
}
|
6172
6305
|
};
|
6173
6306
|
}
|
@@ -9456,6 +9589,7 @@ __export(components_exports, {
|
|
9456
9589
|
Radio: () => radio_default,
|
9457
9590
|
Select: () => select_default,
|
9458
9591
|
Skeleton: () => skeleton_default,
|
9592
|
+
StaticCard: () => static_card_default,
|
9459
9593
|
Stepper: () => stepper_default,
|
9460
9594
|
Switch: () => switch_default,
|
9461
9595
|
Table: () => table_default,
|
@@ -9552,7 +9686,7 @@ function baseBackground(state2, props) {
|
|
9552
9686
|
return surface("disabled", props);
|
9553
9687
|
case "hover":
|
9554
9688
|
default:
|
9555
|
-
return
|
9689
|
+
return { backgroundColor: "transparent" };
|
9556
9690
|
}
|
9557
9691
|
}
|
9558
9692
|
function baseBorder(state2, props) {
|
@@ -10211,7 +10345,6 @@ var config6 = defineStyleConfig$1({
|
|
10211
10345
|
},
|
10212
10346
|
_active: {
|
10213
10347
|
...baseBorder("default", props),
|
10214
|
-
// We want a
|
10215
10348
|
...baseBackground("active", props)
|
10216
10349
|
}
|
10217
10350
|
}),
|
@@ -10299,26 +10432,26 @@ __export(foundations_exports, {
|
|
10299
10432
|
});
|
10300
10433
|
var borders2 = {
|
10301
10434
|
none: "0",
|
10302
|
-
sm: `${
|
10303
|
-
"sm-dashed": `${
|
10304
|
-
md: `${
|
10305
|
-
"md-dashed": `${
|
10306
|
-
lg: `${
|
10307
|
-
"lg-dashed": `${
|
10435
|
+
sm: `${tokens11__default.size.stroke.sm} solid`,
|
10436
|
+
"sm-dashed": `${tokens11__default.size.stroke.sm} dashed`,
|
10437
|
+
md: `${tokens11__default.size.stroke.md} solid`,
|
10438
|
+
"md-dashed": `${tokens11__default.size.stroke.md} dashed`,
|
10439
|
+
lg: `${tokens11__default.size.stroke.lg} solid`,
|
10440
|
+
"lg-dashed": `${tokens11__default.size.stroke.lg} dashed`
|
10308
10441
|
};
|
10309
10442
|
var breakpoints2 = {
|
10310
10443
|
base: "0px",
|
10311
|
-
sm:
|
10312
|
-
md:
|
10313
|
-
lg:
|
10314
|
-
xl:
|
10315
|
-
"2xl":
|
10444
|
+
sm: tokens11__default.size.breakpoint.sm,
|
10445
|
+
md: tokens11__default.size.breakpoint.md,
|
10446
|
+
lg: tokens11__default.size.breakpoint.lg,
|
10447
|
+
xl: tokens11__default.size.breakpoint.xl,
|
10448
|
+
"2xl": tokens11__default.size.breakpoint.xl
|
10316
10449
|
};
|
10317
10450
|
var colors2 = {
|
10318
|
-
...
|
10319
|
-
...
|
10320
|
-
...
|
10321
|
-
linjetag:
|
10451
|
+
...tokens11__default.color.alias,
|
10452
|
+
...tokens11__default.color.palette,
|
10453
|
+
...tokens11__default.color.vyDigital,
|
10454
|
+
linjetag: tokens11__default.color.linjetag
|
10322
10455
|
};
|
10323
10456
|
|
10324
10457
|
// src/theme/foundations/config.ts
|
@@ -10328,34 +10461,34 @@ var config7 = {
|
|
10328
10461
|
useSystemColorMode: false
|
10329
10462
|
};
|
10330
10463
|
var fonts = {
|
10331
|
-
body: `${
|
10332
|
-
heading: `${
|
10333
|
-
mono: `${
|
10464
|
+
body: `${tokens11__default.font.family.body}, arial, sans-serif`,
|
10465
|
+
heading: `${tokens11__default.font.family.heading}, arial, sans-serif`,
|
10466
|
+
mono: `${tokens11__default.font.family.monospace}, monospace`
|
10334
10467
|
};
|
10335
10468
|
var fontSizes = {
|
10336
|
-
"2xs":
|
10337
|
-
xs:
|
10338
|
-
sm:
|
10339
|
-
md:
|
10340
|
-
lg:
|
10341
|
-
xl:
|
10342
|
-
"2xl":
|
10343
|
-
"3xl":
|
10469
|
+
"2xs": tokens11__default.size.font.xs.mobile,
|
10470
|
+
xs: tokens11__default.size.font.sm.mobile,
|
10471
|
+
sm: tokens11__default.size.font.md.mobile,
|
10472
|
+
md: tokens11__default.size.font.lg.mobile,
|
10473
|
+
lg: tokens11__default.size.font.xl.mobile,
|
10474
|
+
xl: tokens11__default.size.font.xxl.mobile,
|
10475
|
+
"2xl": tokens11__default.size.font.xl.desktop,
|
10476
|
+
"3xl": tokens11__default.size.font.xxl.desktop,
|
10344
10477
|
mobile: {
|
10345
|
-
xs:
|
10346
|
-
sm:
|
10347
|
-
md:
|
10348
|
-
lg:
|
10349
|
-
xl:
|
10350
|
-
xxl:
|
10478
|
+
xs: tokens11__default.size.font.xs.mobile,
|
10479
|
+
sm: tokens11__default.size.font.sm.mobile,
|
10480
|
+
md: tokens11__default.size.font.md.mobile,
|
10481
|
+
lg: tokens11__default.size.font.lg.mobile,
|
10482
|
+
xl: tokens11__default.size.font.xl.mobile,
|
10483
|
+
xxl: tokens11__default.size.font.xxl.mobile
|
10351
10484
|
},
|
10352
10485
|
desktop: {
|
10353
|
-
xs:
|
10354
|
-
sm:
|
10355
|
-
md:
|
10356
|
-
lg:
|
10357
|
-
xl:
|
10358
|
-
xxl:
|
10486
|
+
xs: tokens11__default.size.font.xs.desktop,
|
10487
|
+
sm: tokens11__default.size.font.sm.desktop,
|
10488
|
+
md: tokens11__default.size.font.md.desktop,
|
10489
|
+
lg: tokens11__default.size.font.lg.desktop,
|
10490
|
+
xl: tokens11__default.size.font.xl.desktop,
|
10491
|
+
xxl: tokens11__default.size.font.xxl.desktop
|
10359
10492
|
}
|
10360
10493
|
};
|
10361
10494
|
|
@@ -10366,28 +10499,28 @@ var fontWeights = {
|
|
10366
10499
|
bold: 700
|
10367
10500
|
};
|
10368
10501
|
var lineHeights = {
|
10369
|
-
base:
|
10370
|
-
normal:
|
10502
|
+
base: tokens11__default.font.style.lg["line-height"],
|
10503
|
+
normal: tokens11__default.font.style.lg["line-height"]
|
10371
10504
|
};
|
10372
10505
|
var radii2 = {
|
10373
|
-
none:
|
10374
|
-
xs:
|
10375
|
-
sm:
|
10376
|
-
md:
|
10377
|
-
lg:
|
10378
|
-
xl:
|
10379
|
-
"2xl":
|
10506
|
+
none: tokens11__default.size["border-radius"].none,
|
10507
|
+
xs: tokens11__default.size["border-radius"].xs,
|
10508
|
+
sm: tokens11__default.size["border-radius"].sm,
|
10509
|
+
md: tokens11__default.size["border-radius"].md,
|
10510
|
+
lg: tokens11__default.size["border-radius"].lg,
|
10511
|
+
xl: tokens11__default.size["border-radius"].xl,
|
10512
|
+
"2xl": tokens11__default.size["border-radius"]["2xl"],
|
10380
10513
|
round: "50%"
|
10381
10514
|
};
|
10382
10515
|
var shadows2 = {
|
10383
10516
|
none: "none",
|
10384
|
-
sm:
|
10385
|
-
md:
|
10386
|
-
lg:
|
10517
|
+
sm: tokens11__default.depth.shadow.sm.value,
|
10518
|
+
md: tokens11__default.depth.shadow.md.value,
|
10519
|
+
lg: tokens11__default.depth.shadow.lg.value
|
10387
10520
|
};
|
10388
|
-
var spacing2 = Object.entries(
|
10389
|
-
(
|
10390
|
-
...
|
10521
|
+
var spacing2 = Object.entries(tokens11__default.size.spacing).reduce(
|
10522
|
+
(tokens16, [key, token]) => ({
|
10523
|
+
...tokens16,
|
10391
10524
|
[Number(key)]: token
|
10392
10525
|
}),
|
10393
10526
|
{}
|
@@ -10428,89 +10561,89 @@ var sizes24 = {
|
|
10428
10561
|
var textStyles = {
|
10429
10562
|
"2xl": {
|
10430
10563
|
fontSize: [
|
10431
|
-
|
10564
|
+
tokens11__default.font.style.xxl["font-size"].mobile,
|
10432
10565
|
null,
|
10433
10566
|
null,
|
10434
|
-
|
10567
|
+
tokens11__default.font.style.xxl["font-size"].desktop
|
10435
10568
|
],
|
10436
|
-
fontFamily:
|
10437
|
-
lineHeight:
|
10569
|
+
fontFamily: tokens11__default.font.style.xxl["font-family"],
|
10570
|
+
lineHeight: tokens11__default.font.style.xxl["line-height"]
|
10438
10571
|
},
|
10439
10572
|
"xl-display": {
|
10440
10573
|
fontSize: [
|
10441
|
-
|
10574
|
+
tokens11__default.font.style["xl-display"]["font-size"].mobile,
|
10442
10575
|
null,
|
10443
10576
|
null,
|
10444
|
-
|
10577
|
+
tokens11__default.font.style["xl-display"]["font-size"].desktop
|
10445
10578
|
],
|
10446
|
-
fontFamily:
|
10447
|
-
lineHeight:
|
10579
|
+
fontFamily: tokens11__default.font.style["xl-display"]["font-family"],
|
10580
|
+
lineHeight: tokens11__default.font.style["xl-display"]["line-height"]
|
10448
10581
|
},
|
10449
10582
|
"xl-sans": {
|
10450
10583
|
fontSize: [
|
10451
|
-
|
10584
|
+
tokens11__default.font.style["xl-sans"]["font-size"].mobile,
|
10452
10585
|
null,
|
10453
10586
|
null,
|
10454
|
-
|
10587
|
+
tokens11__default.font.style["xl-sans"]["font-size"].desktop
|
10455
10588
|
],
|
10456
|
-
fontFamily:
|
10457
|
-
lineHeight:
|
10589
|
+
fontFamily: tokens11__default.font.style["xl-sans"]["font-family"],
|
10590
|
+
lineHeight: tokens11__default.font.style["xl-sans"]["line-height"]
|
10458
10591
|
},
|
10459
10592
|
lg: {
|
10460
10593
|
fontSize: [
|
10461
|
-
|
10594
|
+
tokens11__default.font.style.lg["font-size"].mobile,
|
10462
10595
|
null,
|
10463
10596
|
null,
|
10464
|
-
|
10597
|
+
tokens11__default.font.style.lg["font-size"].desktop
|
10465
10598
|
],
|
10466
|
-
fontFamily:
|
10467
|
-
lineHeight:
|
10599
|
+
fontFamily: tokens11__default.font.style.lg["font-family"],
|
10600
|
+
lineHeight: tokens11__default.font.style.lg["line-height"]
|
10468
10601
|
},
|
10469
10602
|
md: {
|
10470
10603
|
fontSize: [
|
10471
|
-
|
10604
|
+
tokens11__default.font.style.md["font-size"].mobile,
|
10472
10605
|
null,
|
10473
10606
|
null,
|
10474
|
-
|
10607
|
+
tokens11__default.font.style.md["font-size"].desktop
|
10475
10608
|
],
|
10476
|
-
fontFamily:
|
10477
|
-
lineHeight:
|
10609
|
+
fontFamily: tokens11__default.font.style.md["font-family"],
|
10610
|
+
lineHeight: tokens11__default.font.style.md["line-height"]
|
10478
10611
|
},
|
10479
10612
|
sm: {
|
10480
10613
|
fontSize: [
|
10481
|
-
|
10614
|
+
tokens11__default.font.style.sm["font-size"].mobile,
|
10482
10615
|
null,
|
10483
10616
|
null,
|
10484
|
-
|
10617
|
+
tokens11__default.font.style.sm["font-size"].desktop
|
10485
10618
|
],
|
10486
|
-
fontFamily:
|
10487
|
-
lineHeight:
|
10619
|
+
fontFamily: tokens11__default.font.style.sm["font-family"],
|
10620
|
+
lineHeight: tokens11__default.font.style.sm["line-height"]
|
10488
10621
|
},
|
10489
10622
|
xs: {
|
10490
10623
|
fontSize: [
|
10491
|
-
|
10624
|
+
tokens11__default.font.style.xs["font-size"].mobile,
|
10492
10625
|
null,
|
10493
10626
|
null,
|
10494
|
-
|
10627
|
+
tokens11__default.font.style.xs["font-size"].desktop
|
10495
10628
|
],
|
10496
|
-
fontFamily:
|
10497
|
-
lineHeight:
|
10629
|
+
fontFamily: tokens11__default.font.style.xs["font-family"],
|
10630
|
+
lineHeight: tokens11__default.font.style.xs["line-height"]
|
10498
10631
|
}
|
10499
10632
|
};
|
10500
10633
|
var zIndices2 = {
|
10501
|
-
hide:
|
10634
|
+
hide: tokens11__default.depth["z-index"].hide,
|
10502
10635
|
auto: "auto",
|
10503
|
-
base:
|
10504
|
-
docked:
|
10505
|
-
dropdown:
|
10506
|
-
sticky:
|
10507
|
-
banner:
|
10508
|
-
overlay:
|
10509
|
-
modal:
|
10510
|
-
popover:
|
10511
|
-
skipLink:
|
10512
|
-
toast:
|
10513
|
-
tooltip:
|
10636
|
+
base: tokens11__default.depth["z-index"].base,
|
10637
|
+
docked: tokens11__default.depth["z-index"].docked,
|
10638
|
+
dropdown: tokens11__default.depth["z-index"].dropdown,
|
10639
|
+
sticky: tokens11__default.depth["z-index"].sticky,
|
10640
|
+
banner: tokens11__default.depth["z-index"].banner,
|
10641
|
+
overlay: tokens11__default.depth["z-index"].overlay,
|
10642
|
+
modal: tokens11__default.depth["z-index"].modal,
|
10643
|
+
popover: tokens11__default.depth["z-index"].popover,
|
10644
|
+
skipLink: tokens11__default.depth["z-index"].skipLink,
|
10645
|
+
toast: tokens11__default.depth["z-index"].toast,
|
10646
|
+
tooltip: tokens11__default.depth["z-index"].tooltip
|
10514
10647
|
};
|
10515
10648
|
var styles2 = {
|
10516
10649
|
global: (props) => ({
|
@@ -10904,13 +11037,11 @@ var config11 = helpers6.defineMultiStyleConfig({
|
|
10904
11037
|
variants: {
|
10905
11038
|
base: (props) => ({
|
10906
11039
|
container: {
|
10907
|
-
...baseBackground("default", props),
|
10908
11040
|
...baseBorder("default", props),
|
10909
11041
|
...baseText("default", props),
|
10910
11042
|
_hover: {
|
10911
11043
|
...baseText("default", props),
|
10912
|
-
...baseBorder("hover", props)
|
10913
|
-
...baseBackground("hover", props)
|
11044
|
+
...baseBorder("hover", props)
|
10914
11045
|
},
|
10915
11046
|
_active: {
|
10916
11047
|
...baseBackground("active", props),
|
@@ -11201,6 +11332,7 @@ var config14 = helpers7.defineMultiStyleConfig({
|
|
11201
11332
|
}),
|
11202
11333
|
floating: (props) => ({
|
11203
11334
|
wrapper: {
|
11335
|
+
...floatingBackground("default", props),
|
11204
11336
|
...floatingBorder("default", props),
|
11205
11337
|
boxShadow: "sm",
|
11206
11338
|
_hover: {
|
@@ -11888,7 +12020,6 @@ var config22 = helpers14.defineMultiStyleConfig({
|
|
11888
12020
|
width: "100%",
|
11889
12021
|
outline: "none",
|
11890
12022
|
border: 0,
|
11891
|
-
...baseBackground("default", props),
|
11892
12023
|
borderRadius: "sm",
|
11893
12024
|
transitionProperty: "common",
|
11894
12025
|
transitionDuration: "fast",
|
@@ -11896,6 +12027,7 @@ var config22 = helpers14.defineMultiStyleConfig({
|
|
11896
12027
|
paddingX: 3,
|
11897
12028
|
height: "54px",
|
11898
12029
|
fontSize: "mobile.md",
|
12030
|
+
...baseBackground("default", props),
|
11899
12031
|
...baseBorder("default", props),
|
11900
12032
|
_hover: {
|
11901
12033
|
...baseBorder("hover", props)
|
@@ -12390,8 +12522,8 @@ var config28 = helpers19.defineMultiStyleConfig({
|
|
12390
12522
|
textAlign: "center",
|
12391
12523
|
transitionProperty: "common",
|
12392
12524
|
transitionDuration: "fast",
|
12393
|
-
...baseBackground("default", props),
|
12394
12525
|
...baseText("default", props),
|
12526
|
+
...baseBackground("default", props),
|
12395
12527
|
_disabled: {
|
12396
12528
|
pointerEvents: "none",
|
12397
12529
|
opacity: 0.5
|
@@ -12637,9 +12769,7 @@ var config33 = helpers24.defineMultiStyleConfig({
|
|
12637
12769
|
...input_default.baseStyle(props).field,
|
12638
12770
|
appearance: "none",
|
12639
12771
|
paddingTop: "16px",
|
12640
|
-
"option, optgroup": {
|
12641
|
-
background: "white"
|
12642
|
-
}
|
12772
|
+
"option, optgroup": {}
|
12643
12773
|
},
|
12644
12774
|
icon: {
|
12645
12775
|
width: "30px",
|
@@ -12789,17 +12919,17 @@ var config36 = helpers26.defineMultiStyleConfig({
|
|
12789
12919
|
height: [$height3.reference],
|
12790
12920
|
transitionProperty: "common",
|
12791
12921
|
transitionDuration: "fast",
|
12792
|
-
...baseBackground("default", props),
|
12793
12922
|
...baseBorder("default", props),
|
12794
12923
|
...focusVisibleStyles(props),
|
12924
|
+
...baseBackground("default", props),
|
12795
12925
|
_hover: {
|
12796
|
-
...baseBackground("hover", props),
|
12797
12926
|
...baseBorder("hover", props)
|
12798
12927
|
},
|
12799
12928
|
_checked: {
|
12800
12929
|
...brandBackground("default", props),
|
12801
12930
|
outlineColor: "transparent",
|
12802
12931
|
_hover: {
|
12932
|
+
...baseBackground("default", props),
|
12803
12933
|
...brandBackground("hover", props)
|
12804
12934
|
}
|
12805
12935
|
},
|
@@ -13190,9 +13320,55 @@ var config40 = defineStyleConfig$1({
|
|
13190
13320
|
}
|
13191
13321
|
});
|
13192
13322
|
var toast_default = config40;
|
13323
|
+
var config41 = defineStyleConfig$1({
|
13324
|
+
baseStyle: (props) => ({
|
13325
|
+
appearance: "none",
|
13326
|
+
border: "none",
|
13327
|
+
overflow: "hidden",
|
13328
|
+
fontSize: "inherit",
|
13329
|
+
display: "block",
|
13330
|
+
borderRadius: "md",
|
13331
|
+
// Except for white cards, all cards are light mode always
|
13332
|
+
color: "text.default.light",
|
13333
|
+
...getColorSchemeBaseProps2(props)
|
13334
|
+
})
|
13335
|
+
});
|
13336
|
+
var static_card_default = config41;
|
13337
|
+
var getColorSchemeBaseProps2 = (props) => {
|
13338
|
+
var _a6;
|
13339
|
+
switch (props.colorScheme) {
|
13340
|
+
case "white":
|
13341
|
+
return {
|
13342
|
+
...baseBorder("default", props),
|
13343
|
+
backgroundColor: mode(
|
13344
|
+
"white",
|
13345
|
+
`color-mix(in srgb, white 10%, var(--spor-colors-bg-default-dark))`
|
13346
|
+
)(props),
|
13347
|
+
color: "inherit"
|
13348
|
+
};
|
13349
|
+
case "grey":
|
13350
|
+
return {
|
13351
|
+
backgroundColor: "lightGrey"
|
13352
|
+
};
|
13353
|
+
case "green": {
|
13354
|
+
return {
|
13355
|
+
backgroundColor: "seaMist"
|
13356
|
+
};
|
13357
|
+
}
|
13358
|
+
case "red": {
|
13359
|
+
return {
|
13360
|
+
backgroundColor: "pink"
|
13361
|
+
};
|
13362
|
+
}
|
13363
|
+
default:
|
13364
|
+
return {
|
13365
|
+
backgroundColor: ((_a6 = colors2[props.colorScheme]) == null ? void 0 : _a6[100]) ?? "platinum"
|
13366
|
+
};
|
13367
|
+
}
|
13368
|
+
};
|
13193
13369
|
var fontFaces = `
|
13194
13370
|
@font-face {
|
13195
|
-
font-family: ${
|
13371
|
+
font-family: ${tokens11__default.asset.font["vy-sans"]["light"].name};
|
13196
13372
|
src: url("https://www.vy.no/styles/font/VySans-Light.woff2") format("woff2"),
|
13197
13373
|
url("https://www.vy.no/styles/font/VySans-Light.woff") format("woff");
|
13198
13374
|
font-style: normal;
|
@@ -13200,7 +13376,7 @@ var fontFaces = `
|
|
13200
13376
|
font-display: swap
|
13201
13377
|
}
|
13202
13378
|
@font-face {
|
13203
|
-
font-family: ${
|
13379
|
+
font-family: ${tokens11__default.asset.font["vy-sans"]["light-italic"].name};
|
13204
13380
|
src: url("https://www.vy.no/styles/font/VySans-LightItalic.woff2")
|
13205
13381
|
format("woff2"),
|
13206
13382
|
url("https://www.vy.no/styles/font/VySans-LightItalic.woff") format("woff");
|
@@ -13209,7 +13385,7 @@ var fontFaces = `
|
|
13209
13385
|
font-display: swap
|
13210
13386
|
}
|
13211
13387
|
@font-face {
|
13212
|
-
font-family: ${
|
13388
|
+
font-family: ${tokens11__default.asset.font["vy-sans"]["medium"].name};
|
13213
13389
|
src: url("https://www.vy.no/styles/font/VySans-Regular.woff2") format("woff2"),
|
13214
13390
|
url("https://www.vy.no/styles/font/VySans-Regular.woff") format("woff");
|
13215
13391
|
font-style: normal;
|
@@ -13217,7 +13393,7 @@ var fontFaces = `
|
|
13217
13393
|
font-display: swap
|
13218
13394
|
}
|
13219
13395
|
@font-face {
|
13220
|
-
font-family: ${
|
13396
|
+
font-family: ${tokens11__default.asset.font["vy-sans"]["medium-italic"].name};
|
13221
13397
|
src: url("https://www.vy.no/styles/font/VySans-RegularItalic.woff2")
|
13222
13398
|
format("woff2"),
|
13223
13399
|
url("https://www.vy.no/styles/font/VySans-RegularItalic.woff")
|
@@ -13227,7 +13403,7 @@ var fontFaces = `
|
|
13227
13403
|
font-display: swap
|
13228
13404
|
}
|
13229
13405
|
@font-face {
|
13230
|
-
font-family: ${
|
13406
|
+
font-family: ${tokens11__default.asset.font["vy-sans"]["bold"].name};
|
13231
13407
|
src: url("https://www.vy.no/styles/font/VySans-Bold.woff2") format("woff2"),
|
13232
13408
|
url("https://www.vy.no/styles/font/VySans-Bold.woff") format("woff");
|
13233
13409
|
font-style: normal;
|
@@ -13235,7 +13411,7 @@ var fontFaces = `
|
|
13235
13411
|
font-display: swap
|
13236
13412
|
}
|
13237
13413
|
@font-face {
|
13238
|
-
font-family: ${
|
13414
|
+
font-family: ${tokens11__default.asset.font["vy-sans"]["bold-italic"].name};
|
13239
13415
|
src: url("https://www.vy.no/styles/font/VySans-BoldItalic.woff2")
|
13240
13416
|
format("woff2"),
|
13241
13417
|
url("https://www.vy.no/styles/font/VySans-BoldItalic.woff") format("woff");
|
@@ -13244,7 +13420,7 @@ var fontFaces = `
|
|
13244
13420
|
font-display: swap
|
13245
13421
|
}
|
13246
13422
|
@font-face {
|
13247
|
-
font-family: ${
|
13423
|
+
font-family: ${tokens11__default.asset.font["vy-display"].name};
|
13248
13424
|
src: url("https://www.vy.no/styles/font/VyDisplay-Medium.woff2")
|
13249
13425
|
format("woff2"),
|
13250
13426
|
url("https://www.vy.no/styles/font/VyDisplay-Medium.woff") format("woff");
|
@@ -13286,21 +13462,21 @@ var brandTheme = {
|
|
13286
13462
|
}
|
13287
13463
|
},
|
13288
13464
|
["CargoNet" /* CargoNet */]: {
|
13289
|
-
colors:
|
13465
|
+
colors: tokens11__default.color.cargonet
|
13290
13466
|
}
|
13291
13467
|
};
|
13292
13468
|
var BaseToast = ({ children, variant, id }) => {
|
13293
13469
|
const styles3 = useStyleConfig("Toast", { variant });
|
13294
|
-
return /* @__PURE__ */
|
13470
|
+
return /* @__PURE__ */ React70__default.createElement(Flex, { sx: styles3, id }, /* @__PURE__ */ React70__default.createElement(ToastIcon, { variant }), children);
|
13295
13471
|
};
|
13296
13472
|
var ToastIcon = ({ variant }) => {
|
13297
13473
|
const Icon = getIcon3(variant);
|
13298
13474
|
const { t: t2 } = useTranslation();
|
13299
|
-
return /* @__PURE__ */
|
13475
|
+
return /* @__PURE__ */ React70__default.createElement(
|
13300
13476
|
Icon,
|
13301
13477
|
{
|
13302
13478
|
flexShrink: 0,
|
13303
|
-
"aria-label": t2(
|
13479
|
+
"aria-label": t2(texts25[variant]),
|
13304
13480
|
marginRight: 1,
|
13305
13481
|
marginY: 1.5,
|
13306
13482
|
color: "darkGrey"
|
@@ -13317,7 +13493,7 @@ var getIcon3 = (variant) => {
|
|
13317
13493
|
return ErrorOutline24Icon;
|
13318
13494
|
}
|
13319
13495
|
};
|
13320
|
-
var
|
13496
|
+
var texts25 = createTexts({
|
13321
13497
|
info: {
|
13322
13498
|
nb: "Informasjon",
|
13323
13499
|
nn: "Informasjon",
|
@@ -13346,7 +13522,7 @@ var ActionToast = ({
|
|
13346
13522
|
buttonText,
|
13347
13523
|
id
|
13348
13524
|
}) => {
|
13349
|
-
return /* @__PURE__ */
|
13525
|
+
return /* @__PURE__ */ React70__default.createElement(BaseToast, { variant, id }, /* @__PURE__ */ React70__default.createElement(Box, { marginRight: 2, flexGrow: "1" }, children), /* @__PURE__ */ React70__default.createElement(Button, { variant: "tertiary", size: "sm", onClick }, buttonText));
|
13350
13526
|
};
|
13351
13527
|
var ClosableToast = ({
|
13352
13528
|
children,
|
@@ -13356,18 +13532,18 @@ var ClosableToast = ({
|
|
13356
13532
|
}) => {
|
13357
13533
|
const styles3 = useMultiStyleConfig("Toast", { variant });
|
13358
13534
|
const { t: t2 } = useTranslation();
|
13359
|
-
return /* @__PURE__ */
|
13535
|
+
return /* @__PURE__ */ React70__default.createElement(BaseToast, { variant, id }, /* @__PURE__ */ React70__default.createElement(Box, { flexGrow: "1" }, children), /* @__PURE__ */ React70__default.createElement(
|
13360
13536
|
IconButton,
|
13361
13537
|
{
|
13362
13538
|
sx: styles3.dismissButton,
|
13363
13539
|
variant: "ghost",
|
13364
|
-
"aria-label": t2(
|
13365
|
-
icon: /* @__PURE__ */
|
13540
|
+
"aria-label": t2(texts26.dismiss),
|
13541
|
+
icon: /* @__PURE__ */ React70__default.createElement(CloseFill18Icon, null),
|
13366
13542
|
onClick: onClose
|
13367
13543
|
}
|
13368
13544
|
));
|
13369
13545
|
};
|
13370
|
-
var
|
13546
|
+
var texts26 = createTexts({
|
13371
13547
|
dismiss: {
|
13372
13548
|
nb: "Lukk",
|
13373
13549
|
nn: "Lukk",
|
@@ -13390,7 +13566,7 @@ var useToast = () => {
|
|
13390
13566
|
};
|
13391
13567
|
var getToastComponent = (opts) => {
|
13392
13568
|
if ("isClosable" in opts && opts.isClosable) {
|
13393
|
-
return ({ onClose, id }) => /* @__PURE__ */
|
13569
|
+
return ({ onClose, id }) => /* @__PURE__ */ React70__default.createElement(
|
13394
13570
|
ClosableToast,
|
13395
13571
|
{
|
13396
13572
|
id,
|
@@ -13406,7 +13582,7 @@ var getToastComponent = (opts) => {
|
|
13406
13582
|
);
|
13407
13583
|
}
|
13408
13584
|
if ("buttonText" in opts) {
|
13409
|
-
return ({ id }) => /* @__PURE__ */
|
13585
|
+
return ({ id }) => /* @__PURE__ */ React70__default.createElement(
|
13410
13586
|
ActionToast,
|
13411
13587
|
{
|
13412
13588
|
id,
|
@@ -13417,7 +13593,7 @@ var getToastComponent = (opts) => {
|
|
13417
13593
|
opts.text
|
13418
13594
|
);
|
13419
13595
|
}
|
13420
|
-
return ({ id }) => /* @__PURE__ */
|
13596
|
+
return ({ id }) => /* @__PURE__ */ React70__default.createElement(BaseToast, { id, variant: opts.variant }, opts.text);
|
13421
13597
|
};
|
13422
13598
|
var Tooltip = ({
|
13423
13599
|
children,
|
@@ -13430,7 +13606,7 @@ var Tooltip = ({
|
|
13430
13606
|
withCloseButton = false,
|
13431
13607
|
...props
|
13432
13608
|
}) => {
|
13433
|
-
return /* @__PURE__ */
|
13609
|
+
return /* @__PURE__ */ React70__default.createElement(
|
13434
13610
|
Popover,
|
13435
13611
|
{
|
13436
13612
|
onClose,
|
@@ -13442,8 +13618,8 @@ var Tooltip = ({
|
|
13442
13618
|
arrowShadowColor: "none",
|
13443
13619
|
...props
|
13444
13620
|
},
|
13445
|
-
/* @__PURE__ */
|
13446
|
-
/* @__PURE__ */
|
13621
|
+
/* @__PURE__ */ React70__default.createElement(PopoverTrigger, null, children),
|
13622
|
+
/* @__PURE__ */ React70__default.createElement(PopoverContent, null, /* @__PURE__ */ React70__default.createElement(PopoverArrow, null), withCloseButton && /* @__PURE__ */ React70__default.createElement(PopoverCloseButton, null), /* @__PURE__ */ React70__default.createElement(PopoverBody, null, content))
|
13447
13623
|
);
|
13448
13624
|
};
|
13449
13625
|
|
@@ -13552,4 +13728,4 @@ function slugify(text, maxLength = 50) {
|
|
13552
13728
|
return text.normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/[\u00C6\u00E6]/g, "ae").replace(/[\u00D8\u00F8]/g, "oe").replace(/[\u00C5\u00E5]/g, "aa").toLowerCase().replace(/\s+/g, "-").replace(/[^\w-]+/g, "").replace(/--+/g, "-").replace(/^-+/, "").replace(/-+$/, "").substring(0, maxLength);
|
13553
13729
|
}
|
13554
13730
|
|
13555
|
-
export { Accordion, AttachedInputs, Badge, Brand, Breadcrumb, BreadcrumbItem, BreadcrumbLink, Button, ButtonGroup, Card, CardSelect, Checkbox, CheckboxGroup, ChoiceChip, ClosableAlert, CloseButton, Code, ColorInlineLoader, ColorSpinner, Combobox, ContentLoader, DarkFullScreenLoader, DarkInlineLoader, DarkSpinner, DatePicker, DateRangePicker, Divider, Drawer, DrawerContent, Expandable, ExpandableAlert, ExpandableItem, FloatingActionButton, FormControl, FormErrorMessage, FormLabel3 as FormLabel, Heading, IconButton, InfoSelect, InfoTag, Input, InputLeftElement2 as InputLeftElement, InputRightElement2 as InputRightElement, ItemDescription, ItemLabel, JumpButton, Language, LanguageProvider, LightFullScreenLoader, LightInlineLoader, LightSpinner, LineIcon, ListBox, ModalHeader, NativeSelect, Nudge, NumericStepper, PasswordInput, PhoneNumberInput, PlayPauseButton, ProgressBar, ProgressIndicator, ProgressLoader, Radio, RadioGroup, SearchInput, SimpleDrawer, Skeleton, SkeletonCircle, SkeletonText, SkipButton, SporProvider, Stack, StaticAlert, Stepper, StepperStep, Switch, Table, Tabs, Text4 as Text, TextLink, Textarea, TimePicker, Tooltip, TravelTag, VyLogo, WizardNudge, brandTheme, createTexts, fontFaces, slugify, theme, useSize, useToast, useTranslation };
|
13731
|
+
export { Accordion, AttachedInputs, Badge, Brand, Breadcrumb, BreadcrumbItem, BreadcrumbLink, Button, ButtonGroup, Card, CardSelect, Checkbox, CheckboxGroup, ChoiceChip, ClosableAlert, CloseButton, Code, ColorInlineLoader, ColorSpinner, Combobox, ContentLoader, DarkFullScreenLoader, DarkInlineLoader, DarkSpinner, DatePicker, DateRangePicker, Divider, Drawer, DrawerContent, Expandable, ExpandableAlert, ExpandableItem, FloatingActionButton, FormControl, FormErrorMessage, FormLabel3 as FormLabel, FullScreenDrawer, Heading, IconButton, InfoSelect, InfoTag, Input, InputLeftElement2 as InputLeftElement, InputRightElement2 as InputRightElement, ItemDescription, ItemLabel, JumpButton, Language, LanguageProvider, LightFullScreenLoader, LightInlineLoader, LightSpinner, LineIcon, ListBox, ModalHeader, NativeSelect, Nudge, NumericStepper, PasswordInput, PhoneNumberInput, PlayPauseButton, ProgressBar, ProgressIndicator, ProgressLoader, Radio, RadioGroup, SearchInput, SimpleDrawer, Skeleton, SkeletonCircle, SkeletonText, SkipButton, SporProvider, Stack, StaticAlert, StaticCard, Stepper, StepperStep, Switch, Table, Tabs, Text4 as Text, TextLink, Textarea, TimePicker, Tooltip, TravelTag, VyLogo, WizardNudge, brandTheme, createTexts, fontFaces, slugify, theme, useSize, useToast, useTranslation };
|