@vygruppen/spor-react 13.4.0 → 13.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -2857,6 +2857,8 @@ type TagProps = VariantProps$1 & {
2857
2857
  size?: Size;
2858
2858
  title: string;
2859
2859
  description?: string;
2860
+ descriptionProps?: BoxProps;
2861
+ titleProps?: BoxProps;
2860
2862
  };
2861
2863
  type DefaultVariantProps$1 = {
2862
2864
  variant: Variant$1;
@@ -2908,7 +2910,7 @@ type InfoTagProps = TagProps & PropsWithChildren<InfoTagVariantProps>;
2908
2910
  *
2909
2911
  * @see https://spor.vy.no/components/line-tags
2910
2912
  */
2911
- declare const InfoTag: ({ variant, size, title, description, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2913
+ declare const InfoTag: ({ variant, size, title, description, descriptionProps, titleProps, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2912
2914
 
2913
2915
  declare const lineIconSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon" | "root" | "title" | "iconContainer" | "desc", {
2914
2916
  variant: {
@@ -3073,62 +3075,21 @@ declare const travelTagSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon"
3073
3075
  none: {};
3074
3076
  };
3075
3077
  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": {
3078
+ "local-train": {};
3079
+ "region-train": {};
3080
+ "region-express-train": {};
3081
+ "long-distance-train": {};
3082
+ "airport-express-train": {};
3083
+ "vy-bus": {};
3084
+ "local-bus": {};
3085
+ ferry: {};
3086
+ subway: {};
3087
+ tram: {};
3088
+ "alt-transport": {};
3089
+ walk: {
3127
3090
  container: {
3128
- backgroundColor: "linjetag.altTransportLight";
3091
+ backgroundColor: "none";
3129
3092
  };
3130
- };
3131
- walk: {
3132
3093
  textContainer: {
3133
3094
  position: "absolute";
3134
3095
  left: "0.875rem";
@@ -3199,7 +3160,7 @@ type TravelTagProps = TagProps & BoxProps & PropsWithChildren<TravelTagVariantPr
3199
3160
  */
3200
3161
  customIconVariant?: string;
3201
3162
  };
3202
- declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, ...rest }: TravelTagProps & {
3163
+ declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, descriptionProps, titleProps, ...rest }: TravelTagProps & {
3203
3164
  ref?: React.Ref<HTMLDivElement>;
3204
3165
  }) => react_jsx_runtime.JSX.Element;
3205
3166
 
package/dist/index.d.ts CHANGED
@@ -2857,6 +2857,8 @@ type TagProps = VariantProps$1 & {
2857
2857
  size?: Size;
2858
2858
  title: string;
2859
2859
  description?: string;
2860
+ descriptionProps?: BoxProps;
2861
+ titleProps?: BoxProps;
2860
2862
  };
2861
2863
  type DefaultVariantProps$1 = {
2862
2864
  variant: Variant$1;
@@ -2908,7 +2910,7 @@ type InfoTagProps = TagProps & PropsWithChildren<InfoTagVariantProps>;
2908
2910
  *
2909
2911
  * @see https://spor.vy.no/components/line-tags
2910
2912
  */
2911
- declare const InfoTag: ({ variant, size, title, description, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2913
+ declare const InfoTag: ({ variant, size, title, description, descriptionProps, titleProps, ...customProps }: InfoTagProps) => react_jsx_runtime.JSX.Element;
2912
2914
 
2913
2915
  declare const lineIconSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon" | "root" | "title" | "iconContainer" | "desc", {
2914
2916
  variant: {
@@ -3073,62 +3075,21 @@ declare const travelTagSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"icon"
3073
3075
  none: {};
3074
3076
  };
3075
3077
  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": {
3078
+ "local-train": {};
3079
+ "region-train": {};
3080
+ "region-express-train": {};
3081
+ "long-distance-train": {};
3082
+ "airport-express-train": {};
3083
+ "vy-bus": {};
3084
+ "local-bus": {};
3085
+ ferry: {};
3086
+ subway: {};
3087
+ tram: {};
3088
+ "alt-transport": {};
3089
+ walk: {
3127
3090
  container: {
3128
- backgroundColor: "linjetag.altTransportLight";
3091
+ backgroundColor: "none";
3129
3092
  };
3130
- };
3131
- walk: {
3132
3093
  textContainer: {
3133
3094
  position: "absolute";
3134
3095
  left: "0.875rem";
@@ -3199,7 +3160,7 @@ type TravelTagProps = TagProps & BoxProps & PropsWithChildren<TravelTagVariantPr
3199
3160
  */
3200
3161
  customIconVariant?: string;
3201
3162
  };
3202
- declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, ...rest }: TravelTagProps & {
3163
+ declare const TravelTag: ({ ref, variant, size, deviationLevel, title, description, disabled, foregroundColor, backgroundColor, customIconVariant, descriptionProps, titleProps, ...rest }: TravelTagProps & {
3203
3164
  ref?: React.Ref<HTMLDivElement>;
3204
3165
  }) => react_jsx_runtime.JSX.Element;
3205
3166
 
package/dist/index.mjs CHANGED
@@ -5389,7 +5389,7 @@ var LineIcon = function LineIcon2({
5389
5389
  borderColor: variant === "walk" ? "outline.core" : "transparent",
5390
5390
  "aria-label": label,
5391
5391
  ref,
5392
- className: clsx_default("light", rest.className),
5392
+ className: variant === "walk" ? void 0 : clsx_default("light", rest.className),
5393
5393
  children: /* @__PURE__ */ jsx(LinjeTagIcon, { size, css: styles.icon, variant: getIconVariant() })
5394
5394
  }
5395
5395
  );
@@ -5399,6 +5399,8 @@ var InfoTag = ({
5399
5399
  size = "md",
5400
5400
  title,
5401
5401
  description,
5402
+ descriptionProps,
5403
+ titleProps,
5402
5404
  ...customProps
5403
5405
  }) => {
5404
5406
  const recipe = useSlotRecipe({ key: "infoTag" });
@@ -5417,9 +5419,9 @@ var InfoTag = ({
5417
5419
  }
5418
5420
  ),
5419
5421
  /* @__PURE__ */ jsxs(Box, { css: styles.textContainer, children: [
5420
- title && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.title, children: title }),
5422
+ title && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.title, ...titleProps, children: title }),
5421
5423
  title && description && " ",
5422
- description && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.description, children: description })
5424
+ description && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.description, ...descriptionProps, children: description })
5423
5425
  ] })
5424
5426
  ] });
5425
5427
  };
@@ -5451,6 +5453,8 @@ var TravelTag = function TravelTag2({
5451
5453
  foregroundColor,
5452
5454
  backgroundColor,
5453
5455
  customIconVariant,
5456
+ descriptionProps,
5457
+ titleProps,
5454
5458
  ...rest
5455
5459
  }) {
5456
5460
  const recipie = useSlotRecipe({ key: "travelTag" });
@@ -5465,7 +5469,6 @@ var TravelTag = function TravelTag2({
5465
5469
  css: styles.container,
5466
5470
  "aria-disabled": disabled,
5467
5471
  ref,
5468
- className: clsx_default("light", rest.className),
5469
5472
  backgroundColor,
5470
5473
  ...rest,
5471
5474
  children: [
@@ -5483,9 +5486,9 @@ var TravelTag = function TravelTag2({
5483
5486
  }
5484
5487
  ),
5485
5488
  /* @__PURE__ */ jsxs(Box, { css: styles.textContainer, children: [
5486
- title && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.title, children: title }),
5489
+ title && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.title, ...titleProps, children: title }),
5487
5490
  title && description && " ",
5488
- description && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.description, children: description })
5491
+ description && /* @__PURE__ */ jsx(Box, { as: "span", css: styles.description, ...descriptionProps, children: description })
5489
5492
  ] }),
5490
5493
  renderDeviationLevelIcon(deviationLevel, size, styles.deviationIcon)
5491
5494
  ]
@@ -9989,9 +9992,7 @@ var travelTagSlotRecipe = defineSlotRecipe({
9989
9992
  display: "flex",
9990
9993
  alignItems: "center",
9991
9994
  padding: 0.5,
9992
- _disabled: {
9993
- background: "surface.disabled"
9994
- },
9995
+ backgroundColor: "surface.disabled",
9995
9996
  width: "fit-content",
9996
9997
  transitionDuration: "fast",
9997
9998
  transitionProperty: "common",
@@ -10055,62 +10056,21 @@ var travelTagSlotRecipe = defineSlotRecipe({
10055
10056
  none: {}
10056
10057
  },
10057
10058
  variant: {
10058
- "local-train": {
10059
- container: {
10060
- backgroundColor: "linjetag.lokaltogLight"
10061
- }
10062
- },
10063
- "region-train": {
10064
- container: {
10065
- backgroundColor: "linjetag.regiontogLight"
10066
- }
10067
- },
10068
- "region-express-train": {
10069
- container: {
10070
- backgroundColor: "linjetag.regionEkspressLight"
10071
- }
10072
- },
10073
- "long-distance-train": {
10074
- container: {
10075
- backgroundColor: "linjetag.fjerntogLight"
10076
- }
10077
- },
10078
- "airport-express-train": {
10079
- container: {
10080
- backgroundColor: "linjetag.flytogLight"
10081
- }
10082
- },
10083
- "vy-bus": {
10084
- container: {
10085
- backgroundColor: "linjetag.vyBussLight"
10086
- }
10087
- },
10088
- "local-bus": {
10089
- container: {
10090
- backgroundColor: "linjetag.lokalbussLight"
10091
- }
10092
- },
10093
- ferry: {
10094
- container: {
10095
- backgroundColor: "linjetag.fergeLight"
10096
- }
10097
- },
10098
- subway: {
10099
- container: {
10100
- backgroundColor: "linjetag.tbaneLight"
10101
- }
10102
- },
10103
- tram: {
10104
- container: {
10105
- backgroundColor: "linjetag.trikkLight"
10106
- }
10107
- },
10108
- "alt-transport": {
10109
- container: {
10110
- backgroundColor: "linjetag.altTransportLight"
10111
- }
10112
- },
10059
+ "local-train": {},
10060
+ "region-train": {},
10061
+ "region-express-train": {},
10062
+ "long-distance-train": {},
10063
+ "airport-express-train": {},
10064
+ "vy-bus": {},
10065
+ "local-bus": {},
10066
+ ferry: {},
10067
+ subway: {},
10068
+ tram: {},
10069
+ "alt-transport": {},
10113
10070
  walk: {
10071
+ container: {
10072
+ backgroundColor: "none"
10073
+ },
10114
10074
  textContainer: {
10115
10075
  position: "absolute",
10116
10076
  left: "0.875rem",