@vygruppen/spor-react 11.1.0 → 11.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,5 +1,5 @@
1
1
 
2
- > @vygruppen/spor-react@11.1.0 build
2
+ > @vygruppen/spor-react@11.1.1 build
3
3
  > tsup src/index.tsx --dts --treeshake --format cjs,esm
4
4
 
5
5
  CLI Building entry: src/index.tsx
@@ -10,11 +10,11 @@
10
10
  ESM Build start
11
11
  DTS Build start
12
12
  ESM dist/index.mjs 2.16 KB
13
- ESM dist/CountryCodeSelect-YB3M3566.mjs 1.22 KB
14
- ESM dist/chunk-FBD6IXFW.mjs 428.46 KB
15
- ESM ⚡️ Build success in 2283ms
16
- CJS dist/index.js 542.28 KB
17
- CJS ⚡️ Build success in 2283ms
18
- DTS ⚡️ Build success in 15944ms
13
+ ESM dist/CountryCodeSelect-V422HKUV.mjs 1.22 KB
14
+ ESM dist/chunk-QFSW3GTE.mjs 428.91 KB
15
+ ESM ⚡️ Build success in 2226ms
16
+ CJS dist/index.js 542.81 KB
17
+ CJS ⚡️ Build success in 2227ms
18
+ DTS ⚡️ Build success in 15804ms
19
19
  DTS dist/index.d.ts 343.31 KB
20
20
  DTS dist/index.d.mts 343.31 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @vygruppen/spor-react
2
2
 
3
+ ## 11.1.1
4
+
5
+ ### Patch Changes
6
+
7
+ - c0e50b7: Fixed searchinput so it is more SSR friendly
8
+
3
9
  ## 11.1.0
4
10
 
5
11
  ### Minor Changes
@@ -1,4 +1,4 @@
1
- import { createTexts, useTranslation, InfoSelect, Item } from './chunk-FBD6IXFW.mjs';
1
+ import { createTexts, useTranslation, InfoSelect, Item } from './chunk-QFSW3GTE.mjs';
2
2
  import React from 'react';
3
3
  import { getSupportedCallingCodes } from 'awesome-phonenumber';
4
4
 
@@ -1844,7 +1844,7 @@ var texts4 = createTexts({
1844
1844
  sv: "Landskod"
1845
1845
  }
1846
1846
  });
1847
- var LazyCountryCodeSelect = React85__default.lazy(() => import('./CountryCodeSelect-YB3M3566.mjs'));
1847
+ var LazyCountryCodeSelect = React85__default.lazy(() => import('./CountryCodeSelect-V422HKUV.mjs'));
1848
1848
  var Radio = forwardRef((props, ref) => {
1849
1849
  return /* @__PURE__ */ React85__default.createElement(Radio$1, { ...props, ref });
1850
1850
  });
@@ -1869,16 +1869,37 @@ var SearchInput = forwardRef(
1869
1869
  ...innerProps,
1870
1870
  id: inputId,
1871
1871
  type: "search",
1872
+ placeholder: " ",
1872
1873
  css: {
1873
1874
  "&::-webkit-search-cancel-button": {
1874
1875
  WebkitAppearance: "none"
1875
1876
  }
1876
1877
  },
1877
1878
  ref,
1878
- placeholder: " ",
1879
1879
  "data-attachable": true
1880
1880
  }
1881
- ), /* @__PURE__ */ React85__default.createElement(FormLabel, { htmlFor: inputId, pointerEvents: "none" }, label ?? t2(texts5.label)), showClearButton && /* @__PURE__ */ React85__default.createElement(InputRightElement2, { width: "fit-content" }, /* @__PURE__ */ React85__default.createElement(
1881
+ ), /* @__PURE__ */ React85__default.createElement(
1882
+ FormLabel,
1883
+ {
1884
+ htmlFor: inputId,
1885
+ sx: {
1886
+ position: "absolute",
1887
+ left: "2.6rem",
1888
+ top: "26.9%",
1889
+ fontSize: "1.13rem",
1890
+ pointerEvents: "none",
1891
+ margin: 0,
1892
+ zIndex: 2,
1893
+ "input:focus + &, input[data-has-value] + &": {
1894
+ color: "var(--chakra-colors-gray-600)"
1895
+ },
1896
+ "input[data-has-value] + &": {
1897
+ transform: "translateY(-40%) scale(0.9)"
1898
+ }
1899
+ }
1900
+ },
1901
+ label ?? t2(texts5.label)
1902
+ ), showClearButton && /* @__PURE__ */ React85__default.createElement(InputRightElement2, { width: "fit-content" }, /* @__PURE__ */ React85__default.createElement(
1882
1903
  IconButton$1,
1883
1904
  {
1884
1905
  variant: "ghost",
package/dist/index.js CHANGED
@@ -2098,16 +2098,37 @@ var init_SearchInput = __esm({
2098
2098
  ...innerProps,
2099
2099
  id: inputId,
2100
2100
  type: "search",
2101
+ placeholder: " ",
2101
2102
  css: {
2102
2103
  "&::-webkit-search-cancel-button": {
2103
2104
  WebkitAppearance: "none"
2104
2105
  }
2105
2106
  },
2106
2107
  ref,
2107
- placeholder: " ",
2108
2108
  "data-attachable": true
2109
2109
  }
2110
- ), /* @__PURE__ */ React86__namespace.default.createElement(exports.FormLabel, { htmlFor: inputId, pointerEvents: "none" }, label ?? t2(texts6.label)), showClearButton && /* @__PURE__ */ React86__namespace.default.createElement(exports.InputRightElement, { width: "fit-content" }, /* @__PURE__ */ React86__namespace.default.createElement(
2110
+ ), /* @__PURE__ */ React86__namespace.default.createElement(
2111
+ exports.FormLabel,
2112
+ {
2113
+ htmlFor: inputId,
2114
+ sx: {
2115
+ position: "absolute",
2116
+ left: "2.6rem",
2117
+ top: "26.9%",
2118
+ fontSize: "1.13rem",
2119
+ pointerEvents: "none",
2120
+ margin: 0,
2121
+ zIndex: 2,
2122
+ "input:focus + &, input[data-has-value] + &": {
2123
+ color: "var(--chakra-colors-gray-600)"
2124
+ },
2125
+ "input[data-has-value] + &": {
2126
+ transform: "translateY(-40%) scale(0.9)"
2127
+ }
2128
+ }
2129
+ },
2130
+ label ?? t2(texts6.label)
2131
+ ), showClearButton && /* @__PURE__ */ React86__namespace.default.createElement(exports.InputRightElement, { width: "fit-content" }, /* @__PURE__ */ React86__namespace.default.createElement(
2111
2132
  react.IconButton,
2112
2133
  {
2113
2134
  variant: "ghost",
package/dist/index.mjs CHANGED
@@ -1 +1 @@
1
- export { Accordion, AccordionButton, AccordionIcon, AccordionItem, AccordionPanel, AttachedInputs, Badge, Box, Brand, Breadcrumb, BreadcrumbItem, BreadcrumbLink, Button, ButtonGroup, CardSelect, CargonetLogo, Center, Checkbox, CheckboxGroup, ChoiceChip, ClosableAlert, CloseButton, Code, Collapse, ColorInlineLoader, ColorSpinner, Combobox, Container, ContentLoader, DarkFullScreenLoader, DarkInlineLoader, DarkMode, DarkSpinner, DatePicker, DateRangePicker, Divider, Drawer, DrawerBody, DrawerCloseButton, DrawerContent, DrawerFooter, ModalHeader as DrawerHeader, DrawerOverlay, Expandable, ExpandableAlert, ExpandableItem, Fade, Flex, FloatingActionButton, FormControl, FormErrorMessage, FormHelperText, FormLabel, FullScreenDrawer, Grid, GridItem, HStack, Heading, IconButton, Image, Img, InfoSelect, InfoTag, Input, InputGroup, InputLeftElement, InputRightElement, Item, ItemDescription, ItemLabel, JumpButton, Language, LanguageProvider, LightFullScreenLoader, LightInlineLoader, LightMode, LightSpinner, LineIcon, ListBox, ListItem, Modal, ModalBody, ModalCloseButton, ModalContent, ModalFooter, ModalHeader, ModalOverlay, NativeSelect, Nudge, NumericStepper, OrderedList, Pagination, PasswordInput, PhoneNumberInput, PlayPauseButton, Portal, PressableCard, ProgressBar, ProgressIndicator, ProgressLoader, Radio, RadioCard, RadioCardGroup, RadioCardGroupContext, RadioGroup, ScaleFade, SearchInput, Section, ServiceAlert, SimpleDrawer, SimpleGrid, Skeleton, SkeletonCircle, SkeletonText, SkipButton, Slide, SlideFade, Spacer, SporProvider, Stack, StaticAlert, StaticCard, Stepper, StepperStep, Switch, Tab, TabList, TabPanel, TabPanels, Table, TableCaption, Tabs, Tbody, Td, Text, TextLink, Textarea, Tfoot, Th, Thead, Time, TimePicker, Tooltip, Tr, TravelTag, UnorderedList, VStack, VyLogo, VyLogoPride, WizardNudge, Wrap, WrapItem, brandTheme, createTexts, defineStyleConfig, extendTheme, fontFaces, slugify, theme, tokens, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useSize, useTheme, useToast, useToken, useTranslation } from './chunk-FBD6IXFW.mjs';
1
+ export { Accordion, AccordionButton, AccordionIcon, AccordionItem, AccordionPanel, AttachedInputs, Badge, Box, Brand, Breadcrumb, BreadcrumbItem, BreadcrumbLink, Button, ButtonGroup, CardSelect, CargonetLogo, Center, Checkbox, CheckboxGroup, ChoiceChip, ClosableAlert, CloseButton, Code, Collapse, ColorInlineLoader, ColorSpinner, Combobox, Container, ContentLoader, DarkFullScreenLoader, DarkInlineLoader, DarkMode, DarkSpinner, DatePicker, DateRangePicker, Divider, Drawer, DrawerBody, DrawerCloseButton, DrawerContent, DrawerFooter, ModalHeader as DrawerHeader, DrawerOverlay, Expandable, ExpandableAlert, ExpandableItem, Fade, Flex, FloatingActionButton, FormControl, FormErrorMessage, FormHelperText, FormLabel, FullScreenDrawer, Grid, GridItem, HStack, Heading, IconButton, Image, Img, InfoSelect, InfoTag, Input, InputGroup, InputLeftElement, InputRightElement, Item, ItemDescription, ItemLabel, JumpButton, Language, LanguageProvider, LightFullScreenLoader, LightInlineLoader, LightMode, LightSpinner, LineIcon, ListBox, ListItem, Modal, ModalBody, ModalCloseButton, ModalContent, ModalFooter, ModalHeader, ModalOverlay, NativeSelect, Nudge, NumericStepper, OrderedList, Pagination, PasswordInput, PhoneNumberInput, PlayPauseButton, Portal, PressableCard, ProgressBar, ProgressIndicator, ProgressLoader, Radio, RadioCard, RadioCardGroup, RadioCardGroupContext, RadioGroup, ScaleFade, SearchInput, Section, ServiceAlert, SimpleDrawer, SimpleGrid, Skeleton, SkeletonCircle, SkeletonText, SkipButton, Slide, SlideFade, Spacer, SporProvider, Stack, StaticAlert, StaticCard, Stepper, StepperStep, Switch, Tab, TabList, TabPanel, TabPanels, Table, TableCaption, Tabs, Tbody, Td, Text, TextLink, Textarea, Tfoot, Th, Thead, Time, TimePicker, Tooltip, Tr, TravelTag, UnorderedList, VStack, VyLogo, VyLogoPride, WizardNudge, Wrap, WrapItem, brandTheme, createTexts, defineStyleConfig, extendTheme, fontFaces, slugify, theme, tokens, useBreakpointValue, useClipboard, useColorMode, useColorModePreference, useColorModeValue, useControllableProp, useDisclosure, useMediaQuery, useMergeRefs, useOutsideClick, usePrefersReducedMotion, useSize, useTheme, useToast, useToken, useTranslation } from './chunk-QFSW3GTE.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vygruppen/spor-react",
3
- "version": "11.1.0",
3
+ "version": "11.1.1",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -48,16 +48,33 @@ export const SearchInput = forwardRef<SearchInputProps, "input">(
48
48
  {...innerProps}
49
49
  id={inputId}
50
50
  type="search"
51
+ placeholder=" "
51
52
  css={{
52
53
  "&::-webkit-search-cancel-button": {
53
54
  WebkitAppearance: "none",
54
55
  },
55
56
  }}
56
57
  ref={ref}
57
- placeholder=" " // This is needed to make the label work as expected
58
58
  data-attachable
59
59
  />
60
- <FormLabel htmlFor={inputId} pointerEvents="none">
60
+ <FormLabel
61
+ htmlFor={inputId}
62
+ sx={{
63
+ position: "absolute",
64
+ left: "2.6rem",
65
+ top: "26.9%",
66
+ fontSize: "1.13rem",
67
+ pointerEvents: "none",
68
+ margin: 0,
69
+ zIndex: 2,
70
+ "input:focus + &, input[data-has-value] + &": {
71
+ color: "var(--chakra-colors-gray-600)",
72
+ },
73
+ "input[data-has-value] + &": {
74
+ transform: "translateY(-40%) scale(0.9)",
75
+ },
76
+ }}
77
+ >
61
78
  {label ?? t(texts.label)}
62
79
  </FormLabel>
63
80
  {showClearButton && (