@pine-ds/core 2.16.2 → 2.16.4
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/index2.js +2 -2
- package/components/index2.js.map +1 -1
- package/components/pds-box.js +1 -1
- package/components/pds-box.js.map +1 -1
- package/components/pds-button2.js +25 -5
- package/components/pds-button2.js.map +1 -1
- package/components/pds-checkbox2.js +4 -5
- package/components/pds-checkbox2.js.map +1 -1
- package/components/pds-chip.js +3 -3
- package/components/pds-chip.js.map +1 -1
- package/components/pds-copytext.js +11 -5
- package/components/pds-copytext.js.map +1 -1
- package/components/pds-divider.js +1 -1
- package/components/pds-icon2.js +2 -2
- package/components/pds-icon2.js.map +1 -1
- package/components/pds-image.js +2 -2
- package/components/pds-input.js +12 -4
- package/components/pds-input.js.map +1 -1
- package/components/pds-link.js +2 -2
- package/components/pds-loader.js +1 -61
- package/components/pds-loader.js.map +1 -1
- package/components/pds-loader2.js +65 -0
- package/components/pds-loader2.js.map +1 -0
- package/components/pds-popover.js +2 -2
- package/components/pds-popover.js.map +1 -1
- package/components/pds-progress.js +1 -1
- package/components/pds-radio.js +4 -5
- package/components/pds-radio.js.map +1 -1
- package/components/pds-row.js +2 -2
- package/components/pds-row.js.map +1 -1
- package/components/pds-select.js +3 -3
- package/components/pds-select.js.map +1 -1
- package/components/pds-sortable-item.js +1 -1
- package/components/pds-sortable.js +1 -1
- package/components/pds-switch.js +10 -5
- package/components/pds-switch.js.map +1 -1
- package/components/pds-tab.js +4 -4
- package/components/pds-tab.js.map +1 -1
- package/components/pds-table-body.js +1 -1
- package/components/pds-table-cell2.js +2 -2
- package/components/pds-table-head-cell2.js +2 -2
- package/components/pds-table-head.js +1 -1
- package/components/pds-table-row.js +1 -1
- package/components/pds-table.js +1 -1
- package/components/pds-tabpanel.js +1 -1
- package/components/pds-tabs.js +2 -2
- package/components/pds-tabs.js.map +1 -1
- package/components/pds-text.js +1 -1
- package/components/pds-textarea.js +4 -4
- package/components/pds-tooltip.js +2 -2
- package/dist/cjs/{index-034a8bb0.js → index-603f98cb.js} +3 -3
- package/dist/cjs/index-603f98cb.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/pds-accordion.cjs.entry.js +1 -1
- package/dist/cjs/pds-avatar.cjs.entry.js +1 -1
- package/dist/cjs/pds-box.cjs.entry.js +1 -1
- package/dist/cjs/pds-box.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-button.cjs.entry.js +16 -4
- package/dist/cjs/pds-button.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-checkbox.cjs.entry.js +5 -6
- package/dist/cjs/pds-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-chip.cjs.entry.js +4 -4
- package/dist/cjs/pds-chip.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-copytext.cjs.entry.js +2 -2
- package/dist/cjs/pds-divider.cjs.entry.js +1 -1
- package/dist/cjs/pds-icon.cjs.entry.js +2 -2
- package/dist/cjs/pds-icon.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-image.cjs.entry.js +2 -2
- package/dist/cjs/pds-input.cjs.entry.js +13 -5
- package/dist/cjs/pds-input.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-link.cjs.entry.js +3 -3
- package/dist/cjs/pds-loader.cjs.entry.js +2 -2
- package/dist/cjs/pds-loader.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-popover.cjs.entry.js +2 -2
- package/dist/cjs/pds-popover.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-progress.cjs.entry.js +1 -1
- package/dist/cjs/pds-radio.cjs.entry.js +5 -6
- package/dist/cjs/pds-radio.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-row.cjs.entry.js +2 -2
- package/dist/cjs/pds-row.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-select.cjs.entry.js +4 -4
- package/dist/cjs/pds-select.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-sortable-item.cjs.entry.js +2 -2
- package/dist/cjs/pds-sortable.cjs.entry.js +1 -1
- package/dist/cjs/pds-switch.cjs.entry.js +10 -5
- package/dist/cjs/pds-switch.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-tab.cjs.entry.js +4 -4
- package/dist/cjs/pds-tab.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-table-body.cjs.entry.js +1 -1
- package/dist/cjs/pds-table-cell.cjs.entry.js +2 -2
- package/dist/cjs/pds-table-head-cell.cjs.entry.js +3 -3
- package/dist/cjs/pds-table-head.cjs.entry.js +1 -1
- package/dist/cjs/pds-table-row.cjs.entry.js +1 -1
- package/dist/cjs/pds-table.cjs.entry.js +1 -1
- package/dist/cjs/pds-tabpanel.cjs.entry.js +1 -1
- package/dist/cjs/pds-tabs.cjs.entry.js +2 -2
- package/dist/cjs/pds-tabs.cjs.entry.js.map +1 -1
- package/dist/cjs/pds-text.cjs.entry.js +1 -1
- package/dist/cjs/pds-textarea.cjs.entry.js +5 -5
- package/dist/cjs/pds-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/pine-core.cjs.js +1 -1
- package/dist/collection/components/pds-box/pds-box.css +10 -9
- package/dist/collection/components/pds-button/pds-button.css +56 -3
- package/dist/collection/components/pds-button/pds-button.js +56 -2
- package/dist/collection/components/pds-button/pds-button.js.map +1 -1
- package/dist/collection/components/pds-button/stories/pds-button.stories.js +32 -0
- package/dist/collection/components/pds-checkbox/pds-checkbox.css +7 -4
- package/dist/collection/components/pds-checkbox/pds-checkbox.js +3 -4
- package/dist/collection/components/pds-checkbox/pds-checkbox.js.map +1 -1
- package/dist/collection/components/pds-chip/pds-chip.css +1 -1
- package/dist/collection/components/pds-chip/pds-chip.js +1 -1
- package/dist/collection/components/pds-chip/pds-chip.tokens.css +17 -17
- package/dist/collection/components/pds-copytext/pds-copytext.js +1 -1
- package/dist/collection/components/pds-divider/pds-divider.js +1 -1
- package/dist/collection/components/pds-image/pds-image.js +2 -2
- package/dist/collection/components/pds-input/pds-input.css +22 -19
- package/dist/collection/components/pds-input/pds-input.js +12 -4
- package/dist/collection/components/pds-input/pds-input.js.map +1 -1
- package/dist/collection/components/pds-link/pds-link.js +2 -2
- package/dist/collection/components/pds-loader/pds-loader.css +2 -2
- package/dist/collection/components/pds-loader/pds-loader.js +1 -1
- package/dist/collection/components/pds-popover/pds-popover.css +1 -1
- package/dist/collection/components/pds-popover/pds-popover.js +1 -1
- package/dist/collection/components/pds-progress/pds-progress.js +1 -1
- package/dist/collection/components/pds-radio/pds-radio.css +6 -2
- package/dist/collection/components/pds-radio/pds-radio.js +3 -4
- package/dist/collection/components/pds-radio/pds-radio.js.map +1 -1
- package/dist/collection/components/pds-row/pds-row.css +2 -2
- package/dist/collection/components/pds-row/pds-row.js +1 -1
- package/dist/collection/components/pds-select/pds-select.css +3 -2
- package/dist/collection/components/pds-select/pds-select.js +3 -3
- package/dist/collection/components/pds-select/pds-select.js.map +1 -1
- package/dist/collection/components/pds-sortable/pds-sortable-item/pds-sortable-item.js +1 -1
- package/dist/collection/components/pds-sortable/pds-sortable.js +1 -1
- package/dist/collection/components/pds-switch/pds-switch.js +3 -3
- package/dist/collection/components/pds-table/pds-table-body/pds-table-body.js +1 -1
- package/dist/collection/components/pds-table/pds-table-cell/pds-table-cell.js +2 -2
- package/dist/collection/components/pds-table/pds-table-head/pds-table-head.js +1 -1
- package/dist/collection/components/pds-table/pds-table-head-cell/pds-table-head-cell.js +2 -2
- package/dist/collection/components/pds-table/pds-table-row/pds-table-row.js +1 -1
- package/dist/collection/components/pds-table/pds-table.js +1 -1
- package/dist/collection/components/pds-tabs/pds-tab/pds-tab.css +7 -2
- package/dist/collection/components/pds-tabs/pds-tab/pds-tab.js +3 -3
- package/dist/collection/components/pds-tabs/pds-tabpanel/pds-tabpanel.js +1 -1
- package/dist/collection/components/pds-tabs/pds-tabs.css +1 -0
- package/dist/collection/components/pds-tabs/pds-tabs.js +1 -1
- package/dist/collection/components/pds-text/pds-text.js +1 -1
- package/dist/collection/components/pds-textarea/pds-textarea.js +4 -4
- package/dist/collection/components/pds-tooltip/pds-tooltip.js +2 -2
- package/dist/docs.json +71 -8
- package/dist/esm/{index-d320cfa9.js → index-858623fe.js} +3 -3
- package/dist/esm/index-858623fe.js.map +1 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/pds-accordion.entry.js +1 -1
- package/dist/esm/pds-avatar.entry.js +1 -1
- package/dist/esm/pds-box.entry.js +1 -1
- package/dist/esm/pds-box.entry.js.map +1 -1
- package/dist/esm/pds-button.entry.js +16 -4
- package/dist/esm/pds-button.entry.js.map +1 -1
- package/dist/esm/pds-checkbox.entry.js +5 -6
- package/dist/esm/pds-checkbox.entry.js.map +1 -1
- package/dist/esm/pds-chip.entry.js +4 -4
- package/dist/esm/pds-chip.entry.js.map +1 -1
- package/dist/esm/pds-copytext.entry.js +2 -2
- package/dist/esm/pds-divider.entry.js +1 -1
- package/dist/esm/pds-icon.entry.js +2 -2
- package/dist/esm/pds-icon.entry.js.map +1 -1
- package/dist/esm/pds-image.entry.js +2 -2
- package/dist/esm/pds-input.entry.js +13 -5
- package/dist/esm/pds-input.entry.js.map +1 -1
- package/dist/esm/pds-link.entry.js +3 -3
- package/dist/esm/pds-loader.entry.js +2 -2
- package/dist/esm/pds-loader.entry.js.map +1 -1
- package/dist/esm/pds-popover.entry.js +2 -2
- package/dist/esm/pds-popover.entry.js.map +1 -1
- package/dist/esm/pds-progress.entry.js +1 -1
- package/dist/esm/pds-radio.entry.js +5 -6
- package/dist/esm/pds-radio.entry.js.map +1 -1
- package/dist/esm/pds-row.entry.js +2 -2
- package/dist/esm/pds-row.entry.js.map +1 -1
- package/dist/esm/pds-select.entry.js +4 -4
- package/dist/esm/pds-select.entry.js.map +1 -1
- package/dist/esm/pds-sortable-item.entry.js +2 -2
- package/dist/esm/pds-sortable.entry.js +1 -1
- package/dist/esm/pds-switch.entry.js +11 -6
- package/dist/esm/pds-switch.entry.js.map +1 -1
- package/dist/esm/pds-tab.entry.js +4 -4
- package/dist/esm/pds-tab.entry.js.map +1 -1
- package/dist/esm/pds-table-body.entry.js +1 -1
- package/dist/esm/pds-table-cell.entry.js +2 -2
- package/dist/esm/pds-table-head-cell.entry.js +3 -3
- package/dist/esm/pds-table-head.entry.js +1 -1
- package/dist/esm/pds-table-row.entry.js +1 -1
- package/dist/esm/pds-table.entry.js +1 -1
- package/dist/esm/pds-tabpanel.entry.js +1 -1
- package/dist/esm/pds-tabs.entry.js +2 -2
- package/dist/esm/pds-tabs.entry.js.map +1 -1
- package/dist/esm/pds-text.entry.js +1 -1
- package/dist/esm/pds-textarea.entry.js +5 -5
- package/dist/esm/pds-tooltip.entry.js +2 -2
- package/dist/esm/pine-core.js +1 -1
- package/dist/esm-es5/{index-d320cfa9.js → index-858623fe.js} +2 -2
- package/dist/esm-es5/index-858623fe.js.map +1 -0
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/loader.js.map +1 -1
- package/dist/esm-es5/pds-accordion.entry.js +1 -1
- package/dist/esm-es5/pds-avatar.entry.js +1 -1
- package/dist/esm-es5/pds-box.entry.js +1 -1
- package/dist/esm-es5/pds-box.entry.js.map +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-checkbox.entry.js.map +1 -1
- package/dist/esm-es5/pds-chip.entry.js +1 -1
- package/dist/esm-es5/pds-chip.entry.js.map +1 -1
- package/dist/esm-es5/pds-copytext.entry.js +1 -1
- package/dist/esm-es5/pds-divider.entry.js +1 -1
- package/dist/esm-es5/pds-icon.entry.js.map +1 -1
- package/dist/esm-es5/pds-image.entry.js +1 -1
- package/dist/esm-es5/pds-input.entry.js +1 -1
- package/dist/esm-es5/pds-input.entry.js.map +1 -1
- package/dist/esm-es5/pds-link.entry.js +1 -1
- package/dist/esm-es5/pds-loader.entry.js +1 -1
- package/dist/esm-es5/pds-loader.entry.js.map +1 -1
- package/dist/esm-es5/pds-popover.entry.js +1 -1
- package/dist/esm-es5/pds-popover.entry.js.map +1 -1
- package/dist/esm-es5/pds-progress.entry.js +1 -1
- package/dist/esm-es5/pds-radio.entry.js +1 -1
- package/dist/esm-es5/pds-radio.entry.js.map +1 -1
- package/dist/esm-es5/pds-row.entry.js +1 -1
- package/dist/esm-es5/pds-row.entry.js.map +1 -1
- package/dist/esm-es5/pds-select.entry.js +1 -1
- package/dist/esm-es5/pds-select.entry.js.map +1 -1
- package/dist/esm-es5/pds-sortable-item.entry.js +1 -1
- package/dist/esm-es5/pds-sortable.entry.js +1 -1
- package/dist/esm-es5/pds-switch.entry.js +1 -1
- package/dist/esm-es5/pds-switch.entry.js.map +1 -1
- package/dist/esm-es5/pds-tab.entry.js +1 -1
- package/dist/esm-es5/pds-tab.entry.js.map +1 -1
- package/dist/esm-es5/pds-table-body.entry.js +1 -1
- package/dist/esm-es5/pds-table-cell.entry.js +1 -1
- package/dist/esm-es5/pds-table-head-cell.entry.js +1 -1
- package/dist/esm-es5/pds-table-head.entry.js +1 -1
- package/dist/esm-es5/pds-table-row.entry.js +1 -1
- package/dist/esm-es5/pds-table.entry.js +1 -1
- package/dist/esm-es5/pds-tabpanel.entry.js +1 -1
- package/dist/esm-es5/pds-tabs.entry.js +1 -1
- package/dist/esm-es5/pds-tabs.entry.js.map +1 -1
- package/dist/esm-es5/pds-text.entry.js +1 -1
- package/dist/esm-es5/pds-textarea.entry.js +1 -1
- package/dist/esm-es5/pds-tooltip.entry.js +1 -1
- package/dist/esm-es5/pine-core.js +1 -1
- package/dist/esm-es5/pine-core.js.map +1 -1
- package/dist/pine-core/p-0399a821.entry.js +2 -0
- package/dist/pine-core/p-0399a821.entry.js.map +1 -0
- package/dist/pine-core/p-03e4027f.system.entry.js +2 -0
- package/dist/pine-core/p-03e4027f.system.entry.js.map +1 -0
- package/dist/pine-core/{p-8c07ed73.system.entry.js → p-04fb06cd.system.entry.js} +2 -2
- package/dist/pine-core/{p-c68362cc.entry.js → p-0ad21851.entry.js} +2 -2
- package/dist/pine-core/{p-8420594c.system.entry.js → p-0c68a8ea.system.entry.js} +2 -2
- package/dist/pine-core/{p-8b2db323.system.entry.js → p-10caa9e9.system.entry.js} +2 -2
- package/dist/pine-core/{p-f182a1f2.system.entry.js → p-137aebf6.system.entry.js} +2 -2
- package/dist/pine-core/{p-5e50a381.entry.js → p-138ef0d8.entry.js} +2 -2
- package/dist/pine-core/p-13bc1706.entry.js +2 -0
- package/dist/pine-core/{p-7257c948.entry.js.map → p-13bc1706.entry.js.map} +1 -1
- package/dist/pine-core/{p-d8260ebf.system.entry.js → p-21c441f2.system.entry.js} +2 -2
- package/dist/pine-core/p-21dc34b7.system.entry.js +2 -0
- package/dist/pine-core/p-21dc34b7.system.entry.js.map +1 -0
- package/dist/pine-core/p-2583c14d.entry.js +2 -0
- package/dist/pine-core/p-2583c14d.entry.js.map +1 -0
- package/dist/pine-core/{p-d561168e.js → p-2f60d558.js} +2 -2
- package/dist/pine-core/p-2f60d558.js.map +1 -0
- package/dist/pine-core/{p-e890c1bb.system.entry.js → p-2f80836e.system.entry.js} +2 -2
- package/dist/pine-core/p-3c6a0b2a.system.entry.js.map +1 -1
- package/dist/pine-core/{p-e39bd4b2.system.entry.js → p-3de0ec6c.system.entry.js} +2 -2
- package/dist/pine-core/{p-df73ebae.entry.js → p-3f256ba6.entry.js} +2 -2
- package/dist/pine-core/{p-d6a5ec65.system.entry.js → p-4158fa20.system.entry.js} +2 -2
- package/dist/pine-core/{p-92bcb091.entry.js → p-518f8204.entry.js} +2 -2
- package/dist/pine-core/p-546c2b18.entry.js +2 -0
- package/dist/pine-core/{p-1e9d6f92.system.entry.js → p-55cbb360.system.entry.js} +2 -2
- package/dist/pine-core/p-5ab15bbc.entry.js +2 -0
- package/dist/pine-core/p-5ab15bbc.entry.js.map +1 -0
- package/dist/pine-core/p-5c04aee0.system.js +1 -1
- package/dist/pine-core/p-5c04aee0.system.js.map +1 -1
- package/dist/pine-core/{p-b7e91522.entry.js → p-5d0c0241.entry.js} +2 -2
- package/dist/pine-core/p-5dd93828.system.entry.js +2 -0
- package/dist/pine-core/p-600b7640.system.entry.js +2 -0
- package/dist/pine-core/p-600b7640.system.entry.js.map +1 -0
- package/dist/pine-core/p-61666500.system.entry.js +2 -0
- package/dist/pine-core/p-61666500.system.entry.js.map +1 -0
- package/dist/pine-core/p-61cf32c6.entry.js +2 -0
- package/dist/pine-core/p-61cf32c6.entry.js.map +1 -0
- package/dist/pine-core/{p-80c582b7.system.entry.js → p-6bba1784.system.entry.js} +2 -2
- package/dist/pine-core/p-6e8f3bb4.entry.js.map +1 -1
- package/dist/pine-core/p-72218979.system.entry.js +2 -0
- package/dist/pine-core/p-72218979.system.entry.js.map +1 -0
- package/dist/pine-core/{p-1edca70e.entry.js → p-7369f396.entry.js} +2 -2
- package/dist/pine-core/p-77d8e9fc.entry.js +2 -0
- package/dist/pine-core/{p-e356293a.entry.js.map → p-77d8e9fc.entry.js.map} +1 -1
- package/dist/pine-core/p-7cdcf66c.entry.js +2 -0
- package/dist/pine-core/{p-5e1b7996.entry.js.map → p-7cdcf66c.entry.js.map} +1 -1
- package/dist/pine-core/p-89fd4ca2.entry.js +2 -0
- package/dist/pine-core/p-89fd4ca2.entry.js.map +1 -0
- package/dist/pine-core/{p-19be5a8e.system.entry.js → p-8afa0198.system.entry.js} +2 -2
- package/dist/pine-core/{p-a2465224.entry.js → p-8b3d405b.entry.js} +2 -2
- package/dist/pine-core/{p-954098a2.entry.js → p-8b9e5fe5.entry.js} +2 -2
- package/dist/pine-core/p-910c4422.entry.js +2 -0
- package/dist/pine-core/p-910c4422.entry.js.map +1 -0
- package/dist/pine-core/{p-da961d2b.entry.js → p-9b2cacf1.entry.js} +2 -2
- package/dist/pine-core/p-a020513a.system.entry.js +2 -0
- package/dist/pine-core/p-a020513a.system.entry.js.map +1 -0
- package/dist/pine-core/p-a924b8a6.system.entry.js +2 -0
- package/dist/pine-core/p-a924b8a6.system.entry.js.map +1 -0
- package/dist/pine-core/{p-d0b371ee.system.entry.js → p-acf6cf26.system.entry.js} +2 -2
- package/dist/pine-core/{p-07a7c5bb.entry.js → p-b20dd7d7.entry.js} +2 -2
- package/dist/pine-core/p-b2163263.entry.js +2 -0
- package/dist/pine-core/p-b2163263.entry.js.map +1 -0
- package/dist/pine-core/p-b245df0a.system.entry.js +2 -0
- package/dist/pine-core/p-b245df0a.system.entry.js.map +1 -0
- package/dist/pine-core/{p-ed990ad0.system.entry.js → p-b492ea28.system.entry.js} +2 -2
- package/dist/pine-core/{p-568ef920.entry.js → p-b566ad6b.entry.js} +2 -2
- package/dist/pine-core/p-b6dfd404.system.entry.js +2 -0
- package/dist/pine-core/p-b6dfd404.system.entry.js.map +1 -0
- package/dist/pine-core/p-b95c0169.system.entry.js +2 -0
- package/dist/pine-core/p-b95c0169.system.entry.js.map +1 -0
- package/dist/pine-core/p-bda9a6a0.entry.js +2 -0
- package/dist/pine-core/p-bda9a6a0.entry.js.map +1 -0
- package/dist/pine-core/p-bf55e42e.system.entry.js +2 -0
- package/dist/pine-core/{p-4c252abb.system.entry.js → p-c20bc538.system.entry.js} +2 -2
- package/dist/pine-core/p-c53f6513.entry.js +2 -0
- package/dist/pine-core/p-c53f6513.entry.js.map +1 -0
- package/dist/pine-core/p-c849426d.entry.js +2 -0
- package/dist/pine-core/p-c849426d.entry.js.map +1 -0
- package/dist/pine-core/{p-1da5aaf3.entry.js → p-ce0efc2d.entry.js} +2 -2
- package/dist/pine-core/{p-1fd67cb4.system.entry.js → p-d266843a.system.entry.js} +2 -2
- package/dist/pine-core/{p-f90088df.entry.js → p-d34b9adb.entry.js} +2 -2
- package/dist/pine-core/{p-74ad0244.entry.js → p-d8188c09.entry.js} +2 -2
- package/dist/pine-core/p-d92c8d63.system.entry.js +2 -0
- package/dist/pine-core/p-d92c8d63.system.entry.js.map +1 -0
- package/dist/pine-core/{p-5480346a.system.js → p-dba6ac9c.system.js} +2 -2
- package/dist/pine-core/p-dba6ac9c.system.js.map +1 -0
- package/dist/pine-core/{p-29bb6589.entry.js → p-e19d9edd.entry.js} +2 -2
- package/dist/pine-core/p-e45ee7bb.entry.js +2 -0
- package/dist/pine-core/p-e45ee7bb.entry.js.map +1 -0
- package/dist/pine-core/p-ee78b4c6.entry.js +2 -0
- package/dist/pine-core/p-ee78b4c6.entry.js.map +1 -0
- package/dist/pine-core/p-f099836d.entry.js +2 -0
- package/dist/pine-core/p-f099836d.entry.js.map +1 -0
- package/dist/pine-core/p-f70ebb08.system.entry.js +2 -0
- package/dist/pine-core/p-f70ebb08.system.entry.js.map +1 -0
- package/dist/pine-core/{p-397ce1a8.system.entry.js → p-fad3645f.system.entry.js} +2 -2
- package/dist/pine-core/{p-285cd9d1.system.entry.js → p-fd3e2c23.system.entry.js} +2 -2
- package/dist/pine-core/p-fe70473e.system.entry.js +2 -0
- package/dist/pine-core/p-fe70473e.system.entry.js.map +1 -0
- package/dist/pine-core/pine-core.css +1 -1
- package/dist/pine-core/pine-core.esm.js +1 -1
- package/dist/pine-core/pine-core.esm.js.map +1 -1
- package/dist/pine-core/svg/align-horizontal-bottom.svg +1 -0
- package/dist/pine-core/svg/align-horizontal-center.svg +1 -0
- package/dist/pine-core/svg/align-horizontal-top.svg +1 -0
- package/dist/pine-core/svg/align-vertical-center.svg +1 -0
- package/dist/pine-core/svg/align-vertical-left.svg +1 -0
- package/dist/pine-core/svg/align-vertical-right.svg +1 -0
- package/dist/pine-core/svg/copy-07.svg +1 -0
- package/dist/pine-core/svg/feedback.svg +1 -1
- package/dist/pine-core/svg/form.svg +1 -1
- package/dist/pine-core/svg/grant-offer.svg +1 -1
- package/dist/pine-core/svg/headphones.svg +1 -0
- package/dist/pine-core/svg/kajabi-filled.svg +1 -1
- package/dist/pine-core/svg/kajabi.svg +1 -1
- package/dist/pine-core/svg/keyboard-01.svg +1 -0
- package/dist/pine-core/svg/layout-bottom.svg +1 -0
- package/dist/pine-core/svg/layout-top.svg +1 -0
- package/dist/pine-core/svg/list-numbers.svg +1 -1
- package/dist/pine-core/svg/mail-open.svg +1 -1
- package/dist/pine-core/svg/mail.svg +1 -1
- package/dist/pine-core/svg/merge.svg +1 -1
- package/dist/pine-core/svg/message-text-square-02.svg +1 -0
- package/dist/pine-core/svg/music-note-01.svg +1 -0
- package/dist/pine-core/svg/newsletter-2.svg +1 -1
- package/dist/pine-core/svg/pie-chart-filled.svg +1 -0
- package/dist/pine-core/svg/plus-square.svg +1 -0
- package/dist/pine-core/svg/present.svg +1 -1
- package/dist/pine-core/svg/quote.svg +1 -1
- package/dist/pine-core/svg/restore.svg +1 -1
- package/dist/pine-core/svg/square-dollar.svg +1 -0
- package/dist/pine-core/svg/star-03.svg +1 -0
- package/dist/pine-core/svg/star-filled.svg +1 -0
- package/dist/pine-core/svg/star.svg +1 -1
- package/dist/pine-core/svg/subscript.svg +1 -1
- package/dist/pine-core/svg/sync.svg +1 -1
- package/dist/pine-core/svg/type.svg +1 -0
- package/dist/pine-core/svg/user-filled.svg +1 -1
- package/dist/types/components/pds-button/pds-button.d.ts +11 -0
- package/dist/types/components/pds-input/pds-input.d.ts +2 -1
- package/dist/types/components/pds-select/pds-select.d.ts +1 -1
- package/dist/types/components.d.ts +23 -3
- package/hydrate/index.js +94 -71
- package/hydrate/index.mjs +94 -71
- package/package.json +2 -2
- package/components/pds-label.js +0 -11
- package/components/pds-label.js.map +0 -1
- package/dist/cjs/index-034a8bb0.js.map +0 -1
- package/dist/cjs/pds-label-e0d9a97d.js +0 -13
- package/dist/cjs/pds-label-e0d9a97d.js.map +0 -1
- package/dist/esm/index-d320cfa9.js.map +0 -1
- package/dist/esm/pds-label-949a17b6.js +0 -11
- package/dist/esm/pds-label-949a17b6.js.map +0 -1
- package/dist/esm-es5/index-d320cfa9.js.map +0 -1
- package/dist/esm-es5/pds-label-949a17b6.js +0 -2
- package/dist/esm-es5/pds-label-949a17b6.js.map +0 -1
- package/dist/pine-core/p-03440844.entry.js +0 -2
- package/dist/pine-core/p-03440844.entry.js.map +0 -1
- package/dist/pine-core/p-0c09ce7a.js +0 -2
- package/dist/pine-core/p-0c09ce7a.js.map +0 -1
- package/dist/pine-core/p-27e12bd2.system.entry.js +0 -2
- package/dist/pine-core/p-27e12bd2.system.entry.js.map +0 -1
- package/dist/pine-core/p-2d52d5f7.entry.js +0 -2
- package/dist/pine-core/p-2d52d5f7.entry.js.map +0 -1
- package/dist/pine-core/p-30cd9f18.entry.js +0 -2
- package/dist/pine-core/p-372a04fa.system.entry.js +0 -2
- package/dist/pine-core/p-372a04fa.system.entry.js.map +0 -1
- package/dist/pine-core/p-3fbb568f.entry.js +0 -2
- package/dist/pine-core/p-3fbb568f.entry.js.map +0 -1
- package/dist/pine-core/p-4d1fbb88.system.entry.js +0 -2
- package/dist/pine-core/p-4f2e4e6f.system.entry.js +0 -2
- package/dist/pine-core/p-4f2e4e6f.system.entry.js.map +0 -1
- package/dist/pine-core/p-5480346a.system.js.map +0 -1
- package/dist/pine-core/p-5e1b7996.entry.js +0 -2
- package/dist/pine-core/p-60c2039e.system.entry.js +0 -2
- package/dist/pine-core/p-71dc77f3.entry.js +0 -2
- package/dist/pine-core/p-71dc77f3.entry.js.map +0 -1
- package/dist/pine-core/p-7257c948.entry.js +0 -2
- package/dist/pine-core/p-798cde42.system.entry.js +0 -2
- package/dist/pine-core/p-798cde42.system.entry.js.map +0 -1
- package/dist/pine-core/p-7baec1ed.entry.js +0 -2
- package/dist/pine-core/p-7baec1ed.entry.js.map +0 -1
- package/dist/pine-core/p-853af623.system.entry.js +0 -2
- package/dist/pine-core/p-853af623.system.entry.js.map +0 -1
- package/dist/pine-core/p-8c0a648d.system.entry.js +0 -2
- package/dist/pine-core/p-8c0a648d.system.entry.js.map +0 -1
- package/dist/pine-core/p-8d1efd85.system.js +0 -2
- package/dist/pine-core/p-8d1efd85.system.js.map +0 -1
- package/dist/pine-core/p-95e4a6ff.system.entry.js +0 -2
- package/dist/pine-core/p-95e4a6ff.system.entry.js.map +0 -1
- package/dist/pine-core/p-987a101b.system.entry.js +0 -2
- package/dist/pine-core/p-987a101b.system.entry.js.map +0 -1
- package/dist/pine-core/p-a22fd94e.entry.js +0 -2
- package/dist/pine-core/p-a22fd94e.entry.js.map +0 -1
- package/dist/pine-core/p-aa134d2a.system.entry.js +0 -2
- package/dist/pine-core/p-aa134d2a.system.entry.js.map +0 -1
- package/dist/pine-core/p-ade60629.system.entry.js +0 -2
- package/dist/pine-core/p-ade60629.system.entry.js.map +0 -1
- package/dist/pine-core/p-adf21b0c.entry.js +0 -2
- package/dist/pine-core/p-adf21b0c.entry.js.map +0 -1
- package/dist/pine-core/p-cae3e411.entry.js +0 -2
- package/dist/pine-core/p-cae3e411.entry.js.map +0 -1
- package/dist/pine-core/p-d561168e.js.map +0 -1
- package/dist/pine-core/p-d9390457.entry.js +0 -2
- package/dist/pine-core/p-d9390457.entry.js.map +0 -1
- package/dist/pine-core/p-e356293a.entry.js +0 -2
- package/dist/pine-core/p-e60348bc.system.entry.js +0 -2
- package/dist/pine-core/p-e60348bc.system.entry.js.map +0 -1
- package/dist/pine-core/p-f085efeb.entry.js +0 -2
- package/dist/pine-core/p-f085efeb.entry.js.map +0 -1
- package/dist/pine-core/p-f0c28381.entry.js +0 -2
- package/dist/pine-core/p-f0c28381.entry.js.map +0 -1
- package/dist/pine-core/p-f19e5736.system.entry.js +0 -2
- package/dist/pine-core/p-f19e5736.system.entry.js.map +0 -1
- package/dist/pine-core/p-f34096db.system.entry.js +0 -2
- package/dist/pine-core/p-f34096db.system.entry.js.map +0 -1
- package/dist/pine-core/p-f81066da.entry.js +0 -2
- package/dist/pine-core/p-f81066da.entry.js.map +0 -1
- package/dist/pine-core/p-f900a8ee.entry.js +0 -2
- package/dist/pine-core/p-f900a8ee.entry.js.map +0 -1
- /package/dist/pine-core/{p-8c07ed73.system.entry.js.map → p-04fb06cd.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-c68362cc.entry.js.map → p-0ad21851.entry.js.map} +0 -0
- /package/dist/pine-core/{p-8420594c.system.entry.js.map → p-0c68a8ea.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-8b2db323.system.entry.js.map → p-10caa9e9.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-f182a1f2.system.entry.js.map → p-137aebf6.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-5e50a381.entry.js.map → p-138ef0d8.entry.js.map} +0 -0
- /package/dist/pine-core/{p-d8260ebf.system.entry.js.map → p-21c441f2.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-e890c1bb.system.entry.js.map → p-2f80836e.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-e39bd4b2.system.entry.js.map → p-3de0ec6c.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-df73ebae.entry.js.map → p-3f256ba6.entry.js.map} +0 -0
- /package/dist/pine-core/{p-d6a5ec65.system.entry.js.map → p-4158fa20.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-92bcb091.entry.js.map → p-518f8204.entry.js.map} +0 -0
- /package/dist/pine-core/{p-30cd9f18.entry.js.map → p-546c2b18.entry.js.map} +0 -0
- /package/dist/pine-core/{p-1e9d6f92.system.entry.js.map → p-55cbb360.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-b7e91522.entry.js.map → p-5d0c0241.entry.js.map} +0 -0
- /package/dist/pine-core/{p-4d1fbb88.system.entry.js.map → p-5dd93828.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-80c582b7.system.entry.js.map → p-6bba1784.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-1edca70e.entry.js.map → p-7369f396.entry.js.map} +0 -0
- /package/dist/pine-core/{p-19be5a8e.system.entry.js.map → p-8afa0198.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-a2465224.entry.js.map → p-8b3d405b.entry.js.map} +0 -0
- /package/dist/pine-core/{p-954098a2.entry.js.map → p-8b9e5fe5.entry.js.map} +0 -0
- /package/dist/pine-core/{p-da961d2b.entry.js.map → p-9b2cacf1.entry.js.map} +0 -0
- /package/dist/pine-core/{p-d0b371ee.system.entry.js.map → p-acf6cf26.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-07a7c5bb.entry.js.map → p-b20dd7d7.entry.js.map} +0 -0
- /package/dist/pine-core/{p-ed990ad0.system.entry.js.map → p-b492ea28.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-568ef920.entry.js.map → p-b566ad6b.entry.js.map} +0 -0
- /package/dist/pine-core/{p-60c2039e.system.entry.js.map → p-bf55e42e.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-4c252abb.system.entry.js.map → p-c20bc538.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-1da5aaf3.entry.js.map → p-ce0efc2d.entry.js.map} +0 -0
- /package/dist/pine-core/{p-1fd67cb4.system.entry.js.map → p-d266843a.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-f90088df.entry.js.map → p-d34b9adb.entry.js.map} +0 -0
- /package/dist/pine-core/{p-74ad0244.entry.js.map → p-d8188c09.entry.js.map} +0 -0
- /package/dist/pine-core/{p-29bb6589.entry.js.map → p-e19d9edd.entry.js.map} +0 -0
- /package/dist/pine-core/{p-397ce1a8.system.entry.js.map → p-fad3645f.system.entry.js.map} +0 -0
- /package/dist/pine-core/{p-285cd9d1.system.entry.js.map → p-fd3e2c23.system.entry.js.map} +0 -0
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { h, Host } from "@stencil/core";
|
|
2
2
|
import { assignDescription, messageId } from "../../utils/form";
|
|
3
|
-
import { PdsLabel } from "../_internal/pds-label/pds-label";
|
|
4
3
|
import { danger } from "@pine-ds/icons/icons";
|
|
5
4
|
export class PdsCheckbox {
|
|
6
5
|
constructor() {
|
|
@@ -51,9 +50,9 @@ export class PdsCheckbox {
|
|
|
51
50
|
return classNames.join(' ');
|
|
52
51
|
}
|
|
53
52
|
render() {
|
|
54
|
-
return (h(Host, { key: '
|
|
55
|
-
h("div", { key: '
|
|
56
|
-
h("div", { key: '
|
|
53
|
+
return (h(Host, { key: 'd552ef5967613280f3399015c17d90d2264bee26', class: this.classNames() }, h("label", { key: '7ed49fd6c942d3765ce5c70048fe53252b532f75', htmlFor: this.componentId }, h("input", { key: 'b1d59fc429e9bd92bd7ff0e4edb79b326416d9fb', type: "checkbox", "aria-describedby": assignDescription(this.componentId, this.invalid, this.helperMessage), "aria-invalid": this.invalid ? "true" : undefined, id: this.componentId, indeterminate: this.indeterminate, name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, onChange: this.handleCheckboxChange, onInput: this.handleInput }), this.label), this.helperMessage &&
|
|
54
|
+
h("div", { key: '2bf16b8f87910f727e19b2b3a0df5190f80b9c9b', class: 'pds-checkbox__message', id: messageId(this.componentId, 'helper') }, this.helperMessage), this.errorMessage &&
|
|
55
|
+
h("div", { key: 'dde8ede862aaaf585fe6d1e907b0a78309a59e58', class: `pds-checkbox__message pds-checkbox__message--error`, id: messageId(this.componentId, 'error'), "aria-live": "assertive" }, h("pds-icon", { key: 'b666e9ccbeb8653271da75cdf81419fbad6028e2', icon: danger, size: "small" }), this.errorMessage)));
|
|
57
56
|
}
|
|
58
57
|
static get is() { return "pds-checkbox"; }
|
|
59
58
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pds-checkbox.js","sourceRoot":"","sources":["../../../src/components/pds-checkbox/pds-checkbox.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAgB,KAAK,EAAE,MAAM,eAAe,CAAC;AACrF,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"pds-checkbox.js","sourceRoot":"","sources":["../../../src/components/pds-checkbox/pds-checkbox.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAgB,KAAK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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, Host, Event, EventEmitter, Watch } from '@stencil/core';\nimport { assignDescription, messageId } from '../../utils/form';\nimport { CheckboxChangeEventDetail } from './checkbox-interface';\nimport { danger } from '@pine-ds/icons/icons';\n\n@Component({\n tag: 'pds-checkbox',\n styleUrls: ['../../global/styles/utils/label.scss', 'pds-checkbox.scss'],\n shadow: true,\n})\nexport class PdsCheckbox {\n /**\n * It determines whether or not the checkbox is checked.\n */\n @Prop({ mutable: true }) checked?: boolean = false;\n\n /**\n * A unique identifier used for the underlying component `id` attribute and the label `for` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * It determines whether or not the checkbox is disabled.\n */\n @Prop() disabled: boolean;\n\n /**\n * Displays message text describing an invalid state.\n */\n @Prop() errorMessage: string;\n\n /**\n * String used for helper message below checkbox.\n */\n @Prop() helperMessage: string;\n\n /**\n * If `true`, the checkbox will visually appear as indeterminate.\n * Only JavaScript can set the objects `indeterminate` property. See [MDN Web Docs](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/checkbox#indeterminate_state_checkboxes).\n */\n @Prop({ mutable: true }) indeterminate: boolean;\n\n /**\n * It determines whether or not the checkbox is invalid.\n */\n @Prop() invalid: boolean;\n\n /**\n * String used for label text next to checkbox.\n */\n @Prop() label: string;\n\n /**\n * Visually hides the label text for instances where only the checkbox should be displayed. Label remains accessible to assistive technology such as screen readers.\n */\n @Prop() labelHidden: boolean;\n\n /**\n * String used for checkbox `name` attribute.\n */\n @Prop() name: string;\n\n /**\n * It determines whether or not the checkbox is required.\n */\n @Prop() required: boolean;\n\n /**\n * The value of the checkbox that is submitted with a form.\n */\n @Prop() value: string;\n\n /**\n * Event emitted that contains the `value` and `checked`.\n */\n @Event() pdsCheckboxChange: EventEmitter<CheckboxChangeEventDetail>;\n\n @Event() pdsCheckboxInput: EventEmitter<CheckboxChangeEventDetail>;\n\n @Watch('checked')\n updateIndeterminate() {\n this.indeterminate = undefined\n }\n\n private handleCheckboxChange = (e: Event) => {\n if (this.disabled) {\n return;\n }\n\n const target = e.target as HTMLInputElement;\n this.checked = target.checked;\n\n this.pdsCheckboxChange.emit({\n checked: target.checked,\n value: this.value\n });\n }\n\n private handleInput = () => {\n this.pdsCheckboxInput.emit({\n checked: this.checked,\n value: this.value\n });\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.invalid) { classNames.push('is-invalid'); }\n if (this.indeterminate) { classNames.push('is-indeterminate'); }\n if (this.disabled) { classNames.push('is-disabled'); }\n\n return classNames.join(' ');\n }\n\n render() {\n return (\n <Host class={this.classNames()}>\n <label htmlFor={this.componentId}>\n <input\n type=\"checkbox\"\n aria-describedby={assignDescription(this.componentId, this.invalid, this.helperMessage)}\n aria-invalid={this.invalid ? \"true\" : undefined}\n id={this.componentId}\n indeterminate={this.indeterminate}\n name={this.name}\n value={this.value}\n checked={this.checked}\n required={this.required}\n disabled={this.disabled}\n onChange={this.handleCheckboxChange}\n onInput={this.handleInput}\n />\n {this.label}\n </label>\n {this.helperMessage &&\n <div\n class={'pds-checkbox__message'}\n id={messageId(this.componentId, 'helper')}\n >\n {this.helperMessage}\n </div>\n }\n {this.errorMessage &&\n <div\n class={`pds-checkbox__message pds-checkbox__message--error`}\n id={messageId(this.componentId, 'error')}\n aria-live=\"assertive\"\n >\n <pds-icon icon={danger} size=\"small\" />\n {this.errorMessage}\n </div>\n }\n </Host>\n );\n }\n}\n"]}
|
|
@@ -31,7 +31,7 @@ export class PdsChip {
|
|
|
31
31
|
return chipContent;
|
|
32
32
|
}
|
|
33
33
|
render() {
|
|
34
|
-
return (h(Host, { key: '
|
|
34
|
+
return (h(Host, { key: '91f7d9a87538c4b30b16462061a61fb92812732f', class: this.classNames(), id: this.componentId }, this.setChipContent(), this.variant === 'tag' && (h("button", { key: 'bee8696d3644f33d8630a4ab93ff83c8b1d7ee78', class: "pds-chip__close", type: "button", onClick: this.handleCloseClick, "aria-label": "Remove" }, h("pds-icon", { key: '5a375bf7507f7ac674a6f3c27048e2c218064bb4', icon: remove, size: "12px" })))));
|
|
35
35
|
}
|
|
36
36
|
static get is() { return "pds-chip"; }
|
|
37
37
|
static get encapsulation() { return "shadow"; }
|
|
@@ -2,22 +2,22 @@
|
|
|
2
2
|
* Do not edit directly, this file was auto-generated.
|
|
3
3
|
*/
|
|
4
4
|
:host {
|
|
5
|
-
--pine-chip-color-warning-dot: var(--pine-color-yellow-600);
|
|
6
|
-
--pine-chip-color-warning-hover: var(--pine-color-yellow-300);
|
|
7
|
-
--pine-chip-color-warning: var(--pine-color-yellow-100);
|
|
8
|
-
--pine-chip-color-success-dot: var(--pine-color-green-600);
|
|
9
|
-
--pine-chip-color-success-hover: var(--pine-color-green-300);
|
|
10
|
-
--pine-chip-color-success: var(--pine-color-green-100);
|
|
11
|
-
--pine-chip-color-neutral-dot: var(--pine-color-grey-600);
|
|
12
|
-
--pine-chip-color-neutral-hover: var(--pine-color-grey-300);
|
|
13
|
-
--pine-chip-color-neutral: var(--pine-color-grey-100);
|
|
14
|
-
--pine-chip-color-info-dot: var(--pine-color-blue-600);
|
|
15
|
-
--pine-chip-color-info-hover: var(--pine-color-blue-300);
|
|
16
|
-
--pine-chip-color-info: var(--pine-color-blue-100);
|
|
17
|
-
--pine-chip-color-danger-dot: var(--pine-color-red-600);
|
|
18
|
-
--pine-chip-color-danger-hover: var(--pine-color-red-300);
|
|
19
|
-
--pine-chip-color-danger: var(--pine-color-red-100);
|
|
20
|
-
--pine-chip-color-accent-dot: var(--pine-color-purple-600);
|
|
21
|
-
--pine-chip-color-accent-hover: var(--pine-color-purple-300);
|
|
22
5
|
--pine-chip-color-accent: var(--pine-color-purple-100);
|
|
6
|
+
--pine-chip-color-accent-hover: var(--pine-color-purple-300);
|
|
7
|
+
--pine-chip-color-accent-dot: var(--pine-color-purple-600);
|
|
8
|
+
--pine-chip-color-danger: var(--pine-color-red-100);
|
|
9
|
+
--pine-chip-color-danger-hover: var(--pine-color-red-300);
|
|
10
|
+
--pine-chip-color-danger-dot: var(--pine-color-red-600);
|
|
11
|
+
--pine-chip-color-info: var(--pine-color-blue-100);
|
|
12
|
+
--pine-chip-color-info-hover: var(--pine-color-blue-300);
|
|
13
|
+
--pine-chip-color-info-dot: var(--pine-color-blue-600);
|
|
14
|
+
--pine-chip-color-neutral: var(--pine-color-grey-100);
|
|
15
|
+
--pine-chip-color-neutral-hover: var(--pine-color-grey-300);
|
|
16
|
+
--pine-chip-color-neutral-dot: var(--pine-color-grey-600);
|
|
17
|
+
--pine-chip-color-success: var(--pine-color-green-100);
|
|
18
|
+
--pine-chip-color-success-hover: var(--pine-color-green-300);
|
|
19
|
+
--pine-chip-color-success-dot: var(--pine-color-green-600);
|
|
20
|
+
--pine-chip-color-warning: var(--pine-color-yellow-100);
|
|
21
|
+
--pine-chip-color-warning-hover: var(--pine-color-yellow-300);
|
|
22
|
+
--pine-chip-color-warning-dot: var(--pine-color-yellow-600);
|
|
23
23
|
}
|
|
@@ -36,7 +36,7 @@ export class PdsCopytext {
|
|
|
36
36
|
return classNames.join(' ');
|
|
37
37
|
}
|
|
38
38
|
render() {
|
|
39
|
-
return (h(Host, { key: '
|
|
39
|
+
return (h(Host, { key: '46c38faeba9b70d2e510a4b6af08866577936478', class: this.classNames(), id: this.componentId }, h("pds-button", { key: '6e28c11a9a7a57f4c256b0283b64ec655a897f65', type: "button", variant: "unstyled", onClick: this.handleClick }, h("span", { key: '6818451171f85fd6ad63f07c69871082d3fcba4e' }, this.value), h("pds-icon", { key: '05e683d7b28575d924d6af482e6ce4c3cfee3f05', icon: copyIcon, size: "16px" }))));
|
|
40
40
|
}
|
|
41
41
|
static get is() { return "pds-copytext"; }
|
|
42
42
|
static get encapsulation() { return "shadow"; }
|
|
@@ -17,7 +17,7 @@ export class PdsDivider {
|
|
|
17
17
|
return classNames.join(' ');
|
|
18
18
|
}
|
|
19
19
|
render() {
|
|
20
|
-
return (h(Host, { key: '
|
|
20
|
+
return (h(Host, { key: 'ee48ee45e0463abbd3cb7aa686f8d86928830ccb', id: this.componentId }, h("hr", { key: '4af739f85e502a7d9bff1b3581c283cb6ee53a0e', class: this.classNames() })));
|
|
21
21
|
}
|
|
22
22
|
static get is() { return "pds-divider"; }
|
|
23
23
|
static get encapsulation() { return "shadow"; }
|
|
@@ -11,9 +11,9 @@ export class PdsImage {
|
|
|
11
11
|
this.width = undefined;
|
|
12
12
|
}
|
|
13
13
|
render() {
|
|
14
|
-
return (h(Host, { key: '
|
|
14
|
+
return (h(Host, { key: '2b5893c36517ee6e30c12a141f19b3f13845db97', class: {
|
|
15
15
|
'pds-image': true,
|
|
16
|
-
}, id: this.componentId }, h("img", { key: '
|
|
16
|
+
}, id: this.componentId }, h("img", { key: '965043cab5ea5c62c52951ec90018bced5bb46e8', alt: this.alt, height: this.height, loading: this.loading, sizes: this.sizes, src: this.src, srcset: this.srcset, width: this.width })));
|
|
17
17
|
}
|
|
18
18
|
static get is() { return "pds-image"; }
|
|
19
19
|
static get encapsulation() { return "shadow"; }
|
|
@@ -14,13 +14,14 @@
|
|
|
14
14
|
flex-direction: column;
|
|
15
15
|
}
|
|
16
16
|
|
|
17
|
-
|
|
18
|
-
margin-block-end: var(--pine-dimension-
|
|
17
|
+
.pds-input__label {
|
|
18
|
+
margin-block-end: var(--pine-dimension-2xs);
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
.pds-input__field {
|
|
22
|
+
background: var(--pine-color-background-container);
|
|
22
23
|
border: 1px solid var(--pine-color-border);
|
|
23
|
-
border-radius:
|
|
24
|
+
border-radius: var(--pine-dimension-125);
|
|
24
25
|
color: var(--pine-color-text-active);
|
|
25
26
|
font: var(--pine-typography-body);
|
|
26
27
|
letter-spacing: var(--pine-letter-spacing);
|
|
@@ -28,7 +29,10 @@ input {
|
|
|
28
29
|
/* stylelint-disable */
|
|
29
30
|
/* stylelint-enable */
|
|
30
31
|
}
|
|
31
|
-
|
|
32
|
+
.pds-input__field:hover:not(:disabled, .is-invalid) {
|
|
33
|
+
border: var(--pine-border-hover);
|
|
34
|
+
}
|
|
35
|
+
.pds-input__field:disabled {
|
|
32
36
|
background-color: var(--pine-color-background-container-disabled);
|
|
33
37
|
border-color: var(--pine-color-border-disabled);
|
|
34
38
|
color: var(--pine-color-text-disabled);
|
|
@@ -36,52 +40,51 @@ input:disabled {
|
|
|
36
40
|
/* stylelint-disable */
|
|
37
41
|
/* stylelint-enable */
|
|
38
42
|
}
|
|
39
|
-
|
|
43
|
+
.pds-input__field:disabled::-webkit-input-placeholder {
|
|
40
44
|
color: var(--pine-color-text-placeholder-disabled);
|
|
41
45
|
}
|
|
42
|
-
|
|
46
|
+
.pds-input__field:disabled::-moz-placeholder {
|
|
43
47
|
color: var(--pine-color-text-placeholder-disabled);
|
|
44
48
|
}
|
|
45
|
-
|
|
49
|
+
.pds-input__field:disabled::-moz-placeholder {
|
|
46
50
|
color: var(--pine-color-text-placeholder-disabled);
|
|
47
51
|
}
|
|
48
|
-
|
|
52
|
+
.pds-input__field:disabled:-ms-input-placeholder {
|
|
49
53
|
color: var(--pine-color-text-placeholder-disabled);
|
|
50
54
|
}
|
|
51
|
-
|
|
55
|
+
.pds-input__field:hover {
|
|
52
56
|
border-color: var(--pine-color-border-hover);
|
|
53
57
|
}
|
|
54
|
-
|
|
58
|
+
.pds-input__field:focus-visible {
|
|
55
59
|
border-color: var(--pine-color-border-active);
|
|
56
60
|
box-shadow: var(--box-shadow-focus);
|
|
57
61
|
outline: none;
|
|
58
62
|
}
|
|
59
|
-
|
|
63
|
+
.pds-input__field::-webkit-input-placeholder {
|
|
60
64
|
color: var(--pine-color-text-placeholder);
|
|
61
65
|
}
|
|
62
|
-
|
|
66
|
+
.pds-input__field::-moz-placeholder {
|
|
63
67
|
color: var(--pine-color-text-placeholder);
|
|
64
68
|
}
|
|
65
|
-
|
|
69
|
+
.pds-input__field::-moz-placeholder {
|
|
66
70
|
color: var(--pine-color-text-placeholder);
|
|
67
71
|
}
|
|
68
|
-
|
|
72
|
+
.pds-input__field:-ms-input-placeholder {
|
|
69
73
|
color: var(--pine-color-text-placeholder);
|
|
70
74
|
}
|
|
71
|
-
|
|
75
|
+
.pds-input__field.is-invalid {
|
|
72
76
|
background-color: var(--pine-input-color-background-danger);
|
|
73
77
|
border-color: var(--pine-color-border-danger);
|
|
74
78
|
}
|
|
75
|
-
|
|
79
|
+
.pds-input__field.is-invalid:focus-visible {
|
|
76
80
|
box-shadow: var(--box-shadow-focus-error);
|
|
77
|
-
outline: none;
|
|
78
81
|
}
|
|
79
82
|
|
|
80
83
|
.pds-input__error-message,
|
|
81
84
|
.pds-input__helper-message {
|
|
82
85
|
font: var(--pine-typography-body-sm-medium);
|
|
83
86
|
margin-block-end: 0;
|
|
84
|
-
margin-block-start: var(--pine-dimension-
|
|
87
|
+
margin-block-start: var(--pine-dimension-2xs);
|
|
85
88
|
}
|
|
86
89
|
|
|
87
90
|
.pds-input__error-message {
|
|
@@ -107,10 +107,18 @@ export class PdsInput {
|
|
|
107
107
|
componentDidLoad() {
|
|
108
108
|
this.debounceChanged();
|
|
109
109
|
}
|
|
110
|
+
inputClassNames() {
|
|
111
|
+
const classNames = ['pds-input__field'];
|
|
112
|
+
if (this.invalid && this.invalid === true) {
|
|
113
|
+
classNames.push('is-invalid');
|
|
114
|
+
}
|
|
115
|
+
return classNames.join(' ');
|
|
116
|
+
}
|
|
110
117
|
render() {
|
|
111
|
-
return (h(Host, { key: '
|
|
112
|
-
h("
|
|
113
|
-
h("p", { key: '
|
|
118
|
+
return (h(Host, { key: 'a823b0086b4c4accc0788813a41b19f8b6ff32e1', "aria-disabled": this.disabled ? 'true' : null, "aria-readonly": this.readonly ? 'true' : null }, h("div", { key: 'e9b04aaa8e50c987e6010017fbb82bc7b6774d34', class: "pds-input" }, this.label &&
|
|
119
|
+
h("label", { key: '5c6ddd8b32997344399915929d1ebd9b53c01ec2', class: "pds-input__label", htmlFor: this.componentId }, this.label), h("input", Object.assign({ key: '4bbc00b3ad007fa357ebddccaed0ee5912c464ea', class: this.inputClassNames(), ref: (input) => this.nativeInput = input, "aria-describedby": assignDescription(this.componentId, this.invalid, this.helperMessage), "aria-invalid": this.invalid ? "true" : undefined, autocomplete: this.autocomplete, disabled: this.disabled, id: this.componentId, name: this.name, placeholder: this.placeholder, readOnly: this.readonly, required: this.required, type: this.type, value: this.value, onInput: this.onInputEvent, onChange: this.onChangeEvent, onBlur: this.onBlurEvent, onFocus: this.onFocusEvent, onCompositionstart: this.onCompositionStart, onCompositionend: this.onCompositionEnd }, this.inheritedAttributes)), this.helperMessage &&
|
|
120
|
+
h("p", { key: 'df6340f0d4ac1271e6a304a2accb312b45c87081', class: "pds-input__helper-message", id: messageId(this.componentId, 'helper') }, this.helperMessage), this.errorMessage &&
|
|
121
|
+
h("p", { key: '50ecf4b62a9a7215a9b7043031a82b5f3b4f0291', class: "pds-input__error-message", id: messageId(this.componentId, 'error'), "aria-live": "assertive" }, h("pds-icon", { key: '87cfdda13d2756c221e0fc3e448c94fb46bc2eb8', icon: danger, size: "small" }), this.errorMessage))));
|
|
114
122
|
}
|
|
115
123
|
static get is() { return "pds-input"; }
|
|
116
124
|
static get encapsulation() { return "shadow"; }
|
|
@@ -345,7 +353,7 @@ export class PdsInput {
|
|
|
345
353
|
"name": "defaultValue",
|
|
346
354
|
"text": "\"text\""
|
|
347
355
|
}],
|
|
348
|
-
"text": "Determines the type of control that will be displayed\n`'email'`, `'number'`, `'password'`, `'tel'`, `'text'`"
|
|
356
|
+
"text": "Determines the type of control that will be displayed\n`'email'`, `'number'`, `'password'`, `'tel'`, `'text'`, `'url'`"
|
|
349
357
|
},
|
|
350
358
|
"attribute": "type",
|
|
351
359
|
"reflect": false,
|
|
@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E,EAAE,SAAS,CAAC,IAAI,CAAC,WAAW,EAAE,OAAO,CAAC,eAC9B,WAAW;wBAErB,iEAAU,IAAI,EAAE,MAAM,EAAE,IAAI,EAAC,OAAO,GAAG;wBACtC,IAAI,CAAC,YAAY,CAChB,CAEF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, State, Watch } from '@stencil/core';\nimport { assignDescription, messageId } from '../../utils/form';\nimport { danger } from '@pine-ds/icons/icons';\n\nimport { debounceEvent } from '@utils/utils';\nimport { inheritAriaAttributes } from '@utils/attributes';\n\nimport type { Attributes } from '@utils/attributes';\nimport type { InputChangeEventDetail, InputInputEventDetail } from './input-interface';\n\n@Component({\n tag: 'pds-input',\n styleUrls: ['pds-input.tokens.scss', '../../global/styles/utils/label.scss', 'pds-input.scss'],\n shadow: true,\n})\nexport class PdsInput {\n private nativeInput?: HTMLInputElement;\n private inheritedAttributes: Attributes = {};\n private isComposing = false;\n /**\n * The value of the input when the input is focused.\n */\n private focusedValue?: string | number | null;\n\n private originalPdsInput?: EventEmitter<InputInputEventDetail>;\n\n @Element() el!: HTMLPdsInputElement;\n\n /**\n * Emitted when the input loses focus.\n */\n @Event() pdsBlur!: EventEmitter<FocusEvent>;\n\n /**\n *\n * Emitted when the value has changed.\n *\n * This event will not emit when programmatically setting the `value` property.\n */\n @Event() pdsChange!: EventEmitter<InputChangeEventDetail>;\n\n /**\n * Emitted when the input has focus.\n */\n @Event() pdsFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when a keyboard input occurs.\n */\n @Event() pdsInput: EventEmitter<InputInputEventDetail>;\n\n /**\n * Sets focus on the native `input` in the `pds-input`. Use this method instead of the global\n * `input.focus()`.\n */\n @Method()\n async setFocus() {\n if ( this.nativeInput ) {\n this.nativeInput.focus();\n }\n }\n\n /**\n * Specifies if and how the browser provides `autocomplete` assistance for the field.\n */\n @Prop() autocomplete: string;\n\n /**\n * A unique identifier used for the underlying component `id` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * Sets the number of milliseconds to wait before updating the value.\n */\n @Prop() debounce?: number;\n\n /**\n * Determines whether or not the input field is disabled.\n */\n @Prop() disabled?: boolean;\n\n /**\n * Specifies the error message and provides an error-themed treatment to the field.\n */\n @Prop() errorMessage?: string;\n\n /**\n * Displays a message or hint below the input field.\n */\n @Prop() helperMessage?: string;\n\n /**\n * Determines whether or not the input field is invalid or throws an error.\n */\n @Prop() invalid?: boolean;\n\n /**\n * Text to be displayed as the input label.\n */\n @Prop() label?: string;\n\n /**\n * Specifies the name. Submitted with the form name/value pair.\n */\n @Prop() name?: string;\n\n /**\n * Specifies a short hint that describes the expected value of the input field.\n */\n @Prop() placeholder?: string;\n\n /**\n * Determines whether or not the input field is readonly.\n */\n @Prop() readonly?: boolean;\n\n /**\n * Determines whether or not the input field is required.\n */\n @Prop() required?: boolean;\n\n /**\n * Determines the type of control that will be displayed\n * `'email'`, `'number'`, `'password'`, `'tel'`, `'text'`\n * @defaultValue \"text\"\n */\n @Prop() type = 'text';\n\n /**\n * The value of the input.\n */\n @Prop({mutable: true}) value?: string | number | null = '';\n\n /**\n * Determines if the input has focus.\n */\n @State() hasFocus = false;\n\n\n @Watch('debounce')\n protected debounceChanged() {\n const { pdsInput, debounce, originalPdsInput } = this;\n\n /**\n * If debounce is undefined, we have to manually revert the pdsInput emitter in case\n * debounce used to be set to a number. Otherwise, the event would stay debounced.\n */\n this.pdsInput = debounce === undefined ? originalPdsInput ?? pdsInput : debounceEvent(pdsInput, debounce);\n }\n\n @Watch('value')\n protected valueChanged() {\n const nativeInput = this.nativeInput;\n const value = this.getValue();\n\n if (nativeInput && nativeInput.value !== value && !this.isComposing) {\n nativeInput.value = value;\n }\n }\n\n private getValue(): string {\n return typeof this.value === 'number' ? this.value.toString() : (this.value || '').toString();\n }\n\n private onInputEvent = (ev: Event) => {\n const input = ev.target as HTMLInputElement | null;\n if (input) {\n this.value = input.value || '';\n }\n this.emitInputChange(ev);\n };\n\n private onChangeEvent = (ev: Event) => {\n this.emitValueChange(ev);\n };\n\n private onBlurEvent = (ev: FocusEvent) => {\n this.hasFocus = false;\n\n if (this.focusedValue !== this.value) {\n /**\n * Emits the `pdsChange` event when the input value\n * is different than the value when the input was focused.\n */\n this.emitValueChange(ev);\n }\n\n this.pdsBlur.emit(ev);\n };\n\n private onFocusEvent = (ev: FocusEvent) => {\n this.hasFocus = true;\n this.focusedValue = this.value;\n\n this.pdsFocus.emit(ev);\n };\n\n private onCompositionStart = () => {\n this.isComposing = true;\n }\n\n private onCompositionEnd = () => {\n this.isComposing = false;\n }\n\n /**\n * Emits a pdsChange event\n */\n private emitValueChange(event?: Event) {\n const { value } = this;\n const newValue = value == null ? value : value.toString();\n\n this.focusedValue = newValue;\n this.pdsChange.emit({ value: newValue, event });\n }\n\n /**\n *\n * Emits a `pdsInput` event\n */\n private emitInputChange(event?: Event) {\n const { value } = this;\n\n // Checks for both null and undefined values\n const newValue = value == null ? value : value.toString();\n\n this.pdsInput.emit({ value: newValue, event });\n }\n\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el)\n }\n }\n\n componentDidLoad() {\n this.debounceChanged();\n }\n\n render() {\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n aria-readonly={this.readonly ? 'true' : null}\n >\n <div class=\"pds-input\">\n <label htmlFor={this.componentId}>{this.label}</label>\n <input class=\"pds-input__field\"\n ref={(input) => this.nativeInput = input}\n aria-describedby={assignDescription(this.componentId, this.invalid, this.helperMessage)}\n aria-invalid={this.invalid ? \"true\" : undefined}\n autocomplete={this.autocomplete}\n disabled={this.disabled}\n id={this.componentId}\n name={this.name}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n type={this.type}\n value={this.value}\n onInput={this.onInputEvent}\n onChange={this.onChangeEvent}\n onBlur={this.onBlurEvent}\n onFocus={this.onFocusEvent}\n onCompositionstart={this.onCompositionStart}\n onCompositionend={this.onCompositionEnd}\n {...this.inheritedAttributes}\n />\n {this.helperMessage &&\n <p\n class=\"pds-input__helper-message\"\n id={messageId(this.componentId, 'helper')}\n >\n {this.helperMessage}\n </p>\n }\n {this.errorMessage &&\n <p\n class=\"pds-input__error-message\"\n id={messageId(this.componentId, 'error')}\n aria-live=\"assertive\"\n >\n <pds-icon icon={danger} size=\"small\" />\n {this.errorMessage}\n </p>\n }\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pds-input.js","sourceRoot":"","sources":["../../../src/components/pds-input/pds-input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAC7G,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAU1D,MAAM,OAAO,QAAQ;;QAEX,wBAAmB,GAAe,EAAE,CAAC;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C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, State, Watch } from '@stencil/core';\nimport { assignDescription, messageId } from '../../utils/form';\nimport { danger } from '@pine-ds/icons/icons';\n\nimport { debounceEvent } from '@utils/utils';\nimport { inheritAriaAttributes } from '@utils/attributes';\n\nimport type { Attributes } from '@utils/attributes';\nimport type { InputChangeEventDetail, InputInputEventDetail } from './input-interface';\n\n@Component({\n tag: 'pds-input',\n styleUrls: ['pds-input.tokens.scss', '../../global/styles/utils/label.scss', 'pds-input.scss'],\n shadow: true,\n})\nexport class PdsInput {\n private nativeInput?: HTMLInputElement;\n private inheritedAttributes: Attributes = {};\n private isComposing = false;\n /**\n * The value of the input when the input is focused.\n */\n private focusedValue?: string | number | null;\n\n private originalPdsInput?: EventEmitter<InputInputEventDetail>;\n\n @Element() el!: HTMLPdsInputElement;\n\n /**\n * Emitted when the input loses focus.\n */\n @Event() pdsBlur!: EventEmitter<FocusEvent>;\n\n /**\n *\n * Emitted when the value has changed.\n *\n * This event will not emit when programmatically setting the `value` property.\n */\n @Event() pdsChange!: EventEmitter<InputChangeEventDetail>;\n\n /**\n * Emitted when the input has focus.\n */\n @Event() pdsFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when a keyboard input occurs.\n */\n @Event() pdsInput: EventEmitter<InputInputEventDetail>;\n\n /**\n * Sets focus on the native `input` in the `pds-input`. Use this method instead of the global\n * `input.focus()`.\n */\n @Method()\n async setFocus() {\n if ( this.nativeInput ) {\n this.nativeInput.focus();\n }\n }\n\n /**\n * Specifies if and how the browser provides `autocomplete` assistance for the field.\n */\n @Prop() autocomplete: string;\n\n /**\n * A unique identifier used for the underlying component `id` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * Sets the number of milliseconds to wait before updating the value.\n */\n @Prop() debounce?: number;\n\n /**\n * Determines whether or not the input field is disabled.\n */\n @Prop() disabled?: boolean;\n\n /**\n * Specifies the error message and provides an error-themed treatment to the field.\n */\n @Prop() errorMessage?: string;\n\n /**\n * Displays a message or hint below the input field.\n */\n @Prop() helperMessage?: string;\n\n /**\n * Determines whether or not the input field is invalid or throws an error.\n */\n @Prop() invalid?: boolean;\n\n /**\n * Text to be displayed as the input label.\n */\n @Prop() label?: string;\n\n /**\n * Specifies the name. Submitted with the form name/value pair.\n */\n @Prop() name?: string;\n\n /**\n * Specifies a short hint that describes the expected value of the input field.\n */\n @Prop() placeholder?: string;\n\n /**\n * Determines whether or not the input field is readonly.\n */\n @Prop() readonly?: boolean;\n\n /**\n * Determines whether or not the input field is required.\n */\n @Prop() required?: boolean;\n\n /**\n * Determines the type of control that will be displayed\n * `'email'`, `'number'`, `'password'`, `'tel'`, `'text'`, `'url'`\n * @defaultValue \"text\"\n */\n @Prop() type = 'text';\n\n /**\n * The value of the input.\n */\n @Prop({mutable: true}) value?: string | number | null = '';\n\n /**\n * Determines if the input has focus.\n */\n @State() hasFocus = false;\n\n\n @Watch('debounce')\n protected debounceChanged() {\n const { pdsInput, debounce, originalPdsInput } = this;\n\n /**\n * If debounce is undefined, we have to manually revert the pdsInput emitter in case\n * debounce used to be set to a number. Otherwise, the event would stay debounced.\n */\n this.pdsInput = debounce === undefined ? originalPdsInput ?? pdsInput : debounceEvent(pdsInput, debounce);\n }\n\n @Watch('value')\n protected valueChanged() {\n const nativeInput = this.nativeInput;\n const value = this.getValue();\n\n if (nativeInput && nativeInput.value !== value && !this.isComposing) {\n nativeInput.value = value;\n }\n }\n\n private getValue(): string {\n return typeof this.value === 'number' ? this.value.toString() : (this.value || '').toString();\n }\n\n private onInputEvent = (ev: Event) => {\n const input = ev.target as HTMLInputElement | null;\n if (input) {\n this.value = input.value || '';\n }\n this.emitInputChange(ev);\n };\n\n private onChangeEvent = (ev: Event) => {\n this.emitValueChange(ev);\n };\n\n private onBlurEvent = (ev: FocusEvent) => {\n this.hasFocus = false;\n\n if (this.focusedValue !== this.value) {\n /**\n * Emits the `pdsChange` event when the input value\n * is different than the value when the input was focused.\n */\n this.emitValueChange(ev);\n }\n\n this.pdsBlur.emit(ev);\n };\n\n private onFocusEvent = (ev: FocusEvent) => {\n this.hasFocus = true;\n this.focusedValue = this.value;\n\n this.pdsFocus.emit(ev);\n };\n\n private onCompositionStart = () => {\n this.isComposing = true;\n }\n\n private onCompositionEnd = () => {\n this.isComposing = false;\n }\n\n /**\n * Emits a pdsChange event\n */\n private emitValueChange(event?: Event) {\n const { value } = this;\n const newValue = value == null ? value : value.toString();\n\n this.focusedValue = newValue;\n this.pdsChange.emit({ value: newValue, event });\n }\n\n /**\n *\n * Emits a `pdsInput` event\n */\n private emitInputChange(event?: Event) {\n const { value } = this;\n\n // Checks for both null and undefined values\n const newValue = value == null ? value : value.toString();\n\n this.pdsInput.emit({ value: newValue, event });\n }\n\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el)\n }\n }\n\n componentDidLoad() {\n this.debounceChanged();\n }\n\n private inputClassNames() {\n const classNames = ['pds-input__field'];\n\n if (this.invalid && this.invalid === true) {\n classNames.push('is-invalid');\n }\n\n return classNames.join(' ');\n }\n\n render() {\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n aria-readonly={this.readonly ? 'true' : null}\n >\n <div class=\"pds-input\">\n {this.label &&\n <label class=\"pds-input__label\" htmlFor={this.componentId}>{this.label}</label>\n }\n <input\n class={this.inputClassNames()}\n ref={(input) => this.nativeInput = input}\n aria-describedby={assignDescription(this.componentId, this.invalid, this.helperMessage)}\n aria-invalid={this.invalid ? \"true\" : undefined}\n autocomplete={this.autocomplete}\n disabled={this.disabled}\n id={this.componentId}\n name={this.name}\n placeholder={this.placeholder}\n readOnly={this.readonly}\n required={this.required}\n type={this.type}\n value={this.value}\n onInput={this.onInputEvent}\n onChange={this.onChangeEvent}\n onBlur={this.onBlurEvent}\n onFocus={this.onFocusEvent}\n onCompositionstart={this.onCompositionStart}\n onCompositionend={this.onCompositionEnd}\n {...this.inheritedAttributes}\n />\n {this.helperMessage &&\n <p\n class=\"pds-input__helper-message\"\n id={messageId(this.componentId, 'helper')}\n >\n {this.helperMessage}\n </p>\n }\n {this.errorMessage &&\n <p\n class=\"pds-input__error-message\"\n id={messageId(this.componentId, 'error')}\n aria-live=\"assertive\"\n >\n <pds-icon icon={danger} size=\"small\" />\n {this.errorMessage}\n </p>\n }\n </div>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -23,8 +23,8 @@ export class PdsLink {
|
|
|
23
23
|
return classNames.join(' ');
|
|
24
24
|
}
|
|
25
25
|
render() {
|
|
26
|
-
return (h("a", { key: '
|
|
27
|
-
h("pds-icon", { key: '
|
|
26
|
+
return (h("a", { key: 'ee9b0a9897e2a212989d607c85f2050ee992bd32', class: this.classNames(), href: this.href, id: this.componentId, target: this.external ? '_blank' : undefined, part: "link" }, h("slot", { key: '611a4f9194ce38fd3b79c7e55281a625267846a4' }, this.href), this.external &&
|
|
27
|
+
h("pds-icon", { key: 'a527d217c8ef1e69a2ca127019fbeb3eb25b3a02', icon: launch, size: this.fontSize })));
|
|
28
28
|
}
|
|
29
29
|
static get is() { return "pds-link"; }
|
|
30
30
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
:host {
|
|
2
|
+
--loader-color: var(--pine-color-brand);
|
|
2
3
|
align-items: center;
|
|
3
4
|
display: flex;
|
|
4
5
|
flex-direction: column;
|
|
@@ -19,11 +20,10 @@
|
|
|
19
20
|
}
|
|
20
21
|
|
|
21
22
|
.pds-loader--spinner svg {
|
|
22
|
-
--color-background-spinner: var(--pine-color-brand);
|
|
23
23
|
--number-spinner-timing: 2s;
|
|
24
24
|
--number-spinner-path-timing: 1.5s;
|
|
25
25
|
animation: rotate var(--number-spinner-timing) linear infinite;
|
|
26
|
-
color: var(--color
|
|
26
|
+
color: var(--loader-color);
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
.pds-loader__spinner-path {
|
|
@@ -33,7 +33,7 @@ export class PdsLoader {
|
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
35
|
render() {
|
|
36
|
-
return (h(Host, { key: '
|
|
36
|
+
return (h(Host, { key: '7c8fdc4812310a291f992786f1e7951664afb8b6', class: `pds-loader ${this.isLoading ? '' : 'pds-loader--hidden'}`, "aria-hidden": !this.isLoading, "aria-busy": this.isLoading, "aria-live": "polite" }, this.variant === 'spinner' && (h("div", { key: '411dbd7e815b2160abcbd0049f9e310a9059452c', class: "pds-loader--spinner" }, h("svg", { key: '1d59dc3aea7bb51015680c3657abb964a7b69106', style: this.style(), viewBox: "0 0 200 200", fill: "none" }, h("defs", { key: '9ed887bf61bda5cda7662952dfc9add1e3e1ca40' }, h("linearGradient", { key: 'af416e97cbfbb1b2cc5c6a06f168165d60f984c8', id: "spinner-secondHalf" }, h("stop", { key: 'dd3d79c1b422dbc29a2f7af106d7e648ea739e09', offset: "0%", "stop-opacity": "0", "stop-color": "currentColor" }), h("stop", { key: '313ef7bbcaecad0f4bf8eb268e05ef3ff48f55be', offset: "100%", "stop-opacity": "0.5", "stop-color": "currentColor" })), h("linearGradient", { key: 'b36dde7b2648bb9bef120354f70bab8fbc3879a8', id: "spinner-firstHalf" }, h("stop", { key: '7d38062cf2f39b1be1b29e7799ac68c59744a172', offset: "0%", "stop-opacity": "1", "stop-color": "currentColor" }), h("stop", { key: 'bfe1ea074d55af2098eca57459c54cd92a1ecafc', offset: "100%", "stop-opacity": "0.5", "stop-color": "currentColor" }))), h("g", { key: '0d2ee2c9abe4b90f8c38246c847c43a942316686', class: "pds-loader__spinner-path" }, h("path", { key: '87b0fc01bc7fe59e596013011034e2e1d6eabd38', stroke: "url(#spinner-secondHalf)", d: "M 4 100 A 96 96 0 0 1 196 100" }), h("path", { key: '07b2c9ddd18117d1ef40f3e26f76bafc8c8c5309', stroke: "url(#spinner-firstHalf)", d: "M 196 100 A 96 96 0 0 1 4 100" }), h("path", { key: 'f4a88b3aaefb70c1cb5582f94d507efe88a66fbe', stroke: "currentColor", "stroke-linecap": "round", d: "M 4 100 A 96 96 0 0 1 4 98" }))))), this.variant === 'typing' && (h("div", { key: 'ab906177f012e882487a447338c1e1155524b8c3', class: "pds-loader--typing" }, h("span", { key: 'b7080dffb6dfb66bd89ca754880e7456b33f9cdb' }), h("span", { key: '0b7d00d9e3fcbaecbade0860a2a50cec6f13b017' }), h("span", { key: '0e8cca8e86dba84a7b22913d5458c0c232661526' }))), h("div", { key: '540aee483c31b199a1c4ec09e6a848661379e593', class: `pds-loader__label ${this.showLabel ? '' : 'pds-loader--hidden'}` }, h("slot", { key: 'f94f166ef6a1ef8a995efc664cd2ddf509ad51d8', name: "label" }, "Loading..."))));
|
|
37
37
|
}
|
|
38
38
|
static get is() { return "pds-loader"; }
|
|
39
39
|
static get encapsulation() { return "shadow"; }
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
:host [popover] {
|
|
6
6
|
background-color: var(--pine-color-background-container);
|
|
7
7
|
border: var(--pine-border);
|
|
8
|
-
border-radius:
|
|
8
|
+
border-radius: var(--pine-dimension-125);
|
|
9
9
|
box-shadow: var(--pine-box-shadow-200);
|
|
10
10
|
margin: var(--pine-dimension-none);
|
|
11
11
|
max-width: var(--sizing-max-width-default);
|
|
@@ -52,7 +52,7 @@ export class PdsPopover {
|
|
|
52
52
|
popoverEl.style.left = `${left}px`;
|
|
53
53
|
}
|
|
54
54
|
render() {
|
|
55
|
-
return (h(Host, { key: '
|
|
55
|
+
return (h(Host, { key: '83f5e8306d9a8f9e541e638af6fab4e83700c9ce' }, h("button", { key: '11a49c046a9258b64508c3a48dff8b63468358e0', class: "pds-popover__trigger", popoverTarget: this.componentId, popoverTargetAction: this.popoverTargetAction, onClick: this.handleClick }, this.text), h("div", { key: 'c4034a97e7d3aa794d4cf20891cb1ccd31895fa9', class: `pds-popover ${this.active ? 'pds-popover--active' : ''}`, id: this.componentId, popover: this.popoverType, style: { maxWidth: `${this.maxWidth}px` } }, h("slot", { key: '2005210e15c7f73efed54de5980c117f682cc476' }))));
|
|
56
56
|
}
|
|
57
57
|
static get is() { return "pds-popover"; }
|
|
58
58
|
static get encapsulation() { return "shadow"; }
|
|
@@ -9,7 +9,7 @@ export class PdsProgress {
|
|
|
9
9
|
this.showPercent = false;
|
|
10
10
|
}
|
|
11
11
|
render() {
|
|
12
|
-
return (h(Host, { key: '
|
|
12
|
+
return (h(Host, { key: 'c90714bd802c1ec10cc1d557b21c4761a348c559', class: this.animated ? { 'is-animated': this.animated } : '' }, h("div", { key: '969f33669523f2c67d30aa94652e3b70373b780a', class: "pds-progress" }, h("label", { key: '206a7c2297361caae1c5ecadacfd11939d8decee', class: "pds-progress__label", htmlFor: this.componentId }, this.label), h("progress", { key: 'e7748d02c4070bb894943fe0795a3c7008a43d62', id: this.componentId, max: "100", style: this.fillColor ? { '--color-progress-fill': this.fillColor } : {}, value: this.percent })), this.showPercent && h("div", { key: '7ec96692f3dc869069071bae747371ea6ef911ec', class: "pds-progress__percentage" }, this.percent, "%")));
|
|
13
13
|
}
|
|
14
14
|
static get is() { return "pds-progress"; }
|
|
15
15
|
static get encapsulation() { return "shadow"; }
|
|
@@ -30,10 +30,13 @@
|
|
|
30
30
|
|
|
31
31
|
input {
|
|
32
32
|
appearance: none;
|
|
33
|
+
background: var(--pine-color-background-container);
|
|
33
34
|
border: var(--pine-border);
|
|
34
35
|
border-radius: var(--pine-border-radius-full);
|
|
36
|
+
flex: none;
|
|
35
37
|
height: var(--sizing-input-size);
|
|
36
38
|
margin: 0;
|
|
39
|
+
margin-block-start: var(--pine-dimension-025);
|
|
37
40
|
position: relative;
|
|
38
41
|
width: var(--sizing-input-size);
|
|
39
42
|
}
|
|
@@ -85,13 +88,14 @@ input:focus-visible {
|
|
|
85
88
|
}
|
|
86
89
|
|
|
87
90
|
label {
|
|
88
|
-
|
|
91
|
+
display: flex;
|
|
92
|
+
gap: var(--pine-dimension-xs);
|
|
89
93
|
}
|
|
90
94
|
|
|
91
95
|
.pds-radio__message {
|
|
92
96
|
color: var(--pine-color-text-message);
|
|
93
97
|
margin-block-start: var(--sizing-margin-block-start);
|
|
94
|
-
margin-inline-start:
|
|
98
|
+
margin-inline-start: var(--pine-dimension-md);
|
|
95
99
|
width: 100%;
|
|
96
100
|
}
|
|
97
101
|
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Host, h } from "@stencil/core";
|
|
2
2
|
import { assignDescription, messageId } from "../../utils/form";
|
|
3
|
-
import { PdsLabel } from "../_internal/pds-label/pds-label";
|
|
4
3
|
import { danger } from "@pine-ds/icons/icons";
|
|
5
4
|
export class PdsRadio {
|
|
6
5
|
constructor() {
|
|
@@ -34,9 +33,9 @@ export class PdsRadio {
|
|
|
34
33
|
return classNames.join(' ');
|
|
35
34
|
}
|
|
36
35
|
render() {
|
|
37
|
-
return (h(Host, { key: '
|
|
38
|
-
h("div", { key: '
|
|
39
|
-
h("div", { key: '
|
|
36
|
+
return (h(Host, { key: '1a4f52f466f516a5803b5a539db579890fd5ec97', class: this.classNames() }, h("label", { key: 'fbf2fc5d2be220ad70e314c146f57e25536dbb13', htmlFor: this.componentId }, h("input", { key: '1016b5d553e30af9c2e7199a05cd75b30e725606', "aria-describedby": assignDescription(this.componentId, this.invalid, this.helperMessage), "aria-invalid": this.invalid ? "true" : undefined, type: "radio", id: this.componentId, name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, onChange: this.handleRadioChange }), this.label), this.helperMessage &&
|
|
37
|
+
h("div", { key: '4ac07622503e267abb9e0a808870e75b49329231', class: 'pds-radio__message', id: messageId(this.componentId, 'helper') }, this.helperMessage), this.errorMessage &&
|
|
38
|
+
h("div", { key: '808d6e1b93ed05b7875e9a5aeb7907a9c73f2410', class: `pds-radio__message pds-radio__message--error`, id: messageId(this.componentId, 'error'), "aria-live": "assertive" }, h("pds-icon", { key: 'c7bdadaf26d528c2ebb9e8790c9dd276ddb7d6b3', icon: danger, size: "small" }), this.errorMessage)));
|
|
40
39
|
}
|
|
41
40
|
static get is() { return "pds-radio"; }
|
|
42
41
|
static get encapsulation() { return "scoped"; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pds-radio.js","sourceRoot":"","sources":["../../../src/components/pds-radio/pds-radio.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAgB,MAAM,eAAe,CAAC;AAC9E,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"pds-radio.js","sourceRoot":"","sources":["../../../src/components/pds-radio/pds-radio.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAgB,MAAM,eAAe,CAAC;AAC9E,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAO9C,MAAM,OAAO,QAAQ;;QA4DX,sBAAiB,GAAG,CAAC,CAAQ,EAAE,EAAE;YACvC,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;gBAClB,OAAO;YACT,CAAC;YAED,MAAM,MAAM,GAAG,CAAC,CAAC,MAA0B,CA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C,IAAI,CAAC,WAAW,EAAE,QAAQ,CAAC,IAExC,IAAI,CAAC,aAAa,CACf;YAEP,IAAI,CAAC,YAAY;gBAChB,4DACE,KAAK,EAAE,8CAA8C,EACrD,EAAE,EAAE,SAAS,CAAC,IAAI,CAAC,WAAW,EAAE,OAAO,CAAC,eAC9B,WAAW;oBAErB,iEAAU,IAAI,EAAE,MAAM,EAAE,IAAI,EAAC,OAAO,GAAG;oBACtC,IAAI,CAAC,YAAY,CACd,CAEH,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h, Prop, Event, EventEmitter } from '@stencil/core';\nimport { assignDescription, messageId } from '../../utils/form';\nimport { danger } from '@pine-ds/icons/icons';\n\n@Component({\n tag: 'pds-radio',\n styleUrls: ['../../global/styles/utils/label.scss', 'pds-radio.scss'],\n scoped: true,\n})\nexport class PdsRadio {\n /**\n * Determines whether or not the radio is checked.\n * @defaultValue false\n */\n @Prop() checked = false;\n\n /**\n * A unique identifier used for the underlying component `id` attribute and the label `for` attribute.\n */\n @Prop() componentId!: string;\n\n /**\n * Determines whether or not the radio is disabled.\n * @defaultValue false\n */\n @Prop() disabled = false;\n\n /**\n * Displays error message text describing an invalid state.\n */\n @Prop() errorMessage: string;\n\n /**\n * Displays helper message text below radio.\n */\n @Prop() helperMessage: string;\n\n /**\n * Determines whether or not the radio is invalid.\n * @defaultValue false\n */\n @Prop() invalid = false;\n\n /**\n * String used for label text next to radio.\n */\n @Prop() label: string;\n\n /**\n * String used for radio `name` attribute.\n */\n @Prop() name: string;\n\n /**\n * Determines whether or not the radio is required.\n * @defaultValue false\n */\n @Prop() required = false;\n\n /**\n * The value of the radio that is submitted with a form.\n */\n @Prop() value: string;\n\n /**\n * Emits a boolean indicating whether the checkbox is currently checked or unchecked.\n */\n @Event() pdsRadioChange: EventEmitter<boolean>;\n\n private handleRadioChange = (e: Event) => {\n if (this.disabled) {\n return;\n }\n\n const target = e.target as HTMLInputElement;\n const isChecked = target.checked;\n\n this.pdsRadioChange.emit(isChecked);\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.invalid) {\n classNames.push('is-invalid');\n }\n if (this.disabled) {\n classNames.push('is-disabled');\n }\n\n return classNames.join(' ');\n }\n\n render() {\n return (\n <Host class={this.classNames()}>\n <label htmlFor={this.componentId}>\n <input\n aria-describedby={assignDescription(this.componentId, this.invalid, this.helperMessage)}\n aria-invalid={this.invalid ? \"true\" : undefined}\n type=\"radio\"\n id={this.componentId}\n name={this.name}\n value={this.value}\n checked={this.checked}\n required={this.required}\n disabled={this.disabled}\n onChange={this.handleRadioChange}\n />\n {this.label}\n </label>\n {this.helperMessage &&\n <div\n class={'pds-radio__message'}\n id={messageId(this.componentId, 'helper')}\n >\n {this.helperMessage}\n </div>\n }\n {this.errorMessage &&\n <div\n class={`pds-radio__message pds-radio__message--error`}\n id={messageId(this.componentId, 'error')}\n aria-live=\"assertive\"\n >\n <pds-icon icon={danger} size=\"small\" />\n {this.errorMessage}\n </div>\n }\n </Host>\n );\n }\n}\n"]}
|
|
@@ -32,7 +32,7 @@ export class PdsRow {
|
|
|
32
32
|
})), (this.minHeight && {
|
|
33
33
|
'min-height': this.minHeight,
|
|
34
34
|
}));
|
|
35
|
-
return h(Host, { key: '
|
|
35
|
+
return h(Host, { key: '1984453536572d4bab9efc4c07e64a4e39d9c80a', class: `pds-row ${rowClasses}`, style: rowInlineStyles });
|
|
36
36
|
}
|
|
37
37
|
static get is() { return "pds-row"; }
|
|
38
38
|
static get originalStyleUrls() {
|
|
@@ -24,8 +24,9 @@ label {
|
|
|
24
24
|
|
|
25
25
|
select {
|
|
26
26
|
appearance: none;
|
|
27
|
+
background: var(--pine-color-background-container);
|
|
27
28
|
border: var(--pine-border);
|
|
28
|
-
border-radius:
|
|
29
|
+
border-radius: var(--pine-dimension-125);
|
|
29
30
|
font: var(--pine-typography-body);
|
|
30
31
|
grid-area: field;
|
|
31
32
|
letter-spacing: var(--pine-letter-spacing);
|
|
@@ -70,7 +71,7 @@ select:has(~ .pds-select__message .pds-select__error-message):focus-visible {
|
|
|
70
71
|
.pds-select__helper-message {
|
|
71
72
|
font: var(--pine-typography-body-sm-medium);
|
|
72
73
|
margin-block-end: 0;
|
|
73
|
-
margin-block-start: var(--pine-dimension-
|
|
74
|
+
margin-block-start: var(--pine-dimension-2xs);
|
|
74
75
|
}
|
|
75
76
|
|
|
76
77
|
.pds-select__error-message {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Host, h } from "@stencil/core";
|
|
2
2
|
import { messageId } from "../../utils/form";
|
|
3
|
-
import { PdsLabel } from "../_internal/pds-label/pds-label";
|
|
4
3
|
import { danger, enlarge } from "@pine-ds/icons/icons";
|
|
5
4
|
export class PdsSelect {
|
|
6
5
|
constructor() {
|
|
@@ -111,7 +110,8 @@ export class PdsSelect {
|
|
|
111
110
|
return classNames.join(' ');
|
|
112
111
|
}
|
|
113
112
|
render() {
|
|
114
|
-
return (h(Host, { key: '
|
|
113
|
+
return (h(Host, { key: 'e2d3e77b8bf3bf697615ed3a64ea28d57e6e1804', "aria-disabled": this.disabled ? 'true' : null, class: this.classNames() }, h("div", { key: '1d465fa9b7266807bc1504c76cab0492e4785141', class: "pds-select" }, this.label &&
|
|
114
|
+
h("label", { key: '35d64c31a97e27847c67c6b9c49e7a825da97b5e', htmlFor: this.componentId }, this.label), h("select", { key: '30ec3dfe0fe9ef962392bbc010004613da28b680', autocomplete: this.autocomplete || undefined, class: "pds-select__field", disabled: this.disabled, id: this.componentId, multiple: this.multiple, name: this.name, onChange: this.onSelectUpdate, required: this.required, ref: (el) => (this.selectEl = el) }), h("div", { key: '8dd9a3b63fe5f577287db4f445db43701a995472', "aria-hidden": "true", class: "hidden", ref: (el) => (this.slotContainer = el) }, h("slot", { key: '1c202985751ac7ab7b42dd636a8d6c378d1d67b7', onSlotchange: this.handleSlotChange })), this.renderMessages(), !this.multiple && h("pds-icon", { key: '15731b205d0aad681ca8ca19fc69c1b49e3fc923', class: "pds-select__select-icon", icon: enlarge }))));
|
|
115
115
|
}
|
|
116
116
|
static get is() { return "pds-select"; }
|
|
117
117
|
static get encapsulation() { return "shadow"; }
|
|
@@ -242,7 +242,7 @@ export class PdsSelect {
|
|
|
242
242
|
"references": {}
|
|
243
243
|
},
|
|
244
244
|
"required": false,
|
|
245
|
-
"optional":
|
|
245
|
+
"optional": true,
|
|
246
246
|
"docs": {
|
|
247
247
|
"tags": [],
|
|
248
248
|
"text": "Text to be displayed as the select label."
|