@viasat/beam-web-components 2.0.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/Accordion/Accordion.d.ts +56 -0
- package/Accordion/Accordion.js +12 -0
- package/Accordion/AccordionGroup.context.d.ts +10 -0
- package/Accordion/AccordionGroup.context.js +8 -0
- package/Accordion/AccordionGroup.d.ts +33 -0
- package/Accordion/AccordionGroup.js +79 -0
- package/Accordion/index.d.ts +3 -0
- package/Accordion/index.js +6 -0
- package/Alert/Alert.d.ts +64 -0
- package/Alert/Alert.js +300 -0
- package/Alert/index.d.ts +2 -0
- package/Alert/index.js +4 -0
- package/Avatar/Avatar.d.ts +60 -0
- package/Avatar/Avatar.js +12 -0
- package/Avatar/AvatarGroup.context.d.ts +11 -0
- package/Avatar/AvatarGroup.context.js +8 -0
- package/Avatar/AvatarGroup.d.ts +43 -0
- package/Avatar/AvatarGroup.js +181 -0
- package/Avatar/index.d.ts +3 -0
- package/Avatar/index.js +6 -0
- package/Badge/Badge.d.ts +40 -0
- package/Badge/Badge.js +125 -0
- package/Badge/index.d.ts +2 -0
- package/Badge/index.js +4 -0
- package/BadgeDot/BadgeDot.d.ts +38 -0
- package/BadgeDot/BadgeDot.js +59 -0
- package/BadgeDot/index.d.ts +2 -0
- package/BadgeDot/index.js +4 -0
- package/Box/Box.d.ts +99 -0
- package/Box/Box.js +115 -0
- package/Box/index.d.ts +2 -0
- package/Box/index.js +4 -0
- package/Breadcrumbs/Breadcrumbs.context.d.ts +10 -0
- package/Breadcrumbs/Breadcrumbs.context.js +8 -0
- package/Breadcrumbs/Breadcrumbs.d.ts +38 -0
- package/Breadcrumbs/Breadcrumbs.js +115 -0
- package/Breadcrumbs/BreadcrumbsItem.d.ts +39 -0
- package/Breadcrumbs/BreadcrumbsItem.js +13 -0
- package/Breadcrumbs/index.d.ts +3 -0
- package/Breadcrumbs/index.js +6 -0
- package/Button/Button.d.ts +73 -0
- package/Button/Button.js +125 -0
- package/Button/index.d.ts +2 -0
- package/Button/index.js +4 -0
- package/CloseButton/CloseButton.d.ts +25 -0
- package/CloseButton/CloseButton.js +60 -0
- package/CloseButton/index.d.ts +2 -0
- package/CloseButton/index.js +4 -0
- package/Divider/Divider.d.ts +56 -0
- package/Divider/Divider.js +111 -0
- package/Divider/index.d.ts +2 -0
- package/Divider/index.js +4 -0
- package/EmptyState/EmptyState.d.ts +36 -0
- package/EmptyState/EmptyState.js +56 -0
- package/EmptyState/index.d.ts +2 -0
- package/EmptyState/index.js +4 -0
- package/HelperText/HelperText.d.ts +45 -0
- package/HelperText/HelperText.js +11 -0
- package/HelperText/index.d.ts +2 -0
- package/HelperText/index.js +4 -0
- package/Icon/Icon.d.ts +35 -0
- package/Icon/Icon.js +62 -0
- package/Icon/index.d.ts +2 -0
- package/Icon/index.js +4 -0
- package/InputChoiceGroup/InputChoiceGroup.context.d.ts +13 -0
- package/InputChoiceGroup/InputChoiceGroup.context.js +8 -0
- package/InputChoiceGroup/InputChoiceGroup.d.ts +87 -0
- package/InputChoiceGroup/InputChoiceGroup.js +205 -0
- package/InputChoiceGroup/index.d.ts +2 -0
- package/InputChoiceGroup/index.js +4 -0
- package/Link/Link.d.ts +48 -0
- package/Link/Link.js +77 -0
- package/Link/index.d.ts +2 -0
- package/Link/index.js +4 -0
- package/List/List.context.d.ts +15 -0
- package/List/List.context.js +8 -0
- package/List/List.d.ts +43 -0
- package/List/List.js +101 -0
- package/List/ListItem.d.ts +23 -0
- package/List/ListItem.js +90 -0
- package/List/index.d.ts +3 -0
- package/List/index.js +6 -0
- package/ProgressBar/ProgressBar.d.ts +52 -0
- package/ProgressBar/ProgressBar.js +128 -0
- package/ProgressBar/index.d.ts +2 -0
- package/ProgressBar/index.js +4 -0
- package/README.md +360 -0
- package/SegmentedControl/SegmentedControl.context.d.ts +16 -0
- package/SegmentedControl/SegmentedControl.context.js +8 -0
- package/SegmentedControl/SegmentedControl.d.ts +41 -0
- package/SegmentedControl/SegmentedControl.js +103 -0
- package/SegmentedControl/SegmentedControlItem.d.ts +54 -0
- package/SegmentedControl/SegmentedControlItem.js +284 -0
- package/SegmentedControl/SegmentedControlList.d.ts +23 -0
- package/SegmentedControl/SegmentedControlList.js +61 -0
- package/SegmentedControl/SegmentedControlPanel.d.ts +21 -0
- package/SegmentedControl/SegmentedControlPanel.js +43 -0
- package/SegmentedControl/index.d.ts +5 -0
- package/SegmentedControl/index.js +10 -0
- package/Spinner/Spinner.d.ts +50 -0
- package/Spinner/Spinner.js +186 -0
- package/Spinner/index.d.ts +2 -0
- package/Spinner/index.js +4 -0
- package/StateLayer/StateLayer.d.ts +17 -0
- package/StateLayer/StateLayer.js +6 -0
- package/StateLayer/index.d.ts +2 -0
- package/StateLayer/index.js +5 -0
- package/Text/Text.d.ts +85 -0
- package/Text/Text.js +103 -0
- package/Text/index.d.ts +2 -0
- package/Text/index.js +4 -0
- package/Tooltip/Tooltip.d.ts +139 -0
- package/Tooltip/Tooltip.js +1827 -0
- package/Tooltip/index.d.ts +2 -0
- package/Tooltip/index.js +5 -0
- package/chunks/Accordion.DYD3XcAx.js +161 -0
- package/chunks/Avatar.C2rfzUGP.js +174 -0
- package/chunks/BreadcrumbsItem.4ZR6wbMz.js +121 -0
- package/chunks/CSSLookup.BdqZ5Li9.js +106 -0
- package/chunks/HelperText.CcVVOtA3.js +108 -0
- package/chunks/Upload.B9YEyp7b.js +12 -0
- package/chunks/WarningOutlined.DPfQnPPj.js +12 -0
- package/chunks/classNames.Cq_tbDRp.js +94 -0
- package/chunks/constants.jOWREYQE.js +30 -0
- package/chunks/delegate.baxDQosr.js +63 -0
- package/chunks/dom.C98AFbJh.js +22 -0
- package/chunks/fileUpload.module.kN6o64aL.js +4 -0
- package/chunks/globals.Bz4SVF2g.js +4 -0
- package/chunks/helpers.AwJwaZvv.js +53 -0
- package/chunks/list.module.CZRPBLzy.js +4 -0
- package/chunks/register-custom-element.DHGKOhmA.js +17 -0
- package/chunks/segmentedControl.module.BPXEWodj.js +4 -0
- package/chunks/tokens.CTW8Tt94.js +9 -0
- package/custom-elements.json +11341 -0
- package/local/Accordion/Accordion.js +12 -0
- package/local/Accordion/AccordionGroup.context.js +8 -0
- package/local/Accordion/AccordionGroup.js +78 -0
- package/local/Accordion/index.js +6 -0
- package/local/Alert/Alert.js +301 -0
- package/local/Alert/index.js +4 -0
- package/local/Avatar/Avatar.js +11 -0
- package/local/Avatar/AvatarGroup.context.js +8 -0
- package/local/Avatar/AvatarGroup.js +180 -0
- package/local/Avatar/index.js +6 -0
- package/local/Badge/Badge.js +123 -0
- package/local/Badge/index.js +4 -0
- package/local/BadgeDot/BadgeDot.js +57 -0
- package/local/BadgeDot/index.js +4 -0
- package/local/Box/Box.js +113 -0
- package/local/Box/index.js +4 -0
- package/local/Breadcrumbs/Breadcrumbs.context.js +8 -0
- package/local/Breadcrumbs/Breadcrumbs.js +113 -0
- package/local/Breadcrumbs/BreadcrumbsItem.js +13 -0
- package/local/Breadcrumbs/index.js +6 -0
- package/local/Button/Button.js +154 -0
- package/local/Button/index.js +4 -0
- package/local/CloseButton/CloseButton.js +58 -0
- package/local/CloseButton/index.js +4 -0
- package/local/Divider/Divider.js +111 -0
- package/local/Divider/index.js +4 -0
- package/local/EmptyState/EmptyState.js +54 -0
- package/local/EmptyState/index.js +4 -0
- package/local/HelperText/HelperText.js +9 -0
- package/local/HelperText/index.js +4 -0
- package/local/Icon/Icon.js +60 -0
- package/local/Icon/index.js +4 -0
- package/local/InputChoiceGroup/InputChoiceGroup.context.js +8 -0
- package/local/InputChoiceGroup/InputChoiceGroup.js +205 -0
- package/local/InputChoiceGroup/index.js +4 -0
- package/local/Link/Link.js +75 -0
- package/local/Link/index.js +4 -0
- package/local/List/List.context.js +8 -0
- package/local/List/List.js +101 -0
- package/local/List/ListItem.js +90 -0
- package/local/List/index.js +6 -0
- package/local/ProgressBar/ProgressBar.js +126 -0
- package/local/ProgressBar/index.js +4 -0
- package/local/SegmentedControl/SegmentedControl.context.js +8 -0
- package/local/SegmentedControl/SegmentedControl.js +103 -0
- package/local/SegmentedControl/SegmentedControlItem.js +284 -0
- package/local/SegmentedControl/SegmentedControlList.js +59 -0
- package/local/SegmentedControl/SegmentedControlPanel.js +41 -0
- package/local/SegmentedControl/index.js +10 -0
- package/local/Spinner/Spinner.js +185 -0
- package/local/Spinner/index.js +4 -0
- package/local/StateLayer/StateLayer.js +6 -0
- package/local/StateLayer/index.js +5 -0
- package/local/Text/Text.js +121 -0
- package/local/Text/index.js +4 -0
- package/local/Tooltip/Tooltip.js +1826 -0
- package/local/Tooltip/index.js +5 -0
- package/local/chunks/Accordion.PGU7OILE.js +161 -0
- package/local/chunks/Avatar.CvTOzaRT.js +172 -0
- package/local/chunks/BreadcrumbsItem.GM6sBp_o.js +121 -0
- package/local/chunks/CSSLookup.BdqZ5Li9.js +106 -0
- package/local/chunks/Upload.B9YEyp7b.js +12 -0
- package/local/chunks/WarningOutlined.DPfQnPPj.js +12 -0
- package/local/chunks/base.D76d76ww.js +9 -0
- package/local/chunks/classNames.C6fNrXWF.js +106 -0
- package/local/chunks/constants.jOWREYQE.js +30 -0
- package/local/chunks/consume.Ce9k1-wN.js +47 -0
- package/local/chunks/context-request-event.Bl9Vpkzl.js +13 -0
- package/local/chunks/create-context.DS1OG3vJ.js +11 -0
- package/local/chunks/delegate.baxDQosr.js +63 -0
- package/local/chunks/directive.kLG6oqUu.js +27 -0
- package/local/chunks/dom.C98AFbJh.js +22 -0
- package/local/chunks/fileUpload.module.kN6o64aL.js +4 -0
- package/local/chunks/globals.Bz4SVF2g.js +4 -0
- package/local/chunks/helpers.BWcXAteC.js +53 -0
- package/local/chunks/index.Bz1Jq4c2.js +106 -0
- package/local/chunks/list.module.CZRPBLzy.js +4 -0
- package/local/chunks/lit-element.CJtt9wj5.js +557 -0
- package/local/chunks/provide.i2FlUkOu.js +110 -0
- package/local/chunks/query-assigned-elements.Drkgpk9q.js +19 -0
- package/local/chunks/query-assigned-nodes.Dgvsf6BR.js +19 -0
- package/local/chunks/query.lbpOn5CD.js +20 -0
- package/local/chunks/ref.B7e1Hu4F.js +107 -0
- package/local/chunks/register-custom-element.vod7zfGv.js +51 -0
- package/local/chunks/segmentedControl.module.BPXEWodj.js +4 -0
- package/local/chunks/state.CqiuSzAl.js +12 -0
- package/local/chunks/tokens.CTW8Tt94.js +9 -0
- package/local/chunks/unsafe-html.BzhXEygn.js +27 -0
- package/local/chunks/unsafe-svg.HSGf1NCU.js +14 -0
- package/local/wip/Checkbox/Checkbox.js +102 -0
- package/local/wip/Checkbox/CheckboxGroup/CheckboxGroup.js +27 -0
- package/local/wip/Checkbox/index.js +6 -0
- package/local/wip/FileUpload/FileUpload.Button.js +75 -0
- package/local/wip/FileUpload/FileUpload.Dropzone.js +149 -0
- package/local/wip/FileUpload/FileUpload.List.Item.js +201 -0
- package/local/wip/FileUpload/FileUpload.List.js +105 -0
- package/local/wip/FileUpload/FileUpload.js +452 -0
- package/local/wip/FileUpload/FileUploadContext.js +8 -0
- package/local/wip/FileUpload/FileUploadListContext.js +8 -0
- package/local/wip/FileUpload/index.js +13 -0
- package/local/wip/Form/Form.context.js +20 -0
- package/local/wip/Form/Form.decorator.js +145 -0
- package/local/wip/Form/Form.js +288 -0
- package/local/wip/Form/Form.utils.js +8 -0
- package/local/wip/Form/index.js +7 -0
- package/local/wip/Label/Label.js +86 -0
- package/local/wip/Label/index.js +4 -0
- package/local/wip/NativeSelect/NativeSelect.js +162 -0
- package/local/wip/NativeSelect/index.js +4 -0
- package/local/wip/RadioButton/RadioButton.js +123 -0
- package/local/wip/RadioButton/RadioButtonGroup/RadioButtonGroup.js +96 -0
- package/local/wip/RadioButton/index.js +6 -0
- package/local/wip/Switch/Switch.js +153 -0
- package/local/wip/Switch/SwitchGroup/SwitchGroup.js +15 -0
- package/local/wip/Switch/index.js +6 -0
- package/local/wip/TextArea/TextArea.js +192 -0
- package/local/wip/TextArea/index.js +4 -0
- package/local/wip/TextField/TextField.js +169 -0
- package/local/wip/TextField/index.js +4 -0
- package/package.json +78 -0
- package/vscode.css-custom-data.json +6 -0
- package/vscode.html-custom-data.json +2704 -0
- package/wip/Checkbox/Checkbox.d.ts +55 -0
- package/wip/Checkbox/Checkbox.js +104 -0
- package/wip/Checkbox/CheckboxGroup/CheckboxGroup.d.ts +11 -0
- package/wip/Checkbox/CheckboxGroup/CheckboxGroup.js +27 -0
- package/wip/Checkbox/index.d.ts +3 -0
- package/wip/Checkbox/index.js +6 -0
- package/wip/FileUpload/FileUpload.Button.d.ts +36 -0
- package/wip/FileUpload/FileUpload.Button.js +77 -0
- package/wip/FileUpload/FileUpload.Dropzone.d.ts +55 -0
- package/wip/FileUpload/FileUpload.Dropzone.js +150 -0
- package/wip/FileUpload/FileUpload.List.Item.d.ts +62 -0
- package/wip/FileUpload/FileUpload.List.Item.js +203 -0
- package/wip/FileUpload/FileUpload.List.d.ts +46 -0
- package/wip/FileUpload/FileUpload.List.js +106 -0
- package/wip/FileUpload/FileUpload.d.ts +101 -0
- package/wip/FileUpload/FileUpload.js +451 -0
- package/wip/FileUpload/FileUploadContext.d.ts +5 -0
- package/wip/FileUpload/FileUploadContext.js +8 -0
- package/wip/FileUpload/FileUploadListContext.d.ts +5 -0
- package/wip/FileUpload/FileUploadListContext.js +8 -0
- package/wip/FileUpload/index.d.ts +6 -0
- package/wip/FileUpload/index.js +13 -0
- package/wip/Form/Form.context.d.ts +19 -0
- package/wip/Form/Form.context.js +20 -0
- package/wip/Form/Form.d.ts +50 -0
- package/wip/Form/Form.decorator.d.ts +47 -0
- package/wip/Form/Form.decorator.js +144 -0
- package/wip/Form/Form.js +288 -0
- package/wip/Form/Form.utils.d.ts +2 -0
- package/wip/Form/Form.utils.js +8 -0
- package/wip/Form/index.d.ts +3 -0
- package/wip/Form/index.js +7 -0
- package/wip/Label/Label.d.ts +43 -0
- package/wip/Label/Label.js +87 -0
- package/wip/Label/index.d.ts +2 -0
- package/wip/Label/index.js +4 -0
- package/wip/NativeSelect/NativeSelect.d.ts +69 -0
- package/wip/NativeSelect/NativeSelect.js +163 -0
- package/wip/NativeSelect/index.d.ts +2 -0
- package/wip/NativeSelect/index.js +4 -0
- package/wip/RadioButton/RadioButton.d.ts +56 -0
- package/wip/RadioButton/RadioButton.js +125 -0
- package/wip/RadioButton/RadioButtonGroup/RadioButtonGroup.d.ts +23 -0
- package/wip/RadioButton/RadioButtonGroup/RadioButtonGroup.js +96 -0
- package/wip/RadioButton/index.d.ts +3 -0
- package/wip/RadioButton/index.js +6 -0
- package/wip/Switch/Switch.d.ts +62 -0
- package/wip/Switch/Switch.js +155 -0
- package/wip/Switch/SwitchGroup/SwitchGroup.d.ts +15 -0
- package/wip/Switch/SwitchGroup/SwitchGroup.js +15 -0
- package/wip/Switch/index.d.ts +3 -0
- package/wip/Switch/index.js +6 -0
- package/wip/TextArea/TextArea.d.ts +89 -0
- package/wip/TextArea/TextArea.js +193 -0
- package/wip/TextArea/index.d.ts +2 -0
- package/wip/TextArea/index.js +4 -0
- package/wip/TextField/TextField.d.ts +70 -0
- package/wip/TextField/TextField.js +169 -0
- package/wip/TextField/index.d.ts +2 -0
- package/wip/TextField/index.js +4 -0
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import { r as R, x as _, E as D } from "../../chunks/lit-element.CJtt9wj5.js";
|
|
2
|
+
import { n as m, c as L } from "../../chunks/register-custom-element.vod7zfGv.js";
|
|
3
|
+
import { o as k } from "../../chunks/query-assigned-elements.Drkgpk9q.js";
|
|
4
|
+
import { e as W, n as N } from "../../chunks/ref.B7e1Hu4F.js";
|
|
5
|
+
import { p as d, a as I, c as C, g as V } from "../../chunks/classNames.C6fNrXWF.js";
|
|
6
|
+
import { t as G } from "../../chunks/constants.jOWREYQE.js";
|
|
7
|
+
import { r as B } from "../../chunks/delegate.baxDQosr.js";
|
|
8
|
+
import { FormField as H } from "../Form/Form.decorator.js";
|
|
9
|
+
const j = /* @__PURE__ */ new WeakMap();
|
|
10
|
+
async function Z(e) {
|
|
11
|
+
const r = e.offsetHeight, t = e.clientHeight, s = r - t;
|
|
12
|
+
e.style.overflow = "hidden", e.scrollHeight === t && (e.style.height = "0");
|
|
13
|
+
const c = e.scrollHeight;
|
|
14
|
+
e.style.height = `${c + s}px`;
|
|
15
|
+
}
|
|
16
|
+
const A = (e, r) => {
|
|
17
|
+
const t = j.get(e);
|
|
18
|
+
if (j.set(e, r), !r) {
|
|
19
|
+
t && (e.style.height = "unset", e.style.overflow = "visible");
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
Z(e);
|
|
23
|
+
}, O = ':root,:host,.bm-light,.bm-dark .bm-inverse,[data-bm-theme~=bm-light]{--bm-comp-input-color-bg: var(--bm-sem-color-surface-01, #ffffff);--bm-comp-input-color-bg-disabled: var( --bm-sem-color-surface-highlight, rgba(159, 175, 188, .16) );--bm-comp-input-color-border: var(--bm-sem-color-border-strong, #8697a5);--bm-comp-input-color-border-error: var( --bm-sem-color-border-negative-strong, #cc2429 );--bm-comp-input-color-border-disabled: rgba(134, 151, 165, .4);--bm-comp-input-color-text: var(--bm-sem-color-text-primary, #141d24);--bm-comp-input-color-text-placeholder: var( --bm-sem-color-text-secondary, #576775 );--bm-comp-input-color-text-disabled: var( --bm-sem-color-text-disabled, rgba(87, 103, 117, .4) );--bm-comp-input-color-icon-disabled: var( --bm-sem-color-text-disabled, rgba(87, 103, 117, .4) );--bm-comp-input-color-icon: var(--bm-sem-color-icon-secondary, #576775);--bm-comp-input-color-icon-error: var( --bm-sem-color-icon-negative-strong, #cc2429 );--bm-comp-input-color-divider: var(--bm-sem-color-border-02, #d1dae0);--bm-comp-input-color-choice-checkbox-selected-bg: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-checkbox-selected-icon: var( --bm-sem-color-icon-primary-inverse, #ffffff );--bm-comp-input-color-choice-checkbox-selected-bg-error: var( --bm-sem-color-surface-negative-strong, #cc2429 );--bm-comp-input-color-choice-checkbox-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-switch-selected-bg: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-switch-selected-icon: var( --bm-sem-color-icon-primary-inverse, #ffffff );--bm-comp-input-color-choice-switch-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-radio-selected-bg: var( --bm-sem-color-surface-01, #ffffff );--bm-comp-input-color-choice-radio-selected-border: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-radio-selected-inner-circle: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-radio-selected-bg-error: var( --bm-sem-color-surface-01, #ffffff );--bm-comp-input-color-choice-radio-selected-border-error: var( --bm-sem-color-surface-negative-strong, #cc2429 );--bm-comp-input-color-choice-radio-selected-inner-circle-error: var( --bm-sem-color-surface-negative-strong, #cc2429 );--bm-comp-input-typo-default: var( --bm-sem-typo-compact-body-md, 400 1rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-character-count: var( --bm-sem-typo-body-sm, 400 .875rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-label-choice: var( --bm-sem-typo-body-md, 400 1rem/1.5rem "Source Sans Pro" );--bm-comp-input-space-field-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-field-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-field-gap: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-inside: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-choice-nudge: var( --bm-primitive-dimension-12, .125rem );--bm-comp-input-size-field-md-height: var(--bm-sem-size-height-md, 2.5rem);--bm-comp-input-size-field-width: var(--bm-primitive-dimension-1800, 18rem);--bm-comp-input-size-field-icon: var(--bm-sem-size-icon-md, 1.25rem);--bm-comp-input-size-field-text-area-height: var( --bm-primitive-dimension-475, 4.75rem );--bm-comp-input-size-choice-checkbox: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio-inside: var( --bm-primitive-dimension-50, .5rem );--bm-comp-input-size-choice-switch-height: var( --bm-sem-size-icon-md, 1.25rem );--bm-comp-input-size-choice-switch-width: var( --bm-primitive-dimension-250, 2.5rem );--bm-comp-input-size-choice-switch-knob: var( --bm-primitive-dimension-87, .875rem );--bm-comp-input-radius-field: var(--bm-sem-radius-input-md, .25rem);--bm-comp-input-radius-choice-checkbox: var( --bm-sem-radius-input-sm, .125rem );--bm-comp-input-radius-choice-radio: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-radius-choice-switch: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-border-width-field-default: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-border-width-field-error: var( --bm-sem-border-width-lg, .125rem );--bm-comp-input-border-width-choice: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-shadow-field: var( --bm-sem-shadow-none, 0 0 0 0 rgb(0, 0, 0, 0) )}:host,.bm-dark,.bm-light .bm-inverse,[data-bm-theme~=bm-dark]{--bm-comp-input-color-bg: var(--bm-sem-color-surface-01, #202e39);--bm-comp-input-color-bg-disabled: var( --bm-sem-color-surface-highlight, rgba(134, 151, 165, .16) );--bm-comp-input-color-border: var(--bm-sem-color-border-strong, #9fafbc);--bm-comp-input-color-border-error: var( --bm-sem-color-border-negative-strong, #f67378 );--bm-comp-input-color-border-disabled: rgba(159, 175, 188, .4);--bm-comp-input-color-text: var(--bm-sem-color-text-primary, #ffffff);--bm-comp-input-color-text-placeholder: var( --bm-sem-color-text-secondary, #c3cdd5 );--bm-comp-input-color-text-disabled: var( --bm-sem-color-text-disabled, rgba(195, 205, 213, .4) );--bm-comp-input-color-icon-disabled: var( --bm-sem-color-text-disabled, rgba(195, 205, 213, .4) );--bm-comp-input-color-icon: var(--bm-sem-color-icon-secondary, #c3cdd5);--bm-comp-input-color-icon-error: var( --bm-sem-color-icon-negative-strong, #f67378 );--bm-comp-input-color-divider: var(--bm-sem-color-border-02, #465967);--bm-comp-input-color-choice-checkbox-selected-bg: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-checkbox-selected-icon: var( --bm-sem-color-icon-primary-inverse, #141d24 );--bm-comp-input-color-choice-checkbox-selected-bg-error: var( --bm-sem-color-surface-negative-strong, #f67378 );--bm-comp-input-color-choice-checkbox-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-switch-selected-bg: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-switch-selected-icon: var( --bm-sem-color-icon-primary-inverse, #141d24 );--bm-comp-input-color-choice-switch-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-radio-selected-bg: var( --bm-sem-color-surface-01, #202e39 );--bm-comp-input-color-choice-radio-selected-border: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-radio-selected-inner-circle: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-radio-selected-bg-error: var( --bm-sem-color-surface-01, #202e39 );--bm-comp-input-color-choice-radio-selected-border-error: var( --bm-sem-color-surface-negative-strong, #f67378 );--bm-comp-input-color-choice-radio-selected-inner-circle-error: var( --bm-sem-color-surface-negative-strong, #f67378 );--bm-comp-input-typo-default: var( --bm-sem-typo-compact-body-md, 400 1rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-character-count: var( --bm-sem-typo-body-sm, 400 .875rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-label-choice: var( --bm-sem-typo-body-md, 400 1rem/1.5rem "Source Sans Pro" );--bm-comp-input-space-field-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-field-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-field-gap: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-inside: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-choice-nudge: var( --bm-primitive-dimension-12, .125rem );--bm-comp-input-size-field-md-height: var(--bm-sem-size-height-md, 2.5rem);--bm-comp-input-size-field-width: var(--bm-primitive-dimension-1800, 18rem);--bm-comp-input-size-field-icon: var(--bm-sem-size-icon-md, 1.25rem);--bm-comp-input-size-field-text-area-height: var( --bm-primitive-dimension-475, 4.75rem );--bm-comp-input-size-choice-checkbox: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio-inside: var( --bm-primitive-dimension-50, .5rem );--bm-comp-input-size-choice-switch-height: var( --bm-sem-size-icon-md, 1.25rem );--bm-comp-input-size-choice-switch-width: var( --bm-primitive-dimension-250, 2.5rem );--bm-comp-input-size-choice-switch-knob: var( --bm-primitive-dimension-87, .875rem );--bm-comp-input-radius-field: var(--bm-sem-radius-input-md, .25rem);--bm-comp-input-radius-choice-checkbox: var( --bm-sem-radius-input-sm, .125rem );--bm-comp-input-radius-choice-radio: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-radius-choice-switch: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-border-width-field-default: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-border-width-field-error: var( --bm-sem-border-width-lg, .125rem );--bm-comp-input-border-width-choice: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-shadow-field: var( --bm-sem-shadow-none, 0 0 0 0 rgb(0, 0, 0, 0) )}.bm-text-area{--bm-label-cursor: pointer;max-width:var(--bm-comp-input-size-field-width);--bm-label-space-bottom: var(--bm-comp-label-space-bottom);--bm-helper-text-space-top: var(--bm-comp-helper-text-space-top)}.bm-text-area--disabled{--bm-label-cursor: not-allowed;--bm-label-pointer-events: auto;--bm-text-field-cursor: not-allowed;--bm-text-field-input-cursor: not-allowed}.bm-text-area--error .bm-text-area__header .bm-text-area__counter{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-area--error .bm-text-area__field .bm-text-area__input{color:var(--bm-comp-input-color-text);border-color:var(--bm-comp-input-color-border-error);background-color:var(--bm-comp-input-color-bg);outline-offset:calc(0px - var(--bm-comp-input-border-width-field-error));outline:var(--bm-comp-input-border-width-field-error) solid var(--bm-comp-input-color-border-error)}.bm-text-area--error .bm-text-area__field .bm-text-area__input::placeholder{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-area--read-only .bm-text-area__header .bm-text-area__counter{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-area--read-only .bm-text-area__field .bm-text-area__input{color:var(--bm-comp-input-color-text);border-color:var(--bm-comp-input-color-border-disabled);background-color:var(--bm-comp-input-color-bg-disabled)}.bm-text-area--read-only .bm-text-area__field .bm-text-area__input::placeholder{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-area--disabled .bm-text-area__header .bm-text-area__counter{color:var(--bm-comp-input-color-text-disabled)}.bm-text-area--disabled .bm-text-area__field .bm-text-area__input{color:var(--bm-comp-input-color-text-disabled);border-color:var(--bm-comp-input-color-border-disabled);background-color:var(--bm-comp-input-color-bg-disabled)}.bm-text-area--disabled .bm-text-area__field .bm-text-area__input::placeholder{color:var(--bm-comp-input-color-text-disabled)}.bm-text-area--fluid{max-width:100%}@-moz-document url-prefix(){.bm-text-area__field:after{display:none}}.bm-text-area--hide-resize .bm-text-area__field:after{display:none}.bm-text-area--hide-resize .bm-text-area__field .bm-text-area__input{resize:none}.bm-text-area--cols-width{max-width:fit-content}.bm-text-area--cols-width .bm-text-area__field .bm-text-area__input{width:auto}.bm-text-area__header{display:flex;gap:var(--bm-sem-space-50)}.bm-text-area__header .bm-text-area__counter{margin-block-end:auto;margin-inline-start:auto;font:var(--bm-comp-input-typo-character-count);color:var(--bm-comp-input-color-text-placeholder);padding-block-end:var(--bm-comp-label-space-bottom)}.bm-text-area__field{position:relative;cursor:var(--bm-text-field-cursor, default)}.bm-text-area__field:dir(rtl){--bm-resize-icon-flip: -1}.bm-text-area__field:after{content:"";position:absolute;pointer-events:none;width:var(--bm-sem-space-125);height:var(--bm-sem-space-125);-webkit-mask-image:url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgdmlld0JveD0iMCAwIDIwIDIwIiBmaWxsPSJub25lIj4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAwXzY0NjIyXzQ4MzUzKSI+CjxwYXRoIGQ9Ik0xOC4zMzMzIDE4LjMzMzNIMTYuNjY2N1YxNi42NjY3SDE4LjMzMzNWMTguMzMzM1pNMTguMzMzMyAxNUgxNi42NjY3VjEzLjMzMzNIMTguMzMzM1YxNVpNMTUgMTguMzMzM0gxMy4zMzMzVjE2LjY2NjdIMTVWMTguMzMzM1pNMTUgMTVIMTMuMzMzM1YxMy4zMzMzSDE1VjE1Wk0xMS42NjY3IDE4LjMzMzNIMTBWMTYuNjY2N0gxMS42NjY3VjE4LjMzMzNaTTE4LjMzMzMgMTEuNjY2N0gxNi42NjY3VjEwSDE4LjMzMzNWMTEuNjY2N3oiIGZpbGw9IiM0NjU5NjciLz4KPC9nPgo8ZGVmcz4KPGNsaXBQYXRoIGlkPSJjbGlwMF82NDYyMl80ODM1MyI+CjxyZWN0IHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgZmlsbD0id2hpdGUiLz4KPC9jbGlwUGF0aD4KPC9kZWZzPgo8L3N2Zz4=);-webkit-mask-size:cover;-webkit-mask-position:center;-webkit-mask-repeat:no-repeat;mask-image:url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgdmlld0JveD0iMCAwIDIwIDIwIiBmaWxsPSJub25lIj4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAwXzY0NjIyXzQ4MzUzKSI+CjxwYXRoIGQ9Ik0xOC4zMzMzIDE4LjMzMzNIMTYuNjY2N1YxNi42NjY3SDE4LjMzMzNWMTguMzMzM1pNMTguMzMzMyAxNUgxNi42NjY3VjEzLjMzMzNIMTguMzMzM1YxNVpNMTUgMTguMzMzM0gxMy4zMzMzVjE2LjY2NjdIMTVWMTguMzMzM1pNMTUgMTVIMTMuMzMzM1YxMy4zMzMzSDE1VjE1Wk0xMS42NjY3IDE4LjMzMzNIMTBWMTYuNjY2N0gxMS42NjY3VjE4LjMzMzNaTTE4LjMzMzMgMTEuNjY2N0gxNi42NjY3VjEwSDE4LjMzMzNWMTEuNjY2N3oiIGZpbGw9IiM0NjU5NjciLz4KPC9nPgo8ZGVmcz4KPGNsaXBQYXRoIGlkPSJjbGlwMF82NDYyMl80ODM1MyI+CjxyZWN0IHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgZmlsbD0id2hpdGUiLz4KPC9jbGlwUGF0aD4KPC9kZWZzPgo8L3N2Zz4=);mask-size:cover;mask-position:center;mask-repeat:no-repeat;inset-block-end:var(--bm-sem-space-12);inset-inline-end:var(--bm-sem-space-12);transform:scaleX(var(--bm-resize-icon-flip, 1));background-color:var(--bm-sem-color-icon-secondary)}.bm-text-area__field .bm-text-area__input{width:100%;display:block;resize:vertical;box-sizing:border-box;border-style:solid;border-color:var(--bm-comp-input-color-border);border-radius:var(--bm-comp-input-radius-field);border-width:var(--bm-comp-input-border-width-field-default);color:var(--bm-comp-input-color-text);font:var(--bm-comp-input-typo-default);cursor:var(--bm-text-field-input-cursor, text);box-shadow:var(--bm-comp-input-shadow-field);background-color:var(--bm-comp-input-color-bg);min-height:var(--bm-comp-input-size-field-text-area-height);padding:var(--bm-comp-input-space-field-y) var(--bm-comp-input-space-field-x);transform:translate3d(var(--bm-sem-space-0),var(--bm-sem-space-0),var(--bm-sem-space-0))}.bm-text-area__field .bm-text-area__input::-webkit-resizer{display:none}.bm-text-area__field .bm-text-area__input::placeholder{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-area__field .bm-text-area__input:focus{outline-offset:calc(0px - var(--bm-sem-size-focus-offset));outline:var(--bm-sem-border-width-focus) solid var(--bm-sem-color-border-focus)}';
|
|
24
|
+
var U = Object.defineProperty, X = Object.getOwnPropertyDescriptor, S = (e) => {
|
|
25
|
+
throw TypeError(e);
|
|
26
|
+
}, a = (e, r, t, s) => {
|
|
27
|
+
for (var c = s > 1 ? void 0 : s ? X(r, t) : r, b = e.length - 1, u; b >= 0; b--)
|
|
28
|
+
(u = e[b]) && (c = (s ? u(r, t, c) : u(c)) || c);
|
|
29
|
+
return s && c && U(r, t, c), c;
|
|
30
|
+
}, q = (e, r, t) => r.has(e) || S("Cannot " + t), o = (e, r, t) => (q(e, r, "read from private field"), t ? t.call(e) : r.get(e)), l = (e, r, t) => r.has(e) ? S("Cannot add the same private member more than once") : r instanceof WeakSet ? r.add(e) : r.set(e, t), p, h, M, f, z, v, x, y, w;
|
|
31
|
+
const { baseClassNamePrefix: F, subElementClassPrefix: g, classModifierPrefix: n } = V("text-area");
|
|
32
|
+
let i = class extends H {
|
|
33
|
+
constructor() {
|
|
34
|
+
super(...arguments), this.required = !1, this.hideRequiredMarker = !1, this.readOnly = !1, this.disabled = !1, this.fluid = !1, this.hideResize = !1, this.autoResize = !1, this.formFieldCounterRef = W(), l(this, p, () => {
|
|
35
|
+
var e;
|
|
36
|
+
return !!(this.disabled || (e = this.formContext) != null && e.disabled);
|
|
37
|
+
}), l(this, h, () => {
|
|
38
|
+
var e;
|
|
39
|
+
return !!(this.readOnly || (e = this.formContext) != null && e.readOnly);
|
|
40
|
+
}), l(this, M, () => {
|
|
41
|
+
var e;
|
|
42
|
+
return !!(this.required || (e = this.formContext) != null && e.required);
|
|
43
|
+
}), l(this, f, () => !!this.autoResize), l(this, z, () => o(this, f).call(this) || !!this.hideResize), l(this, v, () => {
|
|
44
|
+
const { value: e } = this.formFieldCounterRef;
|
|
45
|
+
if (!e) return;
|
|
46
|
+
const { value: r } = this.formFieldRef, {
|
|
47
|
+
value: { length: t }
|
|
48
|
+
} = r;
|
|
49
|
+
e.textContent = `${t}`;
|
|
50
|
+
}), l(this, x, () => {
|
|
51
|
+
const { value: e } = this.formFieldRef;
|
|
52
|
+
A(e, o(this, f).call(this));
|
|
53
|
+
}), l(this, y, (e) => {
|
|
54
|
+
o(this, v).call(this), o(this, x).call(this), this.validateFieldOnChange(e);
|
|
55
|
+
}), l(this, w, (e) => e ? _`
|
|
56
|
+
<div class="${g}counter">
|
|
57
|
+
<span ${N(this.formFieldCounterRef)}></span>/<span>${e}</span>
|
|
58
|
+
</div>
|
|
59
|
+
` : D);
|
|
60
|
+
}
|
|
61
|
+
updated(e) {
|
|
62
|
+
const [r] = this._textAreaLabel, [t] = this._textAreaHelperText, { decorate: s } = I(r), { decorate: c } = I(t), b = d(e, ["value"]), u = d(e, ["maxCount"]), T = d(e, ["autoResize"]), Y = d(e, ["validationRules"]), $ = d(e, ["formContext", "disabled"]), E = d(e, [
|
|
63
|
+
"formContext",
|
|
64
|
+
"required",
|
|
65
|
+
"hideRequiredMarker"
|
|
66
|
+
]), P = d(e, ["formContext"]) && this.contextInitialsChanged();
|
|
67
|
+
(b || P) && this.setContextValue(), $ && (s({ disabled: o(this, p).call(this) }), c({ disabled: o(this, p).call(this) })), u && o(this, v).call(this), T && o(this, x).call(this), Y && this.setContextValidation(), E && s({ required: o(this, M).call(this) && !this.hideRequiredMarker });
|
|
68
|
+
}
|
|
69
|
+
finalizeAssociatedCallback(e) {
|
|
70
|
+
return {
|
|
71
|
+
ctxValue: e.slice(0, this.maxCount),
|
|
72
|
+
finalizeCallback: () => {
|
|
73
|
+
o(this, v).call(this), o(this, x).call(this);
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
render() {
|
|
78
|
+
const { ariaInvalid: e } = this, { length: r } = this.validationErrors(), t = typeof this.error == "string" || !!r, s = C(
|
|
79
|
+
this.helperTextId,
|
|
80
|
+
this.error && this.errorId,
|
|
81
|
+
this.validationErrorShown() && this.validationErrorsId
|
|
82
|
+
), c = C(
|
|
83
|
+
F,
|
|
84
|
+
t && `${n}error`,
|
|
85
|
+
this.theme && G(this.theme),
|
|
86
|
+
this.fluid && `${n}fluid`,
|
|
87
|
+
this.cols && `${n}cols-width`,
|
|
88
|
+
o(this, p).call(this) && `${n}disabled`,
|
|
89
|
+
o(this, h).call(this) && `${n}read-only`,
|
|
90
|
+
o(this, z).call(this) && `${n}hide-resize`,
|
|
91
|
+
o(this, f).call(this) && `${n}auto-resize`
|
|
92
|
+
);
|
|
93
|
+
return _`
|
|
94
|
+
<div class="${c}" style="max-width: ${this.width}">
|
|
95
|
+
<div class="${g}header">
|
|
96
|
+
<slot name="label" id="${this.labelId}"></slot>
|
|
97
|
+
${o(this, w).call(this, this.maxCount)}
|
|
98
|
+
</div>
|
|
99
|
+
<div class="${g}field">
|
|
100
|
+
<textarea
|
|
101
|
+
id="${this.id}"
|
|
102
|
+
name="${this.name}"
|
|
103
|
+
rows="${this.rows}"
|
|
104
|
+
cols="${this.cols}"
|
|
105
|
+
${N(this.formFieldRef)}
|
|
106
|
+
maxlength="${this.maxCount}"
|
|
107
|
+
@input="${o(this, y)}"
|
|
108
|
+
?required="${o(this, M).call(this)}"
|
|
109
|
+
?readonly="${o(this, h).call(this)}"
|
|
110
|
+
?disabled="${o(this, p).call(this)}"
|
|
111
|
+
placeholder="${this.placeholder}"
|
|
112
|
+
aria-labelledby="${this.labelId}"
|
|
113
|
+
aria-label="${this.inputAriaLabel}"
|
|
114
|
+
@blur="${this.validateFieldOnBlur}"
|
|
115
|
+
aria-describedby="${s}"
|
|
116
|
+
class="${g}input"
|
|
117
|
+
aria-invalid="${e || t}"
|
|
118
|
+
aria-disabled="${o(this, p).call(this) || o(this, h).call(this)}"
|
|
119
|
+
></textarea>
|
|
120
|
+
</div>
|
|
121
|
+
<slot name="helper-text" id="${this.helperTextId}"></slot>
|
|
122
|
+
${this.renderError(this.error, o(this, p).call(this))}
|
|
123
|
+
${this.renderValidationErrors()}
|
|
124
|
+
</div>
|
|
125
|
+
`;
|
|
126
|
+
}
|
|
127
|
+
};
|
|
128
|
+
p = /* @__PURE__ */ new WeakMap();
|
|
129
|
+
h = /* @__PURE__ */ new WeakMap();
|
|
130
|
+
M = /* @__PURE__ */ new WeakMap();
|
|
131
|
+
f = /* @__PURE__ */ new WeakMap();
|
|
132
|
+
z = /* @__PURE__ */ new WeakMap();
|
|
133
|
+
v = /* @__PURE__ */ new WeakMap();
|
|
134
|
+
x = /* @__PURE__ */ new WeakMap();
|
|
135
|
+
y = /* @__PURE__ */ new WeakMap();
|
|
136
|
+
w = /* @__PURE__ */ new WeakMap();
|
|
137
|
+
B(i);
|
|
138
|
+
i.styles = R(O);
|
|
139
|
+
a([
|
|
140
|
+
m({ type: Number })
|
|
141
|
+
], i.prototype, "rows", 2);
|
|
142
|
+
a([
|
|
143
|
+
m({ type: Number })
|
|
144
|
+
], i.prototype, "cols", 2);
|
|
145
|
+
a([
|
|
146
|
+
m({ type: String })
|
|
147
|
+
], i.prototype, "placeholder", 2);
|
|
148
|
+
a([
|
|
149
|
+
m({ type: Boolean })
|
|
150
|
+
], i.prototype, "required", 2);
|
|
151
|
+
a([
|
|
152
|
+
m({ type: Boolean })
|
|
153
|
+
], i.prototype, "hideRequiredMarker", 2);
|
|
154
|
+
a([
|
|
155
|
+
m({ type: String })
|
|
156
|
+
], i.prototype, "error", 2);
|
|
157
|
+
a([
|
|
158
|
+
m({ type: Boolean })
|
|
159
|
+
], i.prototype, "readOnly", 2);
|
|
160
|
+
a([
|
|
161
|
+
m({ type: Boolean })
|
|
162
|
+
], i.prototype, "disabled", 2);
|
|
163
|
+
a([
|
|
164
|
+
m({ type: Boolean })
|
|
165
|
+
], i.prototype, "fluid", 2);
|
|
166
|
+
a([
|
|
167
|
+
m({ type: String })
|
|
168
|
+
], i.prototype, "width", 2);
|
|
169
|
+
a([
|
|
170
|
+
m({ type: Boolean })
|
|
171
|
+
], i.prototype, "hideResize", 2);
|
|
172
|
+
a([
|
|
173
|
+
m({ type: Number })
|
|
174
|
+
], i.prototype, "maxCount", 2);
|
|
175
|
+
a([
|
|
176
|
+
m({ type: Boolean })
|
|
177
|
+
], i.prototype, "autoResize", 2);
|
|
178
|
+
a([
|
|
179
|
+
m({ type: String })
|
|
180
|
+
], i.prototype, "theme", 2);
|
|
181
|
+
a([
|
|
182
|
+
k({ slot: "label" })
|
|
183
|
+
], i.prototype, "_textAreaLabel", 2);
|
|
184
|
+
a([
|
|
185
|
+
k({ slot: "helper-text" })
|
|
186
|
+
], i.prototype, "_textAreaHelperText", 2);
|
|
187
|
+
i = a([
|
|
188
|
+
L("bm-text-area")
|
|
189
|
+
], i);
|
|
190
|
+
export {
|
|
191
|
+
i as BmTextArea
|
|
192
|
+
};
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
import { r as E, x as b } from "../../chunks/lit-element.CJtt9wj5.js";
|
|
2
|
+
import { n as c, c as O } from "../../chunks/register-custom-element.vod7zfGv.js";
|
|
3
|
+
import { r as k } from "../../chunks/state.CqiuSzAl.js";
|
|
4
|
+
import { o as S } from "../../chunks/query-assigned-elements.Drkgpk9q.js";
|
|
5
|
+
import { n as A } from "../../chunks/ref.B7e1Hu4F.js";
|
|
6
|
+
import { p as f, a as C, c as $, g as P } from "../../chunks/classNames.C6fNrXWF.js";
|
|
7
|
+
import { t as I } from "../../chunks/constants.jOWREYQE.js";
|
|
8
|
+
import { r as T } from "../../chunks/delegate.baxDQosr.js";
|
|
9
|
+
import { s as z } from "../../chunks/helpers.BWcXAteC.js";
|
|
10
|
+
import { FormField as W } from "../Form/Form.decorator.js";
|
|
11
|
+
import "../../chunks/index.Bz1Jq4c2.js";
|
|
12
|
+
const L = ':root,:host,.bm-light,.bm-dark .bm-inverse,[data-bm-theme~=bm-light]{--bm-comp-input-color-bg: var(--bm-sem-color-surface-01, #ffffff);--bm-comp-input-color-bg-disabled: var( --bm-sem-color-surface-highlight, rgba(159, 175, 188, .16) );--bm-comp-input-color-border: var(--bm-sem-color-border-strong, #8697a5);--bm-comp-input-color-border-error: var( --bm-sem-color-border-negative-strong, #cc2429 );--bm-comp-input-color-border-disabled: rgba(134, 151, 165, .4);--bm-comp-input-color-text: var(--bm-sem-color-text-primary, #141d24);--bm-comp-input-color-text-placeholder: var( --bm-sem-color-text-secondary, #576775 );--bm-comp-input-color-text-disabled: var( --bm-sem-color-text-disabled, rgba(87, 103, 117, .4) );--bm-comp-input-color-icon-disabled: var( --bm-sem-color-text-disabled, rgba(87, 103, 117, .4) );--bm-comp-input-color-icon: var(--bm-sem-color-icon-secondary, #576775);--bm-comp-input-color-icon-error: var( --bm-sem-color-icon-negative-strong, #cc2429 );--bm-comp-input-color-divider: var(--bm-sem-color-border-02, #d1dae0);--bm-comp-input-color-choice-checkbox-selected-bg: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-checkbox-selected-icon: var( --bm-sem-color-icon-primary-inverse, #ffffff );--bm-comp-input-color-choice-checkbox-selected-bg-error: var( --bm-sem-color-surface-negative-strong, #cc2429 );--bm-comp-input-color-choice-checkbox-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-switch-selected-bg: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-switch-selected-icon: var( --bm-sem-color-icon-primary-inverse, #ffffff );--bm-comp-input-color-choice-switch-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-radio-selected-bg: var( --bm-sem-color-surface-01, #ffffff );--bm-comp-input-color-choice-radio-selected-border: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-radio-selected-inner-circle: var( --bm-utility-color-accent-default, #00768f );--bm-comp-input-color-choice-radio-selected-bg-error: var( --bm-sem-color-surface-01, #ffffff );--bm-comp-input-color-choice-radio-selected-border-error: var( --bm-sem-color-surface-negative-strong, #cc2429 );--bm-comp-input-color-choice-radio-selected-inner-circle-error: var( --bm-sem-color-surface-negative-strong, #cc2429 );--bm-comp-input-typo-default: var( --bm-sem-typo-compact-body-md, 400 1rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-character-count: var( --bm-sem-typo-body-sm, 400 .875rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-label-choice: var( --bm-sem-typo-body-md, 400 1rem/1.5rem "Source Sans Pro" );--bm-comp-input-space-field-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-field-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-field-gap: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-inside: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-choice-nudge: var( --bm-primitive-dimension-12, .125rem );--bm-comp-input-size-field-md-height: var(--bm-sem-size-height-md, 2.5rem);--bm-comp-input-size-field-width: var(--bm-primitive-dimension-1800, 18rem);--bm-comp-input-size-field-icon: var(--bm-sem-size-icon-md, 1.25rem);--bm-comp-input-size-field-text-area-height: var( --bm-primitive-dimension-475, 4.75rem );--bm-comp-input-size-choice-checkbox: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio-inside: var( --bm-primitive-dimension-50, .5rem );--bm-comp-input-size-choice-switch-height: var( --bm-sem-size-icon-md, 1.25rem );--bm-comp-input-size-choice-switch-width: var( --bm-primitive-dimension-250, 2.5rem );--bm-comp-input-size-choice-switch-knob: var( --bm-primitive-dimension-87, .875rem );--bm-comp-input-radius-field: var(--bm-sem-radius-input-md, .25rem);--bm-comp-input-radius-choice-checkbox: var( --bm-sem-radius-input-sm, .125rem );--bm-comp-input-radius-choice-radio: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-radius-choice-switch: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-border-width-field-default: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-border-width-field-error: var( --bm-sem-border-width-lg, .125rem );--bm-comp-input-border-width-choice: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-shadow-field: var( --bm-sem-shadow-none, 0 0 0 0 rgb(0, 0, 0, 0) )}:host,.bm-dark,.bm-light .bm-inverse,[data-bm-theme~=bm-dark]{--bm-comp-input-color-bg: var(--bm-sem-color-surface-01, #202e39);--bm-comp-input-color-bg-disabled: var( --bm-sem-color-surface-highlight, rgba(134, 151, 165, .16) );--bm-comp-input-color-border: var(--bm-sem-color-border-strong, #9fafbc);--bm-comp-input-color-border-error: var( --bm-sem-color-border-negative-strong, #f67378 );--bm-comp-input-color-border-disabled: rgba(159, 175, 188, .4);--bm-comp-input-color-text: var(--bm-sem-color-text-primary, #ffffff);--bm-comp-input-color-text-placeholder: var( --bm-sem-color-text-secondary, #c3cdd5 );--bm-comp-input-color-text-disabled: var( --bm-sem-color-text-disabled, rgba(195, 205, 213, .4) );--bm-comp-input-color-icon-disabled: var( --bm-sem-color-text-disabled, rgba(195, 205, 213, .4) );--bm-comp-input-color-icon: var(--bm-sem-color-icon-secondary, #c3cdd5);--bm-comp-input-color-icon-error: var( --bm-sem-color-icon-negative-strong, #f67378 );--bm-comp-input-color-divider: var(--bm-sem-color-border-02, #465967);--bm-comp-input-color-choice-checkbox-selected-bg: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-checkbox-selected-icon: var( --bm-sem-color-icon-primary-inverse, #141d24 );--bm-comp-input-color-choice-checkbox-selected-bg-error: var( --bm-sem-color-surface-negative-strong, #f67378 );--bm-comp-input-color-choice-checkbox-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-switch-selected-bg: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-switch-selected-icon: var( --bm-sem-color-icon-primary-inverse, #141d24 );--bm-comp-input-color-choice-switch-selected-border: var( --bm-sem-color-none, #ffffff00 );--bm-comp-input-color-choice-radio-selected-bg: var( --bm-sem-color-surface-01, #202e39 );--bm-comp-input-color-choice-radio-selected-border: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-radio-selected-inner-circle: var( --bm-utility-color-accent-default, #43bfd6 );--bm-comp-input-color-choice-radio-selected-bg-error: var( --bm-sem-color-surface-01, #202e39 );--bm-comp-input-color-choice-radio-selected-border-error: var( --bm-sem-color-surface-negative-strong, #f67378 );--bm-comp-input-color-choice-radio-selected-inner-circle-error: var( --bm-sem-color-surface-negative-strong, #f67378 );--bm-comp-input-typo-default: var( --bm-sem-typo-compact-body-md, 400 1rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-character-count: var( --bm-sem-typo-body-sm, 400 .875rem/1.25rem "Source Sans Pro" );--bm-comp-input-typo-label-choice: var( --bm-sem-typo-body-md, 400 1rem/1.5rem "Source Sans Pro" );--bm-comp-input-space-field-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-field-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-field-gap: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-inside: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-y: var(--bm-sem-space-50, .5rem);--bm-comp-input-space-choice-gap-items-x: var(--bm-sem-space-100, 1rem);--bm-comp-input-space-choice-nudge: var( --bm-primitive-dimension-12, .125rem );--bm-comp-input-size-field-md-height: var(--bm-sem-size-height-md, 2.5rem);--bm-comp-input-size-field-width: var(--bm-primitive-dimension-1800, 18rem);--bm-comp-input-size-field-icon: var(--bm-sem-size-icon-md, 1.25rem);--bm-comp-input-size-field-text-area-height: var( --bm-primitive-dimension-475, 4.75rem );--bm-comp-input-size-choice-checkbox: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio: var(--bm-sem-size-icon-sm, 1rem);--bm-comp-input-size-choice-radio-inside: var( --bm-primitive-dimension-50, .5rem );--bm-comp-input-size-choice-switch-height: var( --bm-sem-size-icon-md, 1.25rem );--bm-comp-input-size-choice-switch-width: var( --bm-primitive-dimension-250, 2.5rem );--bm-comp-input-size-choice-switch-knob: var( --bm-primitive-dimension-87, .875rem );--bm-comp-input-radius-field: var(--bm-sem-radius-input-md, .25rem);--bm-comp-input-radius-choice-checkbox: var( --bm-sem-radius-input-sm, .125rem );--bm-comp-input-radius-choice-radio: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-radius-choice-switch: var( --bm-sem-radius-input-lg, 624.938rem );--bm-comp-input-border-width-field-default: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-border-width-field-error: var( --bm-sem-border-width-lg, .125rem );--bm-comp-input-border-width-choice: var( --bm-sem-border-width-input, .063rem );--bm-comp-input-shadow-field: var( --bm-sem-shadow-none, 0 0 0 0 rgb(0, 0, 0, 0) )}.bm-text-field{--bm-label-cursor: pointer;max-width:var(--bm-comp-input-size-field-width);--bm-label-space-bottom: var(--bm-comp-label-space-bottom);--bm-helper-text-space-top: var(--bm-comp-helper-text-space-top)}.bm-text-field--disabled{--bm-label-cursor: not-allowed;--bm-label-pointer-events: auto;--bm-text-field-cursor: not-allowed;--bm-text-field-input-cursor: not-allowed}.bm-text-field--error .bm-text-field__field{border-color:var(--bm-comp-input-color-border-error);background-color:var(--bm-comp-input-color-bg);outline-offset:calc(0px - var(--bm-comp-input-border-width-field-error));outline:var(--bm-comp-input-border-width-field-error) solid var(--bm-comp-input-color-border-error)}.bm-text-field--error .bm-text-field__field .bm-text-field__input{color:var(--bm-comp-input-color-text)}.bm-text-field--error .bm-text-field__field .bm-text-field__input::placeholder{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-field--read-only .bm-text-field__field{border-color:var(--bm-comp-input-color-border-disabled);background-color:var(--bm-comp-input-color-bg-disabled)}.bm-text-field--read-only .bm-text-field__field .bm-text-field__input{color:var(--bm-comp-input-color-text)}.bm-text-field--read-only .bm-text-field__field .bm-text-field__input::placeholder{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-field--read-only .bm-text-field__field .bm-text-field__content svg,.bm-text-field--read-only .bm-text-field__field .bm-text-field__content ::slotted([slot*=content]){color:var(--bm-comp-input-color-icon)}.bm-text-field--disabled .bm-text-field__field{border-color:var(--bm-comp-input-color-border-disabled);background-color:var(--bm-comp-input-color-bg-disabled)}.bm-text-field--disabled .bm-text-field__field .bm-text-field__input{color:var(--bm-comp-input-color-text-disabled)}.bm-text-field--disabled .bm-text-field__field .bm-text-field__input::placeholder{color:var(--bm-comp-input-color-text-disabled)}.bm-text-field--disabled .bm-text-field__field .bm-text-field__content{opacity:var(--bm-sem-opacity-disabled)}.bm-text-field--disabled .bm-text-field__field .bm-text-field__content svg,.bm-text-field--disabled .bm-text-field__field .bm-text-field__content ::slotted([slot*=content]){color:var(--bm-comp-input-color-text-disabled)}.bm-text-field--fluid{max-width:100%}.bm-text-field--ellipsis .bm-text-field__field .bm-text-field__input{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.bm-text-field__field{display:flex;flex-wrap:nowrap;align-items:center;box-sizing:border-box;transform:translate3d(var(--bm-sem-space-0),var(--bm-sem-space-0),var(--bm-sem-space-0));border-style:solid;border-color:var(--bm-comp-input-color-border);border-radius:var(--bm-comp-input-radius-field);border-width:var(--bm-comp-input-border-width-field-default);cursor:var(--bm-text-field-cursor, default);gap:var(--bm-comp-input-space-field-gap);box-shadow:var(--bm-comp-input-shadow-field);background-color:var(--bm-comp-input-color-bg);height:var(--bm-comp-input-size-field-md-height);padding:var(--bm-comp-input-space-field-y) var(--bm-comp-input-space-field-x)}.bm-text-field__field:focus-within{outline-offset:calc(0px - var(--bm-sem-size-focus-offset));outline:var(--bm-sem-border-width-focus) solid var(--bm-sem-color-border-focus)}.bm-text-field__field .bm-text-field__input{border:none;outline:none;background:none;width:100%;padding:var(--bm-sem-space-0);color:var(--bm-comp-input-color-text);font:var(--bm-comp-input-typo-default);cursor:var(--bm-text-field-input-cursor, text)}.bm-text-field__field .bm-text-field__input:-webkit-autofill{caret-color:var(--bm-comp-input-color-text);-webkit-text-fill-color:var(--bm-comp-input-color-text);box-shadow:0 0 0 var(--bm-comp-input-size-field-md-height) var(--bm-comp-input-color-bg) inset}.bm-text-field__field .bm-text-field__input::placeholder{color:var(--bm-comp-input-color-text-placeholder)}.bm-text-field__field .bm-text-field__content{display:flex;align-items:center}.bm-text-field__field .bm-text-field__content svg,.bm-text-field__field .bm-text-field__content ::slotted([slot*=content]){color:var(--bm-comp-input-color-icon);width:var(--bm-comp-input-size-field-icon);height:var(--bm-comp-input-size-field-icon)}';
|
|
13
|
+
var R = Object.defineProperty, D = Object.getOwnPropertyDescriptor, B = (e) => {
|
|
14
|
+
throw TypeError(e);
|
|
15
|
+
}, r = (e, o, i, a) => {
|
|
16
|
+
for (var l = a > 1 ? void 0 : a ? D(o, i) : o, n = e.length - 1, p; n >= 0; n--)
|
|
17
|
+
(p = e[n]) && (l = (a ? p(o, i, l) : p(l)) || l);
|
|
18
|
+
return a && l && R(o, i, l), l;
|
|
19
|
+
}, H = (e, o, i) => o.has(e) || B("Cannot " + i), m = (e, o, i) => (H(e, o, "read from private field"), i ? i.call(e) : o.get(e)), s = (e, o, i) => o.has(e) ? B("Cannot add the same private member more than once") : o instanceof WeakSet ? o.add(e) : o.set(e, i), g, _, d, v, x, y, w;
|
|
20
|
+
const { baseClassNamePrefix: N, subElementClassPrefix: u, classModifierPrefix: h } = P("text-field");
|
|
21
|
+
let t = class extends W {
|
|
22
|
+
constructor() {
|
|
23
|
+
super(...arguments), this.required = !1, this.hideRequiredMarker = !1, this.readOnly = !1, this.disabled = !1, this.fluid = !1, this.ellipse = !1, this.type = "text", this.inputMode = "text", this._hasContentBeforeSlot = !1, this._hasContentAfterSlot = !1, s(this, g, () => !!this._hasContentAfterSlot), s(this, _, () => !!this._hasContentBeforeSlot), s(this, d, () => {
|
|
24
|
+
var e;
|
|
25
|
+
return !!(this.disabled || (e = this.formContext) != null && e.disabled);
|
|
26
|
+
}), s(this, v, () => {
|
|
27
|
+
var e;
|
|
28
|
+
return !!(this.readOnly || (e = this.formContext) != null && e.readOnly);
|
|
29
|
+
}), s(this, x, () => {
|
|
30
|
+
var e;
|
|
31
|
+
return !!(this.required || (e = this.formContext) != null && e.required);
|
|
32
|
+
}), s(this, y, () => {
|
|
33
|
+
const e = ({ target: o }) => {
|
|
34
|
+
this._hasContentBeforeSlot = z(o);
|
|
35
|
+
};
|
|
36
|
+
return m(this, _).call(this) ? b`
|
|
37
|
+
<div class="${u}content">
|
|
38
|
+
<slot name="content-before" @slotchange="${e}"></slot>
|
|
39
|
+
</div>
|
|
40
|
+
` : b`<slot name="content-before" @slotchange="${e}"></slot>`;
|
|
41
|
+
}), s(this, w, () => {
|
|
42
|
+
const e = ({ target: o }) => {
|
|
43
|
+
this._hasContentAfterSlot = z(o);
|
|
44
|
+
};
|
|
45
|
+
return m(this, g).call(this) ? b`
|
|
46
|
+
<div class="${u}content">
|
|
47
|
+
<slot name="content-after" @slotchange="${e}"></slot>
|
|
48
|
+
</div>
|
|
49
|
+
` : b`<slot name="content-after" @slotchange="${e}"></slot>`;
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
updated(e) {
|
|
53
|
+
const [o] = this._textFieldLabel, [i] = this._textFieldHelperText, { decorate: a } = C(o), { decorate: l } = C(i), n = f(e, ["value"]), p = f(e, ["validationRules"]), F = f(e, ["formContext", "disabled"]), M = f(e, [
|
|
54
|
+
"formContext",
|
|
55
|
+
"required",
|
|
56
|
+
"hideRequiredMarker"
|
|
57
|
+
]), q = f(e, ["formContext"]) && this.contextInitialsChanged();
|
|
58
|
+
(n || q) && this.setContextValue(), F && (a({ disabled: m(this, d).call(this) }), l({ disabled: m(this, d).call(this) })), p && this.setContextValidation(), M && a({ required: m(this, x).call(this) && !this.hideRequiredMarker });
|
|
59
|
+
}
|
|
60
|
+
render() {
|
|
61
|
+
const { ariaInvalid: e } = this, { length: o } = this.validationErrors(), i = typeof this.error == "string" || !!o, a = $(
|
|
62
|
+
this.helperTextId,
|
|
63
|
+
this.error && this.errorId,
|
|
64
|
+
this.validationErrorShown() && this.validationErrorsId
|
|
65
|
+
), l = $(
|
|
66
|
+
N,
|
|
67
|
+
i && `${h}error`,
|
|
68
|
+
this.theme && I(this.theme),
|
|
69
|
+
this.fluid && `${h}fluid`,
|
|
70
|
+
this.ellipse && `${h}ellipsis`,
|
|
71
|
+
m(this, d).call(this) && `${h}disabled`,
|
|
72
|
+
m(this, v).call(this) && `${h}read-only`
|
|
73
|
+
);
|
|
74
|
+
return b`
|
|
75
|
+
<div class="${l}" style="max-width: ${this.width}">
|
|
76
|
+
<slot name="label" id="${this.labelId}"></slot>
|
|
77
|
+
<div class="${u}field">
|
|
78
|
+
${m(this, y).call(this)}
|
|
79
|
+
<input
|
|
80
|
+
id="${this.id}"
|
|
81
|
+
name="${this.name}"
|
|
82
|
+
type="${this.type}"
|
|
83
|
+
${A(this.formFieldRef)}
|
|
84
|
+
inputmode="${this.inputMode}"
|
|
85
|
+
?required="${m(this, x).call(this)}"
|
|
86
|
+
?readonly="${m(this, v).call(this)}"
|
|
87
|
+
?disabled="${m(this, d).call(this)}"
|
|
88
|
+
placeholder="${this.placeholder}"
|
|
89
|
+
aria-labelledby="${this.labelId}"
|
|
90
|
+
aria-label="${this.inputAriaLabel}"
|
|
91
|
+
@blur="${this.validateFieldOnBlur}"
|
|
92
|
+
@keydown="${this.submitFormByEnter}"
|
|
93
|
+
aria-describedby="${a}"
|
|
94
|
+
class="${u}input"
|
|
95
|
+
@input="${this.validateFieldOnChange}"
|
|
96
|
+
aria-invalid="${e || i}"
|
|
97
|
+
/>
|
|
98
|
+
${m(this, w).call(this)}
|
|
99
|
+
</div>
|
|
100
|
+
<slot name="helper-text" id="${this.helperTextId}"></slot>
|
|
101
|
+
${this.renderError(this.error, m(this, d).call(this))}
|
|
102
|
+
${this.renderValidationErrors()}
|
|
103
|
+
</div>
|
|
104
|
+
`;
|
|
105
|
+
}
|
|
106
|
+
};
|
|
107
|
+
g = /* @__PURE__ */ new WeakMap();
|
|
108
|
+
_ = /* @__PURE__ */ new WeakMap();
|
|
109
|
+
d = /* @__PURE__ */ new WeakMap();
|
|
110
|
+
v = /* @__PURE__ */ new WeakMap();
|
|
111
|
+
x = /* @__PURE__ */ new WeakMap();
|
|
112
|
+
y = /* @__PURE__ */ new WeakMap();
|
|
113
|
+
w = /* @__PURE__ */ new WeakMap();
|
|
114
|
+
T(t);
|
|
115
|
+
t.styles = E(L);
|
|
116
|
+
r([
|
|
117
|
+
c({ type: String })
|
|
118
|
+
], t.prototype, "placeholder", 2);
|
|
119
|
+
r([
|
|
120
|
+
c({ type: Boolean })
|
|
121
|
+
], t.prototype, "required", 2);
|
|
122
|
+
r([
|
|
123
|
+
c({ type: Boolean })
|
|
124
|
+
], t.prototype, "hideRequiredMarker", 2);
|
|
125
|
+
r([
|
|
126
|
+
c({ type: String })
|
|
127
|
+
], t.prototype, "error", 2);
|
|
128
|
+
r([
|
|
129
|
+
c({ type: Boolean })
|
|
130
|
+
], t.prototype, "readOnly", 2);
|
|
131
|
+
r([
|
|
132
|
+
c({ type: Boolean })
|
|
133
|
+
], t.prototype, "disabled", 2);
|
|
134
|
+
r([
|
|
135
|
+
c({ type: Boolean })
|
|
136
|
+
], t.prototype, "fluid", 2);
|
|
137
|
+
r([
|
|
138
|
+
c({ type: String })
|
|
139
|
+
], t.prototype, "width", 2);
|
|
140
|
+
r([
|
|
141
|
+
c({ type: Boolean })
|
|
142
|
+
], t.prototype, "ellipse", 2);
|
|
143
|
+
r([
|
|
144
|
+
c({ type: String })
|
|
145
|
+
], t.prototype, "theme", 2);
|
|
146
|
+
r([
|
|
147
|
+
c({ type: String })
|
|
148
|
+
], t.prototype, "type", 2);
|
|
149
|
+
r([
|
|
150
|
+
c({ type: String })
|
|
151
|
+
], t.prototype, "inputMode", 2);
|
|
152
|
+
r([
|
|
153
|
+
S({ slot: "label" })
|
|
154
|
+
], t.prototype, "_textFieldLabel", 2);
|
|
155
|
+
r([
|
|
156
|
+
S({ slot: "helper-text" })
|
|
157
|
+
], t.prototype, "_textFieldHelperText", 2);
|
|
158
|
+
r([
|
|
159
|
+
k()
|
|
160
|
+
], t.prototype, "_hasContentBeforeSlot", 2);
|
|
161
|
+
r([
|
|
162
|
+
k()
|
|
163
|
+
], t.prototype, "_hasContentAfterSlot", 2);
|
|
164
|
+
t = r([
|
|
165
|
+
O("bm-text-field")
|
|
166
|
+
], t);
|
|
167
|
+
export {
|
|
168
|
+
t as BmTextField
|
|
169
|
+
};
|
package/package.json
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@viasat/beam-web-components",
|
|
3
|
+
"version": "2.0.0",
|
|
4
|
+
"description": "Framework-agnostic web components for the Beam Design System built with Lit, compatible with Angular, Vue, Svelte, and vanilla JavaScript",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"author": "Viasat",
|
|
7
|
+
"homepage": "https://react.beam.viasat.com/",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "https://git.viasat.com/vega/beam",
|
|
11
|
+
"directory": "libs/web-components"
|
|
12
|
+
},
|
|
13
|
+
"bugs": {
|
|
14
|
+
"url": "https://git.viasat.com/vega/beam/issues"
|
|
15
|
+
},
|
|
16
|
+
"keywords": [
|
|
17
|
+
"web-components",
|
|
18
|
+
"custom-elements",
|
|
19
|
+
"design-system",
|
|
20
|
+
"beam",
|
|
21
|
+
"lit",
|
|
22
|
+
"angular",
|
|
23
|
+
"vue",
|
|
24
|
+
"svelte",
|
|
25
|
+
"framework-agnostic"
|
|
26
|
+
],
|
|
27
|
+
"type": "module",
|
|
28
|
+
"main": "./index.js",
|
|
29
|
+
"module": "./index.js",
|
|
30
|
+
"types": "./index.d.ts",
|
|
31
|
+
"customElements": "custom-elements.json",
|
|
32
|
+
"exports": {
|
|
33
|
+
".": {
|
|
34
|
+
"types": "./index.d.ts",
|
|
35
|
+
"import": "./index.js"
|
|
36
|
+
},
|
|
37
|
+
"./*": {
|
|
38
|
+
"types": "./*/index.d.ts",
|
|
39
|
+
"import": "./*/index.js"
|
|
40
|
+
},
|
|
41
|
+
"./wip/*": {
|
|
42
|
+
"types": "./wip/*/index.d.ts",
|
|
43
|
+
"import": "./wip/*/index.js"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"files": [
|
|
47
|
+
"**/*.js",
|
|
48
|
+
"**/*.d.ts",
|
|
49
|
+
"**/*.css",
|
|
50
|
+
"custom-elements.json",
|
|
51
|
+
"vscode.css-custom-data.json",
|
|
52
|
+
"vscode.html-custom-data.json",
|
|
53
|
+
"README.md"
|
|
54
|
+
],
|
|
55
|
+
"sideEffects": [
|
|
56
|
+
"**/*.css",
|
|
57
|
+
"**/*.js",
|
|
58
|
+
"**/*.ts"
|
|
59
|
+
],
|
|
60
|
+
"engines": {
|
|
61
|
+
"node": ">=18.0.0"
|
|
62
|
+
},
|
|
63
|
+
"publishConfig": {
|
|
64
|
+
"access": "public"
|
|
65
|
+
},
|
|
66
|
+
"dependencies": {
|
|
67
|
+
"@viasat/beam-fonts": "2.0.0",
|
|
68
|
+
"@viasat/beam-shared": "2.0.0",
|
|
69
|
+
"@viasat/beam-styles": "2.0.0",
|
|
70
|
+
"@viasat/beam-tokens": "2.0.0",
|
|
71
|
+
"@viasat/beam-icons": "2.0.0",
|
|
72
|
+
"clsx": "^1.2.1",
|
|
73
|
+
"lit": "^3.1.0",
|
|
74
|
+
"@lit/context": "^1.1.1",
|
|
75
|
+
"@floating-ui/utils": "^0.2.9",
|
|
76
|
+
"@floating-ui/dom": "^1.6.13"
|
|
77
|
+
}
|
|
78
|
+
}
|