@vygruppen/spor-react 12.0.7 → 12.1.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.
@@ -1,9 +1,9 @@
1
1
 
2
- > @vygruppen/spor-react@12.0.7 build /home/runner/work/spor/spor/packages/spor-react
2
+ > @vygruppen/spor-react@12.1.1 build /home/runner/work/spor/spor/packages/spor-react
3
3
  > pnpm typegen && tsup
4
4
 
5
5
 
6
- > @vygruppen/spor-react@12.0.7 typegen /home/runner/work/spor/spor/packages/spor-react
6
+ > @vygruppen/spor-react@12.1.1 typegen /home/runner/work/spor/spor/packages/spor-react
7
7
  > npx @chakra-ui/cli typegen src/theme/index.ts
8
8
 
9
9
  ┌ Chakra CLI ⚡️
@@ -16,8 +16,7 @@
16
16
  [?25h[?25l│
17
17
  ◇ ✅ Generated utility typings
18
18
  [?25h[?25l│
19
- ◒ Generating token types...
20
- ◇ ✅ Generated token typings
19
+ ◇ Generated token typings
21
20
  [?25h[?25l│
22
21
  ◒ Generating system types...
23
22
  ◇ ✅ Generated system types
@@ -32,12 +31,12 @@ CLI Target: node16
32
31
  CJS Build start
33
32
  ESM Build start
34
33
  DTS Build start
35
- CJS dist/index.js 312.51 KB
36
- CJS dist/index.js.map 620.50 KB
37
- CJS ⚡️ Build success in 1917ms
38
- ESM dist/index.mjs 293.23 KB
39
- ESM dist/index.mjs.map 620.50 KB
40
- ESM ⚡️ Build success in 1920ms
41
- DTS ⚡️ Build success in 21178ms
42
- DTS dist/index.d.ts 134.71 KB
43
- DTS dist/index.d.mts 134.71 KB
34
+ ESM dist/index.mjs 293.19 KB
35
+ ESM dist/index.mjs.map 620.63 KB
36
+ ESM ⚡️ Build success in 1854ms
37
+ CJS dist/index.js 312.69 KB
38
+ CJS dist/index.js.map 620.63 KB
39
+ CJS ⚡️ Build success in 1855ms
40
+ DTS ⚡️ Build success in 21349ms
41
+ DTS dist/index.d.ts 134.76 KB
42
+ DTS dist/index.d.mts 134.76 KB
@@ -1,5 +1,5 @@
1
1
 
2
- > @vygruppen/spor-react@12.0.7 typegen /home/runner/work/spor/spor/packages/spor-react
2
+ > @vygruppen/spor-react@12.1.1 typegen /home/runner/work/spor/spor/packages/spor-react
3
3
  > npx @chakra-ui/cli typegen src/theme/index.ts
4
4
 
5
5
  ┌ Chakra CLI ⚡️
package/CHANGELOG.md CHANGED
@@ -1,5 +1,26 @@
1
1
  # @vygruppen/spor-react
2
2
 
3
+ ## 12.1.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [5e6da7b]
8
+ - @vygruppen/spor-design-tokens@4.0.5
9
+
10
+ ## 12.1.0
11
+
12
+ ### Minor Changes
13
+
14
+ - b1c49c8: - Removed unused `patch-package` from `spor-design-tokens`.
15
+ - Refactored theme setup in `spor-react` for type support and extending theme support.
16
+ - Updated `eslint-config` to better support React 17+ adding jsx runtime rules.
17
+
18
+ ### Patch Changes
19
+
20
+ - Updated dependencies [b1c49c8]
21
+ - @vygruppen/spor-design-tokens@4.0.4
22
+ - @vygruppen/spor-icon-react@4.0.3
23
+
3
24
  ## 12.0.7
4
25
 
5
26
  ### Patch Changes
package/dist/index.d.mts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as _chakra_ui_react from '@chakra-ui/react';
2
- import { Accordion as Accordion$1, Alert as Alert$1, ConditionalValue, Breadcrumb as Breadcrumb$1, RecipeVariantProps, ButtonProps as ButtonProps$1, GroupProps, Clipboard as Clipboard$1, IconButtonProps as IconButtonProps$1, BoxProps, Dialog, Drawer as Drawer$1, InputElementProps, PopoverRootProps, Checkbox as Checkbox$1, CheckboxGroupProps as CheckboxGroupProps$1, Fieldset as Fieldset$1, Field as Field$1, InputProps as InputProps$1, ListRootProps, NativeSelectFieldProps, NativeSelect as NativeSelect$1, RadioGroup as RadioGroup$1, SelectRootProps, Select as Select$1, CollectionItem, Switch as Switch$1, TextareaProps as TextareaProps$1, RadioCard as RadioCard$1, SeparatorProps, LinkProps as LinkProps$1, List as List$1, UseProgressProps, SkeletonProps as SkeletonProps$1, CircleProps, Popover as Popover$1, Pagination as Pagination$1, ChakraProviderProps, TabsRootProps, Tabs as Tabs$1, TableRootProps, Table as Table$1, BadgeProps as BadgeProps$1, CodeProps, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
3
- export { Box, BoxProps, Center, CenterProps, Collapsible, CollapsibleRootProps, Container, ContainerProps, Em, Flex, FlexProps, For, FormatByte, FormatNumber, Grid, GridItem, GridItemProps, GridProps, HStack, Image, ImageProps, Kbd, LocaleProvider, Portal, PortalProps, Show, SimpleGrid, SimpleGridProps, Spacer, SpacerProps, Span, Stack, TableBody, TableBodyProps, TableCaption, TableCaptionProps, TableCell, TableCellProps, TableColumn, TableColumnHeader, TableColumnHeaderProps, TableColumnProps, TableFooter, TableFooterProps, TableHeader, TableHeaderProps, TableRoot, TableRootProps, TableRow, TableRowProps, UseDisclosureProps, VStack, VisuallyHidden, createListCollection, defineRecipe, defineStyle, useBreakpointValue, useCheckbox, useClipboard, useControllableProp, useDisclosure, useMediaQuery, useToken } from '@chakra-ui/react';
2
+ import { Accordion as Accordion$1, Alert as Alert$1, ConditionalValue, Breadcrumb as Breadcrumb$1, RecipeVariantProps, ButtonProps as ButtonProps$1, GroupProps, Clipboard as Clipboard$1, IconButtonProps as IconButtonProps$1, BoxProps, Dialog, Drawer as Drawer$1, InputElementProps, PopoverRootProps, Checkbox as Checkbox$1, CheckboxGroupProps as CheckboxGroupProps$1, Fieldset as Fieldset$1, Field as Field$1, InputProps as InputProps$1, ListRootProps, NativeSelectFieldProps, NativeSelect as NativeSelect$1, RadioGroup as RadioGroup$1, SelectRootProps, Select as Select$1, CollectionItem, Switch as Switch$1, TextareaProps as TextareaProps$1, RadioCard as RadioCard$1, SeparatorProps, LinkProps as LinkProps$1, List as List$1, UseProgressProps, SkeletonProps as SkeletonProps$1, CircleProps, Popover as Popover$1, Pagination as Pagination$1, ChakraProviderProps, SystemContext, TabsRootProps, Tabs as Tabs$1, TableRootProps, Table as Table$1, BadgeProps as BadgeProps$1, CodeProps, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
3
+ export { Box, BoxProps, Center, CenterProps, Collapsible, CollapsibleRootProps, Container, ContainerProps, Em, Flex, FlexProps, For, FormatByte, FormatNumber, Grid, GridItem, GridItemProps, GridProps, HStack, Image, ImageProps, Kbd, LocaleProvider, Portal, PortalProps, Show, SimpleGrid, SimpleGridProps, Spacer, SpacerProps, Span, Stack, TableBody, TableBodyProps, TableCaption, TableCaptionProps, TableCell, TableCellProps, TableColumn, TableColumnHeader, TableColumnHeaderProps, TableColumnProps, TableFooter, TableFooterProps, TableHeader, TableHeaderProps, TableRoot, TableRootProps, TableRow, TableRowProps, UseDisclosureProps, VStack, VisuallyHidden, createListCollection, createSystem, defineConfig, defineRecipe, defineStyle, useBreakpointValue, useCheckbox, useClipboard, useControllableProp, useDisclosure, useMediaQuery, useToken } from '@chakra-ui/react';
4
4
  import * as React$1 from 'react';
5
5
  import React__default, { PropsWithChildren, ReactNode, ChangeEvent } from 'react';
6
6
  import { IconComponent } from '@vygruppen/spor-icon-react';
@@ -3158,18 +3158,9 @@ declare const ProgressIndicator: React__default.ForwardRefExoticComponent<BoxPro
3158
3158
  colorPalette?: string;
3159
3159
  } & React__default.RefAttributes<HTMLDivElement>>;
3160
3160
 
3161
- /** A string of CSS that should be injected in the global CSS space */
3162
- declare const fontFaces: string;
3163
-
3164
- declare enum Brand {
3165
- VyDigital = "VyDigital",
3166
- VyUtvikling = "VyUtvikling",
3167
- CargoNet = "CargoNet"
3168
- }
3169
-
3170
3161
  type SporProviderProps = Omit<ChakraProviderProps, "value"> & {
3171
3162
  language?: Language;
3172
- brand?: Brand;
3163
+ theme?: SystemContext;
3173
3164
  };
3174
3165
  /**
3175
3166
  * This component is used to provide the specified theme of colors and other
@@ -3208,7 +3199,7 @@ import { theme } from '../../../../apps/docs/app/features/portable-text/code-blo
3208
3199
  * );
3209
3200
  * ```
3210
3201
  */
3211
- declare const SporProvider: ({ language, brand, children, }: SporProviderProps) => React__default.JSX.Element;
3202
+ declare const SporProvider: ({ language, theme, children, }: SporProviderProps) => React__default.JSX.Element;
3212
3203
 
3213
3204
  declare const stepperSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"root" | "title" | "closeButton" | "container" | "innerContainer" | "stepCounter" | "stepContainer" | "stepButton" | "stepNumber" | "stepTitle" | "backButton", {
3214
3205
  variant: {
@@ -3709,6 +3700,15 @@ declare const themes: {
3709
3700
  };
3710
3701
  declare const system: _chakra_ui_react.SystemContext;
3711
3702
 
3703
+ /** A string of CSS that should be injected in the global CSS space */
3704
+ declare const fontFaces: string;
3705
+
3706
+ declare enum Brand {
3707
+ VyDigital = "VyDigital",
3708
+ VyUtvikling = "VyUtvikling",
3709
+ CargoNet = "CargoNet"
3710
+ }
3711
+
3712
3712
  type Variant = "info" | "success" | "error";
3713
3713
  type ToastProps = {
3714
3714
  duration?: number;
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as _chakra_ui_react from '@chakra-ui/react';
2
- import { Accordion as Accordion$1, Alert as Alert$1, ConditionalValue, Breadcrumb as Breadcrumb$1, RecipeVariantProps, ButtonProps as ButtonProps$1, GroupProps, Clipboard as Clipboard$1, IconButtonProps as IconButtonProps$1, BoxProps, Dialog, Drawer as Drawer$1, InputElementProps, PopoverRootProps, Checkbox as Checkbox$1, CheckboxGroupProps as CheckboxGroupProps$1, Fieldset as Fieldset$1, Field as Field$1, InputProps as InputProps$1, ListRootProps, NativeSelectFieldProps, NativeSelect as NativeSelect$1, RadioGroup as RadioGroup$1, SelectRootProps, Select as Select$1, CollectionItem, Switch as Switch$1, TextareaProps as TextareaProps$1, RadioCard as RadioCard$1, SeparatorProps, LinkProps as LinkProps$1, List as List$1, UseProgressProps, SkeletonProps as SkeletonProps$1, CircleProps, Popover as Popover$1, Pagination as Pagination$1, ChakraProviderProps, TabsRootProps, Tabs as Tabs$1, TableRootProps, Table as Table$1, BadgeProps as BadgeProps$1, CodeProps, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
3
- export { Box, BoxProps, Center, CenterProps, Collapsible, CollapsibleRootProps, Container, ContainerProps, Em, Flex, FlexProps, For, FormatByte, FormatNumber, Grid, GridItem, GridItemProps, GridProps, HStack, Image, ImageProps, Kbd, LocaleProvider, Portal, PortalProps, Show, SimpleGrid, SimpleGridProps, Spacer, SpacerProps, Span, Stack, TableBody, TableBodyProps, TableCaption, TableCaptionProps, TableCell, TableCellProps, TableColumn, TableColumnHeader, TableColumnHeaderProps, TableColumnProps, TableFooter, TableFooterProps, TableHeader, TableHeaderProps, TableRoot, TableRootProps, TableRow, TableRowProps, UseDisclosureProps, VStack, VisuallyHidden, createListCollection, defineRecipe, defineStyle, useBreakpointValue, useCheckbox, useClipboard, useControllableProp, useDisclosure, useMediaQuery, useToken } from '@chakra-ui/react';
2
+ import { Accordion as Accordion$1, Alert as Alert$1, ConditionalValue, Breadcrumb as Breadcrumb$1, RecipeVariantProps, ButtonProps as ButtonProps$1, GroupProps, Clipboard as Clipboard$1, IconButtonProps as IconButtonProps$1, BoxProps, Dialog, Drawer as Drawer$1, InputElementProps, PopoverRootProps, Checkbox as Checkbox$1, CheckboxGroupProps as CheckboxGroupProps$1, Fieldset as Fieldset$1, Field as Field$1, InputProps as InputProps$1, ListRootProps, NativeSelectFieldProps, NativeSelect as NativeSelect$1, RadioGroup as RadioGroup$1, SelectRootProps, Select as Select$1, CollectionItem, Switch as Switch$1, TextareaProps as TextareaProps$1, RadioCard as RadioCard$1, SeparatorProps, LinkProps as LinkProps$1, List as List$1, UseProgressProps, SkeletonProps as SkeletonProps$1, CircleProps, Popover as Popover$1, Pagination as Pagination$1, ChakraProviderProps, SystemContext, TabsRootProps, Tabs as Tabs$1, TableRootProps, Table as Table$1, BadgeProps as BadgeProps$1, CodeProps, HeadingProps as HeadingProps$1, TextProps as TextProps$1 } from '@chakra-ui/react';
3
+ export { Box, BoxProps, Center, CenterProps, Collapsible, CollapsibleRootProps, Container, ContainerProps, Em, Flex, FlexProps, For, FormatByte, FormatNumber, Grid, GridItem, GridItemProps, GridProps, HStack, Image, ImageProps, Kbd, LocaleProvider, Portal, PortalProps, Show, SimpleGrid, SimpleGridProps, Spacer, SpacerProps, Span, Stack, TableBody, TableBodyProps, TableCaption, TableCaptionProps, TableCell, TableCellProps, TableColumn, TableColumnHeader, TableColumnHeaderProps, TableColumnProps, TableFooter, TableFooterProps, TableHeader, TableHeaderProps, TableRoot, TableRootProps, TableRow, TableRowProps, UseDisclosureProps, VStack, VisuallyHidden, createListCollection, createSystem, defineConfig, defineRecipe, defineStyle, useBreakpointValue, useCheckbox, useClipboard, useControllableProp, useDisclosure, useMediaQuery, useToken } from '@chakra-ui/react';
4
4
  import * as React$1 from 'react';
5
5
  import React__default, { PropsWithChildren, ReactNode, ChangeEvent } from 'react';
6
6
  import { IconComponent } from '@vygruppen/spor-icon-react';
@@ -3158,18 +3158,9 @@ declare const ProgressIndicator: React__default.ForwardRefExoticComponent<BoxPro
3158
3158
  colorPalette?: string;
3159
3159
  } & React__default.RefAttributes<HTMLDivElement>>;
3160
3160
 
3161
- /** A string of CSS that should be injected in the global CSS space */
3162
- declare const fontFaces: string;
3163
-
3164
- declare enum Brand {
3165
- VyDigital = "VyDigital",
3166
- VyUtvikling = "VyUtvikling",
3167
- CargoNet = "CargoNet"
3168
- }
3169
-
3170
3161
  type SporProviderProps = Omit<ChakraProviderProps, "value"> & {
3171
3162
  language?: Language;
3172
- brand?: Brand;
3163
+ theme?: SystemContext;
3173
3164
  };
3174
3165
  /**
3175
3166
  * This component is used to provide the specified theme of colors and other
@@ -3208,7 +3199,7 @@ import { theme } from '../../../../apps/docs/app/features/portable-text/code-blo
3208
3199
  * );
3209
3200
  * ```
3210
3201
  */
3211
- declare const SporProvider: ({ language, brand, children, }: SporProviderProps) => React__default.JSX.Element;
3202
+ declare const SporProvider: ({ language, theme, children, }: SporProviderProps) => React__default.JSX.Element;
3212
3203
 
3213
3204
  declare const stepperSlotRecipe: _chakra_ui_react.SlotRecipeDefinition<"root" | "title" | "closeButton" | "container" | "innerContainer" | "stepCounter" | "stepContainer" | "stepButton" | "stepNumber" | "stepTitle" | "backButton", {
3214
3205
  variant: {
@@ -3709,6 +3700,15 @@ declare const themes: {
3709
3700
  };
3710
3701
  declare const system: _chakra_ui_react.SystemContext;
3711
3702
 
3703
+ /** A string of CSS that should be injected in the global CSS space */
3704
+ declare const fontFaces: string;
3705
+
3706
+ declare enum Brand {
3707
+ VyDigital = "VyDigital",
3708
+ VyUtvikling = "VyUtvikling",
3709
+ CargoNet = "CargoNet"
3710
+ }
3711
+
3712
3712
  type Variant = "info" | "success" | "error";
3713
3713
  type ToastProps = {
3714
3714
  duration?: number;
package/dist/index.js CHANGED
@@ -5811,10 +5811,10 @@ var texts25 = createTexts({
5811
5811
  // src/provider/SporProvider.tsx
5812
5812
  var SporProvider = ({
5813
5813
  language = "nb" /* NorwegianBokmal */,
5814
- brand = "VyDigital" /* VyDigital */,
5814
+ theme = system,
5815
5815
  children
5816
5816
  }) => {
5817
- return /* @__PURE__ */ React67__namespace.default.createElement(LanguageProvider, { language }, /* @__PURE__ */ React67__namespace.default.createElement(react.ChakraProvider, { value: themes[brand] ?? system }, /* @__PURE__ */ React67__namespace.default.createElement(ColorModeProvider, null, /* @__PURE__ */ React67__namespace.default.createElement(Toaster, null), /* @__PURE__ */ React67__namespace.default.createElement(react$2.Global, { styles: fontFaces }), children)));
5817
+ return /* @__PURE__ */ React67__namespace.default.createElement(LanguageProvider, { language }, /* @__PURE__ */ React67__namespace.default.createElement(react.ChakraProvider, { value: theme }, /* @__PURE__ */ React67__namespace.default.createElement(ColorModeProvider, null, /* @__PURE__ */ React67__namespace.default.createElement(Toaster, null), /* @__PURE__ */ React67__namespace.default.createElement(react$2.Global, { styles: fontFaces }), children)));
5818
5818
  };
5819
5819
  var StepperContext = React67__namespace.default.createContext(null);
5820
5820
  var StepperProvider = ({
@@ -10227,8 +10227,6 @@ var textStyles = react.defineTextStyles({
10227
10227
  }
10228
10228
  }
10229
10229
  });
10230
-
10231
- // src/theme/index.ts
10232
10230
  var generateTheme = (brand) => {
10233
10231
  return react.defineConfig({
10234
10232
  ...config,
@@ -10393,6 +10391,14 @@ Object.defineProperty(exports, "createListCollection", {
10393
10391
  enumerable: true,
10394
10392
  get: function () { return react.createListCollection; }
10395
10393
  });
10394
+ Object.defineProperty(exports, "createSystem", {
10395
+ enumerable: true,
10396
+ get: function () { return react.createSystem; }
10397
+ });
10398
+ Object.defineProperty(exports, "defineConfig", {
10399
+ enumerable: true,
10400
+ get: function () { return react.defineConfig; }
10401
+ });
10396
10402
  Object.defineProperty(exports, "defineRecipe", {
10397
10403
  enumerable: true,
10398
10404
  get: function () { return react.defineRecipe; }