@traefik-labs/faency 13.7.0 → 13.7.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/README.md +12 -5
- package/dist/components/AriaTable/AriaTable.cjs +48 -22
- package/dist/components/AriaTable/AriaTable.cjs.map +1 -1
- package/dist/components/AriaTable/AriaTable.js +49 -23
- package/dist/components/AriaTable/AriaTable.js.map +1 -1
- package/dist/components/AriaTable/AriaTable.vanilla.cjs +8 -4
- package/dist/components/AriaTable/AriaTable.vanilla.cjs.map +1 -1
- package/dist/components/AriaTable/AriaTable.vanilla.css.cjs.map +1 -1
- package/dist/components/AriaTable/AriaTable.vanilla.css.js.map +1 -1
- package/dist/components/AriaTable/AriaTable.vanilla.js +8 -4
- package/dist/components/AriaTable/AriaTable.vanilla.js.map +1 -1
- package/dist/components/Avatar/Avatar.vanilla.cjs +5 -2
- package/dist/components/Avatar/Avatar.vanilla.cjs.map +1 -1
- package/dist/components/Avatar/Avatar.vanilla.css.cjs.map +1 -1
- package/dist/components/Avatar/Avatar.vanilla.css.js.map +1 -1
- package/dist/components/Avatar/Avatar.vanilla.js +5 -2
- package/dist/components/Avatar/Avatar.vanilla.js.map +1 -1
- package/dist/components/Badge/Badge.vanilla.cjs +2 -10
- package/dist/components/Badge/Badge.vanilla.cjs.map +1 -1
- package/dist/components/Badge/Badge.vanilla.css.cjs.map +1 -1
- package/dist/components/Badge/Badge.vanilla.css.js.map +1 -1
- package/dist/components/Badge/Badge.vanilla.js +2 -10
- package/dist/components/Badge/Badge.vanilla.js.map +1 -1
- package/dist/components/Blockquote/Blockquote.vanilla.cjs +5 -11
- package/dist/components/Blockquote/Blockquote.vanilla.cjs.map +1 -1
- package/dist/components/Blockquote/Blockquote.vanilla.css.cjs.map +1 -1
- package/dist/components/Blockquote/Blockquote.vanilla.css.js.map +1 -1
- package/dist/components/Blockquote/Blockquote.vanilla.js +5 -11
- package/dist/components/Blockquote/Blockquote.vanilla.js.map +1 -1
- package/dist/components/Box/Box.vanilla.cjs +2 -10
- package/dist/components/Box/Box.vanilla.cjs.map +1 -1
- package/dist/components/Box/Box.vanilla.css.cjs.map +1 -1
- package/dist/components/Box/Box.vanilla.css.js.map +1 -1
- package/dist/components/Box/Box.vanilla.js +2 -10
- package/dist/components/Box/Box.vanilla.js.map +1 -1
- package/dist/components/Bubble/Bubble.vanilla.cjs +2 -10
- package/dist/components/Bubble/Bubble.vanilla.cjs.map +1 -1
- package/dist/components/Bubble/Bubble.vanilla.css.cjs.map +1 -1
- package/dist/components/Bubble/Bubble.vanilla.css.js.map +1 -1
- package/dist/components/Bubble/Bubble.vanilla.js +2 -10
- package/dist/components/Bubble/Bubble.vanilla.js.map +1 -1
- package/dist/components/Button/Button.vanilla.cjs +2 -10
- package/dist/components/Button/Button.vanilla.cjs.map +1 -1
- package/dist/components/Button/Button.vanilla.css.cjs.map +1 -1
- package/dist/components/Button/Button.vanilla.css.js.map +1 -1
- package/dist/components/Button/Button.vanilla.js +2 -10
- package/dist/components/Button/Button.vanilla.js.map +1 -1
- package/dist/components/ButtonSwitch/ButtonSwitch.vanilla.cjs +3 -17
- package/dist/components/ButtonSwitch/ButtonSwitch.vanilla.cjs.map +1 -1
- package/dist/components/ButtonSwitch/ButtonSwitch.vanilla.css.cjs.map +1 -1
- package/dist/components/ButtonSwitch/ButtonSwitch.vanilla.css.js.map +1 -1
- package/dist/components/ButtonSwitch/ButtonSwitch.vanilla.js +3 -17
- package/dist/components/ButtonSwitch/ButtonSwitch.vanilla.js.map +1 -1
- package/dist/components/Card/Card.vanilla.cjs +6 -11
- package/dist/components/Card/Card.vanilla.cjs.map +1 -1
- package/dist/components/Card/Card.vanilla.css.cjs.map +1 -1
- package/dist/components/Card/Card.vanilla.css.js.map +1 -1
- package/dist/components/Card/Card.vanilla.js +6 -11
- package/dist/components/Card/Card.vanilla.js.map +1 -1
- package/dist/components/CodeBlock/CodeBlock.vanilla.cjs +3 -6
- package/dist/components/CodeBlock/CodeBlock.vanilla.cjs.map +1 -1
- package/dist/components/CodeBlock/CodeBlock.vanilla.css.cjs.map +1 -1
- package/dist/components/CodeBlock/CodeBlock.vanilla.css.js.map +1 -1
- package/dist/components/CodeBlock/CodeBlock.vanilla.js +3 -6
- package/dist/components/CodeBlock/CodeBlock.vanilla.js.map +1 -1
- package/dist/components/Combobox/Combobox.vanilla.cjs +3 -10
- package/dist/components/Combobox/Combobox.vanilla.cjs.map +1 -1
- package/dist/components/Combobox/Combobox.vanilla.css.cjs.map +1 -1
- package/dist/components/Combobox/Combobox.vanilla.css.js.map +1 -1
- package/dist/components/Combobox/Combobox.vanilla.js +3 -10
- package/dist/components/Combobox/Combobox.vanilla.js.map +1 -1
- package/dist/components/Container/Container.vanilla.cjs +5 -11
- package/dist/components/Container/Container.vanilla.cjs.map +1 -1
- package/dist/components/Container/Container.vanilla.css.cjs.map +1 -1
- package/dist/components/Container/Container.vanilla.css.js.map +1 -1
- package/dist/components/Container/Container.vanilla.js +5 -11
- package/dist/components/Container/Container.vanilla.js.map +1 -1
- package/dist/components/Elevation/Elevation.vanilla.cjs +5 -11
- package/dist/components/Elevation/Elevation.vanilla.cjs.map +1 -1
- package/dist/components/Elevation/Elevation.vanilla.css.cjs.map +1 -1
- package/dist/components/Elevation/Elevation.vanilla.css.js.map +1 -1
- package/dist/components/Elevation/Elevation.vanilla.js +5 -11
- package/dist/components/Elevation/Elevation.vanilla.js.map +1 -1
- package/dist/components/Field/Field.vanilla.cjs +3 -9
- package/dist/components/Field/Field.vanilla.cjs.map +1 -1
- package/dist/components/Field/Field.vanilla.css.cjs.map +1 -1
- package/dist/components/Field/Field.vanilla.css.js.map +1 -1
- package/dist/components/Field/Field.vanilla.js +3 -9
- package/dist/components/Field/Field.vanilla.js.map +1 -1
- package/dist/components/Flex/Flex.vanilla.cjs +5 -11
- package/dist/components/Flex/Flex.vanilla.cjs.map +1 -1
- package/dist/components/Flex/Flex.vanilla.css.cjs.map +1 -1
- package/dist/components/Flex/Flex.vanilla.css.js.map +1 -1
- package/dist/components/Flex/Flex.vanilla.js +5 -11
- package/dist/components/Flex/Flex.vanilla.js.map +1 -1
- package/dist/components/Grid/Grid.vanilla.cjs +7 -11
- package/dist/components/Grid/Grid.vanilla.cjs.map +1 -1
- package/dist/components/Grid/Grid.vanilla.css.cjs.map +1 -1
- package/dist/components/Grid/Grid.vanilla.css.js.map +1 -1
- package/dist/components/Grid/Grid.vanilla.js +7 -11
- package/dist/components/Grid/Grid.vanilla.js.map +1 -1
- package/dist/components/Heading/Heading.vanilla.cjs +35 -0
- package/dist/components/Heading/Heading.vanilla.cjs.map +1 -0
- package/dist/components/Heading/Heading.vanilla.css.cjs +85 -0
- package/dist/components/Heading/Heading.vanilla.css.cjs.map +1 -0
- package/dist/components/Heading/Heading.vanilla.css.js +74 -0
- package/dist/components/Heading/Heading.vanilla.css.js.map +1 -0
- package/dist/components/Heading/Heading.vanilla.js +30 -0
- package/dist/components/Heading/Heading.vanilla.js.map +1 -0
- package/dist/components/IconButton/IconButton.vanilla.cjs +5 -11
- package/dist/components/IconButton/IconButton.vanilla.cjs.map +1 -1
- package/dist/components/IconButton/IconButton.vanilla.css.cjs.map +1 -1
- package/dist/components/IconButton/IconButton.vanilla.css.js.map +1 -1
- package/dist/components/IconButton/IconButton.vanilla.js +5 -11
- package/dist/components/IconButton/IconButton.vanilla.js.map +1 -1
- package/dist/components/Image/Image.vanilla.cjs +2 -10
- package/dist/components/Image/Image.vanilla.cjs.map +1 -1
- package/dist/components/Image/Image.vanilla.css.cjs.map +1 -1
- package/dist/components/Image/Image.vanilla.css.js.map +1 -1
- package/dist/components/Image/Image.vanilla.js +2 -10
- package/dist/components/Image/Image.vanilla.js.map +1 -1
- package/dist/components/Input/Input.vanilla.cjs +2 -10
- package/dist/components/Input/Input.vanilla.cjs.map +1 -1
- package/dist/components/Input/Input.vanilla.css.cjs.map +1 -1
- package/dist/components/Input/Input.vanilla.css.js.map +1 -1
- package/dist/components/Input/Input.vanilla.js +2 -10
- package/dist/components/Input/Input.vanilla.js.map +1 -1
- package/dist/components/Label/Label.vanilla.cjs +5 -11
- package/dist/components/Label/Label.vanilla.cjs.map +1 -1
- package/dist/components/Label/Label.vanilla.css.cjs.map +1 -1
- package/dist/components/Label/Label.vanilla.css.js.map +1 -1
- package/dist/components/Label/Label.vanilla.js +5 -11
- package/dist/components/Label/Label.vanilla.js.map +1 -1
- package/dist/components/List/List.vanilla.cjs +10 -18
- package/dist/components/List/List.vanilla.cjs.map +1 -1
- package/dist/components/List/List.vanilla.css.cjs.map +1 -1
- package/dist/components/List/List.vanilla.css.js.map +1 -1
- package/dist/components/List/List.vanilla.js +7 -15
- package/dist/components/List/List.vanilla.js.map +1 -1
- package/dist/components/Meter/Meter.vanilla.cjs +3 -8
- package/dist/components/Meter/Meter.vanilla.cjs.map +1 -1
- package/dist/components/Meter/Meter.vanilla.css.cjs.map +1 -1
- package/dist/components/Meter/Meter.vanilla.css.js.map +1 -1
- package/dist/components/Meter/Meter.vanilla.js +3 -8
- package/dist/components/Meter/Meter.vanilla.js.map +1 -1
- package/dist/components/Panel/Panel.vanilla.cjs +2 -10
- package/dist/components/Panel/Panel.vanilla.cjs.map +1 -1
- package/dist/components/Panel/Panel.vanilla.css.cjs.map +1 -1
- package/dist/components/Panel/Panel.vanilla.css.js.map +1 -1
- package/dist/components/Panel/Panel.vanilla.js +2 -10
- package/dist/components/Panel/Panel.vanilla.js.map +1 -1
- package/dist/components/Paragraph/Paragraph.vanilla.cjs +5 -11
- package/dist/components/Paragraph/Paragraph.vanilla.cjs.map +1 -1
- package/dist/components/Paragraph/Paragraph.vanilla.css.cjs.map +1 -1
- package/dist/components/Paragraph/Paragraph.vanilla.css.js.map +1 -1
- package/dist/components/Paragraph/Paragraph.vanilla.js +5 -11
- package/dist/components/Paragraph/Paragraph.vanilla.js.map +1 -1
- package/dist/components/RowLink/RowLink.vanilla.cjs.map +1 -1
- package/dist/components/RowLink/RowLink.vanilla.css.cjs.map +1 -1
- package/dist/components/RowLink/RowLink.vanilla.css.js.map +1 -1
- package/dist/components/RowLink/RowLink.vanilla.js.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.vanilla.cjs +3 -14
- package/dist/components/SegmentedControl/SegmentedControl.vanilla.cjs.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.vanilla.css.cjs.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.vanilla.css.js.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.vanilla.js +3 -14
- package/dist/components/SegmentedControl/SegmentedControl.vanilla.js.map +1 -1
- package/dist/components/Skeleton/Skeleton.vanilla.cjs +2 -10
- package/dist/components/Skeleton/Skeleton.vanilla.cjs.map +1 -1
- package/dist/components/Skeleton/Skeleton.vanilla.css.cjs.map +1 -1
- package/dist/components/Skeleton/Skeleton.vanilla.css.js.map +1 -1
- package/dist/components/Skeleton/Skeleton.vanilla.js +2 -10
- package/dist/components/Skeleton/Skeleton.vanilla.js.map +1 -1
- package/dist/components/Spinner/Spinner.vanilla.cjs +3 -6
- package/dist/components/Spinner/Spinner.vanilla.cjs.map +1 -1
- package/dist/components/Spinner/Spinner.vanilla.css.cjs.map +1 -1
- package/dist/components/Spinner/Spinner.vanilla.css.js.map +1 -1
- package/dist/components/Spinner/Spinner.vanilla.js +3 -6
- package/dist/components/Spinner/Spinner.vanilla.js.map +1 -1
- package/dist/components/SplitLayout/SplitLayout.vanilla.cjs +3 -10
- package/dist/components/SplitLayout/SplitLayout.vanilla.cjs.map +1 -1
- package/dist/components/SplitLayout/SplitLayout.vanilla.css.cjs.map +1 -1
- package/dist/components/SplitLayout/SplitLayout.vanilla.css.js.map +1 -1
- package/dist/components/SplitLayout/SplitLayout.vanilla.js +3 -10
- package/dist/components/SplitLayout/SplitLayout.vanilla.js.map +1 -1
- package/dist/components/Table/Table.vanilla.cjs +8 -4
- package/dist/components/Table/Table.vanilla.cjs.map +1 -1
- package/dist/components/Table/Table.vanilla.css.cjs.map +1 -1
- package/dist/components/Table/Table.vanilla.css.js.map +1 -1
- package/dist/components/Table/Table.vanilla.js +8 -4
- package/dist/components/Table/Table.vanilla.js.map +1 -1
- package/dist/components/Text/Text.vanilla.cjs +5 -11
- package/dist/components/Text/Text.vanilla.cjs.map +1 -1
- package/dist/components/Text/Text.vanilla.css.cjs.map +1 -1
- package/dist/components/Text/Text.vanilla.css.js.map +1 -1
- package/dist/components/Text/Text.vanilla.js +5 -11
- package/dist/components/Text/Text.vanilla.js.map +1 -1
- package/dist/components/TextField/TextField.vanilla.cjs.map +1 -1
- package/dist/components/TextField/TextField.vanilla.css.cjs.map +1 -1
- package/dist/components/TextField/TextField.vanilla.css.js.map +1 -1
- package/dist/components/TextField/TextField.vanilla.js.map +1 -1
- package/dist/components/Textarea/Textarea.vanilla.cjs +2 -10
- package/dist/components/Textarea/Textarea.vanilla.cjs.map +1 -1
- package/dist/components/Textarea/Textarea.vanilla.css.cjs.map +1 -1
- package/dist/components/Textarea/Textarea.vanilla.css.js.map +1 -1
- package/dist/components/Textarea/Textarea.vanilla.js +2 -10
- package/dist/components/Textarea/Textarea.vanilla.js.map +1 -1
- package/dist/components/Toast/Toast.vanilla.cjs +4 -15
- package/dist/components/Toast/Toast.vanilla.cjs.map +1 -1
- package/dist/components/Toast/Toast.vanilla.css.cjs.map +1 -1
- package/dist/components/Toast/Toast.vanilla.css.js.map +1 -1
- package/dist/components/Toast/Toast.vanilla.js +4 -15
- package/dist/components/Toast/Toast.vanilla.js.map +1 -1
- package/dist/faency.css +118 -2
- package/dist/index.cjs +9 -0
- package/dist/index.d.cts +36800 -0
- package/dist/index.d.ts +248 -94
- package/dist/index.js +3 -1
- package/dist/styles/recipeVariants.cjs +15 -0
- package/dist/styles/recipeVariants.cjs.map +1 -0
- package/dist/styles/recipeVariants.js +15 -0
- package/dist/styles/recipeVariants.js.map +1 -0
- package/dist/styles/themeContext.cjs.map +1 -1
- package/dist/styles/themeContext.js.map +1 -1
- package/dist/styles/themes.css.cjs.map +1 -1
- package/dist/styles/themes.css.js.map +1 -1
- package/dist/styles/tokens.css.cjs.map +1 -1
- package/dist/styles/tokens.css.js.map +1 -1
- package/dist/utils/warnOnce.cjs +8 -1
- package/dist/utils/warnOnce.cjs.map +1 -1
- package/dist/utils/warnOnce.js +8 -1
- package/dist/utils/warnOnce.js.map +1 -1
- package/package.json +32 -22
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Field.vanilla.css.js","names":[],"sources":[
|
|
1
|
+
{"version":3,"file":"Field.vanilla.css.js","names":[],"sources":[],"mappings":""}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useVanillaExtractTheme } from "../../styles/themeContext.js";
|
|
1
|
+
import { useInlineStyle } from "../../styles/useInlineStyle.js";
|
|
3
2
|
import { BoxVanilla } from "../Box/Box.vanilla.js";
|
|
4
3
|
import { LabelVanilla } from "../Label/Label.vanilla.js";
|
|
5
4
|
import { TextVanilla } from "../Text/Text.vanilla.js";
|
|
@@ -7,7 +6,6 @@ import { VisuallyHidden } from "../VisuallyHidden/VisuallyHidden.js";
|
|
|
7
6
|
import { endLabelRow, startControl, startLabel, startRow } from "./Field.vanilla.css.js";
|
|
8
7
|
import { FieldContext, useAnnouncedError, useFieldRoot } from "./FieldContext.js";
|
|
9
8
|
import React from "react";
|
|
10
|
-
import { assignInlineVars } from "@vanilla-extract/dynamic";
|
|
11
9
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
12
10
|
// components/Field/Field.vanilla.tsx
|
|
13
11
|
var MESSAGE_CSS = {
|
|
@@ -34,8 +32,7 @@ var FieldVanilla = ({ label, hint, description, error, announceError, labelPosit
|
|
|
34
32
|
...props
|
|
35
33
|
});
|
|
36
34
|
const announcedError = useAnnouncedError(Boolean(announceError), hasError ? ids.errorId : void 0, ids.labelId);
|
|
37
|
-
const
|
|
38
|
-
const { style: rootStyle, vars: rootVars } = processCSSProp(css, colors);
|
|
35
|
+
const rootStyle = useInlineStyle(css);
|
|
39
36
|
const labelNode = React.useMemo(() => {
|
|
40
37
|
if (!hasLabel || !ids.labelId) return null;
|
|
41
38
|
if (typeof label === "function") return label({
|
|
@@ -86,10 +83,7 @@ var FieldVanilla = ({ label, hint, description, error, announceError, labelPosit
|
|
|
86
83
|
value: context,
|
|
87
84
|
children: /* @__PURE__ */ jsxs("div", {
|
|
88
85
|
className: labelPosition === "start" ? startRow : void 0,
|
|
89
|
-
style:
|
|
90
|
-
...rootStyle,
|
|
91
|
-
...assignInlineVars(rootVars)
|
|
92
|
-
},
|
|
86
|
+
style: rootStyle,
|
|
93
87
|
onFocus,
|
|
94
88
|
onBlur,
|
|
95
89
|
...groupProps,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Field.vanilla.js","names":["_Fragment"],"sources":["../../../components/Field/Field.vanilla.tsx"],"sourcesContent":["import
|
|
1
|
+
{"version":3,"file":"Field.vanilla.js","names":["_Fragment"],"sources":["../../../components/Field/Field.vanilla.tsx"],"sourcesContent":["import React from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport { BoxVanilla } from '@/components/Box';\nimport { LabelVanilla } from '@/components/Label';\nimport { TextVanilla } from '@/components/Text';\nimport { VisuallyHidden } from '@/components/VisuallyHidden';\n\nimport { endLabelRow, startControl, startLabel, startRow } from './Field.vanilla.css';\nimport { FieldBaseProps, FieldContext, useAnnouncedError, useFieldRoot } from './FieldContext';\n\nexport type FieldVanillaProps = FieldBaseProps & { css?: CSSProps['css'] };\n\nconst MESSAGE_CSS = { display: 'block', m: 0, mt: '$1', lineHeight: 1.4 };\n// The tall line of a label makes room for a control right under it. Before a hint or beside a control, it is a gap.\nconst COMPACT_LABEL_CSS = { lineHeight: 1.4 };\nconst HINT_ABOVE_CONTROL_CSS = { ...MESSAGE_CSS, mb: '$2' };\n\n/**\n * Gives a label, a hint, a description and an error to the one form control inside it.\n * For more than one control, use `group`.\n */\nexport const FieldVanilla = ({\n label,\n hint,\n description,\n error,\n announceError,\n labelPosition = 'top',\n children,\n css,\n ...props\n}: FieldVanillaProps) => {\n const {\n context,\n ids,\n groupProps,\n messageSize,\n labelFor,\n labelVariant,\n hasLabel,\n hasHint,\n hasDescription,\n hasError,\n onFocus,\n onBlur,\n } = useFieldRoot({ label, hint, description, error, ...props });\n const announcedError = useAnnouncedError(\n Boolean(announceError),\n hasError ? ids.errorId : undefined,\n ids.labelId,\n );\n const rootStyle = useInlineStyle(css);\n\n const labelNode = React.useMemo(() => {\n if (!hasLabel || !ids.labelId) {\n return null;\n }\n if (typeof label === 'function') {\n return label({ variant: labelVariant, htmlFor: labelFor, id: ids.labelId });\n }\n return (\n <LabelVanilla\n variant={labelVariant}\n htmlFor={labelFor}\n id={ids.labelId}\n css={hasHint || labelPosition === 'start' ? COMPACT_LABEL_CSS : undefined}\n >\n {label}\n </LabelVanilla>\n );\n }, [hasLabel, hasHint, label, labelPosition, labelVariant, labelFor, ids.labelId]);\n\n const hintNode = hasHint && (\n <TextVanilla\n as=\"p\"\n id={ids.hintId}\n size={messageSize}\n variant=\"subtle\"\n css={labelPosition === 'top' ? HINT_ABOVE_CONTROL_CSS : MESSAGE_CSS}\n >\n {hint}\n </TextVanilla>\n );\n\n const messages = (\n <>\n {hasDescription && (\n <TextVanilla\n as=\"p\"\n id={ids.descriptionId}\n size={messageSize}\n variant=\"subtle\"\n css={MESSAGE_CSS}\n >\n {description}\n </TextVanilla>\n )}\n {hasError && (\n <TextVanilla as=\"p\" id={ids.errorId} size={messageSize} variant=\"invalid\" css={MESSAGE_CSS}>\n {error}\n </TextVanilla>\n )}\n </>\n );\n\n return (\n <FieldContext.Provider value={context}>\n <div\n className={labelPosition === 'start' ? startRow : undefined}\n style={rootStyle}\n onFocus={onFocus}\n onBlur={onBlur}\n {...groupProps}\n >\n {labelPosition === 'start' ? (\n <>\n <BoxVanilla className={startLabel}>\n {labelNode}\n {hintNode}\n </BoxVanilla>\n <BoxVanilla className={startControl}>\n {children}\n {messages}\n </BoxVanilla>\n </>\n ) : labelPosition === 'end' ? (\n <>\n <BoxVanilla className={endLabelRow}>\n {children}\n {labelNode}\n </BoxVanilla>\n {hintNode}\n {messages}\n </>\n ) : (\n <>\n {labelNode}\n {hintNode}\n {children}\n {messages}\n </>\n )}\n {announceError && <VisuallyHidden aria-live=\"polite\">{announcedError}</VisuallyHidden>}\n </div>\n </FieldContext.Provider>\n );\n};\n"],"mappings":";;;;;;;;;;AAeA,IAAM,cAAc;CAAE,SAAS;CAAS,GAAG;CAAG,IAAI;CAAM,YAAY;AAAI;AAExE,IAAM,oBAAoB,EAAE,YAAY,IAAI;AAC5C,IAAM,yBAAyB;CAAE,GAAG;CAAa,IAAI;AAAK;;;;;AAM1D,IAAa,gBAAgB,EAC3B,OACA,MACA,aACA,OACA,eACA,gBAAgB,OAChB,UACA,KACA,GAAG,YACoB;CACvB,MAAM,EACJ,SACA,KACA,YACA,aACA,UACA,cACA,UACA,SACA,gBACA,UACA,SACA,WACE,aAAa;EAAE;EAAO;EAAM;EAAa;EAAO,GAAG;CAAM,CAAC;CAC9D,MAAM,iBAAiB,kBACrB,QAAQ,aAAa,GACrB,WAAW,IAAI,UAAU,KAAA,GACzB,IAAI,OACN;CACA,MAAM,YAAY,eAAe,GAAG;CAEpC,MAAM,YAAY,MAAM,cAAc;EACpC,IAAI,CAAC,YAAY,CAAC,IAAI,SACpB,OAAO;EAET,IAAI,OAAO,UAAU,YACnB,OAAO,MAAM;GAAE,SAAS;GAAc,SAAS;GAAU,IAAI,IAAI;EAAQ,CAAC;EAE5E,OACE,oBAAC,cAAD;GACE,SAAS;GACT,SAAS;GACT,IAAI,IAAI;GACR,KAAK,WAAW,kBAAkB,UAAU,oBAAoB,KAAA;GAE/D,UAAA;EACW,CAAA;CAElB,GAAG;EAAC;EAAU;EAAS;EAAO;EAAe;EAAc;EAAU,IAAI;CAAO,CAAC;CAEjF,MAAM,WAAW,WACf,oBAAC,aAAD;EACE,IAAG;EACH,IAAI,IAAI;EACR,MAAM;EACN,SAAQ;EACR,KAAK,kBAAkB,QAAQ,yBAAyB;EAEvD,UAAA;CACU,CAAA;CAGf,MAAM,WACJ,qBAAAA,YAAA,EAAA,UAAA,CACG,kBACC,oBAAC,aAAD;EACE,IAAG;EACH,IAAI,IAAI;EACR,MAAM;EACN,SAAQ;EACR,KAAK;EAEJ,UAAA;CACU,CAAA,GAEd,YACC,oBAAC,aAAD;EAAa,IAAG;EAAI,IAAI,IAAI;EAAS,MAAM;EAAa,SAAQ;EAAU,KAAK;EAC5E,UAAA;CACU,CAAA,CAEf,EAAA,CAAA;CAGJ,OACE,oBAAC,aAAa,UAAd;EAAuB,OAAO;EAC5B,UAAA,qBAAC,OAAD;GACE,WAAW,kBAAkB,UAAU,WAAW,KAAA;GAClD,OAAO;GACE;GACD;GACR,GAAI;GALN,UAAA,CAOG,kBAAkB,UACjB,qBAAAA,YAAA,EAAA,UAAA,CACE,qBAAC,YAAD;IAAY,WAAW;IAAvB,UAAA,CACG,WACA,QACS;GACZ,CAAA,GAAA,qBAAC,YAAD;IAAY,WAAW;IAAvB,UAAA,CACG,UACA,QACS;GACZ,CAAA,CAAA,EAAA,CAAA,IACA,kBAAkB,QACpB,qBAAAA,YAAA,EAAA,UAAA;IACE,qBAAC,YAAD;KAAY,WAAW;KAAvB,UAAA,CACG,UACA,SACS;;IACX;IACA;GACD,EAAA,CAAA,IAEF,qBAAAA,YAAA,EAAA,UAAA;IACG;IACA;IACA;IACA;GACD,EAAA,CAAA,GAEH,iBAAiB,oBAAC,gBAAD;IAAgB,aAAU;IAAU,UAAA;GAA+B,CAAA,CAClF;;CACgB,CAAA;AAE3B"}
|
|
@@ -1,23 +1,17 @@
|
|
|
1
1
|
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
-
const require_cssProps = require("../../styles/cssProps.cjs");
|
|
3
2
|
const require_cx = require("../../styles/cx.cjs");
|
|
4
|
-
const
|
|
3
|
+
const require_recipeVariants = require("../../styles/recipeVariants.cjs");
|
|
4
|
+
const require_useInlineStyle = require("../../styles/useInlineStyle.cjs");
|
|
5
5
|
const require_Flex_vanilla_css = require("./Flex.vanilla.css.cjs");
|
|
6
6
|
let react = require("react");
|
|
7
7
|
react = require_runtime.__toESM(react, 1);
|
|
8
|
-
let _vanilla_extract_dynamic = require("@vanilla-extract/dynamic");
|
|
9
8
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
10
9
|
// components/Flex/Flex.vanilla.tsx
|
|
10
|
+
var flexClass = require_recipeVariants.withVariantKeys(require_Flex_vanilla_css.flexRecipe);
|
|
11
11
|
var FlexVanillaComponent = react.default.forwardRef(({ as, className, css, style, direction, align, justify, wrap, gap, ...props }, ref) => {
|
|
12
12
|
const Component = as || "div";
|
|
13
|
-
const
|
|
14
|
-
const
|
|
15
|
-
const mergedStyles = {
|
|
16
|
-
...cssStyles,
|
|
17
|
-
...style,
|
|
18
|
-
...(0, _vanilla_extract_dynamic.assignInlineVars)(vars)
|
|
19
|
-
};
|
|
20
|
-
const recipeClass = require_Flex_vanilla_css.flexRecipe({
|
|
13
|
+
const mergedStyles = require_useInlineStyle.useInlineStyle(css, style);
|
|
14
|
+
const recipeClass = flexClass({
|
|
21
15
|
direction,
|
|
22
16
|
align,
|
|
23
17
|
justify,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Flex.vanilla.cjs","names":["
|
|
1
|
+
{"version":3,"file":"Flex.vanilla.cjs","names":["withVariantKeys","flexRecipe","React","useInlineStyle","cx"],"sources":["../../../components/Flex/Flex.vanilla.tsx"],"sourcesContent":["import React, { ElementType } from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { cx } from '@/styles/cx';\nimport {\n PolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n} from '@/styles/polymorphic';\nimport { withVariantKeys } from '@/styles/recipeVariants';\nimport type {\n FlexAlignSimplified,\n FlexDirection,\n FlexJustifySimplified,\n Gap,\n} from '@/styles/types';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport { flexRecipe } from './Flex.vanilla.css';\n\nconst flexClass = withVariantKeys(flexRecipe);\n\ninterface FlexOwnProps extends CSSProps {\n direction?: FlexDirection;\n align?: FlexAlignSimplified;\n justify?: FlexJustifySimplified;\n wrap?: 'wrap' | 'noWrap' | 'wrapReverse';\n gap?: Gap;\n}\n\nexport type FlexProps<C extends ElementType = 'div'> = PolymorphicComponentProps<C, FlexOwnProps>;\ntype FlexComponent = PolymorphicComponent<'div', FlexProps<ElementType>>;\n\nexport const FlexVanillaComponent = React.forwardRef(\n <C extends ElementType = 'div'>(\n { as, className, css, style, direction, align, justify, wrap, gap, ...props }: FlexProps<C>,\n ref?: PolymorphicRef<C>,\n ) => {\n const Component = as || 'div';\n\n const mergedStyles = useInlineStyle(css, style);\n\n const recipeClass = flexClass({ direction, align, justify, wrap, gap });\n\n return (\n <Component ref={ref} className={cx(recipeClass, className)} style={mergedStyles} {...props} />\n );\n },\n);\n\nFlexVanillaComponent.displayName = 'FlexVanilla';\n\nexport const FlexVanilla = FlexVanillaComponent as FlexComponent;\n"],"mappings":";;;;;;;;;AAoBA,IAAM,YAAYA,uBAAAA,gBAAgBC,yBAAAA,UAAU;AAa5C,IAAa,uBAAuBC,MAAAA,QAAM,YAEtC,EAAE,IAAI,WAAW,KAAK,OAAO,WAAW,OAAO,SAAS,MAAM,KAAK,GAAG,SACtE,QACG;CACH,MAAM,YAAY,MAAM;CAExB,MAAM,eAAeC,uBAAAA,eAAe,KAAK,KAAK;CAE9C,MAAM,cAAc,UAAU;EAAE;EAAW;EAAO;EAAS;EAAM;CAAI,CAAC;CAEtE,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,WAAD;EAAgB;EAAK,WAAWC,WAAAA,GAAG,aAAa,SAAS;EAAG,OAAO;EAAc,GAAI;CAAQ,CAAA;AAEjG,CACF;AAEA,qBAAqB,cAAc;AAEnC,IAAa,cAAc"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Flex.vanilla.css.cjs","names":[
|
|
1
|
+
{"version":3,"file":"Flex.vanilla.css.cjs","names":[],"sources":[],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Flex.vanilla.css.js","names":[
|
|
1
|
+
{"version":3,"file":"Flex.vanilla.css.js","names":[],"sources":[],"mappings":""}
|
|
@@ -1,21 +1,15 @@
|
|
|
1
|
-
import { processCSSProp } from "../../styles/cssProps.js";
|
|
2
1
|
import { cx } from "../../styles/cx.js";
|
|
3
|
-
import {
|
|
2
|
+
import { withVariantKeys } from "../../styles/recipeVariants.js";
|
|
3
|
+
import { useInlineStyle } from "../../styles/useInlineStyle.js";
|
|
4
4
|
import { flexRecipe } from "./Flex.vanilla.css.js";
|
|
5
5
|
import React from "react";
|
|
6
|
-
import { assignInlineVars } from "@vanilla-extract/dynamic";
|
|
7
6
|
import { jsx } from "react/jsx-runtime";
|
|
8
7
|
// components/Flex/Flex.vanilla.tsx
|
|
8
|
+
var flexClass = withVariantKeys(flexRecipe);
|
|
9
9
|
var FlexVanillaComponent = React.forwardRef(({ as, className, css, style, direction, align, justify, wrap, gap, ...props }, ref) => {
|
|
10
10
|
const Component = as || "div";
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const mergedStyles = {
|
|
14
|
-
...cssStyles,
|
|
15
|
-
...style,
|
|
16
|
-
...assignInlineVars(vars)
|
|
17
|
-
};
|
|
18
|
-
const recipeClass = flexRecipe({
|
|
11
|
+
const mergedStyles = useInlineStyle(css, style);
|
|
12
|
+
const recipeClass = flexClass({
|
|
19
13
|
direction,
|
|
20
14
|
align,
|
|
21
15
|
justify,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Flex.vanilla.js","names":[],"sources":["../../../components/Flex/Flex.vanilla.tsx"],"sourcesContent":["import
|
|
1
|
+
{"version":3,"file":"Flex.vanilla.js","names":[],"sources":["../../../components/Flex/Flex.vanilla.tsx"],"sourcesContent":["import React, { ElementType } from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { cx } from '@/styles/cx';\nimport {\n PolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n} from '@/styles/polymorphic';\nimport { withVariantKeys } from '@/styles/recipeVariants';\nimport type {\n FlexAlignSimplified,\n FlexDirection,\n FlexJustifySimplified,\n Gap,\n} from '@/styles/types';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport { flexRecipe } from './Flex.vanilla.css';\n\nconst flexClass = withVariantKeys(flexRecipe);\n\ninterface FlexOwnProps extends CSSProps {\n direction?: FlexDirection;\n align?: FlexAlignSimplified;\n justify?: FlexJustifySimplified;\n wrap?: 'wrap' | 'noWrap' | 'wrapReverse';\n gap?: Gap;\n}\n\nexport type FlexProps<C extends ElementType = 'div'> = PolymorphicComponentProps<C, FlexOwnProps>;\ntype FlexComponent = PolymorphicComponent<'div', FlexProps<ElementType>>;\n\nexport const FlexVanillaComponent = React.forwardRef(\n <C extends ElementType = 'div'>(\n { as, className, css, style, direction, align, justify, wrap, gap, ...props }: FlexProps<C>,\n ref?: PolymorphicRef<C>,\n ) => {\n const Component = as || 'div';\n\n const mergedStyles = useInlineStyle(css, style);\n\n const recipeClass = flexClass({ direction, align, justify, wrap, gap });\n\n return (\n <Component ref={ref} className={cx(recipeClass, className)} style={mergedStyles} {...props} />\n );\n },\n);\n\nFlexVanillaComponent.displayName = 'FlexVanilla';\n\nexport const FlexVanilla = FlexVanillaComponent as FlexComponent;\n"],"mappings":";;;;;;;AAoBA,IAAM,YAAY,gBAAgB,UAAU;AAa5C,IAAa,uBAAuB,MAAM,YAEtC,EAAE,IAAI,WAAW,KAAK,OAAO,WAAW,OAAO,SAAS,MAAM,KAAK,GAAG,SACtE,QACG;CACH,MAAM,YAAY,MAAM;CAExB,MAAM,eAAe,eAAe,KAAK,KAAK;CAE9C,MAAM,cAAc,UAAU;EAAE;EAAW;EAAO;EAAS;EAAM;CAAI,CAAC;CAEtE,OACE,oBAAC,WAAD;EAAgB;EAAK,WAAW,GAAG,aAAa,SAAS;EAAG,OAAO;EAAc,GAAI;CAAQ,CAAA;AAEjG,CACF;AAEA,qBAAqB,cAAc;AAEnC,IAAa,cAAc"}
|
|
@@ -1,26 +1,22 @@
|
|
|
1
1
|
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
-
const require_cssProps = require("../../styles/cssProps.cjs");
|
|
3
2
|
const require_cx = require("../../styles/cx.cjs");
|
|
4
|
-
const
|
|
3
|
+
const require_recipeVariants = require("../../styles/recipeVariants.cjs");
|
|
4
|
+
const require_useInlineStyle = require("../../styles/useInlineStyle.cjs");
|
|
5
5
|
const require_Grid_vanilla_css = require("./Grid.vanilla.css.cjs");
|
|
6
6
|
let react = require("react");
|
|
7
7
|
react = require_runtime.__toESM(react, 1);
|
|
8
|
-
let _vanilla_extract_dynamic = require("@vanilla-extract/dynamic");
|
|
9
8
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
10
9
|
// components/Grid/Grid.vanilla.tsx
|
|
10
|
+
var gridClass = require_recipeVariants.withVariantKeys(require_Grid_vanilla_css.gridRecipe);
|
|
11
11
|
var GridVanillaComponent = react.default.forwardRef(({ as, className, css, style, align, justify, flow, columns, gap, gapX, gapY, ...props }, ref) => {
|
|
12
12
|
const Component = as || "div";
|
|
13
|
-
const { colors } = require_themeContext.useVanillaExtractTheme();
|
|
14
|
-
const { style: cssStyles, vars } = require_cssProps.processCSSProp(css, colors);
|
|
15
13
|
const dynamicStyles = {};
|
|
16
14
|
if (columns !== void 0) dynamicStyles.gridTemplateColumns = `repeat(${columns}, 1fr)`;
|
|
17
|
-
const mergedStyles = {
|
|
18
|
-
...cssStyles,
|
|
15
|
+
const mergedStyles = require_useInlineStyle.useInlineStyle(css, {
|
|
19
16
|
...dynamicStyles,
|
|
20
|
-
...style
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
const recipeClass = require_Grid_vanilla_css.gridRecipe({
|
|
17
|
+
...style
|
|
18
|
+
});
|
|
19
|
+
const recipeClass = gridClass({
|
|
24
20
|
align,
|
|
25
21
|
justify,
|
|
26
22
|
flow,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Grid.vanilla.cjs","names":["
|
|
1
|
+
{"version":3,"file":"Grid.vanilla.cjs","names":["withVariantKeys","gridRecipe","React","useInlineStyle","cx"],"sources":["../../../components/Grid/Grid.vanilla.tsx"],"sourcesContent":["import React, { ElementType } from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { cx } from '@/styles/cx';\nimport {\n PolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n} from '@/styles/polymorphic';\nimport { withVariantKeys } from '@/styles/recipeVariants';\nimport type { Gap, GridAlign, GridFlow, GridJustify } from '@/styles/types';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport { gridRecipe } from './Grid.vanilla.css';\n\nconst gridClass = withVariantKeys(gridRecipe);\n\ninterface GridOwnProps extends CSSProps {\n align?: GridAlign;\n justify?: GridJustify;\n flow?: GridFlow;\n columns?: number;\n gap?: Gap;\n gapX?: Gap;\n gapY?: Gap;\n}\n\nexport type GridProps<C extends ElementType = 'div'> = PolymorphicComponentProps<C, GridOwnProps>;\ntype GridComponent = PolymorphicComponent<'div', GridProps<ElementType>>;\n\nexport const GridVanillaComponent = React.forwardRef(\n <C extends ElementType = 'div'>(\n {\n as,\n className,\n css,\n style,\n align,\n justify,\n flow,\n columns,\n gap,\n gapX,\n gapY,\n ...props\n }: GridProps<C>,\n ref?: PolymorphicRef<C>,\n ) => {\n const Component = as || 'div';\n\n const dynamicStyles: React.CSSProperties = {};\n\n // To support any value on the columns props\n if (columns !== undefined) {\n dynamicStyles.gridTemplateColumns = `repeat(${columns}, 1fr)`;\n }\n\n const mergedStyles = useInlineStyle(css, { ...dynamicStyles, ...style });\n\n const recipeClass = gridClass({ align, justify, flow, gap, gapX, gapY });\n\n return (\n <Component ref={ref} className={cx(recipeClass, className)} style={mergedStyles} {...props} />\n );\n },\n);\n\nGridVanillaComponent.displayName = 'GridVanilla';\n\nexport const GridVanilla = GridVanillaComponent as GridComponent;\n"],"mappings":";;;;;;;;;AAeA,IAAM,YAAYA,uBAAAA,gBAAgBC,yBAAAA,UAAU;AAe5C,IAAa,uBAAuBC,MAAAA,QAAM,YAEtC,EACE,IACA,WACA,KACA,OACA,OACA,SACA,MACA,SACA,KACA,MACA,MACA,GAAG,SAEL,QACG;CACH,MAAM,YAAY,MAAM;CAExB,MAAM,gBAAqC,CAAC;CAG5C,IAAI,YAAY,KAAA,GACd,cAAc,sBAAsB,UAAU,QAAQ;CAGxD,MAAM,eAAeC,uBAAAA,eAAe,KAAK;EAAE,GAAG;EAAe,GAAG;CAAM,CAAC;CAEvE,MAAM,cAAc,UAAU;EAAE;EAAO;EAAS;EAAM;EAAK;EAAM;CAAK,CAAC;CAEvE,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,WAAD;EAAgB;EAAK,WAAWC,WAAAA,GAAG,aAAa,SAAS;EAAG,OAAO;EAAc,GAAI;CAAQ,CAAA;AAEjG,CACF;AAEA,qBAAqB,cAAc;AAEnC,IAAa,cAAc"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Grid.vanilla.css.cjs","names":[
|
|
1
|
+
{"version":3,"file":"Grid.vanilla.css.cjs","names":[],"sources":[],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Grid.vanilla.css.js","names":[
|
|
1
|
+
{"version":3,"file":"Grid.vanilla.css.js","names":[],"sources":[],"mappings":""}
|
|
@@ -1,24 +1,20 @@
|
|
|
1
|
-
import { processCSSProp } from "../../styles/cssProps.js";
|
|
2
1
|
import { cx } from "../../styles/cx.js";
|
|
3
|
-
import {
|
|
2
|
+
import { withVariantKeys } from "../../styles/recipeVariants.js";
|
|
3
|
+
import { useInlineStyle } from "../../styles/useInlineStyle.js";
|
|
4
4
|
import { gridRecipe } from "./Grid.vanilla.css.js";
|
|
5
5
|
import React from "react";
|
|
6
|
-
import { assignInlineVars } from "@vanilla-extract/dynamic";
|
|
7
6
|
import { jsx } from "react/jsx-runtime";
|
|
8
7
|
// components/Grid/Grid.vanilla.tsx
|
|
8
|
+
var gridClass = withVariantKeys(gridRecipe);
|
|
9
9
|
var GridVanillaComponent = React.forwardRef(({ as, className, css, style, align, justify, flow, columns, gap, gapX, gapY, ...props }, ref) => {
|
|
10
10
|
const Component = as || "div";
|
|
11
|
-
const { colors } = useVanillaExtractTheme();
|
|
12
|
-
const { style: cssStyles, vars } = processCSSProp(css, colors);
|
|
13
11
|
const dynamicStyles = {};
|
|
14
12
|
if (columns !== void 0) dynamicStyles.gridTemplateColumns = `repeat(${columns}, 1fr)`;
|
|
15
|
-
const mergedStyles = {
|
|
16
|
-
...cssStyles,
|
|
13
|
+
const mergedStyles = useInlineStyle(css, {
|
|
17
14
|
...dynamicStyles,
|
|
18
|
-
...style
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
const recipeClass = gridRecipe({
|
|
15
|
+
...style
|
|
16
|
+
});
|
|
17
|
+
const recipeClass = gridClass({
|
|
22
18
|
align,
|
|
23
19
|
justify,
|
|
24
20
|
flow,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Grid.vanilla.js","names":[],"sources":["../../../components/Grid/Grid.vanilla.tsx"],"sourcesContent":["import
|
|
1
|
+
{"version":3,"file":"Grid.vanilla.js","names":[],"sources":["../../../components/Grid/Grid.vanilla.tsx"],"sourcesContent":["import React, { ElementType } from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { cx } from '@/styles/cx';\nimport {\n PolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n} from '@/styles/polymorphic';\nimport { withVariantKeys } from '@/styles/recipeVariants';\nimport type { Gap, GridAlign, GridFlow, GridJustify } from '@/styles/types';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport { gridRecipe } from './Grid.vanilla.css';\n\nconst gridClass = withVariantKeys(gridRecipe);\n\ninterface GridOwnProps extends CSSProps {\n align?: GridAlign;\n justify?: GridJustify;\n flow?: GridFlow;\n columns?: number;\n gap?: Gap;\n gapX?: Gap;\n gapY?: Gap;\n}\n\nexport type GridProps<C extends ElementType = 'div'> = PolymorphicComponentProps<C, GridOwnProps>;\ntype GridComponent = PolymorphicComponent<'div', GridProps<ElementType>>;\n\nexport const GridVanillaComponent = React.forwardRef(\n <C extends ElementType = 'div'>(\n {\n as,\n className,\n css,\n style,\n align,\n justify,\n flow,\n columns,\n gap,\n gapX,\n gapY,\n ...props\n }: GridProps<C>,\n ref?: PolymorphicRef<C>,\n ) => {\n const Component = as || 'div';\n\n const dynamicStyles: React.CSSProperties = {};\n\n // To support any value on the columns props\n if (columns !== undefined) {\n dynamicStyles.gridTemplateColumns = `repeat(${columns}, 1fr)`;\n }\n\n const mergedStyles = useInlineStyle(css, { ...dynamicStyles, ...style });\n\n const recipeClass = gridClass({ align, justify, flow, gap, gapX, gapY });\n\n return (\n <Component ref={ref} className={cx(recipeClass, className)} style={mergedStyles} {...props} />\n );\n },\n);\n\nGridVanillaComponent.displayName = 'GridVanilla';\n\nexport const GridVanilla = GridVanillaComponent as GridComponent;\n"],"mappings":";;;;;;;AAeA,IAAM,YAAY,gBAAgB,UAAU;AAe5C,IAAa,uBAAuB,MAAM,YAEtC,EACE,IACA,WACA,KACA,OACA,OACA,SACA,MACA,SACA,KACA,MACA,MACA,GAAG,SAEL,QACG;CACH,MAAM,YAAY,MAAM;CAExB,MAAM,gBAAqC,CAAC;CAG5C,IAAI,YAAY,KAAA,GACd,cAAc,sBAAsB,UAAU,QAAQ;CAGxD,MAAM,eAAe,eAAe,KAAK;EAAE,GAAG;EAAe,GAAG;CAAM,CAAC;CAEvE,MAAM,cAAc,UAAU;EAAE;EAAO;EAAS;EAAM;EAAK;EAAM;CAAK,CAAC;CAEvE,OACE,oBAAC,WAAD;EAAgB;EAAK,WAAW,GAAG,aAAa,SAAS;EAAG,OAAO;EAAc,GAAI;CAAQ,CAAA;AAEjG,CACF;AAEA,qBAAqB,cAAc;AAEnC,IAAa,cAAc"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
const require_cx = require("../../styles/cx.cjs");
|
|
2
|
+
const require_useInlineStyle = require("../../styles/useInlineStyle.cjs");
|
|
3
|
+
const require_Heading_vanilla_css = require("./Heading.vanilla.css.cjs");
|
|
4
|
+
let react = require("react");
|
|
5
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
6
|
+
// components/Heading/Heading.vanilla.tsx
|
|
7
|
+
function createHeadingComponent(defaultElement, recipe, baseStyle, displayName) {
|
|
8
|
+
const HeadingImpl = (0, react.forwardRef)(({ as, className, css, style, transform, ...props }, ref) => {
|
|
9
|
+
const Component = as || defaultElement;
|
|
10
|
+
const mergedStyles = require_useInlineStyle.useInlineStyle(css, style);
|
|
11
|
+
const combinedClassName = require_cx.cx(transform ? recipe({ transform }) : baseStyle, className);
|
|
12
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Component, {
|
|
13
|
+
ref,
|
|
14
|
+
className: combinedClassName,
|
|
15
|
+
style: mergedStyles,
|
|
16
|
+
...props
|
|
17
|
+
});
|
|
18
|
+
});
|
|
19
|
+
HeadingImpl.displayName = displayName;
|
|
20
|
+
return HeadingImpl;
|
|
21
|
+
}
|
|
22
|
+
var H1Vanilla = createHeadingComponent("h1", require_Heading_vanilla_css.h1Recipe, require_Heading_vanilla_css.h1Style, "H1Vanilla");
|
|
23
|
+
var H2Vanilla = createHeadingComponent("h2", require_Heading_vanilla_css.h2Recipe, require_Heading_vanilla_css.h2Style, "H2Vanilla");
|
|
24
|
+
var H3Vanilla = createHeadingComponent("h3", require_Heading_vanilla_css.h3Recipe, require_Heading_vanilla_css.h3Style, "H3Vanilla");
|
|
25
|
+
var H4Vanilla = createHeadingComponent("h4", require_Heading_vanilla_css.h4Recipe, require_Heading_vanilla_css.h4Style, "H4Vanilla");
|
|
26
|
+
var H5Vanilla = createHeadingComponent("h5", require_Heading_vanilla_css.h5Recipe, require_Heading_vanilla_css.h5Style, "H5Vanilla");
|
|
27
|
+
var H6Vanilla = createHeadingComponent("h6", require_Heading_vanilla_css.h6Recipe, require_Heading_vanilla_css.h6Style, "H6Vanilla");
|
|
28
|
+
exports.H1Vanilla = H1Vanilla;
|
|
29
|
+
exports.H2Vanilla = H2Vanilla;
|
|
30
|
+
exports.H3Vanilla = H3Vanilla;
|
|
31
|
+
exports.H4Vanilla = H4Vanilla;
|
|
32
|
+
exports.H5Vanilla = H5Vanilla;
|
|
33
|
+
exports.H6Vanilla = H6Vanilla;
|
|
34
|
+
|
|
35
|
+
//# sourceMappingURL=Heading.vanilla.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Heading.vanilla.cjs","names":["forwardRef","useInlineStyle","cx","h1Recipe","h1Style","h2Recipe","h2Style","h3Recipe","h3Style","h4Recipe","h4Style","h5Recipe","h5Style","h6Recipe","h6Style"],"sources":["../../../components/Heading/Heading.vanilla.tsx"],"sourcesContent":["import { ElementType, forwardRef } from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { cx } from '@/styles/cx';\nimport {\n PolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n} from '@/styles/polymorphic';\nimport type { RecipeVariantProps } from '@/styles/recipeVariants';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport {\n h1Recipe,\n h1Style,\n h2Recipe,\n h2Style,\n h3Recipe,\n h3Style,\n h4Recipe,\n h4Style,\n h5Recipe,\n h5Style,\n h6Recipe,\n h6Style,\n} from './Heading.vanilla.css';\n\ntype HeadingRecipeVariants = RecipeVariantProps<typeof h1Recipe>;\n\ninterface HeadingOwnProps extends HeadingRecipeVariants, CSSProps {}\n\ntype HeadingProps<C extends ElementType> = PolymorphicComponentProps<C, HeadingOwnProps>;\n\nfunction createHeadingComponent<C extends ElementType>(\n defaultElement: C,\n recipe: typeof h1Recipe,\n baseStyle: string,\n displayName: string,\n) {\n type HeadingComponent = PolymorphicComponent<C, HeadingProps<ElementType>>;\n\n const HeadingImpl = forwardRef(\n <E extends ElementType = C>(\n { as, className, css, style, transform, ...props }: HeadingProps<E>,\n ref?: PolymorphicRef<E>,\n ) => {\n const Component = (as || defaultElement) as ElementType;\n const mergedStyles = useInlineStyle(css, style);\n\n const combinedClassName = cx(transform ? recipe({ transform }) : baseStyle, className);\n\n return <Component ref={ref} className={combinedClassName} style={mergedStyles} {...props} />;\n },\n );\n\n HeadingImpl.displayName = displayName;\n\n return HeadingImpl as HeadingComponent;\n}\n\nexport type H1VanillaProps<C extends ElementType = 'h1'> = HeadingProps<C>;\nexport type H2VanillaProps<C extends ElementType = 'h2'> = HeadingProps<C>;\nexport type H3VanillaProps<C extends ElementType = 'h3'> = HeadingProps<C>;\nexport type H4VanillaProps<C extends ElementType = 'h4'> = HeadingProps<C>;\nexport type H5VanillaProps<C extends ElementType = 'h5'> = HeadingProps<C>;\nexport type H6VanillaProps<C extends ElementType = 'h6'> = HeadingProps<C>;\n\nexport const H1Vanilla = createHeadingComponent<'h1'>('h1', h1Recipe, h1Style, 'H1Vanilla');\nexport const H2Vanilla = createHeadingComponent<'h2'>('h2', h2Recipe, h2Style, 'H2Vanilla');\nexport const H3Vanilla = createHeadingComponent<'h3'>('h3', h3Recipe, h3Style, 'H3Vanilla');\nexport const H4Vanilla = createHeadingComponent<'h4'>('h4', h4Recipe, h4Style, 'H4Vanilla');\nexport const H5Vanilla = createHeadingComponent<'h5'>('h5', h5Recipe, h5Style, 'H5Vanilla');\nexport const H6Vanilla = createHeadingComponent<'h6'>('h6', h6Recipe, h6Style, 'H6Vanilla');\n"],"mappings":";;;;;;AAiCA,SAAS,uBACP,gBACA,QACA,WACA,aACA;CAGA,MAAM,eAAA,GAAcA,MAAAA,WAAAA,EAEhB,EAAE,IAAI,WAAW,KAAK,OAAO,WAAW,GAAG,SAC3C,QACG;EACH,MAAM,YAAa,MAAM;EACzB,MAAM,eAAeC,uBAAAA,eAAe,KAAK,KAAK;EAE9C,MAAM,oBAAoBC,WAAAA,GAAG,YAAY,OAAO,EAAE,UAAU,CAAC,IAAI,WAAW,SAAS;EAErF,OAAO,iBAAA,GAAA,kBAAA,IAAA,CAAC,WAAD;GAAgB;GAAK,WAAW;GAAmB,OAAO;GAAc,GAAI;EAAQ,CAAA;CAC7F,CACF;CAEA,YAAY,cAAc;CAE1B,OAAO;AACT;AASA,IAAa,YAAY,uBAA6B,MAAMC,4BAAAA,UAAUC,4BAAAA,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAMC,4BAAAA,UAAUC,4BAAAA,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAMC,4BAAAA,UAAUC,4BAAAA,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAMC,4BAAAA,UAAUC,4BAAAA,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAMC,4BAAAA,UAAUC,4BAAAA,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAMC,4BAAAA,UAAUC,4BAAAA,SAAS,WAAW"}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
;/* empty css */
|
|
2
|
+
;/* empty css */
|
|
3
|
+
;/* empty css */
|
|
4
|
+
let _vanilla_extract_recipes_createRuntimeFn = require("@vanilla-extract/recipes/createRuntimeFn");
|
|
5
|
+
// components/Heading/Heading.vanilla.css.ts
|
|
6
|
+
var h1Recipe = (0, _vanilla_extract_recipes_createRuntimeFn.createRuntimeFn)({
|
|
7
|
+
defaultClassName: "_1qeu5xr1 _1qeu5xr0",
|
|
8
|
+
variantClassNames: { transform: {
|
|
9
|
+
uppercase: "_1qeu5xr2",
|
|
10
|
+
capitalize: "_1qeu5xr3",
|
|
11
|
+
capitalizeWords: "_1qeu5xr4"
|
|
12
|
+
} },
|
|
13
|
+
defaultVariants: {},
|
|
14
|
+
compoundVariants: []
|
|
15
|
+
});
|
|
16
|
+
var h1Style = "_1qeu5xr5 _1qeu5xr0";
|
|
17
|
+
var h2Recipe = (0, _vanilla_extract_recipes_createRuntimeFn.createRuntimeFn)({
|
|
18
|
+
defaultClassName: "_1qeu5xr6 _1qeu5xr0",
|
|
19
|
+
variantClassNames: { transform: {
|
|
20
|
+
uppercase: "_1qeu5xr7",
|
|
21
|
+
capitalize: "_1qeu5xr8",
|
|
22
|
+
capitalizeWords: "_1qeu5xr9"
|
|
23
|
+
} },
|
|
24
|
+
defaultVariants: {},
|
|
25
|
+
compoundVariants: []
|
|
26
|
+
});
|
|
27
|
+
var h2Style = "_1qeu5xra _1qeu5xr0";
|
|
28
|
+
var h3Recipe = (0, _vanilla_extract_recipes_createRuntimeFn.createRuntimeFn)({
|
|
29
|
+
defaultClassName: "_1qeu5xrb _1qeu5xr0",
|
|
30
|
+
variantClassNames: { transform: {
|
|
31
|
+
uppercase: "_1qeu5xrc",
|
|
32
|
+
capitalize: "_1qeu5xrd",
|
|
33
|
+
capitalizeWords: "_1qeu5xre"
|
|
34
|
+
} },
|
|
35
|
+
defaultVariants: {},
|
|
36
|
+
compoundVariants: []
|
|
37
|
+
});
|
|
38
|
+
var h3Style = "_1qeu5xrf _1qeu5xr0";
|
|
39
|
+
var h4Recipe = (0, _vanilla_extract_recipes_createRuntimeFn.createRuntimeFn)({
|
|
40
|
+
defaultClassName: "_1qeu5xrg _1qeu5xr0",
|
|
41
|
+
variantClassNames: { transform: {
|
|
42
|
+
uppercase: "_1qeu5xrh",
|
|
43
|
+
capitalize: "_1qeu5xri",
|
|
44
|
+
capitalizeWords: "_1qeu5xrj"
|
|
45
|
+
} },
|
|
46
|
+
defaultVariants: {},
|
|
47
|
+
compoundVariants: []
|
|
48
|
+
});
|
|
49
|
+
var h4Style = "_1qeu5xrk _1qeu5xr0";
|
|
50
|
+
var h5Recipe = (0, _vanilla_extract_recipes_createRuntimeFn.createRuntimeFn)({
|
|
51
|
+
defaultClassName: "_1qeu5xrl _1qeu5xr0",
|
|
52
|
+
variantClassNames: { transform: {
|
|
53
|
+
uppercase: "_1qeu5xrm",
|
|
54
|
+
capitalize: "_1qeu5xrn",
|
|
55
|
+
capitalizeWords: "_1qeu5xro"
|
|
56
|
+
} },
|
|
57
|
+
defaultVariants: {},
|
|
58
|
+
compoundVariants: []
|
|
59
|
+
});
|
|
60
|
+
var h5Style = "_1qeu5xrp _1qeu5xr0";
|
|
61
|
+
var h6Recipe = (0, _vanilla_extract_recipes_createRuntimeFn.createRuntimeFn)({
|
|
62
|
+
defaultClassName: "_1qeu5xrq _1qeu5xr0",
|
|
63
|
+
variantClassNames: { transform: {
|
|
64
|
+
uppercase: "_1qeu5xrr",
|
|
65
|
+
capitalize: "_1qeu5xrs",
|
|
66
|
+
capitalizeWords: "_1qeu5xrt"
|
|
67
|
+
} },
|
|
68
|
+
defaultVariants: {},
|
|
69
|
+
compoundVariants: []
|
|
70
|
+
});
|
|
71
|
+
var h6Style = "_1qeu5xru _1qeu5xr0";
|
|
72
|
+
exports.h1Recipe = h1Recipe;
|
|
73
|
+
exports.h1Style = h1Style;
|
|
74
|
+
exports.h2Recipe = h2Recipe;
|
|
75
|
+
exports.h2Style = h2Style;
|
|
76
|
+
exports.h3Recipe = h3Recipe;
|
|
77
|
+
exports.h3Style = h3Style;
|
|
78
|
+
exports.h4Recipe = h4Recipe;
|
|
79
|
+
exports.h4Style = h4Style;
|
|
80
|
+
exports.h5Recipe = h5Recipe;
|
|
81
|
+
exports.h5Style = h5Style;
|
|
82
|
+
exports.h6Recipe = h6Recipe;
|
|
83
|
+
exports.h6Style = h6Style;
|
|
84
|
+
|
|
85
|
+
//# sourceMappingURL=Heading.vanilla.css.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Heading.vanilla.css.cjs","names":[],"sources":[],"mappings":""}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/* empty css */
|
|
2
|
+
/* empty css */
|
|
3
|
+
/* empty css */
|
|
4
|
+
import { createRuntimeFn } from "@vanilla-extract/recipes/createRuntimeFn";
|
|
5
|
+
// components/Heading/Heading.vanilla.css.ts
|
|
6
|
+
var h1Recipe = createRuntimeFn({
|
|
7
|
+
defaultClassName: "_1qeu5xr1 _1qeu5xr0",
|
|
8
|
+
variantClassNames: { transform: {
|
|
9
|
+
uppercase: "_1qeu5xr2",
|
|
10
|
+
capitalize: "_1qeu5xr3",
|
|
11
|
+
capitalizeWords: "_1qeu5xr4"
|
|
12
|
+
} },
|
|
13
|
+
defaultVariants: {},
|
|
14
|
+
compoundVariants: []
|
|
15
|
+
});
|
|
16
|
+
var h1Style = "_1qeu5xr5 _1qeu5xr0";
|
|
17
|
+
var h2Recipe = createRuntimeFn({
|
|
18
|
+
defaultClassName: "_1qeu5xr6 _1qeu5xr0",
|
|
19
|
+
variantClassNames: { transform: {
|
|
20
|
+
uppercase: "_1qeu5xr7",
|
|
21
|
+
capitalize: "_1qeu5xr8",
|
|
22
|
+
capitalizeWords: "_1qeu5xr9"
|
|
23
|
+
} },
|
|
24
|
+
defaultVariants: {},
|
|
25
|
+
compoundVariants: []
|
|
26
|
+
});
|
|
27
|
+
var h2Style = "_1qeu5xra _1qeu5xr0";
|
|
28
|
+
var h3Recipe = createRuntimeFn({
|
|
29
|
+
defaultClassName: "_1qeu5xrb _1qeu5xr0",
|
|
30
|
+
variantClassNames: { transform: {
|
|
31
|
+
uppercase: "_1qeu5xrc",
|
|
32
|
+
capitalize: "_1qeu5xrd",
|
|
33
|
+
capitalizeWords: "_1qeu5xre"
|
|
34
|
+
} },
|
|
35
|
+
defaultVariants: {},
|
|
36
|
+
compoundVariants: []
|
|
37
|
+
});
|
|
38
|
+
var h3Style = "_1qeu5xrf _1qeu5xr0";
|
|
39
|
+
var h4Recipe = createRuntimeFn({
|
|
40
|
+
defaultClassName: "_1qeu5xrg _1qeu5xr0",
|
|
41
|
+
variantClassNames: { transform: {
|
|
42
|
+
uppercase: "_1qeu5xrh",
|
|
43
|
+
capitalize: "_1qeu5xri",
|
|
44
|
+
capitalizeWords: "_1qeu5xrj"
|
|
45
|
+
} },
|
|
46
|
+
defaultVariants: {},
|
|
47
|
+
compoundVariants: []
|
|
48
|
+
});
|
|
49
|
+
var h4Style = "_1qeu5xrk _1qeu5xr0";
|
|
50
|
+
var h5Recipe = createRuntimeFn({
|
|
51
|
+
defaultClassName: "_1qeu5xrl _1qeu5xr0",
|
|
52
|
+
variantClassNames: { transform: {
|
|
53
|
+
uppercase: "_1qeu5xrm",
|
|
54
|
+
capitalize: "_1qeu5xrn",
|
|
55
|
+
capitalizeWords: "_1qeu5xro"
|
|
56
|
+
} },
|
|
57
|
+
defaultVariants: {},
|
|
58
|
+
compoundVariants: []
|
|
59
|
+
});
|
|
60
|
+
var h5Style = "_1qeu5xrp _1qeu5xr0";
|
|
61
|
+
var h6Recipe = createRuntimeFn({
|
|
62
|
+
defaultClassName: "_1qeu5xrq _1qeu5xr0",
|
|
63
|
+
variantClassNames: { transform: {
|
|
64
|
+
uppercase: "_1qeu5xrr",
|
|
65
|
+
capitalize: "_1qeu5xrs",
|
|
66
|
+
capitalizeWords: "_1qeu5xrt"
|
|
67
|
+
} },
|
|
68
|
+
defaultVariants: {},
|
|
69
|
+
compoundVariants: []
|
|
70
|
+
});
|
|
71
|
+
var h6Style = "_1qeu5xru _1qeu5xr0";
|
|
72
|
+
export { h1Recipe, h1Style, h2Recipe, h2Style, h3Recipe, h3Style, h4Recipe, h4Style, h5Recipe, h5Style, h6Recipe, h6Style };
|
|
73
|
+
|
|
74
|
+
//# sourceMappingURL=Heading.vanilla.css.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Heading.vanilla.css.js","names":[],"sources":[],"mappings":""}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { cx } from "../../styles/cx.js";
|
|
2
|
+
import { useInlineStyle } from "../../styles/useInlineStyle.js";
|
|
3
|
+
import { h1Recipe, h1Style, h2Recipe, h2Style, h3Recipe, h3Style, h4Recipe, h4Style, h5Recipe, h5Style, h6Recipe, h6Style } from "./Heading.vanilla.css.js";
|
|
4
|
+
import { forwardRef } from "react";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
// components/Heading/Heading.vanilla.tsx
|
|
7
|
+
function createHeadingComponent(defaultElement, recipe, baseStyle, displayName) {
|
|
8
|
+
const HeadingImpl = forwardRef(({ as, className, css, style, transform, ...props }, ref) => {
|
|
9
|
+
const Component = as || defaultElement;
|
|
10
|
+
const mergedStyles = useInlineStyle(css, style);
|
|
11
|
+
const combinedClassName = cx(transform ? recipe({ transform }) : baseStyle, className);
|
|
12
|
+
return /* @__PURE__ */ jsx(Component, {
|
|
13
|
+
ref,
|
|
14
|
+
className: combinedClassName,
|
|
15
|
+
style: mergedStyles,
|
|
16
|
+
...props
|
|
17
|
+
});
|
|
18
|
+
});
|
|
19
|
+
HeadingImpl.displayName = displayName;
|
|
20
|
+
return HeadingImpl;
|
|
21
|
+
}
|
|
22
|
+
var H1Vanilla = createHeadingComponent("h1", h1Recipe, h1Style, "H1Vanilla");
|
|
23
|
+
var H2Vanilla = createHeadingComponent("h2", h2Recipe, h2Style, "H2Vanilla");
|
|
24
|
+
var H3Vanilla = createHeadingComponent("h3", h3Recipe, h3Style, "H3Vanilla");
|
|
25
|
+
var H4Vanilla = createHeadingComponent("h4", h4Recipe, h4Style, "H4Vanilla");
|
|
26
|
+
var H5Vanilla = createHeadingComponent("h5", h5Recipe, h5Style, "H5Vanilla");
|
|
27
|
+
var H6Vanilla = createHeadingComponent("h6", h6Recipe, h6Style, "H6Vanilla");
|
|
28
|
+
export { H1Vanilla, H2Vanilla, H3Vanilla, H4Vanilla, H5Vanilla, H6Vanilla };
|
|
29
|
+
|
|
30
|
+
//# sourceMappingURL=Heading.vanilla.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Heading.vanilla.js","names":[],"sources":["../../../components/Heading/Heading.vanilla.tsx"],"sourcesContent":["import { ElementType, forwardRef } from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { cx } from '@/styles/cx';\nimport {\n PolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n} from '@/styles/polymorphic';\nimport type { RecipeVariantProps } from '@/styles/recipeVariants';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport {\n h1Recipe,\n h1Style,\n h2Recipe,\n h2Style,\n h3Recipe,\n h3Style,\n h4Recipe,\n h4Style,\n h5Recipe,\n h5Style,\n h6Recipe,\n h6Style,\n} from './Heading.vanilla.css';\n\ntype HeadingRecipeVariants = RecipeVariantProps<typeof h1Recipe>;\n\ninterface HeadingOwnProps extends HeadingRecipeVariants, CSSProps {}\n\ntype HeadingProps<C extends ElementType> = PolymorphicComponentProps<C, HeadingOwnProps>;\n\nfunction createHeadingComponent<C extends ElementType>(\n defaultElement: C,\n recipe: typeof h1Recipe,\n baseStyle: string,\n displayName: string,\n) {\n type HeadingComponent = PolymorphicComponent<C, HeadingProps<ElementType>>;\n\n const HeadingImpl = forwardRef(\n <E extends ElementType = C>(\n { as, className, css, style, transform, ...props }: HeadingProps<E>,\n ref?: PolymorphicRef<E>,\n ) => {\n const Component = (as || defaultElement) as ElementType;\n const mergedStyles = useInlineStyle(css, style);\n\n const combinedClassName = cx(transform ? recipe({ transform }) : baseStyle, className);\n\n return <Component ref={ref} className={combinedClassName} style={mergedStyles} {...props} />;\n },\n );\n\n HeadingImpl.displayName = displayName;\n\n return HeadingImpl as HeadingComponent;\n}\n\nexport type H1VanillaProps<C extends ElementType = 'h1'> = HeadingProps<C>;\nexport type H2VanillaProps<C extends ElementType = 'h2'> = HeadingProps<C>;\nexport type H3VanillaProps<C extends ElementType = 'h3'> = HeadingProps<C>;\nexport type H4VanillaProps<C extends ElementType = 'h4'> = HeadingProps<C>;\nexport type H5VanillaProps<C extends ElementType = 'h5'> = HeadingProps<C>;\nexport type H6VanillaProps<C extends ElementType = 'h6'> = HeadingProps<C>;\n\nexport const H1Vanilla = createHeadingComponent<'h1'>('h1', h1Recipe, h1Style, 'H1Vanilla');\nexport const H2Vanilla = createHeadingComponent<'h2'>('h2', h2Recipe, h2Style, 'H2Vanilla');\nexport const H3Vanilla = createHeadingComponent<'h3'>('h3', h3Recipe, h3Style, 'H3Vanilla');\nexport const H4Vanilla = createHeadingComponent<'h4'>('h4', h4Recipe, h4Style, 'H4Vanilla');\nexport const H5Vanilla = createHeadingComponent<'h5'>('h5', h5Recipe, h5Style, 'H5Vanilla');\nexport const H6Vanilla = createHeadingComponent<'h6'>('h6', h6Recipe, h6Style, 'H6Vanilla');\n"],"mappings":";;;;;;AAiCA,SAAS,uBACP,gBACA,QACA,WACA,aACA;CAGA,MAAM,cAAc,YAEhB,EAAE,IAAI,WAAW,KAAK,OAAO,WAAW,GAAG,SAC3C,QACG;EACH,MAAM,YAAa,MAAM;EACzB,MAAM,eAAe,eAAe,KAAK,KAAK;EAE9C,MAAM,oBAAoB,GAAG,YAAY,OAAO,EAAE,UAAU,CAAC,IAAI,WAAW,SAAS;EAErF,OAAO,oBAAC,WAAD;GAAgB;GAAK,WAAW;GAAmB,OAAO;GAAc,GAAI;EAAQ,CAAA;CAC7F,CACF;CAEA,YAAY,cAAc;CAE1B,OAAO;AACT;AASA,IAAa,YAAY,uBAA6B,MAAM,UAAU,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAM,UAAU,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAM,UAAU,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAM,UAAU,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAM,UAAU,SAAS,WAAW;AAC1F,IAAa,YAAY,uBAA6B,MAAM,UAAU,SAAS,WAAW"}
|
|
@@ -1,21 +1,15 @@
|
|
|
1
|
-
const require_cssProps = require("../../styles/cssProps.cjs");
|
|
2
1
|
const require_cx = require("../../styles/cx.cjs");
|
|
3
|
-
const
|
|
2
|
+
const require_recipeVariants = require("../../styles/recipeVariants.cjs");
|
|
3
|
+
const require_useInlineStyle = require("../../styles/useInlineStyle.cjs");
|
|
4
4
|
const require_IconButton_vanilla_css = require("./IconButton.vanilla.css.cjs");
|
|
5
5
|
let react = require("react");
|
|
6
|
-
let _vanilla_extract_dynamic = require("@vanilla-extract/dynamic");
|
|
7
6
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
8
7
|
// components/IconButton/IconButton.vanilla.tsx
|
|
8
|
+
var iconButtonClass = require_recipeVariants.withVariantKeys(require_IconButton_vanilla_css.iconButtonRecipe);
|
|
9
9
|
var IconButtonVanillaComponentImpl = (0, react.forwardRef)(({ as, className, css, style, size, variant, ...props }, ref) => {
|
|
10
10
|
const Component = as || "button";
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const mergedStyles = {
|
|
14
|
-
...cssStyles,
|
|
15
|
-
...style,
|
|
16
|
-
...(0, _vanilla_extract_dynamic.assignInlineVars)(vars)
|
|
17
|
-
};
|
|
18
|
-
const recipeClass = require_IconButton_vanilla_css.iconButtonRecipe({
|
|
11
|
+
const mergedStyles = require_useInlineStyle.useInlineStyle(css, style);
|
|
12
|
+
const recipeClass = iconButtonClass({
|
|
19
13
|
size,
|
|
20
14
|
variant
|
|
21
15
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IconButton.vanilla.cjs","names":["
|
|
1
|
+
{"version":3,"file":"IconButton.vanilla.cjs","names":["withVariantKeys","iconButtonRecipe","forwardRef","useInlineStyle","cx"],"sources":["../../../components/IconButton/IconButton.vanilla.tsx"],"sourcesContent":["import { ElementType, forwardRef } from 'react';\n\nimport { CSSProps } from '@/styles/cssProps';\nimport { cx } from '@/styles/cx';\nimport {\n PolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n} from '@/styles/polymorphic';\nimport { RecipeVariantProps, withVariantKeys } from '@/styles/recipeVariants';\nimport { useInlineStyle } from '@/styles/useInlineStyle';\n\nimport { iconButtonRecipe } from './IconButton.vanilla.css';\n\nconst iconButtonClass = withVariantKeys(iconButtonRecipe);\n\ntype IconButtonRecipeVariants = RecipeVariantProps<typeof iconButtonRecipe>;\n\ninterface IconButtonOwnProps extends IconButtonRecipeVariants, CSSProps {}\n\nexport type IconButtonVanillaProps<C extends ElementType = 'button'> = PolymorphicComponentProps<\n C,\n IconButtonOwnProps\n>;\n\ntype IconButtonVanillaComponent = PolymorphicComponent<\n 'button',\n IconButtonVanillaProps<ElementType>\n>;\n\nconst IconButtonVanillaComponentImpl = forwardRef(\n <C extends ElementType = 'button'>(\n { as, className, css, style, size, variant, ...props }: IconButtonVanillaProps<C>,\n ref?: PolymorphicRef<C>,\n ) => {\n const Component = as || 'button';\n\n const mergedStyles = useInlineStyle(css, style);\n\n const recipeClass = iconButtonClass({ size, variant });\n\n return (\n <Component ref={ref} className={cx(recipeClass, className)} style={mergedStyles} {...props} />\n );\n },\n);\n\nIconButtonVanillaComponentImpl.displayName = 'IconButtonVanilla';\n\nexport const IconButtonVanilla = IconButtonVanillaComponentImpl as IconButtonVanillaComponent;\n"],"mappings":";;;;;;;AAcA,IAAM,kBAAkBA,uBAAAA,gBAAgBC,+BAAAA,gBAAgB;AAgBxD,IAAM,kCAAA,GAAiCC,MAAAA,WAAAA,EAEnC,EAAE,IAAI,WAAW,KAAK,OAAO,MAAM,SAAS,GAAG,SAC/C,QACG;CACH,MAAM,YAAY,MAAM;CAExB,MAAM,eAAeC,uBAAAA,eAAe,KAAK,KAAK;CAE9C,MAAM,cAAc,gBAAgB;EAAE;EAAM;CAAQ,CAAC;CAErD,OACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,WAAD;EAAgB;EAAK,WAAWC,WAAAA,GAAG,aAAa,SAAS;EAAG,OAAO;EAAc,GAAI;CAAQ,CAAA;AAEjG,CACF;AAEA,+BAA+B,cAAc;AAE7C,IAAa,oBAAoB"}
|