@vygruppen/spor-react 12.24.12 → 12.24.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +12 -12
- package/.turbo/turbo-postinstall.log +2 -2
- package/CHANGELOG.md +13 -0
- package/dist/index.cjs +14 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -4
- package/dist/index.d.ts +1 -4
- package/dist/index.mjs +14 -11
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
- package/src/nudge/Nudge.tsx +11 -2
- package/src/stepper/StepperStep.tsx +2 -5
- package/src/theme/slot-recipes/datepicker.ts +1 -4
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vygruppen/spor-react",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "12.24.
|
|
4
|
+
"version": "12.24.14",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
7
7
|
"types": "./dist/index.d.ts",
|
|
@@ -47,8 +47,8 @@
|
|
|
47
47
|
"react-swipeable": "^7.0.1",
|
|
48
48
|
"usehooks-ts": "^3.1.0",
|
|
49
49
|
"@vygruppen/spor-design-tokens": "4.3.3",
|
|
50
|
-
"@vygruppen/spor-
|
|
51
|
-
"@vygruppen/spor-
|
|
50
|
+
"@vygruppen/spor-icon-react": "4.5.3",
|
|
51
|
+
"@vygruppen/spor-loader": "0.7.0"
|
|
52
52
|
},
|
|
53
53
|
"devDependencies": {
|
|
54
54
|
"@react-types/datepicker": "^3.10.0",
|
package/src/nudge/Nudge.tsx
CHANGED
|
@@ -52,14 +52,23 @@ export type NudgeProps = {
|
|
|
52
52
|
} & PopoverRootProps;
|
|
53
53
|
|
|
54
54
|
export const Nudge = (props: NudgeProps) => {
|
|
55
|
-
const { introducedDate, size = "md", ...rest } = props;
|
|
55
|
+
const { introducedDate, size = "md", open, ...rest } = props;
|
|
56
56
|
|
|
57
57
|
if (isNudgeExpired(introducedDate)) {
|
|
58
58
|
logExpirationWarning();
|
|
59
59
|
return null;
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
|
|
62
|
+
const isControlled = open !== undefined;
|
|
63
|
+
|
|
64
|
+
return (
|
|
65
|
+
<Popover
|
|
66
|
+
defaultOpen={isControlled ? undefined : true}
|
|
67
|
+
open={open}
|
|
68
|
+
size={size}
|
|
69
|
+
{...rest}
|
|
70
|
+
/>
|
|
71
|
+
);
|
|
63
72
|
};
|
|
64
73
|
|
|
65
74
|
export const NudgeTrigger = forwardRef<
|
|
@@ -23,11 +23,8 @@ export const StepperStep = ({
|
|
|
23
23
|
const state = getState(stepNumber, activeStep);
|
|
24
24
|
const recipe = useSlotRecipe({ key: "stepper" });
|
|
25
25
|
const style = recipe({ variant });
|
|
26
|
-
const disabledTextColor = "text.
|
|
27
|
-
const iconColor =
|
|
28
|
-
_light: "blackAlpha.200",
|
|
29
|
-
_dark: "whiteAlpha.200",
|
|
30
|
-
};
|
|
26
|
+
const disabledTextColor = "text.tertiary";
|
|
27
|
+
const iconColor = "text.tertiary";
|
|
31
28
|
|
|
32
29
|
const disabled =
|
|
33
30
|
(state !== "active" && disabledOverride) || state === "disabled";
|
|
@@ -182,10 +182,7 @@ export const datePickerSlotRecipe = defineSlotRecipe({
|
|
|
182
182
|
},
|
|
183
183
|
floating: {
|
|
184
184
|
wrapper: {
|
|
185
|
-
|
|
186
|
-
_light: "bg",
|
|
187
|
-
_dark: `color-mix(in srgb, white 10%, var(--spor-colors-bg))`,
|
|
188
|
-
},
|
|
185
|
+
bg: "floating.surface",
|
|
189
186
|
outline: "1px solid",
|
|
190
187
|
outlineColor: "floating.outline",
|
|
191
188
|
boxShadow: "sm",
|