@six-group/ui-library 5.0.0-rc.1 → 5.0.0-rc.2

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 (122) hide show
  1. package/dist/cjs/index-C8rK7OAe.js +4 -0
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/six-range.cjs.entry.js.map +1 -1
  4. package/dist/cjs/six-range.entry.cjs.js.map +1 -1
  5. package/dist/cjs/six-rating.cjs.entry.js +126 -0
  6. package/dist/cjs/six-rating.cjs.entry.js.map +1 -0
  7. package/dist/cjs/six-rating.entry.cjs.js.map +1 -0
  8. package/dist/cjs/six-root.cjs.entry.js +1 -1
  9. package/dist/cjs/six-sidebar-item.cjs.entry.js +2 -2
  10. package/dist/cjs/six-sidebar.cjs.entry.js +2 -2
  11. package/dist/cjs/six-switch.cjs.entry.js +2 -2
  12. package/dist/cjs/six-switch.cjs.entry.js.map +1 -1
  13. package/dist/cjs/six-switch.entry.cjs.js.map +1 -1
  14. package/dist/cjs/six-tab-panel.cjs.entry.js +1 -1
  15. package/dist/cjs/six-tab.cjs.entry.js +2 -2
  16. package/dist/cjs/six-tag.cjs.entry.js +2 -2
  17. package/dist/cjs/six-textarea.cjs.entry.js +2 -2
  18. package/dist/cjs/six-tile.cjs.entry.js +5 -5
  19. package/dist/cjs/six-timepicker.cjs.entry.js +17 -9
  20. package/dist/cjs/six-timepicker.cjs.entry.js.map +1 -1
  21. package/dist/cjs/six-timepicker.entry.cjs.js.map +1 -1
  22. package/dist/cjs/six-tooltip.cjs.entry.js +2 -2
  23. package/dist/cjs/ui-library.cjs.js +1 -1
  24. package/dist/collection/collection-manifest.json +1 -0
  25. package/dist/collection/components/six-rating/six-rating.css +125 -0
  26. package/dist/collection/components/six-rating/six-rating.js +432 -0
  27. package/dist/collection/components/six-rating/six-rating.js.map +1 -0
  28. package/dist/collection/components/six-root/six-root.js +1 -1
  29. package/dist/collection/components/six-sidebar/six-sidebar.js +2 -2
  30. package/dist/collection/components/six-sidebar-item/six-sidebar-item.js +2 -2
  31. package/dist/collection/components/six-switch/six-switch.js +2 -2
  32. package/dist/collection/components/six-tab/six-tab.js +2 -2
  33. package/dist/collection/components/six-tab-panel/six-tab-panel.js +1 -1
  34. package/dist/collection/components/six-tag/six-tag.js +2 -2
  35. package/dist/collection/components/six-textarea/six-textarea.js +2 -2
  36. package/dist/collection/components/six-tile/six-tile.js +5 -5
  37. package/dist/collection/components/six-timepicker/six-timepicker.js +17 -9
  38. package/dist/collection/components/six-timepicker/six-timepicker.js.map +1 -1
  39. package/dist/collection/components/six-tooltip/six-tooltip.js +2 -2
  40. package/dist/components/index.js +2 -0
  41. package/dist/components/index.js.map +1 -1
  42. package/dist/components/{p-DnLdSdN5.js → p-CAJFkiLw.js} +19 -11
  43. package/dist/components/p-CAJFkiLw.js.map +1 -0
  44. package/dist/components/{p-Cs6mMfx-.js → p-ClylOmYH.js} +4 -4
  45. package/dist/components/{p-Cs6mMfx-.js.map → p-ClylOmYH.js.map} +1 -1
  46. package/dist/components/six-datepicker.js +1 -1
  47. package/dist/components/six-range.js.map +1 -1
  48. package/dist/components/six-rating.d.ts +11 -0
  49. package/dist/components/six-rating.js +173 -0
  50. package/dist/components/six-rating.js.map +1 -0
  51. package/dist/components/six-root.js +1 -1
  52. package/dist/components/six-sidebar-item.js +2 -2
  53. package/dist/components/six-sidebar.js +2 -2
  54. package/dist/components/six-switch.js +2 -2
  55. package/dist/components/six-switch.js.map +1 -1
  56. package/dist/components/six-tab-panel.js +1 -1
  57. package/dist/components/six-tab.js +2 -2
  58. package/dist/components/six-tag.js +3 -3
  59. package/dist/components/six-textarea.js +2 -2
  60. package/dist/components/six-tile.js +6 -6
  61. package/dist/components/six-timepicker.js +1 -1
  62. package/dist/components/six-tooltip.js +1 -1
  63. package/dist/components.json +468 -1
  64. package/dist/esm/index-JoG9I7EO.js +4 -0
  65. package/dist/esm/loader.js +1 -1
  66. package/dist/esm/six-range.entry.js.map +1 -1
  67. package/dist/esm/six-rating.entry.js +124 -0
  68. package/dist/esm/six-rating.entry.js.map +1 -0
  69. package/dist/esm/six-root.entry.js +1 -1
  70. package/dist/esm/six-sidebar-item.entry.js +2 -2
  71. package/dist/esm/six-sidebar.entry.js +2 -2
  72. package/dist/esm/six-switch.entry.js +2 -2
  73. package/dist/esm/six-switch.entry.js.map +1 -1
  74. package/dist/esm/six-tab-panel.entry.js +1 -1
  75. package/dist/esm/six-tab.entry.js +2 -2
  76. package/dist/esm/six-tag.entry.js +2 -2
  77. package/dist/esm/six-textarea.entry.js +2 -2
  78. package/dist/esm/six-tile.entry.js +5 -5
  79. package/dist/esm/six-timepicker.entry.js +17 -9
  80. package/dist/esm/six-timepicker.entry.js.map +1 -1
  81. package/dist/esm/six-tooltip.entry.js +2 -2
  82. package/dist/esm/ui-library.js +1 -1
  83. package/dist/types/components/six-rating/six-rating.d.ts +52 -0
  84. package/dist/types/components.d.ts +160 -0
  85. package/dist/ui-library/{p-01243b2e.entry.js → p-03ca4af8.entry.js} +2 -2
  86. package/dist/ui-library/p-12e7a9e1.entry.js +2 -0
  87. package/dist/ui-library/p-12e7a9e1.entry.js.map +1 -0
  88. package/dist/ui-library/{p-362ff192.entry.js → p-21cbccb1.entry.js} +2 -2
  89. package/dist/ui-library/p-39668d61.entry.js +2 -0
  90. package/dist/ui-library/p-39668d61.entry.js.map +1 -0
  91. package/dist/ui-library/{p-ea61b009.entry.js → p-6c8182fa.entry.js} +2 -2
  92. package/dist/ui-library/{p-25ff87fe.entry.js → p-83b35622.entry.js} +2 -2
  93. package/dist/ui-library/{p-f6423fca.entry.js → p-c8fbf085.entry.js} +2 -2
  94. package/dist/ui-library/p-d7c7398d.entry.js +2 -0
  95. package/dist/ui-library/{p-f4dd7b57.entry.js → p-d9e770ab.entry.js} +2 -2
  96. package/dist/ui-library/p-d9e770ab.entry.js.map +1 -0
  97. package/dist/ui-library/p-ea3bf68d.entry.js +2 -0
  98. package/dist/ui-library/p-ee980a0f.entry.js.map +1 -1
  99. package/dist/ui-library/{p-29d79fe3.entry.js → p-f54d3616.entry.js} +2 -2
  100. package/dist/ui-library/{p-285666de.entry.js → p-f6a1c20b.entry.js} +2 -2
  101. package/dist/ui-library/six-range.entry.esm.js.map +1 -1
  102. package/dist/ui-library/six-rating.entry.esm.js.map +1 -0
  103. package/dist/ui-library/six-switch.entry.esm.js.map +1 -1
  104. package/dist/ui-library/six-timepicker.entry.esm.js.map +1 -1
  105. package/dist/ui-library/ui-library.css +1 -1
  106. package/dist/ui-library/ui-library.esm.js +1 -1
  107. package/package.json +1 -1
  108. package/dist/components/p-DnLdSdN5.js.map +0 -1
  109. package/dist/ui-library/p-494546c8.entry.js +0 -2
  110. package/dist/ui-library/p-4f52c56f.entry.js +0 -2
  111. package/dist/ui-library/p-4f52c56f.entry.js.map +0 -1
  112. package/dist/ui-library/p-d36ec323.entry.js +0 -2
  113. package/dist/ui-library/p-f4dd7b57.entry.js.map +0 -1
  114. /package/dist/ui-library/{p-01243b2e.entry.js.map → p-03ca4af8.entry.js.map} +0 -0
  115. /package/dist/ui-library/{p-362ff192.entry.js.map → p-21cbccb1.entry.js.map} +0 -0
  116. /package/dist/ui-library/{p-ea61b009.entry.js.map → p-6c8182fa.entry.js.map} +0 -0
  117. /package/dist/ui-library/{p-25ff87fe.entry.js.map → p-83b35622.entry.js.map} +0 -0
  118. /package/dist/ui-library/{p-f6423fca.entry.js.map → p-c8fbf085.entry.js.map} +0 -0
  119. /package/dist/ui-library/{p-d36ec323.entry.js.map → p-d7c7398d.entry.js.map} +0 -0
  120. /package/dist/ui-library/{p-494546c8.entry.js.map → p-ea3bf68d.entry.js.map} +0 -0
  121. /package/dist/ui-library/{p-29d79fe3.entry.js.map → p-f54d3616.entry.js.map} +0 -0
  122. /package/dist/ui-library/{p-285666de.entry.js.map → p-f6a1c20b.entry.js.map} +0 -0
@@ -5,7 +5,7 @@ import { g as globalScripts } from './app-globals-DQuL1Twl.js';
5
5
  const defineCustomElements = async (win, options) => {
6
6
  if (typeof window === 'undefined') return undefined;
7
7
  await globalScripts();
8
- return bootstrapLazy(JSON.parse("[[\"six-select\",[[1,\"six-select\",{\"multiple\":[4],\"selectAllButton\":[4,\"select-all-button\"],\"selectAllText\":[1,\"select-all-text\"],\"disabled\":[4],\"name\":[1],\"placeholder\":[1],\"filterPlaceholder\":[1,\"filter-placeholder\"],\"filterDebounce\":[2,\"filter-debounce\"],\"size\":[1],\"hoist\":[4],\"value\":[1025],\"pill\":[4],\"helpText\":[1,\"help-text\"],\"required\":[4],\"clearable\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"line\":[4],\"filter\":[4],\"asyncFilter\":[4,\"async-filter\"],\"autocomplete\":[4],\"inputDebounce\":[2,\"input-debounce\"],\"options\":[16],\"virtualScroll\":[4,\"virtual-scroll\"],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32],\"hasErrorTextSlot\":[32],\"isOpen\":[32],\"displayedValues\":[32],\"selectionContainerItems\":[32],\"setFocus\":[64]},null,{\"disabled\":[\"handleDisabledChange\"],\"helpText\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"],\"multiple\":[\"handleMultipleChange\"],\"value\":[\"handleValueChange\"]}]]],[\"six-header-dropdown-item\",[[1,\"six-header-dropdown-item\",{\"filter\":[4],\"filterPlaceholder\":[1,\"filter-placeholder\"],\"active\":[32]}]]],[\"six-datepicker\",[[1,\"six-datepicker\",{\"type\":[1],\"locale\":[1],\"open\":[1540],\"inline\":[516],\"readonly\":[4],\"disabled\":[4],\"allowedDates\":[16,\"allowed-dates\"],\"min\":[16],\"max\":[16],\"closeOnSelect\":[4,\"close-on-select\"],\"placement\":[1],\"size\":[1],\"required\":[4],\"defaultDate\":[1,\"default-date\"],\"placeholder\":[1],\"value\":[1040],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"containingElement\":[16,\"containing-element\"],\"dateFormat\":[1,\"date-format\"],\"debounce\":[2],\"name\":[513],\"clearable\":[4],\"iconPosition\":[1,\"icon-position\"],\"hoist\":[4],\"pointerDate\":[32],\"selectionMode\":[32],\"isDropDownContentUp\":[32],\"setFocus\":[64],\"select\":[64]},[[9,\"resize\",\"resizeHandler\"],[9,\"scroll\",\"scrollHandler\"]],{\"debounce\":[\"debounceChanged\"],\"value\":[\"valueChanged\"]}]]],[\"six-date\",[[1,\"six-date\",{\"language\":[1],\"readonly\":[4],\"disabled\":[4],\"allowedDates\":[16,\"allowed-dates\"],\"min\":[1],\"max\":[1],\"size\":[1],\"required\":[4],\"placeholder\":[1],\"value\":[1025],\"dateFormat\":[1,\"date-format\"],\"label\":[1],\"helpText\":[1,\"help-text\"],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"name\":[513],\"clearable\":[4],\"pointerDate\":[32],\"selectionMode\":[32],\"setFocus\":[64]},null,{\"value\":[\"valueChanged\"]}]]],[\"six-file-upload\",[[6,\"six-file-upload\",{\"compact\":[4],\"label\":[1],\"disabled\":[4],\"accept\":[1],\"multiple\":[4],\"maxFileSize\":[2,\"max-file-size\"],\"uploading\":[516],\"errorText\":[1,\"error-text\"],\"invalid\":[516],\"isOver\":[32],\"hasError\":[32]},[[1,\"dragenter\",\"dragenterHandler\"],[1,\"dragover\",\"dragoverHandler\"],[1,\"dragleave\",\"dragleaveHandler\"],[1,\"drop\",\"dropHandler\"]]]]],[\"six-search-field\",[[1,\"six-search-field\",{\"placeholder\":[1],\"debounce\":[514],\"disabled\":[516],\"value\":[513],\"clearable\":[4]},null,{\"value\":[\"handleValueChange\"]}]]],[\"six-tag\",[[1,\"six-tag\",{\"type\":[513],\"size\":[513],\"pill\":[516],\"clearable\":[516]}]]],[\"six-tile\",[[1,\"six-tile\",{\"label\":[1],\"iconName\":[1,\"icon-name\"],\"closeable\":[4],\"elevated\":[4],\"disableTooltip\":[4,\"disable-tooltip\"],\"disabled\":[516],\"size\":[513],\"visible\":[32],\"hasIconSlot\":[32],\"hasLabelSlot\":[32],\"hide\":[64],\"show\":[64]}]]],[\"six-alert\",[[1,\"six-alert\",{\"open\":[1540],\"closable\":[516],\"type\":[513],\"duration\":[2],\"isVisible\":[32],\"show\":[64],\"hide\":[64],\"toast\":[64]},null,{\"open\":[\"handleOpenChange\"],\"duration\":[\"handleDurationChange\"]}]]],[\"six-dialog\",[[1,\"six-dialog\",{\"open\":[1540],\"label\":[1],\"noHeader\":[4,\"no-header\"],\"hasFooter\":[32],\"isVisible\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-drawer\",[[1,\"six-drawer\",{\"open\":[1540],\"label\":[1],\"placement\":[1],\"contained\":[4],\"noHeader\":[4,\"no-header\"],\"hasFooter\":[32],\"isVisible\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-header-menu-button\",[[1,\"six-header-menu-button\",{\"caret\":[4],\"disabled\":[516],\"loading\":[516],\"submit\":[516],\"reset\":[516]}]]],[\"six-root\",[[1,\"six-root\",{\"padded\":[4],\"stage\":[1],\"version\":[1]}]]],[\"six-sidebar-item-group\",[[1,\"six-sidebar-item-group\",{\"name\":[1],\"icon\":[1],\"value\":[513],\"open\":[1540],\"summaryIcon\":[1,\"summary-icon\"],\"href\":[513],\"hasItems\":[32],\"summaryIconHasContent\":[32]}]]],[\"six-tab\",[[1,\"six-tab\",{\"panel\":[513],\"active\":[516],\"closable\":[4],\"disabled\":[516],\"setFocus\":[64],\"removeFocus\":[64]}]]],[\"six-tab-group\",[[1,\"six-tab-group\",{\"placement\":[1],\"noScrollControls\":[4,\"no-scroll-controls\"],\"hasLeftControl\":[32],\"hasRightControl\":[32],\"show\":[64]},null,{\"noScrollControls\":[\"handleNoScrollControlsChange\"]}]]],[\"six-avatar\",[[1,\"six-avatar\",{\"image\":[1],\"alt\":[1],\"initials\":[1],\"shape\":[1],\"hasError\":[32]}]]],[\"six-error-page\",[[1,\"six-error-page\",{\"errorCode\":[2,\"error-code\"],\"language\":[1],\"customTitle\":[1,\"custom-title\"],\"customDescription\":[16,\"custom-description\"],\"customIcon\":[1,\"custom-icon\"]}]]],[\"six-file-list-item\",[[1,\"six-file-list-item\",{\"identifier\":[513],\"name\":[513],\"date\":[513],\"size\":[514],\"nodownload\":[516],\"nodelete\":[516]}]]],[\"six-group-label\",[[1,\"six-group-label\",{\"size\":[513],\"label\":[1],\"helpText\":[1,\"help-text\"],\"disabled\":[516],\"required\":[4],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32]},null,{\"helpText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"]}]]],[\"six-range\",[[1,\"six-range\",{\"name\":[1],\"value\":[1026],\"required\":[4],\"helpText\":[1,\"help-text\"],\"disabled\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"min\":[2],\"max\":[2],\"step\":[2],\"tooltip\":[1],\"tooltipFormatter\":[16,\"tooltip-formatter\"],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasErrorTextSlot\":[32],\"hasLabelSlot\":[32],\"hasTooltip\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"label\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"helpText\":[\"handleLabelChange\"],\"value\":[\"handleValueChange\"],\"min\":[\"handleValueChange\"],\"max\":[\"handleValueChange\"]}]]],[\"six-sidebar-item\",[[1,\"six-sidebar-item\",{\"value\":[513],\"selected\":[516],\"disabled\":[516],\"icon\":[1],\"href\":[513]}]]],[\"six-switch\",[[1,\"six-switch\",{\"name\":[1],\"value\":[1],\"disabled\":[4],\"required\":[4],\"checked\":[1540],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"hasFocus\":[32],\"hasErrorTextSlot\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"checked\":[\"handleCheckedChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"]}]]],[\"six-textarea\",[[1,\"six-textarea\",{\"size\":[513],\"name\":[513],\"value\":[1537],\"helpText\":[1,\"help-text\"],\"placeholder\":[1],\"rows\":[2],\"resize\":[1],\"disabled\":[516],\"readonly\":[516],\"minlength\":[514],\"maxlength\":[514],\"required\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"autocapitalize\":[1],\"autocorrect\":[1],\"autocomplete\":[1],\"autofocus\":[4],\"spellcheck\":[4],\"inputmode\":[1],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32],\"hasErrorTextSlot\":[32],\"setFocus\":[64],\"removeFocus\":[64],\"select\":[64],\"setSelectionRange\":[64],\"setRangeText\":[64]},null,{\"helpText\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"],\"rows\":[\"handleRowsChange\"],\"value\":[\"handleValueChange\"]}]]],[\"six-badge\",[[1,\"six-badge\",{\"type\":[1],\"pill\":[4],\"pulse\":[4]}]]],[\"six-card\",[[1,\"six-card\"]]],[\"six-file-list\",[[1,\"six-file-list\"]]],[\"six-footer\",[[1,\"six-footer\"]]],[\"six-header\",[[1,\"six-header\",{\"shiftContent\":[4,\"shift-content\"],\"openSearch\":[4,\"open-search\"]},null,{\"openSearch\":[\"handleOpenSearchChange\"]}]]],[\"six-header-item\",[[1,\"six-header-item\",{\"active\":[516]}]]],[\"six-language-switcher\",[[1,\"six-language-switcher\",{\"selected\":[1537],\"languages\":[16]},null,{\"languages\":[\"handleChangesLanguages\"]}]]],[\"six-layout-grid\",[[1,\"six-layout-grid\",{\"columns\":[1026]},null,{\"columns\":[\"handleColumnsChange\"]}]]],[\"six-logo\",[[1,\"six-logo\",{\"brand\":[513]}]]],[\"six-main-container\",[[1,\"six-main-container\",{\"padded\":[4]}]]],[\"six-menu-divider\",[[1,\"six-menu-divider\"]]],[\"six-menu-label\",[[1,\"six-menu-label\"]]],[\"six-progress-bar\",[[1,\"six-progress-bar\",{\"percentage\":[2],\"indeterminate\":[4]}]]],[\"six-progress-ring\",[[1,\"six-progress-ring\",{\"size\":[2],\"strokeWidth\":[2,\"stroke-width\"],\"percentage\":[2]},null,{\"percentage\":[\"handlePercentageChange\"]}]]],[\"six-radio\",[[1,\"six-radio\",{\"name\":[1],\"value\":[513],\"disabled\":[4],\"checked\":[1540],\"invalid\":[516],\"hasFocus\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"checked\":[\"handleCheckedChange\"],\"name\":[\"handleNameChange\"]}]]],[\"six-sidebar\",[[1,\"six-sidebar\",{\"position\":[1],\"open\":[1540],\"width\":[1],\"toggled\":[4],\"isVisible\":[32],\"toggle\":[64],\"show\":[64],\"hide\":[64],\"selectItemByIndex\":[64],\"selectItemByName\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-tab-panel\",[[1,\"six-tab-panel\",{\"name\":[1],\"active\":[516]}]]],[\"six-icon\",[[1,\"six-icon\",{\"size\":[513],\"filled\":[4]}]]],[\"six-item-picker\",[[1,\"six-item-picker\",{\"value\":[1544],\"type\":[1],\"min\":[1544],\"max\":[1544],\"roundtrip\":[516],\"step\":[514],\"items\":[16],\"padded\":[4],\"paddingLength\":[2,\"padding-length\"],\"paddingChar\":[1,\"padding-char\"],\"paddingDirection\":[1,\"padding-direction\"],\"timeout\":[2],\"interval\":[2],\"debounce\":[2],\"_items\":[32],\"_itemIndexes\":[32]},null,{\"value\":[\"handleValueChange\"],\"debounce\":[\"debounceChanged\"],\"items\":[\"handleSetChange\"]}]]],[\"six-timepicker\",[[1,\"six-timepicker\",{\"format\":[1],\"separator\":[1],\"value\":[1025],\"open\":[1540],\"inline\":[516],\"readonly\":[4],\"disabled\":[4],\"placement\":[1],\"size\":[1],\"required\":[4],\"placeholder\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"label\":[1],\"invalid\":[516],\"name\":[513],\"clearable\":[4],\"iconPosition\":[1,\"icon-position\"],\"hoist\":[4],\"timeout\":[2],\"interval\":[2],\"defaultTime\":[1,\"default-time\"],\"debounce\":[2],\"isPopupContentUp\":[32],\"isDropDownContentUp\":[32],\"popupValue\":[32],\"setFocus\":[64]},[[9,\"resize\",\"resizeHandler\"],[9,\"scroll\",\"scrollHandler\"]],{\"value\":[\"valueChanged\"]}]]],[\"six-details\",[[1,\"six-details\",{\"open\":[1540],\"summary\":[1],\"summaryIcon\":[1,\"summary-icon\"],\"summaryIconSize\":[513,\"summary-icon-size\"],\"disabled\":[4],\"inline\":[4],\"selectableEmpty\":[4,\"selectable-empty\"],\"hasContent\":[4,\"has-content\"],\"animateSummaryIcon\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-stage-indicator\",[[1,\"six-stage-indicator\",{\"stage\":[1]}]]],[\"six-picto\",[[1,\"six-picto\",{\"size\":[1]}]]],[\"six-button\",[[1,\"six-button\",{\"type\":[513],\"size\":[513],\"caret\":[4],\"disabled\":[516],\"loading\":[516],\"pill\":[516],\"circle\":[516],\"submit\":[516],\"reset\":[516],\"name\":[1],\"value\":[1],\"href\":[1],\"target\":[1],\"download\":[1],\"hasFocus\":[32],\"hasLabel\":[32],\"hasPrefix\":[32],\"hasSuffix\":[32],\"setFocus\":[64],\"removeFocus\":[64]}]]],[\"six-tooltip\",[[1,\"six-tooltip\",{\"content\":[1],\"placement\":[1],\"disabled\":[4],\"distance\":[2],\"open\":[1540],\"skidding\":[2],\"trigger\":[1],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-spinner\",[[1,\"six-spinner\",{\"logo\":[1],\"six\":[4]}]]],[\"six-error\",[[1,\"six-error\"]]],[\"six-input\",[[1,\"six-input\",{\"type\":[513],\"size\":[513],\"name\":[513],\"value\":[1537],\"pill\":[516],\"helpText\":[1,\"help-text\"],\"placeholder\":[1],\"disabled\":[516],\"readonly\":[516],\"minlength\":[514],\"maxlength\":[514],\"min\":[514],\"max\":[514],\"step\":[514],\"pattern\":[513],\"dropdownSearch\":[4,\"dropdown-search\"],\"required\":[4],\"autocapitalize\":[1],\"autocorrect\":[1],\"autocomplete\":[1],\"autofocus\":[4],\"spellcheck\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"clearable\":[4],\"togglePassword\":[4,\"toggle-password\"],\"inputmode\":[1],\"line\":[4],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32],\"hasErrorSlot\":[32],\"isPasswordVisible\":[32],\"setFocus\":[64],\"removeFocus\":[64],\"select\":[64],\"setSelectionRange\":[64],\"getSelectionRange\":[64],\"setRangeText\":[64]},null,{\"helpText\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"],\"value\":[\"handleValueChange\"]}]]],[\"six-checkbox_2\",[[1,\"six-menu-item\",{\"checkType\":[1,\"check-type\"],\"checked\":[516],\"value\":[513],\"disabled\":[516],\"hasFocus\":[32],\"active\":[32],\"setFocus\":[64],\"removeFocus\":[64],\"getTextLabel\":[64]}],[1,\"six-checkbox\",{\"name\":[1],\"value\":[1],\"disabled\":[4],\"required\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"checked\":[1540],\"indeterminate\":[1540],\"hasFocus\":[32],\"hasLabelSlot\":[32],\"hasErrorSlot\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"checked\":[\"handleCheckedChange\"],\"indeterminate\":[\"handleCheckedChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"]}]]],[\"six-dropdown_2\",[[1,\"six-dropdown\",{\"open\":[1540],\"placement\":[1],\"closeOnSelect\":[4,\"close-on-select\"],\"distance\":[2],\"skidding\":[2],\"hoist\":[4],\"containingElement\":[16,\"containing-element\"],\"filter\":[4],\"asyncFilter\":[4,\"async-filter\"],\"filterPlaceholder\":[1,\"filter-placeholder\"],\"autofocusFilter\":[4,\"autofocus-filter\"],\"filterDebounce\":[1026,\"filter-debounce\"],\"disableHideOnEnterAndSpace\":[4,\"disable-hide-on-enter-and-space\"],\"options\":[1040],\"virtualScroll\":[4,\"virtual-scroll\"],\"matchTriggerWidth\":[4,\"match-trigger-width\"],\"renderedOptions\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"],\"distance\":[\"handlePopoverOptionsChange\"],\"hoist\":[\"handlePopoverOptionsChange\"],\"placement\":[\"handlePopoverOptionsChange\"],\"skidding\":[\"handlePopoverOptionsChange\"],\"options\":[\"handleOptionsChange\"],\"virtualScroll\":[\"handleOptionsChange\"]}],[1,\"six-menu\",{\"removeBoxShadow\":[4,\"remove-box-shadow\"],\"items\":[16],\"itemsShown\":[2,\"items-shown\"],\"virtualScroll\":[4,\"virtual-scroll\"],\"itemSize\":[2,\"item-size\"],\"scrollingDebounce\":[2,\"scrolling-debounce\"],\"disableKeyboardHandling\":[4,\"disable-keyboard-handling\"],\"scrollingIndex\":[32],\"sixMenuItemHeight\":[32],\"typeToSelect\":[64]}]]],[\"six-icon-button\",[[1,\"six-icon-button\",{\"name\":[513],\"size\":[513],\"label\":[513],\"disabled\":[516],\"html\":[513],\"href\":[1],\"target\":[1],\"download\":[1]}]]]]"), options);
8
+ return bootstrapLazy(JSON.parse("[[\"six-select\",[[1,\"six-select\",{\"multiple\":[4],\"selectAllButton\":[4,\"select-all-button\"],\"selectAllText\":[1,\"select-all-text\"],\"disabled\":[4],\"name\":[1],\"placeholder\":[1],\"filterPlaceholder\":[1,\"filter-placeholder\"],\"filterDebounce\":[2,\"filter-debounce\"],\"size\":[1],\"hoist\":[4],\"value\":[1025],\"pill\":[4],\"helpText\":[1,\"help-text\"],\"required\":[4],\"clearable\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"line\":[4],\"filter\":[4],\"asyncFilter\":[4,\"async-filter\"],\"autocomplete\":[4],\"inputDebounce\":[2,\"input-debounce\"],\"options\":[16],\"virtualScroll\":[4,\"virtual-scroll\"],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32],\"hasErrorTextSlot\":[32],\"isOpen\":[32],\"displayedValues\":[32],\"selectionContainerItems\":[32],\"setFocus\":[64]},null,{\"disabled\":[\"handleDisabledChange\"],\"helpText\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"],\"multiple\":[\"handleMultipleChange\"],\"value\":[\"handleValueChange\"]}]]],[\"six-header-dropdown-item\",[[1,\"six-header-dropdown-item\",{\"filter\":[4],\"filterPlaceholder\":[1,\"filter-placeholder\"],\"active\":[32]}]]],[\"six-datepicker\",[[1,\"six-datepicker\",{\"type\":[1],\"locale\":[1],\"open\":[1540],\"inline\":[516],\"readonly\":[4],\"disabled\":[4],\"allowedDates\":[16,\"allowed-dates\"],\"min\":[16],\"max\":[16],\"closeOnSelect\":[4,\"close-on-select\"],\"placement\":[1],\"size\":[1],\"required\":[4],\"defaultDate\":[1,\"default-date\"],\"placeholder\":[1],\"value\":[1040],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"containingElement\":[16,\"containing-element\"],\"dateFormat\":[1,\"date-format\"],\"debounce\":[2],\"name\":[513],\"clearable\":[4],\"iconPosition\":[1,\"icon-position\"],\"hoist\":[4],\"pointerDate\":[32],\"selectionMode\":[32],\"isDropDownContentUp\":[32],\"setFocus\":[64],\"select\":[64]},[[9,\"resize\",\"resizeHandler\"],[9,\"scroll\",\"scrollHandler\"]],{\"debounce\":[\"debounceChanged\"],\"value\":[\"valueChanged\"]}]]],[\"six-date\",[[1,\"six-date\",{\"language\":[1],\"readonly\":[4],\"disabled\":[4],\"allowedDates\":[16,\"allowed-dates\"],\"min\":[1],\"max\":[1],\"size\":[1],\"required\":[4],\"placeholder\":[1],\"value\":[1025],\"dateFormat\":[1,\"date-format\"],\"label\":[1],\"helpText\":[1,\"help-text\"],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"name\":[513],\"clearable\":[4],\"pointerDate\":[32],\"selectionMode\":[32],\"setFocus\":[64]},null,{\"value\":[\"valueChanged\"]}]]],[\"six-file-upload\",[[6,\"six-file-upload\",{\"compact\":[4],\"label\":[1],\"disabled\":[4],\"accept\":[1],\"multiple\":[4],\"maxFileSize\":[2,\"max-file-size\"],\"uploading\":[516],\"errorText\":[1,\"error-text\"],\"invalid\":[516],\"isOver\":[32],\"hasError\":[32]},[[1,\"dragenter\",\"dragenterHandler\"],[1,\"dragover\",\"dragoverHandler\"],[1,\"dragleave\",\"dragleaveHandler\"],[1,\"drop\",\"dropHandler\"]]]]],[\"six-search-field\",[[1,\"six-search-field\",{\"placeholder\":[1],\"debounce\":[514],\"disabled\":[516],\"value\":[513],\"clearable\":[4]},null,{\"value\":[\"handleValueChange\"]}]]],[\"six-tag\",[[1,\"six-tag\",{\"type\":[513],\"size\":[513],\"pill\":[516],\"clearable\":[516]}]]],[\"six-tile\",[[1,\"six-tile\",{\"label\":[1],\"iconName\":[1,\"icon-name\"],\"closeable\":[4],\"elevated\":[4],\"disableTooltip\":[4,\"disable-tooltip\"],\"disabled\":[516],\"size\":[513],\"visible\":[32],\"hasIconSlot\":[32],\"hasLabelSlot\":[32],\"hide\":[64],\"show\":[64]}]]],[\"six-alert\",[[1,\"six-alert\",{\"open\":[1540],\"closable\":[516],\"type\":[513],\"duration\":[2],\"isVisible\":[32],\"show\":[64],\"hide\":[64],\"toast\":[64]},null,{\"open\":[\"handleOpenChange\"],\"duration\":[\"handleDurationChange\"]}]]],[\"six-dialog\",[[1,\"six-dialog\",{\"open\":[1540],\"label\":[1],\"noHeader\":[4,\"no-header\"],\"hasFooter\":[32],\"isVisible\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-drawer\",[[1,\"six-drawer\",{\"open\":[1540],\"label\":[1],\"placement\":[1],\"contained\":[4],\"noHeader\":[4,\"no-header\"],\"hasFooter\":[32],\"isVisible\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-header-menu-button\",[[1,\"six-header-menu-button\",{\"caret\":[4],\"disabled\":[516],\"loading\":[516],\"submit\":[516],\"reset\":[516]}]]],[\"six-rating\",[[1,\"six-rating\",{\"name\":[1],\"value\":[1026],\"disabled\":[4],\"required\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"max\":[2],\"size\":[513],\"readonly\":[4],\"helpText\":[1,\"help-text\"],\"hasFocus\":[32],\"hasLabelSlot\":[32],\"hasErrorSlot\":[32],\"hoveredValue\":[32]},null,{\"value\":[\"handleValueChange\"]}]]],[\"six-root\",[[1,\"six-root\",{\"padded\":[4],\"stage\":[1],\"version\":[1]}]]],[\"six-sidebar-item-group\",[[1,\"six-sidebar-item-group\",{\"name\":[1],\"icon\":[1],\"value\":[513],\"open\":[1540],\"summaryIcon\":[1,\"summary-icon\"],\"href\":[513],\"hasItems\":[32],\"summaryIconHasContent\":[32]}]]],[\"six-tab\",[[1,\"six-tab\",{\"panel\":[513],\"active\":[516],\"closable\":[4],\"disabled\":[516],\"setFocus\":[64],\"removeFocus\":[64]}]]],[\"six-tab-group\",[[1,\"six-tab-group\",{\"placement\":[1],\"noScrollControls\":[4,\"no-scroll-controls\"],\"hasLeftControl\":[32],\"hasRightControl\":[32],\"show\":[64]},null,{\"noScrollControls\":[\"handleNoScrollControlsChange\"]}]]],[\"six-avatar\",[[1,\"six-avatar\",{\"image\":[1],\"alt\":[1],\"initials\":[1],\"shape\":[1],\"hasError\":[32]}]]],[\"six-error-page\",[[1,\"six-error-page\",{\"errorCode\":[2,\"error-code\"],\"language\":[1],\"customTitle\":[1,\"custom-title\"],\"customDescription\":[16,\"custom-description\"],\"customIcon\":[1,\"custom-icon\"]}]]],[\"six-file-list-item\",[[1,\"six-file-list-item\",{\"identifier\":[513],\"name\":[513],\"date\":[513],\"size\":[514],\"nodownload\":[516],\"nodelete\":[516]}]]],[\"six-group-label\",[[1,\"six-group-label\",{\"size\":[513],\"label\":[1],\"helpText\":[1,\"help-text\"],\"disabled\":[516],\"required\":[4],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32]},null,{\"helpText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"]}]]],[\"six-range\",[[1,\"six-range\",{\"name\":[1],\"value\":[1026],\"required\":[4],\"helpText\":[1,\"help-text\"],\"disabled\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"min\":[2],\"max\":[2],\"step\":[2],\"tooltip\":[1],\"tooltipFormatter\":[16,\"tooltip-formatter\"],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasErrorTextSlot\":[32],\"hasLabelSlot\":[32],\"hasTooltip\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"label\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"helpText\":[\"handleLabelChange\"],\"value\":[\"handleValueChange\"],\"min\":[\"handleValueChange\"],\"max\":[\"handleValueChange\"]}]]],[\"six-sidebar-item\",[[1,\"six-sidebar-item\",{\"value\":[513],\"selected\":[516],\"disabled\":[516],\"icon\":[1],\"href\":[513]}]]],[\"six-switch\",[[1,\"six-switch\",{\"name\":[1],\"value\":[1],\"disabled\":[4],\"required\":[4],\"checked\":[1540],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"hasFocus\":[32],\"hasErrorTextSlot\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"checked\":[\"handleCheckedChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"]}]]],[\"six-textarea\",[[1,\"six-textarea\",{\"size\":[513],\"name\":[513],\"value\":[1537],\"helpText\":[1,\"help-text\"],\"placeholder\":[1],\"rows\":[2],\"resize\":[1],\"disabled\":[516],\"readonly\":[516],\"minlength\":[514],\"maxlength\":[514],\"required\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"autocapitalize\":[1],\"autocorrect\":[1],\"autocomplete\":[1],\"autofocus\":[4],\"spellcheck\":[4],\"inputmode\":[1],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32],\"hasErrorTextSlot\":[32],\"setFocus\":[64],\"removeFocus\":[64],\"select\":[64],\"setSelectionRange\":[64],\"setRangeText\":[64]},null,{\"helpText\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"],\"rows\":[\"handleRowsChange\"],\"value\":[\"handleValueChange\"]}]]],[\"six-badge\",[[1,\"six-badge\",{\"type\":[1],\"pill\":[4],\"pulse\":[4]}]]],[\"six-card\",[[1,\"six-card\"]]],[\"six-file-list\",[[1,\"six-file-list\"]]],[\"six-footer\",[[1,\"six-footer\"]]],[\"six-header\",[[1,\"six-header\",{\"shiftContent\":[4,\"shift-content\"],\"openSearch\":[4,\"open-search\"]},null,{\"openSearch\":[\"handleOpenSearchChange\"]}]]],[\"six-header-item\",[[1,\"six-header-item\",{\"active\":[516]}]]],[\"six-language-switcher\",[[1,\"six-language-switcher\",{\"selected\":[1537],\"languages\":[16]},null,{\"languages\":[\"handleChangesLanguages\"]}]]],[\"six-layout-grid\",[[1,\"six-layout-grid\",{\"columns\":[1026]},null,{\"columns\":[\"handleColumnsChange\"]}]]],[\"six-logo\",[[1,\"six-logo\",{\"brand\":[513]}]]],[\"six-main-container\",[[1,\"six-main-container\",{\"padded\":[4]}]]],[\"six-menu-divider\",[[1,\"six-menu-divider\"]]],[\"six-menu-label\",[[1,\"six-menu-label\"]]],[\"six-progress-bar\",[[1,\"six-progress-bar\",{\"percentage\":[2],\"indeterminate\":[4]}]]],[\"six-progress-ring\",[[1,\"six-progress-ring\",{\"size\":[2],\"strokeWidth\":[2,\"stroke-width\"],\"percentage\":[2]},null,{\"percentage\":[\"handlePercentageChange\"]}]]],[\"six-radio\",[[1,\"six-radio\",{\"name\":[1],\"value\":[513],\"disabled\":[4],\"checked\":[1540],\"invalid\":[516],\"hasFocus\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"checked\":[\"handleCheckedChange\"],\"name\":[\"handleNameChange\"]}]]],[\"six-sidebar\",[[1,\"six-sidebar\",{\"position\":[1],\"open\":[1540],\"width\":[1],\"toggled\":[4],\"isVisible\":[32],\"toggle\":[64],\"show\":[64],\"hide\":[64],\"selectItemByIndex\":[64],\"selectItemByName\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-tab-panel\",[[1,\"six-tab-panel\",{\"name\":[1],\"active\":[516]}]]],[\"six-item-picker\",[[1,\"six-item-picker\",{\"value\":[1544],\"type\":[1],\"min\":[1544],\"max\":[1544],\"roundtrip\":[516],\"step\":[514],\"items\":[16],\"padded\":[4],\"paddingLength\":[2,\"padding-length\"],\"paddingChar\":[1,\"padding-char\"],\"paddingDirection\":[1,\"padding-direction\"],\"timeout\":[2],\"interval\":[2],\"debounce\":[2],\"_items\":[32],\"_itemIndexes\":[32]},null,{\"value\":[\"handleValueChange\"],\"debounce\":[\"debounceChanged\"],\"items\":[\"handleSetChange\"]}]]],[\"six-timepicker\",[[1,\"six-timepicker\",{\"format\":[1],\"separator\":[1],\"value\":[1025],\"open\":[1540],\"inline\":[516],\"readonly\":[4],\"disabled\":[4],\"placement\":[1],\"size\":[1],\"required\":[4],\"placeholder\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"label\":[1],\"invalid\":[516],\"name\":[513],\"clearable\":[4],\"iconPosition\":[1,\"icon-position\"],\"hoist\":[4],\"timeout\":[2],\"interval\":[2],\"defaultTime\":[1,\"default-time\"],\"debounce\":[2],\"isPopupContentUp\":[32],\"isDropDownContentUp\":[32],\"popupValue\":[32],\"setFocus\":[64]},[[9,\"resize\",\"resizeHandler\"],[9,\"scroll\",\"scrollHandler\"]],{\"value\":[\"valueChanged\"]}]]],[\"six-details\",[[1,\"six-details\",{\"open\":[1540],\"summary\":[1],\"summaryIcon\":[1,\"summary-icon\"],\"summaryIconSize\":[513,\"summary-icon-size\"],\"disabled\":[4],\"inline\":[4],\"selectableEmpty\":[4,\"selectable-empty\"],\"hasContent\":[4,\"has-content\"],\"animateSummaryIcon\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-stage-indicator\",[[1,\"six-stage-indicator\",{\"stage\":[1]}]]],[\"six-picto\",[[1,\"six-picto\",{\"size\":[1]}]]],[\"six-button\",[[1,\"six-button\",{\"type\":[513],\"size\":[513],\"caret\":[4],\"disabled\":[516],\"loading\":[516],\"pill\":[516],\"circle\":[516],\"submit\":[516],\"reset\":[516],\"name\":[1],\"value\":[1],\"href\":[1],\"target\":[1],\"download\":[1],\"hasFocus\":[32],\"hasLabel\":[32],\"hasPrefix\":[32],\"hasSuffix\":[32],\"setFocus\":[64],\"removeFocus\":[64]}]]],[\"six-tooltip\",[[1,\"six-tooltip\",{\"content\":[1],\"placement\":[1],\"disabled\":[4],\"distance\":[2],\"open\":[1540],\"skidding\":[2],\"trigger\":[1],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"]}]]],[\"six-spinner\",[[1,\"six-spinner\",{\"logo\":[1],\"six\":[4]}]]],[\"six-error\",[[1,\"six-error\"]]],[\"six-icon\",[[1,\"six-icon\",{\"size\":[513],\"filled\":[4]}]]],[\"six-input\",[[1,\"six-input\",{\"type\":[513],\"size\":[513],\"name\":[513],\"value\":[1537],\"pill\":[516],\"helpText\":[1,\"help-text\"],\"placeholder\":[1],\"disabled\":[516],\"readonly\":[516],\"minlength\":[514],\"maxlength\":[514],\"min\":[514],\"max\":[514],\"step\":[514],\"pattern\":[513],\"dropdownSearch\":[4,\"dropdown-search\"],\"required\":[4],\"autocapitalize\":[1],\"autocorrect\":[1],\"autocomplete\":[1],\"autofocus\":[4],\"spellcheck\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"clearable\":[4],\"togglePassword\":[4,\"toggle-password\"],\"inputmode\":[1],\"line\":[4],\"hasFocus\":[32],\"hasHelpTextSlot\":[32],\"hasLabelSlot\":[32],\"hasErrorSlot\":[32],\"isPasswordVisible\":[32],\"setFocus\":[64],\"removeFocus\":[64],\"select\":[64],\"setSelectionRange\":[64],\"getSelectionRange\":[64],\"setRangeText\":[64]},null,{\"helpText\":[\"handleLabelChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"],\"value\":[\"handleValueChange\"]}]]],[\"six-checkbox_2\",[[1,\"six-menu-item\",{\"checkType\":[1,\"check-type\"],\"checked\":[516],\"value\":[513],\"disabled\":[516],\"hasFocus\":[32],\"active\":[32],\"setFocus\":[64],\"removeFocus\":[64],\"getTextLabel\":[64]}],[1,\"six-checkbox\",{\"name\":[1],\"value\":[1],\"disabled\":[4],\"required\":[4],\"label\":[1],\"errorText\":[1,\"error-text\"],\"errorTextCount\":[2,\"error-text-count\"],\"invalid\":[516],\"checked\":[1540],\"indeterminate\":[1540],\"hasFocus\":[32],\"hasLabelSlot\":[32],\"hasErrorSlot\":[32],\"setFocus\":[64],\"removeFocus\":[64]},null,{\"checked\":[\"handleCheckedChange\"],\"indeterminate\":[\"handleCheckedChange\"],\"errorText\":[\"handleLabelChange\"],\"label\":[\"handleLabelChange\"]}]]],[\"six-dropdown_2\",[[1,\"six-dropdown\",{\"open\":[1540],\"placement\":[1],\"closeOnSelect\":[4,\"close-on-select\"],\"distance\":[2],\"skidding\":[2],\"hoist\":[4],\"containingElement\":[16,\"containing-element\"],\"filter\":[4],\"asyncFilter\":[4,\"async-filter\"],\"filterPlaceholder\":[1,\"filter-placeholder\"],\"autofocusFilter\":[4,\"autofocus-filter\"],\"filterDebounce\":[1026,\"filter-debounce\"],\"disableHideOnEnterAndSpace\":[4,\"disable-hide-on-enter-and-space\"],\"options\":[1040],\"virtualScroll\":[4,\"virtual-scroll\"],\"matchTriggerWidth\":[4,\"match-trigger-width\"],\"renderedOptions\":[32],\"show\":[64],\"hide\":[64]},null,{\"open\":[\"handleOpenChange\"],\"distance\":[\"handlePopoverOptionsChange\"],\"hoist\":[\"handlePopoverOptionsChange\"],\"placement\":[\"handlePopoverOptionsChange\"],\"skidding\":[\"handlePopoverOptionsChange\"],\"options\":[\"handleOptionsChange\"],\"virtualScroll\":[\"handleOptionsChange\"]}],[1,\"six-menu\",{\"removeBoxShadow\":[4,\"remove-box-shadow\"],\"items\":[16],\"itemsShown\":[2,\"items-shown\"],\"virtualScroll\":[4,\"virtual-scroll\"],\"itemSize\":[2,\"item-size\"],\"scrollingDebounce\":[2,\"scrolling-debounce\"],\"disableKeyboardHandling\":[4,\"disable-keyboard-handling\"],\"scrollingIndex\":[32],\"sixMenuItemHeight\":[32],\"typeToSelect\":[64]}]]],[\"six-icon-button\",[[1,\"six-icon-button\",{\"name\":[513],\"size\":[513],\"label\":[513],\"disabled\":[516],\"html\":[513],\"href\":[1],\"target\":[1],\"download\":[1]}]]]]"), options);
9
9
  };
10
10
 
11
11
  export { defineCustomElements };
@@ -1 +1 @@
1
- {"version":3,"file":"six-range.entry.js","sources":["src/components/six-range/six-range.scss?tag=six-range&encapsulation=shadow","src/components/six-range/six-range.tsx"],"sourcesContent":["@import 'src/global/component';\n@import '../../functional-components/form-control/form-control';\n\n:host {\n --thumb-size: 14px;\n --tooltip-offset-y: 10px;\n --track-color: var(--six-color-web-rock-900);\n --thumb-color: var(--six-color-web-rock-900);\n --track-height: 3px;\n\n display: block;\n}\n\n.range {\n position: relative;\n\n .range__control {\n -webkit-appearance: none;\n width: 100%;\n height: var(--six-input-height-medium);\n background: transparent;\n line-height: var(--six-input-height-medium);\n vertical-align: middle;\n\n &::-webkit-slider-runnable-track {\n width: 100%;\n height: var(--track-height);\n border-radius: 3px;\n border: none;\n }\n\n &::-webkit-slider-thumb {\n border: none;\n width: var(--thumb-size);\n height: var(--thumb-size);\n border-radius: 50%;\n background-color: var(--thumb-color);\n -webkit-appearance: none;\n margin-top: calc(var(--thumb-size) / -2 + var(--track-height) / 2);\n transition:\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) background-color,\n var(--six-transition-fast) color,\n var(--six-transition-fast) box-shadow,\n var(--six-transition-fast) transform;\n cursor: pointer;\n }\n\n &:not(:disabled)::-webkit-slider-thumb:hover {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled):focus::-webkit-slider-thumb {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled)::-webkit-slider-thumb:active {\n background-color: var(--thumb-color);\n cursor: grabbing;\n }\n\n // Firefox\n &::-moz-focus-outer {\n border: 0;\n }\n\n &::-moz-range-track {\n width: 100%;\n height: var(--track-height);\n background-color: var(--six-progress-track-color);\n border-radius: 3px;\n border: none;\n }\n\n &::-moz-range-progress {\n height: var(--track-height);\n border-radius: 3px;\n background-color: var(--track-color);\n border: none;\n }\n\n &::-moz-range-thumb {\n border: none;\n height: var(--thumb-size);\n width: var(--thumb-size);\n border-radius: 50%;\n background-color: var(--thumb-color);\n transition:\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) background-color,\n var(--six-transition-fast) color,\n var(--six-transition-fast) box-shadow,\n var(--six-transition-fast) transform;\n cursor: pointer;\n }\n\n &:not(:disabled)::-moz-range-thumb:hover {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled):focus::-moz-range-thumb {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled)::-moz-range-thumb:active {\n background-color: var(--thumb-color);\n cursor: grabbing;\n }\n\n // States\n &:focus {\n outline: none;\n }\n\n &:disabled {\n &::-webkit-slider-thumb {\n cursor: not-allowed;\n color: var(--six-color-web-rock-300);\n border-color: var(--six-color-web-rock-300);\n background-color: var(--six-color-web-rock-300);\n }\n\n &::-moz-range-thumb {\n cursor: not-allowed;\n color: var(--six-color-web-rock-300);\n border-color: var(--six-color-web-rock-300);\n background-color: var(--six-color-web-rock-300);\n }\n }\n }\n}\n\n// Tooltip\n.range__tooltip {\n position: absolute;\n z-index: var(--six-z-index-tooltip);\n left: 2px;\n border-radius: var(--six-border-radius-medium);\n background-color: var(--six-color-web-rock-900);\n font-family: var(--six-font-family);\n font-size: var(--six-tooltip-font-size);\n font-weight: var(--six-tooltip-font-weight);\n line-height: var(--six-tooltip-line-height);\n color: var(--six-color-white);\n opacity: 0;\n padding: var(--six-spacing-xxx-small) var(--six-spacing-xx-small);\n transition: var(--six-transition-fast) opacity;\n pointer-events: none;\n\n &::after {\n content: '';\n position: absolute;\n width: 0;\n height: 0;\n left: 50%;\n margin-left: calc(-1 * var(--six-tooltip-arrow-size));\n }\n}\n\n.range--tooltip-visible .range__tooltip {\n opacity: 1;\n}\n\n// Tooltip on top\n.range--tooltip-top .range__tooltip {\n top: calc(-1 * var(--thumb-size) - var(--tooltip-offset-y));\n\n &::after {\n border-top: var(--six-tooltip-arrow-size) solid var(--six-color-web-rock-900);\n border-left: var(--six-tooltip-arrow-size) solid transparent;\n border-right: var(--six-tooltip-arrow-size) solid transparent;\n top: 100%;\n }\n}\n\n// Tooltip on bottom\n.range--tooltip-bottom .range__tooltip {\n bottom: calc(-1 * var(--thumb-size) - var(--tooltip-offset-y));\n\n &::after {\n border-bottom: var(--six-tooltip-arrow-size) solid var(--six-color-web-rock-900);\n border-left: var(--six-tooltip-arrow-size) solid transparent;\n border-right: var(--six-tooltip-arrow-size) solid transparent;\n bottom: 100%;\n }\n}\n","import { Component, Element, Event, EventEmitter, h, Method, Prop, State, Watch } from '@stencil/core';\nimport FormControl from '../../functional-components/form-control/form-control';\nimport { hasSlot } from '../../utils/slot';\nimport { EmptyPayload } from '../../utils/types';\nimport { EventListeners } from '../../utils/event-listeners';\n\nlet id = 0;\n\n/**\n * @since 1.0\n * @status stable\n *\n * Forked from https://github.com/shoelace-style/shoelace version v2.0.0-beta27.\n *\n * @slot label - The input's label. Alternatively, you can use the label prop.\n * @slot help-text - Help text that describes how to use the input. Alternatively, you can use the help-text prop.\n * @slot error-text - Error text that is shown for validation errors. Alternatively, you can use the error-text prop.\n *\n * @part base - The component's base wrapper.\n * @part input - The native range input.\n * @part tooltip - The range tooltip.\n */\n@Component({\n tag: 'six-range',\n styleUrl: 'six-range.scss',\n shadow: true,\n})\nexport class SixRange {\n private inputId = `input-${++id}`;\n private labelId = `input-label-${id}`;\n private helpTextId = `input-help-text-${id}`;\n private errorTextId = `input-error-text-${id}`;\n private eventListeners = new EventListeners();\n private resizeObserver?: ResizeObserver;\n\n private output?: HTMLElement;\n private nativeInput?: HTMLInputElement;\n\n @Element() host!: HTMLSixRangeElement;\n\n @State() hasFocus = false;\n @State() hasHelpTextSlot = false;\n @State() hasErrorTextSlot = false;\n @State() hasLabelSlot = false;\n @State() hasTooltip = false;\n\n /** The input's name attribute. */\n @Prop() name = '';\n\n /** The input's value attribute. */\n @Prop({ mutable: true }) value = 0;\n\n /** Set to true to show an asterisk beneath the label. */\n @Prop() required = false;\n\n /** The range's help text. Alternatively, you can use the help-text slot. */\n @Prop() helpText = '';\n\n /** Set to true to disable the input. */\n @Prop() disabled = false;\n\n /** The label text. */\n @Prop() label = '';\n\n /** The error message shown, if `invalid` is set to true. */\n @Prop() errorText: string | string[] = '';\n\n /** The number of error texts to be shown (if the error-text slot isn't used). Defaults to 1 */\n @Prop() errorTextCount?: number;\n\n /** If this property is set to true and an error message is provided by `errorText`, the error message is displayed. */\n @Prop({ reflect: true }) invalid = false;\n\n /** The input's min attribute. */\n @Prop() min = 0;\n\n /** The input's max attribute. */\n @Prop() max = 100;\n\n /** The input's step attribute. */\n @Prop() step = 1;\n\n /** The preferred placedment of the tooltip. */\n @Prop() tooltip: 'top' | 'bottom' | 'none' = 'top';\n\n /** A function used to format the tooltip's value. */\n @Prop() tooltipFormatter = (value: number) => value.toString();\n\n /** Emitted when the control's value changes. */\n @Event({ eventName: 'six-range-change' }) sixChange!: EventEmitter<EmptyPayload>;\n\n /** Emitted when the control loses focus. */\n @Event({ eventName: 'six-range-blur' }) sixBlur!: EventEmitter<EmptyPayload>;\n\n /** Emitted when the control gains focus. */\n @Event({ eventName: 'six-range-focus' }) sixFocus!: EventEmitter<EmptyPayload>;\n\n @Watch('label')\n @Watch('errorText')\n @Watch('helpText')\n handleLabelChange() {\n this.handleSlotChange();\n }\n\n @Watch('value')\n @Watch('min')\n @Watch('max')\n handleValueChange() {\n this.update();\n }\n\n connectedCallback() {\n this.host.shadowRoot?.addEventListener('slotchange', this.handleSlotChange);\n }\n\n componentWillLoad() {\n this.update();\n this.handleSlotChange();\n }\n\n componentDidLoad() {\n const nativeInput = this.nativeInput;\n if (nativeInput == null) {\n return;\n }\n this.update();\n this.resizeObserver = new ResizeObserver(() => this.update());\n }\n\n disconnectedCallback() {\n this.host.shadowRoot?.removeEventListener('slotchange', this.handleSlotChange);\n this.eventListeners.removeAll();\n }\n\n componentDidUpdate() {\n const { min, max } = this.getMinMax();\n this.syncTooltip(min, max, this.value);\n }\n\n private getMinMax() {\n const min = Number(this.min) ?? 0;\n const max = Number(this.max) ?? 0;\n return { min, max };\n }\n\n /** Sets focus on the input. */\n @Method()\n async setFocus(options?: FocusOptions) {\n this.nativeInput?.focus(options);\n }\n\n /** Removes focus from the input. */\n @Method()\n async removeFocus() {\n this.nativeInput?.blur();\n }\n\n private handleInput = () => {\n if (this.nativeInput != null) {\n this.update(parseFloat(this.nativeInput.value));\n }\n requestAnimationFrame(() => {\n this.sixChange.emit();\n });\n };\n\n private handleBlur = () => {\n this.hasFocus = false;\n this.hasTooltip = false;\n this.sixBlur.emit();\n if (this.nativeInput != null) {\n this.resizeObserver?.unobserve(this.nativeInput);\n }\n };\n\n private handleFocus = () => {\n this.hasFocus = true;\n this.hasTooltip = true;\n this.sixFocus.emit();\n if (this.nativeInput != null) {\n this.resizeObserver?.observe(this.nativeInput);\n }\n };\n\n private handleSlotChange = () => {\n this.hasHelpTextSlot = hasSlot(this.host, 'help-text');\n this.hasLabelSlot = hasSlot(this.host, 'label');\n this.hasErrorTextSlot = hasSlot(this.host, 'error-text');\n };\n\n private handleTouchStart = () => {\n this.setFocus();\n };\n\n private syncTooltip(min: number, max: number, value: number) {\n if (this.tooltip !== 'none' && this.nativeInput != null && this.output != null) {\n const percent = Math.max(0, (value - min) / (max - min));\n const inputWidth = this.nativeInput.offsetWidth;\n const tooltipWidth = this.output.offsetWidth;\n const thumbSize = getComputedStyle(this.nativeInput).getPropertyValue('--thumb-size');\n const x = `calc(${inputWidth * percent}px - calc(calc(${percent} * ${thumbSize}) - calc(${thumbSize} / 2)))`;\n this.output.style.transform = `translateX(${x})`;\n this.output.style.marginLeft = `-${tooltipWidth / 2}px`;\n }\n }\n\n private isFirefox() {\n return navigator.userAgent.toLowerCase().indexOf('firefox') > -1;\n }\n\n private update(updateValue?: number) {\n if (updateValue != null) {\n this.value = updateValue;\n }\n\n const min = Number(this.min) ?? 0;\n const max = Number(this.max) ?? 0;\n let value;\n const parsedValue = parseFloat(this.value as never);\n if (isNaN(parsedValue)) {\n value = this.getDefaultValue(min, max);\n } else {\n value = parsedValue;\n }\n\n if (this.nativeInput != null) {\n // The value may have constraints, so we set the native control's\n // value and sync it back to ensure it adheres to min, max, and step\n // properly.\n this.nativeInput.value = value.toString();\n this.value = parseFloat(this.nativeInput.value);\n } else {\n this.value = value;\n }\n this.calculateColorRunnableTrack(min, max, this.value);\n this.syncTooltip(min, max, this.value);\n }\n\n /**\n * from https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/range#value\n */\n private getDefaultValue(min: number, max: number): number {\n return max < min ? min : min + (max - min) / 2;\n }\n\n /**\n * For Firefox this functionality is not needed because it is supported by standard CSS.\n */\n private calculateColorRunnableTrack(min: number, max: number, value: number) {\n if (!this.isFirefox() && this.nativeInput != null) {\n const percent = Math.ceil(((value - min) / (max - min)) * 100);\n this.nativeInput.style.background =\n '-webkit-linear-gradient(left, var(--track-color) 0%, var(--track-color) ' +\n percent +\n '%, var(--six-color-web-rock-300) ' +\n percent +\n '%)';\n }\n }\n\n render() {\n return (\n <FormControl\n inputId={this.inputId}\n label={this.label}\n labelId={this.labelId}\n hasLabelSlot={this.hasLabelSlot}\n helpTextId={this.helpTextId}\n helpText={this.helpText}\n hasHelpTextSlot={this.hasHelpTextSlot}\n size=\"medium\"\n errorTextId={this.errorTextId}\n errorText={this.errorText}\n hasErrorTextSlot={this.hasErrorTextSlot}\n errorTextCount={this.errorTextCount}\n disabled={this.disabled}\n required={this.required}\n displayError={this.invalid}\n >\n <div\n part=\"base\"\n class={{\n range: true,\n\n // States\n 'range--disabled': this.disabled,\n 'range--focused': this.hasFocus,\n 'range--tooltip-visible': this.hasTooltip,\n 'range--tooltip-top': this.tooltip === 'top',\n 'range--tooltip-bottom': this.tooltip === 'bottom',\n }}\n onTouchStart={this.handleTouchStart}\n >\n <input\n part=\"input\"\n ref={(el) => (this.nativeInput = el)}\n type=\"range\"\n class=\"range__control\"\n name={this.name}\n disabled={this.disabled}\n min={this.min}\n max={this.max}\n step={this.step}\n value={this.value}\n onInput={this.handleInput}\n onFocus={this.handleFocus}\n onBlur={this.handleBlur}\n />\n {this.tooltip !== 'none' && (\n <output part=\"tooltip\" ref={(el) => (this.output = el)} class=\"range__tooltip\">\n {this.tooltipFormatter(this.value)}\n </output>\n )}\n </div>\n </FormControl>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,WAAW,GAAG,0pNAA0pN;;ACM9qN,IAAI,EAAE,GAAG,CAAC;MAqBG,QAAQ,GAAA,MAAA;AALrB,IAAA,WAAA,CAAA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M,KACtB,+DAAQ,IAAI,EAAC,SAAS,EAAC,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,MAAM,GAAG,EAAE,CAAC,EAAE,KAAK,EAAC,gBAAgB,EAAA,EAC3E,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,KAAK,CAAC,CAC3B,CACV,CACG,CACM;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"six-range.entry.js","sources":["src/components/six-range/six-range.scss?tag=six-range&encapsulation=shadow","src/components/six-range/six-range.tsx"],"sourcesContent":["@import '../../../src/global/component';\n@import '../../functional-components/form-control/form-control';\n\n:host {\n --thumb-size: 14px;\n --tooltip-offset-y: 10px;\n --track-color: var(--six-color-web-rock-900);\n --thumb-color: var(--six-color-web-rock-900);\n --track-height: 3px;\n\n display: block;\n}\n\n.range {\n position: relative;\n\n .range__control {\n -webkit-appearance: none;\n width: 100%;\n height: var(--six-input-height-medium);\n background: transparent;\n line-height: var(--six-input-height-medium);\n vertical-align: middle;\n\n &::-webkit-slider-runnable-track {\n width: 100%;\n height: var(--track-height);\n border-radius: 3px;\n border: none;\n }\n\n &::-webkit-slider-thumb {\n border: none;\n width: var(--thumb-size);\n height: var(--thumb-size);\n border-radius: 50%;\n background-color: var(--thumb-color);\n -webkit-appearance: none;\n margin-top: calc(var(--thumb-size) / -2 + var(--track-height) / 2);\n transition:\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) background-color,\n var(--six-transition-fast) color,\n var(--six-transition-fast) box-shadow,\n var(--six-transition-fast) transform;\n cursor: pointer;\n }\n\n &:not(:disabled)::-webkit-slider-thumb:hover {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled):focus::-webkit-slider-thumb {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled)::-webkit-slider-thumb:active {\n background-color: var(--thumb-color);\n cursor: grabbing;\n }\n\n // Firefox\n &::-moz-focus-outer {\n border: 0;\n }\n\n &::-moz-range-track {\n width: 100%;\n height: var(--track-height);\n background-color: var(--six-progress-track-color);\n border-radius: 3px;\n border: none;\n }\n\n &::-moz-range-progress {\n height: var(--track-height);\n border-radius: 3px;\n background-color: var(--track-color);\n border: none;\n }\n\n &::-moz-range-thumb {\n border: none;\n height: var(--thumb-size);\n width: var(--thumb-size);\n border-radius: 50%;\n background-color: var(--thumb-color);\n transition:\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) background-color,\n var(--six-transition-fast) color,\n var(--six-transition-fast) box-shadow,\n var(--six-transition-fast) transform;\n cursor: pointer;\n }\n\n &:not(:disabled)::-moz-range-thumb:hover {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled):focus::-moz-range-thumb {\n background-color: var(--thumb-color);\n }\n\n &:not(:disabled)::-moz-range-thumb:active {\n background-color: var(--thumb-color);\n cursor: grabbing;\n }\n\n // States\n &:focus {\n outline: none;\n }\n\n &:disabled {\n &::-webkit-slider-thumb {\n cursor: not-allowed;\n color: var(--six-color-web-rock-300);\n border-color: var(--six-color-web-rock-300);\n background-color: var(--six-color-web-rock-300);\n }\n\n &::-moz-range-thumb {\n cursor: not-allowed;\n color: var(--six-color-web-rock-300);\n border-color: var(--six-color-web-rock-300);\n background-color: var(--six-color-web-rock-300);\n }\n }\n }\n}\n\n// Tooltip\n.range__tooltip {\n position: absolute;\n z-index: var(--six-z-index-tooltip);\n left: 2px;\n border-radius: var(--six-border-radius-medium);\n background-color: var(--six-color-web-rock-900);\n font-family: var(--six-font-family);\n font-size: var(--six-tooltip-font-size);\n font-weight: var(--six-tooltip-font-weight);\n line-height: var(--six-tooltip-line-height);\n color: var(--six-color-white);\n opacity: 0;\n padding: var(--six-spacing-xxx-small) var(--six-spacing-xx-small);\n transition: var(--six-transition-fast) opacity;\n pointer-events: none;\n\n &::after {\n content: '';\n position: absolute;\n width: 0;\n height: 0;\n left: 50%;\n margin-left: calc(-1 * var(--six-tooltip-arrow-size));\n }\n}\n\n.range--tooltip-visible .range__tooltip {\n opacity: 1;\n}\n\n// Tooltip on top\n.range--tooltip-top .range__tooltip {\n top: calc(-1 * var(--thumb-size) - var(--tooltip-offset-y));\n\n &::after {\n border-top: var(--six-tooltip-arrow-size) solid var(--six-color-web-rock-900);\n border-left: var(--six-tooltip-arrow-size) solid transparent;\n border-right: var(--six-tooltip-arrow-size) solid transparent;\n top: 100%;\n }\n}\n\n// Tooltip on bottom\n.range--tooltip-bottom .range__tooltip {\n bottom: calc(-1 * var(--thumb-size) - var(--tooltip-offset-y));\n\n &::after {\n border-bottom: var(--six-tooltip-arrow-size) solid var(--six-color-web-rock-900);\n border-left: var(--six-tooltip-arrow-size) solid transparent;\n border-right: var(--six-tooltip-arrow-size) solid transparent;\n bottom: 100%;\n }\n}\n","import { Component, Element, Event, EventEmitter, h, Method, Prop, State, Watch } from '@stencil/core';\nimport FormControl from '../../functional-components/form-control/form-control';\nimport { hasSlot } from '../../utils/slot';\nimport { EmptyPayload } from '../../utils/types';\nimport { EventListeners } from '../../utils/event-listeners';\n\nlet id = 0;\n\n/**\n * @since 1.0\n * @status stable\n *\n * Forked from https://github.com/shoelace-style/shoelace version v2.0.0-beta27.\n *\n * @slot label - The input's label. Alternatively, you can use the label prop.\n * @slot help-text - Help text that describes how to use the input. Alternatively, you can use the help-text prop.\n * @slot error-text - Error text that is shown for validation errors. Alternatively, you can use the error-text prop.\n *\n * @part base - The component's base wrapper.\n * @part input - The native range input.\n * @part tooltip - The range tooltip.\n */\n@Component({\n tag: 'six-range',\n styleUrl: 'six-range.scss',\n shadow: true,\n})\nexport class SixRange {\n private inputId = `input-${++id}`;\n private labelId = `input-label-${id}`;\n private helpTextId = `input-help-text-${id}`;\n private errorTextId = `input-error-text-${id}`;\n private eventListeners = new EventListeners();\n private resizeObserver?: ResizeObserver;\n\n private output?: HTMLElement;\n private nativeInput?: HTMLInputElement;\n\n @Element() host!: HTMLSixRangeElement;\n\n @State() hasFocus = false;\n @State() hasHelpTextSlot = false;\n @State() hasErrorTextSlot = false;\n @State() hasLabelSlot = false;\n @State() hasTooltip = false;\n\n /** The input's name attribute. */\n @Prop() name = '';\n\n /** The input's value attribute. */\n @Prop({ mutable: true }) value = 0;\n\n /** Set to true to show an asterisk beneath the label. */\n @Prop() required = false;\n\n /** The range's help text. Alternatively, you can use the help-text slot. */\n @Prop() helpText = '';\n\n /** Set to true to disable the input. */\n @Prop() disabled = false;\n\n /** The label text. */\n @Prop() label = '';\n\n /** The error message shown, if `invalid` is set to true. */\n @Prop() errorText: string | string[] = '';\n\n /** The number of error texts to be shown (if the error-text slot isn't used). Defaults to 1 */\n @Prop() errorTextCount?: number;\n\n /** If this property is set to true and an error message is provided by `errorText`, the error message is displayed. */\n @Prop({ reflect: true }) invalid = false;\n\n /** The input's min attribute. */\n @Prop() min = 0;\n\n /** The input's max attribute. */\n @Prop() max = 100;\n\n /** The input's step attribute. */\n @Prop() step = 1;\n\n /** The preferred placedment of the tooltip. */\n @Prop() tooltip: 'top' | 'bottom' | 'none' = 'top';\n\n /** A function used to format the tooltip's value. */\n @Prop() tooltipFormatter = (value: number) => value.toString();\n\n /** Emitted when the control's value changes. */\n @Event({ eventName: 'six-range-change' }) sixChange!: EventEmitter<EmptyPayload>;\n\n /** Emitted when the control loses focus. */\n @Event({ eventName: 'six-range-blur' }) sixBlur!: EventEmitter<EmptyPayload>;\n\n /** Emitted when the control gains focus. */\n @Event({ eventName: 'six-range-focus' }) sixFocus!: EventEmitter<EmptyPayload>;\n\n @Watch('label')\n @Watch('errorText')\n @Watch('helpText')\n handleLabelChange() {\n this.handleSlotChange();\n }\n\n @Watch('value')\n @Watch('min')\n @Watch('max')\n handleValueChange() {\n this.update();\n }\n\n connectedCallback() {\n this.host.shadowRoot?.addEventListener('slotchange', this.handleSlotChange);\n }\n\n componentWillLoad() {\n this.update();\n this.handleSlotChange();\n }\n\n componentDidLoad() {\n const nativeInput = this.nativeInput;\n if (nativeInput == null) {\n return;\n }\n this.update();\n this.resizeObserver = new ResizeObserver(() => this.update());\n }\n\n disconnectedCallback() {\n this.host.shadowRoot?.removeEventListener('slotchange', this.handleSlotChange);\n this.eventListeners.removeAll();\n }\n\n componentDidUpdate() {\n const { min, max } = this.getMinMax();\n this.syncTooltip(min, max, this.value);\n }\n\n private getMinMax() {\n const min = Number(this.min) ?? 0;\n const max = Number(this.max) ?? 0;\n return { min, max };\n }\n\n /** Sets focus on the input. */\n @Method()\n async setFocus(options?: FocusOptions) {\n this.nativeInput?.focus(options);\n }\n\n /** Removes focus from the input. */\n @Method()\n async removeFocus() {\n this.nativeInput?.blur();\n }\n\n private handleInput = () => {\n if (this.nativeInput != null) {\n this.update(parseFloat(this.nativeInput.value));\n }\n requestAnimationFrame(() => {\n this.sixChange.emit();\n });\n };\n\n private handleBlur = () => {\n this.hasFocus = false;\n this.hasTooltip = false;\n this.sixBlur.emit();\n if (this.nativeInput != null) {\n this.resizeObserver?.unobserve(this.nativeInput);\n }\n };\n\n private handleFocus = () => {\n this.hasFocus = true;\n this.hasTooltip = true;\n this.sixFocus.emit();\n if (this.nativeInput != null) {\n this.resizeObserver?.observe(this.nativeInput);\n }\n };\n\n private handleSlotChange = () => {\n this.hasHelpTextSlot = hasSlot(this.host, 'help-text');\n this.hasLabelSlot = hasSlot(this.host, 'label');\n this.hasErrorTextSlot = hasSlot(this.host, 'error-text');\n };\n\n private handleTouchStart = () => {\n this.setFocus();\n };\n\n private syncTooltip(min: number, max: number, value: number) {\n if (this.tooltip !== 'none' && this.nativeInput != null && this.output != null) {\n const percent = Math.max(0, (value - min) / (max - min));\n const inputWidth = this.nativeInput.offsetWidth;\n const tooltipWidth = this.output.offsetWidth;\n const thumbSize = getComputedStyle(this.nativeInput).getPropertyValue('--thumb-size');\n const x = `calc(${inputWidth * percent}px - calc(calc(${percent} * ${thumbSize}) - calc(${thumbSize} / 2)))`;\n this.output.style.transform = `translateX(${x})`;\n this.output.style.marginLeft = `-${tooltipWidth / 2}px`;\n }\n }\n\n private isFirefox() {\n return navigator.userAgent.toLowerCase().indexOf('firefox') > -1;\n }\n\n private update(updateValue?: number) {\n if (updateValue != null) {\n this.value = updateValue;\n }\n\n const min = Number(this.min) ?? 0;\n const max = Number(this.max) ?? 0;\n let value;\n const parsedValue = parseFloat(this.value as never);\n if (isNaN(parsedValue)) {\n value = this.getDefaultValue(min, max);\n } else {\n value = parsedValue;\n }\n\n if (this.nativeInput != null) {\n // The value may have constraints, so we set the native control's\n // value and sync it back to ensure it adheres to min, max, and step\n // properly.\n this.nativeInput.value = value.toString();\n this.value = parseFloat(this.nativeInput.value);\n } else {\n this.value = value;\n }\n this.calculateColorRunnableTrack(min, max, this.value);\n this.syncTooltip(min, max, this.value);\n }\n\n /**\n * from https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/range#value\n */\n private getDefaultValue(min: number, max: number): number {\n return max < min ? min : min + (max - min) / 2;\n }\n\n /**\n * For Firefox this functionality is not needed because it is supported by standard CSS.\n */\n private calculateColorRunnableTrack(min: number, max: number, value: number) {\n if (!this.isFirefox() && this.nativeInput != null) {\n const percent = Math.ceil(((value - min) / (max - min)) * 100);\n this.nativeInput.style.background =\n '-webkit-linear-gradient(left, var(--track-color) 0%, var(--track-color) ' +\n percent +\n '%, var(--six-color-web-rock-300) ' +\n percent +\n '%)';\n }\n }\n\n render() {\n return (\n <FormControl\n inputId={this.inputId}\n label={this.label}\n labelId={this.labelId}\n hasLabelSlot={this.hasLabelSlot}\n helpTextId={this.helpTextId}\n helpText={this.helpText}\n hasHelpTextSlot={this.hasHelpTextSlot}\n size=\"medium\"\n errorTextId={this.errorTextId}\n errorText={this.errorText}\n hasErrorTextSlot={this.hasErrorTextSlot}\n errorTextCount={this.errorTextCount}\n disabled={this.disabled}\n required={this.required}\n displayError={this.invalid}\n >\n <div\n part=\"base\"\n class={{\n range: true,\n\n // States\n 'range--disabled': this.disabled,\n 'range--focused': this.hasFocus,\n 'range--tooltip-visible': this.hasTooltip,\n 'range--tooltip-top': this.tooltip === 'top',\n 'range--tooltip-bottom': this.tooltip === 'bottom',\n }}\n onTouchStart={this.handleTouchStart}\n >\n <input\n part=\"input\"\n ref={(el) => (this.nativeInput = el)}\n type=\"range\"\n class=\"range__control\"\n name={this.name}\n disabled={this.disabled}\n min={this.min}\n max={this.max}\n step={this.step}\n value={this.value}\n onInput={this.handleInput}\n onFocus={this.handleFocus}\n onBlur={this.handleBlur}\n />\n {this.tooltip !== 'none' && (\n <output part=\"tooltip\" ref={(el) => (this.output = el)} class=\"range__tooltip\">\n {this.tooltipFormatter(this.value)}\n </output>\n )}\n </div>\n </FormControl>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,WAAW,GAAG,0pNAA0pN;;ACM9qN,IAAI,EAAE,GAAG,CAAC;MAqBG,QAAQ,GAAA,MAAA;AALrB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;AAMU,QAAA,IAAA,CAAA,OAAO,GAAG,SAAS,EAAE,EAAE,EAAE;AACzB,QAAA,IAAA,CAAA,OAAO,GAAG,CAAe,YAAA,EAAA,EAAE,EAAE;AAC7B,QAAA,IAAA,CAAA,UAAU,GAAG,CAAmB,gBAAA,EAAA,EAAE,EAAE;AACpC,QAAA,IAAA,CAAA,WAAW,GAAG,CAAoB,iBAAA,EAAA,EAAE,EAAE;AACtC,QAAA,IAAA,CAAA,cAAc,GAAG,IAAI,cAAc,EAAE;AAQpC,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;AAChB,QAAA,IAAe,CAAA,eAAA,GAAG,KAAK;AACvB,QAAA,IAAgB,CAAA,gBAAA,GAAG,KAAK;AACxB,QAAA,IAAY,CAAA,YAAA,GAAG,KAAK;AACpB,QAAA,IAAU,CAAA,UAAA,GAAG,KAAK;;AAGnB,QAAA,IAAI,CAAA,IAAA,GAAG,EAAE;;AAGQ,QAAA,IAAK,CAAA,KAAA,GAAG,CAAC;;AAG1B,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;;AAGhB,QAAA,IAAQ,CAAA,QAAA,GAAG,EAAE;;AAGb,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;;AA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AI,CAAC,WAAW,GAAG,EAAE,CAAC,EACpC,IAAI,EAAC,OAAO,EACZ,KAAK,EAAC,gBAAgB,EACtB,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,GAAG,EAAE,IAAI,CAAC,GAAG,EACb,GAAG,EAAE,IAAI,CAAC,GAAG,EACb,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,MAAM,EAAE,IAAI,CAAC,UAAU,EACvB,CAAA,EACD,IAAI,CAAC,OAAO,KAAK,MAAM,KACtB,+DAAQ,IAAI,EAAC,SAAS,EAAC,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,MAAM,GAAG,EAAE,CAAC,EAAE,KAAK,EAAC,gBAAgB,EAAA,EAC3E,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,KAAK,CAAC,CAC3B,CACV,CACG,CACM;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,124 @@
1
+ import { r as registerInstance, c as createEvent, h, g as getElement } from './index-JoG9I7EO.js';
2
+ import { F as FormControl } from './form-control-DI6V1ZhR.js';
3
+ import { h as hasSlot } from './slot-j3oIB5oT.js';
4
+
5
+ const sixRatingCss = ":host{position:relative;box-sizing:border-box}:host *,:host *:before,:host *:after{box-sizing:border-box}.sr-only{clip:rect(0 0 0 0);clip-path:inset(50%);height:1px;overflow:hidden;position:absolute;white-space:nowrap;width:1px}.form-control .form-control__label{display:none}.form-control .form-control__help-text{display:none}.form-control .form-control__error-text{display:none;text-align:left}.form-control--has-label .form-control__label{display:inline-block;color:var(--six-input-label-color);font-weight:var(--six-font-weight-bold);margin-bottom:var(--six-spacing-x-small)}.form-control--has-label .form-control__label__required::after{color:var(--six-color-danger-800);content:\"*\";transform:scale(1.1);margin-left:var(--six-spacing-xxx-small);position:absolute}.form-control--has-label.form-control--small .form-control__label{font-size:var(--six-input-label-font-size-small)}.form-control--has-label.form-control--medium .form-control__label{font-size:var(--six-input-label-font-size-medium)}.form-control--has-label.form-control--large .form-control_label{font-size:var(--six-input-label-font-size-large)}.form-control--has-help-text .form-control__help-text{display:block;color:var(--six-input-help-text-color);margin-top:var(--six-spacing-x-small)}.form-control--has-help-text .form-control__help-text ::slotted(*){margin-top:var(--six-spacing-xxx-small)}.form-control--has-help-text.form-control--small .form-control__help-text{font-size:var(--six-input-help-text-font-size-small)}.form-control--has-help-text.form-control--medium .form-control__help-text{font-size:var(--six-input-help-text-font-size-medium)}.form-control--has-help-text.form-control--large .form-control__help-text{font-size:var(--six-input-help-text-font-size-large)}.form-control--has-error-text .form-control__error-text{display:block;margin-top:var(--six-spacing-xxx-small)}.form-control--has-error-text .form-control__error-text ::slotted(*){margin-top:var(--six-spacing-xxx-small)}.form-control--has-error-text.form-control--small .form-control__error-text{font-size:var(--six-input-help-text-font-size-small)}.form-control--has-error-text.form-control--medium .form-control__error-text{font-size:var(--six-input-help-text-font-size-medium)}.form-control--has-error-text.form-control--large .form-control__error-text{font-size:var(--six-input-help-text-font-size-large)}.form-control--disabled .form-control__help-text{color:var(--six-input-help-text-color-disabled)}.form-control--disabled .form-control__label{color:var(--six-input-label-color-disabled)}.form-control--invalid:not(.form-control--disabled) .form-control__label{color:var(--six-input-label-color)}:host{--six-rating-color:var(--six-color-web-rock-500);--six-rating-color-active:var(--six-color-warning-700);--six-rating-color-disabled-opacity:0.4;display:block}.six-rating{display:inline-flex;flex-direction:row;user-select:none;cursor:pointer}.six-rating--readonly{cursor:unset}.six-rating--disabled{cursor:not-allowed;opacity:var(--six-rating-color-disabled-opacity)}.six-rating__star{color:var(--six-rating-color)}.six-rating__star--filled{color:var(--six-rating-color-active)}";
6
+
7
+ const SixRating = class {
8
+ constructor(hostRef) {
9
+ registerInstance(this, hostRef);
10
+ this.sixBlur = createEvent(this, "six-rating-blur");
11
+ this.sixChange = createEvent(this, "six-rating-change");
12
+ this.sixFocus = createEvent(this, "six-rating-focus");
13
+ /** The rating's name attribute. */
14
+ this.name = '';
15
+ /** The rating's value attribute. */
16
+ this.value = 0;
17
+ /** Set to true to disable the rating. */
18
+ this.disabled = false;
19
+ /** Set to true to show an asterisk beneath the label. */
20
+ this.required = false;
21
+ /** The label text. */
22
+ this.label = '';
23
+ /** The error message shown, if `invalid` is set to true. */
24
+ this.errorText = '';
25
+ /** If this property is set to true and an error message is provided by `errorText`, the error message is displayed. */
26
+ this.invalid = false;
27
+ /** Maximum number of stars. Default is 5 */
28
+ this.max = 5;
29
+ /** Size of the stars */
30
+ this.size = 'medium';
31
+ /** If its readonly */
32
+ this.readonly = false;
33
+ /** The rating's help text. Alternatively, you can use the help-text slot. */
34
+ this.helpText = '';
35
+ // --
36
+ this.hasFocus = false;
37
+ this.hasLabelSlot = false;
38
+ this.hasErrorSlot = false;
39
+ this.hoveredValue = this.value;
40
+ this.ratingId = `rating-${++SixRating.id}`;
41
+ this.labelId = `rating-label-${SixRating.id}`;
42
+ this.errorTextId = `input-error-text-${SixRating.id}`;
43
+ this.handleSlotChange = () => {
44
+ this.hasLabelSlot = hasSlot(this.el, 'label');
45
+ this.hasErrorSlot = hasSlot(this.el, 'error-text');
46
+ };
47
+ this.handleBlur = () => {
48
+ this.hasFocus = false;
49
+ this.sixBlur.emit(this.value);
50
+ };
51
+ this.handleFocus = () => {
52
+ this.hasFocus = true;
53
+ this.sixFocus.emit();
54
+ };
55
+ this.handleKeyDown = (event) => {
56
+ if (event.key === 'ArrowLeft') {
57
+ event.preventDefault();
58
+ if (this.hoveredValue > 0) {
59
+ this.hoveredValue = this.hoveredValue - 1;
60
+ this.value = this.hoveredValue;
61
+ }
62
+ }
63
+ if (event.key === 'ArrowRight') {
64
+ event.preventDefault();
65
+ if (this.hoveredValue < this.max) {
66
+ this.hoveredValue = this.hoveredValue + 1;
67
+ }
68
+ }
69
+ };
70
+ }
71
+ handleValueChange() {
72
+ this.sixChange.emit(this.value);
73
+ }
74
+ connectedCallback() {
75
+ var _a;
76
+ (_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.addEventListener('slotchange', this.handleSlotChange);
77
+ }
78
+ disconnectedCallback() {
79
+ var _a;
80
+ (_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.removeEventListener('slotchange', this.handleSlotChange);
81
+ }
82
+ renderStars() {
83
+ return Array.from({ length: this.max }, (_, i) => {
84
+ const handleEvent = (event) => {
85
+ if (this.readonly || this.disabled) {
86
+ return;
87
+ }
88
+ switch (event.type) {
89
+ case 'mouseover':
90
+ this.hoveredValue = i + 1;
91
+ break;
92
+ case 'mouseout':
93
+ this.hoveredValue = this.value;
94
+ break;
95
+ case 'click':
96
+ this.value = this.hoveredValue;
97
+ break;
98
+ }
99
+ };
100
+ return (h("six-icon", { class: {
101
+ 'six-rating__star': true,
102
+ 'six-rating__star--filled': i < this.hoveredValue,
103
+ }, filled: true, size: this.size, onMouseOver: handleEvent, onMouseOut: handleEvent, onClick: handleEvent }, "star_rate"));
104
+ });
105
+ }
106
+ render() {
107
+ return (h(FormControl, { key: 'ca3de959a1ffb915f0102ca6baa4a43c799d67ec', inputId: this.ratingId, label: this.label, labelId: this.labelId, hasLabelSlot: this.hasLabelSlot, errorTextId: this.errorTextId, errorText: this.errorText, errorTextCount: this.errorTextCount, helpText: this.helpText, hasErrorTextSlot: this.hasErrorSlot, size: "medium", disabled: this.disabled, required: this.required, displayError: this.invalid }, h("div", { key: 'ef452485f9c3615f4caeaefce7f7034d7f64119f', part: "base", class: {
108
+ 'six-rating': true,
109
+ 'six-rating--readonly': this.readonly,
110
+ 'six-rating--disabled': this.disabled,
111
+ }, role: "slider", "aria-label": this.label, "aria-disabled": this.disabled ? 'true' : 'false', "aria-readonly": this.readonly ? 'true' : 'false', "aria-valuenow": this.value, "aria-valuemin": 0, "aria-valuemax": this.max, tabindex: this.disabled ? '-1' : '0', onBlur: this.handleBlur, onFocus: this.handleFocus, onKeyDown: this.handleKeyDown }, this.renderStars(), h("input", { key: '187ec03d83c3b29fc5917a9abab324d40930b8f4', part: "input", id: this.ratingId, type: "hidden", max: this.max, min: 0, name: this.name, value: this.value, disabled: this.disabled, required: this.required, role: "slider", "aria-labelledby": this.labelId }))));
112
+ }
113
+ get el() { return getElement(this); }
114
+ static get watchers() { return {
115
+ "value": ["handleValueChange"]
116
+ }; }
117
+ };
118
+ SixRating.id = 0;
119
+ SixRating.style = sixRatingCss;
120
+
121
+ export { SixRating as six_rating };
122
+ //# sourceMappingURL=six-rating.entry.js.map
123
+
124
+ //# sourceMappingURL=six-rating.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"six-rating.entry.js","sources":["src/components/six-rating/six-rating.scss?tag=six-rating&encapsulation=shadow","src/components/six-rating/six-rating.tsx"],"sourcesContent":["@import '../../../src/global/component';\n@import '../../functional-components/form-control/form-control';\n\n:host {\n --six-rating-color: var(--six-color-web-rock-500);\n --six-rating-color-active: var(--six-color-warning-700);\n --six-rating-color-disabled-opacity: 0.4;\n\n display: block;\n}\n\n.six-rating {\n display: inline-flex;\n flex-direction: row;\n user-select: none;\n cursor: pointer;\n\n &--readonly {\n cursor: unset;\n }\n\n &--disabled {\n cursor: not-allowed;\n opacity: var(--six-rating-color-disabled-opacity);\n }\n\n &__star {\n color: var(--six-rating-color);\n\n &--filled {\n color: var(--six-rating-color-active);\n }\n }\n}\n","import { Component, Element, Event, EventEmitter, h, Prop, State, Watch } from '@stencil/core';\nimport FormControl from '../../functional-components/form-control/form-control';\nimport { EmptyPayload } from '../../utils/types';\nimport { hasSlot } from '../../utils/slot';\n\n@Component({\n tag: 'six-rating',\n styleUrl: 'six-rating.scss',\n shadow: true,\n})\nexport class SixRating {\n @Element() el!: HTMLSixRatingElement;\n\n /** The rating's name attribute. */\n @Prop() name = '';\n\n /** The rating's value attribute. */\n @Prop({ mutable: true }) value: number = 0;\n\n /** Set to true to disable the rating. */\n @Prop() disabled = false;\n\n /** Set to true to show an asterisk beneath the label. */\n @Prop() required = false;\n\n /** The label text. */\n @Prop() label: string = '';\n\n /** The error message shown, if `invalid` is set to true. */\n @Prop() errorText: string | string[] = '';\n\n /** The number of error texts to be shown (if the error-text slot isn't used). Defaults to 1 */\n @Prop() errorTextCount?: number;\n\n /** If this property is set to true and an error message is provided by `errorText`, the error message is displayed. */\n @Prop({ reflect: true }) invalid = false;\n\n /** Maximum number of stars. Default is 5 */\n @Prop() max: number = 5;\n\n /** Size of the stars */\n @Prop({ reflect: true }) size: 'xSmall' | 'small' | 'medium' | 'large' | 'xLarge' | 'xxLarge' | 'xxxLarge' = 'medium';\n\n /** If its readonly */\n @Prop() readonly: boolean = false;\n\n /** The rating's help text. Alternatively, you can use the help-text slot. */\n @Prop() helpText = '';\n\n /** Emitted when the control loses focus. */\n @Event({ eventName: 'six-rating-blur' }) sixBlur!: EventEmitter<number>;\n\n /** Emitted when the control's checked state changes. */\n @Event({ eventName: 'six-rating-change' }) sixChange!: EventEmitter<number>;\n\n /** Emitted when the control gains focus. */\n @Event({ eventName: 'six-rating-focus' }) sixFocus!: EventEmitter<EmptyPayload>;\n\n // --\n\n @State() hasFocus = false;\n @State() hasLabelSlot = false;\n @State() hasErrorSlot = false;\n @State() hoveredValue = this.value;\n\n private static id: number = 0;\n\n private ratingId = `rating-${++SixRating.id}`;\n private labelId = `rating-label-${SixRating.id}`;\n private errorTextId = `input-error-text-${SixRating.id}`;\n\n @Watch('value')\n handleValueChange() {\n this.sixChange.emit(this.value);\n }\n\n connectedCallback() {\n this.el.shadowRoot?.addEventListener('slotchange', this.handleSlotChange);\n }\n\n disconnectedCallback() {\n this.el.shadowRoot?.removeEventListener('slotchange', this.handleSlotChange);\n }\n\n private handleSlotChange = () => {\n this.hasLabelSlot = hasSlot(this.el, 'label');\n this.hasErrorSlot = hasSlot(this.el, 'error-text');\n };\n\n private handleBlur = () => {\n this.hasFocus = false;\n this.sixBlur.emit(this.value);\n };\n\n private handleFocus = () => {\n this.hasFocus = true;\n this.sixFocus.emit();\n };\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'ArrowLeft') {\n event.preventDefault();\n if (this.hoveredValue > 0) {\n this.hoveredValue = this.hoveredValue - 1;\n this.value = this.hoveredValue;\n }\n }\n\n if (event.key === 'ArrowRight') {\n event.preventDefault();\n if (this.hoveredValue < this.max) {\n this.hoveredValue = this.hoveredValue + 1;\n }\n }\n };\n\n private renderStars() {\n return Array.from({ length: this.max }, (_, i) => {\n const handleEvent = (event: Event) => {\n if (this.readonly || this.disabled) {\n return;\n }\n switch (event.type) {\n case 'mouseover':\n this.hoveredValue = i + 1;\n break;\n case 'mouseout':\n this.hoveredValue = this.value;\n break;\n case 'click':\n this.value = this.hoveredValue;\n break;\n }\n };\n\n return (\n <six-icon\n class={{\n 'six-rating__star': true,\n 'six-rating__star--filled': i < this.hoveredValue,\n }}\n filled\n size={this.size}\n onMouseOver={handleEvent}\n onMouseOut={handleEvent}\n onClick={handleEvent}\n >\n star_rate\n </six-icon>\n );\n });\n }\n\n render() {\n return (\n <FormControl\n inputId={this.ratingId}\n label={this.label}\n labelId={this.labelId}\n hasLabelSlot={this.hasLabelSlot}\n errorTextId={this.errorTextId}\n errorText={this.errorText}\n errorTextCount={this.errorTextCount}\n helpText={this.helpText}\n hasErrorTextSlot={this.hasErrorSlot}\n size=\"medium\"\n disabled={this.disabled}\n required={this.required}\n displayError={this.invalid}\n >\n <div\n part=\"base\"\n class={{\n 'six-rating': true,\n 'six-rating--readonly': this.readonly,\n 'six-rating--disabled': this.disabled,\n }}\n role=\"slider\"\n aria-label={this.label}\n aria-disabled={this.disabled ? 'true' : 'false'}\n aria-readonly={this.readonly ? 'true' : 'false'}\n aria-valuenow={this.value}\n aria-valuemin={0}\n aria-valuemax={this.max}\n tabindex={this.disabled ? '-1' : '0'}\n onBlur={this.handleBlur}\n onFocus={this.handleFocus}\n onKeyDown={this.handleKeyDown}\n >\n {this.renderStars()}\n\n <input\n part=\"input\"\n id={this.ratingId}\n type=\"hidden\"\n max={this.max}\n min={0}\n name={this.name}\n value={this.value}\n disabled={this.disabled}\n required={this.required}\n role=\"slider\"\n aria-labelledby={this.labelId}\n />\n </div>\n </FormControl>\n );\n }\n}\n"],"names":[],"mappings":";;;;AAAA,MAAM,YAAY,GAAG,mkGAAmkG;;MCU3kG,SAAS,GAAA,MAAA;AALtB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;;AASU,QAAA,IAAI,CAAA,IAAA,GAAG,EAAE;;AAGQ,QAAA,IAAK,CAAA,KAAA,GAAW,CAAC;;AAGlC,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;;AAGhB,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;;AAGhB,QAAA,IAAK,CAAA,KAAA,GAAW,EAAE;;AAGlB,QAAA,IAAS,CAAA,SAAA,GAAsB,EAAE;;AAMhB,QAAA,IAAO,CAAA,OAAA,GAAG,KAAK;;AAGhC,QAAA,IAAG,CAAA,GAAA,GAAW,CAAC;;AAGE,QAAA,IAAI,CAAA,IAAA,GAAgF,QAAQ;;AAG7G,QAAA,IAAQ,CAAA,QAAA,GAAY,KAAK;;AAGzB,QAAA,IAAQ,CAAA,QAAA,GAAG,EAAE;;AAaZ,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;AAChB,QAAA,IAAY,CAAA,YAAA,GAAG,KAAK;AACpB,QAAA,IAAY,CAAA,YAAA,GAAG,KAAK;AACpB,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,CAAC,KAAK;QAI1B,IAAA,CAAA,QAAQ,GAAG,CAAA,OAAA,EAAU,EAAE,SAAS,CAAC,EAAE,CAAA,CAAE;QACrC,IAAA,CAAA,OAAO,GAAG,CAAA,aAAA,EAAgB,SAAS,CAAC,EAAE,EAAE;QACxC,IAAA,CAAA,WAAW,GAAG,CAAA,iBAAA,EAAoB,SAAS,CAAC,EAAE,EAAE;AAehD,QAAA,IAAgB,CAAA,gBAAA,GAAG,MAAK;Y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AAA,EAAA,GAAA,EAAA,0CAAA,EAAA,IAAI,EAAC,OAAO,EACZ,EAAE,EAAE,IAAI,CAAC,QAAQ,EACjB,IAAI,EAAC,QAAQ,EACb,GAAG,EAAE,IAAI,CAAC,GAAG,EACb,GAAG,EAAE,CAAC,EACN,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,IAAI,EAAC,QAAQ,EACI,iBAAA,EAAA,IAAI,CAAC,OAAO,EAC7B,CAAA,CACE,CACM;;;;;;;AA5IH,SAAE,CAAA,EAAA,GAAW,CAAX;;;;;"}
@@ -14,7 +14,7 @@ const SixRoot = class {
14
14
  this.version = '';
15
15
  }
16
16
  render() {
17
- return (h("host", { key: '005ad5514d4137e97a862fd2a09151013e6250d0', class: "six-root" }, h("header", { key: '4cde9e57f125b9ea179608c36b311d33449ab9d3', part: "header" }, this.stage && h("six-stage-indicator", { key: '9c8d9ce4ae9d7652249fd3e2bbb39431830e6813', stage: this.stage }, this.version), h("slot", { key: 'dd414f2b13ec59e96ebe1e1df8f2fb71de113a60', name: "header" })), h("nav", { key: 'b9abf9d3eae12e6c492b64aada73bd7101a4edb1', class: "six-root__left-sidebar", part: "left-sidebar" }, h("slot", { key: 'd664769001501f55dd65a0c772fa6df6742ffe4c', name: "left-sidebar" })), h("main", { key: '4fb77beeed3e16ccb53a6d486d1307893d16aac3', part: "main" }, h("div", { key: '587d43eedf0a41c790b184c54f41941ea12fdd37', class: { 'six-root__container': true, 'six-root__container--padded': this.padded }, part: "container" }, h("slot", { key: '66473b0c3e44effb55ce262b27f2980b668b4335', name: "main" })), h("div", { key: 'b4dcc58d0fe42bcee91f2d0586e07f026b70bf5f', class: "six-root__footer" }, h("slot", { key: 'bf3efc6011d2cfbdd121973d77b7eba58c12c440', name: "footer" }))), h("nav", { key: '88683d098fd1c75bf35b9ecb9aaf2d2e1b8f6715', class: "six-root__right-sidebar", part: "right-sidebar" }, h("slot", { key: '3e38e0f3d3c0c66075c27f305d0460f52bbf725c', name: "right-sidebar" }))));
17
+ return (h("host", { key: '574331a30ddbdff3fb37129ec8e46c873bc1832e', class: "six-root" }, h("header", { key: 'f70f24b925ba9a88156d46a6481f6ab3f415bdad', part: "header" }, this.stage && h("six-stage-indicator", { key: '4fe5f33c59e77fcd1cae71afa5ccdd227fbd3d74', stage: this.stage }, this.version), h("slot", { key: '92fcdbb991e5593d0f5e602a3dc72b3bc95ce415', name: "header" })), h("nav", { key: 'd26e8e840ae344dcda1e81879e50f45981ad0035', class: "six-root__left-sidebar", part: "left-sidebar" }, h("slot", { key: 'da2e4b7ea1338e68970364d279753b7dd9ce4716', name: "left-sidebar" })), h("main", { key: '13c283e1e1150c3a6f0cc76feed50889023c8bfc', part: "main" }, h("div", { key: '0fd0a46e4d68dc7af4f4444de6cbd0cb68e3098a', class: { 'six-root__container': true, 'six-root__container--padded': this.padded }, part: "container" }, h("slot", { key: '5591878851514068d3ce5751af12fa86aa6449ca', name: "main" })), h("div", { key: 'fe14e87f84217215d03545b5094f462981124093', class: "six-root__footer" }, h("slot", { key: '44cd8020e7ba2ee5a4bfb50a8e9f46cac4c6010f', name: "footer" }))), h("nav", { key: 'a26ca2c92e7e0ef955bea7796270a5d64e9c1aec', class: "six-root__right-sidebar", part: "right-sidebar" }, h("slot", { key: '8d72471d1f4e06722eed5042dd8e4a5f9141b403', name: "right-sidebar" }))));
18
18
  }
19
19
  get host() { return getElement(this); }
20
20
  };
@@ -16,11 +16,11 @@ const SixSidebarItem = class {
16
16
  }
17
17
  render() {
18
18
  const Tag = this.href != null ? 'a' : 'div';
19
- return (h(Tag, { key: 'd36654ad6af78000c79191da18b9af02d582dde1', class: {
19
+ return (h(Tag, { key: '968d681e125a0c399973cfa9d37ac5f9c269042f', class: {
20
20
  'sidebar-item': true,
21
21
  'sidebar-item--selected': this.selected,
22
22
  'sidebar-item--disabled': this.disabled,
23
- }, role: "menuitem", href: this.href, "aria-selected": this.selected ? 'true' : 'false', "aria-disabled": this.disabled ? 'true' : 'false' }, this.icon && h("six-icon", { key: '8664269ee064fa6abd7529ddf92bfcd62e1fe83d', class: "six-sidebar-item__icon" }, this.icon), h("slot", { key: '528d1bd9d6b2e329292a90b7f21412f441dce27b' })));
23
+ }, role: "menuitem", href: this.href, "aria-selected": this.selected ? 'true' : 'false', "aria-disabled": this.disabled ? 'true' : 'false' }, this.icon && h("six-icon", { key: 'cd6ecec3465b0aeb625d3f0d0e7f8f6a8e76a25f', class: "six-sidebar-item__icon" }, this.icon), h("slot", { key: 'a54998cb6bc27463ab2f9402736008a8767b8358' })));
24
24
  }
25
25
  };
26
26
  SixSidebarItem.style = sixSidebarItemCss;
@@ -179,7 +179,7 @@ const SixSidebar = class {
179
179
  this.open ? this.sixAfterShow.emit() : this.sixAfterHide.emit();
180
180
  }
181
181
  render() {
182
- return (h("host", { key: '38d2d55b73e862c71ef3912fac01f6abd43a3b7c', class: "six-sidebar" }, h("div", { key: 'b8a7a32d48016310f943b42d03f1c4a44ff5bca4', class: {
182
+ return (h("host", { key: '11810533a79d5685e6ab768f0fbc8d9594d44de4', class: "six-sidebar" }, h("div", { key: '6908b34bd6df174046145e9c4813278703e0d7cf', class: {
183
183
  sidebar__container: true,
184
184
  'sidebar--visible': this.isVisible,
185
185
  'sidebar--open': this.open,
@@ -188,7 +188,7 @@ const SixSidebar = class {
188
188
  }, style: {
189
189
  width: this.width,
190
190
  [`margin-${this.position}`]: this.open ? '0' : `calc(1rem - ${this.width})`,
191
- }, ref: (el) => (this.sidebar = el), "aria-hidden": this.open ? 'false' : 'true', onTransitionEnd: this.handleTransitionEnd }, h("slot", { key: 'a13e1cd44a68fa3ad15a94ccc56ec7c09f689e4c' }))));
191
+ }, ref: (el) => (this.sidebar = el), "aria-hidden": this.open ? 'false' : 'true', onTransitionEnd: this.handleTransitionEnd }, h("slot", { key: '31557fda47113669da4d999a54f0074b37daffc8' }))));
192
192
  }
193
193
  static get watchers() { return {
194
194
  "open": ["handleOpenChange"]
@@ -105,12 +105,12 @@ const SixSwitch = class {
105
105
  (_a = this.inputElement) === null || _a === void 0 ? void 0 : _a.blur();
106
106
  }
107
107
  render() {
108
- return (h(FormControl, { key: 'a358f086b57322b8e3225f4775b09506e766c968', inputId: this.switchId, label: this.label, labelId: this.labelId, hasLabelSlot: false, errorTextId: this.errorTextId, errorText: this.errorText, errorTextCount: this.errorTextCount, hasErrorTextSlot: this.hasErrorTextSlot, size: "medium", disabled: this.disabled, required: this.required, displayError: this.invalid }, h("label", { key: '7b87b1d45026bb79c0c1ce5c0cf2e969ee0d0ca7', part: "base", htmlFor: this.switchId, class: {
108
+ return (h(FormControl, { key: 'fd6c9c888316e46623e92b779c2215888783413b', inputId: this.switchId, label: this.label, labelId: this.labelId, hasLabelSlot: false, errorTextId: this.errorTextId, errorText: this.errorText, errorTextCount: this.errorTextCount, hasErrorTextSlot: this.hasErrorTextSlot, size: "medium", disabled: this.disabled, required: this.required, displayError: this.invalid }, h("label", { key: 'd7d5f569d8aea4f7203f7c0973cf212bd6bcfc60', part: "base", htmlFor: this.switchId, class: {
109
109
  switch: true,
110
110
  'switch--checked': this.checked,
111
111
  'switch--disabled': this.disabled,
112
112
  'switch--focused': this.hasFocus,
113
- }, onMouseDown: this.handleMouseDown }, h("span", { key: '35bd92fabfb1b177a048789e9f0f9d68499b7bd0', part: "control", class: "switch__control" }, h("span", { key: '0c85de3b5d75b3d083554931a5648be5ba26f7fc', part: "thumb", class: "switch__thumb" }), h("input", { key: '5c807156b356962f347820301050cd096ba67330', ref: (el) => (this.inputElement = el), id: this.switchId, type: "checkbox", name: this.name, value: this.value, checked: this.checked, disabled: this.disabled, required: this.required, role: "switch", "aria-checked": this.checked ? 'true' : 'false', "aria-labelledby": this.labelId, onClick: this.handleClick, onBlur: this.handleBlur, onFocus: this.handleFocus, onKeyDown: this.handleKeyDown })), h("span", { key: '923235545aec3ccb5c04aec3316fd8e5a2d027e2', part: "label", id: this.labelId, class: "switch__label" }, h("slot", { key: '53e2689b7efaac1a93954d02eb7d6b1cdadc8c73' })))));
113
+ }, onMouseDown: this.handleMouseDown }, h("span", { key: '4043bb4abed6a44a360b5409b0e4ebd5929a719f', part: "control", class: "switch__control" }, h("span", { key: 'd93e868866ea81ae2c2832ddc6fdcb11c0b23679', part: "thumb", class: "switch__thumb" }), h("input", { key: '7e5cff86449295f36e85b221f8795f3df18808ae', ref: (el) => (this.inputElement = el), id: this.switchId, type: "checkbox", name: this.name, value: this.value, checked: this.checked, disabled: this.disabled, required: this.required, role: "switch", "aria-checked": this.checked ? 'true' : 'false', "aria-labelledby": this.labelId, onClick: this.handleClick, onBlur: this.handleBlur, onFocus: this.handleFocus, onKeyDown: this.handleKeyDown })), h("span", { key: 'c0823f84eb3a30c2e0fdfe5acb6f1390e2b389aa', part: "label", id: this.labelId, class: "switch__label" }, h("slot", { key: 'aeb69e52fd37efab7ee8061d3c69bfab1c174933' })))));
114
114
  }
115
115
  get host() { return getElement(this); }
116
116
  static get watchers() { return {
@@ -1 +1 @@
1
- {"version":3,"file":"six-switch.entry.js","sources":["src/components/six-switch/six-switch.scss?tag=six-switch&encapsulation=shadow","src/components/six-switch/six-switch.tsx"],"sourcesContent":["@import 'src/global/component';\n@import '../../functional-components/form-control/form-control';\n\n/**\n * @prop --width: The width of the switch.\n * @prop --height: The height of the switch.\n * @prop --thumb-size: The size of the thumb.\n */\n:host {\n --height: var(--six-selection-control-toggle-size);\n --thumb-size: calc(var(--six-selection-control-toggle-size) - 4px);\n --width: calc(var(--height) * 2);\n\n display: inline-block;\n}\n\n.switch {\n display: inline-flex;\n align-items: center;\n font-family: var(--six-font-family);\n font-size: var(--six-input-font-size-medium);\n font-weight: var(--six-input-font-weight);\n color: var(--six-input-color);\n vertical-align: middle;\n cursor: pointer;\n}\n\n.switch__control {\n position: relative;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: var(--width);\n height: var(--height);\n background-color: var(--six-selection-control-color-disabled);\n border-radius: var(--height);\n transition:\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) background-color;\n\n .switch__thumb {\n width: var(--thumb-size);\n height: var(--thumb-size);\n background-color: var(--six-input-background-color);\n border-radius: 50%;\n transform: translateX(calc(var(--width) / -2 + var(--thumb-size) / 2 - (var(--thumb-size) - var(--height)) / 2));\n transition:\n var(--six-transition-fast) transform ease,\n var(--six-transition-fast) background-color,\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) box-shadow;\n }\n\n input[type='checkbox'] {\n position: absolute;\n opacity: 0;\n padding: 0;\n margin: 0;\n pointer-events: none;\n }\n}\n\n// Hover\n.switch:not(.switch--checked):not(.switch--disabled) .switch__control:hover {\n background-color: var(--six-input-border-color-hover);\n}\n\n// Checked\n.switch--checked .switch__control {\n background-color: var(--six-selection-control-color);\n\n .switch__thumb {\n background-color: var(--six-color-white);\n transform: translateX(calc(var(--width) / 2 - var(--thumb-size) / 2 + (var(--thumb-size) - var(--height)) / 2));\n }\n}\n\n// Checked + hover\n.switch.switch--checked:not(.switch--disabled) .switch__control:hover {\n background-color: var(--six-input-border-color-focus);\n}\n\n// Disabled\n.switch--disabled {\n cursor: not-allowed;\n color: var(--six-selection-control-color-disabled);\n\n .switch__control {\n background-color: var(--six-selection-control-color-disabled);\n }\n\n &.switch--checked .switch__control {\n background-color: var(--six-selection-control-color-disabled);\n }\n}\n\n.switch__label {\n line-height: var(--height);\n margin-left: 0.5em;\n user-select: none;\n}\n","import { Component, Element, Event, EventEmitter, h, Method, Prop, State, Watch } from '@stencil/core';\nimport { EmptyPayload } from '../../utils/types';\nimport { EventListeners } from '../../utils/event-listeners';\nimport FormControl from '../../functional-components/form-control/form-control';\nimport { hasSlot } from '../../utils/slot';\n\nlet id = 0;\n\n/**\n * @since 1.0\n * @status stable\n *\n * Forked from https://github.com/shoelace-style/shoelace version v2.0.0-beta27.\n *\n * @slot - The switch's label.\n * @slot error-text - Error text that is shown for validation errors. Alternatively, you can use the error-text prop.\n *\n * @part base - The component's base wrapper.\n * @part control - The switch control.\n * @part thumb - The switch position indicator.\n * @part label - The switch label.\n */\n\n@Component({\n tag: 'six-switch',\n styleUrl: 'six-switch.scss',\n shadow: true,\n})\nexport class SixSwitch {\n private switchId = `switch-${++id}`;\n private labelId = `switch-label-${id}`;\n private errorTextId = `input-error-text-${id}`;\n\n private inputElement?: HTMLInputElement;\n private eventListeners = new EventListeners();\n\n @Element() host!: HTMLSixSwitchElement;\n\n @State() hasFocus = false;\n @State() hasErrorTextSlot = false;\n\n /** The switch's name attribute. */\n @Prop() name = '';\n\n /** The switch's value attribute. */\n @Prop() value = 'on';\n\n /** Set to true to disable the switch. */\n @Prop() disabled = false;\n\n /** Set to true to show an asterisk beneath the label. */\n @Prop() required = false;\n\n /** Set to true to draw the switch in a checked state. */\n @Prop({ mutable: true, reflect: true }) checked = false;\n\n /** The label text. */\n @Prop() label = '';\n\n /** The error message shown, if `invalid` is set to true. */\n @Prop() errorText: string | string[] = '';\n\n /** The number of error texts to be shown (if the error-text slot isn't used). Defaults to 1 */\n @Prop() errorTextCount?: number;\n\n /** If this property is set to true and an error message is provided by `errorText`, the error message is displayed. */\n @Prop({ reflect: true }) invalid = false;\n\n componentWillLoad() {\n this.handleSlotChange();\n }\n\n @Watch('checked')\n handleCheckedChange() {\n if (this.inputElement != null) {\n this.inputElement.checked = this.checked;\n this.checked = this.inputElement.checked;\n }\n }\n\n /** Emitted when the control loses focus. */\n @Event({ eventName: 'six-switch-blur' }) sixBlur!: EventEmitter<boolean>;\n\n /** Emitted when the control's checked state changes. */\n @Event({ eventName: 'six-switch-change' }) sixChange!: EventEmitter<boolean>;\n\n /** Emitted when the control gains focus. */\n @Event({ eventName: 'six-switch-focus' }) sixFocus!: EventEmitter<EmptyPayload>;\n\n connectedCallback() {\n this.host.shadowRoot?.addEventListener('slotchange', this.handleSlotChange);\n this.eventListeners.forward('six-switch-change', 'change', this.host);\n this.eventListeners.forward('six-switch-blur', 'blur', this.host);\n this.eventListeners.forward('six-switch-focus', 'focus', this.host);\n }\n\n disconnectedCallback() {\n this.host.shadowRoot?.removeEventListener('slotchange', this.handleSlotChange);\n this.eventListeners.removeAll();\n }\n\n @Watch('errorText')\n @Watch('label')\n handleLabelChange() {\n this.handleSlotChange();\n }\n\n private handleSlotChange = () => {\n this.hasErrorTextSlot = hasSlot(this.host, 'error-text');\n };\n\n /** Sets focus on the switch. */\n @Method()\n async setFocus(options?: FocusOptions) {\n this.inputElement?.focus(options);\n }\n\n /** Removes focus from the switch. */\n @Method()\n async removeFocus() {\n this.inputElement?.blur();\n }\n\n private handleClick = () => {\n if (this.inputElement != null) {\n this.checked = this.inputElement.checked;\n this.sixChange.emit(this.checked);\n }\n };\n\n private handleBlur = () => {\n this.hasFocus = false;\n this.sixBlur.emit(this.checked);\n };\n\n private handleFocus = () => {\n this.hasFocus = true;\n this.sixFocus.emit();\n };\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'ArrowLeft') {\n event.preventDefault();\n this.checked = false;\n this.sixChange.emit(this.checked);\n }\n\n if (event.key === 'ArrowRight') {\n event.preventDefault();\n this.checked = true;\n this.sixChange.emit(this.checked);\n }\n };\n\n private handleMouseDown = (event: MouseEvent) => {\n // Prevent clicks on the label from briefly blurring the input\n event.preventDefault();\n this.inputElement?.focus();\n };\n\n render() {\n return (\n <FormControl\n inputId={this.switchId}\n label={this.label}\n labelId={this.labelId}\n hasLabelSlot={false}\n errorTextId={this.errorTextId}\n errorText={this.errorText}\n errorTextCount={this.errorTextCount}\n hasErrorTextSlot={this.hasErrorTextSlot}\n size=\"medium\"\n disabled={this.disabled}\n required={this.required}\n displayError={this.invalid}\n >\n <label\n part=\"base\"\n htmlFor={this.switchId}\n class={{\n switch: true,\n 'switch--checked': this.checked,\n 'switch--disabled': this.disabled,\n 'switch--focused': this.hasFocus,\n }}\n onMouseDown={this.handleMouseDown}\n >\n <span part=\"control\" class=\"switch__control\">\n <span part=\"thumb\" class=\"switch__thumb\" />\n\n <input\n ref={(el) => (this.inputElement = el)}\n id={this.switchId}\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n checked={this.checked}\n disabled={this.disabled}\n required={this.required}\n role=\"switch\"\n aria-checked={this.checked ? 'true' : 'false'}\n aria-labelledby={this.labelId}\n onClick={this.handleClick}\n onBlur={this.handleBlur}\n onFocus={this.handleFocus}\n onKeyDown={this.handleKeyDown}\n />\n </span>\n\n <span part=\"label\" id={this.labelId} class=\"switch__label\">\n <slot />\n </span>\n </label>\n </FormControl>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,YAAY,GAAG,wuJAAwuJ;;ACM7vJ,IAAI,EAAE,GAAG,CAAC;MAsBG,SAAS,GAAA,MAAA;AALtB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;AAMU,QAAA,IAAA,CAAA,QAAQ,GAAG,UAAU,EAAE,EAAE,EAAE;AAC3B,QAAA,IAAA,CAAA,OAAO,GAAG,CAAgB,aAAA,EAAA,EAAE,EAAE;AAC9B,QAAA,IAAA,CAAA,WAAW,GAAG,CAAoB,iBAAA,EAAA,EAAE,EAAE;AAGtC,QAAA,IAAA,CAAA,cAAc,GAAG,IAAI,cAAc,EAAE;AAIpC,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;AAChB,QAAA,IAAgB,CAAA,gBAAA,GAAG,KAAK;;AAGzB,QAAA,IAAI,CAAA,IAAA,GAAG,EAAE;;AAGT,QAAA,IAAK,CAAA,KAAA,GAAG,IAAI;;AAGZ,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;;AAGhB,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;;AAGgB,QAAA,IAAO,CAAA,OAAA,GAAG,KAAK;;AAG/C,QAAA,IAAK,CAAA,KAAA,GAAG,EAAE;;AAGV,QAAA,IAAS,CAAA,SAAA,GAAsB,EAAE;;AAMhB,QAAA,IAAO,CAAA,OAAA,GAAG,KAAK;AAyChC,QAAA,IAAg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iBAAiB,EAAA,EAC1C,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAM,IAAI,EAAC,OAAO,EAAC,KAAK,EAAC,eAAe,EAAG,CAAA,EAE3C,CACE,CAAA,OAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,YAAY,GAAG,EAAE,CAAC,EACrC,EAAE,EAAE,IAAI,CAAC,QAAQ,EACjB,IAAI,EAAC,UAAU,EACf,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,IAAI,EAAC,QAAQ,EACC,cAAA,EAAA,IAAI,CAAC,OAAO,GAAG,MAAM,GAAG,OAAO,EAAA,iBAAA,EAC5B,IAAI,CAAC,OAAO,EAC7B,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,MAAM,EAAE,IAAI,CAAC,UAAU,EACvB,OAAO,EAAE,IAAI,CAAC,WAAW,EACzB,SAAS,EAAE,IAAI,CAAC,aAAa,EAAA,CAC7B,CACG,EAEP,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAM,IAAI,EAAC,OAAO,EAAC,EAAE,EAAE,IAAI,CAAC,OAAO,EAAE,KAAK,EAAC,eAAe,EAAA,EACxD,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAQ,CACH,CACD,CACI;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"six-switch.entry.js","sources":["src/components/six-switch/six-switch.scss?tag=six-switch&encapsulation=shadow","src/components/six-switch/six-switch.tsx"],"sourcesContent":["@import '../../../src/global/component';\n@import '../../functional-components/form-control/form-control';\n\n/**\n * @prop --width: The width of the switch.\n * @prop --height: The height of the switch.\n * @prop --thumb-size: The size of the thumb.\n */\n:host {\n --height: var(--six-selection-control-toggle-size);\n --thumb-size: calc(var(--six-selection-control-toggle-size) - 4px);\n --width: calc(var(--height) * 2);\n\n display: inline-block;\n}\n\n.switch {\n display: inline-flex;\n align-items: center;\n font-family: var(--six-font-family);\n font-size: var(--six-input-font-size-medium);\n font-weight: var(--six-input-font-weight);\n color: var(--six-input-color);\n vertical-align: middle;\n cursor: pointer;\n}\n\n.switch__control {\n position: relative;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: var(--width);\n height: var(--height);\n background-color: var(--six-selection-control-color-disabled);\n border-radius: var(--height);\n transition:\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) background-color;\n\n .switch__thumb {\n width: var(--thumb-size);\n height: var(--thumb-size);\n background-color: var(--six-input-background-color);\n border-radius: 50%;\n transform: translateX(calc(var(--width) / -2 + var(--thumb-size) / 2 - (var(--thumb-size) - var(--height)) / 2));\n transition:\n var(--six-transition-fast) transform ease,\n var(--six-transition-fast) background-color,\n var(--six-transition-fast) border-color,\n var(--six-transition-fast) box-shadow;\n }\n\n input[type='checkbox'] {\n position: absolute;\n opacity: 0;\n padding: 0;\n margin: 0;\n pointer-events: none;\n }\n}\n\n// Hover\n.switch:not(.switch--checked):not(.switch--disabled) .switch__control:hover {\n background-color: var(--six-input-border-color-hover);\n}\n\n// Checked\n.switch--checked .switch__control {\n background-color: var(--six-selection-control-color);\n\n .switch__thumb {\n background-color: var(--six-color-white);\n transform: translateX(calc(var(--width) / 2 - var(--thumb-size) / 2 + (var(--thumb-size) - var(--height)) / 2));\n }\n}\n\n// Checked + hover\n.switch.switch--checked:not(.switch--disabled) .switch__control:hover {\n background-color: var(--six-input-border-color-focus);\n}\n\n// Disabled\n.switch--disabled {\n cursor: not-allowed;\n color: var(--six-selection-control-color-disabled);\n\n .switch__control {\n background-color: var(--six-selection-control-color-disabled);\n }\n\n &.switch--checked .switch__control {\n background-color: var(--six-selection-control-color-disabled);\n }\n}\n\n.switch__label {\n line-height: var(--height);\n margin-left: 0.5em;\n user-select: none;\n}\n","import { Component, Element, Event, EventEmitter, h, Method, Prop, State, Watch } from '@stencil/core';\nimport { EmptyPayload } from '../../utils/types';\nimport { EventListeners } from '../../utils/event-listeners';\nimport FormControl from '../../functional-components/form-control/form-control';\nimport { hasSlot } from '../../utils/slot';\n\nlet id = 0;\n\n/**\n * @since 1.0\n * @status stable\n *\n * Forked from https://github.com/shoelace-style/shoelace version v2.0.0-beta27.\n *\n * @slot - The switch's label.\n * @slot error-text - Error text that is shown for validation errors. Alternatively, you can use the error-text prop.\n *\n * @part base - The component's base wrapper.\n * @part control - The switch control.\n * @part thumb - The switch position indicator.\n * @part label - The switch label.\n */\n\n@Component({\n tag: 'six-switch',\n styleUrl: 'six-switch.scss',\n shadow: true,\n})\nexport class SixSwitch {\n private switchId = `switch-${++id}`;\n private labelId = `switch-label-${id}`;\n private errorTextId = `input-error-text-${id}`;\n\n private inputElement?: HTMLInputElement;\n private eventListeners = new EventListeners();\n\n @Element() host!: HTMLSixSwitchElement;\n\n @State() hasFocus = false;\n @State() hasErrorTextSlot = false;\n\n /** The switch's name attribute. */\n @Prop() name = '';\n\n /** The switch's value attribute. */\n @Prop() value = 'on';\n\n /** Set to true to disable the switch. */\n @Prop() disabled = false;\n\n /** Set to true to show an asterisk beneath the label. */\n @Prop() required = false;\n\n /** Set to true to draw the switch in a checked state. */\n @Prop({ mutable: true, reflect: true }) checked = false;\n\n /** The label text. */\n @Prop() label = '';\n\n /** The error message shown, if `invalid` is set to true. */\n @Prop() errorText: string | string[] = '';\n\n /** The number of error texts to be shown (if the error-text slot isn't used). Defaults to 1 */\n @Prop() errorTextCount?: number;\n\n /** If this property is set to true and an error message is provided by `errorText`, the error message is displayed. */\n @Prop({ reflect: true }) invalid = false;\n\n componentWillLoad() {\n this.handleSlotChange();\n }\n\n @Watch('checked')\n handleCheckedChange() {\n if (this.inputElement != null) {\n this.inputElement.checked = this.checked;\n this.checked = this.inputElement.checked;\n }\n }\n\n /** Emitted when the control loses focus. */\n @Event({ eventName: 'six-switch-blur' }) sixBlur!: EventEmitter<boolean>;\n\n /** Emitted when the control's checked state changes. */\n @Event({ eventName: 'six-switch-change' }) sixChange!: EventEmitter<boolean>;\n\n /** Emitted when the control gains focus. */\n @Event({ eventName: 'six-switch-focus' }) sixFocus!: EventEmitter<EmptyPayload>;\n\n connectedCallback() {\n this.host.shadowRoot?.addEventListener('slotchange', this.handleSlotChange);\n this.eventListeners.forward('six-switch-change', 'change', this.host);\n this.eventListeners.forward('six-switch-blur', 'blur', this.host);\n this.eventListeners.forward('six-switch-focus', 'focus', this.host);\n }\n\n disconnectedCallback() {\n this.host.shadowRoot?.removeEventListener('slotchange', this.handleSlotChange);\n this.eventListeners.removeAll();\n }\n\n @Watch('errorText')\n @Watch('label')\n handleLabelChange() {\n this.handleSlotChange();\n }\n\n private handleSlotChange = () => {\n this.hasErrorTextSlot = hasSlot(this.host, 'error-text');\n };\n\n /** Sets focus on the switch. */\n @Method()\n async setFocus(options?: FocusOptions) {\n this.inputElement?.focus(options);\n }\n\n /** Removes focus from the switch. */\n @Method()\n async removeFocus() {\n this.inputElement?.blur();\n }\n\n private handleClick = () => {\n if (this.inputElement != null) {\n this.checked = this.inputElement.checked;\n this.sixChange.emit(this.checked);\n }\n };\n\n private handleBlur = () => {\n this.hasFocus = false;\n this.sixBlur.emit(this.checked);\n };\n\n private handleFocus = () => {\n this.hasFocus = true;\n this.sixFocus.emit();\n };\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'ArrowLeft') {\n event.preventDefault();\n this.checked = false;\n this.sixChange.emit(this.checked);\n }\n\n if (event.key === 'ArrowRight') {\n event.preventDefault();\n this.checked = true;\n this.sixChange.emit(this.checked);\n }\n };\n\n private handleMouseDown = (event: MouseEvent) => {\n // Prevent clicks on the label from briefly blurring the input\n event.preventDefault();\n this.inputElement?.focus();\n };\n\n render() {\n return (\n <FormControl\n inputId={this.switchId}\n label={this.label}\n labelId={this.labelId}\n hasLabelSlot={false}\n errorTextId={this.errorTextId}\n errorText={this.errorText}\n errorTextCount={this.errorTextCount}\n hasErrorTextSlot={this.hasErrorTextSlot}\n size=\"medium\"\n disabled={this.disabled}\n required={this.required}\n displayError={this.invalid}\n >\n <label\n part=\"base\"\n htmlFor={this.switchId}\n class={{\n switch: true,\n 'switch--checked': this.checked,\n 'switch--disabled': this.disabled,\n 'switch--focused': this.hasFocus,\n }}\n onMouseDown={this.handleMouseDown}\n >\n <span part=\"control\" class=\"switch__control\">\n <span part=\"thumb\" class=\"switch__thumb\" />\n\n <input\n ref={(el) => (this.inputElement = el)}\n id={this.switchId}\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n checked={this.checked}\n disabled={this.disabled}\n required={this.required}\n role=\"switch\"\n aria-checked={this.checked ? 'true' : 'false'}\n aria-labelledby={this.labelId}\n onClick={this.handleClick}\n onBlur={this.handleBlur}\n onFocus={this.handleFocus}\n onKeyDown={this.handleKeyDown}\n />\n </span>\n\n <span part=\"label\" id={this.labelId} class=\"switch__label\">\n <slot />\n </span>\n </label>\n </FormControl>\n );\n }\n}\n"],"names":[],"mappings":";;;;;AAAA,MAAM,YAAY,GAAG,wuJAAwuJ;;ACM7vJ,IAAI,EAAE,GAAG,CAAC;MAsBG,SAAS,GAAA,MAAA;AALtB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;AAMU,QAAA,IAAA,CAAA,QAAQ,GAAG,UAAU,EAAE,EAAE,EAAE;AAC3B,QAAA,IAAA,CAAA,OAAO,GAAG,CAAgB,aAAA,EAAA,EAAE,EAAE;AAC9B,QAAA,IAAA,CAAA,WAAW,GAAG,CAAoB,iBAAA,EAAA,EAAE,EAAE;AAGtC,QAAA,IAAA,CAAA,cAAc,GAAG,IAAI,cAAc,EAAE;AAIpC,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;AAChB,QAAA,IAAgB,CAAA,gBAAA,GAAG,KAAK;;AAGzB,QAAA,IAAI,CAAA,IA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,IAAI,CAAC,OAAO,EAAE,KAAK,EAAC,eAAe,EAAA,EACxD,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAQ,CACH,CACD,CACI;;;;;;;;;;;;;"}
@@ -15,7 +15,7 @@ const SixTabPanel = class {
15
15
  render() {
16
16
  return (
17
17
  // If the user didn't provide an ID, we'll set one, so we can link tabs and tab panels with aria labels
18
- h(Host, { key: '2a0ab4d655a8de97585c947099381c1fab61e858', id: this.host.id || this.componentId, style: { display: this.active ? 'block' : 'none' } }, h("div", { key: '7ee7661cd01b4390bea7981c4f3fad3e8bb0e6c0', part: "base", class: "tab-panel", role: "tabpanel", "aria-selected": this.active ? 'true' : 'false', "aria-hidden": this.active ? 'false' : 'true' }, h("slot", { key: '21c8561d0a126ef557c1fa9660209f10b6cd7936' }))));
18
+ h(Host, { key: 'b4c54fb42d68a3462abbd78dda16b1738e81dc57', id: this.host.id || this.componentId, style: { display: this.active ? 'block' : 'none' } }, h("div", { key: '734645855fb3a875a6a43e46383122ddad15bbb3', part: "base", class: "tab-panel", role: "tabpanel", "aria-selected": this.active ? 'true' : 'false', "aria-hidden": this.active ? 'false' : 'true' }, h("slot", { key: '1a789d112f5a048ac36f9a7e70208c99fb66c6c9' }))));
19
19
  }
20
20
  get host() { return getElement(this); }
21
21
  };
@@ -39,7 +39,7 @@ const SixTab = class {
39
39
  const placement = (_a = tabGroup === null || tabGroup === void 0 ? void 0 : tabGroup.placement) !== null && _a !== void 0 ? _a : 'top';
40
40
  return (
41
41
  // If the user didn't provide an ID, we'll set one, so we can link tabs and tab panels with aria labels
42
- h(Host, { key: '6b59af3a0794c9ea26b362fa1ea1c0d7513babea', id: this.host.id || this.componentId }, h("div", { key: '145b15cdb916d93ecb67a966fd558e37500db17c', part: "base", ref: (el) => (this.tab = el), class: {
42
+ h(Host, { key: '40b4042f28816b55ef585cf24570b64a44031863', id: this.host.id || this.componentId }, h("div", { key: 'e4e8ba43cf2e1384a421835fe1131ea411ac7a18', part: "base", ref: (el) => (this.tab = el), class: {
43
43
  tab: true,
44
44
  // Placements
45
45
  'tab--top': placement === 'top',
@@ -50,7 +50,7 @@ const SixTab = class {
50
50
  'tab--active': this.active,
51
51
  'tab--closable': this.closable,
52
52
  'tab--disabled': this.disabled,
53
- }, role: "tab", "aria-disabled": this.disabled ? 'true' : 'false', "aria-selected": this.active ? 'true' : 'false', tabindex: this.disabled || !this.active ? '-1' : '0', title: this.host.innerHTML }, h("slot", { key: '2a63428f882a98381746e578c98421cf7d065a16' }), this.closable && (h("six-icon-button", { key: 'dc0dbb47462d86dfae7b6806b667d6af69094f31', name: "close", size: "xSmall", exportparts: "base:close-button", class: "tab__close-button", onClick: this.handleCloseClick, tabIndex: -1, "aria-hidden": "true" }))), h("div", { key: '62bb67bb6a95d732e0961f349ada6f7d78a2e3a1', part: this.active ? 'active-tab-indicator' : '', class: {
53
+ }, role: "tab", "aria-disabled": this.disabled ? 'true' : 'false', "aria-selected": this.active ? 'true' : 'false', tabindex: this.disabled || !this.active ? '-1' : '0', title: this.host.innerHTML }, h("slot", { key: '39b1a75c51726543e0371e2607c6aa9197483b34' }), this.closable && (h("six-icon-button", { key: 'b9b2468f19b875ea58292f9ed330b49cff084d7c', name: "close", size: "xSmall", exportparts: "base:close-button", class: "tab__close-button", onClick: this.handleCloseClick, tabIndex: -1, "aria-hidden": "true" }))), h("div", { key: 'da5cf7175879826bfb96f52cd8aca427372e32e6', part: this.active ? 'active-tab-indicator' : '', class: {
54
54
  tab__indicator: true,
55
55
  'tab__indicator--active': this.active,
56
56
  // Placements
@@ -41,7 +41,7 @@ const SixTag = class {
41
41
  this.resizeObserver.disconnect();
42
42
  }
43
43
  render() {
44
- return (h("span", { key: '6d436b39d9a220ad7e764afb2a61db3c15052bd8', part: "base", class: {
44
+ return (h("span", { key: 'e8a2448511ebcfa91f9714c1e575679fca929310', part: "base", class: {
45
45
  tag: true,
46
46
  // Types
47
47
  'tag--primary': this.type === 'primary',
@@ -58,7 +58,7 @@ const SixTag = class {
58
58
  // Modifers
59
59
  'tag--pill': this.pill,
60
60
  'tag--clear': this.clearable,
61
- } }, h("six-tooltip", { key: '12faec51f7e0ac427c47037b815564ff6509fa5b', ref: (el) => (this.tooltipElement = el) }, h("span", { key: '38d9b9a805f423491334d8c91463ec7f5c4a5460', ref: (el) => (this.contentElement = el), part: "content", class: "tag__content" }, h("slot", { key: '1dce2aee10cb11b41ea4ff2a3691a7ed6050e3b9', ref: (el) => (this.contentSlotElement = el) }))), this.clearable && (h("six-icon-button", { key: 'd31750ec14c421b44ddc7a2f62db6dfd4ac19dd1', exportparts: "base:clear-button", size: "xSmall", name: "clear", class: "tag__clear", onClick: this.handleClearClick }))));
61
+ } }, h("six-tooltip", { key: 'a8bffabc14f61bff5f499cd9324cb17497a6082b', ref: (el) => (this.tooltipElement = el) }, h("span", { key: '28a60248833682018fa9f11be5d02372893645e5', ref: (el) => (this.contentElement = el), part: "content", class: "tag__content" }, h("slot", { key: 'd47d95687a69a4822575ac3219872a51f445441d', ref: (el) => (this.contentSlotElement = el) }))), this.clearable && (h("six-icon-button", { key: '477d12d125ff90d1cc0adb2bb62bf11bc6510927', exportparts: "base:clear-button", size: "xSmall", name: "clear", class: "tag__clear", onClick: this.handleClearClick }))));
62
62
  }
63
63
  };
64
64
  SixTag.style = sixTagCss;