@pine-ds/core 3.16.1 → 3.16.3
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/components/form.js +2 -0
- package/components/form.js.map +1 -1
- package/components/pds-button2.js +10 -16
- package/components/pds-button2.js.map +1 -1
- package/components/pds-dropdown-menu-item.js +2 -2
- package/components/pds-dropdown-menu-item.js.map +1 -1
- package/components/pds-dropdown-menu.js +1 -1
- package/components/pds-dropdown-menu.js.map +1 -1
- package/dist/cjs/{form-hmpgbT1I.js → form-DUqlzovE.js} +4 -2
- package/dist/{esm-es5/form-DwjNklzi.js.map → cjs/form-DUqlzovE.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/pds-button.cjs.entry.js +10 -16
- package/dist/cjs/pds-button.entry.cjs.js.map +1 -1
- package/dist/cjs/pds-checkbox.cjs.entry.js +1 -1
- package/dist/cjs/pds-dropdown-menu-item.cjs.entry.js +1 -1
- package/dist/cjs/pds-dropdown-menu-item.entry.cjs.js.map +1 -1
- package/dist/cjs/pds-dropdown-menu.cjs.entry.js +1 -1
- package/dist/cjs/pds-dropdown-menu.entry.cjs.js.map +1 -1
- package/dist/cjs/pds-input.cjs.entry.js +1 -1
- package/dist/cjs/pds-multiselect.cjs.entry.js +1 -1
- package/dist/cjs/pds-radio-group.cjs.entry.js +1 -1
- package/dist/cjs/pds-radio.cjs.entry.js +1 -1
- package/dist/cjs/pds-select.cjs.entry.js +1 -1
- package/dist/cjs/pds-switch.cjs.entry.js +1 -1
- package/dist/cjs/pds-textarea.cjs.entry.js +1 -1
- package/dist/cjs/pine-core.cjs.js +1 -1
- package/dist/collection/components/pds-button/pds-button.css +3 -0
- package/dist/collection/components/pds-button/pds-button.js +9 -15
- package/dist/collection/components/pds-button/pds-button.js.map +1 -1
- package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.js +2 -2
- package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.js.map +1 -1
- package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu.css +4 -4
- package/dist/collection/utils/form.js +2 -0
- package/dist/collection/utils/form.js.map +1 -1
- package/dist/docs.json +2 -2
- package/dist/esm/{form-DwjNklzi.js → form-CN-lL5QG.js} +4 -2
- package/dist/esm/{form-DwjNklzi.js.map → form-CN-lL5QG.js.map} +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/pds-button.entry.js +10 -16
- package/dist/esm/pds-button.entry.js.map +1 -1
- package/dist/esm/pds-checkbox.entry.js +1 -1
- package/dist/esm/pds-dropdown-menu-item.entry.js +1 -1
- package/dist/esm/pds-dropdown-menu-item.entry.js.map +1 -1
- package/dist/esm/pds-dropdown-menu.entry.js +1 -1
- package/dist/esm/pds-dropdown-menu.entry.js.map +1 -1
- package/dist/esm/pds-input.entry.js +1 -1
- package/dist/esm/pds-multiselect.entry.js +1 -1
- package/dist/esm/pds-radio-group.entry.js +1 -1
- package/dist/esm/pds-radio.entry.js +1 -1
- package/dist/esm/pds-select.entry.js +1 -1
- package/dist/esm/pds-switch.entry.js +1 -1
- package/dist/esm/pds-textarea.entry.js +1 -1
- package/dist/esm/pine-core.js +1 -1
- package/dist/esm-es5/form-CN-lL5QG.js +2 -0
- package/dist/{cjs/form-hmpgbT1I.js.map → esm-es5/form-CN-lL5QG.js.map} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/pds-button.entry.js +1 -1
- package/dist/esm-es5/pds-button.entry.js.map +1 -1
- package/dist/esm-es5/pds-checkbox.entry.js +1 -1
- package/dist/esm-es5/pds-dropdown-menu-item.entry.js +1 -1
- package/dist/esm-es5/pds-dropdown-menu-item.entry.js.map +1 -1
- package/dist/esm-es5/pds-dropdown-menu.entry.js +1 -1
- package/dist/esm-es5/pds-dropdown-menu.entry.js.map +1 -1
- package/dist/esm-es5/pds-input.entry.js +1 -1
- package/dist/esm-es5/pds-multiselect.entry.js +1 -1
- package/dist/esm-es5/pds-radio-group.entry.js +1 -1
- package/dist/esm-es5/pds-radio.entry.js +1 -1
- package/dist/esm-es5/pds-select.entry.js +1 -1
- package/dist/esm-es5/pds-switch.entry.js +1 -1
- package/dist/esm-es5/pds-textarea.entry.js +1 -1
- package/dist/esm-es5/pine-core.js +1 -1
- package/dist/pine-core/{p-f94ae58d.system.entry.js → p-01aec1ad.system.entry.js} +2 -2
- package/dist/pine-core/{p-f03f4602.system.entry.js → p-0b52923b.system.entry.js} +2 -2
- package/dist/pine-core/{p-bfac5114.entry.js → p-15e554ae.entry.js} +2 -2
- package/dist/pine-core/{p-09ff71ad.system.entry.js → p-23111b1c.system.entry.js} +2 -2
- package/dist/pine-core/p-29266dcd.system.entry.js +2 -0
- package/dist/pine-core/{p-8b4f76e4.system.entry.js.map → p-29266dcd.system.entry.js.map} +1 -1
- package/dist/pine-core/{p-0270ebee.system.entry.js → p-2aac4495.system.entry.js} +2 -2
- package/dist/pine-core/{p-7a6f11bd.system.entry.js → p-36e5e9f4.system.entry.js} +2 -2
- package/dist/pine-core/p-36e5e9f4.system.entry.js.map +1 -0
- package/dist/pine-core/{p-9d9a5ca8.system.entry.js → p-3f05d72e.system.entry.js} +2 -2
- package/dist/pine-core/{p-7ecfe996.entry.js → p-49c4f34a.entry.js} +2 -2
- package/dist/pine-core/{p-bc4b1749.system.entry.js → p-5abc5d82.system.entry.js} +2 -2
- package/dist/pine-core/{p-bcebce69.entry.js → p-6748d7b4.entry.js} +2 -2
- package/dist/pine-core/{p-ad8fe96c.entry.js → p-73bce0bf.entry.js} +2 -2
- package/dist/pine-core/{p-8eb29dbd.entry.js → p-78246e05.entry.js} +2 -2
- package/dist/pine-core/{p-d0366fba.entry.js → p-7a11a6c7.entry.js} +2 -2
- package/dist/pine-core/{p-694cfe69.entry.js → p-94c73d98.entry.js} +2 -2
- package/dist/pine-core/p-94c73d98.entry.js.map +1 -0
- package/dist/pine-core/{p-CCKncKbB.system.js.map → p-BJPmPVaF.system.js.map} +1 -1
- package/dist/pine-core/{p-BHavepTY.system.js → p-Bch44a-T.system.js} +2 -2
- package/dist/pine-core/{p-BHavepTY.system.js.map → p-Bch44a-T.system.js.map} +1 -1
- package/dist/pine-core/{p-DXoBK65z.system.js.map → p-BnJypAy2.system.js.map} +1 -1
- package/dist/pine-core/p-CN-lL5QG.js +2 -0
- package/dist/pine-core/{p-DwjNklzi.js.map → p-CN-lL5QG.js.map} +1 -1
- package/dist/pine-core/{p-igLtCO20.system.js.map → p-CQtQQn3_.system.js.map} +1 -1
- package/dist/pine-core/p-CjnIO2Ro.system.js.map +1 -0
- package/dist/pine-core/{p-DFY2-W9M.system.js.map → p-D4YdQDsG.system.js.map} +1 -1
- package/dist/pine-core/{p-EnxcYko8.system.js.map → p-DJYyo0MJ.system.js.map} +1 -1
- package/dist/pine-core/p-DR2CskUb.system.js.map +1 -0
- package/dist/pine-core/p-DdTbt4lH.system.js.map +1 -0
- package/dist/pine-core/p-JAVnELnm.system.js +1 -1
- package/dist/pine-core/{p-BssHFst4.system.js.map → p-N-jt0_Yl.system.js.map} +1 -1
- package/dist/pine-core/{p-1e77124d.system.entry.js → p-b1820970.system.entry.js} +2 -2
- package/dist/pine-core/{p-caff29fb.entry.js → p-b1a7a0b2.entry.js} +2 -2
- package/dist/pine-core/{p-9eQIEVii.system.js.map → p-c2oMjk1r.system.js.map} +1 -1
- package/dist/pine-core/{p-bce9f17d.system.entry.js → p-c9965216.system.entry.js} +2 -2
- package/dist/pine-core/{p-5162baee.entry.js → p-ce069162.entry.js} +2 -2
- package/dist/pine-core/{p-b61669b4.system.entry.js → p-ef9c539e.system.entry.js} +2 -2
- package/dist/pine-core/p-f5fb71f6.entry.js +2 -0
- package/dist/pine-core/{p-d456c898.entry.js.map → p-f5fb71f6.entry.js.map} +1 -1
- package/dist/pine-core/{p-563b640d.entry.js → p-fbd8ae50.entry.js} +2 -2
- package/dist/pine-core/{p-CJ4Gf3Nx.system.js.map → p-gcCcHox5.system.js.map} +1 -1
- package/dist/pine-core/pds-button.entry.esm.js.map +1 -1
- package/dist/pine-core/pds-dropdown-menu-item.entry.esm.js.map +1 -1
- package/dist/pine-core/pds-dropdown-menu.entry.esm.js.map +1 -1
- package/dist/pine-core/pine-core.esm.js +1 -1
- package/dist/types/components/pds-button/pds-button.d.ts +0 -1
- package/hydrate/index.js +16 -20
- package/hydrate/index.mjs +16 -20
- package/package.json +2 -2
- package/dist/esm-es5/form-DwjNklzi.js +0 -2
- package/dist/pine-core/p-694cfe69.entry.js.map +0 -1
- package/dist/pine-core/p-7a6f11bd.system.entry.js.map +0 -1
- package/dist/pine-core/p-8b4f76e4.system.entry.js +0 -2
- package/dist/pine-core/p-BRn0ywk1.system.js.map +0 -1
- package/dist/pine-core/p-C7XKS9nY.system.js.map +0 -1
- package/dist/pine-core/p-DsJJz9LK.system.js.map +0 -1
- package/dist/pine-core/p-DwjNklzi.js +0 -2
- package/dist/pine-core/p-d456c898.entry.js +0 -2
- /package/dist/pine-core/{p-f94ae58d.system.entry.js.map → p-01aec1ad.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-f03f4602.system.entry.js.map → p-0b52923b.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-bfac5114.entry.js.map → p-15e554ae.entry.js.map} +0 -0
- /package/dist/pine-core/{p-09ff71ad.system.entry.js.map → p-23111b1c.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-0270ebee.system.entry.js.map → p-2aac4495.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-9d9a5ca8.system.entry.js.map → p-3f05d72e.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-7ecfe996.entry.js.map → p-49c4f34a.entry.js.map} +0 -0
- /package/dist/pine-core/{p-bc4b1749.system.entry.js.map → p-5abc5d82.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-bcebce69.entry.js.map → p-6748d7b4.entry.js.map} +0 -0
- /package/dist/pine-core/{p-ad8fe96c.entry.js.map → p-73bce0bf.entry.js.map} +0 -0
- /package/dist/pine-core/{p-8eb29dbd.entry.js.map → p-78246e05.entry.js.map} +0 -0
- /package/dist/pine-core/{p-d0366fba.entry.js.map → p-7a11a6c7.entry.js.map} +0 -0
- /package/dist/pine-core/{p-1e77124d.system.entry.js.map → p-b1820970.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-caff29fb.entry.js.map → p-b1a7a0b2.entry.js.map} +0 -0
- /package/dist/pine-core/{p-bce9f17d.system.entry.js.map → p-c9965216.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-5162baee.entry.js.map → p-ce069162.entry.js.map} +0 -0
- /package/dist/pine-core/{p-b61669b4.system.entry.js.map → p-ef9c539e.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-563b640d.entry.js.map → p-fbd8ae50.entry.js.map} +0 -0
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var index = require('./index-CI0W8NCh.js');
|
|
4
4
|
var floatingUi_dom = require('./floating-ui.dom-Ca6tS7ef.js');
|
|
5
5
|
var utils = require('./utils-7jx8T2mW.js');
|
|
6
|
-
var form = require('./form-
|
|
6
|
+
var form = require('./form-DUqlzovE.js');
|
|
7
7
|
var index$1 = require('./index-DkQebouX.js');
|
|
8
8
|
|
|
9
9
|
const pdsMultiselectCss = ":host{display:block}:host([aria-disabled=true]) .pds-multiselect__trigger{background:var(--pine-color-background-container-disabled);border-color:var(--pine-color-border-disabled);color:var(--pine-color-text-disabled);cursor:not-allowed}:host([aria-disabled=true]) .pds-multiselect__icon{color:var(--pine-color-text-disabled)}.pds-multiselect{position:relative}.pds-multiselect__label{color:var(--pine-color-text-label);display:block;font:var(--pine-typography-body-medium);letter-spacing:var(--pine-letter-spacing);-webkit-margin-after:var(--pine-dimension-2xs);margin-block-end:var(--pine-dimension-2xs)}.pds-multiselect__wrapper{position:relative}.pds-multiselect__trigger{-ms-flex-align:center;align-items:center;background:var(--pine-color-background-container);border:var(--pine-border);border-radius:var(--pine-dimension-125);cursor:pointer;display:-ms-flexbox;display:flex;font:var(--pine-typography-body);gap:var(--pine-dimension-xs);-ms-flex-pack:justify;justify-content:space-between;letter-spacing:var(--pine-letter-spacing);min-height:var(--pine-dimension-550);padding:var(--pine-dimension-xs) var(--pine-dimension-sm);position:relative;text-align:start;-webkit-transition:border-color 0.2s ease, -webkit-box-shadow 0.2s ease;transition:border-color 0.2s ease, -webkit-box-shadow 0.2s ease;transition:border-color 0.2s ease, box-shadow 0.2s ease;transition:border-color 0.2s ease, box-shadow 0.2s ease, -webkit-box-shadow 0.2s ease;width:100%}.pds-multiselect__trigger:hover:not(.pds-multiselect__trigger--disabled){border-color:var(--pine-color-border-hover)}.pds-multiselect__trigger:focus:not(.pds-multiselect__trigger--disabled){border-color:var(--pine-color-border-active);outline:var(--pine-outline-focus);outline-offset:var(--pine-border-width)}.pds-multiselect__trigger.pds-multiselect__trigger--open{border-color:var(--pine-color-border-active)}.pds-multiselect__trigger.pds-multiselect__trigger--invalid{background-color:var(--pine-color-red-050);border-color:var(--pine-color-border-danger)}.pds-multiselect__trigger.pds-multiselect__trigger--invalid:focus{outline-color:var(--pine-color-focus-ring-danger)}.pds-multiselect__trigger.pds-multiselect__trigger--disabled{background:var(--pine-color-background-container-disabled);border-color:var(--pine-color-border-disabled);color:var(--pine-color-text-disabled);cursor:not-allowed}.pds-multiselect__trigger-text{color:var(--pine-color-text-strong);-ms-flex:1;flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.pds-multiselect__trigger-text.pds-multiselect__trigger-text--placeholder{color:var(--pine-color-text-placeholder)}.pds-multiselect__trigger--disabled .pds-multiselect__trigger-text{color:var(--pine-color-text-disabled)}.pds-multiselect__icon{color:var(--pine-color-icon);-ms-flex-negative:var(--pine-dimension-none);flex-shrink:var(--pine-dimension-none)}.pds-multiselect__panel{background:var(--pine-color-background-container);border-radius:var(--pine-dimension-125);-webkit-box-shadow:var(--pine-box-shadow);box-shadow:var(--pine-box-shadow);-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;position:absolute;z-index:var(--pine-z-index-raised)}.pds-multiselect__search{-ms-flex-align:center;align-items:center;-webkit-border-after:var(--pine-border);border-block-end:var(--pine-border);border-block-end-color:var(--pine-color-border-subtle);display:-ms-flexbox;display:flex;gap:var(--pine-dimension-xs);padding:var(--pine-dimension-xs) var(--pine-dimension-sm)}.pds-multiselect__search pds-icon{color:var(--pine-color-text-muted);-ms-flex-negative:var(--pine-dimension-none);flex-shrink:var(--pine-dimension-none)}.pds-multiselect__search-input{background:transparent;border:var(--pine-dimension-none);color:var(--pine-color-text-strong);-ms-flex:1;flex:1;font:var(--pine-typography-body);letter-spacing:var(--pine-letter-spacing);min-width:var(--pine-dimension-none);outline:none}.pds-multiselect__search-input::-webkit-input-placeholder{color:var(--pine-color-text-placeholder)}.pds-multiselect__search-input::-moz-placeholder{color:var(--pine-color-text-placeholder)}.pds-multiselect__search-input:-ms-input-placeholder{color:var(--pine-color-text-placeholder)}.pds-multiselect__search-input::-ms-input-placeholder{color:var(--pine-color-text-placeholder)}.pds-multiselect__search-input::placeholder{color:var(--pine-color-text-placeholder)}.pds-multiselect__selected-section{-webkit-border-after:var(--pine-border);border-block-end:var(--pine-border);border-block-end-color:var(--pine-color-border-subtle);padding:var(--pine-dimension-xs)}.pds-multiselect__selected-list{list-style:none;margin:var(--pine-dimension-none);padding:var(--pine-dimension-none)}.pds-multiselect__selected-item{color:var(--pine-color-text-strong);font:var(--pine-typography-body);letter-spacing:var(--pine-letter-spacing);overflow:hidden;padding:var(--pine-dimension-2xs) var(--pine-dimension-xs);text-overflow:ellipsis;white-space:nowrap}.pds-multiselect__listbox{background:transparent;border:var(--pine-dimension-none);-webkit-box-sizing:border-box;box-sizing:border-box;list-style:none;margin:var(--pine-dimension-none);overflow-y:auto;padding:var(--pine-dimension-xs)}.pds-multiselect__option{-ms-flex-align:center;align-items:center;background:transparent;border-radius:var(--pine-dimension-xs);cursor:pointer;display:-ms-flexbox;display:flex;padding:var(--pine-dimension-2xs) var(--pine-dimension-xs);-webkit-transition:background 0.15s;transition:background 0.15s}.pds-multiselect__option pds-checkbox{pointer-events:none;width:100%}.pds-multiselect__option:hover,.pds-multiselect__option.pds-multiselect__option--highlighted{background:var(--pine-color-background-muted)}.pds-multiselect__option:focus-visible{outline:var(--pine-dimension-none)}.pds-multiselect__create-option{color:var(--pine-color-text-strong);width:100%}.pds-multiselect__create-option pds-icon{color:var(--pine-color-text-muted);-ms-flex-negative:var(--pine-dimension-none);flex-shrink:var(--pine-dimension-none)}.pds-multiselect__empty,.pds-multiselect__loading{-ms-flex-align:center;align-items:center;color:var(--pine-color-text-muted);display:-ms-flexbox;display:flex;font:var(--pine-typography-body);-ms-flex-pack:center;justify-content:center;padding:var(--pine-dimension-sm)}.pds-multiselect__load-more{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;padding:var(--pine-dimension-xs)}.pds-multiselect__helper{color:var(--pine-color-text-message);font:var(--pine-typography-body-sm);-webkit-margin-before:var(--pine-dimension-2xs);margin-block-start:var(--pine-dimension-2xs);-webkit-margin-start:var(--pine-dimension-none);margin-inline-start:var(--pine-dimension-none)}.pds-multiselect__error{-ms-flex-align:start;align-items:flex-start;color:var(--pine-color-text-message-danger);display:-ms-flexbox;display:flex;font:var(--pine-typography-body-sm);gap:var(--pine-dimension-2xs);-webkit-margin-before:var(--pine-dimension-2xs);margin-block-start:var(--pine-dimension-2xs);-webkit-margin-start:var(--pine-dimension-none);margin-inline-start:var(--pine-dimension-none)}.pds-multiselect__error pds-icon{-ms-flex-negative:var(--pine-dimension-none);flex-shrink:var(--pine-dimension-none);-webkit-margin-before:var(--pine-dimension-025);margin-block-start:var(--pine-dimension-025)}.visually-hidden{border:var(--pine-dimension-none);clip:rect(0 0 0 0);-webkit-clip-path:polygon(0 0, 0 0, 0 0);clip-path:polygon(0 0, 0 0, 0 0);height:1px;margin:-1px;overflow:hidden;padding:var(--pine-dimension-none);position:absolute;white-space:nowrap;width:1px}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var index = require('./index-CI0W8NCh.js');
|
|
4
|
-
var form = require('./form-
|
|
4
|
+
var form = require('./form-DUqlzovE.js');
|
|
5
5
|
var index$1 = require('./index-DkQebouX.js');
|
|
6
6
|
|
|
7
7
|
const pdsRadioGroupCss = ".sc-pds-radio-group-h{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;gap:var(--pine-dimension-sm)}.is-invalid.sc-pds-radio-group-h .pds-radio-group__message--error.sc-pds-radio-group{color:var(--pine-color-text-message-danger)}.pds-radio-group__label.sc-pds-radio-group{color:var(--pine-color-text-label);font:var(--pine-typography-heading-6);font-weight:var(--pine-font-weight-medium);letter-spacing:var(--pine-letter-spacing-heading-6)}.pds-radio-group__radios.sc-pds-radio-group{display:-ms-flexbox;display:flex;gap:var(--pds-radio-group-gap, var(--pine-dimension-xs))}.pds-radio-group__radios--row.sc-pds-radio-group{-ms-flex-align:start;align-items:flex-start;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.pds-radio-group__radios--column.sc-pds-radio-group{-ms-flex-direction:column;flex-direction:column}.pds-radio-group__message.sc-pds-radio-group{color:var(--pine-color-text-message);font:var(--pine-typography-body);width:100%}.pds-radio-group__message--error.sc-pds-radio-group{display:-ms-flexbox;display:flex;gap:var(--pine-dimension-2xs)}.pds-radio-group__message--error.sc-pds-radio-group pds-icon.sc-pds-radio-group{-webkit-margin-before:var(--pine-dimension-050);margin-block-start:var(--pine-dimension-050)}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var index = require('./index-CI0W8NCh.js');
|
|
4
|
-
var form = require('./form-
|
|
4
|
+
var form = require('./form-DUqlzovE.js');
|
|
5
5
|
var index$1 = require('./index-DkQebouX.js');
|
|
6
6
|
|
|
7
7
|
const labelCss = ".sc-pds-radio-h{display:inline-block}[aria-disabled=true].sc-pds-radio-h label.sc-pds-radio{color:var(--pine-color-text-label-disabled)}[aria-readonly=true].sc-pds-radio-h label.sc-pds-radio{color:var(--pine-color-text-label-readonly)}label.sc-pds-radio{color:var(--pine-color-text-label);font:var(--pine-typography-body-medium);letter-spacing:var(--pine-letter-spacing)}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var index = require('./index-CI0W8NCh.js');
|
|
4
|
-
var form = require('./form-
|
|
4
|
+
var form = require('./form-DUqlzovE.js');
|
|
5
5
|
var index$1 = require('./index-DkQebouX.js');
|
|
6
6
|
|
|
7
7
|
const pdsSelectTokensCss = ":host{--pine-select-color-background-danger:var(--pine-color-red-050)}";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var index = require('./index-CI0W8NCh.js');
|
|
4
|
-
var form = require('./form-
|
|
4
|
+
var form = require('./form-DUqlzovE.js');
|
|
5
5
|
var utils = require('./utils-7jx8T2mW.js');
|
|
6
6
|
var attributes = require('./attributes-oNMnBEnP.js');
|
|
7
7
|
var index$1 = require('./index-DkQebouX.js');
|
|
@@ -18,7 +18,7 @@ var patchBrowser = () => {
|
|
|
18
18
|
|
|
19
19
|
patchBrowser().then(async (options) => {
|
|
20
20
|
await index.globalScripts();
|
|
21
|
-
return index.bootstrapLazy(JSON.parse("[[\"pds-multiselect.cjs\",[[321,\"pds-multiselect\",{\"componentId\":[1,\"component-id\"],\"label\":[1],\"placeholder\":[1],\"name\":[1],\"value\":[1040],\"disabled\":[4],\"asyncUrl\":[1,\"async-url\"],\"asyncMethod\":[1,\"async-method\"],\"debounce\":[2],\"fetchTimeout\":[2,\"fetch-timeout\"],\"maxSelections\":[2,\"max-selections\"],\"maxHeight\":[1,\"max-height\"],\"triggerWidth\":[1,\"trigger-width\"],\"minWidth\":[1,\"min-width\"],\"panelWidth\":[1,\"panel-width\"],\"hideLabel\":[4,\"hide-label\"],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"required\":[4],\"loading\":[1028],\"options\":[16],\"formatResult\":[16],\"createUrl\":[1,\"create-url\"],\"csrfToken\":[1,\"csrf-token\"],\"csrfHeaderName\":[1,\"csrf-header-name\"],\"isOpen\":[32],\"searchQuery\":[32],\"highlightedIndex\":[32],\"internalOptions\":[32],\"selectedItems\":[32],\"currentPage\":[32],\"hasMore\":[32],\"creating\":[32],\"setFocus\":[64]},[[8,\"keydown\",\"handleWindowKeyDown\"]],{\"debounce\":[\"setupDebounce\"],\"value\":[\"valueChanged\"],\"options\":[\"optionsChanged\"],\"internalOptions\":[\"internalOptionsChanged\"]}]]],[\"pds-combobox.cjs\",[[321,\"pds-combobox\",{\"componentId\":[1,\"component-id\"],\"name\":[513],\"customOptionLayouts\":[4,\"custom-option-layouts\"],\"customTriggerContent\":[4,\"custom-trigger-content\"],\"disabled\":[4],\"dropdownPlacement\":[1,\"dropdown-placement\"],\"dropdownWidth\":[1,\"dropdown-width\"],\"hideLabel\":[4,\"hide-label\"],\"label\":[1],\"maxHeight\":[1,\"max-height\"],\"mode\":[1],\"placeholder\":[1],\"trigger\":[1],\"triggerWidth\":[1,\"trigger-width\"],\"triggerVariant\":[1,\"trigger-variant\"],\"chipSentiment\":[1,\"chip-sentiment\"],\"chipLarge\":[4,\"chip-large\"],\"chipIcon\":[1,\"chip-icon\"],\"chipDot\":[4,\"chip-dot\"],\"value\":[1025],\"asyncUrl\":[1,\"async-url\"],\"asyncMethod\":[1,\"async-method\"],\"debounce\":[2],\"fetchTimeout\":[2,\"fetch-timeout\"],\"loading\":[1028],\"options\":[16],\"formatResult\":[16],\"displayText\":[32],\"filteredItems\":[32],\"highlightedIndex\":[32],\"isOpen\":[32],\"selectedOption\":[32],\"selectedOptionLayoutContent\":[32],\"selectedOptionChipProps\":[32],\"internalOptions\":[32],\"currentPage\":[32],\"hasMore\":[32],\"setFocus\":[64],\"getSelectedValue\":[64]},null,{\"debounce\":[\"setupDebounce\"],\"options\":[\"optionsChanged\"],\"value\":[\"handleValueChange\"],\"selectedOption\":[\"handleSelectedOptionChange\"]}]]],[\"pds-alert.cjs\",[[257,\"pds-alert\",{\"componentId\":[1,\"component-id\"],\"heading\":[1],\"small\":[4],\"dismissible\":[4],\"variant\":[1],\"hasActionsContent\":[32]}]]],[\"pds-copytext.cjs\",[[257,\"pds-copytext\",{\"border\":[516],\"componentId\":[1,\"component-id\"],\"fullWidth\":[4,\"full-width\"],\"truncate\":[4],\"value\":[1]}]]],[\"pds-table-head.cjs\",[[257,\"pds-table-head\",{\"indeterminate\":[1028],\"isSelected\":[1028,\"is-selected\"],\"border\":[516],\"background\":[516]}]]],[\"pds-table-row.cjs\",[[257,\"pds-table-row\",{\"indeterminate\":[1028],\"isSelected\":[1028,\"is-selected\"],\"hasDivider\":[32],\"isLastRow\":[32]}]]],[\"pds-dropdown-menu-item.cjs\",[[257,\"pds-dropdown-menu-item\",{\"componentId\":[1,\"component-id\"],\"destructive\":[4],\"disabled\":[4],\"href\":[1],\"external\":[516],\"target\":[513],\"hasFocus\":[32],\"clickItem\":[64]}]]],[\"pds-property.cjs\",[[257,\"pds-property\",{\"componentId\":[1,\"component-id\"],\"icon\":[1]}]]],[\"pds-accordion.cjs\",[[257,\"pds-accordion\",{\"componentId\":[1,\"component-id\"],\"isOpen\":[1540,\"open\"]},null,{\"isOpen\":[\"handleOpenState\"]}]]],[\"pds-avatar.cjs\",[[257,\"pds-avatar\",{\"alt\":[1],\"badge\":[4],\"componentId\":[1,\"component-id\"],\"dropdown\":[4],\"image\":[1],\"initials\":[1],\"size\":[513],\"variant\":[513]}]]],[\"pds-dropdown-menu.cjs\",[[257,\"pds-dropdown-menu\",{\"componentId\":[1,\"component-id\"],\"placement\":[1],\"currentFocusIndex\":[32]},[[8,\"keydown\",\"handleKeyDown\"],[8,\"click\",\"handleWindowClick\"]]]]],[\"pds-filter.cjs\",[[257,\"pds-filter\",{\"componentId\":[1,\"component-id\"],\"variant\":[1],\"icon\":[1],\"text\":[1],\"isOpen\":[32],\"showFilter\":[64],\"hideFilter\":[64]},[[9,\"resize\",\"handleWindowResize\"],[9,\"scroll\",\"handleWindowScroll\"],[4,\"toggle\",\"handlePopoverToggle\"],[4,\"click\",\"handleDocumentClick\"],[4,\"keydown\",\"handleEscapeKey\"]]]]],[\"pds-input.cjs\",[[321,\"pds-input\",{\"autocomplete\":[1],\"componentId\":[1,\"component-id\"],\"debounce\":[2],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"max\":[1],\"maxlength\":[1],\"min\":[1],\"minlength\":[1],\"name\":[1],\"pattern\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"step\":[1],\"type\":[1],\"value\":[1032],\"fullWidth\":[4,\"full-width\"],\"highlight\":[516],\"hasPrefix\":[32],\"hasSuffix\":[32],\"hasPrepend\":[32],\"hasAppend\":[32],\"hasAction\":[32],\"hasFocus\":[32],\"setFocus\":[64]},null,{\"debounce\":[\"debounceChanged\"],\"value\":[\"valueChanged\"]}]]],[\"pds-radio.cjs\",[[262,\"pds-radio\",{\"checked\":[4],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"hasBorder\":[4,\"has-border\"],\"invalid\":[4],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"name\":[1],\"required\":[4],\"value\":[1],\"_hasImage\":[32]}]]],[\"pds-radio-group.cjs\",[[262,\"pds-radio-group\",{\"componentId\":[1,\"component-id\"],\"direction\":[1],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"gap\":[1],\"disabled\":[4],\"invalid\":[4],\"groupLabel\":[1,\"group-label\"],\"name\":[1],\"required\":[4]},[[0,\"change\",\"handleRadioChange\"]],{\"name\":[\"handlePropsChange\"],\"disabled\":[\"handlePropsChange\"],\"invalid\":[\"handlePropsChange\"],\"required\":[\"handlePropsChange\"]}]]],[\"pds-select.cjs\",[[321,\"pds-select\",{\"autocomplete\":[1],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"hideLabel\":[4,\"hide-label\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"label\":[1],\"multiple\":[4],\"name\":[1],\"required\":[4],\"highlight\":[516],\"value\":[1025]},null,{\"value\":[\"valueChanged\"],\"multiple\":[\"multipleChanged\"]}]]],[\"pds-sortable-item.cjs\",[[262,\"pds-sortable-item\",{\"enableActions\":[4,\"enable-actions\"],\"componentId\":[1,\"component-id\"],\"showHandle\":[1028,\"show-handle\"]}]]],[\"pds-switch.cjs\",[[321,\"pds-switch\",{\"componentId\":[1,\"component-id\"],\"checked\":[1028],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"hideLabel\":[4,\"hide-label\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"label\":[1],\"name\":[1],\"required\":[4],\"value\":[1]},null,{\"checked\":[\"checkedChanged\"]}]]],[\"pds-textarea.cjs\",[[321,\"pds-textarea\",{\"autocomplete\":[1],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"debounce\":[2],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[1028],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"name\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"rows\":[2],\"maxLength\":[514,\"max-length\"],\"highlight\":[516],\"value\":[1025],\"hasFocus\":[32],\"hasAction\":[32],\"setFocus\":[64]},null,{\"debounce\":[\"debounceChanged\"],\"value\":[\"valueChanged\"],\"maxLength\":[\"maxLengthChanged\"]}]]],[\"pds-toast.cjs\",[[257,\"pds-toast\",{\"componentId\":[1,\"component-id\"],\"dismissible\":[4],\"duration\":[2],\"icon\":[1],\"type\":[1],\"isVisible\":[32],\"isAnimatingOut\":[32],\"dismiss\":[64]},null,{\"duration\":[\"handleDurationChange\"]}]]],[\"mock-pds-modal.cjs\",[[260,\"mock-pds-modal\",{\"componentId\":[1,\"component-id\"],\"size\":[1],\"scrollable\":[4],\"backdropDismiss\":[4,\"backdrop-dismiss\"],\"open\":[1028],\"showModal\":[64],\"hideModal\":[64]}]]],[\"pds-divider.cjs\",[[257,\"pds-divider\",{\"componentId\":[1,\"component-id\"],\"offset\":[1],\"vertical\":[4]}]]],[\"pds-dropdown-menu-separator.cjs\",[[257,\"pds-dropdown-menu-separator\",{\"componentId\":[1,\"component-id\"],\"disabled\":[4]}]]],[\"pds-filters.cjs\",[[257,\"pds-filters\",{\"componentId\":[1,\"component-id\"]}]]],[\"pds-image.cjs\",[[257,\"pds-image\",{\"alt\":[1],\"componentId\":[1,\"component-id\"],\"height\":[2],\"loading\":[1],\"sizes\":[1],\"src\":[1],\"srcset\":[1],\"width\":[2]}]]],[\"pds-modal.cjs\",[[260,\"pds-modal\",{\"backdropDismiss\":[4,\"backdrop-dismiss\"],\"componentId\":[1,\"component-id\"],\"open\":[1028],\"size\":[1],\"scrollable\":[4],\"focusableElementsArray\":[32],\"showModal\":[64],\"hideModal\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"pds-modal-content.cjs\",[[260,\"pds-modal-content\",{\"border\":[1537],\"contentMaxHeight\":[32]}]]],[\"pds-modal-footer.cjs\",[[260,\"pds-modal-footer\"]]],[\"pds-modal-header.cjs\",[[260,\"pds-modal-header\"]]],[\"pds-popover.cjs\",[[257,\"pds-popover\",{\"popoverTargetAction\":[1,\"popover-target-action\"],\"popoverType\":[1,\"popover-type\"],\"componentId\":[1,\"component-id\"],\"maxWidth\":[2,\"max-width\"],\"placement\":[513],\"active\":[32],\"show\":[64],\"hide\":[64],\"toggle\":[64]}]]],[\"pds-progress.cjs\",[[257,\"pds-progress\",{\"animated\":[4],\"componentId\":[1,\"component-id\"],\"fillColor\":[1,\"fill-color\"],\"label\":[1],\"percent\":[2],\"showPercent\":[4,\"show-percent\"]}]]],[\"pds-row.cjs\",[[256,\"pds-row\",{\"alignItems\":[1,\"align-items\"],\"border\":[4],\"colGap\":[1,\"col-gap\"],\"colGapBlock\":[1,\"col-gap-block\"],\"colGapInline\":[1,\"col-gap-inline\"],\"componentId\":[1,\"component-id\"],\"justifyContent\":[1,\"justify-content\"],\"minHeight\":[1,\"min-height\"],\"noWrap\":[4,\"no-wrap\"]}]]],[\"pds-sortable.cjs\",[[262,\"pds-sortable\",{\"border\":[516],\"componentId\":[1,\"component-id\"],\"dividers\":[516],\"handleType\":[1,\"handle-type\"]}]]],[\"pds-tab.cjs\",[[260,\"pds-tab\",{\"disabled\":[4],\"name\":[1],\"parentComponentId\":[1,\"parent-component-id\"],\"variant\":[1],\"index\":[2],\"selected\":[4]}]]],[\"pds-table.cjs\",[[257,\"pds-table\",{\"compact\":[4],\"componentId\":[1,\"component-id\"],\"responsive\":[4],\"fixedColumn\":[4,\"fixed-column\"],\"selectable\":[4],\"rowDividers\":[516,\"row-dividers\"],\"defaultSortColumn\":[1,\"default-sort-column\"],\"defaultSortDirection\":[1,\"default-sort-direction\"],\"sortingColumn\":[32],\"sortingDirection\":[32]},[[0,\"pdsTableSort\",\"handleTableSort\"],[0,\"pdsTableSelectAll\",\"handleTableSelectAll\"],[0,\"pdsTableRowSelected\",\"handleTableSelect\"]]]]],[\"pds-table-body.cjs\",[[257,\"pds-table-body\"]]],[\"pds-tabpanel.cjs\",[[260,\"pds-tabpanel\",{\"name\":[1],\"parentComponentId\":[1,\"parent-component-id\"],\"variant\":[1],\"selected\":[1028]}]]],[\"pds-tabs.cjs\",[[257,\"pds-tabs\",{\"tablistLabel\":[1,\"tablist-label\"],\"componentId\":[1,\"component-id\"],\"variant\":[1],\"activeTabName\":[1025,\"active-tab-name\"],\"activeTabIndex\":[1026,\"active-tab-index\"]},[[16,\"pdsTabClick\",\"tabClickHandler\"],[0,\"keydown\",\"handleKeyDown\"]]]]],[\"pds-tooltip.cjs\",[[260,\"pds-tooltip\",{\"content\":[1],\"componentId\":[1,\"component-id\"],\"hasArrow\":[4,\"has-arrow\"],\"htmlContent\":[4,\"html-content\"],\"placement\":[513],\"maxWidth\":[1,\"max-width\"],\"opened\":[1540],\"_isInteractiveOpen\":[32],\"showTooltip\":[64],\"hideTooltip\":[64]},null,{\"opened\":[\"handleOpenToggle\"]}]]],[\"pds-icon.cjs\",[[257,\"pds-icon\",{\"color\":[1],\"flipRtl\":[4,\"flip-rtl\"],\"icon\":[8],\"name\":[513],\"size\":[513],\"src\":[1],\"ariaLabel\":[32],\"isVisible\":[32],\"svgContent\":[32]},null,{\"size\":[\"updateStyles\"],\"color\":[\"updateStyles\"],\"name\":[\"onIconPropertyChange\"],\"src\":[\"onIconPropertyChange\"],\"icon\":[\"onIconPropertyChange\"]}]]],[\"pds-button.cjs\",[[257,\"pds-button\",{\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"fullWidth\":[4,\"full-width\"],\"href\":[1],\"icon\":[1],\"iconOnly\":[4,\"icon-only\"],\"loading\":[4],\"name\":[1],\"target\":[1],\"type\":[1],\"value\":[1],\"size\":[1],\"variant\":[1]},[[16,\"keydown\",\"handleFormKeyDown\"]]]]],[\"pds-chip.cjs\",[[257,\"pds-chip\",{\"componentId\":[1,\"component-id\"],\"dot\":[4],\"icon\":[1],\"large\":[4],\"sentiment\":[1],\"variant\":[1],\"removeUrl\":[1,\"remove-url\"],\"removeHttpMethod\":[1,\"remove-http-method\"],\"removeTarget\":[1,\"remove-target\"]}]]],[\"pds-link.cjs\",[[257,\"pds-link\",{\"color\":[1],\"componentId\":[1,\"component-id\"],\"external\":[4],\"target\":[1],\"variant\":[1],\"fontSize\":[1,\"font-size\"],\"href\":[1]}]]],[\"pds-table-head-cell.cjs\",[[257,\"pds-table-head-cell\",{\"cellAlign\":[1,\"cell-align\"],\"sortable\":[4],\"sortingDirection\":[32],\"tableScrolling\":[32],\"isSelected\":[32],\"hasHeadBorder\":[32],\"hasHeadBackground\":[32],\"isActive\":[32],\"setActiveSort\":[64],\"clearActiveSort\":[64]}]]],[\"pds-table-cell.cjs\",[[257,\"pds-table-cell\",{\"cellAlign\":[1,\"cell-align\"],\"truncate\":[4],\"tableScrolling\":[32]}]]],[\"pds-text.cjs\",[[257,\"pds-text\",{\"align\":[1],\"color\":[1],\"decoration\":[1],\"gutter\":[1],\"italic\":[4],\"size\":[1],\"weight\":[1],\"tag\":[1],\"truncate\":[516]}]]],[\"pds-checkbox.cjs\",[[321,\"pds-checkbox\",{\"checked\":[1028],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"indeterminate\":[1028],\"invalid\":[4],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"name\":[1],\"required\":[4],\"value\":[1]},null,{\"checked\":[\"updateIndeterminate\",\"checkedChanged\"]}]]],[\"pds-loader.cjs\",[[257,\"pds-loader\",{\"isLoading\":[4,\"is-loading\"],\"showLabel\":[4,\"show-label\"],\"size\":[513],\"variant\":[1]}]]],[\"pds-box.cjs\",[[256,\"pds-box\",{\"alignItems\":[1,\"align-items\"],\"alignItemsXs\":[1,\"align-items-xs\"],\"alignItemsSm\":[1,\"align-items-sm\"],\"alignItemsMd\":[1,\"align-items-md\"],\"alignItemsLg\":[1,\"align-items-lg\"],\"alignItemsXl\":[1,\"align-items-xl\"],\"alignSelf\":[1,\"align-self\"],\"alignSelfXs\":[1,\"align-self-xs\"],\"alignSelfSm\":[1,\"align-self-sm\"],\"alignSelfMd\":[1,\"align-self-md\"],\"alignSelfLg\":[1,\"align-self-lg\"],\"alignSelfXl\":[1,\"align-self-xl\"],\"auto\":[4],\"autoXs\":[4,\"auto-xs\"],\"autoSm\":[4,\"auto-sm\"],\"autoMd\":[4,\"auto-md\"],\"autoLg\":[4,\"auto-lg\"],\"autoXl\":[4,\"auto-xl\"],\"backgroundColor\":[1,\"background-color\"],\"border\":[4],\"borderColor\":[1,\"border-color\"],\"borderRadius\":[1,\"border-radius\"],\"direction\":[1],\"display\":[1],\"fit\":[4],\"fitXs\":[4,\"fit-xs\"],\"fitSm\":[4,\"fit-sm\"],\"fitMd\":[4,\"fit-md\"],\"fitLg\":[4,\"fit-lg\"],\"fitXl\":[4,\"fit-xl\"],\"gap\":[1],\"gapXs\":[1,\"gap-xs\"],\"gapSm\":[1,\"gap-sm\"],\"gapMd\":[1,\"gap-md\"],\"gapLg\":[1,\"gap-lg\"],\"gapXl\":[1,\"gap-xl\"],\"wrap\":[4],\"wrapXs\":[4,\"wrap-xs\"],\"wrapSm\":[4,\"wrap-sm\"],\"wrapMd\":[4,\"wrap-md\"],\"wrapLg\":[4,\"wrap-lg\"],\"wrapXl\":[4,\"wrap-xl\"],\"flex\":[1],\"justifyContent\":[1,\"justify-content\"],\"justifyContentXs\":[1,\"justify-content-xs\"],\"justifyContentSm\":[1,\"justify-content-sm\"],\"justifyContentMd\":[1,\"justify-content-md\"],\"justifyContentLg\":[1,\"justify-content-lg\"],\"justifyContentXl\":[1,\"justify-content-xl\"],\"marginBlockStart\":[1,\"margin-block-start\"],\"marginBlockStartXs\":[1,\"margin-block-start-xs\"],\"marginBlockStartSm\":[1,\"margin-block-start-sm\"],\"marginBlockStartMd\":[1,\"margin-block-start-md\"],\"marginBlockStartLg\":[1,\"margin-block-start-lg\"],\"marginBlockStartXl\":[1,\"margin-block-start-xl\"],\"marginInlineStart\":[1,\"margin-inline-start\"],\"marginInlineStartXs\":[1,\"margin-inline-start-xs\"],\"marginInlineStartSm\":[1,\"margin-inline-start-sm\"],\"marginInlineStartMd\":[1,\"margin-inline-start-md\"],\"marginInlineStartLg\":[1,\"margin-inline-start-lg\"],\"marginInlineStartXl\":[1,\"margin-inline-start-xl\"],\"marginInlineEnd\":[1,\"margin-inline-end\"],\"marginInlineEndXs\":[1,\"margin-inline-end-xs\"],\"marginInlineEndSm\":[1,\"margin-inline-end-sm\"],\"marginInlineEndMd\":[1,\"margin-inline-end-md\"],\"marginInlineEndLg\":[1,\"margin-inline-end-lg\"],\"marginInlineEndXl\":[1,\"margin-inline-end-xl\"],\"marginBlockEnd\":[1,\"margin-block-end\"],\"marginBlockEndXs\":[1,\"margin-block-end-xs\"],\"marginBlockEndSm\":[1,\"margin-block-end-sm\"],\"marginBlockEndMd\":[1,\"margin-block-end-md\"],\"marginBlockEndLg\":[1,\"margin-block-end-lg\"],\"marginBlockEndXl\":[1,\"margin-block-end-xl\"],\"minHeight\":[513,\"min-height\"],\"minWidth\":[513,\"min-width\"],\"offset\":[1],\"offsetXs\":[1,\"offset-xs\"],\"offsetSm\":[1,\"offset-sm\"],\"offsetMd\":[1,\"offset-md\"],\"offsetLg\":[1,\"offset-lg\"],\"offsetXl\":[1,\"offset-xl\"],\"padding\":[1],\"paddingXs\":[1,\"padding-xs\"],\"paddingSm\":[1,\"padding-sm\"],\"paddingMd\":[1,\"padding-md\"],\"paddingLg\":[1,\"padding-lg\"],\"paddingXl\":[1,\"padding-xl\"],\"paddingBlockStart\":[1,\"padding-block-start\"],\"paddingBlockStartXs\":[1,\"padding-block-start-xs\"],\"paddingBlockStartSm\":[1,\"padding-block-start-sm\"],\"paddingBlockStartMd\":[1,\"padding-block-start-md\"],\"paddingBlockStartLg\":[1,\"padding-block-start-lg\"],\"paddingBlockStartXl\":[1,\"padding-block-start-xl\"],\"paddingBlockEnd\":[1,\"padding-block-end\"],\"paddingBlockEndXs\":[1,\"padding-block-end-xs\"],\"paddingBlockEndSm\":[1,\"padding-block-end-sm\"],\"paddingBlockEndMd\":[1,\"padding-block-end-md\"],\"paddingBlockEndLg\":[1,\"padding-block-end-lg\"],\"paddingBlockEndXl\":[1,\"padding-block-end-xl\"],\"paddingInlineStart\":[1,\"padding-inline-start\"],\"paddingInlineStartXs\":[1,\"padding-inline-start-xs\"],\"paddingInlineStartSm\":[1,\"padding-inline-start-sm\"],\"paddingInlineStartMd\":[1,\"padding-inline-start-md\"],\"paddingInlineStartLg\":[1,\"padding-inline-start-lg\"],\"paddingInlineStartXl\":[1,\"padding-inline-start-xl\"],\"paddingInlineEnd\":[1,\"padding-inline-end\"],\"paddingInlineEndXs\":[1,\"padding-inline-end-xs\"],\"paddingInlineEndSm\":[1,\"padding-inline-end-sm\"],\"paddingInlineEndMd\":[1,\"padding-inline-end-md\"],\"paddingInlineEndLg\":[1,\"padding-inline-end-lg\"],\"paddingInlineEndXl\":[1,\"padding-inline-end-xl\"],\"shadow\":[1],\"size\":[1],\"sizeXs\":[1,\"size-xs\"],\"sizeSm\":[1,\"size-sm\"],\"sizeMd\":[1,\"size-md\"],\"sizeLg\":[1,\"size-lg\"],\"sizeXl\":[1,\"size-xl\"]}]]]]"), options);
|
|
21
|
+
return index.bootstrapLazy(JSON.parse("[[\"pds-multiselect.cjs\",[[321,\"pds-multiselect\",{\"componentId\":[1,\"component-id\"],\"label\":[1],\"placeholder\":[1],\"name\":[1],\"value\":[1040],\"disabled\":[4],\"asyncUrl\":[1,\"async-url\"],\"asyncMethod\":[1,\"async-method\"],\"debounce\":[2],\"fetchTimeout\":[2,\"fetch-timeout\"],\"maxSelections\":[2,\"max-selections\"],\"maxHeight\":[1,\"max-height\"],\"triggerWidth\":[1,\"trigger-width\"],\"minWidth\":[1,\"min-width\"],\"panelWidth\":[1,\"panel-width\"],\"hideLabel\":[4,\"hide-label\"],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"required\":[4],\"loading\":[1028],\"options\":[16],\"formatResult\":[16],\"createUrl\":[1,\"create-url\"],\"csrfToken\":[1,\"csrf-token\"],\"csrfHeaderName\":[1,\"csrf-header-name\"],\"isOpen\":[32],\"searchQuery\":[32],\"highlightedIndex\":[32],\"internalOptions\":[32],\"selectedItems\":[32],\"currentPage\":[32],\"hasMore\":[32],\"creating\":[32],\"setFocus\":[64]},[[8,\"keydown\",\"handleWindowKeyDown\"]],{\"debounce\":[\"setupDebounce\"],\"value\":[\"valueChanged\"],\"options\":[\"optionsChanged\"],\"internalOptions\":[\"internalOptionsChanged\"]}]]],[\"pds-combobox.cjs\",[[321,\"pds-combobox\",{\"componentId\":[1,\"component-id\"],\"name\":[513],\"customOptionLayouts\":[4,\"custom-option-layouts\"],\"customTriggerContent\":[4,\"custom-trigger-content\"],\"disabled\":[4],\"dropdownPlacement\":[1,\"dropdown-placement\"],\"dropdownWidth\":[1,\"dropdown-width\"],\"hideLabel\":[4,\"hide-label\"],\"label\":[1],\"maxHeight\":[1,\"max-height\"],\"mode\":[1],\"placeholder\":[1],\"trigger\":[1],\"triggerWidth\":[1,\"trigger-width\"],\"triggerVariant\":[1,\"trigger-variant\"],\"chipSentiment\":[1,\"chip-sentiment\"],\"chipLarge\":[4,\"chip-large\"],\"chipIcon\":[1,\"chip-icon\"],\"chipDot\":[4,\"chip-dot\"],\"value\":[1025],\"asyncUrl\":[1,\"async-url\"],\"asyncMethod\":[1,\"async-method\"],\"debounce\":[2],\"fetchTimeout\":[2,\"fetch-timeout\"],\"loading\":[1028],\"options\":[16],\"formatResult\":[16],\"displayText\":[32],\"filteredItems\":[32],\"highlightedIndex\":[32],\"isOpen\":[32],\"selectedOption\":[32],\"selectedOptionLayoutContent\":[32],\"selectedOptionChipProps\":[32],\"internalOptions\":[32],\"currentPage\":[32],\"hasMore\":[32],\"setFocus\":[64],\"getSelectedValue\":[64]},null,{\"debounce\":[\"setupDebounce\"],\"options\":[\"optionsChanged\"],\"value\":[\"handleValueChange\"],\"selectedOption\":[\"handleSelectedOptionChange\"]}]]],[\"pds-alert.cjs\",[[257,\"pds-alert\",{\"componentId\":[1,\"component-id\"],\"heading\":[1],\"small\":[4],\"dismissible\":[4],\"variant\":[1],\"hasActionsContent\":[32]}]]],[\"pds-copytext.cjs\",[[257,\"pds-copytext\",{\"border\":[516],\"componentId\":[1,\"component-id\"],\"fullWidth\":[4,\"full-width\"],\"truncate\":[4],\"value\":[1]}]]],[\"pds-table-head.cjs\",[[257,\"pds-table-head\",{\"indeterminate\":[1028],\"isSelected\":[1028,\"is-selected\"],\"border\":[516],\"background\":[516]}]]],[\"pds-table-row.cjs\",[[257,\"pds-table-row\",{\"indeterminate\":[1028],\"isSelected\":[1028,\"is-selected\"],\"hasDivider\":[32],\"isLastRow\":[32]}]]],[\"pds-dropdown-menu-item.cjs\",[[257,\"pds-dropdown-menu-item\",{\"componentId\":[1,\"component-id\"],\"destructive\":[4],\"disabled\":[516],\"href\":[1],\"external\":[516],\"target\":[513],\"hasFocus\":[32],\"clickItem\":[64]}]]],[\"pds-property.cjs\",[[257,\"pds-property\",{\"componentId\":[1,\"component-id\"],\"icon\":[1]}]]],[\"pds-accordion.cjs\",[[257,\"pds-accordion\",{\"componentId\":[1,\"component-id\"],\"isOpen\":[1540,\"open\"]},null,{\"isOpen\":[\"handleOpenState\"]}]]],[\"pds-avatar.cjs\",[[257,\"pds-avatar\",{\"alt\":[1],\"badge\":[4],\"componentId\":[1,\"component-id\"],\"dropdown\":[4],\"image\":[1],\"initials\":[1],\"size\":[513],\"variant\":[513]}]]],[\"pds-dropdown-menu.cjs\",[[257,\"pds-dropdown-menu\",{\"componentId\":[1,\"component-id\"],\"placement\":[1],\"currentFocusIndex\":[32]},[[8,\"keydown\",\"handleKeyDown\"],[8,\"click\",\"handleWindowClick\"]]]]],[\"pds-filter.cjs\",[[257,\"pds-filter\",{\"componentId\":[1,\"component-id\"],\"variant\":[1],\"icon\":[1],\"text\":[1],\"isOpen\":[32],\"showFilter\":[64],\"hideFilter\":[64]},[[9,\"resize\",\"handleWindowResize\"],[9,\"scroll\",\"handleWindowScroll\"],[4,\"toggle\",\"handlePopoverToggle\"],[4,\"click\",\"handleDocumentClick\"],[4,\"keydown\",\"handleEscapeKey\"]]]]],[\"pds-input.cjs\",[[321,\"pds-input\",{\"autocomplete\":[1],\"componentId\":[1,\"component-id\"],\"debounce\":[2],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"max\":[1],\"maxlength\":[1],\"min\":[1],\"minlength\":[1],\"name\":[1],\"pattern\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"step\":[1],\"type\":[1],\"value\":[1032],\"fullWidth\":[4,\"full-width\"],\"highlight\":[516],\"hasPrefix\":[32],\"hasSuffix\":[32],\"hasPrepend\":[32],\"hasAppend\":[32],\"hasAction\":[32],\"hasFocus\":[32],\"setFocus\":[64]},null,{\"debounce\":[\"debounceChanged\"],\"value\":[\"valueChanged\"]}]]],[\"pds-radio.cjs\",[[262,\"pds-radio\",{\"checked\":[4],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"hasBorder\":[4,\"has-border\"],\"invalid\":[4],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"name\":[1],\"required\":[4],\"value\":[1],\"_hasImage\":[32]}]]],[\"pds-radio-group.cjs\",[[262,\"pds-radio-group\",{\"componentId\":[1,\"component-id\"],\"direction\":[1],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"gap\":[1],\"disabled\":[4],\"invalid\":[4],\"groupLabel\":[1,\"group-label\"],\"name\":[1],\"required\":[4]},[[0,\"change\",\"handleRadioChange\"]],{\"name\":[\"handlePropsChange\"],\"disabled\":[\"handlePropsChange\"],\"invalid\":[\"handlePropsChange\"],\"required\":[\"handlePropsChange\"]}]]],[\"pds-select.cjs\",[[321,\"pds-select\",{\"autocomplete\":[1],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"hideLabel\":[4,\"hide-label\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"label\":[1],\"multiple\":[4],\"name\":[1],\"required\":[4],\"highlight\":[516],\"value\":[1025]},null,{\"value\":[\"valueChanged\"],\"multiple\":[\"multipleChanged\"]}]]],[\"pds-sortable-item.cjs\",[[262,\"pds-sortable-item\",{\"enableActions\":[4,\"enable-actions\"],\"componentId\":[1,\"component-id\"],\"showHandle\":[1028,\"show-handle\"]}]]],[\"pds-switch.cjs\",[[321,\"pds-switch\",{\"componentId\":[1,\"component-id\"],\"checked\":[1028],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"hideLabel\":[4,\"hide-label\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[4],\"label\":[1],\"name\":[1],\"required\":[4],\"value\":[1]},null,{\"checked\":[\"checkedChanged\"]}]]],[\"pds-textarea.cjs\",[[321,\"pds-textarea\",{\"autocomplete\":[1],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"debounce\":[2],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"invalid\":[1028],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"name\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"rows\":[2],\"maxLength\":[514,\"max-length\"],\"highlight\":[516],\"value\":[1025],\"hasFocus\":[32],\"hasAction\":[32],\"setFocus\":[64]},null,{\"debounce\":[\"debounceChanged\"],\"value\":[\"valueChanged\"],\"maxLength\":[\"maxLengthChanged\"]}]]],[\"pds-toast.cjs\",[[257,\"pds-toast\",{\"componentId\":[1,\"component-id\"],\"dismissible\":[4],\"duration\":[2],\"icon\":[1],\"type\":[1],\"isVisible\":[32],\"isAnimatingOut\":[32],\"dismiss\":[64]},null,{\"duration\":[\"handleDurationChange\"]}]]],[\"mock-pds-modal.cjs\",[[260,\"mock-pds-modal\",{\"componentId\":[1,\"component-id\"],\"size\":[1],\"scrollable\":[4],\"backdropDismiss\":[4,\"backdrop-dismiss\"],\"open\":[1028],\"showModal\":[64],\"hideModal\":[64]}]]],[\"pds-divider.cjs\",[[257,\"pds-divider\",{\"componentId\":[1,\"component-id\"],\"offset\":[1],\"vertical\":[4]}]]],[\"pds-dropdown-menu-separator.cjs\",[[257,\"pds-dropdown-menu-separator\",{\"componentId\":[1,\"component-id\"],\"disabled\":[4]}]]],[\"pds-filters.cjs\",[[257,\"pds-filters\",{\"componentId\":[1,\"component-id\"]}]]],[\"pds-image.cjs\",[[257,\"pds-image\",{\"alt\":[1],\"componentId\":[1,\"component-id\"],\"height\":[2],\"loading\":[1],\"sizes\":[1],\"src\":[1],\"srcset\":[1],\"width\":[2]}]]],[\"pds-modal.cjs\",[[260,\"pds-modal\",{\"backdropDismiss\":[4,\"backdrop-dismiss\"],\"componentId\":[1,\"component-id\"],\"open\":[1028],\"size\":[1],\"scrollable\":[4],\"focusableElementsArray\":[32],\"showModal\":[64],\"hideModal\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"pds-modal-content.cjs\",[[260,\"pds-modal-content\",{\"border\":[1537],\"contentMaxHeight\":[32]}]]],[\"pds-modal-footer.cjs\",[[260,\"pds-modal-footer\"]]],[\"pds-modal-header.cjs\",[[260,\"pds-modal-header\"]]],[\"pds-popover.cjs\",[[257,\"pds-popover\",{\"popoverTargetAction\":[1,\"popover-target-action\"],\"popoverType\":[1,\"popover-type\"],\"componentId\":[1,\"component-id\"],\"maxWidth\":[2,\"max-width\"],\"placement\":[513],\"active\":[32],\"show\":[64],\"hide\":[64],\"toggle\":[64]}]]],[\"pds-progress.cjs\",[[257,\"pds-progress\",{\"animated\":[4],\"componentId\":[1,\"component-id\"],\"fillColor\":[1,\"fill-color\"],\"label\":[1],\"percent\":[2],\"showPercent\":[4,\"show-percent\"]}]]],[\"pds-row.cjs\",[[256,\"pds-row\",{\"alignItems\":[1,\"align-items\"],\"border\":[4],\"colGap\":[1,\"col-gap\"],\"colGapBlock\":[1,\"col-gap-block\"],\"colGapInline\":[1,\"col-gap-inline\"],\"componentId\":[1,\"component-id\"],\"justifyContent\":[1,\"justify-content\"],\"minHeight\":[1,\"min-height\"],\"noWrap\":[4,\"no-wrap\"]}]]],[\"pds-sortable.cjs\",[[262,\"pds-sortable\",{\"border\":[516],\"componentId\":[1,\"component-id\"],\"dividers\":[516],\"handleType\":[1,\"handle-type\"]}]]],[\"pds-tab.cjs\",[[260,\"pds-tab\",{\"disabled\":[4],\"name\":[1],\"parentComponentId\":[1,\"parent-component-id\"],\"variant\":[1],\"index\":[2],\"selected\":[4]}]]],[\"pds-table.cjs\",[[257,\"pds-table\",{\"compact\":[4],\"componentId\":[1,\"component-id\"],\"responsive\":[4],\"fixedColumn\":[4,\"fixed-column\"],\"selectable\":[4],\"rowDividers\":[516,\"row-dividers\"],\"defaultSortColumn\":[1,\"default-sort-column\"],\"defaultSortDirection\":[1,\"default-sort-direction\"],\"sortingColumn\":[32],\"sortingDirection\":[32]},[[0,\"pdsTableSort\",\"handleTableSort\"],[0,\"pdsTableSelectAll\",\"handleTableSelectAll\"],[0,\"pdsTableRowSelected\",\"handleTableSelect\"]]]]],[\"pds-table-body.cjs\",[[257,\"pds-table-body\"]]],[\"pds-tabpanel.cjs\",[[260,\"pds-tabpanel\",{\"name\":[1],\"parentComponentId\":[1,\"parent-component-id\"],\"variant\":[1],\"selected\":[1028]}]]],[\"pds-tabs.cjs\",[[257,\"pds-tabs\",{\"tablistLabel\":[1,\"tablist-label\"],\"componentId\":[1,\"component-id\"],\"variant\":[1],\"activeTabName\":[1025,\"active-tab-name\"],\"activeTabIndex\":[1026,\"active-tab-index\"]},[[16,\"pdsTabClick\",\"tabClickHandler\"],[0,\"keydown\",\"handleKeyDown\"]]]]],[\"pds-tooltip.cjs\",[[260,\"pds-tooltip\",{\"content\":[1],\"componentId\":[1,\"component-id\"],\"hasArrow\":[4,\"has-arrow\"],\"htmlContent\":[4,\"html-content\"],\"placement\":[513],\"maxWidth\":[1,\"max-width\"],\"opened\":[1540],\"_isInteractiveOpen\":[32],\"showTooltip\":[64],\"hideTooltip\":[64]},null,{\"opened\":[\"handleOpenToggle\"]}]]],[\"pds-icon.cjs\",[[257,\"pds-icon\",{\"color\":[1],\"flipRtl\":[4,\"flip-rtl\"],\"icon\":[8],\"name\":[513],\"size\":[513],\"src\":[1],\"ariaLabel\":[32],\"isVisible\":[32],\"svgContent\":[32]},null,{\"size\":[\"updateStyles\"],\"color\":[\"updateStyles\"],\"name\":[\"onIconPropertyChange\"],\"src\":[\"onIconPropertyChange\"],\"icon\":[\"onIconPropertyChange\"]}]]],[\"pds-button.cjs\",[[257,\"pds-button\",{\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"fullWidth\":[4,\"full-width\"],\"href\":[1],\"icon\":[1],\"iconOnly\":[4,\"icon-only\"],\"loading\":[4],\"name\":[1],\"target\":[1],\"type\":[1],\"value\":[1],\"size\":[1],\"variant\":[1]},[[16,\"keydown\",\"handleFormKeyDown\"]]]]],[\"pds-chip.cjs\",[[257,\"pds-chip\",{\"componentId\":[1,\"component-id\"],\"dot\":[4],\"icon\":[1],\"large\":[4],\"sentiment\":[1],\"variant\":[1],\"removeUrl\":[1,\"remove-url\"],\"removeHttpMethod\":[1,\"remove-http-method\"],\"removeTarget\":[1,\"remove-target\"]}]]],[\"pds-link.cjs\",[[257,\"pds-link\",{\"color\":[1],\"componentId\":[1,\"component-id\"],\"external\":[4],\"target\":[1],\"variant\":[1],\"fontSize\":[1,\"font-size\"],\"href\":[1]}]]],[\"pds-table-head-cell.cjs\",[[257,\"pds-table-head-cell\",{\"cellAlign\":[1,\"cell-align\"],\"sortable\":[4],\"sortingDirection\":[32],\"tableScrolling\":[32],\"isSelected\":[32],\"hasHeadBorder\":[32],\"hasHeadBackground\":[32],\"isActive\":[32],\"setActiveSort\":[64],\"clearActiveSort\":[64]}]]],[\"pds-table-cell.cjs\",[[257,\"pds-table-cell\",{\"cellAlign\":[1,\"cell-align\"],\"truncate\":[4],\"tableScrolling\":[32]}]]],[\"pds-text.cjs\",[[257,\"pds-text\",{\"align\":[1],\"color\":[1],\"decoration\":[1],\"gutter\":[1],\"italic\":[4],\"size\":[1],\"weight\":[1],\"tag\":[1],\"truncate\":[516]}]]],[\"pds-checkbox.cjs\",[[321,\"pds-checkbox\",{\"checked\":[1028],\"componentId\":[1,\"component-id\"],\"disabled\":[4],\"errorMessage\":[1,\"error-message\"],\"helperMessage\":[1,\"helper-message\"],\"indeterminate\":[1028],\"invalid\":[4],\"label\":[1],\"hideLabel\":[4,\"hide-label\"],\"name\":[1],\"required\":[4],\"value\":[1]},null,{\"checked\":[\"updateIndeterminate\",\"checkedChanged\"]}]]],[\"pds-loader.cjs\",[[257,\"pds-loader\",{\"isLoading\":[4,\"is-loading\"],\"showLabel\":[4,\"show-label\"],\"size\":[513],\"variant\":[1]}]]],[\"pds-box.cjs\",[[256,\"pds-box\",{\"alignItems\":[1,\"align-items\"],\"alignItemsXs\":[1,\"align-items-xs\"],\"alignItemsSm\":[1,\"align-items-sm\"],\"alignItemsMd\":[1,\"align-items-md\"],\"alignItemsLg\":[1,\"align-items-lg\"],\"alignItemsXl\":[1,\"align-items-xl\"],\"alignSelf\":[1,\"align-self\"],\"alignSelfXs\":[1,\"align-self-xs\"],\"alignSelfSm\":[1,\"align-self-sm\"],\"alignSelfMd\":[1,\"align-self-md\"],\"alignSelfLg\":[1,\"align-self-lg\"],\"alignSelfXl\":[1,\"align-self-xl\"],\"auto\":[4],\"autoXs\":[4,\"auto-xs\"],\"autoSm\":[4,\"auto-sm\"],\"autoMd\":[4,\"auto-md\"],\"autoLg\":[4,\"auto-lg\"],\"autoXl\":[4,\"auto-xl\"],\"backgroundColor\":[1,\"background-color\"],\"border\":[4],\"borderColor\":[1,\"border-color\"],\"borderRadius\":[1,\"border-radius\"],\"direction\":[1],\"display\":[1],\"fit\":[4],\"fitXs\":[4,\"fit-xs\"],\"fitSm\":[4,\"fit-sm\"],\"fitMd\":[4,\"fit-md\"],\"fitLg\":[4,\"fit-lg\"],\"fitXl\":[4,\"fit-xl\"],\"gap\":[1],\"gapXs\":[1,\"gap-xs\"],\"gapSm\":[1,\"gap-sm\"],\"gapMd\":[1,\"gap-md\"],\"gapLg\":[1,\"gap-lg\"],\"gapXl\":[1,\"gap-xl\"],\"wrap\":[4],\"wrapXs\":[4,\"wrap-xs\"],\"wrapSm\":[4,\"wrap-sm\"],\"wrapMd\":[4,\"wrap-md\"],\"wrapLg\":[4,\"wrap-lg\"],\"wrapXl\":[4,\"wrap-xl\"],\"flex\":[1],\"justifyContent\":[1,\"justify-content\"],\"justifyContentXs\":[1,\"justify-content-xs\"],\"justifyContentSm\":[1,\"justify-content-sm\"],\"justifyContentMd\":[1,\"justify-content-md\"],\"justifyContentLg\":[1,\"justify-content-lg\"],\"justifyContentXl\":[1,\"justify-content-xl\"],\"marginBlockStart\":[1,\"margin-block-start\"],\"marginBlockStartXs\":[1,\"margin-block-start-xs\"],\"marginBlockStartSm\":[1,\"margin-block-start-sm\"],\"marginBlockStartMd\":[1,\"margin-block-start-md\"],\"marginBlockStartLg\":[1,\"margin-block-start-lg\"],\"marginBlockStartXl\":[1,\"margin-block-start-xl\"],\"marginInlineStart\":[1,\"margin-inline-start\"],\"marginInlineStartXs\":[1,\"margin-inline-start-xs\"],\"marginInlineStartSm\":[1,\"margin-inline-start-sm\"],\"marginInlineStartMd\":[1,\"margin-inline-start-md\"],\"marginInlineStartLg\":[1,\"margin-inline-start-lg\"],\"marginInlineStartXl\":[1,\"margin-inline-start-xl\"],\"marginInlineEnd\":[1,\"margin-inline-end\"],\"marginInlineEndXs\":[1,\"margin-inline-end-xs\"],\"marginInlineEndSm\":[1,\"margin-inline-end-sm\"],\"marginInlineEndMd\":[1,\"margin-inline-end-md\"],\"marginInlineEndLg\":[1,\"margin-inline-end-lg\"],\"marginInlineEndXl\":[1,\"margin-inline-end-xl\"],\"marginBlockEnd\":[1,\"margin-block-end\"],\"marginBlockEndXs\":[1,\"margin-block-end-xs\"],\"marginBlockEndSm\":[1,\"margin-block-end-sm\"],\"marginBlockEndMd\":[1,\"margin-block-end-md\"],\"marginBlockEndLg\":[1,\"margin-block-end-lg\"],\"marginBlockEndXl\":[1,\"margin-block-end-xl\"],\"minHeight\":[513,\"min-height\"],\"minWidth\":[513,\"min-width\"],\"offset\":[1],\"offsetXs\":[1,\"offset-xs\"],\"offsetSm\":[1,\"offset-sm\"],\"offsetMd\":[1,\"offset-md\"],\"offsetLg\":[1,\"offset-lg\"],\"offsetXl\":[1,\"offset-xl\"],\"padding\":[1],\"paddingXs\":[1,\"padding-xs\"],\"paddingSm\":[1,\"padding-sm\"],\"paddingMd\":[1,\"padding-md\"],\"paddingLg\":[1,\"padding-lg\"],\"paddingXl\":[1,\"padding-xl\"],\"paddingBlockStart\":[1,\"padding-block-start\"],\"paddingBlockStartXs\":[1,\"padding-block-start-xs\"],\"paddingBlockStartSm\":[1,\"padding-block-start-sm\"],\"paddingBlockStartMd\":[1,\"padding-block-start-md\"],\"paddingBlockStartLg\":[1,\"padding-block-start-lg\"],\"paddingBlockStartXl\":[1,\"padding-block-start-xl\"],\"paddingBlockEnd\":[1,\"padding-block-end\"],\"paddingBlockEndXs\":[1,\"padding-block-end-xs\"],\"paddingBlockEndSm\":[1,\"padding-block-end-sm\"],\"paddingBlockEndMd\":[1,\"padding-block-end-md\"],\"paddingBlockEndLg\":[1,\"padding-block-end-lg\"],\"paddingBlockEndXl\":[1,\"padding-block-end-xl\"],\"paddingInlineStart\":[1,\"padding-inline-start\"],\"paddingInlineStartXs\":[1,\"padding-inline-start-xs\"],\"paddingInlineStartSm\":[1,\"padding-inline-start-sm\"],\"paddingInlineStartMd\":[1,\"padding-inline-start-md\"],\"paddingInlineStartLg\":[1,\"padding-inline-start-lg\"],\"paddingInlineStartXl\":[1,\"padding-inline-start-xl\"],\"paddingInlineEnd\":[1,\"padding-inline-end\"],\"paddingInlineEndXs\":[1,\"padding-inline-end-xs\"],\"paddingInlineEndSm\":[1,\"padding-inline-end-sm\"],\"paddingInlineEndMd\":[1,\"padding-inline-end-md\"],\"paddingInlineEndLg\":[1,\"padding-inline-end-lg\"],\"paddingInlineEndXl\":[1,\"padding-inline-end-xl\"],\"shadow\":[1],\"size\":[1],\"sizeXs\":[1,\"size-xs\"],\"sizeSm\":[1,\"size-sm\"],\"sizeMd\":[1,\"size-md\"],\"sizeLg\":[1,\"size-lg\"],\"sizeXl\":[1,\"size-xl\"]}]]]]"), options);
|
|
22
22
|
});
|
|
23
23
|
|
|
24
24
|
exports.setNonce = index.setNonce;
|
|
@@ -143,23 +143,18 @@ export class PdsButton {
|
|
|
143
143
|
}
|
|
144
144
|
return classNames.join(' ');
|
|
145
145
|
}
|
|
146
|
-
hasSlotContent(slotName) {
|
|
147
|
-
const elements = this.el.querySelectorAll(`[slot="${slotName}"]`);
|
|
148
|
-
return elements.length > 0;
|
|
149
|
-
}
|
|
150
146
|
renderStartContent() {
|
|
151
|
-
const hasIcon = this.icon && this.variant !== 'disclosure' && this.variant !== 'filter';
|
|
152
|
-
const hasStartSlot = this.hasSlotContent('start');
|
|
153
147
|
if (this.variant === 'filter') {
|
|
154
148
|
return (h("pds-icon", { class: this.loading ? 'pds-button__icon--hidden' : '', icon: addCircle, part: "icon", "aria-hidden": "true" }));
|
|
155
149
|
}
|
|
156
|
-
|
|
150
|
+
// Deprecated icon prop still takes precedence over start slot
|
|
151
|
+
const hasIcon = this.icon && this.variant !== 'disclosure';
|
|
152
|
+
if (Boolean(hasIcon)) {
|
|
157
153
|
return (h("pds-icon", { class: this.loading ? 'pds-button__icon--hidden' : '', name: this.icon, part: "icon", "aria-hidden": "true" }));
|
|
158
154
|
}
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
}
|
|
162
|
-
return null;
|
|
155
|
+
// Always render the start slot so slotted content is projected reliably.
|
|
156
|
+
// CSS hides the wrapper when no content is slotted (prevents empty gap space).
|
|
157
|
+
return h("span", { class: `pds-button__icon ${this.loading ? 'pds-button__icon--hidden' : ''}` }, h("slot", { name: "start" }));
|
|
163
158
|
}
|
|
164
159
|
renderEndContent() {
|
|
165
160
|
if (this.iconOnly) {
|
|
@@ -168,10 +163,9 @@ export class PdsButton {
|
|
|
168
163
|
if (this.variant === 'disclosure') {
|
|
169
164
|
return (h("pds-icon", { class: this.loading ? 'pds-button__icon--hidden' : '', icon: caretDown, part: "caret", "aria-hidden": "true" }));
|
|
170
165
|
}
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
}
|
|
174
|
-
return null;
|
|
166
|
+
// Always render the end slot so slotted content is projected reliably.
|
|
167
|
+
// CSS hides the wrapper when no content is slotted (prevents empty gap space).
|
|
168
|
+
return h("span", { class: `pds-button__icon ${this.loading ? 'pds-button__icon--hidden' : ''}` }, h("slot", { name: "end" }));
|
|
175
169
|
}
|
|
176
170
|
render() {
|
|
177
171
|
// Common props for both button and anchor elements
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pds-button.js","sourceRoot":"","sources":["../../../../src/components/pds-button/pds-button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAC/F,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAE5D;;;;;;;;;;EAUE;AAOF,MAAM,OAAO,SAAS;IALtB;QAaE;;;WAGG;QACK,aAAQ,GAAI,KAAK,CAAC;QAE1B;;;WAGG;QACK,cAAS,GAAI,KAAK,CAAC;QAQ3B;;;;WAIG;QACK,SAAI,GAAY,IAAI,CAAC;QAE7B;;WAEG;QACK,aAAQ,GAAI,KAAK,CAAC;QAE1B;;;;WAIG;QACK,YAAO,GAAI,KAAK,CAAC;QAazB;;;WAGG;QACK,SAAI,GAAmC,QAAQ,CAAC;QAOxD;;;WAGG;QACK,SAAI,GAAmC,SAAS,CAAC;QAEzD;;;WAGG;QACK,YAAO,GAA2G,SAAS,CAAC;QAyD5H,gBAAW,GAAG,CAAC,EAAS,EAAE,EAAE;YAClC,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;gBACjB,EAAE,CAAC,cAAc,EAAE,CAAC;gBACpB,OAAO;YACT,CAA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,KAAK,EAAC,oBAAoB;gBAC9B,gCAAwB,IAAI,EAAE,IAAI,EAAC,gCAAgC,EAAC,OAAO,EAAC,SAAS,EAAC,WAAW,EAAC,YAAY,iBAEjG,CACR,CACR;YAEA,IAAI,CAAC,gBAAgB,EAAE,CACpB,CACP,CAAC;QAEF,OAAO,CACL,EAAC,IAAI,qBACY,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,EAC5C,EAAE,EAAE,IAAI,CAAC,WAAW,EACpB,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,OAAO,EAAE,IAAI,CAAC,OAAO;YAErB,EAAC,cAAc,oBAAK,UAAU,EAAE,GAC7B,OAAO,CACO,CACZ,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, Host, h, Listen, Prop } from '@stencil/core';\nimport { hasShadowDom } from '../../utils/utils';\n\nimport { caretDown, addCircle } from '@pine-ds/icons/icons';\n\n/**\n * @part button - Exposes the button element for styling.\n * @part button-content - Exposes the button content for styling.\n * @part button-text - Exposes the button text for styling.\n * @part caret - Exposes the caret icon component for styling. Appears only on the disclosure variant.\n * @part icon - Exposes the icon component for styling.\n * @part loader-svg - Exposes the loader SVG element for color customization. Appears only when loading.\n * @slot (default) - Button text.\n * @slot start - Content to display before the button text.\n * @slot end - Content to display after the button text.\n*/\n\n@Component({\n tag: 'pds-button',\n styleUrls: ['pds-button.scss'],\n shadow: true,\n})\nexport class PdsButton {\n @Element() el: HTMLPdsButtonElement;\n\n /**\n * A unique identifier used for the underlying component `id` attribute.\n */\n @Prop() componentId: string;\n\n /**\n * Determines the button's disabled state.\n * @defaultValue false\n */\n @Prop() disabled? = false;\n\n /**\n * Determines if the button should take up the full width of its container.\n * @defaultValue false\n */\n @Prop() fullWidth? = false;\n\n /**\n * If provided, renders the component as an anchor (`<a>`) element instead of a button.\n * When using href, button-specific props (type, name, value, loading) will be ignored.\n */\n @Prop() href?: string;\n\n /**\n * Displays a leading icon in the button. DEPRECATED.\n * @defaultValue null\n * @deprecated Use `start` slot instead.\n */\n @Prop() icon?: string = null;\n\n /**\n * When true, displays only the icon and visually hides the text (keeping it accessible).\n */\n @Prop() iconOnly? = false;\n\n /**\n * Determines if the button is in a loading state.\n * When true, displays a loader and hides the button text.\n * @defaultValue false\n */\n @Prop() loading? = false;\n\n /**\n * Provides the button with a submittable name.\n */\n @Prop() name?: string;\n\n /**\n * Specifies where to open the linked document when href is provided.\n * Only applies when href is set.\n */\n @Prop() target?: '_blank' | '_self' | '_parent' | '_top';\n\n /**\n * Provides button with a type.\n * @defaultValue button\n */\n @Prop() type?: 'button' | 'reset' | 'submit' = 'button';\n\n /**\n * Provides button with a submittable value\n */\n @Prop() value?: string;\n\n /**\n * Sets the size of the button.\n * @defaultValue default\n */\n @Prop() size?: 'default' | 'small' | 'micro' = 'default';\n\n /**\n * Sets the style variant of the button.\n * @defaultValue primary\n */\n @Prop() variant: 'primary' | 'secondary' | 'tertiary' | 'accent' | 'disclosure' | 'destructive' | 'unstyled' | 'filter' = 'primary';\n\n @Event() pdsClick: EventEmitter<Event>;\n\n /**\n * Listen for Enter key presses on form inputs to trigger submit\n */\n @Listen('keydown', { target: 'body' })\n\n handleFormKeyDown(event: KeyboardEvent) {\n // Only handle Enter key for submit buttons that are not disabled\n if (event.key !== 'Enter' || this.type !== 'submit' || this.href || this.disabled) {\n return;\n }\n\n const target = event.target as Element;\n\n // Ensure event.target is an Element with matches method before proceeding\n if (!target || typeof target.matches !== 'function') {\n return;\n }\n const form = this.el.closest('form');\n\n // Check if the Enter key was pressed in a form input within the same form\n if (!form || !target || !form.contains(target)) {\n return;\n }\n\n // Check if target is a form input element (exclude reset buttons)\n const isFormInput = target.matches('input:not([type=\"submit\"]):not([type=\"button\"]):not([type=\"reset\"])') ||\n target.matches('pds-input') ||\n target.matches('pds-select') ||\n target.matches('pds-switch') ||\n target.matches('pds-checkbox') ||\n target.matches('pds-radio');\n\n if (isFormInput) {\n // Find all submit buttons in the form and check their actual properties\n const allSubmitButtons = Array.from(form.querySelectorAll('pds-button, button[type=\"submit\"], input[type=\"submit\"]'));\n const enabledSubmitButtons = allSubmitButtons.filter(button => {\n if (button.tagName.toLowerCase() === 'pds-button') {\n const pdsButton = button as HTMLPdsButtonElement;\n return pdsButton.type === 'submit' && !pdsButton.disabled;\n } else {\n return !button.hasAttribute('disabled');\n }\n });\n\n // Only synthesize click if this button is strictly the first enabled submit button\n if (enabledSubmitButtons.length > 0 && enabledSubmitButtons[0] === this.el) {\n event.preventDefault();\n this.el.click();\n }\n }\n }\n\n\n private handleClick = (ev: Event) => {\n if (this.loading) {\n ev.preventDefault();\n return;\n }\n\n // Prevent form submission for disabled buttons\n if (this.disabled) {\n ev.preventDefault();\n return;\n }\n\n if (!this.href && this.type != 'button') {\n // Handle form submission for Shadow DOM buttons\n if (hasShadowDom(this.el)) {\n const form = this.el.closest('form');\n if (form) {\n ev.preventDefault();\n\n const fakeButton = document.createElement('button');\n fakeButton.type = this.type;\n fakeButton.style.display = 'none';\n form.appendChild(fakeButton);\n fakeButton.click();\n fakeButton.remove();\n }\n }\n }\n this.pdsClick.emit(ev);\n };\n\n private classNames() {\n const classNames = ['pds-button'];\n\n if (this.variant) {\n classNames.push('pds-button--' + this.variant);\n }\n\n if (this.size && this.size !== 'default') {\n classNames.push('pds-button--' + this.size);\n }\n\n if (this.iconOnly) {\n classNames.push('pds-button--icon-only');\n }\n\n if (this.loading) {\n classNames.push('pds-button--loading');\n }\n\n return classNames.join(' ');\n }\n\n private hasSlotContent(slotName: string): boolean {\n const elements = this.el.querySelectorAll(`[slot=\"${slotName}\"]`);\n return elements.length > 0;\n }\n\n private renderStartContent() {\n const hasIcon = this.icon && this.variant !== 'disclosure' && this.variant !== 'filter';\n const hasStartSlot = this.hasSlotContent('start');\n\n if (this.variant === 'filter') {\n return (\n <pds-icon class={this.loading ? 'pds-button__icon--hidden' : ''} icon={addCircle} part=\"icon\" aria-hidden=\"true\"></pds-icon>\n );\n } else if (Boolean(hasIcon)) {\n return (\n <pds-icon class={this.loading ? 'pds-button__icon--hidden' : ''} name={this.icon} part=\"icon\" aria-hidden=\"true\"></pds-icon>\n );\n } else if (Boolean(hasStartSlot)) {\n return <span class={`pds-button__icon ${this.loading ? 'pds-button__icon--hidden' : ''}`}><slot name=\"start\" /></span>;\n }\n\n return null;\n }\n\n private renderEndContent() {\n if (this.iconOnly) {\n return null;\n }\n\n if (this.variant === 'disclosure') {\n return (\n <pds-icon class={this.loading ? 'pds-button__icon--hidden' : ''} icon={caretDown} part=\"caret\" aria-hidden=\"true\"></pds-icon>\n );\n } else if (this.hasSlotContent('end')) {\n return <span class={`pds-button__icon ${this.loading ? 'pds-button__icon--hidden' : ''}`}><slot name=\"end\" /></span>;\n }\n\n return null;\n }\n\n render() {\n // Common props for both button and anchor elements\n const commonProps = {\n class: this.classNames(),\n part: 'button',\n };\n\n const attributes = () => {\n if (this.href) {\n return {\n // Anchor element props\n ...commonProps,\n href: this.disabled ? null : this.href,\n target: this.target,\n };\n }\n\n return {\n // Button element props\n ...commonProps,\n 'aria-busy': this.loading ? 'true' : null,\n 'aria-live': this.loading ? 'polite' : null,\n 'disabled': this.disabled,\n 'name': this.name,\n 'type': this.type,\n 'value': this.value,\n };\n };\n\n const ContentElement = this.href ? 'a' : 'button';\n\n // Hide text when loading or iconOnly is true\n const hideText = this.loading || this.iconOnly;\n\n const content = (\n <div class=\"pds-button__content\" part=\"button-content\">\n {this.renderStartContent()}\n\n <span class={`pds-button__text ${hideText ? 'pds-button__text--hidden' : ''}`} part=\"button-text\">\n <slot />\n </span>\n\n {this.loading && (\n <span class=\"pds-button__loader\">\n <pds-loader is-loading={true} size=\"var(--pine-font-size-body-2xl)\" variant=\"spinner\" exportparts=\"loader-svg\">\n Loading...\n </pds-loader>\n </span>\n )}\n\n {this.renderEndContent()}\n </div>\n );\n\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n id={this.componentId}\n onClick={this.handleClick}\n variant={this.variant}\n >\n <ContentElement {...attributes()}>\n {content}\n </ContentElement>\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pds-button.js","sourceRoot":"","sources":["../../../../src/components/pds-button/pds-button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAC/F,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAE5D;;;;;;;;;;EAUE;AAOF,MAAM,OAAO,SAAS;IALtB;QAaE;;;WAGG;QACK,aAAQ,GAAI,KAAK,CAAC;QAE1B;;;WAGG;QACK,cAAS,GAAI,KAAK,CAAC;QAQ3B;;;;WAIG;QACK,SAAI,GAAY,IAAI,CAAC;QAE7B;;WAEG;QACK,aAAQ,GAAI,KAAK,CAAC;QAE1B;;;;WAIG;QACK,YAAO,GAAI,KAAK,CAAC;QAazB;;;WAGG;QACK,SAAI,GAAmC,QAAQ,CAAC;QAOxD;;;WAGG;QACK,SAAI,GAAmC,SAAS,CAAC;QAEzD;;;WAGG;QACK,YAAO,GAA2G,SAAS,CAAC;QAyD5H,gBAAW,GAAG,CA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C,CAAC,CAAC,IAAI,EAC5C,EAAE,EAAE,IAAI,CAAC,WAAW,EACpB,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,OAAO,EAAE,IAAI,CAAC,OAAO;YAErB,EAAC,cAAc,oBAAK,UAAU,EAAE,GAC7B,OAAO,CACO,CACZ,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, Host, h, Listen, Prop } from '@stencil/core';\nimport { hasShadowDom } from '../../utils/utils';\n\nimport { caretDown, addCircle } from '@pine-ds/icons/icons';\n\n/**\n * @part button - Exposes the button element for styling.\n * @part button-content - Exposes the button content for styling.\n * @part button-text - Exposes the button text for styling.\n * @part caret - Exposes the caret icon component for styling. Appears only on the disclosure variant.\n * @part icon - Exposes the icon component for styling.\n * @part loader-svg - Exposes the loader SVG element for color customization. Appears only when loading.\n * @slot (default) - Button text.\n * @slot start - Content to display before the button text.\n * @slot end - Content to display after the button text.\n*/\n\n@Component({\n tag: 'pds-button',\n styleUrls: ['pds-button.scss'],\n shadow: true,\n})\nexport class PdsButton {\n @Element() el: HTMLPdsButtonElement;\n\n /**\n * A unique identifier used for the underlying component `id` attribute.\n */\n @Prop() componentId: string;\n\n /**\n * Determines the button's disabled state.\n * @defaultValue false\n */\n @Prop() disabled? = false;\n\n /**\n * Determines if the button should take up the full width of its container.\n * @defaultValue false\n */\n @Prop() fullWidth? = false;\n\n /**\n * If provided, renders the component as an anchor (`<a>`) element instead of a button.\n * When using href, button-specific props (type, name, value, loading) will be ignored.\n */\n @Prop() href?: string;\n\n /**\n * Displays a leading icon in the button. DEPRECATED.\n * @defaultValue null\n * @deprecated Use `start` slot instead.\n */\n @Prop() icon?: string = null;\n\n /**\n * When true, displays only the icon and visually hides the text (keeping it accessible).\n */\n @Prop() iconOnly? = false;\n\n /**\n * Determines if the button is in a loading state.\n * When true, displays a loader and hides the button text.\n * @defaultValue false\n */\n @Prop() loading? = false;\n\n /**\n * Provides the button with a submittable name.\n */\n @Prop() name?: string;\n\n /**\n * Specifies where to open the linked document when href is provided.\n * Only applies when href is set.\n */\n @Prop() target?: '_blank' | '_self' | '_parent' | '_top';\n\n /**\n * Provides button with a type.\n * @defaultValue button\n */\n @Prop() type?: 'button' | 'reset' | 'submit' = 'button';\n\n /**\n * Provides button with a submittable value\n */\n @Prop() value?: string;\n\n /**\n * Sets the size of the button.\n * @defaultValue default\n */\n @Prop() size?: 'default' | 'small' | 'micro' = 'default';\n\n /**\n * Sets the style variant of the button.\n * @defaultValue primary\n */\n @Prop() variant: 'primary' | 'secondary' | 'tertiary' | 'accent' | 'disclosure' | 'destructive' | 'unstyled' | 'filter' = 'primary';\n\n @Event() pdsClick: EventEmitter<Event>;\n\n /**\n * Listen for Enter key presses on form inputs to trigger submit\n */\n @Listen('keydown', { target: 'body' })\n\n handleFormKeyDown(event: KeyboardEvent) {\n // Only handle Enter key for submit buttons that are not disabled\n if (event.key !== 'Enter' || this.type !== 'submit' || this.href || this.disabled) {\n return;\n }\n\n const target = event.target as Element;\n\n // Ensure event.target is an Element with matches method before proceeding\n if (!target || typeof target.matches !== 'function') {\n return;\n }\n const form = this.el.closest('form');\n\n // Check if the Enter key was pressed in a form input within the same form\n if (!form || !target || !form.contains(target)) {\n return;\n }\n\n // Check if target is a form input element (exclude reset buttons)\n const isFormInput = target.matches('input:not([type=\"submit\"]):not([type=\"button\"]):not([type=\"reset\"])') ||\n target.matches('pds-input') ||\n target.matches('pds-select') ||\n target.matches('pds-switch') ||\n target.matches('pds-checkbox') ||\n target.matches('pds-radio');\n\n if (isFormInput) {\n // Find all submit buttons in the form and check their actual properties\n const allSubmitButtons = Array.from(form.querySelectorAll('pds-button, button[type=\"submit\"], input[type=\"submit\"]'));\n const enabledSubmitButtons = allSubmitButtons.filter(button => {\n if (button.tagName.toLowerCase() === 'pds-button') {\n const pdsButton = button as HTMLPdsButtonElement;\n return pdsButton.type === 'submit' && !pdsButton.disabled;\n } else {\n return !button.hasAttribute('disabled');\n }\n });\n\n // Only synthesize click if this button is strictly the first enabled submit button\n if (enabledSubmitButtons.length > 0 && enabledSubmitButtons[0] === this.el) {\n event.preventDefault();\n this.el.click();\n }\n }\n }\n\n\n private handleClick = (ev: Event) => {\n if (this.loading) {\n ev.preventDefault();\n return;\n }\n\n // Prevent form submission for disabled buttons\n if (this.disabled) {\n ev.preventDefault();\n return;\n }\n\n if (!this.href && this.type != 'button') {\n // Handle form submission for Shadow DOM buttons\n if (hasShadowDom(this.el)) {\n const form = this.el.closest('form');\n if (form) {\n ev.preventDefault();\n\n const fakeButton = document.createElement('button');\n fakeButton.type = this.type;\n fakeButton.style.display = 'none';\n form.appendChild(fakeButton);\n fakeButton.click();\n fakeButton.remove();\n }\n }\n }\n this.pdsClick.emit(ev);\n };\n\n private classNames() {\n const classNames = ['pds-button'];\n\n if (this.variant) {\n classNames.push('pds-button--' + this.variant);\n }\n\n if (this.size && this.size !== 'default') {\n classNames.push('pds-button--' + this.size);\n }\n\n if (this.iconOnly) {\n classNames.push('pds-button--icon-only');\n }\n\n if (this.loading) {\n classNames.push('pds-button--loading');\n }\n\n return classNames.join(' ');\n }\n\n private renderStartContent() {\n if (this.variant === 'filter') {\n return (\n <pds-icon class={this.loading ? 'pds-button__icon--hidden' : ''} icon={addCircle} part=\"icon\" aria-hidden=\"true\"></pds-icon>\n );\n }\n\n // Deprecated icon prop still takes precedence over start slot\n const hasIcon = this.icon && this.variant !== 'disclosure';\n if (Boolean(hasIcon)) {\n return (\n <pds-icon class={this.loading ? 'pds-button__icon--hidden' : ''} name={this.icon} part=\"icon\" aria-hidden=\"true\"></pds-icon>\n );\n }\n\n // Always render the start slot so slotted content is projected reliably.\n // CSS hides the wrapper when no content is slotted (prevents empty gap space).\n return <span class={`pds-button__icon ${this.loading ? 'pds-button__icon--hidden' : ''}`}><slot name=\"start\" /></span>;\n }\n\n private renderEndContent() {\n if (this.iconOnly) {\n return null;\n }\n\n if (this.variant === 'disclosure') {\n return (\n <pds-icon class={this.loading ? 'pds-button__icon--hidden' : ''} icon={caretDown} part=\"caret\" aria-hidden=\"true\"></pds-icon>\n );\n }\n\n // Always render the end slot so slotted content is projected reliably.\n // CSS hides the wrapper when no content is slotted (prevents empty gap space).\n return <span class={`pds-button__icon ${this.loading ? 'pds-button__icon--hidden' : ''}`}><slot name=\"end\" /></span>;\n }\n\n render() {\n // Common props for both button and anchor elements\n const commonProps = {\n class: this.classNames(),\n part: 'button',\n };\n\n const attributes = () => {\n if (this.href) {\n return {\n // Anchor element props\n ...commonProps,\n href: this.disabled ? null : this.href,\n target: this.target,\n };\n }\n\n return {\n // Button element props\n ...commonProps,\n 'aria-busy': this.loading ? 'true' : null,\n 'aria-live': this.loading ? 'polite' : null,\n 'disabled': this.disabled,\n 'name': this.name,\n 'type': this.type,\n 'value': this.value,\n };\n };\n\n const ContentElement = this.href ? 'a' : 'button';\n\n // Hide text when loading or iconOnly is true\n const hideText = this.loading || this.iconOnly;\n\n const content = (\n <div class=\"pds-button__content\" part=\"button-content\">\n {this.renderStartContent()}\n\n <span class={`pds-button__text ${hideText ? 'pds-button__text--hidden' : ''}`} part=\"button-text\">\n <slot />\n </span>\n\n {this.loading && (\n <span class=\"pds-button__loader\">\n <pds-loader is-loading={true} size=\"var(--pine-font-size-body-2xl)\" variant=\"spinner\" exportparts=\"loader-svg\">\n Loading...\n </pds-loader>\n </span>\n )}\n\n {this.renderEndContent()}\n </div>\n );\n\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n id={this.componentId}\n onClick={this.handleClick}\n variant={this.variant}\n >\n <ContentElement {...attributes()}>\n {content}\n </ContentElement>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -69,7 +69,7 @@ export class PdsDropdownMenuItem {
|
|
|
69
69
|
}, tabIndex: this.disabled ? -1 : 0, type: "button", onKeyDown: this.handleKeyDown, onFocus: this.handleFocus, onBlur: this.handleBlur, disabled: this.disabled, "aria-disabled": this.disabled ? 'true' : null }, h("slot", null)));
|
|
70
70
|
}
|
|
71
71
|
render() {
|
|
72
|
-
return (h(Host, { key: '
|
|
72
|
+
return (h(Host, { key: 'a1a195326721b531676e281f54167d60031af418', id: this.componentId, class: { 'is-disabled': this.disabled, 'destructive': !this.disabled && this.destructive }, onClick: () => !this.disabled && this.handleClick(), role: "none", tabIndex: -1, "aria-disabled": this.disabled ? 'true' : null }, this.renderElement()));
|
|
73
73
|
}
|
|
74
74
|
static get is() { return "pds-dropdown-menu-item"; }
|
|
75
75
|
static get encapsulation() { return "shadow"; }
|
|
@@ -146,7 +146,7 @@ export class PdsDropdownMenuItem {
|
|
|
146
146
|
},
|
|
147
147
|
"getter": false,
|
|
148
148
|
"setter": false,
|
|
149
|
-
"reflect":
|
|
149
|
+
"reflect": true,
|
|
150
150
|
"attribute": "disabled",
|
|
151
151
|
"defaultValue": "false"
|
|
152
152
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pds-dropdown-menu-item.js","sourceRoot":"","sources":["../../../../../src/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAQtG,MAAM,OAAO,mBAAmB;IALhC;QAaE;;;WAGG;QACK,gBAAW,GAAY,KAAK,CAAC;QAErC;;;WAGG;
|
|
1
|
+
{"version":3,"file":"pds-dropdown-menu-item.js","sourceRoot":"","sources":["../../../../../src/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAQtG,MAAM,OAAO,mBAAmB;IALhC;QAaE;;;WAGG;QACK,gBAAW,GAAY,KAAK,CAAC;QAErC;;;WAGG;QACsB,aAAQ,GAAY,KAAK,CAAC;QAQnD;;;;WAIG;QACsB,aAAQ,GAAY,KAAK,CAAC;QA0C1C,aAAQ,GAAY,KAAK,CAAC;QAE3B,gBAAW,GAAG,GAAG,EAAE;YACzB,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC;QACvB,CAAC,CAAA;QAEO,eAAU,GAAG,GAAG,EAAE;YACxB,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;QACxB,CAAC,CAAA;QA2CO,kBAAa,GAAG,CAAC,KAAoB,EAAE,EAAE;YAC/C,yBAAyB;YACzB,IAAI,CAAC,IAAI,CAAC,QAAQ,IAAI,CAAC,KAAK,CAAC,GAAG,KAAK,OAAO,CAAC,EAAE,CAAC;gBAC9C,wDAAwD;gBACxD,oEAAoE;gBACpE,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC;oBACf,KAAK,CAAC,cAAc,EAAE,CAAC;gBACzB,CAAC;gBACD,IAAI,CAAC,WAAW,EAAE,CAAC;YACrB,CAAC;QACH,CAAC,CAAA;KAeF;IAtGC;;OAEG;IAEH,KAAK,CAAC,SAAS;QACb,IAAI,CAAC,WAAW,EAAE,CAAC;IACrB,CAAC;IAAA,CAAC;IAGM,WAAW;;QACjB,qFAAqF;QACrF,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAC,IA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I,CAAC,QAAQ;aAC3B,EACD,QAAQ,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAChC,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,IAAI,CAAC,aAAa,EAC7B,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,MAAM,EAAE,IAAI,CAAC,UAAU,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,mBACR,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI;YAE5C,eAAa,CACN,CACV,CAAC;IACJ,CAAC;IAcD,MAAM;QACJ,OAAO,CACL,EAAC,IAAI,qDAAC,EAAE,EAAE,IAAI,CAAC,WAAW,EACxB,KAAK,EAAE,EAAE,aAAa,EAAE,IAAI,CAAC,QAAQ,EAAE,aAAa,EAAE,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,WAAW,EAAE,EAC1F,OAAO,EAAE,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,WAAW,EAAE,EACnD,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,CAAC,CAAC,mBACG,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,IAEzC,IAAI,CAAC,aAAa,EAAE,CAClB,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, State } from '@stencil/core';\nimport type { BasePdsProps } from '@utils/interfaces';\n\n@Component({\n tag: 'pds-dropdown-menu-item',\n styleUrl: 'pds-dropdown-menu-item.scss',\n shadow: true,\n})\nexport class PdsDropdownMenuItem implements BasePdsProps {\n @Element() host: HTMLPdsDropdownMenuItemElement;\n\n /**\n * A unique identifier used for the underlying component `id` attribute.\n */\n @Prop() componentId: string;\n\n /**\n * It determines whether or not the dropdown-item is destructive.\n * @defaultValue false\n */\n @Prop() destructive: boolean = false;\n\n /**\n * It determines whether or not the dropdown-item is disabled.\n * @defaultValue false\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n\n /**\n * If provided, renders the dropdown-item as an anchor (`<a>`) element instead of a button.\n */\n @Prop() href: string | undefined;\n\n /**\n * Determines whether the link should open in a new tab and display an external icon.\n * This is a simpler alternative to using `target=\"_blank\"` for the common case.\n * @defaultValue false\n */\n @Prop({ reflect: true }) external: boolean = false;\n\n /**\n * Specifies where to open the linked document when href is provided.\n * Takes precedence over the `external` prop if both are set.\n * Only applies when href is set.\n * @defaultValue undefined\n */\n @Prop({ reflect: true }) target?: '_blank' | '_self' | '_parent' | '_top';\n\n /**\n * Emitted when the dropdown-item is clicked.\n *\n */\n @Event() pdsClick: EventEmitter<{itemIndex: number, item: HTMLPdsDropdownMenuItemElement, content: string}>;\n\n /**\n * Trigger the click event\n */\n @Method()\n async clickItem() {\n this.handleClick();\n };\n\n\n private handleClick() {\n // Filter only pds-dropdown-menu-item elements and find the index of the current item\n const menuItems = Array.from(this.host.parentNode.children).filter(\n (child) => child.tagName.toLowerCase() === 'pds-dropdown-menu-item'\n );\n const itemIndex = menuItems.indexOf(this.host);\n\n // Get the text content from the slotted content\n const content = this.host.textContent?.trim() || '';\n\n this.pdsClick.emit({\n itemIndex,\n item: this.host,\n content\n });\n }\n\n @State() hasFocus: boolean = false;\n\n private handleFocus = () => {\n this.hasFocus = true;\n }\n\n private handleBlur = () => {\n this.hasFocus = false;\n }\n\n private renderElement() {\n if (this.href !== undefined) {\n return (\n <pds-link\n href={this.disabled ? null : this.href}\n external={this.external}\n target={this.target}\n class={{\n 'pds-dropdown-menu-item__content': true,\n 'has-focus': this.hasFocus\n }}\n tabIndex={this.disabled ? -1 : 0}\n onKeyDown={this.handleKeyDown}\n onFocus={this.handleFocus}\n onBlur={this.handleBlur}\n aria-disabled={this.disabled ? 'true' : null}\n >\n <slot></slot>\n </pds-link>\n );\n }\n\n return (\n <button\n class={{\n 'pds-dropdown-menu-item__content': true,\n 'has-focus': this.hasFocus\n }}\n tabIndex={this.disabled ? -1 : 0}\n type=\"button\"\n onKeyDown={this.handleKeyDown}\n onFocus={this.handleFocus}\n onBlur={this.handleBlur}\n disabled={this.disabled}\n aria-disabled={this.disabled ? 'true' : null}\n >\n <slot></slot>\n </button>\n );\n }\n\n private handleKeyDown = (event: KeyboardEvent) => {\n // Handle keyboard events\n if (!this.disabled && (event.key === 'Enter')) {\n // Only prevent default for button elements or Space key\n // For links with Enter key, we want the default navigation behavior\n if (!this.href) {\n event.preventDefault();\n }\n this.handleClick();\n }\n }\n\n render() {\n return (\n <Host id={this.componentId}\n class={{ 'is-disabled': this.disabled, 'destructive': !this.disabled && this.destructive }}\n onClick={() => !this.disabled && this.handleClick()}\n role=\"none\"\n tabIndex={-1}\n aria-disabled={this.disabled ? 'true' : null}\n >\n {this.renderElement()}\n </Host>\n );\n }\n}\n"]}
|
|
@@ -25,16 +25,16 @@
|
|
|
25
25
|
appearance: none;
|
|
26
26
|
background: transparent;
|
|
27
27
|
border: 0;
|
|
28
|
-
border-radius: var(--pine-dimension-xs);
|
|
28
|
+
border-radius: var(--pine-dimension-xs) !important;
|
|
29
29
|
box-sizing: border-box;
|
|
30
30
|
color: var(--pine-color-text) !important;
|
|
31
31
|
cursor: pointer;
|
|
32
32
|
display: flex;
|
|
33
33
|
flex-grow: 1;
|
|
34
|
-
font: var(--pine-typography-body-medium);
|
|
34
|
+
font: var(--pine-typography-body-medium) !important;
|
|
35
35
|
gap: var(--pine-dimension-xs);
|
|
36
|
-
margin: calc(var(--pine-border-width) + 2px);
|
|
37
|
-
padding: var(--pine-dimension-xs);
|
|
36
|
+
margin: calc(var(--pine-border-width) + 2px) !important;
|
|
37
|
+
padding: var(--pine-dimension-xs) !important;
|
|
38
38
|
text-align: start;
|
|
39
39
|
text-decoration: none !important;
|
|
40
40
|
width: calc(100% - (var(--pine-border-width) + 2px) * 2);
|
|
@@ -34,6 +34,8 @@ export const isRequired = (target, component) => {
|
|
|
34
34
|
* @param type - The type value (string literal) or a getter function that returns the type
|
|
35
35
|
*/
|
|
36
36
|
export function exposeTypeProperty(element, type) {
|
|
37
|
+
if (Object.getOwnPropertyDescriptor(element, 'type'))
|
|
38
|
+
return;
|
|
37
39
|
Object.defineProperty(element, 'type', {
|
|
38
40
|
get: typeof type === 'function' ? type : () => type,
|
|
39
41
|
enumerable: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"form.js","sourceRoot":"","sources":["../../../src/utils/form.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,EAAU,EAAE,WAAmB,EAAE,EAAE;IAC3D,OAAO,GAAG,EAAE,KAAK,WAAW,UAAU,CAAC;AACzC,CAAC,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,EAAU,EAAE,OAAgB,EAAE,aAAqB,EAAE,EAAE;IACvF,IAAI,CAAC,aAAa;QAAE,OAAM;IAE1B,IAAI,SAAS,GAAG,SAAS,CAAC,EAAE,EAAE,QAAQ,CAAC,CAAA;IAEvC,IAAI,OAAO;QAAE,SAAS,GAAG,SAAS,CAAC,EAAE,EAAE,OAAO,CAAC,CAAC;IAEhD,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,EAAE;IAC9C,IAAK,CAAC,MAAM,IAAI,CAAC,SAAS;QAAG,OAAO;IACpC,IAAI,SAAS,CAAC,QAAQ,KAAK,IAAI,EAAE,CAAC;QAChC,CAAC,MAAM,CAAC,aAAa,EAAE,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,OAAO,GAAG,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,OAAO,GAAG,KAAK,CAAC;IAC5F,CAAC;AACH,CAAC,CAAA;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,kBAAkB,CAAC,OAAgB,EAAE,IAA6B;IAChF,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE;QACrC,GAAG,EAAE,OAAO,IAAI,KAAK,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC,IAAI;QACnD,UAAU,EAAE,IAAI;QAChB,YAAY,EAAE,KAAK;KACpB,CAAC,CAAC;AACL,CAAC","sourcesContent":["/**\n * Create id for messaging\n */\nexport const messageId = (id: string, messageType: string) => {\n return `${id}__${messageType}-message`;\n};\n\n/**\n * Assign aria-description id to relate messages with form element\n */\nexport const assignDescription = (id: string, invalid: boolean, helperMessage: string) => {\n if (!helperMessage) return\n\n let relatedId = messageId(id, 'helper')\n\n if (invalid) relatedId = messageId(id, 'error');\n\n return relatedId;\n};\n\n/**\n * Updates the `invalid` prop of a form element based on it's values validity\n */\nexport const isRequired = (target, component) => {\n if ( !target || !component ) return;\n if (component.required === true) {\n (target.checkValidity() === false) ? component.invalid = true : component.invalid = false;\n }\n}\n\n/**\n * Exposes a readonly type property on a custom form element to match native form element behavior.\n * This makes the type property enumerable and accessible via element.type, matching native HTML elements.\n * The property is non-configurable, preventing it from being redefined or deleted at runtime.\n *\n * @param element - The custom element to add the type property to\n * @param type - The type value (string literal) or a getter function that returns the type\n */\nexport function exposeTypeProperty(element: Element, type: string | (() => string)) {\n Object.defineProperty(element, 'type', {\n get: typeof type === 'function' ? type : () => type,\n enumerable: true,\n configurable: false\n });\n}\n"]}
|
|
1
|
+
{"version":3,"file":"form.js","sourceRoot":"","sources":["../../../src/utils/form.ts"],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KACpB,CAAC,CAAC;AACL,CAAC","sourcesContent":["/**\n * Create id for messaging\n */\nexport const messageId = (id: string, messageType: string) => {\n return `${id}__${messageType}-message`;\n};\n\n/**\n * Assign aria-description id to relate messages with form element\n */\nexport const assignDescription = (id: string, invalid: boolean, helperMessage: string) => {\n if (!helperMessage) return\n\n let relatedId = messageId(id, 'helper')\n\n if (invalid) relatedId = messageId(id, 'error');\n\n return relatedId;\n};\n\n/**\n * Updates the `invalid` prop of a form element based on it's values validity\n */\nexport const isRequired = (target, component) => {\n if ( !target || !component ) return;\n if (component.required === true) {\n (target.checkValidity() === false) ? component.invalid = true : component.invalid = false;\n }\n}\n\n/**\n * Exposes a readonly type property on a custom form element to match native form element behavior.\n * This makes the type property enumerable and accessible via element.type, matching native HTML elements.\n * The property is non-configurable, preventing it from being redefined or deleted at runtime.\n *\n * @param element - The custom element to add the type property to\n * @param type - The type value (string literal) or a getter function that returns the type\n */\nexport function exposeTypeProperty(element: Element, type: string | (() => string)) {\n if (Object.getOwnPropertyDescriptor(element, 'type')) return;\n\n Object.defineProperty(element, 'type', {\n get: typeof type === 'function' ? type : () => type,\n enumerable: true,\n configurable: false\n });\n}\n"]}
|
package/dist/docs.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "2026-02-
|
|
2
|
+
"timestamp": "2026-02-10T20:18:26",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "@stencil/core",
|
|
5
5
|
"version": "4.38.3",
|
|
@@ -14327,7 +14327,7 @@
|
|
|
14327
14327
|
},
|
|
14328
14328
|
"mutable": false,
|
|
14329
14329
|
"attr": "disabled",
|
|
14330
|
-
"reflectToAttr":
|
|
14330
|
+
"reflectToAttr": true,
|
|
14331
14331
|
"docs": "It determines whether or not the dropdown-item is disabled.",
|
|
14332
14332
|
"docsTags": [
|
|
14333
14333
|
{
|
|
@@ -34,6 +34,8 @@ const isRequired = (target, component) => {
|
|
|
34
34
|
* @param type - The type value (string literal) or a getter function that returns the type
|
|
35
35
|
*/
|
|
36
36
|
function exposeTypeProperty(element, type) {
|
|
37
|
+
if (Object.getOwnPropertyDescriptor(element, 'type'))
|
|
38
|
+
return;
|
|
37
39
|
Object.defineProperty(element, 'type', {
|
|
38
40
|
get: typeof type === 'function' ? type : () => type,
|
|
39
41
|
enumerable: true,
|
|
@@ -42,6 +44,6 @@ function exposeTypeProperty(element, type) {
|
|
|
42
44
|
}
|
|
43
45
|
|
|
44
46
|
export { assignDescription as a, exposeTypeProperty as e, isRequired as i, messageId as m };
|
|
45
|
-
//# sourceMappingURL=form-
|
|
47
|
+
//# sourceMappingURL=form-CN-lL5QG.js.map
|
|
46
48
|
|
|
47
|
-
//# sourceMappingURL=form-
|
|
49
|
+
//# sourceMappingURL=form-CN-lL5QG.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"form-
|
|
1
|
+
{"version":3,"file":"form-CN-lL5QG.js","sources":["src/utils/form.ts"],"sourcesContent":["/**\n * Create id for messaging\n */\nexport const messageId = (id: string, messageType: string) => {\n return `${id}__${messageType}-message`;\n};\n\n/**\n * Assign aria-description id to relate messages with form element\n */\nexport const assignDescription = (id: string, invalid: boolean, helperMessage: string) => {\n if (!helperMessage) return\n\n let relatedId = messageId(id, 'helper')\n\n if (invalid) relatedId = messageId(id, 'error');\n\n return relatedId;\n};\n\n/**\n * Updates the `invalid` prop of a form element based on it's values validity\n */\nexport const isRequired = (target, component) => {\n if ( !target || !component ) return;\n if (component.required === true) {\n (target.checkValidity() === false) ? component.invalid = true : component.invalid = false;\n }\n}\n\n/**\n * Exposes a readonly type property on a custom form element to match native form element behavior.\n * This makes the type property enumerable and accessible via element.type, matching native HTML elements.\n * The property is non-configurable, preventing it from being redefined or deleted at runtime.\n *\n * @param element - The custom element to add the type property to\n * @param type - The type value (string literal) or a getter function that returns the type\n */\nexport function exposeTypeProperty(element: Element, type: string | (() => string)) {\n if (Object.getOwnPropertyDescriptor(element, 'type')) return;\n\n Object.defineProperty(element, 'type', {\n get: typeof type === 'function' ? type : () => type,\n enumerable: true,\n configurable: false\n });\n}\n"],"names":[],"mappings":"AAAA;;AAEG;MACU,SAAS,GAAG,CAAC,EAAU,EAAE,WAAmB,KAAI;AAC3D,IAAA,OAAO,CAAG,EAAA,EAAE,CAAK,EAAA,EAAA,WAAW,UAAU;AACxC;AAEA;;AAEG;AACU,MAAA,iBAAiB,GAAG,CAAC,EAAU,EAAE,OAAgB,EAAE,aAAqB,KAAI;AACvF,IAAA,IAAI,CAAC,aAAa;QAAE;IAEpB,IAAI,SAAS,GAAG,SAAS,CAAC,EAAE,EAAE,QAAQ,CAAC;AAEvC,IAAA,IAAI,OAAO;AAAE,QAAA,SAAS,GAAG,SAAS,CAAC,EAAE,EAAE,OAAO,CAAC;AAE/C,IAAA,OAAO,SAAS;AAClB;AAEA;;AAEG;MACU,UAAU,GAAG,CAAC,MAAM,EAAE,SAAS,KAAI;AAC9C,IAAA,IAAK,CAAC,MAAM,IAAI,CAAC,SAAS;QAAG;AAC7B,IAAA,IAAI,SAAS,CAAC,QAAQ,KAAK,IAAI,EAAE;QAC/B,CAAC,MAAM,CAAC,aAAa,EAAE,KAAK,KAAK,IAAI,SAAS,CAAC,OAAO,GAAG,IAAI,GAAG,SAAS,CAAC,OAAO,GAAG,KAAK;;AAE7F;AAEA;;;;;;;AAOG;AACa,SAAA,kBAAkB,CAAC,OAAgB,EAAE,IAA6B,EAAA;AAChF,IAAA,IAAI,MAAM,CAAC,wBAAwB,CAAC,OAAO,EAAE,MAAM,CAAC;QAAE;AAEtD,IAAA,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE;AACrC,QAAA,GAAG,EAAE,OAAO,IAAI,KAAK,UAAU,GAAG,IAAI,GAAG,MAAM,IAAI;AACnD,QAAA,UAAU,EAAE,IAAI;AAChB,QAAA,YAAY,EAAE;AACf,KAAA,CAAC;AACJ;;;;"}
|