@sellmate/design-system 0.0.24 → 0.0.26

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 (231) hide show
  1. package/dist/cjs/design-system.cjs.js +2 -2
  2. package/dist/cjs/{index-BjPOPvqs.js → index-DXo1Fhkn.js} +3 -3
  3. package/dist/cjs/index-DXo1Fhkn.js.map +1 -0
  4. package/dist/cjs/loader.cjs.js +2 -2
  5. package/dist/{esm/color-CgyTlXBV.js → cjs/resolveColor-DxvExwgo.js} +17 -4
  6. package/dist/{esm/resolveColor-CswQ9y2Q.js.map → cjs/resolveColor-DxvExwgo.js.map} +1 -1
  7. package/dist/cjs/sd-badge.cjs.entry.js +3 -4
  8. package/dist/cjs/sd-badge.entry.cjs.js.map +1 -1
  9. package/dist/cjs/sd-button.sd-checkbox.sd-guide.sd-icon.sd-input.sd-pagination.sd-portal.sd-select.sd-select-option.sd-table.sd-tooltip.sd-tooltip-portal.entry.cjs.js.map +1 -0
  10. package/dist/cjs/{sd-checkbox_9.cjs.entry.js → sd-button_12.cjs.entry.js} +739 -817
  11. package/dist/cjs/sd-card.cjs.entry.js +2 -2
  12. package/dist/cjs/sd-date-box.cjs.entry.js +1 -1
  13. package/dist/cjs/sd-date-picker.cjs.entry.js +3 -3
  14. package/dist/cjs/sd-date-range-picker.cjs.entry.js +3 -3
  15. package/dist/cjs/sd-popover.cjs.entry.js +4 -4
  16. package/dist/cjs/sd-select-multiple-group.cjs.entry.js +380 -0
  17. package/dist/cjs/sd-select-multiple-group.entry.cjs.js.map +1 -0
  18. package/dist/cjs/sd-select-multiple.cjs.entry.js +263 -0
  19. package/dist/cjs/sd-select-multiple.entry.cjs.js.map +1 -0
  20. package/dist/cjs/sd-select-option-group.cjs.entry.js +69 -0
  21. package/dist/cjs/sd-select-option-group.entry.cjs.js.map +1 -0
  22. package/dist/cjs/sd-tag.cjs.entry.js +2 -2
  23. package/dist/cjs/select-keyboard-navigation-6fO_V4En.js +119 -0
  24. package/dist/cjs/select-keyboard-navigation-6fO_V4En.js.map +1 -0
  25. package/dist/cjs/{tooltipArrow-qwvq153k.js → tooltipArrow-DNiGFQNW.js} +3 -3
  26. package/dist/cjs/{tooltipArrow-qwvq153k.js.map → tooltipArrow-DNiGFQNW.js.map} +1 -1
  27. package/dist/collection/components/sd-badge/sd-badge.js +1 -1
  28. package/dist/collection/components/sd-card/sd-card.js +1 -1
  29. package/dist/collection/components/sd-date-picker/sd-date-picker.js +2 -2
  30. package/dist/collection/components/sd-date-range-picker/sd-date-range-picker.js +2 -2
  31. package/dist/collection/components/sd-guide/sd-guide.css +6 -1
  32. package/dist/collection/components/sd-guide/sd-guide.js +4 -4
  33. package/dist/collection/components/sd-guide/sd-guide.js.map +1 -1
  34. package/dist/collection/components/sd-icon/sd-icon.js +1 -1
  35. package/dist/collection/components/sd-input/sd-input.js +2 -2
  36. package/dist/collection/components/sd-pagination/sd-pagination.js +2 -3
  37. package/dist/collection/components/sd-pagination/sd-pagination.js.map +1 -1
  38. package/dist/collection/components/sd-popover/sd-popover.js +2 -2
  39. package/dist/collection/components/sd-portal/sd-portal.js +25 -4
  40. package/dist/collection/components/sd-portal/sd-portal.js.map +1 -1
  41. package/dist/collection/components/sd-select/sd-select-option/sd-select-option.js +1 -1
  42. package/dist/collection/components/sd-select/sd-select.css +0 -6
  43. package/dist/collection/components/sd-select-multiple/sd-select-multiple.css +0 -6
  44. package/dist/collection/components/sd-select-multiple/sd-select-multiple.js +2 -2
  45. package/dist/collection/components/sd-select-multiple-group/sd-select-multiple-group.css +0 -6
  46. package/dist/collection/components/sd-select-multiple-group/sd-select-option-group/sd-select-option-group.js +3 -3
  47. package/dist/collection/components/sd-table/sd-table.css +7 -1316
  48. package/dist/collection/components/sd-table/sd-table.js +70 -5
  49. package/dist/collection/components/sd-table/sd-table.js.map +1 -1
  50. package/dist/collection/components/sd-tag/sd-tag.js +1 -1
  51. package/dist/collection/components/sd-tooltip/sd-tooltip.css +67 -1
  52. package/dist/collection/components/sd-tooltip/sd-tooltip.js +4 -5
  53. package/dist/collection/components/sd-tooltip/sd-tooltip.js.map +1 -1
  54. package/dist/collection/components/sd-tooltip-portal/sd-tooltip-portal.js +1 -1
  55. package/dist/components/index.js +1 -1
  56. package/dist/components/{p-Bl-wgv-z.js → p-B9QE7fbR.js} +6 -6
  57. package/dist/components/{p-Bl-wgv-z.js.map → p-B9QE7fbR.js.map} +1 -1
  58. package/dist/components/{p-CZG8wDBH.js → p-BWF8FOjZ.js} +4 -4
  59. package/dist/components/{p-CZG8wDBH.js.map → p-BWF8FOjZ.js.map} +1 -1
  60. package/dist/components/{p-Cxrr7vOk.js → p-BhRUodRD.js} +13 -14
  61. package/dist/components/p-BhRUodRD.js.map +1 -0
  62. package/dist/components/{p-nehvpX7w.js → p-BtS3tSh2.js} +4 -4
  63. package/dist/components/{p-nehvpX7w.js.map → p-BtS3tSh2.js.map} +1 -1
  64. package/dist/components/{p-DpiRZxT1.js → p-BttJlXkp.js} +6 -6
  65. package/dist/components/{p-DpiRZxT1.js.map → p-BttJlXkp.js.map} +1 -1
  66. package/dist/components/{p-Bfro0I6y.js → p-BvuTaRpn.js} +3 -3
  67. package/dist/components/{p-Bfro0I6y.js.map → p-BvuTaRpn.js.map} +1 -1
  68. package/dist/components/{p-DNUN6dGL.js → p-CMFEznYN.js} +7 -8
  69. package/dist/components/p-CMFEznYN.js.map +1 -0
  70. package/dist/components/{p-e74imoE0.js → p-Cafw-qR4.js} +3 -3
  71. package/dist/components/{p-e74imoE0.js.map → p-Cafw-qR4.js.map} +1 -1
  72. package/dist/components/{p-DzRr3BEe.js → p-CbnL1UUF.js} +3 -3
  73. package/dist/components/p-CbnL1UUF.js.map +1 -0
  74. package/dist/components/p-CkHD07WH.js +323 -0
  75. package/dist/components/p-CkHD07WH.js.map +1 -0
  76. package/dist/components/{p-BqIcTSCQ.js → p-Cs1Kf3Tx.js} +4 -4
  77. package/dist/components/{p-BqIcTSCQ.js.map → p-Cs1Kf3Tx.js.map} +1 -1
  78. package/dist/components/{p-aU8C4Pcb.js → p-DWYqZdbI.js} +8 -8
  79. package/dist/components/{p-aU8C4Pcb.js.map → p-DWYqZdbI.js.map} +1 -1
  80. package/dist/components/{p-CbTvFUCY.js → p-DtOWZESA.js} +28 -7
  81. package/dist/components/p-DtOWZESA.js.map +1 -0
  82. package/dist/components/{p-QBJzxOWs.js → p-hf6YF2Mx.js} +4 -4
  83. package/dist/components/{p-QBJzxOWs.js.map → p-hf6YF2Mx.js.map} +1 -1
  84. package/dist/components/{p-BvOGkIDI.js → p-wA4KCOG0.js} +3 -3
  85. package/dist/components/{p-BvOGkIDI.js.map → p-wA4KCOG0.js.map} +1 -1
  86. package/dist/components/sd-badge.js +2 -2
  87. package/dist/components/sd-button.js +1 -1
  88. package/dist/components/sd-card.js +2 -2
  89. package/dist/components/sd-checkbox.js +1 -1
  90. package/dist/components/sd-date-box.js +1 -1
  91. package/dist/components/sd-date-picker.js +7 -7
  92. package/dist/components/sd-date-range-picker.js +7 -7
  93. package/dist/components/sd-guide.js +9 -9
  94. package/dist/components/sd-guide.js.map +1 -1
  95. package/dist/components/sd-icon.js +1 -1
  96. package/dist/components/sd-input.js +1 -1
  97. package/dist/components/sd-pagination.js +1 -1
  98. package/dist/components/sd-popover.js +7 -7
  99. package/dist/components/sd-portal.js +1 -1
  100. package/dist/components/sd-select-multiple-group.js +8 -8
  101. package/dist/components/sd-select-multiple-group.js.map +1 -1
  102. package/dist/components/sd-select-multiple.js +10 -10
  103. package/dist/components/sd-select-multiple.js.map +1 -1
  104. package/dist/components/sd-select-option-group.js +1 -1
  105. package/dist/components/sd-select-option.js +1 -1
  106. package/dist/components/sd-select.js +1 -318
  107. package/dist/components/sd-select.js.map +1 -1
  108. package/dist/components/sd-table.js +64 -17
  109. package/dist/components/sd-table.js.map +1 -1
  110. package/dist/components/sd-tag.js +2 -2
  111. package/dist/components/sd-tooltip-portal.js +1 -1
  112. package/dist/components/sd-tooltip.js +1 -1
  113. package/dist/design-system/design-system.css +1 -1
  114. package/dist/design-system/design-system.esm.js +1 -1
  115. package/dist/design-system/p-054ae376.entry.js +2 -0
  116. package/dist/design-system/p-054ae376.entry.js.map +1 -0
  117. package/dist/design-system/{p-b537f724.entry.js → p-12134716.entry.js} +2 -2
  118. package/dist/design-system/p-12b6c1a5.entry.js +2 -0
  119. package/dist/design-system/p-12b6c1a5.entry.js.map +1 -0
  120. package/dist/design-system/p-3d9fccae.entry.js +2 -0
  121. package/dist/design-system/p-3d9fccae.entry.js.map +1 -0
  122. package/dist/design-system/{p-691dc436.entry.js → p-871c8d66.entry.js} +2 -2
  123. package/dist/design-system/p-9975f6f3.entry.js +2 -0
  124. package/dist/design-system/p-9975f6f3.entry.js.map +1 -0
  125. package/dist/design-system/{p-CqOU6L62.js → p-B2T3tS5r.js} +3 -3
  126. package/dist/design-system/p-B2T3tS5r.js.map +1 -0
  127. package/dist/design-system/p-BE6EMCXm.js +2 -0
  128. package/dist/design-system/{p-BUzABVug.js.map → p-BE6EMCXm.js.map} +1 -1
  129. package/dist/design-system/{p-CgyTlXBV.js → p-BYf-ybt2.js} +2 -2
  130. package/dist/design-system/{p-BoLmB6pG.js.map → p-BYf-ybt2.js.map} +1 -1
  131. package/dist/design-system/p-C2JaR3A6.js +2 -0
  132. package/dist/design-system/p-C2JaR3A6.js.map +1 -0
  133. package/dist/design-system/{p-2aef624e.entry.js → p-a7ab1b43.entry.js} +2 -2
  134. package/dist/design-system/p-af3a1dbb.entry.js +2 -0
  135. package/dist/design-system/p-d1aa75e7.entry.js +2 -0
  136. package/dist/design-system/p-e061c4f8.entry.js +2 -0
  137. package/dist/design-system/p-e061c4f8.entry.js.map +1 -0
  138. package/dist/design-system/{p-c4f5ed94.entry.js → p-e25d96e4.entry.js} +2 -2
  139. package/dist/design-system/sd-badge.entry.esm.js.map +1 -1
  140. package/dist/design-system/sd-button.sd-checkbox.sd-guide.sd-icon.sd-input.sd-pagination.sd-portal.sd-select.sd-select-option.sd-table.sd-tooltip.sd-tooltip-portal.entry.esm.js.map +1 -0
  141. package/dist/design-system/sd-select-multiple-group.entry.esm.js.map +1 -0
  142. package/dist/design-system/sd-select-multiple.entry.esm.js.map +1 -0
  143. package/dist/design-system/sd-select-option-group.entry.esm.js.map +1 -0
  144. package/dist/esm/design-system.js +3 -3
  145. package/dist/esm/{index-CqOU6L62.js → index-B2T3tS5r.js} +3 -3
  146. package/dist/esm/index-B2T3tS5r.js.map +1 -0
  147. package/dist/esm/loader.js +3 -3
  148. package/dist/{cjs/color-Oz29vj7L.js → esm/resolveColor-BYf-ybt2.js} +14 -6
  149. package/dist/{cjs/resolveColor-CauSLF0s.js.map → esm/resolveColor-BYf-ybt2.js.map} +1 -1
  150. package/dist/esm/sd-badge.entry.js +3 -4
  151. package/dist/esm/sd-badge.entry.js.map +1 -1
  152. package/dist/esm/sd-button.sd-checkbox.sd-guide.sd-icon.sd-input.sd-pagination.sd-portal.sd-select.sd-select-option.sd-table.sd-tooltip.sd-tooltip-portal.entry.js.map +1 -0
  153. package/dist/esm/{sd-checkbox_9.entry.js → sd-button_12.entry.js} +732 -813
  154. package/dist/esm/sd-card.entry.js +2 -2
  155. package/dist/esm/sd-date-box.entry.js +1 -1
  156. package/dist/esm/sd-date-picker.entry.js +3 -3
  157. package/dist/esm/sd-date-range-picker.entry.js +3 -3
  158. package/dist/esm/sd-popover.entry.js +4 -4
  159. package/dist/esm/sd-select-multiple-group.entry.js +378 -0
  160. package/dist/esm/sd-select-multiple-group.entry.js.map +1 -0
  161. package/dist/esm/sd-select-multiple.entry.js +261 -0
  162. package/dist/esm/sd-select-multiple.entry.js.map +1 -0
  163. package/dist/esm/sd-select-option-group.entry.js +67 -0
  164. package/dist/esm/sd-select-option-group.entry.js.map +1 -0
  165. package/dist/esm/sd-tag.entry.js +2 -2
  166. package/dist/esm/select-keyboard-navigation-C2JaR3A6.js +116 -0
  167. package/dist/esm/select-keyboard-navigation-C2JaR3A6.js.map +1 -0
  168. package/dist/esm/{tooltipArrow-hOEWkZyH.js → tooltipArrow-Pa2XQhpp.js} +3 -3
  169. package/dist/esm/{tooltipArrow-hOEWkZyH.js.map → tooltipArrow-Pa2XQhpp.js.map} +1 -1
  170. package/dist/types/components/sd-table/sd-table.d.ts +3 -0
  171. package/dist/types/components.d.ts +16 -0
  172. package/hydrate/index.js +90 -46
  173. package/hydrate/index.mjs +90 -46
  174. package/package.json +2 -2
  175. package/dist/cjs/color-Oz29vj7L.js.map +0 -1
  176. package/dist/cjs/index-BjPOPvqs.js.map +0 -1
  177. package/dist/cjs/resolveColor-CauSLF0s.js +0 -18
  178. package/dist/cjs/sd-button.sd-tooltip-portal.entry.cjs.js.map +0 -1
  179. package/dist/cjs/sd-button_2.cjs.entry.js +0 -221
  180. package/dist/cjs/sd-checkbox.sd-icon.sd-input.sd-portal.sd-select.sd-select-multiple.sd-select-multiple-group.sd-select-option.sd-select-option-group.entry.cjs.js.map +0 -1
  181. package/dist/cjs/sd-guide.cjs.entry.js +0 -84
  182. package/dist/cjs/sd-guide.entry.cjs.js.map +0 -1
  183. package/dist/cjs/sd-pagination.sd-tooltip.entry.cjs.js.map +0 -1
  184. package/dist/cjs/sd-pagination_2.cjs.entry.js +0 -168
  185. package/dist/cjs/sd-table.cjs.entry.js +0 -237
  186. package/dist/cjs/sd-table.entry.cjs.js.map +0 -1
  187. package/dist/components/p-CbTvFUCY.js.map +0 -1
  188. package/dist/components/p-Cxrr7vOk.js.map +0 -1
  189. package/dist/components/p-DNUN6dGL.js.map +0 -1
  190. package/dist/components/p-DzRr3BEe.js.map +0 -1
  191. package/dist/design-system/p-158f9392.entry.js +0 -2
  192. package/dist/design-system/p-158f9392.entry.js.map +0 -1
  193. package/dist/design-system/p-37042d15.entry.js +0 -2
  194. package/dist/design-system/p-37042d15.entry.js.map +0 -1
  195. package/dist/design-system/p-949de8eb.entry.js +0 -2
  196. package/dist/design-system/p-949de8eb.entry.js.map +0 -1
  197. package/dist/design-system/p-9f5eed30.entry.js +0 -2
  198. package/dist/design-system/p-BUzABVug.js +0 -2
  199. package/dist/design-system/p-BoLmB6pG.js +0 -2
  200. package/dist/design-system/p-CgyTlXBV.js.map +0 -1
  201. package/dist/design-system/p-CqOU6L62.js.map +0 -1
  202. package/dist/design-system/p-adee3154.entry.js +0 -2
  203. package/dist/design-system/p-adee3154.entry.js.map +0 -1
  204. package/dist/design-system/p-bda05b6f.entry.js +0 -2
  205. package/dist/design-system/p-bda05b6f.entry.js.map +0 -1
  206. package/dist/design-system/p-f015c024.entry.js +0 -2
  207. package/dist/design-system/p-f6a1ff99.entry.js +0 -2
  208. package/dist/design-system/p-f6a1ff99.entry.js.map +0 -1
  209. package/dist/design-system/sd-button.sd-tooltip-portal.entry.esm.js.map +0 -1
  210. package/dist/design-system/sd-checkbox.sd-icon.sd-input.sd-portal.sd-select.sd-select-multiple.sd-select-multiple-group.sd-select-option.sd-select-option-group.entry.esm.js.map +0 -1
  211. package/dist/design-system/sd-guide.entry.esm.js.map +0 -1
  212. package/dist/design-system/sd-pagination.sd-tooltip.entry.esm.js.map +0 -1
  213. package/dist/design-system/sd-table.entry.esm.js.map +0 -1
  214. package/dist/esm/color-CgyTlXBV.js.map +0 -1
  215. package/dist/esm/index-CqOU6L62.js.map +0 -1
  216. package/dist/esm/resolveColor-CswQ9y2Q.js +0 -16
  217. package/dist/esm/sd-button.sd-tooltip-portal.entry.js.map +0 -1
  218. package/dist/esm/sd-button_2.entry.js +0 -218
  219. package/dist/esm/sd-checkbox.sd-icon.sd-input.sd-portal.sd-select.sd-select-multiple.sd-select-multiple-group.sd-select-option.sd-select-option-group.entry.js.map +0 -1
  220. package/dist/esm/sd-guide.entry.js +0 -82
  221. package/dist/esm/sd-guide.entry.js.map +0 -1
  222. package/dist/esm/sd-pagination.sd-tooltip.entry.js.map +0 -1
  223. package/dist/esm/sd-pagination_2.entry.js +0 -165
  224. package/dist/esm/sd-table.entry.js +0 -235
  225. package/dist/esm/sd-table.entry.js.map +0 -1
  226. /package/dist/design-system/{p-b537f724.entry.js.map → p-12134716.entry.js.map} +0 -0
  227. /package/dist/design-system/{p-691dc436.entry.js.map → p-871c8d66.entry.js.map} +0 -0
  228. /package/dist/design-system/{p-2aef624e.entry.js.map → p-a7ab1b43.entry.js.map} +0 -0
  229. /package/dist/design-system/{p-f015c024.entry.js.map → p-af3a1dbb.entry.js.map} +0 -0
  230. /package/dist/design-system/{p-9f5eed30.entry.js.map → p-d1aa75e7.entry.js.map} +0 -0
  231. /package/dist/design-system/{p-c4f5ed94.entry.js.map → p-e25d96e4.entry.js.map} +0 -0
@@ -1,6 +1,67 @@
1
- import { r as registerInstance, c as createEvent, a as getElement, h, H as Host } from './index-CqOU6L62.js';
2
- import { r as resolveColor } from './resolveColor-CswQ9y2Q.js';
3
- import './color-CgyTlXBV.js';
1
+ import { r as registerInstance, c as createEvent, a as getElement, h, H as Host, F as Fragment } from './index-B2T3tS5r.js';
2
+ import { r as resolveColor, c as colors } from './resolveColor-BYf-ybt2.js';
3
+ import { B as BaseDropdownEvent, S as SelectKeyboardNavigation } from './select-keyboard-navigation-C2JaR3A6.js';
4
+ import { T as TooltipArrow } from './tooltipArrow-Pa2XQhpp.js';
5
+
6
+ const sdButtonCss = ".sd-button{text-decoration:none;cursor:pointer;border-radius:4px;transition:all 0.2s ease-in-out;position:relative;overflow:hidden;white-space:nowrap;-webkit-user-select:none;user-select:none;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center}.sd-button--xs{padding:0 8px;font-size:12px;font-weight:500;line-height:20px;min-height:24px}.sd-button--sm{padding:0 12px;font-size:12px;font-weight:500;line-height:20px;min-height:28px}.sd-button--md{padding:0 20px;font-size:16px;font-weight:500;line-height:26px;min-height:34px}.sd-button--lg{padding:0 28px;font-size:18px;font-weight:500;line-height:30px;min-height:62px}.sd-button--primary{background-color:var(--button-color);color:white;transition:filter 0.2s ease}.sd-button--primary::before{content:\"\";position:absolute;inset:0;background:#000000;opacity:0;transition:opacity 0.2s ease;z-index:0}.sd-button--primary:hover:not(.sd-button--disabled):not(.sd-button--loading)::before{opacity:0.25}.sd-button--outline{background:white;border:1px solid var(--button-color);color:var(--button-color)}.sd-button--outline::before{content:\"\";position:absolute;inset:0;background:var(--button-color);opacity:0;transition:opacity 0.2s ease;z-index:0}.sd-button--outline:hover:not(.sd-button--disabled):not(.sd-button--loading)::before{opacity:0.15}.sd-button--outline .sd-button__content{position:relative;z-index:1}.sd-button--ghost{background-color:transparent;color:var(--button-color);border-color:transparent}.sd-button--ghost::before{content:\"\";position:absolute;inset:0;background:var(--button-color);opacity:0;transition:opacity 0.2s ease;z-index:0}.sd-button--ghost:hover:not(.sd-button--disabled):not(.sd-button--loading)::before{opacity:0.15}.sd-button--ghost .sd-button__content{position:relative;z-index:1}.sd-button--disabled{border:1px solid #cccccc;background:#e1e1e1;color:#888888;cursor:not-allowed !important}.sd-button--icon-only{padding:0;width:fit-content;height:fit-content;aspect-ratio:1/1}.sd-button--no-hover:hover::before{opacity:0 !important}.sd-button .sd-button__content{display:inline-flex;align-items:center;justify-content:center;gap:4px;z-index:1;font-weight:500}";
7
+
8
+ const ICON_SIZES = {
9
+ xs: 12,
10
+ sm: 16,
11
+ md: 20,
12
+ lg: 24,
13
+ };
14
+ const SdButton = class {
15
+ constructor(hostRef) {
16
+ registerInstance(this, hostRef);
17
+ this.sdClick = createEvent(this, "sdClick");
18
+ }
19
+ get el() { return getElement(this); }
20
+ variant = 'primary';
21
+ size = 'sm';
22
+ color = '#025497';
23
+ label = '';
24
+ disabled = false;
25
+ type = 'button';
26
+ icon;
27
+ iconColor;
28
+ iconSize;
29
+ iconRight;
30
+ noHover = false;
31
+ class = '';
32
+ sdClick;
33
+ handleClick = (event) => {
34
+ if (this.disabled) {
35
+ event.preventDefault();
36
+ event.stopPropagation();
37
+ return;
38
+ }
39
+ this.sdClick.emit(event);
40
+ };
41
+ getButtonClasses() {
42
+ const classes = ['sd-button'];
43
+ classes.push(`sd-button--${this.variant}`);
44
+ classes.push(`sd-button--${this.size}`);
45
+ classes.push(`sd-button--color-${this.color}`);
46
+ if (this.disabled) {
47
+ classes.push('sd-button--disabled');
48
+ }
49
+ if (!this.label && (this.icon || this.iconRight)) {
50
+ classes.push('sd-button--icon-only');
51
+ }
52
+ if (this.noHover) {
53
+ classes.push('sd-button--no-hover');
54
+ }
55
+ return classes.join(' ');
56
+ }
57
+ render() {
58
+ const buttonClasses = this.getButtonClasses();
59
+ // 유틸로 색상 키 -> HEX 매핑 (없으면 원본 그대로)
60
+ const resolvedColor = resolveColor(this.color);
61
+ return (h(Host, { key: 'b30c8006e2f187fb971bcd47f8ce4a91d1dc47a6', style: { '--button-color': resolvedColor } }, h("button", { key: 'f494c93fc0b9d55537b468f5c6458569df962633', class: `${buttonClasses} ${this.class}`, type: this.type, disabled: this.disabled, onClick: this.handleClick }, h("div", { key: '7d64a6526baeac8569cccc60d9befacef3e3777d', class: "sd-button__content" }, this.icon && (h("sd-icon", { key: '9439e9456783aa5b057d383252a6b0c45a44b588', class: "sd-button__icon sd-button__icon--left", name: this.icon, size: this.iconSize ? this.iconSize : ICON_SIZES[this.size], color: this.iconColor ? this.iconColor : this.variant === 'primary' ? '#fff' : resolvedColor })), this.label && h("div", { key: '324371a6f8864c444cda39e7b349b4c9ec19b7f6', class: "sd-button__label" }, this.label), this.iconRight && (h("sd-icon", { key: '733790ceda6e1822c71911b17e66f527936b15a2', class: "sd-button__icon sd-button__icon--right", name: this.iconRight, size: ICON_SIZES[this.size], color: this.variant === 'primary' ? '#fff' : resolvedColor }))))));
62
+ }
63
+ };
64
+ SdButton.style = sdButtonCss;
4
65
 
5
66
  const sdCheckboxCss = "sd-checkbox{display:inline-block;height:20px;line-height:0}sd-checkbox .sd-checkbox{cursor:pointer;display:inline-flex;align-items:center;gap:8px;height:20px;max-height:20px}sd-checkbox .sd-checkbox>input{display:none}sd-checkbox .sd-checkbox:hover.sd-checkbox--checked .sd-checkbox__bg,sd-checkbox .sd-checkbox:hover.sd-checkbox--indeterminate .sd-checkbox__bg{border-color:#005cc9;background:#005cc9}sd-checkbox .sd-checkbox:hover.sd-checkbox--unchecked .sd-checkbox__bg{border:1px solid #0075ff;background:#d9eaff}sd-checkbox .sd-checkbox:hover.sd-checkbox--disabled .sd-checkbox__bg{border:1px solid transparent;background:#eeeeee}sd-checkbox .sd-checkbox__bg{width:16px;height:16px;border-radius:2px;border:1px solid #888888;box-sizing:border-box;display:inline-flex;justify-content:center;align-items:center;overflow:hidden;line-height:0}sd-checkbox .sd-checkbox__label{font-size:12px;color:#333333;line-height:20px}sd-checkbox .sd-checkbox--checked.sd-checkbox--disabled .sd-checkbox__bg,sd-checkbox .sd-checkbox--indeterminate.sd-checkbox--disabled .sd-checkbox__bg{background:#eeeeee;border:1px solid #cccccc !important}sd-checkbox .sd-checkbox--checked .sd-checkbox__bg,sd-checkbox .sd-checkbox--indeterminate .sd-checkbox__bg{border:1px solid #0075ff;background:#0075ff}sd-checkbox .sd-checkbox--unchecked .sd-checkbox__bg{background:white}sd-checkbox .sd-checkbox--disabled{cursor:not-allowed}sd-checkbox .sd-checkbox--disabled .sd-checkbox__bg{background:#eeeeee;border:1px solid #cccccc !important}";
6
67
 
@@ -84,6 +145,83 @@ const SdCheckbox = class {
84
145
  };
85
146
  SdCheckbox.style = sdCheckboxCss;
86
147
 
148
+ const sdGuideCss = "@charset \"UTF-8\";.sd-button{text-decoration:none;cursor:pointer;border-radius:4px;transition:all 0.2s ease-in-out;position:relative;overflow:hidden;white-space:nowrap;-webkit-user-select:none;user-select:none;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center}.sd-button--xs{padding:0 8px;font-size:12px;font-weight:500;line-height:20px;min-height:24px}.sd-button--sm{padding:0 12px;font-size:12px;font-weight:500;line-height:20px;min-height:28px}.sd-button--md{padding:0 20px;font-size:16px;font-weight:500;line-height:26px;min-height:34px}.sd-button--lg{padding:0 28px;font-size:18px;font-weight:500;line-height:30px;min-height:62px}.sd-button--primary{background-color:var(--button-color);color:white;transition:filter 0.2s ease}.sd-button--primary::before{content:\"\";position:absolute;inset:0;background:#000000;opacity:0;transition:opacity 0.2s ease;z-index:0}.sd-button--primary:hover:not(.sd-button--disabled):not(.sd-button--loading)::before{opacity:0.25}.sd-button--outline{background:white;border:1px solid var(--button-color);color:var(--button-color)}.sd-button--outline::before{content:\"\";position:absolute;inset:0;background:var(--button-color);opacity:0;transition:opacity 0.2s ease;z-index:0}.sd-button--outline:hover:not(.sd-button--disabled):not(.sd-button--loading)::before{opacity:0.15}.sd-button--outline .sd-button__content{position:relative;z-index:1}.sd-button--ghost{background-color:transparent;color:var(--button-color);border-color:transparent}.sd-button--ghost::before{content:\"\";position:absolute;inset:0;background:var(--button-color);opacity:0;transition:opacity 0.2s ease;z-index:0}.sd-button--ghost:hover:not(.sd-button--disabled):not(.sd-button--loading)::before{opacity:0.15}.sd-button--ghost .sd-button__content{position:relative;z-index:1}.sd-button--disabled{border:1px solid #cccccc;background:#e1e1e1;color:#888888;cursor:not-allowed !important}.sd-button--icon-only{padding:0;width:fit-content;height:fit-content;aspect-ratio:1/1}.sd-button--no-hover:hover::before{opacity:0 !important}.sd-button .sd-button__content{display:inline-flex;align-items:center;justify-content:center;gap:4px;z-index:1;font-weight:500}sd-guide{display:inline-block;height:fit-content}sd-guide .sd-guide{display:inline-block}sd-guide .sd-guide .sd-button{padding:0 16px 0 12px;border-radius:16px;color:#333333 !important;display:flex;align-items:center;transition:none}sd-guide .sd-guide .sd-button .sd-button__content{color:#333333 !important}sd-guide .sd-guide .sd-button .sd-button__content .sd-button__label{color:#333333 !important;margin-left:4px}sd-guide .sd-guide--active .sd-button{border:1px solid #12b553}sd-guide .sd-guide--active .sd-button .sd-button__content .sd-button__label{color:white !important}.sd-guide__popup{position:relative;padding:20px 32px;border-radius:8px;box-shadow:4px 4px 24px 4px rgba(0, 0, 0, 0.1);background:white}.sd-guide__popup>.sd-guide__popup__close{position:absolute;top:12px;right:12px}.sd-guide__popup__header{display:flex;align-items:center;gap:8px;margin-bottom:12px}.sd-guide__popup__header .sd-guide__popup__title{margin-top:0;font-size:16px;font-weight:700;line-height:26px;color:#333333}.sd-guide__popup__list{width:100%;padding:0;margin:0}.sd-guide__popup__list__item{display:flex;width:100%;align-items:start;list-style:none;color:#333333;font-size:12px;font-weight:400}.sd-guide__popup__list__item p{width:100%;padding:0;margin:0;word-wrap:break-word;word-break:break-word;white-space:normal;overflow-wrap:break-word;min-width:0}.sd-guide__popup__list__item::before{display:block;content:\"-\";width:6px;color:#333333;font-size:12px;font-weight:400;margin-left:10px;margin-right:12px;flex-shrink:0}.sd-guide__popup__list__item--depth-2::before{content:\"•\"}.sd-guide__popup__list__item--depth-2{padding-left:26px}";
149
+
150
+ const GUIDE_LABEL = {
151
+ help: '활용 TIP',
152
+ pdf: 'PDF Guide',
153
+ youtube: 'Video Guide',
154
+ notion: '사용 가이드',
155
+ event: 'Event Button',
156
+ };
157
+ const GUIDE_ICON = {
158
+ help: {
159
+ name: 'helpOutline',
160
+ size: 20,
161
+ color: colors.green_70,
162
+ },
163
+ pdf: { name: 'pdf', size: 20, color: colors.red_75 },
164
+ youtube: { name: 'youtube', size: 20, color: colors.red_75 },
165
+ notion: { name: 'notion', size: 16, color: colors.black },
166
+ event: { name: 'event', size: 16, color: colors.brilliantblue_70 },
167
+ };
168
+ const SdGuide = class {
169
+ constructor(hostRef) {
170
+ registerInstance(this, hostRef);
171
+ }
172
+ get el() { return getElement(this); }
173
+ type = 'help';
174
+ label = '';
175
+ message = '';
176
+ guideUrl = '';
177
+ popupWidth;
178
+ popupShow = false;
179
+ guideRef;
180
+ handleClickGuide = () => {
181
+ if (this.type === 'help') {
182
+ this.popupShow = !this.popupShow;
183
+ return;
184
+ }
185
+ if (this.guideUrl) {
186
+ window.open(this.guideUrl, '_blank');
187
+ }
188
+ };
189
+ get guideClass() {
190
+ const classes = ['sd-guide', `sd-guide--${this.type}`];
191
+ if (this.popupShow)
192
+ classes.push('sd-guide--active');
193
+ return classes.join(' ');
194
+ }
195
+ closeDropdown = () => {
196
+ this.popupShow = false;
197
+ };
198
+ render() {
199
+ const { name: iconName, size: iconSize, color: iconColor } = GUIDE_ICON[this.type];
200
+ return (h(Host, { key: '1365e7c6c52a218e419f94dc741a70e74b954bc6', style: {
201
+ '--sd-guide-color': GUIDE_ICON[this.type].color,
202
+ } }, h("sd-button", { key: '23cab4f2354f889012d0eb39ff04daf5a469c24a', ref: el => (this.guideRef = el), class: this.guideClass, variant: this.popupShow ? 'primary' : 'outline', label: GUIDE_LABEL[this.type], size: "sm", color: this.popupShow ? GUIDE_ICON[this.type].color : 'grey_45', icon: iconName, iconColor: this.popupShow ? 'white' : iconColor, iconSize: iconSize, noHover: this.popupShow, onSdClick: this.handleClickGuide }), this.type === 'help' && this.popupShow && (h("sd-portal", { key: '7d9c7a40a1f1d0a49388b207882ebe3510a0797c', open: this.popupShow, parentRef: this.guideRef, onSdClose: this.closeDropdown, offset: [0, 4] }, h("div", { key: '4e61879615a5e4466cc572df02b571b4bbf6b604', class: "sd-guide__popup", style: { width: this.popupWidth ? this.popupWidth + 'px' : '426px' } }, h("sd-button", { key: 'e365cd7b185f194871d5780b892683b84a1f97c5', class: "sd-guide__popup__close", icon: "close", color: colors.grey_65, size: "md", variant: "ghost", noHover: true,
203
+ // buttonStyle={{ padding: '0px', minHeight: '0px' }}
204
+ onSdClick: this.closeDropdown }), h("div", { key: '1198a0d6a84321395501a7afe9f003c627c1c2bc', class: "sd-guide__popup__header" }, h("sd-icon", { key: 'b4aee8ab7a237c9ae6475291cd5c51997b8505e9', name: "helpOutline", size: 24, color: colors.green_65 }), h("h3", { key: '9bc0f5ef484f950d6659c9bc8a27ce42bc315048', class: "sd-guide__popup__title" }, this.label || GUIDE_LABEL[this.type])), h("ul", { key: 'bb2d3ec6369dd464410771af81343735963b4a9c', class: "sd-guide__popup__list" }, this.renderListItem(this.message)))))));
205
+ }
206
+ // 현재 2depth까지만 스타일 적용
207
+ renderListItem(message, depth = 0) {
208
+ const listItems = [];
209
+ if (Array.isArray(message)) {
210
+ const depthMsg = message.map(msg => this.renderListItem(msg, depth + 1));
211
+ listItems.push(...depthMsg.flat());
212
+ }
213
+ else {
214
+ listItems.push(this.renderLi(message, depth));
215
+ }
216
+ return listItems;
217
+ }
218
+ renderLi = (message, depth) => {
219
+ const listContent = message.replace(/ /gi, ' ');
220
+ return (h("li", { class: `sd-guide__popup__list__item sd-guide__popup__list__item--depth-${depth}` }, h("p", { innerHTML: listContent })));
221
+ };
222
+ };
223
+ SdGuide.style = sdGuideCss;
224
+
87
225
  const Check12 = (props) => {
88
226
  return (h("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props }, h("g", { "clip-path": "url(#clip0_8697_9693)" }, h("path", { d: "M10.5962 3.19745L5.02773 8.76591C4.97891 8.81473 4.89977 8.81473 4.85095 8.76591L1.40381 5.31877", stroke: "currentColor", "stroke-width": "0.75", "stroke-linecap": "round" })), h("defs", null, h("clipPath", { id: "clip0_8697_9693" }, h("rect", { width: "12", height: "12", fill: "none" })))));
89
227
  };
@@ -445,7 +583,7 @@ const SdIcon = class {
445
583
  }
446
584
  render() {
447
585
  const IconComponent = Icons[this.name]?.[this.size];
448
- return (h("i", { key: '20f187a90566d35f7c459480b6917061cd26c734', class: this.getIconClasses(), style: this.iconStyle }, h(IconComponent, { key: '9db914748d948a695b248d04e5008e726ac6e4d2', color: this.resolvedColor })));
586
+ return (h("i", { key: 'c0d4a3993efc47345406ba9b30e49cefaa14f8da', class: this.getIconClasses(), style: this.iconStyle }, h(IconComponent, { key: '47476081ac11dd8ef1b04d9372d05f4afe72b323', color: this.resolvedColor })));
449
587
  }
450
588
  };
451
589
  SdIcon.style = sdIconCss;
@@ -550,11 +688,11 @@ const SdInput = class {
550
688
  '--input-width': typeof this.width === 'number' ? `${this.width}px` : this.width,
551
689
  }
552
690
  : {};
553
- return (h(Host, { key: '099f819c08b8eb4627f7857d10877d2a9bbeac51', style: inputWidth }, this.label && h("div", { key: 'ef1dffa2707e2f2844efee6646e14b750ea7c319', class: "sd-input__label" }, this.label), h("label", { key: '89e8a0ea5a02ecd114b9e1a7cb9fdcdce0130849', class: {
691
+ return (h(Host, { key: '9a0b975f20b4b8bbc8bff2aef4ee9036450921d4', style: inputWidth }, this.label && h("div", { key: 'ec6c840dcdaa7b9788c32ecbd03dc5daee74c748', class: "sd-input__label" }, this.label), h("label", { key: '4c11c34fd26897b50e0cfbb569de476c9e06884c', class: {
554
692
  'sd-input': true,
555
693
  [this.getInputStatus()]: true,
556
694
  'sd-input--barcode': !!this.barcode,
557
- }, onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: this.inputStyle }, h("slot", { key: 'b1c64655ea940ae454bac4aed58df8944ed579a3', name: "prefix" }), h("input", { key: '1bb32efb0c46d3e1b91ac90c64e60943ac59ee41', ref: el => (this.nativeEl = el), class: `sd-input__native_element ${this.inputClass}`, type: "text", value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, onInput: this.handleInput, onChange: this.handleChange, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event) }), h("slot", { key: 'bcdc6e6780b6eba56e788665669abcfe04406e64', name: "suffix" }), this.clearable && this.internalValue && (h("sd-icon", { key: '3f8d9fe950d5313f0df807b06ffd5872dc4b1835', name: "close", color: "#888", class: "sd-input__clear-icon", onClick: () => {
695
+ }, onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: this.inputStyle }, h("slot", { key: '0d7df02ed548b12f415bd72f84ea411fde5ef549', name: "prefix" }), h("input", { key: '6203dcb95fd486d263e0fe33495243e95c332e1a', ref: el => (this.nativeEl = el), class: `sd-input__native_element ${this.inputClass}`, type: "text", value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, onInput: this.handleInput, onChange: this.handleChange, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event) }), h("slot", { key: '21544173b390be5607c50faf84f1d47fa703e8bf', name: "suffix" }), this.clearable && this.internalValue && (h("sd-icon", { key: 'af486def3d146c4638d1f6fecf95a6de61e8d528', name: "close", color: "#888", class: "sd-input__clear-icon", onClick: () => {
558
696
  this.internalValue = '';
559
697
  this.sdChange?.emit(this.internalValue);
560
698
  this.sdInput?.emit(this.internalValue);
@@ -567,6 +705,100 @@ const SdInput = class {
567
705
  };
568
706
  SdInput.style = sdInputCss;
569
707
 
708
+ const sdPaginationCss = ".sd-pagination{display:flex;flex-flow:row nowrap;align-items:center;justify-content:center;gap:8px;color:#555555;width:100%;font-size:12px}.sd-pagination .prepend-btns{display:flex;flex-flow:row nowrap;align-items:center;gap:8px;width:60px}.sd-pagination .prepend-btns button{width:26px;height:26px;border:0;background:none}.sd-pagination .prepend-btns button:hover{border:1px solid #006ac1;border-radius:14px}.sd-pagination .append-btns{display:flex;flex-flow:row nowrap;align-items:center;gap:8px;width:60px}.sd-pagination .append-btns button{width:26px;height:26px;border:0;background:none}.sd-pagination .append-btns button:hover{border:1px solid #006ac1;border-radius:14px}.sd-pagination .pagination-btn{display:flex;align-items:center;justify-content:center;border-radius:14px;outline:none;border:none;cursor:pointer;height:26px;color:#555555;width:var(--pagination-btn-width, 26px)}.sd-pagination .pagination-btn--selected{background-color:#006ac1;color:white}.sd-pagination .pagination-btn:hover{border:1px solid #006ac1}.sd-pagination--simple .pagination-info{line-height:26px;display:flex;flex-flow:row nowrap;align-items:center;gap:8px}.sd-pagination--simple .pagination-info .current-page,.sd-pagination--simple .pagination-info .last-page{padding:0 2px}";
709
+
710
+ const BUTTON_WIDTH = {
711
+ 1: 26,
712
+ 2: 36,
713
+ 3: 42,
714
+ 4: 50,
715
+ 5: 58,
716
+ };
717
+ const PER_PAGE = 10;
718
+ const SdPagination = class {
719
+ constructor(hostRef) {
720
+ registerInstance(this, hostRef);
721
+ this.pageChange = createEvent(this, "pageChange");
722
+ }
723
+ currentPage = 1;
724
+ lastPage = 1;
725
+ simple = false;
726
+ pageChange;
727
+ onPropChange() {
728
+ console.log('Pagination props changed', {
729
+ currentPage: this.currentPage,
730
+ lastPage: this.lastPage,
731
+ });
732
+ }
733
+ get paginationClasses() {
734
+ const classes = ['sd-pagination'];
735
+ if (this.simple) {
736
+ classes.push('sd-pagination--simple');
737
+ }
738
+ return classes.join(' ');
739
+ }
740
+ get pageNumbers() {
741
+ const start = Math.floor((this.currentPage - 1) / PER_PAGE) * PER_PAGE + 1;
742
+ const end = Math.min(start + PER_PAGE - 1, this.lastPage);
743
+ return Array.from({ length: end - start + 1 }, (_, i) => start + i);
744
+ }
745
+ get buttonWidth() {
746
+ const lastPageNum = this.pageNumbers.at(-1) ?? 1;
747
+ const maxPageLength = lastPageNum.toString().length;
748
+ return BUTTON_WIDTH[maxPageLength] || BUTTON_WIDTH[1];
749
+ }
750
+ handlePageChange(page) {
751
+ if (page < 1 || page > this.lastPage)
752
+ return;
753
+ this.pageChange.emit(page);
754
+ }
755
+ handleGroupChange(direction) {
756
+ const delta = direction === 'forward' ? PER_PAGE : -10;
757
+ const newPage = Math.min(Math.max(this.currentPage + delta, 1), this.lastPage);
758
+ this.handlePageChange(newPage);
759
+ }
760
+ get isFirstGroup() {
761
+ return this.currentPage <= PER_PAGE;
762
+ }
763
+ get isLastGroup() {
764
+ const startPageGroup = Math.floor((this.currentPage - 1) / PER_PAGE) * PER_PAGE + 1;
765
+ return startPageGroup + PER_PAGE - 1 >= this.lastPage;
766
+ }
767
+ renderPrevButtons() {
768
+ if (this.simple) {
769
+ if (this.currentPage <= 1)
770
+ return null;
771
+ return (h(Fragment, null, h("button", { "aria-label": "Go to first page", onClick: () => this.handlePageChange(1) }, h("sd-icon", { name: "arrowLeftEnd", size: "12", color: "#222222" })), h("button", { "aria-label": "Go to previous page", onClick: () => this.handlePageChange(this.currentPage - 1) }, h("sd-icon", { name: "arrowLeft", size: "12", color: "#222222" }))));
772
+ }
773
+ if (!this.isFirstGroup) {
774
+ return (h(Fragment, null, h("button", { "aria-label": "Go to first page", onClick: () => this.handlePageChange(1) }, h("sd-icon", { name: "arrowLeftEnd", size: "12", color: "#222222" })), h("button", { "aria-label": "Go to previous page group", onClick: () => this.handleGroupChange('backward') }, h("sd-icon", { name: "arrowLeft", size: "12", color: "#222222" }))));
775
+ }
776
+ }
777
+ renderNextButtons() {
778
+ if (this.simple) {
779
+ if (this.currentPage >= this.lastPage)
780
+ return null;
781
+ return (h(Fragment, null, h("button", { "aria-label": "Go to next page", onClick: () => this.handlePageChange(this.currentPage + 1) }, h("sd-icon", { name: "arrowRight", size: "12", color: "#222222" })), h("button", { "aria-label": "Go to last page", onClick: () => this.handlePageChange(this.lastPage) }, h("sd-icon", { name: "arrowRightEnd", size: "12", color: "#222222" }))));
782
+ }
783
+ if (!this.isLastGroup) {
784
+ return (h(Fragment, null, h("button", { "aria-label": "Go to next page group", onClick: () => this.handleGroupChange('forward') }, h("sd-icon", { name: "arrowRight", size: "12", color: "#222222" })), h("button", { "aria-label": "Go to last page", onClick: () => this.handlePageChange(this.lastPage) }, h("sd-icon", { name: "arrowRightEnd", size: "12", color: "#222222" }))));
785
+ }
786
+ }
787
+ render() {
788
+ return (h("div", { key: '2707331958e2c375b570590a8742655bacb1aa4d', class: this.paginationClasses }, h("div", { key: 'e98573b80c04454ea0b30f6cb7fe1974028a0464', class: "prepend-btns" }, this.renderPrevButtons()), this.simple ? (h("div", { class: "pagination-info" }, h("span", { class: "current-page" }, this.currentPage), h("span", null, "/"), h("span", { class: "last-page" }, this.lastPage))) : (this.pageNumbers.map(n => (h("button", { type: "button", "aria-current": this.currentPage === n ? 'page' : undefined, class: {
789
+ 'pagination-btn': true,
790
+ 'pagination-btn--selected': this.currentPage === n,
791
+ }, disabled: this.currentPage === n, style: {
792
+ '--pagination-btn-width': `${this.buttonWidth}px`,
793
+ }, onClick: () => this.handlePageChange(n) }, n)))), h("div", { key: 'ccb867eccaece5ecbdcef7abe0e4d333fb169d11', class: "append-btns" }, this.renderNextButtons())));
794
+ }
795
+ static get watchers() { return {
796
+ "currentPage": ["onPropChange"],
797
+ "lastPage": ["onPropChange"]
798
+ }; }
799
+ };
800
+ SdPagination.style = sdPaginationCss;
801
+
570
802
  const SdPortal = class {
571
803
  constructor(hostRef) {
572
804
  registerInstance(this, hostRef);
@@ -629,9 +861,30 @@ const SdPortal = class {
629
861
  this.rafId = requestAnimationFrame(() => {
630
862
  if (!this.parentRef || !this.wrapper)
631
863
  return;
632
- const rect = this.parentRef.getBoundingClientRect();
633
- this.wrapper.style.top = `${rect.bottom + window.scrollY + this.offset[1]}px`;
634
- this.wrapper.style.left = `${rect.left + window.scrollX + this.offset[0]}px`;
864
+ const parentRect = this.parentRef.getBoundingClientRect();
865
+ const wrapperRect = this.wrapper.getBoundingClientRect();
866
+ const viewport = {
867
+ width: window.innerWidth,
868
+ height: window.innerHeight,
869
+ };
870
+ let top = parentRect.bottom + window.scrollY + this.offset[1];
871
+ let left = parentRect.left + window.scrollX + this.offset[0];
872
+ // 화면 상하단 넘어갈 시 반전
873
+ if (parentRect.bottom + wrapperRect.height + this.offset[1] > viewport.height) {
874
+ top = parentRect.top + window.scrollY - wrapperRect.height - this.offset[1];
875
+ }
876
+ if (top < window.scrollY) {
877
+ top = parentRect.bottom + window.scrollY + this.offset[1];
878
+ }
879
+ // 화면 좌우측 넘어갈 시 반전
880
+ if (parentRect.left + wrapperRect.width + this.offset[0] > viewport.width) {
881
+ left = parentRect.right + window.scrollX - wrapperRect.width - this.offset[0];
882
+ }
883
+ if (left < 0) {
884
+ left = this.offset[0];
885
+ }
886
+ this.wrapper.style.top = `${top}px`;
887
+ this.wrapper.style.left = `${left}px`;
635
888
  });
636
889
  }
637
890
  // parentRef의 이동 / 크기변경 감지
@@ -664,123 +917,11 @@ const SdPortal = class {
664
917
  this.sdClose.emit();
665
918
  }
666
919
  render() {
667
- return h("slot", { key: '9ccb84d877ac49b85e64a12c1f1ff4b3105b2213' });
920
+ return h("slot", { key: '4f344b083ff3a2d32d1a23f99e90687aeeb676b1' });
668
921
  }
669
922
  };
670
923
 
671
- class DropdownManager {
672
- static instance;
673
- activeDropdowns = new Set();
674
- static getInstance() {
675
- if (!DropdownManager.instance) {
676
- DropdownManager.instance = new DropdownManager();
677
- }
678
- return DropdownManager.instance;
679
- }
680
- register(component) {
681
- this.activeDropdowns.add(component);
682
- }
683
- unregister(component) {
684
- this.activeDropdowns.delete(component);
685
- }
686
- openDropdown(targetComponent) {
687
- // 다른 모든 드롭다운 닫기
688
- this.activeDropdowns.forEach(component => {
689
- if (component !== targetComponent && component.isOpen) {
690
- component.closeDropdown();
691
- }
692
- });
693
- }
694
- closeAllDropdowns() {
695
- this.activeDropdowns.forEach(component => {
696
- if (component.isOpen) {
697
- component.closeDropdown();
698
- }
699
- });
700
- }
701
- }
702
- const dropdownManager = DropdownManager.getInstance();
703
-
704
- // 여러 select를 동시에 사용할때에 이벤트 리스너의 등록이 충돌나는 문제를 해결하기 위한 Base class
705
- // 각 드롭다운 컴포넌트는 이 클래스를 상속 및 구현 필요
706
- // 기본적으로 click, keydown 추상 이벤트를 구현해야하고
707
- // isOpen가 true일때에만 이벤트 등록 그외에는 이벤트 클리닝을 수행
708
- // 추후 필요한 이벤트는 이곳에 추가하여 추가 구현 후 사용
709
- // 별도로 드롭다운 전용의 Base class가 아닌 공통적으로 사용할 수 있는 Base class가 필요할지 검토 필요
710
- class BaseDropdownEvent {
711
- documentClickHandler;
712
- documentKeydownHandler;
713
- // 컴포넌트 생명주기에서 호출할 메서드들
714
- initializeEvent() {
715
- dropdownManager.register(this);
716
- this.initializeEventHandlers();
717
- }
718
- cleanupEvent() {
719
- dropdownManager.unregister(this);
720
- this.cleanup();
721
- }
722
- initializeEventHandlers() {
723
- this.documentClickHandler = (event) => this.handleDocumentClick(event);
724
- this.documentKeydownHandler = (event) => this.handleDocumentKeydown(event);
725
- }
726
- addGlobalEventListeners() {
727
- if (this.documentClickHandler) {
728
- document.addEventListener('click', this.documentClickHandler);
729
- }
730
- if (this.documentKeydownHandler) {
731
- document.addEventListener('keydown', this.documentKeydownHandler);
732
- }
733
- }
734
- removeGlobalEventListeners() {
735
- if (this.documentClickHandler) {
736
- document.removeEventListener('click', this.documentClickHandler);
737
- }
738
- if (this.documentKeydownHandler) {
739
- document.removeEventListener('keydown', this.documentKeydownHandler);
740
- }
741
- }
742
- onDropdownToggle(isOpen) {
743
- if (isOpen && !this.disabled) {
744
- dropdownManager.openDropdown(this);
745
- this.addGlobalEventListeners();
746
- }
747
- else {
748
- this.removeGlobalEventListeners();
749
- }
750
- }
751
- cleanup() {
752
- this.removeGlobalEventListeners();
753
- }
754
- closeDropdown() {
755
- this.isOpen = false;
756
- }
757
- }
758
-
759
- class SelectKeyboardNavigation {
760
- isSearchable;
761
- filteredOptions;
762
- constructor(isSearchable, filteredOptions) {
763
- this.isSearchable = isSearchable;
764
- this.filteredOptions = filteredOptions;
765
- }
766
- getNavigationBounds() {
767
- return {
768
- minIndex: this.isSearchable ? -1 : 0,
769
- maxIndex: this.filteredOptions.length - 1,
770
- };
771
- }
772
- getNextIndex(currentIndex, direction) {
773
- const { minIndex, maxIndex } = this.getNavigationBounds();
774
- if (direction === 'ArrowUp') {
775
- return currentIndex > minIndex ? currentIndex - 1 : maxIndex;
776
- }
777
- else {
778
- return currentIndex < maxIndex ? currentIndex + 1 : minIndex;
779
- }
780
- }
781
- }
782
-
783
- const sdSelectCss = ".sd-select__dropdown{overflow-y:auto;overflow-x:hidden;scroll-behavior:smooth}.sd-select__dropdown::-webkit-scrollbar{opacity:0;background:#e5e5e5}.sd-select__dropdown::-webkit-scrollbar:horizontal{height:8px}.sd-select__dropdown::-webkit-scrollbar:vertical{width:8px}.sd-select__dropdown::-webkit-scrollbar-thumb{height:80px;background-color:#cccccc;border-radius:4px}.sd-select__dropdown::-webkit-scrollbar-thumb:hover{background:#e5e5e5}.sd-select__dropdown::-webkit-scrollbar-thumb:active{background:#e5e5e5}.sd-select__dropdown::-webkit-scrollbar-track{background-color:transparent}.sd-select{display:flex;width:var(--select-width, 200px);height:28px;position:relative;color:#333333;cursor:pointer;user-select:none;border:1px solid #aaaaaa;border-radius:4px;background-color:white}.sd-select:hover:not(.sd-select--disabled){background:#f6f6f6}.sd-select.sd-select--disabled{cursor:not-allowed;background-color:#eeeeee;border-color:#cccccc}.sd-select.sd-select--disabled .sd-select__label{border-right:1px solid #cccccc}.sd-select.sd-select--disabled .sd-select__trigger{color:#888888}.sd-select.sd-select--disabled .sd-select__trigger:focus,.sd-select.sd-select--disabled .sd-select__trigger:focus-visible,.sd-select.sd-select--disabled .sd-select__trigger:focus-within{outline:none !important}.sd-select__label{font-size:12px;line-height:20px;font-weight:500;color:#333333;padding:4px 12px;border-right:1px solid #cccccc;border-radius:4px 0 0 4px;background-color:#f6f6f6;display:inline-block;white-space:nowrap}.sd-select__container{position:relative;width:100%;display:flex}.sd-select__container .sd-select__trigger{padding:4px 20px 4px 12px;display:flex;width:100%;align-items:center}.sd-select__container .sd-select__trigger .sd-select__value{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;line-height:20px;font-size:12px;font-weight:400;text-align:left}.sd-select__container .sd-select__trigger .sd-select__clear{margin:0 4px;width:8px;height:8px;background-color:transparent;outline:none;border:none}.sd-select__container .sd-select__arrow{position:absolute;top:8px;right:8px;width:12px;height:12px;color:#888888;transition:transform 0.3s ease}.sd-select__container .sd-select__arrow--open{transform:rotate(180deg)}.sd-select__dropdown{width:var(--select-dropdown-width, 200px);max-height:var(--select-dropdown-height, 260px);padding-bottom:2px;background-color:white;box-shadow:2px 2px 12px 2px rgba(0, 0, 0, 0.1);border-radius:4px;overflow-y:auto;color:#333333;display:flex;flex-direction:column}.sd-select__dropdown .sd-select__search-container{position:sticky;top:0;display:flex;width:100%;background-color:white;align-items:center;padding:4px 8px}.sd-select__dropdown .sd-select__search-container--scrolled{box-shadow:2px 2px 8px 2px rgba(0, 0, 0, 0.2)}.sd-select__dropdown .sd-select__option-placeholder{padding:4px 12px;font-size:12px;line-height:20px;text-align:left}";
924
+ const sdSelectCss = ".sd-select__dropdown{overflow-y:auto;overflow-x:hidden;scroll-behavior:smooth}.sd-select__dropdown::-webkit-scrollbar{opacity:0;background:#e5e5e5}.sd-select__dropdown::-webkit-scrollbar:horizontal{height:8px}.sd-select__dropdown::-webkit-scrollbar:vertical{width:8px}.sd-select__dropdown::-webkit-scrollbar-thumb{height:80px;background-color:#cccccc;border-radius:4px}.sd-select__dropdown::-webkit-scrollbar-track{background-color:transparent}.sd-select{display:flex;width:var(--select-width, 200px);height:28px;position:relative;color:#333333;cursor:pointer;user-select:none;border:1px solid #aaaaaa;border-radius:4px;background-color:white}.sd-select:hover:not(.sd-select--disabled){background:#f6f6f6}.sd-select.sd-select--disabled{cursor:not-allowed;background-color:#eeeeee;border-color:#cccccc}.sd-select.sd-select--disabled .sd-select__label{border-right:1px solid #cccccc}.sd-select.sd-select--disabled .sd-select__trigger{color:#888888}.sd-select.sd-select--disabled .sd-select__trigger:focus,.sd-select.sd-select--disabled .sd-select__trigger:focus-visible,.sd-select.sd-select--disabled .sd-select__trigger:focus-within{outline:none !important}.sd-select__label{font-size:12px;line-height:20px;font-weight:500;color:#333333;padding:4px 12px;border-right:1px solid #cccccc;border-radius:4px 0 0 4px;background-color:#f6f6f6;display:inline-block;white-space:nowrap}.sd-select__container{position:relative;width:100%;display:flex}.sd-select__container .sd-select__trigger{padding:4px 20px 4px 12px;display:flex;width:100%;align-items:center}.sd-select__container .sd-select__trigger .sd-select__value{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;line-height:20px;font-size:12px;font-weight:400;text-align:left}.sd-select__container .sd-select__trigger .sd-select__clear{margin:0 4px;width:8px;height:8px;background-color:transparent;outline:none;border:none}.sd-select__container .sd-select__arrow{position:absolute;top:8px;right:8px;width:12px;height:12px;color:#888888;transition:transform 0.3s ease}.sd-select__container .sd-select__arrow--open{transform:rotate(180deg)}.sd-select__dropdown{width:var(--select-dropdown-width, 200px);max-height:var(--select-dropdown-height, 260px);padding-bottom:2px;background-color:white;box-shadow:2px 2px 12px 2px rgba(0, 0, 0, 0.1);border-radius:4px;overflow-y:auto;color:#333333;display:flex;flex-direction:column}.sd-select__dropdown .sd-select__search-container{position:sticky;top:0;display:flex;width:100%;background-color:white;align-items:center;padding:4px 8px}.sd-select__dropdown .sd-select__search-container--scrolled{box-shadow:2px 2px 8px 2px rgba(0, 0, 0, 0.2)}.sd-select__dropdown .sd-select__option-placeholder{padding:4px 12px;font-size:12px;line-height:20px;text-align:left}";
784
925
 
785
926
  const SdSelect = class extends BaseDropdownEvent {
786
927
  constructor(hostRef) {
@@ -1028,750 +1169,528 @@ const SdSelect = class extends BaseDropdownEvent {
1028
1169
  };
1029
1170
  SdSelect.style = sdSelectCss;
1030
1171
 
1031
- const sdSelectMultipleCss = ".sd-select-multiple__dropdown{overflow-y:auto;overflow-x:hidden;scroll-behavior:smooth}.sd-select-multiple__dropdown::-webkit-scrollbar{opacity:0;background:#e5e5e5}.sd-select-multiple__dropdown::-webkit-scrollbar:horizontal{height:8px}.sd-select-multiple__dropdown::-webkit-scrollbar:vertical{width:8px}.sd-select-multiple__dropdown::-webkit-scrollbar-thumb{height:80px;background-color:#cccccc;border-radius:4px}.sd-select-multiple__dropdown::-webkit-scrollbar-thumb:hover{background:#e5e5e5}.sd-select-multiple__dropdown::-webkit-scrollbar-thumb:active{background:#e5e5e5}.sd-select-multiple__dropdown::-webkit-scrollbar-track{background-color:transparent}:host{display:inline-block;height:fit-content;position:relative}.sd-select-multiple{display:flex;flex-wrap:nowrap;width:var(--select-width, 200px);height:28px;cursor:pointer;user-select:none;border:1px solid #aaaaaa;border-radius:4px;background-color:white}.sd-select-multiple:hover:not(.sd-select-multiple--disabled){background:#f6f6f6}.sd-select-multiple.sd-select-multiple--disabled{cursor:not-allowed;background-color:#eeeeee;border-color:#cccccc}.sd-select-multiple.sd-select-multiple--disabled .sd-select-multiple__label{border-right:1px solid #cccccc}.sd-select-multiple.sd-select-multiple--disabled .sd-select-multiple__trigger{color:#888888}.sd-select-multiple.sd-select-multiple--disabled .sd-select-multiple__trigger:focus,.sd-select-multiple.sd-select-multiple--disabled .sd-select-multiple__trigger:focus-visible,.sd-select-multiple.sd-select-multiple--disabled .sd-select-multiple__trigger:focus-within{outline:none !important}.sd-select-multiple__label{font-size:12px;font-weight:500;color:#333333;padding:4px 12px;border-right:1px solid #cccccc;border-radius:4px 0 0 4px;background-color:#f6f6f6}.sd-select-multiple__container{position:relative;width:100%;display:flex}.sd-select-multiple__container .sd-select-multiple__trigger{padding:4px 20px 4px 12px;display:flex;width:100%;align-items:center}.sd-select-multiple__container .sd-select-multiple__trigger .sd-select-multiple__value{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;line-height:20px;font-size:12px;font-weight:400}.sd-select-multiple__container .sd-select-multiple__trigger .sd-select-multiple__clear{margin:0 4px;width:8px;height:8px;background-color:transparent;outline:none;border:none}.sd-select-multiple__container .sd-select-multiple__arrow{position:absolute;top:8px;right:8px;width:12px;height:12px;color:#888888;transition:transform 0.3s ease}.sd-select-multiple__container .sd-select-multiple__arrow--open{transform:rotate(180deg)}.sd-select-multiple__dropdown{width:var(--select-dropdown-width, 200px);max-height:var(--select-dropdown-height, 260px);padding-bottom:2px;background-color:white;box-shadow:2px 2px 12px 2px rgba(0, 0, 0, 0.1);border-radius:4px;overflow-y:auto;color:#333333}.sd-select-multiple__dropdown .sd-select-multiple__search-container{position:sticky;top:0;display:flex;width:100%;background-color:white;align-items:center;padding:4px 8px;z-index:1}.sd-select-multiple__dropdown .sd-select-multiple__search-container--scrolled{box-shadow:2px 2px 8px 2px rgba(0, 0, 0, 0.2)}.sd-select-multiple__dropdown .sd-select-multiple__option-placeholder{padding:4px 12px;font-size:12px;line-height:20px;text-align:left}";
1172
+ const sdSelectOptionCss = "sd-select-option{display:block;height:fit-content;line-height:0}sd-select-option .sd-select__option{display:flex;padding:4px 12px;font-size:12px;line-height:20px;cursor:pointer}sd-select-option .sd-select__option__checkbox-wrapper{display:flex;width:100%;column-gap:8px;align-items:center;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}sd-select-option .sd-select__option--focused{background-color:#e6f1ff}sd-select-option .sd-select__option--selected:not(:hover):not(.sd-select__option--use-checkbox),sd-select-option .sd-select__option--focused:not(:hover):not(.sd-select__option--use-checkbox){color:#0075ff;font-weight:700}sd-select-option .sd-select__option--disabled{color:#aaaaaa;cursor:not-allowed}sd-select-option .sd-select__option:hover:not(.sd-select__option--disabled){background-color:#0075ff;color:white}";
1032
1173
 
1033
- const SdSelectMultiple = class extends BaseDropdownEvent {
1174
+ const SdSelectOption = class {
1034
1175
  constructor(hostRef) {
1035
- super();
1036
1176
  registerInstance(this, hostRef);
1037
- this.sdChange = createEvent(this, "sdChange");
1038
- this.dropDownShow = createEvent(this, "dropDownShow");
1177
+ this.optionClick = createEvent(this, "optionClick");
1039
1178
  }
1040
1179
  get el() { return getElement(this); }
1041
- // props
1042
- value = null;
1043
- label = '';
1044
- options = [];
1045
- placeholder = '선택';
1046
- optionPlaceholder = '옵션이 없습니다.';
1047
- width = '200px';
1048
- dropdownHeight = '260px';
1180
+ option;
1181
+ index;
1182
+ isSelected = false;
1183
+ isFocused = false;
1184
+ optionStyle;
1049
1185
  disabled = false;
1050
- clearable = false;
1051
- searchable = false;
1052
1186
  useCheckbox = false;
1053
- // props - custom slots
1054
- optionRenderer;
1055
- // states
1056
- filteredOptions = this.options;
1057
- isOpen = false;
1058
- searchText = null;
1059
- itemIndex = -1;
1060
- isScrolled = false;
1061
- // events
1062
- sdChange;
1063
- dropDownShow;
1064
- selectRef;
1065
- searchRef;
1066
- optionRef;
1067
- dropdownRef;
1068
- valueChanged() {
1069
- this.sdChange?.emit(this.value);
1187
+ isHovered = false;
1188
+ async isDisabled() {
1189
+ return !!this.option.disabled;
1070
1190
  }
1071
- optionsChanged() {
1072
- this.filteredOptions = this.options;
1073
- this.filterOptions();
1191
+ optionClick;
1192
+ handleClick = (event) => {
1193
+ event.stopPropagation();
1194
+ if (!this.option.disabled && !this.disabled) {
1195
+ this.optionClick.emit({
1196
+ option: this.option,
1197
+ index: this.index,
1198
+ event,
1199
+ });
1200
+ }
1201
+ };
1202
+ render() {
1203
+ return (h(Host, { key: '23d87df53fa083e6c9aceb1956de51800117df9f' }, h("div", { key: '569c5d35098350fa4d186ba838925de4f966c491', class: {
1204
+ 'sd-select__option': true,
1205
+ 'sd-select__option--selected': this.isSelected,
1206
+ 'sd-select__option--disabled': !!this.option.disabled,
1207
+ 'sd-select__option--focused': this.isFocused,
1208
+ 'sd-select__option--use-checkbox': this.useCheckbox,
1209
+ }, onMouseEnter: () => (this.isHovered = true), onMouseLeave: () => (this.isHovered = false), style: this.optionStyle, "data-index": this.index, onClick: this.handleClick }, this.useCheckbox ? (h("div", { class: "sd-select__option__checkbox-wrapper" }, h("sd-checkbox", { checked: this.isSelected, disabled: this.option.disabled,
1210
+ // checkboxStyle={
1211
+ // !this.isSelected
1212
+ // ? { borderColor: '#888' }
1213
+ // : this.isHovered
1214
+ // ? { borderColor: 'white' }
1215
+ // : { borderColor: '#0075ff' }
1216
+ // }
1217
+ onClick: e => {
1218
+ e.preventDefault();
1219
+ this.handleClick(e);
1220
+ } }), h("span", { class: "sd-select__option-label" }, this.option.label))) : (this.option.label))));
1074
1221
  }
1075
- searchTextChanged() {
1076
- this.filterOptions();
1222
+ };
1223
+ SdSelectOption.style = sdSelectOptionCss;
1224
+
1225
+ const sdTableCss = ".sd-table__wrapper .sd-table__container .sd-table__middle{overflow-y:auto;overflow-x:hidden;scroll-behavior:smooth}.sd-table__wrapper .sd-table__container .sd-table__middle::-webkit-scrollbar{opacity:0;background:#e5e5e5}.sd-table__wrapper .sd-table__container .sd-table__middle::-webkit-scrollbar:horizontal{height:8px}.sd-table__wrapper .sd-table__container .sd-table__middle::-webkit-scrollbar:vertical{width:8px}.sd-table__wrapper .sd-table__container .sd-table__middle::-webkit-scrollbar-thumb{height:80px;background-color:#cccccc;border-radius:4px}.sd-table__wrapper .sd-table__container .sd-table__middle::-webkit-scrollbar-track{background-color:transparent}.sd-table__wrapper{height:var(--table-height, auto);width:var(--table-width, 100%);color:#222222}.sd-table__wrapper .sd-table__container{width:100%;height:auto;border:1px solid #e1e1e1;border-radius:8px;font-size:12px;overflow:hidden}.sd-table__wrapper .sd-table__container .sd-table__middle{overflow:auto;will-change:scroll-position;height:var(--table-height, auto)}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table{width:100%;border-collapse:separate;border-spacing:0;table-layout:fixed}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--selectable td.sd-td--selected,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--selectable th.sd-th--selected{width:52px !important;max-width:52px !important;min-width:52px !important;padding:0 10px 0 24px;text-align:left}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-header thead{position:sticky;top:0;z-index:120}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column th.sticky-left,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column th.sticky-right{position:sticky;background-color:#f5faff;z-index:110 !important}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column td.sticky-left,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column td.sticky-right{position:sticky;background-color:white;z-index:100 !important}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column .sticky-left{left:var(--sticky-left-offset, 0)}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column .sticky-right{right:var(--sticky-right-offset, 0)}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column th.sticky-cell{position:sticky;z-index:102;background-color:#f5faff}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--sticky-column td.sticky-cell{position:sticky;z-index:101;background-color:white}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-left th.sticky-left-edge,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-left td.sticky-left-edge{overflow:visible}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-left th.sticky-left-edge:after,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-left td.sticky-left-edge:after{content:\"\";position:absolute;top:0;left:100%;right:-20px;width:20px;height:100%;z-index:101 !important;box-shadow:inset 12px 0 20px -25px;opacity:1;pointer-events:none}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-right th.sticky-right-edge,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-right td.sticky-right-edge{overflow:visible}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-right th.sticky-right-edge:after,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--scrolled-right td.sticky-right-edge:after{content:\"\";position:absolute;top:0;left:-20px;width:20px;height:100%;z-index:101 !important;box-shadow:inset -12px 0 20px -25px;opacity:1;pointer-events:none}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--no-data thead{opacity:0.4}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table--no-data thead tr th.sd-th{border-bottom:1px solid rgba(225, 225, 225, 0.4) !important}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table td,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table th,.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table .sd-th__content--label{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;word-break:keep-all}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead{height:36px}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead tr{width:100%}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead tr th{background:#f5faff;height:36px;padding:0 16px;font-weight:500;vertical-align:middle;border-bottom:1px solid #e1e1e1;-webkit-user-select:none;user-select:none;position:relative}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead tr th.sd-th .sd-th__content{display:flex;flex-flow:row nowrap;align-items:center;gap:4px}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead tr th.sd-th .sd-th__content--left{justify-content:flex-start}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead tr th.sd-th .sd-th__content--center{justify-content:center}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead tr th.sd-th .sd-th__content--right{justify-content:flex-end}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table thead tr th.sd-th .sd-th__resizer{position:absolute;top:50%;right:0;transform:translateY(-50%);width:4px;height:16px;cursor:col-resize;z-index:3;border-left:1px solid #cccccc;border-right:1px solid #cccccc}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table tbody tr:last-of-type td{border-bottom:none}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table tbody tr td{height:44px;padding:0 16px;border-bottom:1px solid #e1e1e1;background:white;vertical-align:middle}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table tbody tr td.sd-td--left{text-align:left}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table tbody tr td.sd-td--center{text-align:center}.sd-table__wrapper .sd-table__container .sd-table__middle .sd-table tbody tr td.sd-td--right{text-align:right}.sd-table__wrapper .sd-table__container .sd-table__bottom{background:white;text-align:center}.sd-table__wrapper .sd-table__pagination{position:relative;background:#f9f9f9;height:48px;display:flex;align-items:center;justify-content:center;border:1px solid #e1e1e1;border-top:none;border-radius:8px}.sd-table__wrapper .sd-table__pagination sd-select{position:absolute;right:10px;top:50%;transform:translateY(-50%)}";
1226
+
1227
+ const SdTable = class {
1228
+ constructor(hostRef) {
1229
+ registerInstance(this, hostRef);
1230
+ this.sdSelectChange = createEvent(this, "sdSelectChange");
1231
+ this.sdPageChange = createEvent(this, "sdPageChange");
1077
1232
  }
1078
- async itemIndexChanged(newIndex, oldIndex) {
1079
- if (this.searchable) {
1080
- const searchInput = await this.getNativeInputElement();
1081
- if (this.itemIndex === -1) {
1082
- searchInput?.focus();
1083
- return;
1084
- }
1085
- else if (searchInput?.matches(':focus')) {
1086
- searchInput?.blur();
1087
- }
1088
- }
1089
- const optionElements = Array.from(this.dropdownRef?.querySelectorAll('.sd-select-multiple__dropdown sd-select-option') || []);
1090
- const currentItem = optionElements?.[this.itemIndex];
1091
- if (!currentItem || !this.isOpen)
1233
+ get el() { return getElement(this); }
1234
+ columns;
1235
+ rows;
1236
+ selected = new Set();
1237
+ rowKey = 'id';
1238
+ selectable = false;
1239
+ resizable = false;
1240
+ width;
1241
+ height;
1242
+ stickyHeader = false;
1243
+ stickyColumn = { left: 0, right: 0 };
1244
+ noDataLabel = '데이터가 없습니다.';
1245
+ pagination;
1246
+ bodyCellRenderer;
1247
+ useInternalPagination = false;
1248
+ useRowsPerPageSelect = false;
1249
+ rowsPerPageOption = [
1250
+ { label: '10개씩 보기', value: 10 },
1251
+ { label: '25개씩 보기', value: 25 },
1252
+ { label: '50개씩 보기', value: 50 },
1253
+ { label: '100개씩 보기', value: 100 },
1254
+ ];
1255
+ sdSelectChange;
1256
+ sdPageChange;
1257
+ currentPage = this.pagination?.page || 1;
1258
+ innerRows = [];
1259
+ innerSelected = new Set();
1260
+ columnWidths = [];
1261
+ scrolledLeft = false;
1262
+ scrolledRight = false;
1263
+ handleColumnsChange(newCols) {
1264
+ this.columnWidths = newCols.map(c => parseInt(c.width || '120', 10));
1265
+ }
1266
+ handleRowsChange(newRows) {
1267
+ this.innerRows = [...newRows];
1268
+ }
1269
+ handleSelectedChange(newSelected) {
1270
+ this.innerSelected = new Set(newSelected);
1271
+ }
1272
+ handlePaginationChange(newVal) {
1273
+ if (newVal?.page && newVal.page !== this.currentPage)
1274
+ this.currentPage = newVal.page;
1275
+ }
1276
+ componentWillLoad() {
1277
+ this.innerRows = [...(this.rows || [])];
1278
+ this.innerSelected = new Set(this.selected);
1279
+ this.columnWidths = (this.columns || []).map(c => parseInt(c.width || '120', 10));
1280
+ }
1281
+ componentDidLoad() {
1282
+ // SSR 환경 체크
1283
+ if (typeof window === 'undefined')
1092
1284
  return;
1093
- this.optionRef = currentItem;
1094
- const isOptionDisabled = await this.optionRef.isDisabled();
1095
- if (isOptionDisabled) {
1096
- newIndex > oldIndex ? this.itemIndex++ : this.itemIndex--;
1285
+ const middle = this.el.querySelector('.sd-table__middle');
1286
+ if (!middle)
1097
1287
  return;
1098
- }
1099
- this.scrollToOption(currentItem);
1288
+ const onScroll = () => {
1289
+ const { scrollLeft, scrollWidth, clientWidth } = middle;
1290
+ this.scrolledLeft = scrollLeft > 0;
1291
+ this.scrolledRight = scrollLeft + clientWidth < scrollWidth;
1292
+ };
1293
+ middle.addEventListener('scroll', onScroll, { passive: true });
1294
+ onScroll();
1295
+ }
1296
+ // ----- Derived getters -----
1297
+ get visibleColumns() {
1298
+ return this.columns.filter(col => col.visible !== false);
1299
+ }
1300
+ get paginatedRows() {
1301
+ if (!this.pagination || !this.useInternalPagination)
1302
+ return this.innerRows;
1303
+ const { rowsPerPage = this.rows.length } = this.pagination || {};
1304
+ const result = this.innerRows.slice((this.currentPage - 1) * rowsPerPage, this.currentPage * rowsPerPage);
1305
+ return result;
1306
+ }
1307
+ get lastPageNumber() {
1308
+ const { lastPage, rowsPerPage = this.rows.length } = this.pagination || {};
1309
+ return lastPage ?? Math.max(1, Math.ceil(this.rows.length / rowsPerPage));
1310
+ }
1311
+ get sdTableClasses() {
1312
+ return [
1313
+ 'sd-table',
1314
+ this.stickyHeader && 'sd-table--sticky-header',
1315
+ this.selectable && 'sd-table--selectable',
1316
+ this.resizable && 'sd-table--resizable',
1317
+ !this.innerRows.length && 'sd-table--no-data',
1318
+ ((this.stickyColumn?.left ?? 0) > 0 || (this.stickyColumn?.right ?? 0) > 0) &&
1319
+ 'sd-table--sticky-column',
1320
+ this.scrolledLeft && 'sd-table--scrolled-left',
1321
+ this.scrolledRight && 'sd-table--scrolled-right',
1322
+ ]
1323
+ .filter(Boolean)
1324
+ .join(' ');
1325
+ }
1326
+ // ----- Selection -----
1327
+ isRowSelected(row) {
1328
+ return Array.from(this.innerSelected).some(r => r[this.rowKey] === row[this.rowKey]);
1329
+ }
1330
+ updateRowSelect(row) {
1331
+ const selectedArray = Array.from(this.innerSelected);
1332
+ const exists = this.isRowSelected(row);
1333
+ const newSelected = exists
1334
+ ? selectedArray.filter(r => r[this.rowKey] !== row[this.rowKey])
1335
+ : [...selectedArray, row];
1336
+ // 동일 상태면 set하지 않음 → 불필요 렌더 방지
1337
+ if (newSelected.length === selectedArray.length)
1338
+ return;
1339
+ this.innerSelected = new Set(newSelected);
1340
+ this.sdSelectChange.emit(Array.from(this.innerSelected));
1100
1341
  }
1101
- async isOpenChanged() {
1102
- // Base class의 이벤트 관리 호출 - 다른 select와의 이벤트 충돌 방지
1103
- this.onDropdownToggle(this.isOpen);
1104
- const selectedOption = this.getSelectedOption();
1105
- if (!selectedOption) {
1106
- this.itemIndex = -1;
1342
+ toggleSelectAll(checked) {
1343
+ if (checked) {
1344
+ const pageRows = new Set([...this.paginatedRows]);
1345
+ this.innerSelected = new Set([...this.innerSelected, ...pageRows]);
1107
1346
  }
1108
1347
  else {
1109
- this.itemIndex = this.options.indexOf(selectedOption[0]);
1110
- }
1111
- this.dropDownShow?.emit({ isOpen: this.isOpen });
1112
- if (this.isOpen === false)
1113
- return;
1114
- await new Promise(resolve => setTimeout(resolve, 10));
1115
- const optionElements = Array.from(this.dropdownRef?.querySelectorAll('.sd-select-multiple__dropdown sd-select-item') || []);
1116
- const currentItem = optionElements?.[this.itemIndex];
1117
- // 드롭다운이 열릴 때 검색 입력에 포커스
1118
- if (this.searchable) {
1119
- const searchInput = await this.getNativeInputElement();
1120
- searchInput?.focus();
1121
- }
1122
- if (!currentItem)
1123
- return;
1124
- await new Promise(resolve => setTimeout(resolve, 10)); // 추가 딜레이
1125
- this.scrollToOption(currentItem);
1348
+ const currentPageKeys = this.paginatedRows.map(r => r[this.rowKey]);
1349
+ this.innerSelected = new Set([...this.innerSelected].filter(r => !currentPageKeys.includes(r[this.rowKey])));
1350
+ }
1351
+ this.sdSelectChange.emit(Array.from(this.innerSelected));
1352
+ }
1353
+ get isAllChecked() {
1354
+ const total = this.paginatedRows.length;
1355
+ const selectedCount = this.paginatedRows.filter(row => Array.from(this.innerSelected).some(selectedRow => selectedRow[this.rowKey] === row[this.rowKey])).length;
1356
+ if (selectedCount === 0)
1357
+ return false; // 아무것도 안 선택됨
1358
+ if (selectedCount === total)
1359
+ return true; // 전부 선택됨
1360
+ return null; // 일부만 선택됨
1361
+ }
1362
+ // ----- Helpers -----
1363
+ getStickyStyle(colIdx) {
1364
+ const leftOffset = this.columnWidths.slice(0, colIdx).reduce((a, b) => a + b, 0) + (this.selectable ? 52 : 0);
1365
+ const rightOffset = this.columnWidths
1366
+ .filter((_, i) => i >= this.visibleColumns.length - (this.stickyColumn.right || 0) && i > colIdx)
1367
+ .reduce((a, b) => a + b, 0);
1368
+ return {
1369
+ '--sticky-left-offset': `${leftOffset}px`,
1370
+ '--sticky-right-offset': `${rightOffset}px`,
1371
+ 'width': `${this.columnWidths[colIdx]}px`,
1372
+ 'minWidth': `${this.columnWidths[colIdx]}px`,
1373
+ 'maxWidth': `${this.columnWidths[colIdx]}px`,
1374
+ };
1126
1375
  }
1127
- connectedCallback() {
1128
- // props가 모두 설정된 후에 실행되므로 올바른 options 값을 가져올 수 있음
1129
- this.filteredOptions = this.options;
1130
- this.initializeEvent(); // global dropdown Manager에 등록 + 이벤트 핸들러 초기화
1376
+ handleResize(index, event) {
1377
+ // SSR 환경 체크
1378
+ if (typeof document === 'undefined')
1379
+ return;
1380
+ const startX = event.clientX;
1381
+ const startWidth = this.columnWidths[index];
1382
+ const handleMouseMove = (moveEvent) => {
1383
+ const newWidth = Math.max(startWidth + moveEvent.clientX - startX, 50);
1384
+ this.columnWidths = this.columnWidths.map((width, idx) => (idx === index ? newWidth : width));
1385
+ };
1386
+ const handleMouseUp = () => {
1387
+ document.removeEventListener('mousemove', handleMouseMove);
1388
+ document.removeEventListener('mouseup', handleMouseUp);
1389
+ };
1390
+ document.addEventListener('mousemove', handleMouseMove);
1391
+ document.addEventListener('mouseup', handleMouseUp);
1392
+ }
1393
+ getCellValue(column, row) {
1394
+ const { field, format, name } = column;
1395
+ const value = typeof field === 'function' ? field(row) : field ? row[field] : row[name];
1396
+ return format ? format(value, row) : value;
1397
+ }
1398
+ // ----- Render -----
1399
+ renderHeader() {
1400
+ return (h("thead", null, h("tr", null, this.selectable && (h("th", { class: {
1401
+ 'sd-th': true,
1402
+ 'sd-th--selected': true,
1403
+ 'sticky-left': Boolean(this.stickyColumn.left && this.stickyColumn.left > 0),
1404
+ }, style: {
1405
+ '--sticky-left-offset': '0px',
1406
+ } }, h("sd-checkbox", { checked: this.isAllChecked, disabled: !this.paginatedRows.length, onSdChange: (e) => this.toggleSelectAll(e.detail) }))), this.visibleColumns.map((col, colIdx) => (h("th", { key: col.name, class: {
1407
+ 'sd-th': true,
1408
+ [`${col.thClass}`]: Boolean(col.thClass),
1409
+ 'sticky-left': Boolean(this.stickyColumn.left && colIdx < this.stickyColumn.left),
1410
+ 'sticky-right': Boolean(this.stickyColumn.right && colIdx >= this.visibleColumns.length - this.stickyColumn.right),
1411
+ 'sticky-left-edge': Boolean(this.stickyColumn.left && colIdx === this.stickyColumn.left - 1),
1412
+ 'sticky-right-edge': Boolean(this.stickyColumn.right &&
1413
+ colIdx === this.visibleColumns.length - this.stickyColumn.right),
1414
+ }, style: this.getStickyStyle(colIdx) }, h("div", { class: `sd-th__content sd-th__content--${col.align || 'left'}` }, h("slot", { name: `header-cell-${col.name}` }, h("div", { class: "sd-th__content--label" }, col.label)), col.usePageMoveIcon && h("sd-icon", { name: "pageMove", size: "12", color: "#006AC1" }), col.tooltip && (h("sd-tooltip", { ...col.tooltipOptions }, h("div", { slot: "content" }, col.tooltip.map(text => (h("p", null, text))))))), this.resizable && typeof window !== 'undefined' && (h("div", { class: "sd-th__resizer", onMouseDown: (evt) => this.handleResize(colIdx, evt) }))))))));
1415
+ }
1416
+ renderBody() {
1417
+ if (!this.paginatedRows.length)
1418
+ return (h("tbody", { part: "tbody-empty" }, h("tr", null, h("td", { colSpan: this.visibleColumns.length + (this.selectable ? 1 : 0) }, this.noDataLabel))));
1419
+ return (h("tbody", null, this.paginatedRows.map((row, rowIdx) => (h("tr", { key: row[this.rowKey], class: "hover:bg-Grey_Lighten-6" }, this.selectable && (h("td", { class: {
1420
+ 'sd-td': true,
1421
+ 'sd-td--selected': true,
1422
+ 'sticky-left': Boolean(this.stickyColumn.left && this.stickyColumn.left > 0),
1423
+ }, style: {
1424
+ '--sticky-left-offset': '0px',
1425
+ } }, h("sd-checkbox", { checked: this.isRowSelected(row), disabled: !this.paginatedRows.length, onSdChange: () => this.updateRowSelect(row) }))), this.visibleColumns.map((column, colIdx) => {
1426
+ const rendered = this.bodyCellRenderer?.(column, row);
1427
+ return (h("td", { key: column.name, part: `td-${column.name}`, class: {
1428
+ 'sd-td': true,
1429
+ [`sd-td--${column.align || 'left'}`]: true,
1430
+ 'sticky-left': Boolean(this.stickyColumn.left && colIdx < this.stickyColumn.left),
1431
+ 'sticky-right': Boolean(this.stickyColumn.right &&
1432
+ colIdx >= this.visibleColumns.length - this.stickyColumn.right),
1433
+ 'sticky-left-edge': Boolean(this.stickyColumn.left && colIdx === this.stickyColumn.left - 1),
1434
+ 'sticky-right-edge': Boolean(this.stickyColumn.right &&
1435
+ colIdx === this.visibleColumns.length - this.stickyColumn.right),
1436
+ [`${column.tdClass}`]: Boolean(column.tdClass),
1437
+ }, style: this.getStickyStyle(colIdx) }, h("slot", { name: `body-cell-${column.name}-${rowIdx}` }, rendered ? (typeof rendered === 'string' ? (h("span", { innerHTML: rendered })) : (rendered)) : (this.getCellValue(column, row)))));
1438
+ }))))));
1131
1439
  }
1132
- disconnectedCallback() {
1133
- this.cleanupEvent(); // global dropdown Manager에서 제거 + 이벤트 정리
1134
- }
1135
- handleDocumentClick(event) {
1136
- if (!this.selectRef?.contains(event.target)) {
1137
- this.isOpen = false;
1138
- }
1139
- }
1140
- handleDocumentKeydown(keyboardEvent) {
1141
- keyboardEvent.stopPropagation();
1142
- const targetKey = ['ArrowDown', 'ArrowUp', 'Enter', 'Escape'];
1143
- if (!targetKey.includes(keyboardEvent.key))
1144
- return;
1145
- keyboardEvent.preventDefault();
1146
- switch (keyboardEvent.key) {
1147
- case 'ArrowDown':
1148
- case 'ArrowUp':
1149
- const keyboardNavigation = new SelectKeyboardNavigation(this.searchable, this.filteredOptions);
1150
- const nextIndex = keyboardNavigation.getNextIndex(this.itemIndex, keyboardEvent.key);
1151
- this.itemIndex = nextIndex;
1152
- break;
1153
- case 'Enter':
1154
- const selectedOption = this.filteredOptions[this.itemIndex];
1155
- if (selectedOption && !selectedOption.disabled) {
1156
- this.handleOptionSelection(selectedOption);
1157
- }
1158
- break;
1159
- case 'Escape':
1160
- this.isOpen = false;
1161
- break;
1162
- }
1163
- }
1164
- // event handlers
1165
- handleTriggerClick = (event) => {
1166
- event.stopPropagation();
1167
- if (!this.disabled) {
1168
- this.isOpen = !this.isOpen;
1169
- this.dropDownShow?.emit({ isOpen: this.isOpen });
1170
- }
1171
- };
1172
- handleOptionClick = (detail) => {
1173
- const { option, event } = detail;
1174
- event.stopPropagation();
1175
- this.handleOptionSelection(option);
1176
- };
1177
- filterOptions() {
1178
- if (!this.searchText || this.searchText.trim() === '') {
1179
- // 검색어가 없으면 전체 옵션 표시
1180
- this.filteredOptions = this.options;
1181
- }
1182
- else {
1183
- // 검색어가 있으면 필터링
1184
- this.filteredOptions = this.options.filter(option => option.label.toLowerCase().includes(this.searchText.toLowerCase()));
1185
- }
1186
- }
1187
- getSelectedOption() {
1188
- return this.options.filter(option => this.value?.includes(option));
1189
- }
1190
- handleDropdownScroll = (event) => {
1191
- const target = event.target;
1192
- const scrollTop = target.scrollTop;
1193
- // 스크롤이 조금이라도 되면 그림자 표시
1194
- this.isScrolled = scrollTop > 0;
1195
- };
1196
- async getNativeInputElement() {
1197
- if (this.searchRef) {
1198
- return this.searchRef.getNativeElement();
1199
- }
1200
- return null;
1201
- }
1202
- handleOptionSelection = (option) => {
1203
- if (!option || option.disabled)
1204
- return;
1205
- const isAlreadySelected = this.value?.some(opt => opt.value === option.value);
1206
- if (isAlreadySelected) {
1207
- // 이미 선택된 옵션인 경우, 선택 해제
1208
- this.value = this.value?.filter(opt => opt.value !== option.value) || null;
1209
- }
1210
- else {
1211
- // 새로운 옵션 선택
1212
- this.value = [...(this.value || []), option];
1213
- }
1214
- };
1215
- closeDropdown() {
1216
- this.isOpen = false;
1217
- }
1218
- scrollToOption(optionElement) {
1219
- if (!this.dropdownRef || !optionElement)
1220
- return;
1221
- const dropdown = this.dropdownRef;
1222
- const optionTop = optionElement.offsetTop;
1223
- const optionHeight = optionElement.offsetHeight;
1224
- const dropdownScrollTop = dropdown.scrollTop;
1225
- const dropdownHeight = dropdown.clientHeight;
1226
- const searchContainer = dropdown.querySelector('.sd-select__search-container');
1227
- const searchOffset = searchContainer ? searchContainer.offsetHeight : 0;
1228
- const visibleTop = dropdownScrollTop + searchOffset;
1229
- const visibleBottom = dropdownScrollTop + dropdownHeight;
1230
- if (optionTop < visibleTop) {
1231
- dropdown.scrollTop = optionTop - searchOffset;
1232
- }
1233
- else if (optionTop + optionHeight > visibleBottom) {
1234
- dropdown.scrollTop = optionTop + optionHeight - dropdownHeight + searchOffset;
1235
- }
1236
- }
1237
- // render method
1238
- render() {
1239
- const style = {
1240
- '--select-width': this.width || '200px',
1241
- '--select-dropdown-height': this.dropdownHeight || '260px',
1242
- };
1243
- return (h(Host, { key: '7f8cd5ee5ccf46bf023b02439d1cc1dd331a2d03', style: style }, h("div", { key: 'c8789241b7ae42119b94c25740d314745b6b3b0b', class: {
1244
- 'sd-select-multiple': true,
1245
- 'sd-select-multiple--open': this.isOpen,
1246
- 'sd-select-multiple--disabled': this.disabled,
1247
- }, ref: el => (this.selectRef = el) }, this.renderLabel(this.label), h("div", { key: 'cf57263149b3cfbeada5699a66b11fbc237965c7', class: "sd-select-multiple__container" }, this.renderTrigger(), this.renderDropdown()))));
1248
- }
1249
- renderLabel(label) {
1250
- if (!label)
1251
- return null;
1252
- return h("label", { class: "sd-select-multiple__label" }, label);
1253
- }
1254
- renderTrigger() {
1255
- const selectedOption = this.getSelectedOption();
1256
- return (h("div", { class: "sd-select-multiple__trigger", tabindex: this.disabled ? -1 : 0, onClick: this.handleTriggerClick }, h("span", { class: "sd-select-multiple__value" }, !selectedOption
1257
- ? '선택'
1258
- : selectedOption.length
1259
- ? selectedOption.map(option => option.label).join(', ')
1260
- : this.placeholder), this.clearable && selectedOption?.length > 0 && !this.disabled && (h("sd-icon", { key: "close-icon", name: "close", size: 10, color: "#888", class: "sd-select-multiple__clear", onClick: event => {
1261
- event.stopPropagation();
1262
- this.value = null;
1263
- } })), h("sd-icon", { key: "arrow-icon", name: "arrowDown", color: "#888", class: { 'sd-select-multiple__arrow': true, 'sd-select-multiple__arrow--open': this.isOpen } })));
1264
- }
1265
- renderDropdown() {
1266
- if (this.isOpen === false)
1267
- return null;
1268
- return (h("sd-portal", { open: this.isOpen, parentRef: this.selectRef, onSdClose: this.closeDropdown }, h("div", { class: "sd-select-multiple__dropdown", onScroll: this.handleDropdownScroll, ref: el => (this.dropdownRef = el) }, this.searchable && (h("div", { class: {
1269
- 'sd-select-multiple__search-container': true,
1270
- 'sd-select-multiple__search-container--scrolled': this.isScrolled,
1271
- }, onClick: event => event.stopPropagation() }, h("sd-input", { ref: el => (this.searchRef = el), value: this.searchText, placeholder: "\uAC80\uC0C9", clearable: true, inputStyle: { 'padding-left': '8px' }, autofocus: true, onSdInput: event => {
1272
- this.searchText = String(event?.detail);
1273
- }, onSdFocus: () => {
1274
- this.itemIndex = -1;
1275
- } }, h("sd-icon", { name: "search", size: 16, color: "#737373", style: { marginRight: '4px' }, slot: "prefix" })))), this.filteredOptions.length > 0 ? (this.filteredOptions.map((option, index) => (h("slot", { name: `option-${option.value}` }, h("sd-select-option", { option: option, index: index, isSelected: this.value?.some(selected => selected.value === option.value), isFocused: index === this.itemIndex, onOptionClick: ({ detail }) => this.handleOptionClick(detail), useCheckbox: this.useCheckbox }))))) : (h("slot", { name: "option-placeholder" }, h("div", { class: 'sd-select-multiple__option-placeholder' }, this.optionPlaceholder))))));
1440
+ render() {
1441
+ return (h(Host, { key: 'b73fefde2c99c864002a2e778b02a306d4c8c32d' }, h("div", { key: '4fbf588871e3b8cb92e087cbde59aa9280ba75cd', class: "sd-table__wrapper", style: {
1442
+ '--table-width': this.width,
1443
+ '--table-height': this.height,
1444
+ } }, h("div", { key: '92d69eaf8e499fd5b3a0ebb3d77353c8285949e5', class: "sd-table__container" }, h("div", { key: '590fd93058983bab3bc829e7c6ce4e058365287f', class: "sd-table__middle" }, h("table", { key: 'c1fd46586bd9429377dfff9df94550cb5437b05a', part: "table", class: this.sdTableClasses }, this.renderHeader(), this.renderBody())), h("div", { key: '89a48072c9f6b84d062e4e127b5858657003fc87', class: "sd-table__bottom" })), this.pagination && this.innerRows.length > 0 && (h("div", { key: '526c024bc5493b8a3abb4f7887ec221e38dd2937', class: "sd-table__pagination" }, h("sd-pagination", { key: 'f607579ff98e70f2c6975139a17c7fc48b940a19', currentPage: !this.useInternalPagination ? this.pagination.page : this.currentPage, lastPage: !this.useInternalPagination ? this.pagination.lastPage : this.lastPageNumber, onPageChange: (e) => {
1445
+ if (!this.useInternalPagination) {
1446
+ this.sdPageChange.emit(e.detail);
1447
+ }
1448
+ else {
1449
+ this.currentPage = e.detail;
1450
+ this.sdPageChange.emit(this.currentPage);
1451
+ }
1452
+ } }), this.useRowsPerPageSelect && (h("sd-select", { key: '683424acaf3961dcf681e8a04275cdba6bdf9928', value: this.pagination.rowsPerPage, options: this.rowsPerPageOption, width: "128px", onSdChange: (e) => {
1453
+ const newRowsPerPage = Number(e.detail.value || 0);
1454
+ let newLastPage = Math.max(1, Math.ceil(this.innerRows.length / newRowsPerPage));
1455
+ let newCurrentPage = this.currentPage;
1456
+ if (newCurrentPage > newLastPage) {
1457
+ newCurrentPage = newLastPage;
1458
+ }
1459
+ this.pagination = {
1460
+ page: newCurrentPage,
1461
+ rowsPerPage: newRowsPerPage,
1462
+ lastPage: newLastPage,
1463
+ };
1464
+ this.currentPage = newCurrentPage;
1465
+ this.sdPageChange.emit(this.currentPage);
1466
+ } })))))));
1276
1467
  }
1277
1468
  static get watchers() { return {
1278
- "value": ["valueChanged"],
1279
- "options": ["optionsChanged"],
1280
- "searchText": ["searchTextChanged"],
1281
- "itemIndex": ["itemIndexChanged"],
1282
- "isOpen": ["isOpenChanged"]
1469
+ "columns": ["handleColumnsChange"],
1470
+ "rows": ["handleRowsChange"],
1471
+ "selected": ["handleSelectedChange"],
1472
+ "pagination": ["handlePaginationChange"]
1283
1473
  }; }
1284
1474
  };
1285
- SdSelectMultiple.style = sdSelectMultipleCss;
1475
+ SdTable.style = sdTableCss;
1286
1476
 
1287
- const sdSelectMultipleGroupCss = ".sd-select-multiple-group__dropdown{overflow-y:auto;overflow-x:hidden;scroll-behavior:smooth}.sd-select-multiple-group__dropdown::-webkit-scrollbar{opacity:0;background:#e5e5e5}.sd-select-multiple-group__dropdown::-webkit-scrollbar:horizontal{height:8px}.sd-select-multiple-group__dropdown::-webkit-scrollbar:vertical{width:8px}.sd-select-multiple-group__dropdown::-webkit-scrollbar-thumb{height:80px;background-color:#cccccc;border-radius:4px}.sd-select-multiple-group__dropdown::-webkit-scrollbar-thumb:hover{background:#e5e5e5}.sd-select-multiple-group__dropdown::-webkit-scrollbar-thumb:active{background:#e5e5e5}.sd-select-multiple-group__dropdown::-webkit-scrollbar-track{background-color:transparent}sd-select-multiple-group{display:inline-block;height:fit-content}sd-select-multiple-group .sd-select-multiple-group{display:flex;flex-wrap:nowrap;width:var(--select-width, 200px);cursor:pointer;user-select:none;border:1px solid #aaaaaa;border-radius:4px;background-color:white;color:#333333}sd-select-multiple-group .sd-select-multiple-group:hover:not(.sd-select-multiple-group--disabled){background:#f6f6f6}sd-select-multiple-group .sd-select-multiple-group.sd-select-multiple-group--disabled{cursor:not-allowed;background-color:#eeeeee;border-color:#cccccc}sd-select-multiple-group .sd-select-multiple-group.sd-select-multiple-group--disabled .sd-select-multiple-group__label{border-right:1px solid #cccccc}sd-select-multiple-group .sd-select-multiple-group.sd-select-multiple-group--disabled .sd-select-multiple-group__trigger{color:#888888}sd-select-multiple-group .sd-select-multiple-group.sd-select-multiple-group--disabled .sd-select-multiple-group__trigger:focus,sd-select-multiple-group .sd-select-multiple-group.sd-select-multiple-group--disabled .sd-select-multiple-group__trigger:focus-visible,sd-select-multiple-group .sd-select-multiple-group.sd-select-multiple-group--disabled .sd-select-multiple-group__trigger:focus-within{outline:none !important}sd-select-multiple-group .sd-select-multiple-group__label{font-size:12px;font-weight:500;color:#333333;padding:4px 12px;border-right:1px solid #cccccc;border-radius:4px 0 0 4px;background-color:#f6f6f6}sd-select-multiple-group .sd-select-multiple-group__container{position:relative;width:100%;display:flex}sd-select-multiple-group .sd-select-multiple-group__container .sd-select-multiple-group__trigger{padding:4px 20px 4px 12px;display:flex;width:100%;align-items:center}sd-select-multiple-group .sd-select-multiple-group__container .sd-select-multiple-group__trigger .sd-select-multiple-group__value{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;line-height:20px;font-size:12px;font-weight:400}sd-select-multiple-group .sd-select-multiple-group__container .sd-select-multiple-group__trigger .sd-select-multiple-group__clear{margin:0 4px;width:8px;height:8px;background-color:transparent;outline:none;border:none}sd-select-multiple-group .sd-select-multiple-group__container .sd-select-multiple-group__arrow{position:absolute;top:8px;right:8px;width:12px;height:12px;color:#888888;transition:transform 0.3s ease}sd-select-multiple-group .sd-select-multiple-group__container .sd-select-multiple-group__arrow--open{transform:rotate(180deg)}.sd-select-multiple-group__dropdown{width:var(--select-width, 200px);max-height:var(--select-dropdown-height, 260px);padding-bottom:2px;background-color:white;box-shadow:2px 2px 12px 2px rgba(0, 0, 0, 0.1);border-radius:4px;overflow-y:auto;color:#333333}.sd-select-multiple-group__dropdown .sd-select-multiple-group__search-container{position:sticky;top:0;display:flex;width:100%;background-color:white;align-items:center;padding:4px 8px}.sd-select-multiple-group__dropdown .sd-select-multiple-group__search-container sd-input{width:100%}.sd-select-multiple-group__dropdown .sd-select-multiple-group__search-container--scrolled{box-shadow:2px 2px 8px 2px rgba(0, 0, 0, 0.2)}.sd-select-multiple-group__dropdown .sd-select-multiple-group__option-placeholder{padding:4px 12px;font-size:12px;line-height:20px}";
1477
+ const sdTooltipCss = "sd-tooltip [slot=content]{display:none}sd-tooltip .sd-tooltip{position:relative;cursor:pointer;display:inline-block}.sd-tooltip-menu{width:fit-content;padding:8px 16px;border-radius:4px;font-size:12px;position:relative;box-sizing:border-box;display:flex;align-items:start;justify-content:center;gap:12px}.sd-tooltip-menu--with-close{padding-right:12px !important}.sd-tooltip-menu__arrow{position:absolute;display:flex;width:9.6px;height:7.2px}.sd-tooltip-menu__arrow svg{width:100%;height:100%}.sd-tooltip-menu__arrow--top{bottom:-7.2px;left:50%;transform:translateX(-50%)}.sd-tooltip-menu__arrow--bottom{top:-7.2px;left:50%;transform:translateX(-50%) rotate(180deg)}.sd-tooltip-menu__arrow--left{right:-7.2px;top:50%;transform:translateY(-50%) rotate(-90deg)}.sd-tooltip-menu__arrow--right{left:-7.2px;top:50%;transform:translateY(-50%) rotate(90deg)}.sd-tooltip-menu__content{line-height:20px;font-weight:500}.sd-tooltip-menu__content p{margin:0}.sd-tooltip-menu__close-button{padding-top:4px;display:flex}.sd-tooltip-menu__close-button button{padding:0;background:none;border:none;cursor:pointer}";
1288
1478
 
1289
- const SdSelectMultipleGroup = class extends BaseDropdownEvent {
1479
+ const SdTooltip = class {
1290
1480
  constructor(hostRef) {
1291
- super();
1292
1481
  registerInstance(this, hostRef);
1293
- this.sdChange = createEvent(this, "sdChange");
1294
- this.dropDownShow = createEvent(this, "dropDownShow");
1295
1482
  }
1296
1483
  get el() { return getElement(this); }
1297
- // props
1298
- value = null;
1484
+ trigger = 'hover';
1485
+ placement = 'top';
1486
+ color = '#01BB4B';
1487
+ type = 'default';
1488
+ icon = 'helpOutline';
1489
+ iconSize = 12;
1299
1490
  label = '';
1300
- options = [];
1301
- placeholder = '선택';
1302
- optionPlaceholder = '옵션이 없습니다.';
1303
- width = '200px';
1304
- dropdownHeight = '260px';
1305
- disabled = false;
1306
- clearable = false;
1307
- searchable = false;
1308
- useCheckbox = false;
1309
- // props - custom styles
1310
- containerStyle = {};
1311
- triggerStyle = {};
1312
- dropdownStyle = {};
1313
- optionStyle = {};
1314
- labelStyle = {};
1315
- // props - custom slots
1316
- optionRenderer;
1317
- // states
1318
- filteredOptions = this.options;
1319
- isOpen = false;
1320
- searchText = null;
1321
- itemIndex = -1;
1322
- isScrolled = false;
1323
- // events
1324
- sdChange;
1325
- dropDownShow;
1326
- selectRef;
1327
- searchRef;
1328
- optionRef;
1329
- dropdownRef;
1330
- valueChanged() {
1331
- this.sdChange?.emit(this.value);
1491
+ buttonSize = 'sm';
1492
+ buttonVariant = 'primary';
1493
+ noHover = true;
1494
+ useClose = false;
1495
+ showTooltip = false;
1496
+ slotContent = null;
1497
+ static COLOR_OF_TYPE = {
1498
+ default: { background: 'oceanblue_85', text: 'white' },
1499
+ caution: { background: 'red_20', text: 'red_70' },
1500
+ notice: { background: 'orange_10', text: 'orange_65' },
1501
+ accent: { background: 'brilliantblue_20', text: 'brilliantblue_75' },
1502
+ };
1503
+ buttonEl;
1504
+ handleClose = () => {
1505
+ this.showTooltip = false;
1506
+ };
1507
+ // 현재 tooltip popover가 조건부 렌더링이여서 초기 slot이 렌더링 되지 않은 시점에
1508
+ // 데이터 매핑에 실패 (light dom에 저장된 slot내용을 shadow dom을 찾지못해 매핑 실패)
1509
+ // 따라서 slot내용을 받은 후에 복제하여 state에 저장
1510
+ componentWillLoad() {
1511
+ const contentEl = this.el.querySelector('[slot="content"]');
1512
+ if (contentEl) {
1513
+ this.slotContent = contentEl.cloneNode(true);
1514
+ }
1332
1515
  }
1333
- optionsChanged() {
1334
- this.filteredOptions = this.options;
1335
- this.filterOptions();
1516
+ render() {
1517
+ const handleTrigger = this.trigger === 'hover'
1518
+ ? {
1519
+ onMouseEnter: () => (this.showTooltip = true),
1520
+ onMouseLeave: () => (this.showTooltip = false),
1521
+ }
1522
+ : {
1523
+ onClick: () => (this.showTooltip = !this.showTooltip),
1524
+ };
1525
+ return (h(Fragment, { key: 'da480a55495b1311368ae55ef8827a54ea5de766' }, this.label ? (h("sd-button", { ref: el => (this.buttonEl = el), label: this.label, icon: this.icon, size: this.buttonSize, color: this.color, variant: this.buttonVariant, class: "sd-tooltip", ...handleTrigger })) : (h("sd-icon", { ref: el => (this.buttonEl = el), name: this.icon, size: this.iconSize, color: this.color, class: "sd-tooltip", ...handleTrigger })), this.showTooltip && (h("sd-tooltip-portal", { key: '74be36575fbf97c9b51577fa5b24a4fbcfcf4c6b', parentRef: this.buttonEl, onSdClose: () => this.handleClose(), placement: this.placement }, h("div", { key: '63707a51fcc66a3a0c91fc7d409d30f61c0b1f17', class: {
1526
+ 'sd-tooltip-menu': true,
1527
+ [`sd-tooltip-menu--${this.type}`]: true,
1528
+ [`sd-tooltip-menu--${this.placement}`]: true,
1529
+ 'sd-tooltip-menu--with-close': this.useClose,
1530
+ [`bg-${SdTooltip.COLOR_OF_TYPE[this.type].background}`]: true,
1531
+ [`text-${SdTooltip.COLOR_OF_TYPE[this.type].text}`]: true,
1532
+ } }, h("i", { key: 'a2c557e1457c293ef4a6fb3e23a70c9ff5b0b027', class: `sd-tooltip-menu__arrow sd-tooltip-menu__arrow--${this.placement}` }, h(TooltipArrow, { key: '7e7e471bb288680875fbbaa1d7b7df34b636c76f', class: {
1533
+ [`text-${SdTooltip.COLOR_OF_TYPE[this.type].background}`]: true,
1534
+ } })), h("div", { key: 'c7f7a093907053c100fdb5f247d09d984f8cddd8', class: "sd-tooltip-menu__content", ref: el => {
1535
+ if (el && this.slotContent && !el.hasChildNodes()) {
1536
+ el.appendChild(this.slotContent.cloneNode(true));
1537
+ }
1538
+ } }, !this.slotContent && h("span", { key: '14925b4653ca984bd6adf99f6297713dc8b2bafa' }, this.el.textContent)), this.useClose && (h("div", { key: '1a02cee06eaaf9068396fb0b489c93e23ba5c8b7', class: "sd-tooltip-menu__close-button" }, h("button", { key: '40973df40b2ec2ab887a47c7f3e466f6cae4e69f', type: "button", "aria-label": "Close tooltip", title: "Close tooltip", onClick: () => this.handleClose() }, h("sd-icon", { key: 'a02e35f80ae7d3c1414577ce253a67d6dfd64bc0', name: "close", size: "12", color: "#AAAAAA" })))))))));
1336
1539
  }
1337
- searchTextChanged() {
1338
- this.filterOptions();
1540
+ };
1541
+ SdTooltip.style = sdTooltipCss;
1542
+
1543
+ const SdTooltipPortal = class {
1544
+ constructor(hostRef) {
1545
+ registerInstance(this, hostRef);
1546
+ this.sdClose = createEvent(this, "sdClose");
1339
1547
  }
1340
- async itemIndexChanged(newIndex, oldIndex) {
1341
- if (this.searchable) {
1342
- const searchInput = await this.getNativeInputElement();
1343
- if (this.itemIndex === -1) {
1344
- searchInput?.focus();
1345
- return;
1346
- }
1347
- else if (searchInput?.matches(':focus')) {
1348
- searchInput?.blur();
1548
+ get el() { return getElement(this); }
1549
+ to = 'body';
1550
+ parentRef = null;
1551
+ offset = [0, 0];
1552
+ zIndex = 9999;
1553
+ placement = 'bottom';
1554
+ open = false;
1555
+ sdClose;
1556
+ container;
1557
+ wrapper;
1558
+ rafId;
1559
+ isInsideClick = false;
1560
+ resizeObserver;
1561
+ mutationObserver;
1562
+ static ARROW_SIZE = 11.2;
1563
+ componentDidLoad() {
1564
+ this.container = this.resolveContainer();
1565
+ this.createWrapper();
1566
+ this.moveSlotContent();
1567
+ // DOM이 완전히 렌더링된 후 위치 계산
1568
+ requestAnimationFrame(() => {
1569
+ this.updatePosition();
1570
+ if (this.wrapper) {
1571
+ this.wrapper.style.visibility = 'visible'; // 위치 계산 후 표시
1349
1572
  }
1350
- }
1351
- const optionElements = Array.from(this.dropdownRef?.querySelectorAll('.sd-select-multiple-group__dropdown sd-select-option-group') || []);
1352
- const currentItem = optionElements?.[this.itemIndex];
1353
- if (!currentItem || !this.isOpen)
1354
- return;
1355
- this.optionRef = currentItem;
1356
- const isOptionDisabled = await this.optionRef.isDisabled();
1357
- if (isOptionDisabled) {
1358
- newIndex > oldIndex ? this.itemIndex++ : this.itemIndex--;
1359
- return;
1360
- }
1361
- this.scrollToOption(currentItem);
1573
+ });
1574
+ this.observeParent();
1362
1575
  }
1363
- async isOpenChanged() {
1364
- // Base class의 이벤트 관리 호출 - 다른 select와의 이벤트 충돌 방지
1365
- this.onDropdownToggle(this.isOpen);
1366
- const selectedOption = this.getSelectedOption();
1367
- if (!selectedOption) {
1368
- this.itemIndex = -1;
1576
+ componentDidRender() {
1577
+ if (!this.wrapper)
1578
+ return;
1579
+ // this.wrapper.style.display = this.open ? 'block' : 'none';
1580
+ // if (this.open) this.updatePosition();
1581
+ if (this.open) {
1582
+ this.wrapper.style.display = 'block';
1583
+ // RAF를 사용해서 다음 프레임에 위치 업데이트
1584
+ requestAnimationFrame(() => {
1585
+ this.updatePosition();
1586
+ if (this.wrapper) {
1587
+ this.wrapper.style.visibility = 'visible';
1588
+ }
1589
+ });
1369
1590
  }
1370
1591
  else {
1371
- this.itemIndex = this.options.indexOf(selectedOption[0]);
1372
- }
1373
- this.dropDownShow?.emit({ isOpen: this.isOpen });
1374
- if (this.isOpen === false)
1375
- return;
1376
- await new Promise(resolve => setTimeout(resolve, 10));
1377
- const optionElements = Array.from(this.dropdownRef?.querySelectorAll('.sd-select-multiple__dropdown sd-select-item') || []);
1378
- const currentItem = optionElements?.[this.itemIndex];
1379
- // 드롭다운이 열릴 때 검색 입력에 포커스
1380
- if (this.searchable) {
1381
- const searchInput = await this.getNativeInputElement();
1382
- searchInput?.focus();
1592
+ this.wrapper.style.display = 'none';
1593
+ this.wrapper.style.visibility = 'hidden';
1383
1594
  }
1384
- if (!currentItem)
1385
- return;
1386
- await new Promise(resolve => setTimeout(resolve, 10)); // 추가 딜레이
1387
- this.scrollToOption(currentItem);
1388
- }
1389
- componentWillLoad() {
1390
- // props가 모두 설정된 후에 실행되므로 올바른 options 값을 가져올 수 있음
1391
- this.filteredOptions = this.options;
1392
- this.initializeEvent(); // global dropdown Manager에 등록 + 이벤트 핸들러 초기화
1393
1595
  }
1394
1596
  disconnectedCallback() {
1395
- this.cleanupEvent(); // global dropdown Manager에서 제거 + 이벤트 정리
1396
- }
1397
- handleDocumentClick(event) {
1398
- if (!this.selectRef?.contains(event.target)) {
1399
- this.isOpen = false;
1400
- }
1597
+ if (this.rafId)
1598
+ cancelAnimationFrame(this.rafId);
1599
+ this.unobserveParent();
1600
+ this.wrapper?.remove();
1401
1601
  }
1402
- handleDocumentKeydown(keyboardEvent) {
1403
- keyboardEvent.stopPropagation();
1404
- const targetKey = ['ArrowDown', 'ArrowUp', 'Enter', 'Escape'];
1405
- if (!targetKey.includes(keyboardEvent.key))
1406
- return;
1407
- keyboardEvent.preventDefault();
1408
- switch (keyboardEvent.key) {
1409
- case 'ArrowDown':
1410
- case 'ArrowUp':
1411
- const keyboardNavigation = new SelectKeyboardNavigation(this.searchable, this.filteredOptions);
1412
- const nextIndex = keyboardNavigation.getNextIndex(this.itemIndex, keyboardEvent.key);
1413
- this.itemIndex = nextIndex;
1414
- break;
1415
- case 'Enter':
1416
- const selectedOption = this.filteredOptions[this.itemIndex];
1417
- if (selectedOption && !selectedOption.disabled) {
1418
- this.handleOptionSelection(selectedOption);
1419
- }
1420
- break;
1421
- case 'Escape':
1422
- this.isOpen = false;
1423
- break;
1424
- }
1602
+ resolveContainer() {
1603
+ const el = typeof this.to === 'string' ? document.querySelector(this.to) : this.to;
1604
+ return el instanceof HTMLElement ? el : document.body;
1425
1605
  }
1426
- // event handlers
1427
- handleTriggerClick = (event) => {
1428
- event.stopPropagation();
1429
- if (!this.disabled) {
1430
- this.isOpen = !this.isOpen;
1431
- this.dropDownShow?.emit({ isOpen: this.isOpen });
1432
- }
1433
- };
1434
- handleOptionClick = (detail) => {
1435
- const { option, event } = detail;
1436
- event.stopPropagation();
1437
- if (option.type === 'group')
1438
- this.handleGroupOptionClick(detail);
1439
- if (option.type === 'subgroup')
1440
- this.handleSubGroupOptionClick(detail);
1441
- if (option.type === 'item')
1442
- this.handleOptionSelection(option);
1443
- };
1444
- handleGroupOptionClick = (detail) => {
1445
- const { option, isSelected } = detail;
1446
- const childOptions = this.filteredOptions.filter(opt => opt.parent === option.value && !opt.disabled);
1447
- childOptions.forEach(subgroup => {
1448
- this.handleSubGroupOptionClick({
1449
- option: subgroup,
1450
- isSelected: isSelected || isSelected === null,
1451
- });
1606
+ createWrapper() {
1607
+ this.wrapper = document.createElement('div');
1608
+ Object.assign(this.wrapper.style, {
1609
+ position: 'absolute',
1610
+ zIndex: this.zIndex.toString(),
1611
+ transition: 'opacity 0.4s',
1612
+ top: '-9999px',
1613
+ left: '-9999px',
1452
1614
  });
1453
- };
1454
- handleSubGroupOptionClick = (detail) => {
1455
- const { option, isSelected } = detail;
1456
- const childOptions = this.filteredOptions.filter(opt => opt.parent === option.value && !opt.disabled);
1457
- if (isSelected || isSelected === null) {
1458
- // 모든 자식 옵션이 선택된 경우, 모두 선택 해제
1459
- this.value =
1460
- this.value?.filter(selected => !childOptions.some(child => child.value === selected.value)) ||
1461
- null;
1462
- }
1463
- else {
1464
- // 일부 또는 전체 자식 옵션이 선택되지 않은 경우, 모두 선택
1465
- const newSelections = childOptions.filter(child => !this.value?.some(selected => selected.value === child.value));
1466
- this.value = [...(this.value || []), ...newSelections];
1467
- }
1468
- };
1469
- filterOptions() {
1470
- if (!this.searchText || this.searchText.trim() === '') {
1471
- // 검색어가 없으면 전체 옵션 표시
1472
- this.filteredOptions = this.options;
1615
+ this.container.appendChild(this.wrapper);
1616
+ }
1617
+ moveSlotContent() {
1618
+ if (!this.wrapper)
1473
1619
  return;
1474
- }
1475
- const searchTerm = this.searchText.toLowerCase();
1476
- const matchedOptions = new Set();
1477
- // 1. 직접 매칭되는 옵션들 찾기
1478
- this.options.forEach(option => {
1479
- if (option.label.toLowerCase().includes(searchTerm)) {
1480
- matchedOptions.add(option);
1481
- // 매칭된 옵션의 상위 그룹들도 포함
1482
- this.addParentGroups(option, matchedOptions);
1620
+ const nodes = Array.from(this.el.childNodes).filter(n => n.nodeType !== Node.COMMENT_NODE);
1621
+ nodes.forEach(n => this.wrapper.appendChild(n));
1622
+ }
1623
+ // 위치 갱신 (scroll / resize)
1624
+ updatePosition() {
1625
+ if (this.rafId)
1626
+ cancelAnimationFrame(this.rafId);
1627
+ this.rafId = requestAnimationFrame(() => {
1628
+ if (!this.parentRef || !this.wrapper)
1629
+ return;
1630
+ const rect = this.parentRef.getBoundingClientRect();
1631
+ if (!rect.width && !rect.height)
1632
+ return; // 요소가 보이지 않는 경우
1633
+ const [offsetX, offsetY] = this.offset;
1634
+ const ARROW_SIZE = SdTooltipPortal.ARROW_SIZE;
1635
+ let top = 0;
1636
+ let left = 0;
1637
+ switch (this.placement) {
1638
+ case 'top':
1639
+ top = rect.top + window.scrollY - this.wrapper.offsetHeight + offsetY - ARROW_SIZE;
1640
+ left = rect.left + window.scrollX + rect.width / 2 - this.wrapper.offsetWidth / 2 + offsetX;
1641
+ break;
1642
+ case 'bottom':
1643
+ top = rect.bottom + window.scrollY + offsetY + ARROW_SIZE;
1644
+ left = rect.left + window.scrollX + rect.width / 2 - this.wrapper.offsetWidth / 2 + offsetX;
1645
+ break;
1646
+ case 'left':
1647
+ top = rect.top + window.scrollY + rect.height / 2 - this.wrapper.offsetHeight / 2 + offsetY;
1648
+ left = rect.left + window.scrollX - this.wrapper.offsetWidth - offsetX - ARROW_SIZE;
1649
+ break;
1650
+ case 'right':
1651
+ top = rect.top + window.scrollY + rect.height / 2 - this.wrapper.offsetHeight / 2 + offsetY;
1652
+ left = rect.right + window.scrollX + offsetX + ARROW_SIZE;
1653
+ break;
1483
1654
  }
1655
+ Object.assign(this.wrapper.style, {
1656
+ top: `${top}px`,
1657
+ left: `${left}px`,
1658
+ });
1484
1659
  });
1485
- // 2. Set을 배열로 변환하고 원본 순서 유지
1486
- this.filteredOptions = this.options.filter(option => matchedOptions.has(option));
1487
1660
  }
1488
- addParentGroups(option, matchedSet) {
1489
- if (!option.parent)
1661
+ // parentRef의 이동 / 크기변경 감지
1662
+ observeParent() {
1663
+ if (!this.parentRef)
1490
1664
  return;
1491
- const parentOption = this.options.find(opt => opt.value === option.parent);
1492
- if (parentOption && !matchedSet.has(parentOption)) {
1493
- matchedSet.add(parentOption);
1494
- // 재귀적으로 상위 그룹들도 추가
1495
- this.addParentGroups(parentOption, matchedSet);
1496
- }
1665
+ this.resizeObserver = new ResizeObserver(() => this.updatePosition());
1666
+ this.resizeObserver.observe(this.parentRef);
1667
+ this.mutationObserver = new MutationObserver(() => this.updatePosition());
1668
+ this.mutationObserver.observe(document.body, {
1669
+ childList: true,
1670
+ subtree: true,
1671
+ });
1497
1672
  }
1498
- getSelectedOption() {
1499
- return this.options.filter(option => this.value?.includes(option));
1673
+ unobserveParent() {
1674
+ this.resizeObserver?.disconnect();
1675
+ this.mutationObserver?.disconnect();
1500
1676
  }
1501
- handleDropdownScroll = (event) => {
1502
- const target = event.target;
1503
- const scrollTop = target.scrollTop;
1504
- // 스크롤이 조금이라도 되면 그림자 표시
1505
- this.isScrolled = scrollTop > 0;
1506
- };
1507
- async getNativeInputElement() {
1508
- if (this.searchRef) {
1509
- return this.searchRef.getNativeElement();
1510
- }
1511
- return null;
1677
+ // 외부 클릭 감지
1678
+ handleMouseDown(e) {
1679
+ this.isInsideClick = !!(this.wrapper && this.wrapper.contains(e.target));
1512
1680
  }
1513
- handleOptionSelection = (option) => {
1514
- if (!option || option.disabled)
1681
+ handleWindowClick(e) {
1682
+ if (this.isInsideClick) {
1683
+ this.isInsideClick = false;
1515
1684
  return;
1516
- const isAlreadySelected = this.value?.some(opt => opt.value === option.value);
1517
- if (isAlreadySelected) {
1518
- // 이미 선택된 옵션인 경우, 선택 해제
1519
- this.value = this.value?.filter(opt => opt.value !== option.value) || null;
1520
- }
1521
- else {
1522
- // 새로운 옵션 선택
1523
- this.value = [...(this.value || []), option];
1524
- }
1525
- };
1526
- getAllItemsUnderOption(parentOption) {
1527
- const childOptions = this.filteredOptions.filter(option => option.parent === parentOption.value && !option.disabled);
1528
- if (parentOption.type === 'group') {
1529
- // Group - 모든 하위 item들을 수집
1530
- const subgroupOptions = childOptions.filter(option => option.type === 'subgroup');
1531
- const allItemsUnderGroup = [];
1532
- // subgroup 하위의 모든 item
1533
- subgroupOptions.forEach(subgroup => {
1534
- const itemsUnderSubgroup = this.filteredOptions.filter(option => option.parent === subgroup.value && option.type === 'item' && !option.disabled);
1535
- allItemsUnderGroup.push(...itemsUnderSubgroup);
1536
- });
1537
- // Group 바로 하위 item
1538
- const directItems = childOptions.filter(option => option.type === 'item');
1539
- allItemsUnderGroup.push(...directItems);
1540
- return allItemsUnderGroup;
1541
1685
  }
1542
- return childOptions.filter(option => option.type === 'item');
1543
- }
1544
- isAllChildrenSelected(groupOption) {
1545
- const allItems = this.getAllItemsUnderOption(groupOption);
1546
- if (allItems.length === 0)
1547
- return false;
1548
- const selectedItems = allItems.filter(item => this.value?.some(selected => selected.value === item.value));
1549
- if (selectedItems.length === allItems.length)
1550
- return true;
1551
- if (selectedItems.length > 0)
1552
- return null;
1553
- return false;
1554
- }
1555
- getChildrenOptions(parentOption) {
1556
- if (parentOption.type === 'group') {
1557
- const allItems = this.getAllItemsUnderOption(parentOption);
1558
- const selectedItems = allItems.filter(item => this.value?.some(selected => selected.value === item.value));
1559
- return {
1560
- selectedCount: selectedItems.length,
1561
- totalCount: allItems.length,
1562
- };
1563
- }
1564
- // Subgroup의 경우
1565
- const children = this.filteredOptions.filter(option => option.parent === parentOption.value);
1566
- return {
1567
- selectedCount: children.filter(child => this.value?.some(val => val.value === child.value))
1568
- .length,
1569
- totalCount: children.length,
1570
- };
1571
- }
1572
- closeDropdown() {
1573
- this.isOpen = false;
1574
- }
1575
- scrollToOption(optionElement) {
1576
- if (!this.dropdownRef || !optionElement)
1686
+ if (this.wrapper?.contains(e.target))
1577
1687
  return;
1578
- const dropdown = this.dropdownRef;
1579
- const optionTop = optionElement.offsetTop;
1580
- const optionHeight = optionElement.offsetHeight;
1581
- const dropdownScrollTop = dropdown.scrollTop;
1582
- const dropdownHeight = dropdown.clientHeight;
1583
- const searchContainer = dropdown.querySelector('.sd-select__search-container');
1584
- const searchOffset = searchContainer ? searchContainer.offsetHeight : 0;
1585
- const visibleTop = dropdownScrollTop + searchOffset;
1586
- const visibleBottom = dropdownScrollTop + dropdownHeight;
1587
- if (optionTop < visibleTop) {
1588
- dropdown.scrollTop = optionTop - searchOffset;
1589
- }
1590
- else if (optionTop + optionHeight > visibleBottom) {
1591
- dropdown.scrollTop = optionTop + optionHeight - dropdownHeight + searchOffset;
1592
- }
1593
- }
1594
- render() {
1595
- const style = {
1596
- '--select-width': this.width || '200px',
1597
- '--select-dropdown-height': this.dropdownHeight || '260px',
1598
- };
1599
- return (h(Host, { key: 'bb06ec5405f0d97d3f970c49370249f7a05e1996', style: style }, h("div", { key: '325998f7e153d28ecce995f836d4192dc4adfe65', class: {
1600
- 'sd-select-multiple-group': true,
1601
- 'sd-select-multiple-group--open': this.isOpen,
1602
- 'sd-select-multiple-group--disabled': this.disabled,
1603
- }, style: this.containerStyle, ref: el => (this.selectRef = el) }, this.renderLabel(this.label, this.labelStyle), h("div", { key: 'c228f012628ffb7dd4346789c356eff8f256c2da', class: "sd-select-multiple-group__container" }, this.renderTrigger(), this.renderDropdown()))));
1604
- }
1605
- renderLabel(label, labelStyle) {
1606
- if (!label)
1607
- return null;
1608
- return (h("label", { class: "sd-select-multiple-group__label", style: labelStyle }, label));
1609
- }
1610
- renderTrigger() {
1611
- const selectedOption = this.getSelectedOption();
1612
- return (h("div", { class: "sd-select-multiple-group__trigger", tabindex: this.disabled ? -1 : 0, onClick: this.handleTriggerClick, style: this.triggerStyle }, h("span", { class: "sd-select-multiple-group__value" }, !selectedOption
1613
- ? '선택'
1614
- : selectedOption.length
1615
- ? selectedOption.map(option => option.label).join(', ')
1616
- : this.placeholder), this.clearable && selectedOption?.length > 0 && !this.disabled && (h("sd-icon", { key: "close-icon", name: "close", size: 10, color: "#888", class: "sd-select-multiple-group__clear", onClick: event => {
1617
- event.stopPropagation();
1618
- this.value = null;
1619
- } })), h("sd-icon", { key: "arrow-icon", name: "arrowDown", color: "#888", class: {
1620
- 'sd-select-multiple-group__arrow': true,
1621
- 'sd-select-multiple-group__arrow--open': this.isOpen,
1622
- } })));
1623
- }
1624
- renderDropdown() {
1625
- const style = {
1626
- '--select-width': this.width || '200px',
1627
- '--select-dropdown-height': this.dropdownHeight || '260px',
1628
- };
1629
- if (this.isOpen === false)
1630
- return null;
1631
- return (h("sd-portal", { open: this.isOpen, parentRef: this.selectRef, onSdClose: this.closeDropdown }, h("div", { class: "sd-select-multiple-group__dropdown", style: { ...style, ...this.dropdownStyle }, onScroll: this.handleDropdownScroll, ref: el => (this.dropdownRef = el) }, this.searchable && (h("div", { class: {
1632
- 'sd-select-multiple-group__search-container': true,
1633
- 'sd-select-multiple-group__search-container--scrolled': this.isScrolled,
1634
- }, onClick: event => event.stopPropagation() }, h("sd-input", { ref: el => (this.searchRef = el), value: this.searchText, placeholder: "\uAC80\uC0C9", clearable: true, inputStyle: { 'padding-left': '8px' }, autofocus: true, onSdInput: event => {
1635
- this.searchText = String(event?.detail);
1636
- }, onSdFocus: () => {
1637
- this.itemIndex = -1;
1638
- }, onKeyDown: e => {
1639
- if (e.code === 'Enter')
1640
- e.stopPropagation();
1641
- } }, h("sd-icon", { name: "search", size: 16, color: "#737373", slot: "prefix" })))), this.filteredOptions.length > 0 ? (this.filteredOptions.map((option, index) => (h("slot", { name: `option-${option.value}` }, h("sd-select-option-group", { option: option, index: index, isSelected: option.type === 'item'
1642
- ? this.value?.some(selected => selected.value === option.value)
1643
- : this.isAllChildrenSelected(option), isFocused: index === this.itemIndex, optionStyle: this.optionStyle, onOptionClick: ({ detail, }) => {
1644
- if (option.type !== 'item' && !this.useCheckbox) {
1645
- return;
1646
- }
1647
- this.handleOptionClick(detail);
1648
- }, useCheckbox: this.useCheckbox, ...(option.type !== 'item' && { countInfo: this.getChildrenOptions(option) }) }))))) : (h("slot", { name: "option-placeholder" }, h("div", { class: 'sd-select-multiple-group__option-placeholder', style: this.optionStyle }, this.optionPlaceholder))))));
1649
- }
1650
- static get watchers() { return {
1651
- "value": ["valueChanged"],
1652
- "options": ["optionsChanged"],
1653
- "searchText": ["searchTextChanged"],
1654
- "itemIndex": ["itemIndexChanged"],
1655
- "isOpen": ["isOpenChanged"]
1656
- }; }
1657
- };
1658
- SdSelectMultipleGroup.style = sdSelectMultipleGroupCss;
1659
-
1660
- const sdSelectOptionCss = "sd-select-option{display:block;height:fit-content;line-height:0}sd-select-option .sd-select__option{display:flex;padding:4px 12px;font-size:12px;line-height:20px;cursor:pointer}sd-select-option .sd-select__option__checkbox-wrapper{display:flex;width:100%;column-gap:8px;align-items:center;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}sd-select-option .sd-select__option--focused{background-color:#e6f1ff}sd-select-option .sd-select__option--selected:not(:hover):not(.sd-select__option--use-checkbox),sd-select-option .sd-select__option--focused:not(:hover):not(.sd-select__option--use-checkbox){color:#0075ff;font-weight:700}sd-select-option .sd-select__option--disabled{color:#aaaaaa;cursor:not-allowed}sd-select-option .sd-select__option:hover:not(.sd-select__option--disabled){background-color:#0075ff;color:white}";
1661
-
1662
- const SdSelectOption = class {
1663
- constructor(hostRef) {
1664
- registerInstance(this, hostRef);
1665
- this.optionClick = createEvent(this, "optionClick");
1666
- }
1667
- get el() { return getElement(this); }
1668
- option;
1669
- index;
1670
- isSelected = false;
1671
- isFocused = false;
1672
- optionStyle;
1673
- disabled = false;
1674
- useCheckbox = false;
1675
- isHovered = false;
1676
- async isDisabled() {
1677
- return !!this.option.disabled;
1678
- }
1679
- optionClick;
1680
- handleClick = (event) => {
1681
- event.stopPropagation();
1682
- if (!this.option.disabled && !this.disabled) {
1683
- this.optionClick.emit({
1684
- option: this.option,
1685
- index: this.index,
1686
- event,
1687
- });
1688
- }
1689
- };
1690
- render() {
1691
- return (h(Host, { key: 'cb2d7b25a778f3ea56dd6aaa880dde5b3f109d92' }, h("div", { key: '5b954062fdfc0466bcbbad7c86eeb9ed62655cf9', class: {
1692
- 'sd-select__option': true,
1693
- 'sd-select__option--selected': this.isSelected,
1694
- 'sd-select__option--disabled': !!this.option.disabled,
1695
- 'sd-select__option--focused': this.isFocused,
1696
- 'sd-select__option--use-checkbox': this.useCheckbox,
1697
- }, onMouseEnter: () => (this.isHovered = true), onMouseLeave: () => (this.isHovered = false), style: this.optionStyle, "data-index": this.index, onClick: this.handleClick }, this.useCheckbox ? (h("div", { class: "sd-select__option__checkbox-wrapper" }, h("sd-checkbox", { checked: this.isSelected, disabled: this.option.disabled,
1698
- // checkboxStyle={
1699
- // !this.isSelected
1700
- // ? { borderColor: '#888' }
1701
- // : this.isHovered
1702
- // ? { borderColor: 'white' }
1703
- // : { borderColor: '#0075ff' }
1704
- // }
1705
- onClick: e => {
1706
- e.preventDefault();
1707
- this.handleClick(e);
1708
- } }), h("span", { class: "sd-select__option-label" }, this.option.label))) : (this.option.label))));
1709
- }
1710
- };
1711
- SdSelectOption.style = sdSelectOptionCss;
1712
-
1713
- const sdSelectOptionGroupCss = "sd-select-option-group{display:block;height:fit-content}sd-select-option-group .sd-select__option-group{display:flex;padding:4px 12px;padding-left:28px;font-size:12px;line-height:20px}sd-select-option-group .sd-select__option-group.sd-select__option-group--group:not(.sd-select__option-group--use-checkbox),sd-select-option-group .sd-select__option-group.sd-select__option-group--subgroup:not(.sd-select__option-group--use-checkbox){cursor:default}sd-select-option-group .sd-select__option-group.sd-select__option-group--group{padding-left:12px;background-color:#f5faff !important;color:#333333 !important;font-weight:700}sd-select-option-group .sd-select__option-group.sd-select__option-group--subgroup{padding-left:20px;background-color:#f9f9f9 !important;color:#333333 !important;font-weight:500}sd-select-option-group .sd-select__option-group sd-checkbox__bg{border-color:#888888}sd-select-option-group .sd-select__option-group__label-wrapper{display:flex;width:100%;column-gap:8px;align-items:center;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}sd-select-option-group .sd-select__option-group__label-wrapper sd-checkbox{flex-shrink:0}sd-select-option-group .sd-select__option-group__label-wrapper .sd-select__option-group-label{flex:0 1 auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}sd-select-option-group .sd-select__option-group__label-wrapper .sd-select__option-group__count-indicator{width:fit-content;flex-shrink:0;font-size:12px;font-weight:500;color:#888888}sd-select-option-group .sd-select__option-group--focused{background-color:#e6f1ff}sd-select-option-group .sd-select__option-group--selected.sd-select__option-group--item:not(:hover):not(.sd-select__option-group--use-checkbox),sd-select-option-group .sd-select__option-group--focused.sd-select__option-group--item:not(:hover):not(.sd-select__option-group--use-checkbox){color:#0075ff;font-weight:700}sd-select-option-group .sd-select__option-group--disabled{color:#aaaaaa;cursor:not-allowed}sd-select-option-group .sd-select__option-group:hover:not(.sd-select__option-group--disabled){background-color:#0075ff;color:white}sd-select-option-group .sd-select__option-group:hover.sd-select__option-group--selected.sd-select__option-group--item sd-checkbox .sd-checkbox__bg{border-color:white !important}";
1714
-
1715
- const SdSelectOptionGroup = class {
1716
- constructor(hostRef) {
1717
- registerInstance(this, hostRef);
1718
- this.optionClick = createEvent(this, "optionClick");
1719
- }
1720
- get el() { return getElement(this); }
1721
- option;
1722
- index;
1723
- isSelected = false;
1724
- isFocused = false;
1725
- optionStyle;
1726
- disabled = false;
1727
- useCheckbox = false;
1728
- useIndicator = true;
1729
- countInfo = {
1730
- selectedCount: 0,
1731
- totalCount: 0,
1732
- };
1733
- isHovered = false;
1734
- async isDisabled() {
1735
- return !!this.option.disabled || this.option.type === 'group' || this.option.type === 'subgroup';
1688
+ this.sdClose.emit();
1736
1689
  }
1737
- optionClick;
1738
- handleClick = (option, isSelected, event) => {
1739
- event.stopPropagation();
1740
- if (option.type === 'group' || option.type === 'subgroup') {
1741
- this.optionClick.emit({
1742
- option: this.option,
1743
- isSelected,
1744
- index: this.index,
1745
- event,
1746
- });
1747
- return;
1748
- }
1749
- if (!this.option.disabled && !this.disabled) {
1750
- this.optionClick.emit({
1751
- option: this.option,
1752
- isSelected,
1753
- index: this.index,
1754
- event,
1755
- });
1756
- }
1757
- };
1758
1690
  render() {
1759
- return (h("div", { key: '2761283354fd179a42c719d5e67a10b44c0c11bb', class: {
1760
- 'sd-select__option-group': true,
1761
- 'sd-select__option-group--selected': !!this.isSelected,
1762
- 'sd-select__option-group--disabled': !!this.option.disabled,
1763
- 'sd-select__option-group--focused': this.isFocused,
1764
- 'sd-select__option-group--use-checkbox': this.useCheckbox,
1765
- 'sd-select__option-group--group': this.option.type === 'group',
1766
- 'sd-select__option-group--subgroup': this.option.type === 'subgroup',
1767
- 'sd-select__option-group--item': this.option.type === 'item',
1768
- }, onMouseEnter: () => (this.isHovered = true), onMouseLeave: () => (this.isHovered = false), style: this.optionStyle, "data-index": this.index, onClick: event => this.handleClick(this.option, this.isSelected, event) }, h("div", { key: '5cd6f320711e866a18076040fb4de57b1626784f', class: "sd-select__option-group__label-wrapper" }, this.useCheckbox && (h("sd-checkbox", { key: 'bc76cef83da27c879dcd05bb5dbb370e10b18957', checked: this.isSelected, disabled: this.option.disabled, onClick: e => {
1769
- e.preventDefault();
1770
- this.handleClick(this.option, this.isSelected, e);
1771
- } })), h("span", { key: 'b768ea0c0a3385f00823b9743e7256c29d6d58fd', class: "sd-select__option-group-label" }, this.option.label), this.useIndicator && this.option.type !== 'item' && (h("span", { key: '63cf4fd18f904441f5d4b27d8e6e32fdeb1aba5a', class: "sd-select__option-group__count-indicator" }, `(${this.countInfo?.selectedCount}/${this.countInfo?.totalCount})`)))));
1691
+ return h("slot", { key: '641dacdeceb023695ced987731591783daa6b88e' });
1772
1692
  }
1773
1693
  };
1774
- SdSelectOptionGroup.style = sdSelectOptionGroupCss;
1775
1694
 
1776
- export { SdCheckbox as sd_checkbox, SdIcon as sd_icon, SdInput as sd_input, SdPortal as sd_portal, SdSelect as sd_select, SdSelectMultiple as sd_select_multiple, SdSelectMultipleGroup as sd_select_multiple_group, SdSelectOption as sd_select_option, SdSelectOptionGroup as sd_select_option_group };
1777
- //# sourceMappingURL=sd-checkbox.sd-icon.sd-input.sd-portal.sd-select.sd-select-multiple.sd-select-multiple-group.sd-select-option.sd-select-option-group.entry.js.map
1695
+ export { SdButton as sd_button, SdCheckbox as sd_checkbox, SdGuide as sd_guide, SdIcon as sd_icon, SdInput as sd_input, SdPagination as sd_pagination, SdPortal as sd_portal, SdSelect as sd_select, SdSelectOption as sd_select_option, SdTable as sd_table, SdTooltip as sd_tooltip, SdTooltipPortal as sd_tooltip_portal };
1696
+ //# sourceMappingURL=sd-button.sd-checkbox.sd-guide.sd-icon.sd-input.sd-pagination.sd-portal.sd-select.sd-select-option.sd-table.sd-tooltip.sd-tooltip-portal.entry.js.map