@wordpress/ui 0.5.1-next.v.0 → 0.6.0
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/CHANGELOG.md +5 -1
- package/build/box/box.cjs +2 -2
- package/build/box/box.cjs.map +2 -2
- package/build/button/button.cjs +18 -303
- package/build/button/button.cjs.map +3 -3
- package/build/form/primitives/constants.cjs +35 -0
- package/build/form/primitives/constants.cjs.map +7 -0
- package/build/form/primitives/field/description.cjs +6 -33
- package/build/form/primitives/field/description.cjs.map +2 -2
- package/build/form/primitives/field/details.cjs +6 -33
- package/build/form/primitives/field/details.cjs.map +2 -2
- package/build/form/primitives/field/label.cjs +6 -33
- package/build/form/primitives/field/label.cjs.map +2 -2
- package/build/form/primitives/field/root.cjs +6 -17
- package/build/form/primitives/field/root.cjs.map +2 -2
- package/build/form/primitives/fieldset/description.cjs +6 -33
- package/build/form/primitives/fieldset/description.cjs.map +2 -2
- package/build/form/primitives/fieldset/details.cjs +6 -33
- package/build/form/primitives/fieldset/details.cjs.map +2 -2
- package/build/form/primitives/fieldset/legend.cjs +6 -33
- package/build/form/primitives/fieldset/legend.cjs.map +2 -2
- package/build/form/primitives/fieldset/root.cjs +6 -16
- package/build/form/primitives/fieldset/root.cjs.map +2 -2
- package/build/form/primitives/index.cjs +8 -2
- package/build/form/primitives/index.cjs.map +2 -2
- package/build/form/primitives/input/index.cjs +31 -0
- package/build/form/primitives/input/index.cjs.map +7 -0
- package/build/form/primitives/input/input.cjs +82 -0
- package/build/form/primitives/input/input.cjs.map +7 -0
- package/build/form/primitives/input/types.cjs +19 -0
- package/build/form/primitives/input/types.cjs.map +7 -0
- package/build/form/primitives/input-layout/input-layout.cjs +12 -111
- package/build/form/primitives/input-layout/input-layout.cjs.map +3 -3
- package/build/form/primitives/input-layout/slot.cjs +6 -94
- package/build/form/primitives/input-layout/slot.cjs.map +2 -2
- package/build/form/primitives/select/index.cjs +40 -0
- package/build/form/primitives/select/index.cjs.map +7 -0
- package/build/form/primitives/select/item.cjs +98 -0
- package/build/form/primitives/select/item.cjs.map +7 -0
- package/build/form/primitives/select/popup.cjs +109 -0
- package/build/form/primitives/select/popup.cjs.map +7 -0
- package/build/form/primitives/select/root.cjs +35 -0
- package/build/form/primitives/select/root.cjs.map +7 -0
- package/build/form/primitives/select/trigger.cjs +116 -0
- package/build/form/primitives/select/trigger.cjs.map +7 -0
- package/build/form/primitives/select/types.cjs +19 -0
- package/build/form/primitives/select/types.cjs.map +7 -0
- package/build/index.cjs +19 -0
- package/build/index.cjs.map +2 -2
- package/build/lock-unlock.cjs +37 -0
- package/build/lock-unlock.cjs.map +7 -0
- package/build/stack/stack.cjs +6 -11
- package/build/stack/stack.cjs.map +2 -2
- package/build/tooltip/index.cjs +40 -0
- package/build/tooltip/index.cjs.map +7 -0
- package/build/tooltip/popup.cjs +100 -0
- package/build/tooltip/popup.cjs.map +7 -0
- package/build/tooltip/provider.cjs +35 -0
- package/build/tooltip/provider.cjs.map +7 -0
- package/build/tooltip/root.cjs +35 -0
- package/build/tooltip/root.cjs.map +7 -0
- package/build/tooltip/trigger.cjs +38 -0
- package/build/tooltip/trigger.cjs.map +7 -0
- package/build/tooltip/types.cjs +19 -0
- package/build/tooltip/types.cjs.map +7 -0
- package/build/utils/types.cjs.map +1 -1
- package/build/visually-hidden/visually-hidden.cjs +6 -19
- package/build/visually-hidden/visually-hidden.cjs.map +2 -2
- package/build-module/box/box.mjs +2 -2
- package/build-module/box/box.mjs.map +2 -2
- package/build-module/button/button.mjs +18 -303
- package/build-module/button/button.mjs.map +3 -3
- package/build-module/form/primitives/constants.mjs +10 -0
- package/build-module/form/primitives/constants.mjs.map +7 -0
- package/build-module/form/primitives/field/description.mjs +6 -33
- package/build-module/form/primitives/field/description.mjs.map +2 -2
- package/build-module/form/primitives/field/details.mjs +6 -33
- package/build-module/form/primitives/field/details.mjs.map +2 -2
- package/build-module/form/primitives/field/label.mjs +6 -33
- package/build-module/form/primitives/field/label.mjs.map +2 -2
- package/build-module/form/primitives/field/root.mjs +6 -17
- package/build-module/form/primitives/field/root.mjs.map +2 -2
- package/build-module/form/primitives/fieldset/description.mjs +6 -33
- package/build-module/form/primitives/fieldset/description.mjs.map +2 -2
- package/build-module/form/primitives/fieldset/details.mjs +6 -33
- package/build-module/form/primitives/fieldset/details.mjs.map +2 -2
- package/build-module/form/primitives/fieldset/legend.mjs +6 -33
- package/build-module/form/primitives/fieldset/legend.mjs.map +2 -2
- package/build-module/form/primitives/fieldset/root.mjs +6 -16
- package/build-module/form/primitives/fieldset/root.mjs.map +2 -2
- package/build-module/form/primitives/index.mjs +5 -1
- package/build-module/form/primitives/index.mjs.map +2 -2
- package/build-module/form/primitives/input/index.mjs +6 -0
- package/build-module/form/primitives/input/index.mjs.map +7 -0
- package/build-module/form/primitives/input/input.mjs +47 -0
- package/build-module/form/primitives/input/input.mjs.map +7 -0
- package/build-module/form/primitives/input/types.mjs +1 -0
- package/build-module/form/primitives/input/types.mjs.map +7 -0
- package/build-module/form/primitives/input-layout/input-layout.mjs +12 -111
- package/build-module/form/primitives/input-layout/input-layout.mjs.map +3 -3
- package/build-module/form/primitives/input-layout/slot.mjs +6 -94
- package/build-module/form/primitives/input-layout/slot.mjs.map +2 -2
- package/build-module/form/primitives/select/index.mjs +12 -0
- package/build-module/form/primitives/select/index.mjs.map +7 -0
- package/build-module/form/primitives/select/item.mjs +63 -0
- package/build-module/form/primitives/select/item.mjs.map +7 -0
- package/build-module/form/primitives/select/popup.mjs +76 -0
- package/build-module/form/primitives/select/popup.mjs.map +7 -0
- package/build-module/form/primitives/select/root.mjs +10 -0
- package/build-module/form/primitives/select/root.mjs.map +7 -0
- package/build-module/form/primitives/select/trigger.mjs +81 -0
- package/build-module/form/primitives/select/trigger.mjs.map +7 -0
- package/build-module/form/primitives/select/types.mjs +1 -0
- package/build-module/form/primitives/select/types.mjs.map +7 -0
- package/build-module/index.mjs +4 -0
- package/build-module/index.mjs.map +2 -2
- package/build-module/lock-unlock.mjs +11 -0
- package/build-module/lock-unlock.mjs.map +7 -0
- package/build-module/stack/stack.mjs +6 -11
- package/build-module/stack/stack.mjs.map +2 -2
- package/build-module/tooltip/index.mjs +12 -0
- package/build-module/tooltip/index.mjs.map +7 -0
- package/build-module/tooltip/popup.mjs +67 -0
- package/build-module/tooltip/popup.mjs.map +7 -0
- package/build-module/tooltip/provider.mjs +10 -0
- package/build-module/tooltip/provider.mjs.map +7 -0
- package/build-module/tooltip/root.mjs +10 -0
- package/build-module/tooltip/root.mjs.map +7 -0
- package/build-module/tooltip/trigger.mjs +13 -0
- package/build-module/tooltip/trigger.mjs.map +7 -0
- package/build-module/tooltip/types.mjs +1 -0
- package/build-module/tooltip/types.mjs.map +7 -0
- package/build-module/visually-hidden/visually-hidden.mjs +6 -19
- package/build-module/visually-hidden/visually-hidden.mjs.map +2 -2
- package/build-types/badge/stories/choosing-intent.story.d.ts +17 -0
- package/build-types/badge/stories/choosing-intent.story.d.ts.map +1 -0
- package/build-types/badge/stories/index.story.d.ts +1 -1
- package/build-types/badge/stories/index.story.d.ts.map +1 -1
- package/build-types/box/stories/index.story.d.ts +1 -1
- package/build-types/box/stories/index.story.d.ts.map +1 -1
- package/build-types/button/stories/index.story.d.ts +1 -1
- package/build-types/button/stories/index.story.d.ts.map +1 -1
- package/build-types/form/primitives/constants.d.ts +9 -0
- package/build-types/form/primitives/constants.d.ts.map +1 -0
- package/build-types/form/primitives/field/stories/index.story.d.ts +1 -1
- package/build-types/form/primitives/field/stories/index.story.d.ts.map +1 -1
- package/build-types/form/primitives/fieldset/stories/index.story.d.ts +1 -1
- package/build-types/form/primitives/fieldset/stories/index.story.d.ts.map +1 -1
- package/build-types/form/primitives/index.d.ts +2 -0
- package/build-types/form/primitives/index.d.ts.map +1 -1
- package/build-types/form/primitives/input/index.d.ts +2 -0
- package/build-types/form/primitives/input/index.d.ts.map +1 -0
- package/build-types/form/primitives/input/input.d.ts +10 -0
- package/build-types/form/primitives/input/input.d.ts.map +1 -0
- package/build-types/form/primitives/input/stories/index.story.d.ts +13 -0
- package/build-types/form/primitives/input/stories/index.story.d.ts.map +1 -0
- package/build-types/form/primitives/input/test/index.test.d.ts +2 -0
- package/build-types/form/primitives/input/test/index.test.d.ts.map +1 -0
- package/build-types/form/primitives/input/types.d.ts +27 -0
- package/build-types/form/primitives/input/types.d.ts.map +1 -0
- package/build-types/form/primitives/input-layout/stories/index.story.d.ts +1 -1
- package/build-types/form/primitives/input-layout/stories/index.story.d.ts.map +1 -1
- package/build-types/form/primitives/select/index.d.ts +5 -0
- package/build-types/form/primitives/select/index.d.ts.map +1 -0
- package/build-types/form/primitives/select/item.d.ts +7 -0
- package/build-types/form/primitives/select/item.d.ts.map +1 -0
- package/build-types/form/primitives/select/popup.d.ts +2 -0
- package/build-types/form/primitives/select/popup.d.ts.map +1 -0
- package/build-types/form/primitives/select/root.d.ts +3 -0
- package/build-types/form/primitives/select/root.d.ts.map +1 -0
- package/build-types/form/primitives/select/stories/index.story.d.ts +50 -0
- package/build-types/form/primitives/select/stories/index.story.d.ts.map +1 -0
- package/build-types/form/primitives/select/test/index.test.d.ts +2 -0
- package/build-types/form/primitives/select/test/index.test.d.ts.map +1 -0
- package/build-types/form/primitives/select/trigger.d.ts +7 -0
- package/build-types/form/primitives/select/trigger.d.ts.map +1 -0
- package/build-types/form/primitives/select/types.d.ts +42 -0
- package/build-types/form/primitives/select/types.d.ts.map +1 -0
- package/build-types/icon/stories/index.story.d.ts +1 -1
- package/build-types/icon/stories/index.story.d.ts.map +1 -1
- package/build-types/index.d.ts +1 -0
- package/build-types/index.d.ts.map +1 -1
- package/build-types/lock-unlock.d.ts +2 -0
- package/build-types/lock-unlock.d.ts.map +1 -0
- package/build-types/stack/stories/index.story.d.ts +1 -1
- package/build-types/stack/stories/index.story.d.ts.map +1 -1
- package/build-types/tooltip/index.d.ts +6 -0
- package/build-types/tooltip/index.d.ts.map +1 -0
- package/build-types/tooltip/popup.d.ts +4 -0
- package/build-types/tooltip/popup.d.ts.map +1 -0
- package/build-types/tooltip/provider.d.ts +4 -0
- package/build-types/tooltip/provider.d.ts.map +1 -0
- package/build-types/tooltip/root.d.ts +4 -0
- package/build-types/tooltip/root.d.ts.map +1 -0
- package/build-types/tooltip/stories/index.story.d.ts +23 -0
- package/build-types/tooltip/stories/index.story.d.ts.map +1 -0
- package/build-types/tooltip/test/index.test.d.ts +2 -0
- package/build-types/tooltip/test/index.test.d.ts.map +1 -0
- package/build-types/tooltip/trigger.d.ts +4 -0
- package/build-types/tooltip/trigger.d.ts.map +1 -0
- package/build-types/tooltip/types.d.ts +18 -0
- package/build-types/tooltip/types.d.ts.map +1 -0
- package/build-types/utils/types.d.ts +0 -3
- package/build-types/utils/types.d.ts.map +1 -1
- package/build-types/visually-hidden/stories/index.story.d.ts +1 -1
- package/build-types/visually-hidden/stories/index.story.d.ts.map +1 -1
- package/package.json +12 -10
- package/src/badge/stories/choosing-intent.mdx +29 -32
- package/src/badge/stories/choosing-intent.story.tsx +129 -0
- package/src/badge/stories/index.story.tsx +1 -1
- package/src/box/box.tsx +2 -2
- package/src/box/stories/index.story.tsx +1 -1
- package/src/box/test/box.test.tsx +0 -11
- package/src/button/stories/index.story.tsx +1 -6
- package/src/button/style.module.css +2 -2
- package/src/button/test/button.test.tsx +1 -16
- package/src/form/primitives/constants.ts +10 -0
- package/src/form/primitives/field/stories/index.story.tsx +1 -1
- package/src/form/primitives/fieldset/stories/index.story.tsx +1 -1
- package/src/form/primitives/index.ts +2 -0
- package/src/form/primitives/input/index.ts +1 -0
- package/src/form/primitives/input/input.tsx +28 -0
- package/src/form/primitives/input/stories/index.story.tsx +40 -0
- package/src/form/primitives/input/style.module.css +34 -0
- package/src/form/primitives/input/test/index.test.tsx +13 -0
- package/src/form/primitives/input/types.ts +31 -0
- package/src/form/primitives/input-layout/stories/index.story.tsx +1 -1
- package/src/form/primitives/input-layout/style.module.css +5 -4
- package/src/form/primitives/select/index.ts +4 -0
- package/src/form/primitives/select/item.tsx +39 -0
- package/src/form/primitives/select/popup.tsx +55 -0
- package/src/form/primitives/select/root.tsx +6 -0
- package/src/form/primitives/select/stories/index.story.tsx +276 -0
- package/src/form/primitives/select/style.module.css +7 -0
- package/src/form/primitives/select/test/index.test.tsx +35 -0
- package/src/form/primitives/select/trigger.tsx +58 -0
- package/src/form/primitives/select/types.ts +52 -0
- package/src/icon/stories/index.story.tsx +1 -1
- package/src/index.ts +1 -0
- package/src/lock-unlock.ts +7 -0
- package/src/stack/stories/index.story.tsx +1 -1
- package/src/stories/introduction.mdx +1 -1
- package/src/tooltip/index.ts +6 -0
- package/src/tooltip/popup.tsx +64 -0
- package/src/tooltip/provider.tsx +8 -0
- package/src/tooltip/root.tsx +8 -0
- package/src/tooltip/stories/index.story.tsx +97 -0
- package/src/tooltip/style.module.css +20 -0
- package/src/tooltip/test/index.test.tsx +87 -0
- package/src/tooltip/trigger.tsx +15 -0
- package/src/tooltip/types.ts +26 -0
- package/src/utils/css/dropdown-motion.module.css +47 -0
- package/src/utils/css/focus.module.css +1 -1
- package/src/utils/css/item-popup.module.css +127 -0
- package/src/utils/css/select-trigger.module.css +58 -0
- package/src/utils/types.ts +0 -3
- package/src/visually-hidden/stories/index.story.tsx +1 -1
|
@@ -39,40 +39,13 @@ var import_element = require("@wordpress/element");
|
|
|
39
39
|
var import_i18n = require("@wordpress/i18n");
|
|
40
40
|
|
|
41
41
|
// packages/ui/src/utils/css/field.module.css
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
font-family: var(--wpds-font-family-body);
|
|
49
|
-
font-size: var(--wpds-font-size-xs);
|
|
50
|
-
line-height: var(--wp-ui-field-label-line-height);
|
|
51
|
-
font-weight: var(--wpds-font-weight-medium);
|
|
52
|
-
text-transform: uppercase;
|
|
53
|
-
color: var(--wpds-color-fg-content-neutral);
|
|
54
|
-
|
|
55
|
-
&.field-module__is-plain__F8QhR {
|
|
56
|
-
font-size: var(--wpds-font-size-md);
|
|
57
|
-
text-transform: none;
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.field-module__description__CKN1B {
|
|
62
|
-
margin: 0;
|
|
63
|
-
font-family: var(--wpds-font-family-body);
|
|
64
|
-
font-size: var(--wpds-font-size-sm);
|
|
65
|
-
line-height: var(--wpds-font-line-height-xs);
|
|
66
|
-
color: var(--wpds-color-fg-content-neutral-weak);
|
|
67
|
-
}
|
|
42
|
+
if (typeof document !== "undefined" && !document.head.querySelector("style[data-wp-hash='04c8f253c6']")) {
|
|
43
|
+
const style = document.createElement("style");
|
|
44
|
+
style.setAttribute("data-wp-hash", "04c8f253c6");
|
|
45
|
+
style.appendChild(document.createTextNode("@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}"));
|
|
46
|
+
document.head.appendChild(style);
|
|
68
47
|
}
|
|
69
|
-
|
|
70
|
-
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
71
|
-
var field_default = {
|
|
72
|
-
"label": "field-module__label__LVrYU",
|
|
73
|
-
"is-plain": "field-module__is-plain__F8QhR",
|
|
74
|
-
"description": "field-module__description__CKN1B"
|
|
75
|
-
};
|
|
48
|
+
var field_default = { "label": "_2d5ad850b2f90964__label", "is-plain": "_17c4214649230bea__is-plain", "description": "_08a3750500e0233f__description" };
|
|
76
49
|
|
|
77
50
|
// packages/ui/src/form/primitives/field/details.tsx
|
|
78
51
|
var import_visually_hidden = require("../../../visually-hidden/index.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form/primitives/field/details.tsx", "../../../../src/utils/css/field.module.css"],
|
|
4
|
-
"sourcesContent": ["import clsx from 'clsx';\nimport { Field as _Field } from '@base-ui/react/field';\nimport { forwardRef } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport type { FieldDetailsProps } from './types';\nimport { VisuallyHidden } from '../../../visually-hidden';\n\n/**\n * A component for showing additional information about the field,\n * styled similarly to a normal `Field.Description`.\n * Unlike a normal description, it can include links and other semantic elements.\n *\n * Although this content is not associated with the field using direct semantics,\n * it is made discoverable to screen reader users via a visually hidden description,\n * alerting them to the presence of additional information below.\n *\n * If the content only includes plain text, use `Field.Description` instead,\n * so the readout is not unnecessarily verbose for screen reader users.\n */\nexport const Details = forwardRef< HTMLDivElement, FieldDetailsProps >(\n\tfunction Details( { className, ...restProps }, ref ) {\n\t\treturn (\n\t\t\t<>\n\t\t\t\t<_Field.Description render={ <VisuallyHidden /> }>\n\t\t\t\t\t{ __( 'More details follow the field.' ) }\n\t\t\t\t</_Field.Description>\n\t\t\t\t<div\n\t\t\t\t\tref={ ref }\n\t\t\t\t\tclassName={ clsx( fieldStyles.description, className ) }\n\t\t\t\t\t{ ...restProps }\n\t\t\t\t></div>\n\t\t\t</>\n\t\t);\n\t}\n);\n", "
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAgC;AAChC,qBAA2B;AAC3B,kBAAmB;;;ACHnB,
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport { Field as _Field } from '@base-ui/react/field';\nimport { forwardRef } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport type { FieldDetailsProps } from './types';\nimport { VisuallyHidden } from '../../../visually-hidden';\n\n/**\n * A component for showing additional information about the field,\n * styled similarly to a normal `Field.Description`.\n * Unlike a normal description, it can include links and other semantic elements.\n *\n * Although this content is not associated with the field using direct semantics,\n * it is made discoverable to screen reader users via a visually hidden description,\n * alerting them to the presence of additional information below.\n *\n * If the content only includes plain text, use `Field.Description` instead,\n * so the readout is not unnecessarily verbose for screen reader users.\n */\nexport const Details = forwardRef< HTMLDivElement, FieldDetailsProps >(\n\tfunction Details( { className, ...restProps }, ref ) {\n\t\treturn (\n\t\t\t<>\n\t\t\t\t<_Field.Description render={ <VisuallyHidden /> }>\n\t\t\t\t\t{ __( 'More details follow the field.' ) }\n\t\t\t\t</_Field.Description>\n\t\t\t\t<div\n\t\t\t\t\tref={ ref }\n\t\t\t\t\tclassName={ clsx( fieldStyles.description, className ) }\n\t\t\t\t\t{ ...restProps }\n\t\t\t\t></div>\n\t\t\t</>\n\t\t);\n\t}\n);\n", "if (typeof document !== 'undefined' && !document.head.querySelector(\"style[data-wp-hash='04c8f253c6']\")) {\n\tconst style = document.createElement(\"style\");\n\tstyle.setAttribute(\"data-wp-hash\", \"04c8f253c6\");\n\tstyle.appendChild(document.createTextNode(\"@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}\"));\n\tdocument.head.appendChild(style);\n}\nexport default {\"label\":\"_2d5ad850b2f90964__label\",\"is-plain\":\"_17c4214649230bea__is-plain\",\"description\":\"_08a3750500e0233f__description\"};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAgC;AAChC,qBAA2B;AAC3B,kBAAmB;;;ACHnB,IAAI,OAAO,aAAa,eAAe,CAAC,SAAS,KAAK,cAAc,kCAAkC,GAAG;AACxG,QAAM,QAAQ,SAAS,cAAc,OAAO;AAC5C,QAAM,aAAa,gBAAgB,YAAY;AAC/C,QAAM,YAAY,SAAS,eAAe,qtBAAqtB,CAAC;AAChwB,WAAS,KAAK,YAAY,KAAK;AAChC;AACA,IAAO,gBAAQ,EAAC,SAAQ,4BAA2B,YAAW,+BAA8B,eAAc,iCAAgC;;;ADA1I,6BAA+B;AAiB5B;AAHI,IAAM,cAAU;AAAA,EACtB,SAASA,SAAS,EAAE,WAAW,GAAG,UAAU,GAAG,KAAM;AACpD,WACC,4EACC;AAAA,kDAAC,aAAAC,MAAO,aAAP,EAAmB,QAAS,4CAAC,yCAAe,GAC1C,8BAAI,gCAAiC,GACxC;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACA;AAAA,UACA,eAAY,YAAAC,SAAM,cAAY,aAAa,SAAU;AAAA,UACnD,GAAG;AAAA;AAAA,MACL;AAAA,OACF;AAAA,EAEF;AACD;",
|
|
6
6
|
"names": ["Details", "_Field", "clsx"]
|
|
7
7
|
}
|
|
@@ -38,40 +38,13 @@ var import_field = require("@base-ui/react/field");
|
|
|
38
38
|
var import_element = require("@wordpress/element");
|
|
39
39
|
|
|
40
40
|
// packages/ui/src/utils/css/field.module.css
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
font-family: var(--wpds-font-family-body);
|
|
48
|
-
font-size: var(--wpds-font-size-xs);
|
|
49
|
-
line-height: var(--wp-ui-field-label-line-height);
|
|
50
|
-
font-weight: var(--wpds-font-weight-medium);
|
|
51
|
-
text-transform: uppercase;
|
|
52
|
-
color: var(--wpds-color-fg-content-neutral);
|
|
53
|
-
|
|
54
|
-
&.field-module__is-plain__F8QhR {
|
|
55
|
-
font-size: var(--wpds-font-size-md);
|
|
56
|
-
text-transform: none;
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.field-module__description__CKN1B {
|
|
61
|
-
margin: 0;
|
|
62
|
-
font-family: var(--wpds-font-family-body);
|
|
63
|
-
font-size: var(--wpds-font-size-sm);
|
|
64
|
-
line-height: var(--wpds-font-line-height-xs);
|
|
65
|
-
color: var(--wpds-color-fg-content-neutral-weak);
|
|
66
|
-
}
|
|
41
|
+
if (typeof document !== "undefined" && !document.head.querySelector("style[data-wp-hash='04c8f253c6']")) {
|
|
42
|
+
const style = document.createElement("style");
|
|
43
|
+
style.setAttribute("data-wp-hash", "04c8f253c6");
|
|
44
|
+
style.appendChild(document.createTextNode("@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}"));
|
|
45
|
+
document.head.appendChild(style);
|
|
67
46
|
}
|
|
68
|
-
|
|
69
|
-
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
70
|
-
var field_default = {
|
|
71
|
-
"label": "field-module__label__LVrYU",
|
|
72
|
-
"is-plain": "field-module__is-plain__F8QhR",
|
|
73
|
-
"description": "field-module__description__CKN1B"
|
|
74
|
-
};
|
|
47
|
+
var field_default = { "label": "_2d5ad850b2f90964__label", "is-plain": "_17c4214649230bea__is-plain", "description": "_08a3750500e0233f__description" };
|
|
75
48
|
|
|
76
49
|
// packages/ui/src/form/primitives/field/label.tsx
|
|
77
50
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form/primitives/field/label.tsx", "../../../../src/utils/css/field.module.css"],
|
|
4
|
-
"sourcesContent": ["import clsx from 'clsx';\nimport { Field as _Field } from '@base-ui/react/field';\nimport { forwardRef } from '@wordpress/element';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport type { FieldLabelProps } from './types';\n\nexport const Label = forwardRef< HTMLLabelElement, FieldLabelProps >(\n\tfunction Label( { className, variant, ...restProps }, ref ) {\n\t\treturn (\n\t\t\t<_Field.Label\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx(\n\t\t\t\t\tfieldStyles.label,\n\t\t\t\t\tvariant && fieldStyles[ `is-${ variant }` ],\n\t\t\t\t\tclassName\n\t\t\t\t) }\n\t\t\t\t{ ...restProps }\n\t\t\t/>\n\t\t);\n\t}\n);\n", "
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAgC;AAChC,qBAA2B;;;ACF3B,
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport { Field as _Field } from '@base-ui/react/field';\nimport { forwardRef } from '@wordpress/element';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport type { FieldLabelProps } from './types';\n\nexport const Label = forwardRef< HTMLLabelElement, FieldLabelProps >(\n\tfunction Label( { className, variant, ...restProps }, ref ) {\n\t\treturn (\n\t\t\t<_Field.Label\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx(\n\t\t\t\t\tfieldStyles.label,\n\t\t\t\t\tvariant && fieldStyles[ `is-${ variant }` ],\n\t\t\t\t\tclassName\n\t\t\t\t) }\n\t\t\t\t{ ...restProps }\n\t\t\t/>\n\t\t);\n\t}\n);\n", "if (typeof document !== 'undefined' && !document.head.querySelector(\"style[data-wp-hash='04c8f253c6']\")) {\n\tconst style = document.createElement(\"style\");\n\tstyle.setAttribute(\"data-wp-hash\", \"04c8f253c6\");\n\tstyle.appendChild(document.createTextNode(\"@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}\"));\n\tdocument.head.appendChild(style);\n}\nexport default {\"label\":\"_2d5ad850b2f90964__label\",\"is-plain\":\"_17c4214649230bea__is-plain\",\"description\":\"_08a3750500e0233f__description\"};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAgC;AAChC,qBAA2B;;;ACF3B,IAAI,OAAO,aAAa,eAAe,CAAC,SAAS,KAAK,cAAc,kCAAkC,GAAG;AACxG,QAAM,QAAQ,SAAS,cAAc,OAAO;AAC5C,QAAM,aAAa,gBAAgB,YAAY;AAC/C,QAAM,YAAY,SAAS,eAAe,qtBAAqtB,CAAC;AAChwB,WAAS,KAAK,YAAY,KAAK;AAChC;AACA,IAAO,gBAAQ,EAAC,SAAQ,4BAA2B,YAAW,+BAA8B,eAAc,iCAAgC;;;ADGvI;AAHI,IAAM,YAAQ;AAAA,EACpB,SAASA,OAAO,EAAE,WAAW,SAAS,GAAG,UAAU,GAAG,KAAM;AAC3D,WACC;AAAA,MAAC,aAAAC,MAAO;AAAA,MAAP;AAAA,QACA;AAAA,QACA,eAAY,YAAAC;AAAA,UACX,cAAY;AAAA,UACZ,WAAW,cAAa,MAAO,OAAQ,EAAG;AAAA,UAC1C;AAAA,QACD;AAAA,QACE,GAAG;AAAA;AAAA,IACN;AAAA,EAEF;AACD;",
|
|
6
6
|
"names": ["Label", "_Field", "clsx"]
|
|
7
7
|
}
|
|
@@ -38,24 +38,13 @@ var import_field = require("@base-ui/react/field");
|
|
|
38
38
|
var import_element = require("@wordpress/element");
|
|
39
39
|
|
|
40
40
|
// packages/ui/src/utils/css/resets.module.css
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
*,
|
|
48
|
-
*::before,
|
|
49
|
-
*::after {
|
|
50
|
-
box-sizing: inherit;
|
|
51
|
-
}
|
|
52
|
-
}
|
|
41
|
+
if (typeof document !== "undefined" && !document.head.querySelector("style[data-wp-hash='671ebfc62d']")) {
|
|
42
|
+
const style = document.createElement("style");
|
|
43
|
+
style.setAttribute("data-wp-hash", "671ebfc62d");
|
|
44
|
+
style.appendChild(document.createTextNode("@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}"));
|
|
45
|
+
document.head.appendChild(style);
|
|
53
46
|
}
|
|
54
|
-
|
|
55
|
-
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
56
|
-
var resets_default = {
|
|
57
|
-
"box-sizing": "resets-module__box-sizing__M2zT5"
|
|
58
|
-
};
|
|
47
|
+
var resets_default = { "box-sizing": "_336cd3e4e743482f__box-sizing" };
|
|
59
48
|
|
|
60
49
|
// packages/ui/src/form/primitives/field/root.tsx
|
|
61
50
|
var import_stack = require("../../../stack/index.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form/primitives/field/root.tsx", "../../../../src/utils/css/resets.module.css"],
|
|
4
|
-
"sourcesContent": ["import clsx from 'clsx';\nimport { Field as _Field } from '@base-ui/react/field';\nimport { forwardRef } from '@wordpress/element';\nimport resetStyles from '../../../utils/css/resets.module.css';\nimport type { FieldRootProps } from './types';\nimport { Stack } from '../../../stack';\n\nconst DEFAULT_RENDER = ( props: React.ComponentProps< typeof Stack > ) => (\n\t<Stack { ...props } direction=\"column\" gap=\"xs\" />\n);\n\n/**\n * A low-level component that associates an accessible label and description\n * with a single form control element.\n *\n * To label a group of multiple form control elements, use the `Fieldset` component instead.\n *\n * Simply wrapping a control with this component does not guarantee\n * accessible labeling. See examples for how to associate the label in different cases.\n */\nexport const Root = forwardRef< HTMLDivElement, FieldRootProps >( function Root(\n\t{ className, render = DEFAULT_RENDER, ...restProps },\n\tref\n) {\n\treturn (\n\t\t<_Field.Root\n\t\t\tref={ ref }\n\t\t\tclassName={ clsx( resetStyles[ 'box-sizing' ], className ) }\n\t\t\trender={ render }\n\t\t\t{ ...restProps }\n\t\t/>\n\t);\n} );\n", "
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAgC;AAChC,qBAA2B;;;ACF3B,
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport { Field as _Field } from '@base-ui/react/field';\nimport { forwardRef } from '@wordpress/element';\nimport resetStyles from '../../../utils/css/resets.module.css';\nimport type { FieldRootProps } from './types';\nimport { Stack } from '../../../stack';\n\nconst DEFAULT_RENDER = ( props: React.ComponentProps< typeof Stack > ) => (\n\t<Stack { ...props } direction=\"column\" gap=\"xs\" />\n);\n\n/**\n * A low-level component that associates an accessible label and description\n * with a single form control element.\n *\n * To label a group of multiple form control elements, use the `Fieldset` component instead.\n *\n * Simply wrapping a control with this component does not guarantee\n * accessible labeling. See examples for how to associate the label in different cases.\n */\nexport const Root = forwardRef< HTMLDivElement, FieldRootProps >( function Root(\n\t{ className, render = DEFAULT_RENDER, ...restProps },\n\tref\n) {\n\treturn (\n\t\t<_Field.Root\n\t\t\tref={ ref }\n\t\t\tclassName={ clsx( resetStyles[ 'box-sizing' ], className ) }\n\t\t\trender={ render }\n\t\t\t{ ...restProps }\n\t\t/>\n\t);\n} );\n", "if (typeof document !== 'undefined' && !document.head.querySelector(\"style[data-wp-hash='671ebfc62d']\")) {\n\tconst style = document.createElement(\"style\");\n\tstyle.setAttribute(\"data-wp-hash\", \"671ebfc62d\");\n\tstyle.appendChild(document.createTextNode(\"@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}\"));\n\tdocument.head.appendChild(style);\n}\nexport default {\"box-sizing\":\"_336cd3e4e743482f__box-sizing\"};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAgC;AAChC,qBAA2B;;;ACF3B,IAAI,OAAO,aAAa,eAAe,CAAC,SAAS,KAAK,cAAc,kCAAkC,GAAG;AACxG,QAAM,QAAQ,SAAS,cAAc,OAAO;AAC5C,QAAM,aAAa,gBAAgB,YAAY;AAC/C,QAAM,YAAY,SAAS,eAAe,kMAAkM,CAAC;AAC7O,WAAS,KAAK,YAAY,KAAK;AAChC;AACA,IAAO,iBAAQ,EAAC,cAAa,gCAA+B;;;ADD5D,mBAAsB;AAGrB;AADD,IAAM,iBAAiB,CAAE,UACxB,4CAAC,sBAAQ,GAAG,OAAQ,WAAU,UAAS,KAAI,MAAK;AAY1C,IAAM,WAAO,2BAA8C,SAASA,MAC1E,EAAE,WAAW,SAAS,gBAAgB,GAAG,UAAU,GACnD,KACC;AACD,SACC;AAAA,IAAC,aAAAC,MAAO;AAAA,IAAP;AAAA,MACA;AAAA,MACA,eAAY,YAAAC,SAAM,eAAa,YAAa,GAAG,SAAU;AAAA,MACzD;AAAA,MACE,GAAG;AAAA;AAAA,EACN;AAEF,CAAE;",
|
|
6
6
|
"names": ["Root", "_Field", "clsx"]
|
|
7
7
|
}
|
|
@@ -38,40 +38,13 @@ var import_react = require("@base-ui/react");
|
|
|
38
38
|
var import_element = require("@wordpress/element");
|
|
39
39
|
|
|
40
40
|
// packages/ui/src/utils/css/field.module.css
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
font-family: var(--wpds-font-family-body);
|
|
48
|
-
font-size: var(--wpds-font-size-xs);
|
|
49
|
-
line-height: var(--wp-ui-field-label-line-height);
|
|
50
|
-
font-weight: var(--wpds-font-weight-medium);
|
|
51
|
-
text-transform: uppercase;
|
|
52
|
-
color: var(--wpds-color-fg-content-neutral);
|
|
53
|
-
|
|
54
|
-
&.field-module__is-plain__F8QhR {
|
|
55
|
-
font-size: var(--wpds-font-size-md);
|
|
56
|
-
text-transform: none;
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.field-module__description__CKN1B {
|
|
61
|
-
margin: 0;
|
|
62
|
-
font-family: var(--wpds-font-family-body);
|
|
63
|
-
font-size: var(--wpds-font-size-sm);
|
|
64
|
-
line-height: var(--wpds-font-line-height-xs);
|
|
65
|
-
color: var(--wpds-color-fg-content-neutral-weak);
|
|
66
|
-
}
|
|
41
|
+
if (typeof document !== "undefined" && !document.head.querySelector("style[data-wp-hash='04c8f253c6']")) {
|
|
42
|
+
const style = document.createElement("style");
|
|
43
|
+
style.setAttribute("data-wp-hash", "04c8f253c6");
|
|
44
|
+
style.appendChild(document.createTextNode("@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}"));
|
|
45
|
+
document.head.appendChild(style);
|
|
67
46
|
}
|
|
68
|
-
|
|
69
|
-
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
70
|
-
var field_default = {
|
|
71
|
-
"label": "field-module__label__LVrYU",
|
|
72
|
-
"is-plain": "field-module__is-plain__F8QhR",
|
|
73
|
-
"description": "field-module__description__CKN1B"
|
|
74
|
-
};
|
|
47
|
+
var field_default = { "label": "_2d5ad850b2f90964__label", "is-plain": "_17c4214649230bea__is-plain", "description": "_08a3750500e0233f__description" };
|
|
75
48
|
|
|
76
49
|
// packages/ui/src/form/primitives/fieldset/description.tsx
|
|
77
50
|
var import_context = require("./context.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form/primitives/fieldset/description.tsx", "../../../../src/utils/css/field.module.css"],
|
|
4
|
-
"sourcesContent": ["import clsx from 'clsx';\nimport { mergeProps, useRender } from '@base-ui/react';\nimport { forwardRef, useEffect, useId } from '@wordpress/element';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport { useFieldsetContext } from './context';\nimport type { FieldsetDescriptionProps } from './types';\n\nexport const FieldsetDescription = forwardRef<\n\tHTMLParagraphElement,\n\tFieldsetDescriptionProps\n>( function FieldsetDescription(\n\t{ className, id: idProp, render, ...restProps },\n\tref\n) {\n\tconst generatedId = useId();\n\tconst id = idProp ?? generatedId;\n\tconst { registerDescriptionId, unregisterDescriptionId } =\n\t\tuseFieldsetContext();\n\n\tuseEffect( () => {\n\t\tregisterDescriptionId( id );\n\t\treturn unregisterDescriptionId;\n\t}, [ registerDescriptionId, unregisterDescriptionId, id ] );\n\n\tconst element = useRender( {\n\t\tdefaultTagName: 'p',\n\t\trender,\n\t\tref,\n\t\tprops: mergeProps< 'p' >(\n\t\t\t{ className: clsx( fieldStyles.description, className ), id },\n\t\t\trestProps\n\t\t),\n\t} );\n\n\treturn element;\n} );\n", "
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAsC;AACtC,qBAA6C;;;ACF7C,
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport { mergeProps, useRender } from '@base-ui/react';\nimport { forwardRef, useEffect, useId } from '@wordpress/element';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport { useFieldsetContext } from './context';\nimport type { FieldsetDescriptionProps } from './types';\n\nexport const FieldsetDescription = forwardRef<\n\tHTMLParagraphElement,\n\tFieldsetDescriptionProps\n>( function FieldsetDescription(\n\t{ className, id: idProp, render, ...restProps },\n\tref\n) {\n\tconst generatedId = useId();\n\tconst id = idProp ?? generatedId;\n\tconst { registerDescriptionId, unregisterDescriptionId } =\n\t\tuseFieldsetContext();\n\n\tuseEffect( () => {\n\t\tregisterDescriptionId( id );\n\t\treturn unregisterDescriptionId;\n\t}, [ registerDescriptionId, unregisterDescriptionId, id ] );\n\n\tconst element = useRender( {\n\t\tdefaultTagName: 'p',\n\t\trender,\n\t\tref,\n\t\tprops: mergeProps< 'p' >(\n\t\t\t{ className: clsx( fieldStyles.description, className ), id },\n\t\t\trestProps\n\t\t),\n\t} );\n\n\treturn element;\n} );\n", "if (typeof document !== 'undefined' && !document.head.querySelector(\"style[data-wp-hash='04c8f253c6']\")) {\n\tconst style = document.createElement(\"style\");\n\tstyle.setAttribute(\"data-wp-hash\", \"04c8f253c6\");\n\tstyle.appendChild(document.createTextNode(\"@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}\"));\n\tdocument.head.appendChild(style);\n}\nexport default {\"label\":\"_2d5ad850b2f90964__label\",\"is-plain\":\"_17c4214649230bea__is-plain\",\"description\":\"_08a3750500e0233f__description\"};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,mBAAsC;AACtC,qBAA6C;;;ACF7C,IAAI,OAAO,aAAa,eAAe,CAAC,SAAS,KAAK,cAAc,kCAAkC,GAAG;AACxG,QAAM,QAAQ,SAAS,cAAc,OAAO;AAC5C,QAAM,aAAa,gBAAgB,YAAY;AAC/C,QAAM,YAAY,SAAS,eAAe,qtBAAqtB,CAAC;AAChwB,WAAS,KAAK,YAAY,KAAK;AAChC;AACA,IAAO,gBAAQ,EAAC,SAAQ,4BAA2B,YAAW,+BAA8B,eAAc,iCAAgC;;;ADF1I,qBAAmC;AAG5B,IAAM,0BAAsB,2BAGhC,SAASA,qBACX,EAAE,WAAW,IAAI,QAAQ,QAAQ,GAAG,UAAU,GAC9C,KACC;AACD,QAAM,kBAAc,sBAAM;AAC1B,QAAM,KAAK,UAAU;AACrB,QAAM,EAAE,uBAAuB,wBAAwB,QACtD,mCAAmB;AAEpB,gCAAW,MAAM;AAChB,0BAAuB,EAAG;AAC1B,WAAO;AAAA,EACR,GAAG,CAAE,uBAAuB,yBAAyB,EAAG,CAAE;AAE1D,QAAM,cAAU,wBAAW;AAAA,IAC1B,gBAAgB;AAAA,IAChB;AAAA,IACA;AAAA,IACA,WAAO;AAAA,MACN,EAAE,eAAW,YAAAC,SAAM,cAAY,aAAa,SAAU,GAAG,GAAG;AAAA,MAC5D;AAAA,IACD;AAAA,EACD,CAAE;AAEF,SAAO;AACR,CAAE;",
|
|
6
6
|
"names": ["FieldsetDescription", "clsx"]
|
|
7
7
|
}
|
|
@@ -38,40 +38,13 @@ var import_element = require("@wordpress/element");
|
|
|
38
38
|
var import_i18n = require("@wordpress/i18n");
|
|
39
39
|
|
|
40
40
|
// packages/ui/src/utils/css/field.module.css
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
font-family: var(--wpds-font-family-body);
|
|
48
|
-
font-size: var(--wpds-font-size-xs);
|
|
49
|
-
line-height: var(--wp-ui-field-label-line-height);
|
|
50
|
-
font-weight: var(--wpds-font-weight-medium);
|
|
51
|
-
text-transform: uppercase;
|
|
52
|
-
color: var(--wpds-color-fg-content-neutral);
|
|
53
|
-
|
|
54
|
-
&.field-module__is-plain__F8QhR {
|
|
55
|
-
font-size: var(--wpds-font-size-md);
|
|
56
|
-
text-transform: none;
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.field-module__description__CKN1B {
|
|
61
|
-
margin: 0;
|
|
62
|
-
font-family: var(--wpds-font-family-body);
|
|
63
|
-
font-size: var(--wpds-font-size-sm);
|
|
64
|
-
line-height: var(--wpds-font-line-height-xs);
|
|
65
|
-
color: var(--wpds-color-fg-content-neutral-weak);
|
|
66
|
-
}
|
|
41
|
+
if (typeof document !== "undefined" && !document.head.querySelector("style[data-wp-hash='04c8f253c6']")) {
|
|
42
|
+
const style = document.createElement("style");
|
|
43
|
+
style.setAttribute("data-wp-hash", "04c8f253c6");
|
|
44
|
+
style.appendChild(document.createTextNode("@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}"));
|
|
45
|
+
document.head.appendChild(style);
|
|
67
46
|
}
|
|
68
|
-
|
|
69
|
-
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
70
|
-
var field_default = {
|
|
71
|
-
"label": "field-module__label__LVrYU",
|
|
72
|
-
"is-plain": "field-module__is-plain__F8QhR",
|
|
73
|
-
"description": "field-module__description__CKN1B"
|
|
74
|
-
};
|
|
47
|
+
var field_default = { "label": "_2d5ad850b2f90964__label", "is-plain": "_17c4214649230bea__is-plain", "description": "_08a3750500e0233f__description" };
|
|
75
48
|
|
|
76
49
|
// packages/ui/src/form/primitives/fieldset/details.tsx
|
|
77
50
|
var import_context = require("./context.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form/primitives/fieldset/details.tsx", "../../../../src/utils/css/field.module.css"],
|
|
4
|
-
"sourcesContent": ["import clsx from 'clsx';\nimport { forwardRef, useEffect, useId } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport { useFieldsetContext } from './context';\nimport { VisuallyHidden } from '../../../visually-hidden';\nimport type { FieldsetDetailsProps } from './types';\n\n/**\n * A component for showing additional information about the fieldset,\n * styled similarly to a normal `Fieldset.Description`.\n * Unlike a normal description, it can include links and other semantic elements.\n *\n * Although this content is not associated with the fieldset using direct semantics,\n * it is made discoverable to screen reader users via a visually hidden description,\n * alerting them to the presence of additional information below.\n *\n * If the content only includes plain text, use `Fieldset.Description` instead,\n * so the readout is not unnecessarily verbose for screen reader users.\n */\nexport const FieldsetDetails = forwardRef<\n\tHTMLDivElement,\n\tFieldsetDetailsProps\n>( function FieldsetDetails( { className, ...restProps }, ref ) {\n\tconst id = useId();\n\tconst { registerDescriptionId, unregisterDescriptionId } =\n\t\tuseFieldsetContext();\n\n\tuseEffect( () => {\n\t\tregisterDescriptionId( id );\n\t\treturn unregisterDescriptionId;\n\t}, [ registerDescriptionId, unregisterDescriptionId, id ] );\n\n\treturn (\n\t\t<>\n\t\t\t<VisuallyHidden id={ id }>\n\t\t\t\t{ __( 'More details follow.' ) }\n\t\t\t</VisuallyHidden>\n\t\t\t<div\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx( fieldStyles.description, className ) }\n\t\t\t\t{ ...restProps }\n\t\t\t/>\n\t\t</>\n\t);\n} );\n", "
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,qBAA6C;AAC7C,kBAAmB;;;ACFnB,
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport { forwardRef, useEffect, useId } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport { useFieldsetContext } from './context';\nimport { VisuallyHidden } from '../../../visually-hidden';\nimport type { FieldsetDetailsProps } from './types';\n\n/**\n * A component for showing additional information about the fieldset,\n * styled similarly to a normal `Fieldset.Description`.\n * Unlike a normal description, it can include links and other semantic elements.\n *\n * Although this content is not associated with the fieldset using direct semantics,\n * it is made discoverable to screen reader users via a visually hidden description,\n * alerting them to the presence of additional information below.\n *\n * If the content only includes plain text, use `Fieldset.Description` instead,\n * so the readout is not unnecessarily verbose for screen reader users.\n */\nexport const FieldsetDetails = forwardRef<\n\tHTMLDivElement,\n\tFieldsetDetailsProps\n>( function FieldsetDetails( { className, ...restProps }, ref ) {\n\tconst id = useId();\n\tconst { registerDescriptionId, unregisterDescriptionId } =\n\t\tuseFieldsetContext();\n\n\tuseEffect( () => {\n\t\tregisterDescriptionId( id );\n\t\treturn unregisterDescriptionId;\n\t}, [ registerDescriptionId, unregisterDescriptionId, id ] );\n\n\treturn (\n\t\t<>\n\t\t\t<VisuallyHidden id={ id }>\n\t\t\t\t{ __( 'More details follow.' ) }\n\t\t\t</VisuallyHidden>\n\t\t\t<div\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx( fieldStyles.description, className ) }\n\t\t\t\t{ ...restProps }\n\t\t\t/>\n\t\t</>\n\t);\n} );\n", "if (typeof document !== 'undefined' && !document.head.querySelector(\"style[data-wp-hash='04c8f253c6']\")) {\n\tconst style = document.createElement(\"style\");\n\tstyle.setAttribute(\"data-wp-hash\", \"04c8f253c6\");\n\tstyle.appendChild(document.createTextNode(\"@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}\"));\n\tdocument.head.appendChild(style);\n}\nexport default {\"label\":\"_2d5ad850b2f90964__label\",\"is-plain\":\"_17c4214649230bea__is-plain\",\"description\":\"_08a3750500e0233f__description\"};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,qBAA6C;AAC7C,kBAAmB;;;ACFnB,IAAI,OAAO,aAAa,eAAe,CAAC,SAAS,KAAK,cAAc,kCAAkC,GAAG;AACxG,QAAM,QAAQ,SAAS,cAAc,OAAO;AAC5C,QAAM,aAAa,gBAAgB,YAAY;AAC/C,QAAM,YAAY,SAAS,eAAe,qtBAAqtB,CAAC;AAChwB,WAAS,KAAK,YAAY,KAAK;AAChC;AACA,IAAO,gBAAQ,EAAC,SAAQ,4BAA2B,YAAW,+BAA8B,eAAc,iCAAgC;;;ADF1I,qBAAmC;AACnC,6BAA+B;AA6B7B;AAdK,IAAM,sBAAkB,2BAG5B,SAASA,iBAAiB,EAAE,WAAW,GAAG,UAAU,GAAG,KAAM;AAC/D,QAAM,SAAK,sBAAM;AACjB,QAAM,EAAE,uBAAuB,wBAAwB,QACtD,mCAAmB;AAEpB,gCAAW,MAAM;AAChB,0BAAuB,EAAG;AAC1B,WAAO;AAAA,EACR,GAAG,CAAE,uBAAuB,yBAAyB,EAAG,CAAE;AAE1D,SACC,4EACC;AAAA,gDAAC,yCAAe,IACb,8BAAI,sBAAuB,GAC9B;AAAA,IACA;AAAA,MAAC;AAAA;AAAA,QACA;AAAA,QACA,eAAY,YAAAC,SAAM,cAAY,aAAa,SAAU;AAAA,QACnD,GAAG;AAAA;AAAA,IACN;AAAA,KACD;AAEF,CAAE;",
|
|
6
6
|
"names": ["FieldsetDetails", "clsx"]
|
|
7
7
|
}
|
|
@@ -38,40 +38,13 @@ var import_fieldset = require("@base-ui/react/fieldset");
|
|
|
38
38
|
var import_element = require("@wordpress/element");
|
|
39
39
|
|
|
40
40
|
// packages/ui/src/utils/css/field.module.css
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
font-family: var(--wpds-font-family-body);
|
|
48
|
-
font-size: var(--wpds-font-size-xs);
|
|
49
|
-
line-height: var(--wp-ui-field-label-line-height);
|
|
50
|
-
font-weight: var(--wpds-font-weight-medium);
|
|
51
|
-
text-transform: uppercase;
|
|
52
|
-
color: var(--wpds-color-fg-content-neutral);
|
|
53
|
-
|
|
54
|
-
&.field-module__is-plain__F8QhR {
|
|
55
|
-
font-size: var(--wpds-font-size-md);
|
|
56
|
-
text-transform: none;
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.field-module__description__CKN1B {
|
|
61
|
-
margin: 0;
|
|
62
|
-
font-family: var(--wpds-font-family-body);
|
|
63
|
-
font-size: var(--wpds-font-size-sm);
|
|
64
|
-
line-height: var(--wpds-font-line-height-xs);
|
|
65
|
-
color: var(--wpds-color-fg-content-neutral-weak);
|
|
66
|
-
}
|
|
41
|
+
if (typeof document !== "undefined" && !document.head.querySelector("style[data-wp-hash='04c8f253c6']")) {
|
|
42
|
+
const style = document.createElement("style");
|
|
43
|
+
style.setAttribute("data-wp-hash", "04c8f253c6");
|
|
44
|
+
style.appendChild(document.createTextNode("@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}"));
|
|
45
|
+
document.head.appendChild(style);
|
|
67
46
|
}
|
|
68
|
-
|
|
69
|
-
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
70
|
-
var field_default = {
|
|
71
|
-
"label": "field-module__label__LVrYU",
|
|
72
|
-
"is-plain": "field-module__is-plain__F8QhR",
|
|
73
|
-
"description": "field-module__description__CKN1B"
|
|
74
|
-
};
|
|
47
|
+
var field_default = { "label": "_2d5ad850b2f90964__label", "is-plain": "_17c4214649230bea__is-plain", "description": "_08a3750500e0233f__description" };
|
|
75
48
|
|
|
76
49
|
// packages/ui/src/form/primitives/fieldset/legend.tsx
|
|
77
50
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form/primitives/fieldset/legend.tsx", "../../../../src/utils/css/field.module.css"],
|
|
4
|
-
"sourcesContent": ["import clsx from 'clsx';\nimport { Fieldset as _Fieldset } from '@base-ui/react/fieldset';\nimport { forwardRef } from '@wordpress/element';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport type { FieldsetLegendProps } from './types';\n\nexport const FieldsetLegend = forwardRef< HTMLDivElement, FieldsetLegendProps >(\n\tfunction FieldsetLegend( { className, ...restProps }, ref ) {\n\t\treturn (\n\t\t\t<_Fieldset.Legend\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx( fieldStyles.label, className ) }\n\t\t\t\t{ ...restProps }\n\t\t\t/>\n\t\t);\n\t}\n);\n", "
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,sBAAsC;AACtC,qBAA2B;;;ACF3B,
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport { Fieldset as _Fieldset } from '@base-ui/react/fieldset';\nimport { forwardRef } from '@wordpress/element';\nimport fieldStyles from '../../../utils/css/field.module.css';\nimport type { FieldsetLegendProps } from './types';\n\nexport const FieldsetLegend = forwardRef< HTMLDivElement, FieldsetLegendProps >(\n\tfunction FieldsetLegend( { className, ...restProps }, ref ) {\n\t\treturn (\n\t\t\t<_Fieldset.Legend\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx( fieldStyles.label, className ) }\n\t\t\t\t{ ...restProps }\n\t\t\t/>\n\t\t);\n\t}\n);\n", "if (typeof document !== 'undefined' && !document.head.querySelector(\"style[data-wp-hash='04c8f253c6']\")) {\n\tconst style = document.createElement(\"style\");\n\tstyle.setAttribute(\"data-wp-hash\", \"04c8f253c6\");\n\tstyle.appendChild(document.createTextNode(\"@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-utilities{._2d5ad850b2f90964__label{--wp-ui-field-label-line-height:var(--wpds-font-line-height-xs);color:var(--wpds-color-fg-content-neutral);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-xs);font-weight:var(--wpds-font-weight-medium);line-height:var(--wp-ui-field-label-line-height);text-transform:uppercase;&._17c4214649230bea__is-plain{font-size:var(--wpds-font-size-md);text-transform:none}}._08a3750500e0233f__description{color:var(--wpds-color-fg-content-neutral-weak);font-family:var(--wpds-font-family-body);font-size:var(--wpds-font-size-sm);line-height:var(--wpds-font-line-height-xs);margin:0}}\"));\n\tdocument.head.appendChild(style);\n}\nexport default {\"label\":\"_2d5ad850b2f90964__label\",\"is-plain\":\"_17c4214649230bea__is-plain\",\"description\":\"_08a3750500e0233f__description\"};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,sBAAsC;AACtC,qBAA2B;;;ACF3B,IAAI,OAAO,aAAa,eAAe,CAAC,SAAS,KAAK,cAAc,kCAAkC,GAAG;AACxG,QAAM,QAAQ,SAAS,cAAc,OAAO;AAC5C,QAAM,aAAa,gBAAgB,YAAY;AAC/C,QAAM,YAAY,SAAS,eAAe,qtBAAqtB,CAAC;AAChwB,WAAS,KAAK,YAAY,KAAK;AAChC;AACA,IAAO,gBAAQ,EAAC,SAAQ,4BAA2B,YAAW,+BAA8B,eAAc,iCAAgC;;;ADGvI;AAHI,IAAM,qBAAiB;AAAA,EAC7B,SAASA,gBAAgB,EAAE,WAAW,GAAG,UAAU,GAAG,KAAM;AAC3D,WACC;AAAA,MAAC,gBAAAC,SAAU;AAAA,MAAV;AAAA,QACA;AAAA,QACA,eAAY,YAAAC,SAAM,cAAY,OAAO,SAAU;AAAA,QAC7C,GAAG;AAAA;AAAA,IACN;AAAA,EAEF;AACD;",
|
|
6
6
|
"names": ["FieldsetLegend", "_Fieldset", "clsx"]
|
|
7
7
|
}
|
|
@@ -38,23 +38,13 @@ var import_fieldset = require("@base-ui/react/fieldset");
|
|
|
38
38
|
var import_element = require("@wordpress/element");
|
|
39
39
|
|
|
40
40
|
// packages/ui/src/form/primitives/fieldset/style.module.css
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
flex-direction: column;
|
|
47
|
-
gap: var(--wpds-dimension-gap-2xs);
|
|
48
|
-
border: 0;
|
|
49
|
-
margin: 0;
|
|
50
|
-
padding: 0;
|
|
51
|
-
}
|
|
41
|
+
if (typeof document !== "undefined" && !document.head.querySelector("style[data-wp-hash='645ae380ba']")) {
|
|
42
|
+
const style = document.createElement("style");
|
|
43
|
+
style.setAttribute("data-wp-hash", "645ae380ba");
|
|
44
|
+
style.appendChild(document.createTextNode("@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-components{.a946d12d3d763c87__root{border:0;display:flex;flex-direction:column;gap:var(--wpds-dimension-gap-2xs);margin:0;padding:0}}"));
|
|
45
|
+
document.head.appendChild(style);
|
|
52
46
|
}
|
|
53
|
-
|
|
54
|
-
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
55
|
-
var style_default = {
|
|
56
|
-
"root": "style-module__root__qUbRL"
|
|
57
|
-
};
|
|
47
|
+
var style_default = { "root": "a946d12d3d763c87__root" };
|
|
58
48
|
|
|
59
49
|
// packages/ui/src/form/primitives/fieldset/root.tsx
|
|
60
50
|
var import_context = require("./context.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form/primitives/fieldset/root.tsx", "../../../../src/form/primitives/fieldset/style.module.css"],
|
|
4
|
-
"sourcesContent": ["import clsx from 'clsx';\nimport { Fieldset as _Fieldset } from '@base-ui/react/fieldset';\nimport { forwardRef, useState, useMemo } from '@wordpress/element';\nimport styles from './style.module.css';\nimport { FieldsetContext } from './context';\nimport type { FieldsetRootProps } from './types';\n\n/**\n * A low-level component that associates an accessible legend and description with\n * a group of multiple form control elements.\n *\n * To label a single form control element, use the `Field` component instead.\n */\nexport const FieldsetRoot = forwardRef<\n\tHTMLFieldSetElement,\n\tFieldsetRootProps\n>( function FieldsetRoot( { className, children, ...restProps }, ref ) {\n\tconst [ descriptionId, setDescriptionId ] = useState< string >();\n\n\tconst contextValue = useMemo(\n\t\t() => ( {\n\t\t\tregisterDescriptionId: ( id: string ) => setDescriptionId( id ),\n\t\t\tunregisterDescriptionId: () => setDescriptionId( undefined ),\n\t\t} ),\n\t\t[]\n\t);\n\n\treturn (\n\t\t<FieldsetContext.Provider value={ contextValue }>\n\t\t\t<_Fieldset.Root\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx( styles.root, className ) }\n\t\t\t\t// Certain screen readers may not read a fieldset's description\n\t\t\t\t// https://w3c.github.io/using-aria/#label-support\n\t\t\t\taria-describedby={ descriptionId }\n\t\t\t\t{ ...restProps }\n\t\t\t>\n\t\t\t\t{ children }\n\t\t\t</_Fieldset.Root>\n\t\t</FieldsetContext.Provider>\n\t);\n} );\n", "
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,sBAAsC;AACtC,qBAA8C;;;ACF9C,
|
|
4
|
+
"sourcesContent": ["import clsx from 'clsx';\nimport { Fieldset as _Fieldset } from '@base-ui/react/fieldset';\nimport { forwardRef, useState, useMemo } from '@wordpress/element';\nimport styles from './style.module.css';\nimport { FieldsetContext } from './context';\nimport type { FieldsetRootProps } from './types';\n\n/**\n * A low-level component that associates an accessible legend and description with\n * a group of multiple form control elements.\n *\n * To label a single form control element, use the `Field` component instead.\n */\nexport const FieldsetRoot = forwardRef<\n\tHTMLFieldSetElement,\n\tFieldsetRootProps\n>( function FieldsetRoot( { className, children, ...restProps }, ref ) {\n\tconst [ descriptionId, setDescriptionId ] = useState< string >();\n\n\tconst contextValue = useMemo(\n\t\t() => ( {\n\t\t\tregisterDescriptionId: ( id: string ) => setDescriptionId( id ),\n\t\t\tunregisterDescriptionId: () => setDescriptionId( undefined ),\n\t\t} ),\n\t\t[]\n\t);\n\n\treturn (\n\t\t<FieldsetContext.Provider value={ contextValue }>\n\t\t\t<_Fieldset.Root\n\t\t\t\tref={ ref }\n\t\t\t\tclassName={ clsx( styles.root, className ) }\n\t\t\t\t// Certain screen readers may not read a fieldset's description\n\t\t\t\t// https://w3c.github.io/using-aria/#label-support\n\t\t\t\taria-describedby={ descriptionId }\n\t\t\t\t{ ...restProps }\n\t\t\t>\n\t\t\t\t{ children }\n\t\t\t</_Fieldset.Root>\n\t\t</FieldsetContext.Provider>\n\t);\n} );\n", "if (typeof document !== 'undefined' && !document.head.querySelector(\"style[data-wp-hash='645ae380ba']\")) {\n\tconst style = document.createElement(\"style\");\n\tstyle.setAttribute(\"data-wp-hash\", \"645ae380ba\");\n\tstyle.appendChild(document.createTextNode(\"@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-components{.a946d12d3d763c87__root{border:0;display:flex;flex-direction:column;gap:var(--wpds-dimension-gap-2xs);margin:0;padding:0}}\"));\n\tdocument.head.appendChild(style);\n}\nexport default {\"root\":\"a946d12d3d763c87__root\"};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAiB;AACjB,sBAAsC;AACtC,qBAA8C;;;ACF9C,IAAI,OAAO,aAAa,eAAe,CAAC,SAAS,KAAK,cAAc,kCAAkC,GAAG;AACxG,QAAM,QAAQ,SAAS,cAAc,OAAO;AAC5C,QAAM,aAAa,gBAAgB,YAAY;AAC/C,QAAM,YAAY,SAAS,eAAe,kOAAkO,CAAC;AAC7Q,WAAS,KAAK,YAAY,KAAK;AAChC;AACA,IAAO,gBAAQ,EAAC,QAAO,yBAAwB;;;ADF/C,qBAAgC;AAyB7B;AAhBI,IAAM,mBAAe,2BAGzB,SAASA,cAAc,EAAE,WAAW,UAAU,GAAG,UAAU,GAAG,KAAM;AACtE,QAAM,CAAE,eAAe,gBAAiB,QAAI,yBAAmB;AAE/D,QAAM,mBAAe;AAAA,IACpB,OAAQ;AAAA,MACP,uBAAuB,CAAE,OAAgB,iBAAkB,EAAG;AAAA,MAC9D,yBAAyB,MAAM,iBAAkB,MAAU;AAAA,IAC5D;AAAA,IACA,CAAC;AAAA,EACF;AAEA,SACC,4CAAC,+BAAgB,UAAhB,EAAyB,OAAQ,cACjC;AAAA,IAAC,gBAAAC,SAAU;AAAA,IAAV;AAAA,MACA;AAAA,MACA,eAAY,YAAAC,SAAM,cAAO,MAAM,SAAU;AAAA,MAGzC,oBAAmB;AAAA,MACjB,GAAG;AAAA,MAEH;AAAA;AAAA,EACH,GACD;AAEF,CAAE;",
|
|
6
6
|
"names": ["FieldsetRoot", "_Fieldset", "clsx"]
|
|
7
7
|
}
|
|
@@ -32,16 +32,22 @@ var primitives_exports = {};
|
|
|
32
32
|
__export(primitives_exports, {
|
|
33
33
|
Field: () => Field,
|
|
34
34
|
Fieldset: () => Fieldset,
|
|
35
|
-
|
|
35
|
+
Input: () => import_input.Input,
|
|
36
|
+
InputLayout: () => import_input_layout.InputLayout,
|
|
37
|
+
Select: () => Select
|
|
36
38
|
});
|
|
37
39
|
module.exports = __toCommonJS(primitives_exports);
|
|
38
40
|
var Field = __toESM(require("./field/index.cjs"));
|
|
39
41
|
var Fieldset = __toESM(require("./fieldset/index.cjs"));
|
|
42
|
+
var import_input = require("./input/index.cjs");
|
|
40
43
|
var import_input_layout = require("./input-layout/index.cjs");
|
|
44
|
+
var Select = __toESM(require("./select/index.cjs"));
|
|
41
45
|
// Annotate the CommonJS export names for ESM import in node:
|
|
42
46
|
0 && (module.exports = {
|
|
43
47
|
Field,
|
|
44
48
|
Fieldset,
|
|
45
|
-
|
|
49
|
+
Input,
|
|
50
|
+
InputLayout,
|
|
51
|
+
Select
|
|
46
52
|
});
|
|
47
53
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/form/primitives/index.ts"],
|
|
4
|
-
"sourcesContent": ["export * as Field from './field';\nexport * as Fieldset from './fieldset';\nexport { InputLayout } from './input-layout';\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,YAAuB;AACvB,eAA0B;AAC1B,0BAA4B;",
|
|
4
|
+
"sourcesContent": ["export * as Field from './field';\nexport * as Fieldset from './fieldset';\nexport { Input } from './input';\nexport { InputLayout } from './input-layout';\nexport * as Select from './select';\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,YAAuB;AACvB,eAA0B;AAC1B,mBAAsB;AACtB,0BAA4B;AAC5B,aAAwB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// packages/ui/src/form/primitives/input/index.ts
|
|
21
|
+
var input_exports = {};
|
|
22
|
+
__export(input_exports, {
|
|
23
|
+
Input: () => import_input.Input
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(input_exports);
|
|
26
|
+
var import_input = require("./input.cjs");
|
|
27
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
28
|
+
0 && (module.exports = {
|
|
29
|
+
Input
|
|
30
|
+
});
|
|
31
|
+
//# sourceMappingURL=index.cjs.map
|