@vygruppen/spor-react 13.4.0 → 13.4.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/dist/index.d.cts CHANGED
@@ -1390,6 +1390,7 @@ interface DialogContentProps extends Dialog.ContentProps {
1390
1390
  portalRef?: React$1.RefObject<HTMLElement>;
1391
1391
  backdrop?: boolean;
1392
1392
  children?: React$1.ReactNode;
1393
+ positionerProps?: Dialog.PositionerProps;
1393
1394
  }
1394
1395
  declare const DialogContent: ({ ref, ...props }: DialogContentProps & {
1395
1396
  ref?: React$1.Ref<HTMLDivElement>;
@@ -1728,8 +1729,10 @@ type AttachedInputsProps = RecipeVariantProps<typeof attachedInputsRecipe> & Gro
1728
1729
  } | {
1729
1730
  onFlip: () => void;
1730
1731
  flipAriaLabel: string;
1731
- });
1732
- declare const AttachedInputs: ({ ref, ...props }: AttachedInputsProps & {
1732
+ }) & {
1733
+ flipButtonProps?: Omit<IconButtonProps$1, "icon" | "aria-label" | "onClick" | "variant" | "size" | "orientation" | "spinner">;
1734
+ };
1735
+ declare const AttachedInputs: ({ ref, flipButtonProps, ...props }: AttachedInputsProps & {
1733
1736
  ref?: React.Ref<HTMLDivElement>;
1734
1737
  }) => react_jsx_runtime.JSX.Element;
1735
1738
 
@@ -2857,6 +2860,8 @@ type TagProps = VariantProps$1 & {
2857
2860
  size?: Size;
2858
2861
  title: string;
2859
2862
  description?: string;
2863
+ descriptionProps?: BoxProps;
2864
+ titleProps?: BoxProps;
2860
2865
  };
2861
2866
  type DefaultVariantProps$1 = {
2862
2867
  variant: Variant$1;
@@ -2908,7 +2913,7 @@ type InfoTagProps = TagProps & PropsWithChildren<InfoTagVariantProps>;
2908
2913
  *
2909
2914
  * @see https://spor.vy.no/components/line-tags
2910
2915
  */
2911
- declare const InfoTag: ({ variant, size, title, description, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2916
+ declare const InfoTag: ({ variant, size, title, description, descriptionProps, titleProps, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2912
2917
 
2913
2918
  declare const lineIconSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon" | "root" | "title" | "iconContainer" | "desc", {
2914
2919
  variant: {
@@ -3073,62 +3078,21 @@ declare const travelTagSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon"
3073
3078
  none: {};
3074
3079
  };
3075
3080
  variant: {
3076
- "local-train": {
3077
- container: {
3078
- backgroundColor: "linjetag.lokaltogLight";
3079
- };
3080
- };
3081
- "region-train": {
3082
- container: {
3083
- backgroundColor: "linjetag.regiontogLight";
3084
- };
3085
- };
3086
- "region-express-train": {
3087
- container: {
3088
- backgroundColor: "linjetag.regionEkspressLight";
3089
- };
3090
- };
3091
- "long-distance-train": {
3092
- container: {
3093
- backgroundColor: "linjetag.fjerntogLight";
3094
- };
3095
- };
3096
- "airport-express-train": {
3097
- container: {
3098
- backgroundColor: "linjetag.flytogLight";
3099
- };
3100
- };
3101
- "vy-bus": {
3102
- container: {
3103
- backgroundColor: "linjetag.vyBussLight";
3104
- };
3105
- };
3106
- "local-bus": {
3107
- container: {
3108
- backgroundColor: "linjetag.lokalbussLight";
3109
- };
3110
- };
3111
- ferry: {
3112
- container: {
3113
- backgroundColor: "linjetag.fergeLight";
3114
- };
3115
- };
3116
- subway: {
3117
- container: {
3118
- backgroundColor: "linjetag.tbaneLight";
3119
- };
3120
- };
3121
- tram: {
3122
- container: {
3123
- backgroundColor: "linjetag.trikkLight";
3124
- };
3125
- };
3126
- "alt-transport": {
3081
+ "local-train": {};
3082
+ "region-train": {};
3083
+ "region-express-train": {};
3084
+ "long-distance-train": {};
3085
+ "airport-express-train": {};
3086
+ "vy-bus": {};
3087
+ "local-bus": {};
3088
+ ferry: {};
3089
+ subway: {};
3090
+ tram: {};
3091
+ "alt-transport": {};
3092
+ walk: {
3127
3093
  container: {
3128
- backgroundColor: "linjetag.altTransportLight";
3094
+ backgroundColor: "none";
3129
3095
  };
3130
- };
3131
- walk: {
3132
3096
  textContainer: {
3133
3097
  position: "absolute";
3134
3098
  left: "0.875rem";
@@ -3199,7 +3163,7 @@ type TravelTagProps = TagProps & BoxProps & PropsWithChildren<TravelTagVariantPr
3199
3163
  */
3200
3164
  customIconVariant?: string;
3201
3165
  };
3202
- declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, ...rest }: TravelTagProps & {
3166
+ declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, descriptionProps, titleProps, ...rest }: TravelTagProps & {
3203
3167
  ref?: React.Ref<HTMLDivElement>;
3204
3168
  }) => react_jsx_runtime.JSX.Element;
3205
3169
 
@@ -4312,7 +4276,124 @@ declare const TooltipContent: ({ ref, children, showArrow, ...props }: TooltipPr
4312
4276
  ref?: React.Ref<HTMLDivElement>;
4313
4277
  }) => react_jsx_runtime.JSX.Element;
4314
4278
 
4279
+ declare const badgeRecipie: _chakra_ui_react.RecipeDefinition<{
4280
+ colorPalette: {
4281
+ neutral: {
4282
+ backgroundColor: "surface";
4283
+ color: "text";
4284
+ "& svg": {
4285
+ color: "icon";
4286
+ };
4287
+ };
4288
+ grey: {
4289
+ backgroundColor: "surface.neutral";
4290
+ color: "text.neutral";
4291
+ "& svg": {
4292
+ color: "icon.neutral";
4293
+ };
4294
+ };
4295
+ green: {
4296
+ backgroundColor: "surface.success";
4297
+ color: "text.success";
4298
+ "& svg": {
4299
+ color: "icon.success";
4300
+ };
4301
+ };
4302
+ blue: {
4303
+ backgroundColor: "surface.info";
4304
+ color: "text.info";
4305
+ "& svg": {
4306
+ color: "icon.info";
4307
+ };
4308
+ };
4309
+ cream: {
4310
+ backgroundColor: "surface.warning";
4311
+ color: "text.warning";
4312
+ "& svg": {
4313
+ color: "icon.warning";
4314
+ };
4315
+ };
4316
+ yellow: {
4317
+ backgroundColor: "surface.notice";
4318
+ color: "text.notice";
4319
+ "& svg": {
4320
+ color: "icon.notice";
4321
+ };
4322
+ };
4323
+ orange: {
4324
+ backgroundColor: "surface.caution";
4325
+ color: "text.caution";
4326
+ "& svg": {
4327
+ color: "icon.caution";
4328
+ };
4329
+ };
4330
+ red: {
4331
+ backgroundColor: "surface.critical";
4332
+ color: "text.critical";
4333
+ "& svg": {
4334
+ color: "icon.critical";
4335
+ };
4336
+ };
4337
+ brightRed: {
4338
+ backgroundColor: {
4339
+ _light: "brightRed";
4340
+ _dark: "brightRed";
4341
+ };
4342
+ color: {
4343
+ _light: "pink";
4344
+ _dark: "pink";
4345
+ };
4346
+ "& svg": {
4347
+ color: {
4348
+ _light: "pink";
4349
+ _dark: "pink";
4350
+ };
4351
+ };
4352
+ };
4353
+ disabled: {
4354
+ backgroundColor: "surface.disabled";
4355
+ color: "text.disabled";
4356
+ "& svg": {
4357
+ color: "icon.disabled";
4358
+ };
4359
+ };
4360
+ };
4361
+ size: {
4362
+ sm: {
4363
+ fontSize: "desktop.2xs";
4364
+ paddingX: "0.5";
4365
+ paddingY: "0";
4366
+ fontWeight: "normal";
4367
+ borderRadius: "xxs";
4368
+ };
4369
+ md: {
4370
+ fontSize: "desktop.2xs";
4371
+ paddingX: "1";
4372
+ paddingY: "0.5";
4373
+ fontWeight: "bold";
4374
+ borderRadius: "xs";
4375
+ };
4376
+ lg: {
4377
+ fontSize: "desktop.xs";
4378
+ paddingX: "1.5";
4379
+ paddingY: "0.5";
4380
+ fontWeight: "bold";
4381
+ borderRadius: "xs";
4382
+ };
4383
+ };
4384
+ attached: {
4385
+ true: {
4386
+ borderBottomRadius: "none";
4387
+ };
4388
+ };
4389
+ inverted: {
4390
+ true: {};
4391
+ };
4392
+ }>;
4393
+
4394
+ type BadgeVariantProps = RecipeVariantProps<typeof badgeRecipie>;
4315
4395
  type BadgeProps = BadgeProps$1 & {
4396
+ colorPalette?: BadgeVariantProps["colorPalette"];
4316
4397
  icon?: IconComponent;
4317
4398
  };
4318
4399
  declare const Badge: ({ ref, icon, children, ...props }: BadgeProps & {
package/dist/index.d.ts CHANGED
@@ -1390,6 +1390,7 @@ interface DialogContentProps extends Dialog.ContentProps {
1390
1390
  portalRef?: React$1.RefObject<HTMLElement>;
1391
1391
  backdrop?: boolean;
1392
1392
  children?: React$1.ReactNode;
1393
+ positionerProps?: Dialog.PositionerProps;
1393
1394
  }
1394
1395
  declare const DialogContent: ({ ref, ...props }: DialogContentProps & {
1395
1396
  ref?: React$1.Ref<HTMLDivElement>;
@@ -1728,8 +1729,10 @@ type AttachedInputsProps = RecipeVariantProps<typeof attachedInputsRecipe> & Gro
1728
1729
  } | {
1729
1730
  onFlip: () => void;
1730
1731
  flipAriaLabel: string;
1731
- });
1732
- declare const AttachedInputs: ({ ref, ...props }: AttachedInputsProps & {
1732
+ }) & {
1733
+ flipButtonProps?: Omit<IconButtonProps$1, "icon" | "aria-label" | "onClick" | "variant" | "size" | "orientation" | "spinner">;
1734
+ };
1735
+ declare const AttachedInputs: ({ ref, flipButtonProps, ...props }: AttachedInputsProps & {
1733
1736
  ref?: React.Ref<HTMLDivElement>;
1734
1737
  }) => react_jsx_runtime.JSX.Element;
1735
1738
 
@@ -2857,6 +2860,8 @@ type TagProps = VariantProps$1 & {
2857
2860
  size?: Size;
2858
2861
  title: string;
2859
2862
  description?: string;
2863
+ descriptionProps?: BoxProps;
2864
+ titleProps?: BoxProps;
2860
2865
  };
2861
2866
  type DefaultVariantProps$1 = {
2862
2867
  variant: Variant$1;
@@ -2908,7 +2913,7 @@ type InfoTagProps = TagProps & PropsWithChildren<InfoTagVariantProps>;
2908
2913
  *
2909
2914
  * @see https://spor.vy.no/components/line-tags
2910
2915
  */
2911
- declare const InfoTag: ({ variant, size, title, description, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2916
+ declare const InfoTag: ({ variant, size, title, description, descriptionProps, titleProps, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2912
2917
 
2913
2918
  declare const lineIconSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon" | "root" | "title" | "iconContainer" | "desc", {
2914
2919
  variant: {
@@ -3073,62 +3078,21 @@ declare const travelTagSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon"
3073
3078
  none: {};
3074
3079
  };
3075
3080
  variant: {
3076
- "local-train": {
3077
- container: {
3078
- backgroundColor: "linjetag.lokaltogLight";
3079
- };
3080
- };
3081
- "region-train": {
3082
- container: {
3083
- backgroundColor: "linjetag.regiontogLight";
3084
- };
3085
- };
3086
- "region-express-train": {
3087
- container: {
3088
- backgroundColor: "linjetag.regionEkspressLight";
3089
- };
3090
- };
3091
- "long-distance-train": {
3092
- container: {
3093
- backgroundColor: "linjetag.fjerntogLight";
3094
- };
3095
- };
3096
- "airport-express-train": {
3097
- container: {
3098
- backgroundColor: "linjetag.flytogLight";
3099
- };
3100
- };
3101
- "vy-bus": {
3102
- container: {
3103
- backgroundColor: "linjetag.vyBussLight";
3104
- };
3105
- };
3106
- "local-bus": {
3107
- container: {
3108
- backgroundColor: "linjetag.lokalbussLight";
3109
- };
3110
- };
3111
- ferry: {
3112
- container: {
3113
- backgroundColor: "linjetag.fergeLight";
3114
- };
3115
- };
3116
- subway: {
3117
- container: {
3118
- backgroundColor: "linjetag.tbaneLight";
3119
- };
3120
- };
3121
- tram: {
3122
- container: {
3123
- backgroundColor: "linjetag.trikkLight";
3124
- };
3125
- };
3126
- "alt-transport": {
3081
+ "local-train": {};
3082
+ "region-train": {};
3083
+ "region-express-train": {};
3084
+ "long-distance-train": {};
3085
+ "airport-express-train": {};
3086
+ "vy-bus": {};
3087
+ "local-bus": {};
3088
+ ferry: {};
3089
+ subway: {};
3090
+ tram: {};
3091
+ "alt-transport": {};
3092
+ walk: {
3127
3093
  container: {
3128
- backgroundColor: "linjetag.altTransportLight";
3094
+ backgroundColor: "none";
3129
3095
  };
3130
- };
3131
- walk: {
3132
3096
  textContainer: {
3133
3097
  position: "absolute";
3134
3098
  left: "0.875rem";
@@ -3199,7 +3163,7 @@ type TravelTagProps = TagProps & BoxProps & PropsWithChildren<TravelTagVariantPr
3199
3163
  */
3200
3164
  customIconVariant?: string;
3201
3165
  };
3202
- declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, ...rest }: TravelTagProps & {
3166
+ declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, descriptionProps, titleProps, ...rest }: TravelTagProps & {
3203
3167
  ref?: React.Ref<HTMLDivElement>;
3204
3168
  }) => react_jsx_runtime.JSX.Element;
3205
3169
 
@@ -4312,7 +4276,124 @@ declare const TooltipContent: ({ ref, children, showArrow, ...props }: TooltipPr
4312
4276
  ref?: React.Ref<HTMLDivElement>;
4313
4277
  }) => react_jsx_runtime.JSX.Element;
4314
4278
 
4279
+ declare const badgeRecipie: _chakra_ui_react.RecipeDefinition<{
4280
+ colorPalette: {
4281
+ neutral: {
4282
+ backgroundColor: "surface";
4283
+ color: "text";
4284
+ "& svg": {
4285
+ color: "icon";
4286
+ };
4287
+ };
4288
+ grey: {
4289
+ backgroundColor: "surface.neutral";
4290
+ color: "text.neutral";
4291
+ "& svg": {
4292
+ color: "icon.neutral";
4293
+ };
4294
+ };
4295
+ green: {
4296
+ backgroundColor: "surface.success";
4297
+ color: "text.success";
4298
+ "& svg": {
4299
+ color: "icon.success";
4300
+ };
4301
+ };
4302
+ blue: {
4303
+ backgroundColor: "surface.info";
4304
+ color: "text.info";
4305
+ "& svg": {
4306
+ color: "icon.info";
4307
+ };
4308
+ };
4309
+ cream: {
4310
+ backgroundColor: "surface.warning";
4311
+ color: "text.warning";
4312
+ "& svg": {
4313
+ color: "icon.warning";
4314
+ };
4315
+ };
4316
+ yellow: {
4317
+ backgroundColor: "surface.notice";
4318
+ color: "text.notice";
4319
+ "& svg": {
4320
+ color: "icon.notice";
4321
+ };
4322
+ };
4323
+ orange: {
4324
+ backgroundColor: "surface.caution";
4325
+ color: "text.caution";
4326
+ "& svg": {
4327
+ color: "icon.caution";
4328
+ };
4329
+ };
4330
+ red: {
4331
+ backgroundColor: "surface.critical";
4332
+ color: "text.critical";
4333
+ "& svg": {
4334
+ color: "icon.critical";
4335
+ };
4336
+ };
4337
+ brightRed: {
4338
+ backgroundColor: {
4339
+ _light: "brightRed";
4340
+ _dark: "brightRed";
4341
+ };
4342
+ color: {
4343
+ _light: "pink";
4344
+ _dark: "pink";
4345
+ };
4346
+ "& svg": {
4347
+ color: {
4348
+ _light: "pink";
4349
+ _dark: "pink";
4350
+ };
4351
+ };
4352
+ };
4353
+ disabled: {
4354
+ backgroundColor: "surface.disabled";
4355
+ color: "text.disabled";
4356
+ "& svg": {
4357
+ color: "icon.disabled";
4358
+ };
4359
+ };
4360
+ };
4361
+ size: {
4362
+ sm: {
4363
+ fontSize: "desktop.2xs";
4364
+ paddingX: "0.5";
4365
+ paddingY: "0";
4366
+ fontWeight: "normal";
4367
+ borderRadius: "xxs";
4368
+ };
4369
+ md: {
4370
+ fontSize: "desktop.2xs";
4371
+ paddingX: "1";
4372
+ paddingY: "0.5";
4373
+ fontWeight: "bold";
4374
+ borderRadius: "xs";
4375
+ };
4376
+ lg: {
4377
+ fontSize: "desktop.xs";
4378
+ paddingX: "1.5";
4379
+ paddingY: "0.5";
4380
+ fontWeight: "bold";
4381
+ borderRadius: "xs";
4382
+ };
4383
+ };
4384
+ attached: {
4385
+ true: {
4386
+ borderBottomRadius: "none";
4387
+ };
4388
+ };
4389
+ inverted: {
4390
+ true: {};
4391
+ };
4392
+ }>;
4393
+
4394
+ type BadgeVariantProps = RecipeVariantProps<typeof badgeRecipie>;
4315
4395
  type BadgeProps = BadgeProps$1 & {
4396
+ colorPalette?: BadgeVariantProps["colorPalette"];
4316
4397
  icon?: IconComponent;
4317
4398
  };
4318
4399
  declare const Badge: ({ ref, icon, children, ...props }: BadgeProps & {