@vygruppen/spor-react 12.10.0 → 12.10.2
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/.turbo/turbo-postinstall.log +1 -1
- package/CHANGELOG.md +20 -29
- package/dist/index.cjs +185 -231
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +10 -41
- package/dist/index.d.ts +10 -41
- package/dist/index.mjs +185 -231
- package/dist/index.mjs.map +1 -1
- package/package.json +5 -4
- package/src/alert/ServiceAlert.tsx +2 -2
- package/src/datepicker/DateField.tsx +6 -2
- package/src/datepicker/TimeField.tsx +2 -6
- package/src/dialog/Drawer.tsx +2 -2
- package/src/input/ListBox.tsx +16 -3
- package/src/input/PhoneNumberInput.tsx +31 -40
- package/src/input/Switch.tsx +1 -1
- package/src/linjetag/LineIcon.tsx +4 -2
- package/src/linjetag/TravelTag.tsx +2 -1
- package/src/loader/DarkFullScreenLoader.tsx +2 -1
- package/src/loader/LightFullScreenLoader.tsx +1 -7
- package/src/loader/LightInlineLoader.tsx +1 -7
- package/src/theme/recipes/badge.ts +1 -1
- package/src/theme/recipes/close-button.ts +2 -2
- package/src/theme/recipes/link.ts +3 -3
- package/src/theme/recipes/pressable-card.ts +0 -1
- package/src/theme/recipes/skeleton.ts +1 -1
- package/src/theme/slot-recipes/alert-service.ts +3 -3
- package/src/theme/slot-recipes/checkbox.ts +2 -3
- package/src/theme/slot-recipes/choice-chip.ts +7 -7
- package/src/theme/slot-recipes/datepicker.ts +1 -2
- package/src/theme/slot-recipes/dialog.ts +1 -0
- package/src/theme/slot-recipes/drawer.ts +1 -0
- package/src/theme/slot-recipes/field.ts +4 -3
- package/src/theme/slot-recipes/floating-action-button.ts +1 -1
- package/src/theme/slot-recipes/line-icon.ts +3 -36
- package/src/theme/slot-recipes/radio-card.ts +0 -1
- package/src/theme/slot-recipes/select.ts +8 -18
- package/src/theme/slot-recipes/switch.ts +3 -5
- package/src/theme/slot-recipes/table.ts +0 -1
- package/src/theme/slot-recipes/tabs.ts +3 -4
- package/src/theme/slot-recipes/toast.ts +0 -9
- package/src/theme/slot-recipes/travel-tag.ts +11 -9
- package/src/toast/toast.tsx +1 -1
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@vygruppen/spor-react",
|
3
3
|
"type": "module",
|
4
|
-
"version": "12.10.
|
4
|
+
"version": "12.10.2",
|
5
5
|
"exports": {
|
6
6
|
".": {
|
7
7
|
"types": "./dist/index.d.ts",
|
@@ -25,8 +25,8 @@
|
|
25
25
|
"dependencies": {
|
26
26
|
"@ark-ui/react": "^4.9.2",
|
27
27
|
"@chakra-ui/anatomy": "^2.3.4",
|
28
|
-
"@chakra-ui/react": "^3.24.0",
|
29
28
|
"@chakra-ui/cli": "^3.8.0",
|
29
|
+
"@chakra-ui/react": "^3.24.0",
|
30
30
|
"@chakra-ui/react-use-size": "^2.1.0",
|
31
31
|
"@chakra-ui/styled-system": "^2.12.0",
|
32
32
|
"@chakra-ui/system": "^2.6.2",
|
@@ -58,6 +58,7 @@
|
|
58
58
|
"@types/node": "^22.13.4",
|
59
59
|
"@types/react": "^18.3.3",
|
60
60
|
"@types/react-dom": "^18.3.0",
|
61
|
+
"clsx": "^2.1.1",
|
61
62
|
"concurrently": "^9.1.2",
|
62
63
|
"eslint": "^9.25.1",
|
63
64
|
"react": "^18.3.1",
|
@@ -67,8 +68,8 @@
|
|
67
68
|
"vitest": "^0.26.3",
|
68
69
|
"vitest-axe": "^0.1.0",
|
69
70
|
"vitest-canvas-mock": "^0.2.2",
|
70
|
-
"@vygruppen/
|
71
|
-
"@vygruppen/
|
71
|
+
"@vygruppen/eslint-config": "1.2.3",
|
72
|
+
"@vygruppen/tsconfig": "0.1.1"
|
72
73
|
},
|
73
74
|
"peerDependencies": {
|
74
75
|
"react": ">=18.0.0 <19.0.0",
|
@@ -128,10 +128,10 @@ export const ServiceAlert = forwardRef<HTMLDivElement, ServiceAlertProps>(
|
|
128
128
|
</Accordion.ItemTrigger>
|
129
129
|
|
130
130
|
<Accordion.ItemContent asChild>
|
131
|
-
<Stack flexDirection="row"
|
131
|
+
<Stack flexDirection="row" width="100%">
|
132
132
|
<Accordion.ItemBody
|
133
133
|
as={Stack}
|
134
|
-
|
134
|
+
width={contentWidth}
|
135
135
|
css={styles.itemBody}
|
136
136
|
>
|
137
137
|
{children}
|
@@ -1,11 +1,13 @@
|
|
1
1
|
"use client";
|
2
|
-
import { Box, Flex, useSlotRecipe } from "@chakra-ui/react";
|
2
|
+
import { Box, Field, Flex, useSlotRecipe } from "@chakra-ui/react";
|
3
3
|
import { DateValue, GregorianCalendar } from "@internationalized/date";
|
4
4
|
import { DOMAttributes, FocusableElement } from "@react-types/shared";
|
5
5
|
import React, { forwardRef, PropsWithChildren, RefObject, useRef } from "react";
|
6
6
|
import { AriaDateFieldProps, useDateField } from "react-aria";
|
7
7
|
import { DateSegment, useDateFieldState } from "react-stately";
|
8
8
|
|
9
|
+
import { Label } from "@/input/Label";
|
10
|
+
|
9
11
|
import { createTexts, useTranslation } from "../i18n";
|
10
12
|
import { DatePickerVariantProps } from "./DatePicker";
|
11
13
|
import { DateTimeSegment } from "./DateTimeSegment";
|
@@ -61,7 +63,9 @@ export const DateField = forwardRef<HTMLDivElement, DateFieldProps>(
|
|
61
63
|
position="absolute"
|
62
64
|
paddingTop="2px"
|
63
65
|
>
|
64
|
-
<
|
66
|
+
<Label padding="0" fontSize="2xs" {...props.labelProps}>
|
67
|
+
{props.label} <Field.RequiredIndicator />
|
68
|
+
</Label>
|
65
69
|
</Box>
|
66
70
|
)}
|
67
71
|
<Flex {...fieldProps} ref={ref} paddingTop="3" paddingBottom="0.5">
|
@@ -38,12 +38,8 @@ export const TimeField = ({ state, ...props }: TimeFieldProps) => {
|
|
38
38
|
{props.label}
|
39
39
|
</label>
|
40
40
|
<Flex {...fieldProps} ref={ref} paddingTop="3" paddingBottom="0.5">
|
41
|
-
{state.segments.map((segment: DateSegment) => (
|
42
|
-
<DateTimeSegment
|
43
|
-
key={JSON.stringify(segment)}
|
44
|
-
segment={segment}
|
45
|
-
state={state}
|
46
|
-
/>
|
41
|
+
{state.segments.map((segment: DateSegment, index) => (
|
42
|
+
<DateTimeSegment key={index} segment={segment} state={state} />
|
47
43
|
))}
|
48
44
|
</Flex>
|
49
45
|
<input
|
package/src/dialog/Drawer.tsx
CHANGED
@@ -14,6 +14,7 @@ import {
|
|
14
14
|
CloseFill24Icon,
|
15
15
|
} from "@vygruppen/spor-icon-react";
|
16
16
|
import { forwardRef } from "react";
|
17
|
+
import { useSwipeable } from "react-swipeable";
|
17
18
|
|
18
19
|
import { Button, CloseButton } from "../button";
|
19
20
|
import { createTexts, useTranslation } from "../i18n";
|
@@ -22,7 +23,6 @@ import {
|
|
22
23
|
DrawerFullScreenHeaderProps,
|
23
24
|
DrawerProps,
|
24
25
|
} from "./types";
|
25
|
-
import { useSwipeable } from "react-swipeable";
|
26
26
|
|
27
27
|
/**
|
28
28
|
* A drawer is a panel that slides in from the side of the screen. It is used to display additional content without taking up too much space.
|
@@ -98,7 +98,7 @@ export const CloseDrawerLine = forwardRef<HTMLButtonElement>((props, ref) => {
|
|
98
98
|
top={0}
|
99
99
|
marginY={2}
|
100
100
|
marginX="auto"
|
101
|
-
backgroundColor="
|
101
|
+
backgroundColor="floating.outline.active"
|
102
102
|
borderRadius="xs"
|
103
103
|
{...props}
|
104
104
|
ref={ref}
|
package/src/input/ListBox.tsx
CHANGED
@@ -90,6 +90,7 @@ export const ListBox = (props: ListBoxProps<object>) => {
|
|
90
90
|
css={styles.root}
|
91
91
|
aria-busy={loading}
|
92
92
|
maxWidth={maxWidth}
|
93
|
+
padding="1"
|
93
94
|
>
|
94
95
|
{state.collection.size === 0 && props.emptyContent}
|
95
96
|
{[...state.collection].map((item) =>
|
@@ -181,7 +182,14 @@ function Option({ item, state }: OptionProps) {
|
|
181
182
|
}, []);
|
182
183
|
return (
|
183
184
|
<OptionContext.Provider value={{ labelProps, descriptionProps }}>
|
184
|
-
<ListItem
|
185
|
+
<ListItem
|
186
|
+
{...optionProps}
|
187
|
+
{...dataFields}
|
188
|
+
ref={ref}
|
189
|
+
css={styles.item}
|
190
|
+
padding="1"
|
191
|
+
marginX="0"
|
192
|
+
>
|
185
193
|
{item.rendered}
|
186
194
|
</ListItem>
|
187
195
|
</OptionContext.Provider>
|
@@ -217,14 +225,19 @@ function ListBoxSection({ section, state }: ListBoxSectionProps) {
|
|
217
225
|
|
218
226
|
return (
|
219
227
|
<List>
|
220
|
-
<ListItem
|
228
|
+
<ListItem
|
229
|
+
{...itemProps}
|
230
|
+
listStyleType={"none"}
|
231
|
+
marginLeft="0"
|
232
|
+
paddingX="1"
|
233
|
+
>
|
221
234
|
{section.rendered && (
|
222
235
|
<Box
|
223
236
|
fontSize="mobile.xs"
|
224
237
|
color={titleColor}
|
225
|
-
paddingX={3}
|
226
238
|
paddingTop={1}
|
227
239
|
marginTop={isFirstSection ? 0 : 2}
|
240
|
+
marginLeft="1"
|
228
241
|
textTransform="uppercase"
|
229
242
|
fontWeight="bold"
|
230
243
|
{...headingProps}
|
@@ -80,46 +80,37 @@ export const PhoneNumberInput = forwardRef<
|
|
80
80
|
};
|
81
81
|
|
82
82
|
return (
|
83
|
-
<AttachedInputs
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
{
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
countryCode: value.countryCode,
|
115
|
-
nationalNumber: strippedValue,
|
116
|
-
});
|
117
|
-
}}
|
118
|
-
variant={variant}
|
119
|
-
data-state="on"
|
120
|
-
label={label}
|
121
|
-
/>
|
122
|
-
</>
|
83
|
+
<AttachedInputs display="grid" gridTemplateColumns="1fr 10fr">
|
84
|
+
<CountryCodeSelect
|
85
|
+
value={[value.countryCode]}
|
86
|
+
onValueChange={handleCountryCodeChange}
|
87
|
+
height="100%"
|
88
|
+
width="6.25rem"
|
89
|
+
variant={variant}
|
90
|
+
allowedCountryCodes={allowedCountryCodes}
|
91
|
+
data-state="on"
|
92
|
+
invalid={invalid}
|
93
|
+
/>
|
94
|
+
<Input
|
95
|
+
ref={ref}
|
96
|
+
type="tel"
|
97
|
+
{...props}
|
98
|
+
value={value.nationalNumber}
|
99
|
+
invalid={invalid}
|
100
|
+
errorText={errorText}
|
101
|
+
onChange={(e) => {
|
102
|
+
const target = e.target as HTMLInputElement;
|
103
|
+
// Removes everything but numbers, spaces and dashes
|
104
|
+
const strippedValue = target.value.replaceAll(/[^\d\s-]/g, "");
|
105
|
+
onChange({
|
106
|
+
countryCode: value.countryCode,
|
107
|
+
nationalNumber: strippedValue,
|
108
|
+
});
|
109
|
+
}}
|
110
|
+
variant={variant}
|
111
|
+
data-state="on"
|
112
|
+
label={label}
|
113
|
+
/>
|
123
114
|
</AttachedInputs>
|
124
115
|
);
|
125
116
|
});
|
package/src/input/Switch.tsx
CHANGED
@@ -74,11 +74,11 @@ export const Switch = forwardRef<HTMLInputElement, SwitchProps>(
|
|
74
74
|
checked={props.checked}
|
75
75
|
css={styles.root}
|
76
76
|
>
|
77
|
-
<ChakraSwitch.Label>{label}</ChakraSwitch.Label>
|
78
77
|
<ChakraSwitch.HiddenInput ref={ref} />
|
79
78
|
<ChakraSwitch.Control css={styles.control}>
|
80
79
|
<ChakraSwitch.Thumb />
|
81
80
|
</ChakraSwitch.Control>
|
81
|
+
<ChakraSwitch.Label>{label}</ChakraSwitch.Label>
|
82
82
|
</ChakraSwitch.Root>
|
83
83
|
</Field>
|
84
84
|
);
|
@@ -5,6 +5,7 @@ import {
|
|
5
5
|
RecipeVariantProps,
|
6
6
|
useSlotRecipe,
|
7
7
|
} from "@chakra-ui/react";
|
8
|
+
import clsx from "clsx";
|
8
9
|
import React, { forwardRef, PropsWithChildren } from "react";
|
9
10
|
|
10
11
|
import { lineIconSlotRecipe } from "../theme/slot-recipes/line-icon";
|
@@ -90,10 +91,10 @@ export const LineIcon = forwardRef<HTMLDivElement, LineIconProps>(
|
|
90
91
|
|
91
92
|
const Icon: React.ElementType = getCorrectIcon({
|
92
93
|
variant:
|
94
|
+
// eslint-disable-next-line no-nested-ternary
|
93
95
|
variant === "custom" && "customIconVariant" in rest
|
94
96
|
? rest.customIconVariant
|
95
|
-
:
|
96
|
-
variant === "custom" //eslint rules and prettier conflict
|
97
|
+
: variant === "custom"
|
97
98
|
? "local-train"
|
98
99
|
: variant,
|
99
100
|
size,
|
@@ -116,6 +117,7 @@ export const LineIcon = forwardRef<HTMLDivElement, LineIconProps>(
|
|
116
117
|
borderColor={variant === "walk" ? "core.outline" : "transparent"}
|
117
118
|
aria-label={label}
|
118
119
|
ref={ref}
|
120
|
+
className={clsx("light", rest.className)}
|
119
121
|
>
|
120
122
|
<Icon css={styles.icon} />
|
121
123
|
</Box>
|
@@ -13,6 +13,7 @@ import {
|
|
13
13
|
WarningFill18Icon,
|
14
14
|
WarningFill24Icon,
|
15
15
|
} from "@vygruppen/spor-icon-react";
|
16
|
+
import clsx from "clsx";
|
16
17
|
import { forwardRef, PropsWithChildren } from "react";
|
17
18
|
|
18
19
|
import { travelTagSlotRecipe } from "../theme/slot-recipes/travel-tag";
|
@@ -122,8 +123,8 @@ export const TravelTag = forwardRef<HTMLDivElement, TravelTagProps>(
|
|
122
123
|
css={styles.container}
|
123
124
|
aria-disabled={disabled}
|
124
125
|
ref={ref}
|
126
|
+
className={clsx("light", rest.className)}
|
125
127
|
{...rest}
|
126
|
-
backgroundColor={disabled ? "surface.disabled" : backgroundColor}
|
127
128
|
>
|
128
129
|
<LineIcon
|
129
130
|
variant={variant}
|
@@ -13,13 +13,7 @@ export const LightFullScreenLoader = ({
|
|
13
13
|
...props
|
14
14
|
}: LightFullScreenLoaderProps) => {
|
15
15
|
return (
|
16
|
-
<Center
|
17
|
-
height="100%"
|
18
|
-
background="white"
|
19
|
-
role="status"
|
20
|
-
aria-live="polite"
|
21
|
-
{...props}
|
22
|
-
>
|
16
|
+
<Center height="100%" role="status" aria-live="polite" {...props}>
|
23
17
|
<Box width={width} maxWidth={maxWidth}>
|
24
18
|
<ClientOnly>
|
25
19
|
<Lottie animationData={fullScreenLoaderBlackData} />
|
@@ -15,13 +15,7 @@ export const LightInlineLoader = ({
|
|
15
15
|
...props
|
16
16
|
}: LightInlineLoaderProps) => {
|
17
17
|
return (
|
18
|
-
<Center
|
19
|
-
height="100%"
|
20
|
-
background="white"
|
21
|
-
role="status"
|
22
|
-
aria-live="polite"
|
23
|
-
{...props}
|
24
|
-
>
|
18
|
+
<Center height="100%" role="status" aria-live="polite" {...props}>
|
25
19
|
<Box width={width} maxWidth={maxWidth}>
|
26
20
|
<ClientOnly>
|
27
21
|
<Lottie animationData={inlineLoaderLightData} />
|
@@ -6,12 +6,12 @@ export const closeButtonRecipe = defineRecipe({
|
|
6
6
|
transitionDuration: "normal",
|
7
7
|
borderRadius: "md",
|
8
8
|
backgroundColor: "transparent",
|
9
|
-
color: "
|
9
|
+
color: "text",
|
10
10
|
fontWeight: "normal",
|
11
11
|
_hover: {
|
12
12
|
background: "ghost.surface.hover",
|
13
13
|
_disabled: {
|
14
|
-
color: "
|
14
|
+
color: "icon.disabled",
|
15
15
|
},
|
16
16
|
_active: {
|
17
17
|
background: "ghost.surface.active",
|
@@ -34,17 +34,17 @@ export const linkRecipe = defineRecipe({
|
|
34
34
|
primary: {
|
35
35
|
color: "core.text",
|
36
36
|
_hover: {
|
37
|
-
color: "text
|
37
|
+
color: "text",
|
38
38
|
_active: {
|
39
39
|
color: "text.disabled",
|
40
40
|
},
|
41
41
|
},
|
42
42
|
},
|
43
43
|
secondary: {
|
44
|
-
color: "text.
|
44
|
+
color: "text.highlight",
|
45
45
|
padding: "2px",
|
46
46
|
_hover: {
|
47
|
-
color: "text.
|
47
|
+
color: "text.highlight",
|
48
48
|
_active: {
|
49
49
|
color: "text.disabled",
|
50
50
|
},
|
@@ -35,7 +35,7 @@ export const alertServiceSlotRecipe = defineSlotRecipe({
|
|
35
35
|
},
|
36
36
|
|
37
37
|
_icon: {
|
38
|
-
color: "
|
38
|
+
color: "text",
|
39
39
|
},
|
40
40
|
},
|
41
41
|
itemTriggerTitle: {
|
@@ -47,13 +47,13 @@ export const alertServiceSlotRecipe = defineSlotRecipe({
|
|
47
47
|
textWrap: "nowrap",
|
48
48
|
},
|
49
49
|
itemBody: {
|
50
|
-
|
50
|
+
marginX: "auto",
|
51
|
+
padding: "0 !important",
|
51
52
|
paddingBottom: ["0.5", null, null, "1"],
|
52
53
|
color: "text.inverted",
|
53
54
|
"& > p": {
|
54
55
|
gap: 2,
|
55
56
|
width: "full",
|
56
|
-
justifyContent: "center",
|
57
57
|
borderBottom: "1px dashed",
|
58
58
|
borderColor: "outline.inverted",
|
59
59
|
paddingBottom: "3",
|
@@ -25,7 +25,6 @@ export const checkboxSlotRecipe = defineSlotRecipe({
|
|
25
25
|
indicator: {
|
26
26
|
width: "100%",
|
27
27
|
height: "100%",
|
28
|
-
borderColor: "white",
|
29
28
|
marginTop: -1,
|
30
29
|
transform: "scale(1)",
|
31
30
|
opacity: 0,
|
@@ -59,8 +58,8 @@ export const checkboxSlotRecipe = defineSlotRecipe({
|
|
59
58
|
},
|
60
59
|
|
61
60
|
_invalid: {
|
62
|
-
backgroundColor: "
|
63
|
-
borderColor: "
|
61
|
+
backgroundColor: "outline.error",
|
62
|
+
borderColor: "outline.error",
|
64
63
|
},
|
65
64
|
},
|
66
65
|
_disabled: {
|
@@ -19,7 +19,7 @@ export const choiceChipSlotRecipe = defineSlotRecipe({
|
|
19
19
|
paddingInlineEnd: "2",
|
20
20
|
|
21
21
|
outline: "1px solid",
|
22
|
-
outlineColor: "
|
22
|
+
outlineColor: "core.outline",
|
23
23
|
_checked: {
|
24
24
|
backgroundColor: "brand.surface",
|
25
25
|
borderRadius: "sm",
|
@@ -47,19 +47,19 @@ export const choiceChipSlotRecipe = defineSlotRecipe({
|
|
47
47
|
outline: "none",
|
48
48
|
|
49
49
|
_hover: {
|
50
|
-
backgroundColor: "
|
50
|
+
backgroundColor: "surface.disabled",
|
51
51
|
boxShadow: "none",
|
52
|
-
color: "
|
52
|
+
color: "text.disabled",
|
53
53
|
},
|
54
54
|
_checked: {
|
55
55
|
cursor: "not-allowed",
|
56
56
|
boxShadow: "none",
|
57
|
-
color: "
|
58
|
-
backgroundColor: "
|
57
|
+
color: "text.disabled",
|
58
|
+
backgroundColor: "surface.disabled",
|
59
59
|
_hover: {
|
60
|
-
backgroundColor: "
|
60
|
+
backgroundColor: "surface.disabled",
|
61
61
|
boxShadow: "none",
|
62
|
-
color: "
|
62
|
+
color: "text.disabled",
|
63
63
|
},
|
64
64
|
},
|
65
65
|
},
|
@@ -37,7 +37,7 @@ export const datePickerSlotRecipe = defineSlotRecipe({
|
|
37
37
|
dateTimeSegment: {
|
38
38
|
_focus: {
|
39
39
|
backgroundColor: "ghost.surface.active",
|
40
|
-
color: "text
|
40
|
+
color: "text",
|
41
41
|
},
|
42
42
|
},
|
43
43
|
box: {
|
@@ -147,7 +147,6 @@ export const datePickerSlotRecipe = defineSlotRecipe({
|
|
147
147
|
wrapper: {
|
148
148
|
outline: "1px solid",
|
149
149
|
outlineColor: "core.outline",
|
150
|
-
backgroundColor: "core.surface",
|
151
150
|
|
152
151
|
_hover: {
|
153
152
|
outline: "2px solid",
|
@@ -14,6 +14,7 @@ export const fieldSlotRecipe = defineSlotRecipe({
|
|
14
14
|
},
|
15
15
|
requiredIndicator: {
|
16
16
|
marginStart: 1,
|
17
|
+
// eslint-disable-next-line spor/use-semantic-tokens
|
17
18
|
color: "brightRed",
|
18
19
|
},
|
19
20
|
label: {
|
@@ -27,8 +28,8 @@ export const fieldSlotRecipe = defineSlotRecipe({
|
|
27
28
|
},
|
28
29
|
errorText: {
|
29
30
|
borderRadius: "xs",
|
30
|
-
backgroundColor: "
|
31
|
-
color: "
|
31
|
+
backgroundColor: "alert.error.surface",
|
32
|
+
color: "text",
|
32
33
|
paddingX: 1.5,
|
33
34
|
paddingY: 1,
|
34
35
|
textStyle: "xs",
|
@@ -45,7 +46,7 @@ export const fieldSlotRecipe = defineSlotRecipe({
|
|
45
46
|
left: "1em",
|
46
47
|
width: "0.5rem",
|
47
48
|
height: "0.5rem",
|
48
|
-
backgroundColor: "
|
49
|
+
backgroundColor: "alert.error.surface",
|
49
50
|
transform: "translateY(-50%) rotate(45deg)",
|
50
51
|
pointerEvents: "none",
|
51
52
|
},
|
@@ -76,7 +76,7 @@ export const floatingActionButtonSlotRecipe = defineSlotRecipe({
|
|
76
76
|
_hover: {
|
77
77
|
backgroundColor: "transparent",
|
78
78
|
outline: "2px solid",
|
79
|
-
outlineColor: "core.outline
|
79
|
+
outlineColor: "core.outline",
|
80
80
|
_active: {
|
81
81
|
outline: "1px solid",
|
82
82
|
outlineColor: "core.outline",
|
@@ -10,21 +10,12 @@ export const lineIconSlotRecipe = defineSlotRecipe({
|
|
10
10
|
display: "flex",
|
11
11
|
justifyContent: "center",
|
12
12
|
alignItems: "center",
|
13
|
-
"[aria-disabled=true] &": {
|
14
|
-
backgroundColor: "surface.disabled",
|
15
|
-
},
|
16
13
|
},
|
17
14
|
icon: {
|
18
|
-
color: "
|
19
|
-
"[aria-disabled=true] &": {
|
20
|
-
color: "icon.disabled",
|
21
|
-
},
|
15
|
+
color: "bg",
|
22
16
|
},
|
23
17
|
title: {
|
24
|
-
color: "
|
25
|
-
"[aria-disabled=true] &": {
|
26
|
-
color: "text.disabled",
|
27
|
-
},
|
18
|
+
color: "text",
|
28
19
|
},
|
29
20
|
},
|
30
21
|
variants: {
|
@@ -83,38 +74,14 @@ export const lineIconSlotRecipe = defineSlotRecipe({
|
|
83
74
|
iconContainer: {
|
84
75
|
backgroundColor: "linjetag.altTransport",
|
85
76
|
},
|
86
|
-
icon: {
|
87
|
-
color: "darkGrey",
|
88
|
-
"[aria-disabled=true] &": {
|
89
|
-
color: "white",
|
90
|
-
},
|
91
|
-
},
|
92
77
|
},
|
93
78
|
walk: {
|
94
79
|
title: {
|
95
80
|
color: "text",
|
96
81
|
},
|
97
|
-
icon: {
|
98
|
-
color: "linjetag.walkLight",
|
99
|
-
"[aria-disabled=true] &": {
|
100
|
-
color: "icon.disabled",
|
101
|
-
},
|
102
|
-
},
|
103
|
-
_disabled: {
|
104
|
-
icon: {
|
105
|
-
color: "text.disabled",
|
106
|
-
},
|
107
|
-
title: {
|
108
|
-
color: "text.disabled",
|
109
|
-
},
|
110
|
-
},
|
111
82
|
},
|
112
83
|
custom: {
|
113
|
-
iconContainer: {
|
114
|
-
_disabled: {
|
115
|
-
backgroundColor: "surface.disabled",
|
116
|
-
},
|
117
|
-
},
|
84
|
+
iconContainer: {},
|
118
85
|
},
|
119
86
|
},
|
120
87
|
size: {
|