@vygruppen/spor-react 12.4.12 → 12.4.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 +1 -1
- package/CHANGELOG.md +13 -0
- package/dist/index.d.mts +3 -32
- package/dist/index.d.ts +3 -32
- package/dist/index.js +32 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +33 -10
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
- package/src/input/Combobox.tsx +7 -6
- package/src/input/Field.tsx +1 -1
- package/src/link/TextLink.tsx +28 -23
- package/src/theme/recipes/link.ts +19 -0
package/dist/index.mjs
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { useSlotRecipe, Accordion as Accordion$1, Stack, Box, HStack, Progress, defineRecipe, chakra, Text, useRecipe, Circle, Skeleton as Skeleton$1, Button as Button$1, Group as Group$1, Badge as Badge$1, Code as Code$1, Clipboard as Clipboard$1, IconButton as IconButton$1, useDisclosure, Alert as Alert$1, Span, Flex, Breadcrumb as Breadcrumb$1, ClientOnly as ClientOnly$1, Field, defineStyle, defineSlotRecipe, PopoverAnchor, useFieldContext, Popover as Popover$1, Portal, Dialog, createContext as createContext$1, Drawer as Drawer$1, Grid, GridItem, usePopoverContext, Checkbox as Checkbox$1, CheckboxGroup as CheckboxGroup$1, CheckboxCard, Fieldset as Fieldset$1, Input as Input$1, InputElement, NativeSelect as NativeSelect$1, useControllableState, createListCollection, RadioGroup as RadioGroup$1, Select as Select$1, useSelectContext, Switch as Switch$1, Textarea as Textarea$1, RadioCard as RadioCard$1, Separator as Separator$1, Link, List as List$1, Center, PopoverCloseTrigger, Pagination as Pagination$1, usePaginationContext, createToaster, Tabs as Tabs$1, Table as Table$1, defineSemanticTokens, defineTokens, defineAnimationStyles, defineGlobalStyles, defineTextStyles, createSystem, defaultBaseConfig, VisuallyHidden, defineConfig, ListItem, ChakraProvider, Toaster as Toaster$1, Toast, Icon } from '@chakra-ui/react';
|
2
2
|
export { Box, BreadcrumbCurrentLink, BreadcrumbEllipsis, BreadcrumbLink, Center, ClientOnly, Collapsible, Container, Em, Flex, For, FormatByte, FormatNumber, Grid, GridItem, HStack, Image, Kbd, LocaleProvider, Portal, Show, SimpleGrid, Spacer, Span, Stack, TableBody, TableCaption, TableCell, TableColumn, TableColumnGroup, TableColumnHeader, TableFooter, TableHeader, TableRoot, TableRow, VStack, VisuallyHidden, createListCollection, createSystem, defineConfig, defineRecipe, defineStyle, useBreakpointValue, useCheckbox, useClipboard, useControllableProp, useDisclosure, useMediaQuery, useToken } from '@chakra-ui/react';
|
3
|
-
import { DropdownDownFill24Icon, CopyOutline18Icon, CheckmarkFill18Icon, CloseFill18Icon, CloseFill30Icon, CloseFill24Icon, ServiceFill24Icon, QuestionFill24Icon, ErrorOutline24Icon, ErrorFill24Icon, AltTransportFill24Icon, WarningFill24Icon, SuccessFill24Icon, InformationFill24Icon, DropdownDownFill18Icon, DropdownRightFill18Icon, CalendarOutline24Icon, ArrowLeftFill24Icon, CloseOutline24Icon, SearchOutline24Icon, InformationFill18Icon, WarningFill18Icon, ErrorFill18Icon, Forward15MediaControllerFill30Icon, Backward15MediaControllerFill30Icon, PauseMediaControllerFill24Icon, PlayMediaControllerFill24Icon, NextMediaControllerFill30Icon, PreviousMediaControllerFill30Icon, ArrowRightFill18Icon, DropdownLeftOutline18Icon, DropdownRightOutline18Icon, WalkFill30Icon, WalkFill24Icon, WalkFill18Icon, AltTransportFill30Icon, AltTransportFill18Icon, TramFill30Icon, TramFill24Icon, TramFill18Icon, SubwayFill30Icon, SubwayFill24Icon, SubwayFill18Icon, FerryFill30Icon, FerryFill24Icon, FerryFill18Icon, BusFill30Icon, BusFill24Icon, BusFill18Icon, ExpressBusFill30Icon, ExpressBusFill24Icon, ExpressBusFill18Icon, TrainFill30Icon, TrainFill24Icon, TrainFill18Icon, LinkOutOutline24Icon, ArrowLeftOutline24Icon, ArrowRightOutline24Icon, DropdownLeftFill18Icon, SuccessFill18Icon } from '@vygruppen/spor-icon-react';
|
3
|
+
import { DropdownDownFill24Icon, CopyOutline18Icon, CheckmarkFill18Icon, CloseFill18Icon, CloseFill30Icon, CloseFill24Icon, ServiceFill24Icon, QuestionFill24Icon, ErrorOutline24Icon, ErrorFill24Icon, AltTransportFill24Icon, WarningFill24Icon, SuccessFill24Icon, InformationFill24Icon, DropdownDownFill18Icon, DropdownRightFill18Icon, CalendarOutline24Icon, ArrowLeftFill24Icon, CloseOutline24Icon, SearchOutline24Icon, InformationFill18Icon, WarningFill18Icon, ErrorFill18Icon, Forward15MediaControllerFill30Icon, Backward15MediaControllerFill30Icon, PauseMediaControllerFill24Icon, PlayMediaControllerFill24Icon, NextMediaControllerFill30Icon, PreviousMediaControllerFill30Icon, ArrowRightFill18Icon, DropdownLeftOutline18Icon, DropdownRightOutline18Icon, WalkFill30Icon, WalkFill24Icon, WalkFill18Icon, AltTransportFill30Icon, AltTransportFill18Icon, TramFill30Icon, TramFill24Icon, TramFill18Icon, SubwayFill30Icon, SubwayFill24Icon, SubwayFill18Icon, FerryFill30Icon, FerryFill24Icon, FerryFill18Icon, BusFill30Icon, BusFill24Icon, BusFill18Icon, ExpressBusFill30Icon, ExpressBusFill24Icon, ExpressBusFill18Icon, TrainFill30Icon, TrainFill24Icon, TrainFill18Icon, LinkOutOutline24Icon, LinkOutOutline18Icon, ArrowLeftOutline24Icon, ArrowRightOutline24Icon, DropdownLeftFill18Icon, SuccessFill18Icon } from '@vygruppen/spor-icon-react';
|
4
4
|
import * as React28 from 'react';
|
5
5
|
import React28__default, { forwardRef, createContext, useId, cloneElement, useEffect, useRef, isValidElement, useState, useMemo, useLayoutEffect, useContext } from 'react';
|
6
6
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
@@ -1436,7 +1436,7 @@ var Field3 = React28.forwardRef(
|
|
1436
1436
|
} = props;
|
1437
1437
|
const recipe = useSlotRecipe({ key: "field" });
|
1438
1438
|
const styles = recipe();
|
1439
|
-
return /* @__PURE__ */ jsxs(Stack, { gap: "2", ref, ...rest,
|
1439
|
+
return /* @__PURE__ */ jsxs(Stack, { gap: "2", ref, ...rest, children: [
|
1440
1440
|
/* @__PURE__ */ jsxs(
|
1441
1441
|
Field.Root,
|
1442
1442
|
{
|
@@ -3144,8 +3144,8 @@ var Combobox = (props) => {
|
|
3144
3144
|
const {
|
3145
3145
|
label,
|
3146
3146
|
loading,
|
3147
|
-
|
3148
|
-
|
3147
|
+
leftIcon,
|
3148
|
+
rightIcon,
|
3149
3149
|
borderBottomLeftRadius = "sm",
|
3150
3150
|
borderBottomRightRadius = "sm",
|
3151
3151
|
borderTopLeftRadius = "sm",
|
@@ -3194,7 +3194,7 @@ var Combobox = (props) => {
|
|
3194
3194
|
paddingLeft,
|
3195
3195
|
paddingX,
|
3196
3196
|
paddingY,
|
3197
|
-
|
3197
|
+
leftIcon
|
3198
3198
|
};
|
3199
3199
|
const {
|
3200
3200
|
inputProps: { ...inputProps },
|
@@ -3231,6 +3231,7 @@ var Combobox = (props) => {
|
|
3231
3231
|
borderBottomRightRadius: state.isOpen && !loading ? 0 : borderBottomRightRadius,
|
3232
3232
|
_active: { backgroundColor: "core.surface.active" },
|
3233
3233
|
...inputProps,
|
3234
|
+
startElement: leftIcon,
|
3234
3235
|
endElement: loading ? /* @__PURE__ */ jsx(
|
3235
3236
|
ColorSpinner,
|
3236
3237
|
{
|
@@ -3244,7 +3245,7 @@ var Combobox = (props) => {
|
|
3244
3245
|
}
|
3245
3246
|
}
|
3246
3247
|
}
|
3247
|
-
) :
|
3248
|
+
) : rightIcon,
|
3248
3249
|
placeholder: ""
|
3249
3250
|
}
|
3250
3251
|
),
|
@@ -4854,8 +4855,11 @@ var getDeviationLevelIcon = ({
|
|
4854
4855
|
}
|
4855
4856
|
}
|
4856
4857
|
};
|
4857
|
-
var ExternalIcon = ({
|
4858
|
-
|
4858
|
+
var ExternalIcon = ({
|
4859
|
+
label,
|
4860
|
+
size
|
4861
|
+
}) => /* @__PURE__ */ jsxs(Fragment, { children: [
|
4862
|
+
size === "lg" || size === "md" ? /* @__PURE__ */ jsx(LinkOutOutline24Icon, { "aria-hidden": true }) : /* @__PURE__ */ jsx(LinkOutOutline18Icon, { "aria-hidden": true }),
|
4859
4863
|
/* @__PURE__ */ jsx(VisuallyHidden, { children: label })
|
4860
4864
|
] });
|
4861
4865
|
var TextLink = forwardRef(
|
@@ -4868,13 +4872,13 @@ var TextLink = forwardRef(
|
|
4868
4872
|
...children.props,
|
4869
4873
|
children: /* @__PURE__ */ jsxs(Fragment, { children: [
|
4870
4874
|
children.props.children,
|
4871
|
-
isExternal && /* @__PURE__ */ jsx(ExternalIcon, { label: externalLabel })
|
4875
|
+
isExternal && /* @__PURE__ */ jsx(ExternalIcon, { label: externalLabel, size: props.size })
|
4872
4876
|
] })
|
4873
4877
|
}) });
|
4874
4878
|
}
|
4875
4879
|
return /* @__PURE__ */ jsxs(Link, { href, ...props, ref, children: [
|
4876
4880
|
children,
|
4877
|
-
isExternal && /* @__PURE__ */ jsx(ExternalIcon, { label: externalLabel })
|
4881
|
+
isExternal && /* @__PURE__ */ jsx(ExternalIcon, { label: externalLabel, size: props.size })
|
4878
4882
|
] });
|
4879
4883
|
}
|
4880
4884
|
);
|
@@ -6586,6 +6590,7 @@ var linkRecipe = defineRecipe({
|
|
6586
6590
|
paddingY: "0",
|
6587
6591
|
color: "inherit",
|
6588
6592
|
display: "inline-flex",
|
6593
|
+
alignItems: "center",
|
6589
6594
|
gap: "0",
|
6590
6595
|
position: "relative",
|
6591
6596
|
boxDecorationBreak: "clone",
|
@@ -6627,7 +6632,25 @@ var linkRecipe = defineRecipe({
|
|
6627
6632
|
}
|
6628
6633
|
}
|
6629
6634
|
}
|
6635
|
+
},
|
6636
|
+
size: {
|
6637
|
+
xs: {
|
6638
|
+
fontSize: { base: "mobile.xs", sm: "desktop.xs" }
|
6639
|
+
},
|
6640
|
+
sm: {
|
6641
|
+
fontSize: { base: "mobile.sm", sm: "desktop.sm" }
|
6642
|
+
},
|
6643
|
+
md: {
|
6644
|
+
fontSize: { base: "mobile.md", sm: "desktop.md" }
|
6645
|
+
},
|
6646
|
+
lg: {
|
6647
|
+
fontSize: { base: "mobile.lg", sm: "desktop.lg" }
|
6648
|
+
}
|
6630
6649
|
}
|
6650
|
+
},
|
6651
|
+
defaultVariants: {
|
6652
|
+
variant: "primary",
|
6653
|
+
size: "sm"
|
6631
6654
|
}
|
6632
6655
|
});
|
6633
6656
|
var _a3, _b2;
|