@pine-ds/core 3.15.0 → 3.15.2-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/components/pds-dropdown-menu-item.js +3 -3
  2. package/components/pds-dropdown-menu-item.js.map +1 -1
  3. package/components/pds-multiselect.js +63 -32
  4. package/components/pds-multiselect.js.map +1 -1
  5. package/components/pds-table-row.js +1 -1
  6. package/components/pds-table-row.js.map +1 -1
  7. package/dist/cjs/loader.cjs.js +1 -1
  8. package/dist/cjs/pds-dropdown-menu-item.cjs.entry.js +1 -1
  9. package/dist/cjs/pds-dropdown-menu-item.entry.cjs.js.map +1 -1
  10. package/dist/cjs/pds-multiselect.cjs.entry.js +62 -32
  11. package/dist/cjs/pds-multiselect.entry.cjs.js.map +1 -1
  12. package/dist/cjs/pds-table-row.cjs.entry.js +1 -1
  13. package/dist/cjs/pds-table-row.entry.cjs.js.map +1 -1
  14. package/dist/cjs/pine-core.cjs.js +1 -1
  15. package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.js +3 -3
  16. package/dist/collection/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.js.map +1 -1
  17. package/dist/collection/components/pds-multiselect/pds-multiselect.js +81 -32
  18. package/dist/collection/components/pds-multiselect/pds-multiselect.js.map +1 -1
  19. package/dist/collection/components/pds-table/pds-table-row/pds-table-row.css +1 -1
  20. package/dist/docs.json +26 -3
  21. package/dist/esm/loader.js +1 -1
  22. package/dist/esm/pds-dropdown-menu-item.entry.js +1 -1
  23. package/dist/esm/pds-dropdown-menu-item.entry.js.map +1 -1
  24. package/dist/esm/pds-multiselect.entry.js +62 -32
  25. package/dist/esm/pds-multiselect.entry.js.map +1 -1
  26. package/dist/esm/pds-table-row.entry.js +1 -1
  27. package/dist/esm/pds-table-row.entry.js.map +1 -1
  28. package/dist/esm/pine-core.js +1 -1
  29. package/dist/esm-es5/loader.js +1 -1
  30. package/dist/esm-es5/pds-dropdown-menu-item.entry.js +1 -1
  31. package/dist/esm-es5/pds-dropdown-menu-item.entry.js.map +1 -1
  32. package/dist/esm-es5/pds-multiselect.entry.js +1 -1
  33. package/dist/esm-es5/pds-multiselect.entry.js.map +1 -1
  34. package/dist/esm-es5/pds-table-row.entry.js +1 -1
  35. package/dist/esm-es5/pds-table-row.entry.js.map +1 -1
  36. package/dist/esm-es5/pine-core.js +1 -1
  37. package/dist/pine-core/{p-4ed357a4.entry.js → p-4c2809cb.entry.js} +2 -2
  38. package/dist/pine-core/p-4c2809cb.entry.js.map +1 -0
  39. package/dist/pine-core/{p-795e1727.entry.js → p-56cf3af8.entry.js} +2 -2
  40. package/dist/pine-core/{p-ef56bc80.system.entry.js → p-5f552640.system.entry.js} +2 -2
  41. package/dist/pine-core/p-93d0be59.entry.js +2 -0
  42. package/dist/pine-core/{p-88dd25dd.entry.js.map → p-93d0be59.entry.js.map} +1 -1
  43. package/dist/pine-core/p-Dtx30lCy.system.js.map +1 -0
  44. package/dist/pine-core/p-JAVnELnm.system.js +1 -1
  45. package/dist/pine-core/p-ZUqfslIz.system.js.map +1 -0
  46. package/dist/pine-core/p-aeb2f6ac.system.entry.js +2 -0
  47. package/dist/pine-core/{p-63a669c9.system.entry.js.map → p-aeb2f6ac.system.entry.js.map} +1 -1
  48. package/dist/pine-core/p-anXbtQm4.system.js.map +1 -0
  49. package/dist/pine-core/{p-ae359dc7.system.entry.js → p-b98a04cd.system.entry.js} +2 -2
  50. package/dist/pine-core/p-b98a04cd.system.entry.js.map +1 -0
  51. package/dist/pine-core/pds-dropdown-menu-item.entry.esm.js.map +1 -1
  52. package/dist/pine-core/pds-multiselect.entry.esm.js.map +1 -1
  53. package/dist/pine-core/pds-table-row.entry.esm.js.map +1 -1
  54. package/dist/pine-core/pine-core.esm.js +1 -1
  55. package/dist/types/components/pds-multiselect/pds-multiselect.d.ts +5 -0
  56. package/dist/types/components.d.ts +8 -0
  57. package/dist/vscode.html-data.json +10343 -0
  58. package/hydrate/index.js +68 -37
  59. package/hydrate/index.mjs +68 -37
  60. package/package.json +2 -2
  61. package/dist/pine-core/p-4ed357a4.entry.js.map +0 -1
  62. package/dist/pine-core/p-63a669c9.system.entry.js +0 -2
  63. package/dist/pine-core/p-88dd25dd.entry.js +0 -2
  64. package/dist/pine-core/p-CWPG1B5Z.system.js.map +0 -1
  65. package/dist/pine-core/p-DgtQU13G.system.js.map +0 -1
  66. package/dist/pine-core/p-DwXA2Glx.system.js.map +0 -1
  67. package/dist/pine-core/p-ae359dc7.system.entry.js.map +0 -1
  68. /package/dist/pine-core/{p-795e1727.entry.js.map → p-56cf3af8.entry.js.map} +0 -0
  69. /package/dist/pine-core/{p-ef56bc80.system.entry.js.map → p-5f552640.system.entry.js.map} +0 -0
@@ -1 +1 @@
1
- {"file":"pds-table-row.js","mappings":";;;;;;AAAA,MAAM,cAAc,GAAG,w9BAAw9B;;MCSl+BA,aAAW,iBAAAC,kBAAA,CAAA,MAAA,WAAA,SAAA,WAAA,CAAA;AALxB,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;;AAQU,QAAA,IAAQ,CAAA,QAAA,GAA4B,IAAI;AACxC,QAAA,IAAY,CAAA,YAAA,GAA4B,IAAI;AAYpD;;;AAGG;AACc,QAAA,IAAU,CAAA,UAAA,GAAY,KAAK;AAE5C;;;AAGG;AACc,QAAA,IAAS,CAAA,SAAA,GAAY,KAAK;AAOnC,QAAA,IAAW,CAAA,WAAA,GAAG,MAAK;YACzB,IAAI,CAAC,UAAU,GAAG,CAAC,IAAI,CAAC,UAAU,CAAC;AACnC,YAAA,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,UAAU,CAAC;AACpC,SAAC;AAEO,QAAA,IAAA,CAAA,YAAY,GAAG,CAAC,UAAmB,KAAI;AAC7C,YAAA,IAAI,CAAC,aAAa,GAAG,KAAK;YAE1B,IAAI,CAAC,OAAO,CAAC,gBAAgB,EAAE,IAAI,CAAC,WAAW,C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M,GAAA;AACJ,QAAA,QACE,CAAC,CAAA,IAAI,EACH,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAE,IAAI,CAAC,UAAU,EAAE,EACxB,IAAI,EAAC,KAAK,EACV,IAAI,EAAC,KAAK,EAAA,EAET,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,QAAQ,CAAC,UAAU,KACxC,CAAA,CAAA,gBAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAgB,IAAI,EAAE,IAAI,CAAC,QAAQ,CAAC,WAAW,GAAG,eAAe,GAAG,eAAe,EAAE,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,UAAU,GAAG,cAAc,GAAG,EAAE,EAAA,EACxI,CAAA,CAAA,cAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,WAAW,EAAE,IAAI,CAAC,gBAAgB,EAAE,EACpC,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,aAAa,EAAE,IAAI,CAAC,aAAa,EACjC,KAAK,EAAE,YAAY,EACnB,SAAS,EAAE,IAAI,EACf,OAAO,EAAE,IAAI,CAAC,UAAU,EACxB,IAAI,EAAC,cAAc,EAAA,CACnB,CACa,CAClB,EACD,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["PdsTableRow","__stencil_proxyCustomElement"],"sources":["src/components/pds-table/pds-table-row/pds-table-row.scss?tag=pds-table-row&encapsulation=shadow","src/components/pds-table/pds-table-row/pds-table-row.tsx"],"sourcesContent":[":host {\n --color-background-interactive: var(--pine-color-border-disabled);\n\n border-color: inherit;\n display: table-row;\n vertical-align: inherit;\n\n // used for pds-checkbox-cell\n // because it is in the ShadowDom\n &::part(checkbox-cell) {\n background-color: var(--pine-color-background-container);\n inset-inline-start: var(--pine-dimension-none);\n position: sticky;\n z-index: var(--pine-z-index-raised);\n }\n}\n\n:host(:hover),\n:host(:hover)::part(checkbox-cell),\n:host(:hover) ::slotted(pds-table-cell),\n:host(.is-selected),\n:host(.is-selected)::part(checkbox-cell),\n:host(.is-selected) ::slotted(pds-table-cell) {\n background: var(--color-background-interactive);\n}\n\n:host(.has-divider) ::slotted(pds-table-cell),\n:host(.has-divider) pds-table-cell {\n border-block-end: var(--pine-border-width-thin) solid var(--pine-color-border-subtle);\n}\n\n:host(.has-divider.is-last-row) ::slotted(pds-table-cell),\n:host(.has-divider.is-last-row) pds-table-cell {\n border-block-end: 0;\n}\n","import { Component, Element, Host, h, Event, EventEmitter, Prop, State } from '@stencil/core';\n\nimport { closest } from '../../../utils/closest';\n\n@Component({\n tag: 'pds-table-row',\n styleUrls: ['pds-table-row.scss'],\n shadow: true,\n})\nexport class PdsTableRow {\n @Element() hostElement: HTMLPdsTableRowElement;\n private tableRef: HTMLPdsTableElement;\n private observer: MutationObserver | null = null;\n private bodyObserver: MutationObserver | null = null;\n\n /**\n * Determines if the row selected is in an indeterminate state.\n */\n @Prop({ mutable: true }) indeterminate?: boolean;\n\n /**\n * Determines if the table row is currently selected.\n */\n @Prop({ mutable: true }) isSelected?: boolean;\n\n /**\n * Determines if the row should have a divider border.\n * @defaultValue false\n */\n @State() private hasDivider: boolean = false;\n\n /**\n * Determines if this is the last row in the table body.\n * @defaultValue false\n */\n @State() private isLastRow: boolean = false;\n\n /**\n * Event that is emitted when the checkbox is clicked, carrying the selected value.\n */\n @Event() pdsTableRowSelected: EventEmitter<{ rowIndex: number; isSelected: boolean; }>;\n\n private handleClick = () => {\n this.isSelected = !this.isSelected; // Toggle the selected state\n this.handleSelect(this.isSelected);\n }\n\n private handleSelect = (isSelected: boolean) => {\n this.indeterminate = false;\n\n if (!closest('pds-table-head', this.hostElement)) {\n const rowIndex = Array.from(this.hostElement.parentNode.children).indexOf(this.hostElement)\n this.pdsTableRowSelected.emit({\n rowIndex,\n isSelected,\n })\n }\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.isSelected) {\n classNames.push(\"is-selected\");\n }\n\n if (this.hasDivider) {\n classNames.push(\"has-divider\");\n }\n\n if (this.isLastRow) {\n classNames.push(\"is-last-row\");\n }\n\n return classNames.join(' ');\n }\n\n componentWillRender() {\n // Always refresh tableRef to get latest prop values\n // This ensures we pick up changes to parent table props\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n\n if (this.tableRef && this.tableRef.fixedColumn) {\n const tableCell = this.hostElement.querySelector('pds-table-cell');\n tableCell?.classList.add(\"is-fixed\");\n }\n }\n\n componentWillLoad() {\n // Handle initial selection state\n if (this.isSelected) {\n this.handleSelect(this.isSelected);\n }\n // Note: tableRef, observers, and divider state are set up in connectedCallback\n // which runs before componentWillLoad and also handles row re-attachment after sorting\n }\n\n connectedCallback() {\n // When a row is re-attached to the DOM (e.g., after sorting),\n // we need to re-setup the observers since disconnectedCallback cleared them\n // Note: componentDidLoad only fires once, but connectedCallback fires every time\n // the element is attached to the DOM (including after being moved)\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n this.setupObservers();\n this.updateDividerState();\n }\n\n disconnectedCallback() {\n this.cleanupObservers();\n }\n\n private cleanupObservers() {\n if (this.observer) {\n this.observer.disconnect();\n this.observer = null;\n }\n if (this.bodyObserver) {\n this.bodyObserver.disconnect();\n this.bodyObserver = null;\n }\n }\n\n private setupObservers() {\n // Clean up any existing observers first\n this.cleanupObservers();\n\n // Watch for changes to the parent table's row-dividers attribute\n if (this.tableRef && typeof MutationObserver !== 'undefined') {\n this.observer = new MutationObserver(() => {\n this.updateDividerState();\n });\n\n this.observer.observe(this.tableRef, {\n attributes: true,\n attributeFilter: ['row-dividers']\n });\n }\n\n // Watch for child list changes in table body (e.g., when rows are reordered during sorting)\n const tableBody = this.hostElement.closest('pds-table-body');\n if (tableBody && typeof MutationObserver !== 'undefined') {\n this.bodyObserver = new MutationObserver(() => {\n this.updateLastRowState();\n });\n\n this.bodyObserver.observe(tableBody, {\n childList: true\n });\n }\n }\n\n private shouldHaveDivider(): boolean {\n if (!this.tableRef) {\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n }\n // Reads the parent pds-table component's rowDividers property value directly\n return !!(this.tableRef && this.tableRef.rowDividers);\n }\n\n private updateDividerState() {\n this.hasDivider = this.shouldHaveDivider();\n this.updateLastRowState();\n }\n\n private updateLastRowState() {\n if (!this.hasDivider) {\n this.isLastRow = false;\n return;\n }\n\n const tableBody = this.hostElement.closest('pds-table-body');\n if (tableBody) {\n const rows = Array.from(tableBody.querySelectorAll('pds-table-row'));\n this.isLastRow = rows[rows.length - 1] === this.hostElement;\n } else {\n this.isLastRow = false;\n }\n }\n\n private generateUniqueId = () => {\n const randomString = Math.random().toString(36).substring(2, 8);\n const timestamp = new Date().toISOString().replace(/[:.]/g, '-');\n const uniqueId = `${randomString}-${timestamp}`;\n\n return uniqueId;\n }\n\n render() {\n return (\n <Host\n class={this.classNames()}\n role=\"row\"\n part=\"row\"\n >\n {this.tableRef && this.tableRef.selectable && (\n <pds-table-cell part={this.tableRef.fixedColumn ? 'checkbox-cell' : 'checkbox-cell'} class={this.tableRef.selectable ? 'has-checkbox' : ''} >\n <pds-checkbox\n componentId={this.generateUniqueId()}\n onClick={this.handleClick}\n indeterminate={this.indeterminate}\n label={\"Select Row\"}\n hideLabel={true}\n checked={this.isSelected}\n part=\"row-checkbox\"\n />\n </pds-table-cell>\n )}\n <slot></slot>\n </Host>\n );\n }\n}\n"],"version":3}
1
+ {"file":"pds-table-row.js","mappings":";;;;;;AAAA,MAAM,cAAc,GAAG,09BAA09B;;MCSp+BA,aAAW,iBAAAC,kBAAA,CAAA,MAAA,WAAA,SAAA,WAAA,CAAA;AALxB,IAAA,WAAA,CAAA,YAAA,EAAA;;;;;;;AAQU,QAAA,IAAQ,CAAA,QAAA,GAA4B,IAAI;AACxC,QAAA,IAAY,CAAA,YAAA,GAA4B,IAAI;AAYpD;;;AAGG;AACc,QAAA,IAAU,CAAA,UAAA,GAAY,KAAK;AA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;;;;;;;;;;;;;;;;;;;;;","names":["PdsTableRow","__stencil_proxyCustomElement"],"sources":["src/components/pds-table/pds-table-row/pds-table-row.scss?tag=pds-table-row&encapsulation=shadow","src/components/pds-table/pds-table-row/pds-table-row.tsx"],"sourcesContent":[":host {\n --color-background-interactive: var(--pine-color-background-subtle);\n\n border-color: inherit;\n display: table-row;\n vertical-align: inherit;\n\n // used for pds-checkbox-cell\n // because it is in the ShadowDom\n &::part(checkbox-cell) {\n background-color: var(--pine-color-background-container);\n inset-inline-start: var(--pine-dimension-none);\n position: sticky;\n z-index: var(--pine-z-index-raised);\n }\n}\n\n:host(:hover),\n:host(:hover)::part(checkbox-cell),\n:host(:hover) ::slotted(pds-table-cell),\n:host(.is-selected),\n:host(.is-selected)::part(checkbox-cell),\n:host(.is-selected) ::slotted(pds-table-cell) {\n background: var(--color-background-interactive);\n}\n\n:host(.has-divider) ::slotted(pds-table-cell),\n:host(.has-divider) pds-table-cell {\n border-block-end: var(--pine-border-width-thin) solid var(--pine-color-border-subtle);\n}\n\n:host(.has-divider.is-last-row) ::slotted(pds-table-cell),\n:host(.has-divider.is-last-row) pds-table-cell {\n border-block-end: 0;\n}\n","import { Component, Element, Host, h, Event, EventEmitter, Prop, State } from '@stencil/core';\n\nimport { closest } from '../../../utils/closest';\n\n@Component({\n tag: 'pds-table-row',\n styleUrls: ['pds-table-row.scss'],\n shadow: true,\n})\nexport class PdsTableRow {\n @Element() hostElement: HTMLPdsTableRowElement;\n private tableRef: HTMLPdsTableElement;\n private observer: MutationObserver | null = null;\n private bodyObserver: MutationObserver | null = null;\n\n /**\n * Determines if the row selected is in an indeterminate state.\n */\n @Prop({ mutable: true }) indeterminate?: boolean;\n\n /**\n * Determines if the table row is currently selected.\n */\n @Prop({ mutable: true }) isSelected?: boolean;\n\n /**\n * Determines if the row should have a divider border.\n * @defaultValue false\n */\n @State() private hasDivider: boolean = false;\n\n /**\n * Determines if this is the last row in the table body.\n * @defaultValue false\n */\n @State() private isLastRow: boolean = false;\n\n /**\n * Event that is emitted when the checkbox is clicked, carrying the selected value.\n */\n @Event() pdsTableRowSelected: EventEmitter<{ rowIndex: number; isSelected: boolean; }>;\n\n private handleClick = () => {\n this.isSelected = !this.isSelected; // Toggle the selected state\n this.handleSelect(this.isSelected);\n }\n\n private handleSelect = (isSelected: boolean) => {\n this.indeterminate = false;\n\n if (!closest('pds-table-head', this.hostElement)) {\n const rowIndex = Array.from(this.hostElement.parentNode.children).indexOf(this.hostElement)\n this.pdsTableRowSelected.emit({\n rowIndex,\n isSelected,\n })\n }\n }\n\n private classNames() {\n const classNames = [];\n\n if (this.isSelected) {\n classNames.push(\"is-selected\");\n }\n\n if (this.hasDivider) {\n classNames.push(\"has-divider\");\n }\n\n if (this.isLastRow) {\n classNames.push(\"is-last-row\");\n }\n\n return classNames.join(' ');\n }\n\n componentWillRender() {\n // Always refresh tableRef to get latest prop values\n // This ensures we pick up changes to parent table props\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n\n if (this.tableRef && this.tableRef.fixedColumn) {\n const tableCell = this.hostElement.querySelector('pds-table-cell');\n tableCell?.classList.add(\"is-fixed\");\n }\n }\n\n componentWillLoad() {\n // Handle initial selection state\n if (this.isSelected) {\n this.handleSelect(this.isSelected);\n }\n // Note: tableRef, observers, and divider state are set up in connectedCallback\n // which runs before componentWillLoad and also handles row re-attachment after sorting\n }\n\n connectedCallback() {\n // When a row is re-attached to the DOM (e.g., after sorting),\n // we need to re-setup the observers since disconnectedCallback cleared them\n // Note: componentDidLoad only fires once, but connectedCallback fires every time\n // the element is attached to the DOM (including after being moved)\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n this.setupObservers();\n this.updateDividerState();\n }\n\n disconnectedCallback() {\n this.cleanupObservers();\n }\n\n private cleanupObservers() {\n if (this.observer) {\n this.observer.disconnect();\n this.observer = null;\n }\n if (this.bodyObserver) {\n this.bodyObserver.disconnect();\n this.bodyObserver = null;\n }\n }\n\n private setupObservers() {\n // Clean up any existing observers first\n this.cleanupObservers();\n\n // Watch for changes to the parent table's row-dividers attribute\n if (this.tableRef && typeof MutationObserver !== 'undefined') {\n this.observer = new MutationObserver(() => {\n this.updateDividerState();\n });\n\n this.observer.observe(this.tableRef, {\n attributes: true,\n attributeFilter: ['row-dividers']\n });\n }\n\n // Watch for child list changes in table body (e.g., when rows are reordered during sorting)\n const tableBody = this.hostElement.closest('pds-table-body');\n if (tableBody && typeof MutationObserver !== 'undefined') {\n this.bodyObserver = new MutationObserver(() => {\n this.updateLastRowState();\n });\n\n this.bodyObserver.observe(tableBody, {\n childList: true\n });\n }\n }\n\n private shouldHaveDivider(): boolean {\n if (!this.tableRef) {\n this.tableRef = this.hostElement.closest('pds-table') as HTMLPdsTableElement;\n }\n // Reads the parent pds-table component's rowDividers property value directly\n return !!(this.tableRef && this.tableRef.rowDividers);\n }\n\n private updateDividerState() {\n this.hasDivider = this.shouldHaveDivider();\n this.updateLastRowState();\n }\n\n private updateLastRowState() {\n if (!this.hasDivider) {\n this.isLastRow = false;\n return;\n }\n\n const tableBody = this.hostElement.closest('pds-table-body');\n if (tableBody) {\n const rows = Array.from(tableBody.querySelectorAll('pds-table-row'));\n this.isLastRow = rows[rows.length - 1] === this.hostElement;\n } else {\n this.isLastRow = false;\n }\n }\n\n private generateUniqueId = () => {\n const randomString = Math.random().toString(36).substring(2, 8);\n const timestamp = new Date().toISOString().replace(/[:.]/g, '-');\n const uniqueId = `${randomString}-${timestamp}`;\n\n return uniqueId;\n }\n\n render() {\n return (\n <Host\n class={this.classNames()}\n role=\"row\"\n part=\"row\"\n >\n {this.tableRef && this.tableRef.selectable && (\n <pds-table-cell part={this.tableRef.fixedColumn ? 'checkbox-cell' : 'checkbox-cell'} class={this.tableRef.selectable ? 'has-checkbox' : ''} >\n <pds-checkbox\n componentId={this.generateUniqueId()}\n onClick={this.handleClick}\n indeterminate={this.indeterminate}\n label={\"Select Row\"}\n hideLabel={true}\n checked={this.isSelected}\n part=\"row-checkbox\"\n />\n </pds-table-cell>\n )}\n <slot></slot>\n </Host>\n );\n }\n}\n"],"version":3}
@@ -5,7 +5,7 @@ var index = require('./index-CI0W8NCh.js');
5
5
  const defineCustomElements = async (win, options) => {
6
6
  if (typeof window === 'undefined') return undefined;
7
7
  await index.globalScripts();
8
- 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\"],\"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\":[4],\"target\":[1],\"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);
8
+ 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\"],\"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);
9
9
  };
10
10
 
11
11
  exports.setNonce = index.setNonce;
@@ -76,7 +76,7 @@ const PdsDropdownMenuItem = class {
76
76
  }, 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 }, index.h("slot", null)));
77
77
  }
78
78
  render() {
79
- return (index.h(index.Host, { key: '81fce1eaf2020b0e524dbbe0d872f29771b3a0f9', 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()));
79
+ return (index.h(index.Host, { key: '2a0603c754506f9ff9293db0868342a057265b64', 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()));
80
80
  }
81
81
  get host() { return index.getElement(this); }
82
82
  };
@@ -1 +1 @@
1
- {"version":3,"file":"pds-dropdown-menu-item.entry.cjs.js","sources":["src/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.scss?tag=pds-dropdown-menu-item&encapsulation=shadow","src/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.tsx"],"sourcesContent":[":host {\n cursor: pointer;\n display: flex;\n width: 100%; /* Ensure the host takes full width */\n}\n\n/* Make the disabled styles more specific and add !important to ensure they apply */\n:host(.is-disabled) {\n cursor: not-allowed !important;\n opacity: 0.5 !important;\n\n .pds-dropdown-menu-item__content {\n cursor: not-allowed !important;\n pointer-events: none !important;\n }\n}\n\n.pds-dropdown-menu-item__content {\n align-items: center;\n appearance: none;\n background: transparent;\n border: 0;\n border-radius: var(--pine-dimension-xs);\n color: var(--pine-color-text);\n display: flex;\n flex-grow: 1; /* Make it grow to fill available space */\n font: var(--pine-typography-body-medium);\n gap: var(--pine-dimension-xs);\n margin: calc(var(--pine-border-width) + 2px);\n padding: var(--pine-dimension-xs);\n text-align: start; /* Ensure text aligns properly */\n width: 100%; /* Ensure full width */\n\n &:hover {\n background-color: var(--pine-color-background-muted);\n color: var(--pine-color-text-hover);\n }\n\n /* Focus styles applied via class + browser focus */\n &:focus,\n &:focus-visible,\n &.has-focus {\n outline: var(--pine-outline-focus);\n outline-offset: var(--pine-border-width);\n }\n\n}\n\n:host(.destructive) {\n .pds-dropdown-menu-item__content {\n align-items: center;\n color: var(--pine-color-danger);\n\n &:hover {\n background-color: var(--pine-color-danger-disabled);\n color: var(--pine-color-danger-hover);\n }\n\n &:focus,\n &:focus-visible,\n &.has-focus {\n background-color: var(--pine-color-danger-disabled);\n outline: var(--pine-outline-focus-danger);\n outline-offset: var(--pine-border-width);\n }\n }\n}\n\n/* Remove outline on contained links using the custom property */\npds-link::part(link):focus,\npds-link::part(link):focus-visible {\n box-shadow: none;\n outline: none;\n}\n\npds-link::part(link) {\n display: block;\n margin: calc(var(--pine-dimension-xs) * -1);\n padding: var(--pine-dimension-xs);\n text-decoration: none;\n width: calc(100% + var(--pine-dimension-xs) * 2);\n}\n","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() 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() 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() 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"],"names":["h","Host"],"mappings":";;;;AAAA,MAAM,sBAAsB,GAAG,67DAA67D;;MCQ/8D,mBAAmB,GAAA,MAAA;AALhC,IAAA,WAAA,CAAA,OAAA,EAAA;;;AAaE;;;AAGG;AACK,QAAA,IAAW,CAAA,WAAA,GAAY,KAAK;AAEpC;;;AAGG;AACK,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;AAQjC;;;;AAIG;AACK,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;AA0CxB,QAAA,IAAQ,CAAA,QAAA,GAAY,K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,EAAE,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,WAAW,EAAE,EAC1F,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,WAAW,EAAE,EACnD,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,EAAE,EAAA,eAAA,EACG,IAAI,CAAC,QAAQ,GAAG,MAAM,GAAG,IAAI,EAAA,EAEzC,IAAI,CAAC,aAAa,EAAE,CAClB;;;;;;;;"}
1
+ {"version":3,"file":"pds-dropdown-menu-item.entry.cjs.js","sources":["src/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.scss?tag=pds-dropdown-menu-item&encapsulation=shadow","src/components/pds-dropdown-menu/pds-dropdown-menu-item/pds-dropdown-menu-item.tsx"],"sourcesContent":[":host {\n cursor: pointer;\n display: flex;\n width: 100%; /* Ensure the host takes full width */\n}\n\n/* Make the disabled styles more specific and add !important to ensure they apply */\n:host(.is-disabled) {\n cursor: not-allowed !important;\n opacity: 0.5 !important;\n\n .pds-dropdown-menu-item__content {\n cursor: not-allowed !important;\n pointer-events: none !important;\n }\n}\n\n.pds-dropdown-menu-item__content {\n align-items: center;\n appearance: none;\n background: transparent;\n border: 0;\n border-radius: var(--pine-dimension-xs);\n color: var(--pine-color-text);\n display: flex;\n flex-grow: 1; /* Make it grow to fill available space */\n font: var(--pine-typography-body-medium);\n gap: var(--pine-dimension-xs);\n margin: calc(var(--pine-border-width) + 2px);\n padding: var(--pine-dimension-xs);\n text-align: start; /* Ensure text aligns properly */\n width: 100%; /* Ensure full width */\n\n &:hover {\n background-color: var(--pine-color-background-muted);\n color: var(--pine-color-text-hover);\n }\n\n /* Focus styles applied via class + browser focus */\n &:focus,\n &:focus-visible,\n &.has-focus {\n outline: var(--pine-outline-focus);\n outline-offset: var(--pine-border-width);\n }\n\n}\n\n:host(.destructive) {\n .pds-dropdown-menu-item__content {\n align-items: center;\n color: var(--pine-color-danger);\n\n &:hover {\n background-color: var(--pine-color-danger-disabled);\n color: var(--pine-color-danger-hover);\n }\n\n &:focus,\n &:focus-visible,\n &.has-focus {\n background-color: var(--pine-color-danger-disabled);\n outline: var(--pine-outline-focus-danger);\n outline-offset: var(--pine-border-width);\n }\n }\n}\n\n/* Remove outline on contained links using the custom property */\npds-link::part(link):focus,\npds-link::part(link):focus-visible {\n box-shadow: none;\n outline: none;\n}\n\npds-link::part(link) {\n display: block;\n margin: calc(var(--pine-dimension-xs) * -1);\n padding: var(--pine-dimension-xs);\n text-decoration: none;\n width: calc(100% + var(--pine-dimension-xs) * 2);\n}\n","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() 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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AAE,IAAI,CAAC,UAAU,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EAAA,eAAA,EACR,IAAI,CAAC,QAAQ,GAAG,MAAM,GAAG,IAAI,EAAA,EAE5CA,OAAa,CAAA,MAAA,EAAA,IAAA,CAAA,CACN;;IAgBb,MAAM,GAAA;AACJ,QAAA,QACEA,OAAA,CAACC,UAAI,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAC,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,MAAM,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,WAAW,EAAE,EACnD,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,EAAE,EAAA,eAAA,EACG,IAAI,CAAC,QAAQ,GAAG,MAAM,GAAG,IAAI,EAAA,EAEzC,IAAI,CAAC,aAAa,EAAE,CAClB;;;;;;;;"}
@@ -328,9 +328,25 @@ const PdsMultiselect = class {
328
328
  // Ensure value is an array (may be string from HTML attribute)
329
329
  const valueArray = this.ensureValueArray();
330
330
  const allOptions = this.getAllOptions();
331
- this.selectedItems = valueArray
332
- .map(val => allOptions.find(opt => String(opt.id) === String(val)))
333
- .filter((opt) => opt !== undefined);
331
+ // Map values to options, preserving existing selectedItems for values not yet in options
332
+ const newSelectedItems = [];
333
+ const existingItemsMap = new Map(this.selectedItems.map(item => [String(item.id), item]));
334
+ valueArray.forEach(val => {
335
+ // First try to find in available options
336
+ const option = allOptions.find(opt => String(opt.id) === String(val));
337
+ if (option) {
338
+ newSelectedItems.push(option);
339
+ }
340
+ else if (existingItemsMap.has(String(val))) {
341
+ // If not in options but exists in current selectedItems, preserve it
342
+ // This handles the case where async data hasn't loaded yet or newly created items
343
+ newSelectedItems.push(existingItemsMap.get(String(val)));
344
+ }
345
+ // Note: We don't create placeholders for values without matching options.
346
+ // This ensures selectedItems remains empty until options are actually loaded,
347
+ // which matches the expected behavior for preselected values.
348
+ });
349
+ this.selectedItems = newSelectedItems;
334
350
  }
335
351
  ensureValueArray() {
336
352
  // Handle JSON string values passed via HTML attribute
@@ -396,6 +412,15 @@ const PdsMultiselect = class {
396
412
  }
397
413
  }
398
414
  }
415
+ getCsrfToken() {
416
+ // Use provided token if available
417
+ if (this.csrfToken) {
418
+ return this.csrfToken;
419
+ }
420
+ // Try to read from meta tag
421
+ const metaTag = document.querySelector('meta[name="csrf-token"]');
422
+ return (metaTag === null || metaTag === void 0 ? void 0 : metaTag.content) || null;
423
+ }
399
424
  async fetchOptions(query, page = 1) {
400
425
  var _a;
401
426
  if (!this.asyncUrl)
@@ -427,10 +452,15 @@ const PdsMultiselect = class {
427
452
  url.searchParams.set('search', query);
428
453
  url.searchParams.set('page', String(page));
429
454
  }
430
- const response = await fetch(url.toString(), Object.assign({ method: this.asyncMethod, signal: this.abortController.signal, headers: {
431
- 'Content-Type': 'application/json',
432
- 'Accept': 'application/json',
433
- } }, (this.asyncMethod === 'POST' && {
455
+ const csrfToken = this.getCsrfToken();
456
+ const headers = {
457
+ 'Content-Type': 'application/json',
458
+ 'Accept': 'application/json',
459
+ };
460
+ if (csrfToken) {
461
+ headers['X-CSRF-Token'] = csrfToken;
462
+ }
463
+ const response = await fetch(url.toString(), Object.assign({ method: this.asyncMethod, signal: this.abortController.signal, headers }, (this.asyncMethod === 'POST' && {
434
464
  body: JSON.stringify({ search: query, page }),
435
465
  })));
436
466
  // Clear timeout on successful response
@@ -488,30 +518,35 @@ const PdsMultiselect = class {
488
518
  this.creating = true;
489
519
  try {
490
520
  const url = new URL(this.createUrl, window.location.origin);
521
+ const csrfToken = this.getCsrfToken();
522
+ const headers = {
523
+ 'Content-Type': 'application/json',
524
+ 'Accept': 'application/json',
525
+ };
526
+ if (csrfToken) {
527
+ headers['X-CSRF-Token'] = csrfToken;
528
+ }
491
529
  const response = await fetch(url.toString(), {
492
530
  method: 'POST',
493
- headers: {
494
- 'Content-Type': 'application/json',
495
- 'Accept': 'application/json',
496
- },
531
+ headers,
497
532
  body: JSON.stringify({ text: query.trim() }),
498
533
  });
499
534
  if (!response.ok)
500
535
  throw new Error('Failed to create option');
501
536
  const data = await response.json();
502
537
  const newOption = Object.assign({ id: data.id, text: data.text }, data);
503
- // Add to internal options
538
+ // Add to internal options first
504
539
  this.internalOptions = [...this.internalOptions, newOption];
505
540
  // Select the new option
506
541
  this.value = [...this.value, String(newOption.id)];
507
- // Sync selected items
542
+ // Sync selected items to update display with new option
508
543
  this.syncSelectedItems();
509
544
  // Emit create event
510
545
  this.pdsMultiselectCreate.emit({
511
546
  query: query.trim(),
512
547
  newOption,
513
548
  });
514
- // Emit change event
549
+ // Emit change event with synced items
515
550
  this.pdsMultiselectChange.emit({
516
551
  values: this.value,
517
552
  items: this.selectedItems,
@@ -621,27 +656,22 @@ const PdsMultiselect = class {
621
656
  const isSelected = this.value.includes(String(option.id));
622
657
  if (isSelected) {
623
658
  // Remove from selection
624
- const newValue = this.value.filter(v => v !== String(option.id));
625
- this.value = newValue;
626
- const newSelectedItems = this.selectedItems.filter(item => String(item.id) !== String(option.id));
627
- this.pdsMultiselectChange.emit({
628
- values: newValue,
629
- items: newSelectedItems,
630
- });
659
+ this.value = this.value.filter(v => v !== String(option.id));
631
660
  }
632
661
  else {
633
662
  // Add to selection
634
663
  if (this.maxSelections && this.value.length >= this.maxSelections) {
635
664
  return;
636
665
  }
637
- const newValue = [...this.value, String(option.id)];
638
- this.value = newValue;
639
- const newSelectedItems = [...this.selectedItems, option];
640
- this.pdsMultiselectChange.emit({
641
- values: newValue,
642
- items: newSelectedItems,
643
- });
666
+ this.value = [...this.value, String(option.id)];
644
667
  }
668
+ // Sync selected items to ensure no duplicates and accurate state
669
+ this.syncSelectedItems();
670
+ // Emit change event with synced items
671
+ this.pdsMultiselectChange.emit({
672
+ values: this.value,
673
+ items: this.selectedItems,
674
+ });
645
675
  // Keep focus on search input, don't close dropdown
646
676
  (_a = this.searchInputEl) === null || _a === void 0 ? void 0 : _a.focus();
647
677
  }
@@ -685,19 +715,19 @@ const PdsMultiselect = class {
685
715
  }
686
716
  render() {
687
717
  const hasSelections = this.selectedItems.length > 0;
688
- return (index.h(index.Host, { key: 'b03d0709427e89ae3971d2f1fdc42a6e6616e428', "aria-disabled": this.disabled ? 'true' : null }, index.h("div", { key: 'd71fc5ec468c6c54bafe93307a6b3e65c0fe5b81', class: "pds-multiselect" }, this.label && (index.h("label", { key: 'c15deeec84eac043bb7c8813327d0f942b892734', htmlFor: this.componentId, class: {
718
+ return (index.h(index.Host, { key: '5eabf872bf4e4f109106c0dd7f9fc8ea48e8c0c0', "aria-disabled": this.disabled ? 'true' : null }, index.h("div", { key: '2623280ddbb4e116da4dbf0fe9123b5f06f0da0c', class: "pds-multiselect" }, this.label && (index.h("label", { key: 'ec644a7af54ca4dcdece849c6df692fae268b445', htmlFor: this.componentId, class: {
689
719
  'pds-multiselect__label': true,
690
720
  'visually-hidden': this.hideLabel,
691
- } }, this.label)), index.h("div", { key: 'f256795c69fd40f9c717d8c884d897032d3c4f49', class: "pds-multiselect__wrapper", ref: el => (this.containerEl = el), onFocusout: this.handleContainerFocusOut, style: { width: this.triggerWidth } }, index.h("button", { key: '131f3141229ee14418737010615e9e1f2f430c4f', ref: el => (this.triggerEl = el), type: "button", class: {
721
+ } }, this.label)), index.h("div", { key: 'ae08d5be617ee801a730fd9289146e82f2df8258', class: "pds-multiselect__wrapper", ref: el => (this.containerEl = el), onFocusout: this.handleContainerFocusOut, style: { width: this.triggerWidth } }, index.h("button", { key: 'c4639d573de4bb7963f848284057afcf9cc65cb9', ref: el => (this.triggerEl = el), type: "button", class: {
692
722
  'pds-multiselect__trigger': true,
693
723
  'pds-multiselect__trigger--open': this.isOpen,
694
724
  'pds-multiselect__trigger--disabled': this.disabled,
695
725
  'pds-multiselect__trigger--invalid': this.invalid || !!this.errorMessage,
696
726
  'pds-multiselect__trigger--has-value': hasSelections,
697
- }, id: this.componentId, disabled: this.disabled, "aria-required": this.required ? 'true' : undefined, "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-describedby": form.assignDescription(this.componentId, this.invalid || !!this.errorMessage, this.errorMessage || this.helperMessage), "aria-invalid": this.invalid || !!this.errorMessage ? 'true' : undefined, onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown }, index.h("span", { key: '3e61f1728014a97a193b6fa6158f21abd0d169c3', class: {
727
+ }, id: this.componentId, disabled: this.disabled, "aria-required": this.required ? 'true' : undefined, "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-describedby": form.assignDescription(this.componentId, this.invalid || !!this.errorMessage, this.errorMessage || this.helperMessage), "aria-invalid": this.invalid || !!this.errorMessage ? 'true' : undefined, onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown }, index.h("span", { key: 'b16da29ea9a98d6672813d9c142ef63135b12dca', class: {
698
728
  'pds-multiselect__trigger-text': true,
699
729
  'pds-multiselect__trigger-text--placeholder': !hasSelections,
700
- } }, this.getTriggerText()), index.h("pds-icon", { key: '13bc74c492bf7ead5a77e42e92002b45389f1906', class: "pds-multiselect__icon", icon: index$1.enlarge })), this.renderDropdown()), this.helperMessage && !(this.errorMessage && this.errorMessage.length > 0) && (index.h("p", { key: '53d6219eb3b910a277b5025be11d2d0a742c0ee1', class: "pds-multiselect__helper", id: form.messageId(this.componentId, 'helper') }, this.helperMessage)), this.errorMessage && (index.h("p", { key: '475fd9c02f8cc3cdd1f1911b3e71dce32e2f1743', class: "pds-multiselect__error", id: form.messageId(this.componentId, 'error') }, index.h("pds-icon", { key: 'ab6fdb8a743caa1712fc30532c0c2b6099703564', icon: index$1.danger, size: "small" }), this.errorMessage)), index.h("div", { key: '64d5db05c6b0e04a6cbf899ccc30ee479c23e9d6', style: { display: 'none' } }, index.h("slot", { key: '378ceb06d78d5542ca40ed4852bb582da514028c' })))));
730
+ } }, this.getTriggerText()), index.h("pds-icon", { key: '4e86739529355331c9fa6b95b63f223d5a315ad5', class: "pds-multiselect__icon", icon: index$1.enlarge })), this.renderDropdown()), this.helperMessage && !(this.errorMessage && this.errorMessage.length > 0) && (index.h("p", { key: '34cd42ddb1725546ce367699ef520e37d24cae25', class: "pds-multiselect__helper", id: form.messageId(this.componentId, 'helper') }, this.helperMessage)), this.errorMessage && (index.h("p", { key: '0eada43d1bcb44ea7b95927dd3f799aff6cc6b3a', class: "pds-multiselect__error", id: form.messageId(this.componentId, 'error') }, index.h("pds-icon", { key: '546dcc24794d274d73b3de867b79123b6f0069fc', icon: index$1.danger, size: "small" }), this.errorMessage)), index.h("div", { key: '3921e646c9e3638077c016e7cb28a19adaa302f0', style: { display: 'none' } }, index.h("slot", { key: '3923872eaae0a59da8c4a5b9801abf41ae9a3c3d' })))));
701
731
  }
702
732
  static get formAssociated() { return true; }
703
733
  get el() { return index.getElement(this); }