@sellmate/design-system 1.0.63 → 1.0.65

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 (144) hide show
  1. package/dist/cjs/design-system.cjs.js +1 -1
  2. package/dist/cjs/index.cjs.js +2 -2
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/sd-action-modal.cjs.entry.js +12 -2
  5. package/dist/cjs/sd-barcode-input.cjs.entry.js +2 -1
  6. package/dist/cjs/sd-button_4.cjs.entry.js +14 -8
  7. package/dist/cjs/sd-date-picker.cjs.entry.js +3 -2
  8. package/dist/cjs/sd-date-range-picker.cjs.entry.js +3 -2
  9. package/dist/cjs/sd-file-picker.cjs.entry.js +2 -1
  10. package/dist/cjs/sd-input_2.cjs.entry.js +3 -2
  11. package/dist/cjs/sd-number-input.cjs.entry.js +4 -3
  12. package/dist/cjs/sd-pagination_2.cjs.entry.js +4 -3
  13. package/dist/cjs/sd-portal.cjs.entry.js +3 -3
  14. package/dist/cjs/sd-select-group.cjs.entry.js +2 -1
  15. package/dist/cjs/sd-select-multiple-group.cjs.entry.js +2 -1
  16. package/dist/cjs/sd-select-multiple.cjs.entry.js +2 -1
  17. package/dist/cjs/sd-select.cjs.entry.js +2 -1
  18. package/dist/cjs/sd-textarea.cjs.entry.js +2 -1
  19. package/dist/collection/components/sd-action-modal/sd-action-modal.css +4 -2
  20. package/dist/collection/components/sd-action-modal/sd-action-modal.js +49 -1
  21. package/dist/collection/components/sd-barcode-input/sd-barcode-input.js +22 -1
  22. package/dist/collection/components/sd-date-picker/sd-date-picker.js +23 -2
  23. package/dist/collection/components/sd-date-range-picker/sd-date-range-picker.js +23 -2
  24. package/dist/collection/components/sd-field/sd-field.css +7 -0
  25. package/dist/collection/components/sd-field/sd-field.js +30 -4
  26. package/dist/collection/components/sd-file-picker/sd-file-picker.js +22 -1
  27. package/dist/collection/components/sd-floating-portal/sd-floating-portal.js +4 -4
  28. package/dist/collection/components/sd-input/sd-input.js +23 -2
  29. package/dist/collection/components/sd-number-input/sd-number-input.js +24 -3
  30. package/dist/collection/components/sd-portal/sd-portal.js +4 -4
  31. package/dist/collection/components/sd-select/sd-select.js +22 -1
  32. package/dist/collection/components/sd-select-group/sd-select-group.js +22 -1
  33. package/dist/collection/components/sd-select-multiple/sd-select-multiple.js +22 -1
  34. package/dist/collection/components/sd-select-multiple-group/sd-select-multiple-group.js +22 -1
  35. package/dist/collection/components/sd-select-v2/sd-select-v2.js +24 -3
  36. package/dist/collection/components/sd-textarea/sd-textarea.js +22 -1
  37. package/dist/collection/utils/modal.js +2 -2
  38. package/dist/components/index.js +1 -1
  39. package/dist/components/{p-DUqX35W_.js → p-BH3z_vB9.js} +1 -1
  40. package/dist/components/{p-DgYBr7xb.js → p-CAeSM6Ov.js} +1 -1
  41. package/dist/components/{p-BZ7V5xV5.js → p-Cc7ZBscb.js} +1 -1
  42. package/dist/components/p-Cpg2hVm3.js +1 -0
  43. package/dist/components/p-DXtyg5eK.js +1 -0
  44. package/dist/components/p-HsTw_qYU.js +1 -0
  45. package/dist/components/p-fcZvjHk_.js +1 -0
  46. package/dist/components/p-h6zSUtA2.js +1 -0
  47. package/dist/components/sd-action-modal.js +1 -1
  48. package/dist/components/sd-barcode-input.js +1 -1
  49. package/dist/components/sd-date-picker.js +1 -1
  50. package/dist/components/sd-date-range-picker.js +1 -1
  51. package/dist/components/sd-dropdown-button.js +1 -1
  52. package/dist/components/sd-field.js +1 -1
  53. package/dist/components/sd-file-picker.js +1 -1
  54. package/dist/components/sd-floating-portal.js +1 -1
  55. package/dist/components/sd-guide.js +1 -1
  56. package/dist/components/sd-input.js +1 -1
  57. package/dist/components/sd-number-input.js +1 -1
  58. package/dist/components/sd-popover.js +1 -1
  59. package/dist/components/sd-portal.js +1 -1
  60. package/dist/components/sd-select-dropdown.js +1 -1
  61. package/dist/components/sd-select-group.js +1 -1
  62. package/dist/components/sd-select-multiple-group.js +1 -1
  63. package/dist/components/sd-select-multiple.js +1 -1
  64. package/dist/components/sd-select-search-input.js +1 -1
  65. package/dist/components/sd-select-v2.js +1 -1
  66. package/dist/components/sd-select.js +1 -1
  67. package/dist/components/sd-table.js +1 -1
  68. package/dist/components/sd-textarea.js +1 -1
  69. package/dist/components/sd-thead.js +1 -1
  70. package/dist/components/sd-tooltip.js +1 -1
  71. package/dist/design-system/design-system.esm.js +1 -1
  72. package/dist/design-system/index.esm.js +1 -1
  73. package/dist/design-system/p-010e4f47.entry.js +1 -0
  74. package/dist/design-system/p-05ce3449.entry.js +1 -0
  75. package/dist/design-system/p-2ae97b1c.entry.js +1 -0
  76. package/dist/design-system/p-6644c4a0.entry.js +1 -0
  77. package/dist/design-system/p-96b14db1.entry.js +1 -0
  78. package/dist/design-system/p-a983560d.entry.js +1 -0
  79. package/dist/design-system/p-b291a2f5.entry.js +1 -0
  80. package/dist/design-system/p-b3279f07.entry.js +1 -0
  81. package/dist/design-system/p-b81e0493.entry.js +1 -0
  82. package/dist/design-system/p-cf1156cb.entry.js +1 -0
  83. package/dist/design-system/p-d040ec6f.entry.js +1 -0
  84. package/dist/design-system/p-d8eb17a8.entry.js +1 -0
  85. package/dist/design-system/p-e5f71ec0.entry.js +1 -0
  86. package/dist/design-system/p-ed61fe19.entry.js +1 -0
  87. package/dist/design-system/p-f3d082c8.entry.js +1 -0
  88. package/dist/esm/design-system.js +1 -1
  89. package/dist/esm/index.js +2 -2
  90. package/dist/esm/loader.js +1 -1
  91. package/dist/esm/sd-action-modal.entry.js +12 -2
  92. package/dist/esm/sd-barcode-input.entry.js +2 -1
  93. package/dist/esm/sd-button_4.entry.js +14 -8
  94. package/dist/esm/sd-date-picker.entry.js +3 -2
  95. package/dist/esm/sd-date-range-picker.entry.js +3 -2
  96. package/dist/esm/sd-file-picker.entry.js +2 -1
  97. package/dist/esm/sd-input_2.entry.js +3 -2
  98. package/dist/esm/sd-number-input.entry.js +4 -3
  99. package/dist/esm/sd-pagination_2.entry.js +4 -3
  100. package/dist/esm/sd-portal.entry.js +3 -3
  101. package/dist/esm/sd-select-group.entry.js +2 -1
  102. package/dist/esm/sd-select-multiple-group.entry.js +2 -1
  103. package/dist/esm/sd-select-multiple.entry.js +2 -1
  104. package/dist/esm/sd-select.entry.js +2 -1
  105. package/dist/esm/sd-textarea.entry.js +2 -1
  106. package/dist/types/components/sd-action-modal/sd-action-modal.d.ts +2 -0
  107. package/dist/types/components/sd-barcode-input/sd-barcode-input.d.ts +1 -0
  108. package/dist/types/components/sd-date-picker/sd-date-picker.d.ts +1 -0
  109. package/dist/types/components/sd-date-range-picker/sd-date-range-picker.d.ts +1 -0
  110. package/dist/types/components/sd-field/sd-field.d.ts +1 -0
  111. package/dist/types/components/sd-file-picker/sd-file-picker.d.ts +1 -0
  112. package/dist/types/components/sd-input/sd-input.d.ts +1 -0
  113. package/dist/types/components/sd-modal-container/sd-modal-container.config.d.ts +1 -1
  114. package/dist/types/components/sd-number-input/sd-number-input.d.ts +1 -0
  115. package/dist/types/components/sd-select/sd-select.d.ts +1 -0
  116. package/dist/types/components/sd-select-group/sd-select-group.d.ts +1 -0
  117. package/dist/types/components/sd-select-multiple/sd-select-multiple.d.ts +1 -0
  118. package/dist/types/components/sd-select-multiple-group/sd-select-multiple-group.d.ts +1 -0
  119. package/dist/types/components/sd-select-v2/sd-select-v2.d.ts +1 -0
  120. package/dist/types/components/sd-textarea/sd-textarea.d.ts +1 -0
  121. package/dist/types/components.d.ts +127 -4
  122. package/hydrate/index.js +76 -33
  123. package/hydrate/index.mjs +76 -33
  124. package/package.json +1 -1
  125. package/dist/components/p-BgRPWxrz.js +0 -1
  126. package/dist/components/p-DxzgCf_d.js +0 -1
  127. package/dist/components/p-aC4HJHug.js +0 -1
  128. package/dist/components/p-e35Du7-7.js +0 -1
  129. package/dist/components/p-e8HA30H_.js +0 -1
  130. package/dist/design-system/p-0ca594a4.entry.js +0 -1
  131. package/dist/design-system/p-1b9e427e.entry.js +0 -1
  132. package/dist/design-system/p-1cbe4b22.entry.js +0 -1
  133. package/dist/design-system/p-1d310832.entry.js +0 -1
  134. package/dist/design-system/p-656acb07.entry.js +0 -1
  135. package/dist/design-system/p-748ece8e.entry.js +0 -1
  136. package/dist/design-system/p-9af7e19a.entry.js +0 -1
  137. package/dist/design-system/p-a24c3431.entry.js +0 -1
  138. package/dist/design-system/p-a9a91e69.entry.js +0 -1
  139. package/dist/design-system/p-c2f3470f.entry.js +0 -1
  140. package/dist/design-system/p-c98ed6ae.entry.js +0 -1
  141. package/dist/design-system/p-ca80379a.entry.js +0 -1
  142. package/dist/design-system/p-e9f24d23.entry.js +0 -1
  143. package/dist/design-system/p-ec79fefd.entry.js +0 -1
  144. package/dist/design-system/p-f3a60f61.entry.js +0 -1
package/hydrate/index.mjs CHANGED
@@ -5400,7 +5400,7 @@ const ACTION_MODAL_TITLE = {
5400
5400
  lineHeight: Number(action.title.typography.lineHeight),
5401
5401
  };
5402
5402
 
5403
- const sdActionModalCss = () => `sd-action-modal{display:block;width:fit-content;min-width:520px}sd-action-modal .sd-action-modal{position:relative;display:flex;flex-direction:column;border-radius:var(--sd-action-modal-radius);background:var(--sd-action-modal-bg);box-shadow:4px 4px 24px 4px rgba(0, 0, 0, 0.2);overflow:hidden}sd-action-modal .sd-action-modal__header{display:flex;align-items:center;gap:var(--sd-action-modal-header-gap);padding:var(--sd-action-modal-header-padding-y) calc(var(--sd-action-modal-header-padding-x) + 20px) var(--sd-action-modal-header-padding-y) var(--sd-action-modal-header-padding-x)}sd-action-modal .sd-action-modal__title{margin:0;color:var(--sd-action-modal-title-color);font-family:var(--sd-action-modal-title-font-family);font-weight:var(--sd-action-modal-title-font-weight);font-size:var(--sd-action-modal-title-font-size);line-height:var(--sd-action-modal-title-line-height);white-space:nowrap}sd-action-modal .sd-action-modal__header-sub{flex:1 1 auto;min-width:0;display:flex;align-items:center;gap:8px}sd-action-modal .sd-action-modal__header-sub:empty{display:none}sd-action-modal .sd-action-modal__close{position:absolute;top:16px;right:16px;cursor:pointer}sd-action-modal .sd-action-modal__body{flex:1 1 auto;min-height:0;padding:0 var(--sd-action-modal-body-padding-x) var(--sd-action-modal-body-padding-bottom);overflow:auto}sd-action-modal .sd-action-modal__footer{display:flex;align-items:center;gap:var(--sd-action-modal-footer-gap);padding:var(--sd-action-modal-footer-padding-y) var(--sd-action-modal-footer-padding-x);background:var(--sd-action-modal-footer-bg);border-top:1px solid var(--sd-action-modal-footer-border)}sd-action-modal .sd-action-modal__footer>sd-button-v2{margin-left:auto}sd-action-modal .sd-action-modal__footer-sub{display:flex;align-items:center;gap:8px;min-width:0}sd-action-modal .sd-action-modal__footer-sub:empty{display:none}`;
5403
+ const sdActionModalCss = () => `sd-action-modal{display:block}sd-action-modal .sd-action-modal{position:relative;display:flex;flex-direction:column;width:fit-content;min-width:520px;border-radius:var(--sd-action-modal-radius);background:var(--sd-action-modal-bg);box-shadow:4px 4px 24px 4px rgba(0, 0, 0, 0.2);overflow:hidden}sd-action-modal .sd-action-modal__header{display:flex;align-items:center;flex-shrink:0;gap:var(--sd-action-modal-header-gap);padding:var(--sd-action-modal-header-padding-y) calc(var(--sd-action-modal-header-padding-x) + 20px) var(--sd-action-modal-header-padding-y) var(--sd-action-modal-header-padding-x)}sd-action-modal .sd-action-modal__title{margin:0;color:var(--sd-action-modal-title-color);font-family:var(--sd-action-modal-title-font-family);font-weight:var(--sd-action-modal-title-font-weight);font-size:var(--sd-action-modal-title-font-size);line-height:var(--sd-action-modal-title-line-height);white-space:nowrap}sd-action-modal .sd-action-modal__header-sub{flex:1 1 auto;min-width:0;display:flex;align-items:center;gap:8px}sd-action-modal .sd-action-modal__header-sub:empty{display:none}sd-action-modal .sd-action-modal__close{position:absolute;top:16px;right:16px;cursor:pointer}sd-action-modal .sd-action-modal__body{flex:1 1 auto;min-height:0;padding:0 var(--sd-action-modal-body-padding-x) var(--sd-action-modal-body-padding-bottom);overflow:auto}sd-action-modal .sd-action-modal__footer{display:flex;align-items:center;flex-shrink:0;gap:var(--sd-action-modal-footer-gap);padding:var(--sd-action-modal-footer-padding-y) var(--sd-action-modal-footer-padding-x);background:var(--sd-action-modal-footer-bg);border-top:1px solid var(--sd-action-modal-footer-border)}sd-action-modal .sd-action-modal__footer>sd-button-v2{margin-left:auto}sd-action-modal .sd-action-modal__footer-sub{display:flex;align-items:center;gap:8px;min-width:0}sd-action-modal .sd-action-modal__footer-sub:empty{display:none}`;
5404
5404
 
5405
5405
  const DEFAULT_BUTTON_PROPS = {
5406
5406
  name: 'primary_md',
@@ -5414,6 +5414,8 @@ class SdActionModal {
5414
5414
  }
5415
5415
  modalTitle = '';
5416
5416
  buttonProps = {};
5417
+ width;
5418
+ height;
5417
5419
  close;
5418
5420
  ok;
5419
5421
  render() {
@@ -5436,7 +5438,15 @@ class SdActionModal {
5436
5438
  '--sd-action-modal-title-font-size': `${ACTION_MODAL_TITLE.fontSize}px`,
5437
5439
  '--sd-action-modal-title-line-height': `${ACTION_MODAL_TITLE.lineHeight}px`,
5438
5440
  };
5439
- return (hAsync("div", { key: 'b306dc102137e9b76faeeb19587dce32d670163c', class: "sd-action-modal", style: cssVars }, hAsync("header", { key: 'e6b9699e9943d1f4001b4cd23f99975474c3e86e', class: "sd-action-modal__header" }, hAsync("h2", { key: '4d30b98d01a191e4bdc3fb1ff772483dfd3a8397', class: "sd-action-modal__title" }, this.modalTitle), hAsync("div", { key: 'f1083fe5c2643d09dc4bad4c50064ffda2db65ab', class: "sd-action-modal__header-sub" }, hAsync("slot", { key: 'a11c9a13ae11569226ac11fb4be6b782667defeb', name: "header-sub-title" })), hAsync("sd-ghost-button", { key: 'e8a76ecd5d1388a79ac19705d634f40c05e6c2fc', class: "sd-action-modal__close", icon: "close", ariaLabel: "close", onClick: () => this.close.emit() })), hAsync("div", { key: 'eb615713a8fbfdd1c40c805e3146fc8341686c72', class: "sd-action-modal__body" }, hAsync("slot", { key: 'd56a3331bc2e94748f150c11dba9e5bd1fad8043', name: "body" })), hAsync("footer", { key: 'd80ad9de537846b01f79588e363bb40e76c64fba', class: "sd-action-modal__footer" }, hAsync("div", { key: '49187df32a64d18b2492995a80ce49df02e9303e', class: "sd-action-modal__footer-sub" }, hAsync("slot", { key: 'd73e66710152c0718d7cab6bbcbd1ab2cebf1f87', name: "bottom-sub-content" })), hAsync("sd-button-v2", { key: '03d2f2a0fa6960983c46e47460f623dfd42811a3', ...DEFAULT_BUTTON_PROPS, ...this.buttonProps, onSdClick: () => this.ok.emit() }))));
5441
+ const sizeStyle = {};
5442
+ if (this.width != null && this.width !== '') {
5443
+ sizeStyle.width = typeof this.width === 'number' ? `${this.width}px` : this.width;
5444
+ sizeStyle.minWidth = '0';
5445
+ }
5446
+ if (this.height != null && this.height !== '') {
5447
+ sizeStyle.height = typeof this.height === 'number' ? `${this.height}px` : this.height;
5448
+ }
5449
+ return (hAsync("div", { key: '566cba5061dbc13229ab2b51375cc4008f472343', class: "sd-action-modal", style: { ...cssVars, ...sizeStyle } }, hAsync("header", { key: 'fe396d5a90282deb3a9b42be4f451ee89648d20a', class: "sd-action-modal__header" }, hAsync("h2", { key: '7086fd3acf6be20d244f1c493d0f2669fb65dd01', class: "sd-action-modal__title" }, this.modalTitle), hAsync("div", { key: '90a7ae7d6a0a5c22921912e705ebfdee721e7e4a', class: "sd-action-modal__header-sub" }, hAsync("slot", { key: '74daa609d40f22dc825ea2a4a68e6d51d0db1f75', name: "header-sub-title" })), hAsync("sd-ghost-button", { key: '1d38b1374172f7a060ef3781079d301ae1fea84a', class: "sd-action-modal__close", icon: "close", ariaLabel: "close", onClick: () => this.close.emit() })), hAsync("div", { key: '657659d94d24581c6f33b8ab6d5dd74260cf22ad', class: "sd-action-modal__body" }, hAsync("slot", { key: '6f05c054e98537c43a78b72e14351092266933b2', name: "body" })), hAsync("footer", { key: 'dbd38be86c98e556039baa97ef2d84c48839e687', class: "sd-action-modal__footer" }, hAsync("div", { key: '268dfd29463453b9db4976145469f5045f2be16d', class: "sd-action-modal__footer-sub" }, hAsync("slot", { key: '38c76ecba8652c32807be076a898db75f87ea8f9', name: "bottom-sub-content" })), hAsync("sd-button-v2", { key: '5b4a651bbd35412b9b02bed7709d0bc27792811e', ...DEFAULT_BUTTON_PROPS, ...this.buttonProps, onSdClick: () => this.ok.emit() }))));
5440
5450
  }
5441
5451
  static get style() { return sdActionModalCss(); }
5442
5452
  static get cmpMeta() { return {
@@ -5444,7 +5454,9 @@ class SdActionModal {
5444
5454
  "$tagName$": "sd-action-modal",
5445
5455
  "$members$": {
5446
5456
  "modalTitle": [1, "modal-title"],
5447
- "buttonProps": [16]
5457
+ "buttonProps": [16],
5458
+ "width": [8],
5459
+ "height": [8]
5448
5460
  },
5449
5461
  "$listeners$": undefined,
5450
5462
  "$lazyBundleId$": "-",
@@ -5616,6 +5628,7 @@ class SdBarcodeInput {
5616
5628
  hovered = false;
5617
5629
  // props - label
5618
5630
  label = '';
5631
+ labelWidth = '';
5619
5632
  icon = undefined;
5620
5633
  labelTooltip = '';
5621
5634
  labelTooltipProps = null;
@@ -5694,7 +5707,7 @@ class SdBarcodeInput {
5694
5707
  '--sd-system-radius-field-sm': `${sizeTokens.radius}px`,
5695
5708
  '--sd-system-color-field-bg-default': BARCODE_INPUT_COLORS.bg.barcode,
5696
5709
  };
5697
- return (hAsync("sd-field", { key: 'ea17ae1c54890e57be4f582b3e993f370646b81a', name: this.name, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("label", { key: 'c96462ac8db261a31681744585a4f396b6561abb', class: "sd-barcode-input__content" }, hAsync("slot", { key: 'fde26b71059c79ef6911ab7a185bacda19b2800a', name: "prefix" }), hAsync("input", { key: 'a015944a0396a2fc3ab1c1ea401f79f25a260764', name: this.name, ref: el => (this.nativeEl = el), class: `sd-barcode-input__native ${this.inputClass}`, type: "text", value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, onInput: this.handleInput, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event), style: this.inputStyle }), hAsync("slot", { key: '45958b98d96ad527cfb9b59491e48e6f5c75e990', name: "suffix" }), this.clearable && this.internalValue && (hAsync("sd-ghost-button", { key: '7bf3f5e3ffcb35def3576e5f07d2af6392ce0c59', icon: "close", ariaLabel: "close", size: "xxs", disabled: this.disabled, class: "sd-barcode-input__clear-icon", onClick: async () => {
5710
+ return (hAsync("sd-field", { key: 'bba439856e0cbaedc7b54411dac904f9c845b50c', name: this.name, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("label", { key: '8553cfb4b5ef9535608abc1f2987ce08970c318a', class: "sd-barcode-input__content" }, hAsync("slot", { key: '93db2b38e8d674230f48e3b9496a7221d8477da6', name: "prefix" }), hAsync("input", { key: '30997bea593052322a2d29fc1e517b00cf19b1fb', name: this.name, ref: el => (this.nativeEl = el), class: `sd-barcode-input__native ${this.inputClass}`, type: "text", value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, onInput: this.handleInput, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event), style: this.inputStyle }), hAsync("slot", { key: '690daa6c1daa6058713ee09b0efe976557cde3ab', name: "suffix" }), this.clearable && this.internalValue && (hAsync("sd-ghost-button", { key: '8ab4e45a23d1b06dc415d969e25ed5ea59540643', icon: "close", ariaLabel: "close", size: "xxs", disabled: this.disabled, class: "sd-barcode-input__clear-icon", onClick: async () => {
5698
5711
  if (this.disabled)
5699
5712
  return;
5700
5713
  this.internalValue = '';
@@ -5732,6 +5745,7 @@ class SdBarcodeInput {
5732
5745
  "focused": [1028],
5733
5746
  "hovered": [1028],
5734
5747
  "label": [1],
5748
+ "labelWidth": [8, "label-width"],
5735
5749
  "icon": [16],
5736
5750
  "labelTooltip": [1, "label-tooltip"],
5737
5751
  "labelTooltipProps": [16],
@@ -7344,6 +7358,7 @@ class SdDatePicker {
7344
7358
  width = '';
7345
7359
  // sd-field 공통 props
7346
7360
  label = '';
7361
+ labelWidth = '';
7347
7362
  addonLabel = '';
7348
7363
  hint = '';
7349
7364
  errorMessage = '';
@@ -7423,9 +7438,9 @@ class SdDatePicker {
7423
7438
  '--sd-system-color-field-border-focus': DATEPICKER_COLORS.border.focus,
7424
7439
  '--sd-system-color-field-bg-default': DATEPICKER_COLORS.bg.default,
7425
7440
  };
7426
- return (hAsync("sd-field", { key: 'cfbaa89a7e07ff2d8994f3e8faa16bc55decce0f', name: this.fieldName || this.internalName, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: '674cc78bc3a3cda15a1cff07c36d0d5adbcfa2ef', class: "sd-date-picker", ref: el => {
7441
+ return (hAsync("sd-field", { key: '693c0c75e6b0a9ee8323f4be7ec101592e586372', name: this.fieldName || this.internalName, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: 'ea7f506f0163119fac0c660ef1bef5781780a118', class: "sd-date-picker", ref: el => {
7427
7442
  this.triggerRef = el;
7428
- } }, hAsync("sd-date-picker-trigger", { key: '1491cea4ff657631b3dc197fa39981c2c4df96c7', displayText: this.value ?? '', placeholder: this.placeholder, disabled: this.disabled, size: this.size, onSdTriggerClick: this.handleTriggerClick })), (this.isOpen || this.isAnimatingOut) && (hAsync("sd-portal", { key: '9a759a3470bc077a52efbd4718cf11f3b67ef477', open: this.isOpen, parentRef: this.triggerRef, onSdClose: () => this.closeDropdown() }, hAsync("sd-date-picker-calendar", { key: 'a14a447fbf28d95173eca5fae3baa73319c0bc37', value: this.value, selectable: this.selectable, onSdSelect: this.handleSelect, onSdViewChange: this.handleViewChange })))));
7443
+ } }, hAsync("sd-date-picker-trigger", { key: '0109eb0326655018bc02cc373e766ffdada85ff0', displayText: this.value ?? '', placeholder: this.placeholder, disabled: this.disabled, size: this.size, onSdTriggerClick: this.handleTriggerClick })), (this.isOpen || this.isAnimatingOut) && (hAsync("sd-portal", { key: '65a628af43ae036a752f3511341fd8c9c82303a1', open: this.isOpen, parentRef: this.triggerRef, onSdClose: () => this.closeDropdown() }, hAsync("sd-date-picker-calendar", { key: '21f574fc9551f9aaccfcb5d49a81952dbba72d7a', value: this.value, selectable: this.selectable, onSdSelect: this.handleSelect, onSdViewChange: this.handleViewChange })))));
7429
7444
  }
7430
7445
  static get watchers() { return {
7431
7446
  "isOpen": [{
@@ -7444,6 +7459,7 @@ class SdDatePicker {
7444
7459
  "disabled": [516],
7445
7460
  "width": [8],
7446
7461
  "label": [1],
7462
+ "labelWidth": [8, "label-width"],
7447
7463
  "addonLabel": [1, "addon-label"],
7448
7464
  "hint": [1],
7449
7465
  "errorMessage": [1, "error-message"],
@@ -7723,6 +7739,7 @@ class SdDateRangePicker {
7723
7739
  width = '';
7724
7740
  // sd-field 공통 props
7725
7741
  label = '';
7742
+ labelWidth = '';
7726
7743
  addonLabel = '';
7727
7744
  hint = '';
7728
7745
  errorMessage = '';
@@ -7807,9 +7824,9 @@ class SdDateRangePicker {
7807
7824
  '--sd-system-color-field-border-focus': DATEPICKER_COLORS.border.focus,
7808
7825
  '--sd-system-color-field-bg-default': DATEPICKER_COLORS.bg.default,
7809
7826
  };
7810
- return (hAsync("sd-field", { key: 'c3ce7e19d317939c193b6d1481b78ce599b0ffb1', name: this.fieldName || this.internalName, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: 'a3b48e2f79359620aabe01cfb32ac6a066acf567', class: "sd-date-range-picker", ref: el => {
7827
+ return (hAsync("sd-field", { key: '95ec666c91635d6b6b749d660b4495b7ebe48e6a', name: this.fieldName || this.internalName, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: '3051fda66e94d51208347ae2053173570d5f1ca9', class: "sd-date-range-picker", ref: el => {
7811
7828
  this.triggerRef = el;
7812
- } }, hAsync("sd-date-picker-trigger", { key: '3b2a963d29e93fe2ef82d1cd466ebd079c31ee30', displayText: this.displayText, placeholder: this.placeholder, disabled: this.disabled, size: this.size, onSdTriggerClick: this.handleTriggerClick })), (this.isOpen || this.isAnimatingOut) && (hAsync("sd-portal", { key: '5e51463ffdaf21c67a796b8a4418a287b48f7528', open: this.isOpen, parentRef: this.triggerRef, onSdClose: () => this.closeDropdown() }, hAsync("sd-date-range-picker-calendar", { key: '820176f7e03e9aab97e8b1f7752a535385918e46', value: this.value, selectable: this.selectable, maxRange: this.maxRange, onSdSelect: this.handleSelect, onSdViewChange: this.handleViewChange })))));
7829
+ } }, hAsync("sd-date-picker-trigger", { key: '71693b5a4cec562169d9427a4e19aed4d8b19a45', displayText: this.displayText, placeholder: this.placeholder, disabled: this.disabled, size: this.size, onSdTriggerClick: this.handleTriggerClick })), (this.isOpen || this.isAnimatingOut) && (hAsync("sd-portal", { key: '75b9f1c1ebdabcd1c1a33cad51189ba132274bb1', open: this.isOpen, parentRef: this.triggerRef, onSdClose: () => this.closeDropdown() }, hAsync("sd-date-range-picker-calendar", { key: 'f158eead4f44bc452bf102b3324721df84fc3b0c', value: this.value, selectable: this.selectable, maxRange: this.maxRange, onSdSelect: this.handleSelect, onSdViewChange: this.handleViewChange })))));
7813
7830
  }
7814
7831
  static get watchers() { return {
7815
7832
  "isOpen": [{
@@ -7829,6 +7846,7 @@ class SdDateRangePicker {
7829
7846
  "disabled": [516],
7830
7847
  "width": [8],
7831
7848
  "label": [1],
7849
+ "labelWidth": [8, "label-width"],
7832
7850
  "addonLabel": [1, "addon-label"],
7833
7851
  "hint": [1],
7834
7852
  "errorMessage": [1, "error-message"],
@@ -8567,7 +8585,7 @@ const FIELD_LABEL_SIZE_MAP = {
8567
8585
  },
8568
8586
  };
8569
8587
 
8570
- const sdFieldCss = () => `sd-field{display:inline-flex;flex-flow:column nowrap;height:fit-content;width:100%}sd-field .sd-field *:focus,sd-field .sd-field *:focus-visible,sd-field .sd-field *:focus-within{outline:none !important}sd-field .sd-field.sd-field--disabled{cursor:not-allowed}sd-field .sd-field.sd-field--disabled .sd-field__wrapper{cursor:not-allowed !important}sd-field .sd-field.sd-field--disabled .sd-field__wrapper .sd-field__label-inside{border-color:#CCCCCC;color:#888888;cursor:not-allowed !important}sd-field .sd-field.sd-field--disabled .sd-field__wrapper .sd-field__control{background-color:#E1E1E1;border-color:#CCCCCC;color:#888888;cursor:not-allowed !important}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label{display:flex;align-items:center;height:var(--sd-field-label-height);margin-right:var(--sd-field-label-margin-right)}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__icon{margin-right:var(--sd-field-label-gap)}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__text{font-size:var(--sd-field-label-font-size);line-height:var(--sd-field-label-line-height);font-weight:var(--sd-field-label-font-weight);color:var(--sd-system-color-field-text-default);white-space:nowrap}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__tooltip{margin-left:var(--sd-field-label-gap)}sd-field .sd-field--has-addon .sd-field__control .sd-field__addon{display:flex;gap:var(--sd-field-addon-gap);align-items:center;white-space:nowrap;padding:0 var(--sd-field-addon-padding-x);font-size:var(--sd-field-addon-font-size);line-height:var(--sd-field-addon-line-height);font-weight:var(--sd-field-addon-font-weight);background:var(--sd-field-addon-bg);border-right:var(--sd-field-addon-border-width) solid var(--sd-field-addon-border-color);border-radius:calc(var(--sd-field-control-radius) - 1px) 0 0 calc(var(--sd-field-control-radius) - 1px)}sd-field .sd-field__wrapper{width:100%;display:flex;align-items:flex-start;flex-flow:row nowrap;position:relative;color:var(--sd-system-color-field-text-default);-webkit-user-select:none;user-select:none}sd-field .sd-field__wrapper .sd-field__main{flex:1;min-width:0;display:flex;flex-direction:column}sd-field .sd-field__wrapper .sd-field__control{position:relative;height:var(--sd-field-wrapper-height);display:flex;min-width:0;border:1px solid var(--sd-system-color-field-border-default);border-radius:var(--sd-field-control-radius);background:var(--sd-system-color-field-bg-default)}sd-field .sd-field--error .sd-field__wrapper .sd-field__control:not(:hover){border:1px solid var(--sd-system-color-field-border-danger) !important}sd-field .sd-field.sd-field--pass .sd-field__wrapper .sd-field__control{border:1px solid var(--sd-system-color-field-border-success) !important}sd-field .sd-field:not(.sd-field--disabled) .sd-field__wrapper .sd-field__control:hover{border:1px solid var(--sd-system-color-field-border-focus) !important;box-shadow:0px 0px 4px 0px rgba(0, 113, 255, 0.4)}sd-field .sd-field.sd-field--focus .sd-field__wrapper .sd-field__control{border:1px solid var(--sd-system-color-field-border-focus) !important;box-shadow:0px 0px 4px 0px rgba(0, 113, 255, 0.4)}sd-field .sd-field .sd-field__error-message{color:var(--sd-textinput-textinput-text-error-message);font-size:var(--sd-textinput-textinput-error-message-typography-font-size);line-height:var(--sd-textinput-textinput-error-message-typography-line-height);margin-top:var(--sd-textinput-textinput-contents-gap)}sd-field .sd-field .sd-field__hint{color:var(--sd-textinput-textinput-text-hint);font-size:var(--sd-textinput-textinput-hint-typography-font-size);line-height:var(--sd-textinput-textinput-hint-typography-line-height);margin-top:var(--sd-textinput-textinput-contents-gap)}`;
8588
+ const sdFieldCss = () => `sd-field{display:inline-flex;flex-flow:column nowrap;height:fit-content;width:100%}sd-field .sd-field *:focus,sd-field .sd-field *:focus-visible,sd-field .sd-field *:focus-within{outline:none !important}sd-field .sd-field.sd-field--disabled{cursor:not-allowed}sd-field .sd-field.sd-field--disabled .sd-field__wrapper{cursor:not-allowed !important}sd-field .sd-field.sd-field--disabled .sd-field__wrapper .sd-field__label-inside{border-color:#CCCCCC;color:#888888;cursor:not-allowed !important}sd-field .sd-field.sd-field--disabled .sd-field__wrapper .sd-field__control{background-color:#E1E1E1;border-color:#CCCCCC;color:#888888;cursor:not-allowed !important}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label{display:flex;align-items:center;flex-shrink:0;width:var(--sd-field-label-width, auto);height:var(--sd-field-label-height);margin-right:var(--sd-field-label-margin-right)}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__icon{margin-right:var(--sd-field-label-gap);flex-shrink:0}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__text{font-size:var(--sd-field-label-font-size);line-height:var(--sd-field-label-line-height);font-weight:var(--sd-field-label-font-weight);color:var(--sd-system-color-field-text-default);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__tooltip{margin-left:var(--sd-field-label-gap);flex-shrink:0}sd-field .sd-field--has-addon .sd-field__control .sd-field__addon{display:flex;gap:var(--sd-field-addon-gap);align-items:center;white-space:nowrap;padding:0 var(--sd-field-addon-padding-x);font-size:var(--sd-field-addon-font-size);line-height:var(--sd-field-addon-line-height);font-weight:var(--sd-field-addon-font-weight);background:var(--sd-field-addon-bg);border-right:var(--sd-field-addon-border-width) solid var(--sd-field-addon-border-color);border-radius:calc(var(--sd-field-control-radius) - 1px) 0 0 calc(var(--sd-field-control-radius) - 1px)}sd-field .sd-field__wrapper{width:100%;display:flex;align-items:flex-start;flex-flow:row nowrap;position:relative;color:var(--sd-system-color-field-text-default);-webkit-user-select:none;user-select:none}sd-field .sd-field__wrapper .sd-field__main{flex:1;min-width:0;display:flex;flex-direction:column}sd-field .sd-field__wrapper .sd-field__control{position:relative;height:var(--sd-field-wrapper-height);display:flex;min-width:0;border:1px solid var(--sd-system-color-field-border-default);border-radius:var(--sd-field-control-radius);background:var(--sd-system-color-field-bg-default)}sd-field .sd-field--error .sd-field__wrapper .sd-field__control:not(:hover){border:1px solid var(--sd-system-color-field-border-danger) !important}sd-field .sd-field.sd-field--pass .sd-field__wrapper .sd-field__control{border:1px solid var(--sd-system-color-field-border-success) !important}sd-field .sd-field:not(.sd-field--disabled) .sd-field__wrapper .sd-field__control:hover{border:1px solid var(--sd-system-color-field-border-focus) !important;box-shadow:0px 0px 4px 0px rgba(0, 113, 255, 0.4)}sd-field .sd-field.sd-field--focus .sd-field__wrapper .sd-field__control{border:1px solid var(--sd-system-color-field-border-focus) !important;box-shadow:0px 0px 4px 0px rgba(0, 113, 255, 0.4)}sd-field .sd-field .sd-field__error-message{color:var(--sd-textinput-textinput-text-error-message);font-size:var(--sd-textinput-textinput-error-message-typography-font-size);line-height:var(--sd-textinput-textinput-error-message-typography-line-height);margin-top:var(--sd-textinput-textinput-contents-gap)}sd-field .sd-field .sd-field__hint{color:var(--sd-textinput-textinput-text-hint);font-size:var(--sd-textinput-textinput-hint-typography-font-size);line-height:var(--sd-textinput-textinput-hint-typography-line-height);margin-top:var(--sd-textinput-textinput-contents-gap)}`;
8571
8589
 
8572
8590
  const FORM_PARENT_TAGS = [
8573
8591
  'sd-select',
@@ -8600,6 +8618,7 @@ class SdField {
8600
8618
  size = 'sm';
8601
8619
  // props - label
8602
8620
  label = '';
8621
+ labelWidth = '';
8603
8622
  addonLabel = '';
8604
8623
  icon = undefined;
8605
8624
  labelTooltip = '';
@@ -8712,6 +8731,11 @@ class SdField {
8712
8731
  '--sd-field-label-font-size': `${labelTokens.fontSize}px`,
8713
8732
  '--sd-field-label-line-height': `${labelTokens.lineHeight}px`,
8714
8733
  '--sd-field-label-font-weight': labelTokens.fontWeight,
8734
+ ...(this.labelWidth
8735
+ ? {
8736
+ '--sd-field-label-width': typeof this.labelWidth === 'number' ? `${this.labelWidth}px` : this.labelWidth,
8737
+ }
8738
+ : {}),
8715
8739
  }
8716
8740
  : {};
8717
8741
  const addonCssVars = addon
@@ -8728,20 +8752,20 @@ class SdField {
8728
8752
  '--sd-field-addon-border-width': `${addonTokens.border.width}px`,
8729
8753
  }
8730
8754
  : {};
8731
- return (hAsync("div", { key: '72ffdb42c88b90eb60637b10c1330dc509ece812', class: {
8755
+ return (hAsync("div", { key: 'f12b2e13ac8152d1e688f903a60a8fa670e99065', class: {
8732
8756
  'sd-field': true,
8733
8757
  'sd-field--has-label': !!this.label,
8734
8758
  'sd-field--has-addon': !!addon,
8735
8759
  [this.fieldStatus]: !!this.fieldStatus,
8736
- }, style: { ...sizeCssVars, ...labelCssVars, ...addonCssVars } }, hAsync("div", { key: 'fb5d90aea5a4988ec58984b4a85ed609f032549e', class: "sd-field__wrapper" }, this.renderLabel(this.label), hAsync("div", { key: 'c0372be3a39ca1d6cebfe5e765d120751e39d03e', class: "sd-field__main", style: this.width
8760
+ }, style: { ...sizeCssVars, ...labelCssVars, ...addonCssVars } }, hAsync("div", { key: '79f7a40b5e1ee95bb9075b0855e22261cd8adc6a', class: "sd-field__wrapper" }, this.renderLabel(this.label), hAsync("div", { key: '54b5bbfbe18df48c40cc30ec3d6761ccd8e446cc', class: "sd-field__main", style: this.width
8737
8761
  ? {
8738
8762
  width: typeof this.width === 'number' ? `${this.width}px` : this.width,
8739
8763
  flex: 'none',
8740
8764
  }
8741
- : {} }, hAsync("div", { key: 'd203154db0eef4e73908d78ba3667710c51b6595', class: {
8765
+ : {} }, hAsync("div", { key: '39542908287175ade4d6e0f1acd2cb1f03c9e2a1', class: {
8742
8766
  'sd-field__control': true,
8743
8767
  'sd-field__control--has-addon': !!addon,
8744
- } }, addon && hAsync("div", { key: '851b996010c4f0402df8b6bfe9ced0c8444bc591', class: "sd-field__addon" }, addon), hAsync("slot", { key: '081b95a99090c3c1d2d28170500ac7be15452876' })), this.errorMsg || this.errorMessage ? (hAsync("div", { class: "sd-field__error-message" }, this.errorMsg || this.errorMessage)) : (this.hint && hAsync("div", { class: "sd-field__hint" }, this.hint))))));
8768
+ } }, addon && hAsync("div", { key: '236650de53d1d1951f26586aa0d22f0f267fc411', class: "sd-field__addon" }, addon), hAsync("slot", { key: '41df3dca21aa68d3324617891f2555f1c488a61b' })), this.errorMsg || this.errorMessage ? (hAsync("div", { class: "sd-field__error-message" }, this.errorMsg || this.errorMessage)) : (this.hint && hAsync("div", { class: "sd-field__hint" }, this.hint))))));
8745
8769
  }
8746
8770
  renderLabel(label) {
8747
8771
  if (!label)
@@ -8765,6 +8789,7 @@ class SdField {
8765
8789
  "width": [8],
8766
8790
  "size": [513],
8767
8791
  "label": [1],
8792
+ "labelWidth": [8, "label-width"],
8768
8793
  "addonLabel": [1, "addon-label"],
8769
8794
  "icon": [16],
8770
8795
  "labelTooltip": [1, "label-tooltip"],
@@ -8845,6 +8870,7 @@ class SdFilePicker {
8845
8870
  // sd-field 패스스루 props
8846
8871
  name = '';
8847
8872
  label = '';
8873
+ labelWidth = '';
8848
8874
  addonLabel = '';
8849
8875
  hint = '';
8850
8876
  errorMessage = '';
@@ -9007,7 +9033,7 @@ class SdFilePicker {
9007
9033
  'sd-file-picker--inline-disabled': this.disabled,
9008
9034
  }, style: cssVars, onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false) }, content));
9009
9035
  }
9010
- return (hAsync("sd-field", { name: this.name, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, content));
9036
+ return (hAsync("sd-field", { name: this.name, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, content));
9011
9037
  }
9012
9038
  static get watchers() { return {
9013
9039
  "value": [{
@@ -9030,6 +9056,7 @@ class SdFilePicker {
9030
9056
  "maxFiles": [8, "max-files"],
9031
9057
  "name": [1],
9032
9058
  "label": [1],
9059
+ "labelWidth": [8, "label-width"],
9033
9060
  "addonLabel": [1, "addon-label"],
9034
9061
  "hint": [1],
9035
9062
  "errorMessage": [1, "error-message"],
@@ -9065,7 +9092,7 @@ class SdFloatingPopover {
9065
9092
  to = 'body';
9066
9093
  parentRef = null;
9067
9094
  offset = [0, 0];
9068
- zIndex = 9999;
9095
+ zIndex = 10000;
9069
9096
  placement = 'bottom';
9070
9097
  open = false;
9071
9098
  close;
@@ -9123,7 +9150,7 @@ class SdFloatingPopover {
9123
9150
  this.wrapper = document.createElement('div');
9124
9151
  Object.assign(this.wrapper.style, {
9125
9152
  position: 'absolute',
9126
- zIndex: (this.zIndex ?? 9999).toString(),
9153
+ zIndex: (this.zIndex ?? 10000).toString(),
9127
9154
  transition: 'opacity 0.4s',
9128
9155
  top: '-9999px',
9129
9156
  left: '-9999px',
@@ -9205,7 +9232,7 @@ class SdFloatingPopover {
9205
9232
  this.close.emit();
9206
9233
  }
9207
9234
  render() {
9208
- return hAsync("slot", { key: '4f7cf13fe78e7d4e906a2cda47de4258d9ceda74' });
9235
+ return hAsync("slot", { key: '4dafb853b2a82e541f59056d2fedf08a6fa040ba' });
9209
9236
  }
9210
9237
  static get style() { return sdFloatingPortalCss(); }
9211
9238
  static get cmpMeta() { return {
@@ -10167,6 +10194,7 @@ class SdInput {
10167
10194
  hovered = false;
10168
10195
  // props - label
10169
10196
  label = '';
10197
+ labelWidth = '';
10170
10198
  icon = undefined;
10171
10199
  labelTooltip = '';
10172
10200
  labelTooltipProps = null;
@@ -10248,12 +10276,12 @@ class SdInput {
10248
10276
  '--sd-system-size-field-sm-height': `${sizeTokens.height}px`,
10249
10277
  '--sd-system-radius-field-sm': `${sizeTokens.radius}px`,
10250
10278
  };
10251
- return (hAsync("sd-field", { key: 'a96aaa54fe54c9d9ee5ab31537e1b6fb7b612c8f', name: this.name, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("label", { key: 'd806549d41156ab414d04664e6887075ef97f307', class: "sd-input__content" }, hAsync("slot", { key: '29f447128f6211792742a252d1ea087b5a5b413e', name: "prefix" }), hAsync("input", { key: 'e1870c7573268e97eac820d7508e134c13c32b40', name: this.name, ref: el => (this.nativeEl = el), class: `sd-input__native ${this.inputClass}`, type: this.type === 'password' && this.passwordVisible ? 'text' : this.type, value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, autocomplete: this.autocomplete || undefined, maxlength: this.maxlength, minlength: this.minlength, inputmode: this.inputmode, enterkeyhint: this.enterkeyhint, spellcheck: this.spellcheck, onInput: this.handleInput, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event), style: this.inputStyle }), hAsync("slot", { key: 'f12b87b5d30878a55e1224abf789b924c1fd3a0c', name: "suffix" }), this.clearable && this.internalValue && !this.disabled && (hAsync("sd-ghost-button", { key: 'dad4be5dc6e8239dedc094fe0eb02a2587dd9f9c', icon: "close", ariaLabel: "close", size: "xxs", disabled: this.disabled, class: "sd-input__clear-icon", onClick: async () => {
10279
+ return (hAsync("sd-field", { key: 'a72ce8674fb761de7cd188e99cc19d5f3731a899', name: this.name, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, size: this.size, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("label", { key: 'e5cbdbc2b233bda57488ead19401d277891301ae', class: "sd-input__content" }, hAsync("slot", { key: 'a327005770df94ef61f2e08071e77407a24b7b5c', name: "prefix" }), hAsync("input", { key: '36301cd586151b8c607e14715b26fca467f68c13', name: this.name, ref: el => (this.nativeEl = el), class: `sd-input__native ${this.inputClass}`, type: this.type === 'password' && this.passwordVisible ? 'text' : this.type, value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, autocomplete: this.autocomplete || undefined, maxlength: this.maxlength, minlength: this.minlength, inputmode: this.inputmode, enterkeyhint: this.enterkeyhint, spellcheck: this.spellcheck, onInput: this.handleInput, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event), style: this.inputStyle }), hAsync("slot", { key: '532e201860db0709572502aa4275fc9251e1aeb1', name: "suffix" }), this.clearable && this.internalValue && !this.disabled && (hAsync("sd-ghost-button", { key: 'cc6132852c65f0597cbe25751c7246b1cdad3096', icon: "close", ariaLabel: "close", size: "xxs", disabled: this.disabled, class: "sd-input__clear-icon", onClick: async () => {
10252
10280
  if (this.disabled)
10253
10281
  return;
10254
10282
  this.internalValue = '';
10255
10283
  await this.formField?.sdValidate();
10256
- } })), this.type === 'password' && (hAsync("sd-ghost-button", { key: '71c5cf7565ad13f08173fc10e828ddf5f8f546b8', icon: this.passwordVisible ? 'visibilityOn' : 'visibilityOff', ariaLabel: "visibility", size: "xxs", disabled: this.disabled, class: "sd-input__password-icon", onClick: () => {
10284
+ } })), this.type === 'password' && (hAsync("sd-ghost-button", { key: 'fd3d567346cf5771ec28c73f15cdf0db15835766', icon: this.passwordVisible ? 'visibilityOn' : 'visibilityOff', ariaLabel: "visibility", size: "xxs", disabled: this.disabled, class: "sd-input__password-icon", onClick: () => {
10257
10285
  if (this.disabled)
10258
10286
  return;
10259
10287
  this.passwordVisible = !this.passwordVisible;
@@ -10297,6 +10325,7 @@ class SdInput {
10297
10325
  "focused": [1028],
10298
10326
  "hovered": [1028],
10299
10327
  "label": [1],
10328
+ "labelWidth": [8, "label-width"],
10300
10329
  "icon": [16],
10301
10330
  "labelTooltip": [1, "label-tooltip"],
10302
10331
  "labelTooltipProps": [16],
@@ -10873,6 +10902,7 @@ class SdNumberInput {
10873
10902
  useDecimal = false;
10874
10903
  value = null;
10875
10904
  label;
10905
+ labelWidth = '';
10876
10906
  addonLabel = '';
10877
10907
  placeholder = '입력해 주세요.';
10878
10908
  disabled = false;
@@ -11132,12 +11162,12 @@ class SdNumberInput {
11132
11162
  '--sd-textinput-input-hint-typography-line-height': `${NUMBER_INPUT_HINT.typography.lineHeight}px`,
11133
11163
  '--sd-textinput-input-contents-gap': `${NUMBER_INPUT_CONTENTS_GAP}px`,
11134
11164
  };
11135
- return (hAsync("sd-field", { key: 'e05cc16f4dde4fd82d11a811b578723af2f5b092', name: this.name, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, size: this.size, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: 'db4f02b5f882acfe481698745ca374874643efbd', class: "sd-number-input__content" }, this.useButton && (hAsync("button", { key: 'c83df0e915849792427b2f3609937bb0b62aae15', type: "button", class: "sd-number-input__stepper sd-number-input__stepper--decrement", disabled: this.isDecrementDisabled(), onClick: this.handleDecrement, tabindex: -1 }, hAsync("sd-icon", { key: 'b7ea0704c9d114b5e1b8eca29a408efb5e532b7e', name: "minus", size: iconSize, color: this.isDecrementDisabled()
11165
+ return (hAsync("sd-field", { key: 'f81b01b27960130cbf6b37a29fc0ddc11750768e', name: this.name, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, size: this.size, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: '0f9b5a0b966c7d51d5913c61a585ff789fa4973f', class: "sd-number-input__content" }, this.useButton && (hAsync("button", { key: 'b037ee3062253bf229f9639dd04c7475657fabb6', type: "button", class: "sd-number-input__stepper sd-number-input__stepper--decrement", disabled: this.isDecrementDisabled(), onClick: this.handleDecrement, tabindex: -1 }, hAsync("sd-icon", { key: '39a9f73a15008a481e758e663e027cd4f6454146', name: "minus", size: iconSize, color: this.isDecrementDisabled()
11136
11166
  ? NUMBER_INPUT_STEPPER.icon.disabled
11137
- : NUMBER_INPUT_STEPPER.icon.default }))), this.inputPrefix && (hAsync("span", { key: '57ed4229c30d52b6925ebaccd816cd8496ab60c0', class: "sd-number-input__prefix" }, this.inputPrefix)), hAsync("input", { key: 'b018a810ca085218beb7acbba0187543c8369236', name: this.name, ref: el => (this.nativeEl = el), class: `sd-number-input__native ${this.inputClass}`, type: "text", inputMode: "numeric", value: this.displayValue, placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, onInput: this.handleInput, onKeyDown: this.handleKeyDown, onFocus: this.handleFocus, onBlur: this.handleBlur, style: {
11167
+ : NUMBER_INPUT_STEPPER.icon.default }))), this.inputPrefix && (hAsync("span", { key: '050334ce25bb767e7f11dca886d4aeecaa1ed3dc', class: "sd-number-input__prefix" }, this.inputPrefix)), hAsync("input", { key: 'a72697d136eeee52ef23fee6ee2017b6dd37e54c', name: this.name, ref: el => (this.nativeEl = el), class: `sd-number-input__native ${this.inputClass}`, type: "text", inputMode: "numeric", value: this.displayValue, placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, autofocus: this.autoFocus, onInput: this.handleInput, onKeyDown: this.handleKeyDown, onFocus: this.handleFocus, onBlur: this.handleBlur, style: {
11138
11168
  textAlign: this.useButton ? 'center' : 'right',
11139
11169
  ...this.inputStyle,
11140
- } }), this.inputSuffix && (hAsync("span", { key: '5db549a3cc81b98123cdec69b866b25d961f210f', class: "sd-number-input__suffix" }, this.inputSuffix)), this.useButton && (hAsync("button", { key: '8b0b8c4ba46cf1cc5fba21f7fa8c113ca215b265', type: "button", class: "sd-number-input__stepper sd-number-input__stepper--increment", disabled: this.isIncrementDisabled(), onClick: this.handleIncrement, tabindex: -1 }, hAsync("sd-icon", { key: '77012f79ba5a3a5550af844149bb35fa1e165533', name: "add", size: iconSize, color: this.isIncrementDisabled()
11170
+ } }), this.inputSuffix && (hAsync("span", { key: '845202622b3377add18782d96d0af0c49caf95ec', class: "sd-number-input__suffix" }, this.inputSuffix)), this.useButton && (hAsync("button", { key: '208c976c1b755bec0cd7efb5ceacb3e07dce3a7d', type: "button", class: "sd-number-input__stepper sd-number-input__stepper--increment", disabled: this.isIncrementDisabled(), onClick: this.handleIncrement, tabindex: -1 }, hAsync("sd-icon", { key: 'fe9848c8f044d01378dc183a80d3f81eb56a67f9', name: "add", size: iconSize, color: this.isIncrementDisabled()
11141
11171
  ? NUMBER_INPUT_STEPPER.icon.disabled
11142
11172
  : NUMBER_INPUT_STEPPER.icon.default }))))));
11143
11173
  }
@@ -11162,6 +11192,7 @@ class SdNumberInput {
11162
11192
  "useDecimal": [4, "use-decimal"],
11163
11193
  "value": [1032],
11164
11194
  "label": [1],
11195
+ "labelWidth": [8, "label-width"],
11165
11196
  "addonLabel": [1, "addon-label"],
11166
11197
  "placeholder": [1],
11167
11198
  "disabled": [4],
@@ -11397,7 +11428,7 @@ class SdPortal {
11397
11428
  parentRef = null;
11398
11429
  offset = [0, 4];
11399
11430
  viewportPadding = 0;
11400
- zIndex = 9999;
11431
+ zIndex = 10000;
11401
11432
  open = false;
11402
11433
  close;
11403
11434
  container;
@@ -11443,7 +11474,7 @@ class SdPortal {
11443
11474
  position: 'absolute',
11444
11475
  top: '0',
11445
11476
  left: '0',
11446
- zIndex: (this.zIndex ?? 9999).toString(),
11477
+ zIndex: (this.zIndex ?? 10000).toString(),
11447
11478
  opacity: '0',
11448
11479
  transition: 'opacity 0.15s ease-out',
11449
11480
  boxSizing: 'border-box',
@@ -11612,7 +11643,7 @@ class SdPortal {
11612
11643
  this.close.emit();
11613
11644
  }
11614
11645
  render() {
11615
- return hAsync("slot", { key: 'e9862350592ae8ea0741b4639a94e288f0b302f2' });
11646
+ return hAsync("slot", { key: '7213237baa73430dbf3d01aeb6f7a3e5fe173ecb' });
11616
11647
  }
11617
11648
  static get watchers() { return {
11618
11649
  "open": [{
@@ -12153,6 +12184,7 @@ class SdSelect extends BaseDropdownEvent {
12153
12184
  searchable = false;
12154
12185
  // props - label
12155
12186
  label = '';
12187
+ labelWidth = '';
12156
12188
  addonLabel = '';
12157
12189
  icon = undefined;
12158
12190
  labelTooltip = '';
@@ -12271,7 +12303,7 @@ class SdSelect extends BaseDropdownEvent {
12271
12303
  }
12272
12304
  };
12273
12305
  render() {
12274
- return (hAsync("sd-field", { key: '33f8a4e75ab20389213be5643f479b806e8e78c3', label: this.label, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, addonLabel: this.addonLabel, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el) }, hAsync("div", { key: '148f21e1a19cf4f4b9e61b4192d631d85dbc57a4', class: {
12306
+ return (hAsync("sd-field", { key: 'd96961fe4c425c3f0fcb1c2f438c8b70c510b632', label: this.label, labelWidth: this.labelWidth, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, addonLabel: this.addonLabel, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el) }, hAsync("div", { key: '0113ffb76ea79cbe3b77dff85d8186a5b994e7b6', class: {
12275
12307
  'sd-select': true,
12276
12308
  'sd-select--disabled': this.disabled,
12277
12309
  'sd-select--error': !!this.error,
@@ -12314,6 +12346,7 @@ class SdSelect extends BaseDropdownEvent {
12314
12346
  "clearable": [4],
12315
12347
  "searchable": [4],
12316
12348
  "label": [1],
12349
+ "labelWidth": [8, "label-width"],
12317
12350
  "addonLabel": [1, "addon-label"],
12318
12351
  "icon": [16],
12319
12352
  "labelTooltip": [1, "label-tooltip"],
@@ -12556,6 +12589,7 @@ class SdSelectGroup extends BaseDropdownEvent {
12556
12589
  searchable = false;
12557
12590
  // props - label
12558
12591
  label = '';
12592
+ labelWidth = '';
12559
12593
  addonLabel = '';
12560
12594
  icon = undefined;
12561
12595
  labelTooltip = '';
@@ -12803,7 +12837,7 @@ class SdSelectGroup extends BaseDropdownEvent {
12803
12837
  });
12804
12838
  }
12805
12839
  render() {
12806
- return (hAsync("sd-field", { key: 'b1b62a2e99fda1f0fbc4f8b3ede5af95a9ed09aa', label: this.label, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, addonLabel: this.addonLabel, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), style: { '--field-width': this.width || '200px' } }, hAsync("div", { key: '91f30fd84c70010030813f2d0cd9e86939e185d7', class: {
12840
+ return (hAsync("sd-field", { key: '1e6a0f9947f5d137bb65844fe666c07b4eefb2f7', label: this.label, labelWidth: this.labelWidth, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, addonLabel: this.addonLabel, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), style: { '--field-width': this.width || '200px' } }, hAsync("div", { key: '62dcd2f37c2eda0e51f2e77de36ece6ab592c4ce', class: {
12807
12841
  'sd-select-group': true,
12808
12842
  'sd-select-group--open': this.isOpen,
12809
12843
  'sd-select-group--disabled': this.disabled,
@@ -12868,6 +12902,7 @@ class SdSelectGroup extends BaseDropdownEvent {
12868
12902
  "clearable": [4],
12869
12903
  "searchable": [4],
12870
12904
  "label": [1],
12905
+ "labelWidth": [8, "label-width"],
12871
12906
  "addonLabel": [1, "addon-label"],
12872
12907
  "icon": [16],
12873
12908
  "labelTooltip": [1, "label-tooltip"],
@@ -12927,6 +12962,7 @@ class SdSelectMultiple extends BaseDropdownEvent {
12927
12962
  useCheckbox = false;
12928
12963
  // props - label
12929
12964
  label = '';
12965
+ labelWidth = '';
12930
12966
  icon = undefined;
12931
12967
  labelTooltip = '';
12932
12968
  labelTooltipProps = null;
@@ -13051,7 +13087,7 @@ class SdSelectMultiple extends BaseDropdownEvent {
13051
13087
  this.handleOptionSelection(option);
13052
13088
  };
13053
13089
  render() {
13054
- return (hAsync("sd-field", { key: 'e372aab1dafc730f22c6d58cbd39d651e65a66dc', label: this.label, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el) }, hAsync("div", { key: 'a73dc6abd9a05f888c39d2176f72275a329ccae0', class: {
13090
+ return (hAsync("sd-field", { key: 'f5dda40563661955aa194d841ca89628afd496cb', label: this.label, labelWidth: this.labelWidth, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el) }, hAsync("div", { key: '81541d9adabfea7c3af1c22ed419036f56e1a353', class: {
13055
13091
  'sd-select-multiple': true,
13056
13092
  'sd-select-multiple--open': this.isOpen,
13057
13093
  'sd-select-multiple--disabled': this.disabled,
@@ -13098,6 +13134,7 @@ class SdSelectMultiple extends BaseDropdownEvent {
13098
13134
  "useAll": [4, "use-all"],
13099
13135
  "useCheckbox": [4, "use-checkbox"],
13100
13136
  "label": [1],
13137
+ "labelWidth": [8, "label-width"],
13101
13138
  "icon": [16],
13102
13139
  "labelTooltip": [1, "label-tooltip"],
13103
13140
  "labelTooltipProps": [16],
@@ -13148,6 +13185,7 @@ class SdSelectMultipleGroup extends BaseDropdownEvent {
13148
13185
  allCheckOptionLabel = '전체';
13149
13186
  // props - label
13150
13187
  label = '';
13188
+ labelWidth = '';
13151
13189
  icon = undefined;
13152
13190
  labelTooltip = '';
13153
13191
  labelTooltipProps = null;
@@ -13514,7 +13552,7 @@ class SdSelectMultipleGroup extends BaseDropdownEvent {
13514
13552
  });
13515
13553
  }
13516
13554
  render() {
13517
- return (hAsync("sd-field", { key: '3cc9e5b2f1062e216a0dd738dff6918084c5e3b4', label: this.label, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), style: { '--field-width': this.width || '200px' } }, hAsync("div", { key: '60be94c561be252d6cc822e6be60a5e31390a15f', class: {
13555
+ return (hAsync("sd-field", { key: 'e7d00571a19a83e8d243d0c4f7433d931d4a2304', label: this.label, labelWidth: this.labelWidth, name: this.name, rules: this.rules, error: this.error, disabled: this.disabled, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), style: { '--field-width': this.width || '200px' } }, hAsync("div", { key: '8c7288d853fed5bb829f1ef90af5e96a512c11b3', class: {
13518
13556
  'sd-select-multiple-group': true,
13519
13557
  'sd-select-multiple-group--open': this.isOpen,
13520
13558
  'sd-select-multiple-group--disabled': this.disabled,
@@ -13587,6 +13625,7 @@ class SdSelectMultipleGroup extends BaseDropdownEvent {
13587
13625
  "allCheckedLabel": [1, "all-checked-label"],
13588
13626
  "allCheckOptionLabel": [1, "all-check-option-label"],
13589
13627
  "label": [1],
13628
+ "labelWidth": [8, "label-width"],
13590
13629
  "icon": [16],
13591
13630
  "labelTooltip": [1, "label-tooltip"],
13592
13631
  "labelTooltipProps": [16],
@@ -13842,6 +13881,7 @@ class SdSelectV2 {
13842
13881
  dropdownHeight = '260px';
13843
13882
  disabled = false;
13844
13883
  label = '';
13884
+ labelWidth = '';
13845
13885
  addonLabel = '';
13846
13886
  error = false;
13847
13887
  hint = '';
@@ -14035,13 +14075,13 @@ class SdSelectV2 {
14035
14075
  this.closeDropdown();
14036
14076
  },
14037
14077
  };
14038
- return (hAsync("sd-field", { key: 'b2a7f6ff2b4844069703400d68e9e736689d130a', name: this.fieldName || this.internalName, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, onMouseEnter: () => {
14078
+ return (hAsync("sd-field", { key: 'c9f08598c8f9852ab4000f056621dfef238e16de', name: this.fieldName || this.internalName, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, onMouseEnter: () => {
14039
14079
  this.hovered = true;
14040
14080
  }, onMouseLeave: () => {
14041
14081
  this.hovered = false;
14042
- } }, hAsync("div", { key: 'f832e4df90c6874c56e1f0ec5b109a7a77f3d0d1', class: "sd-select-v2", ref: el => {
14082
+ } }, hAsync("div", { key: '302103a425963e5d577b01ad179d5af82e6f30b1', class: "sd-select-v2", ref: el => {
14043
14083
  this.triggerRef = el;
14044
- } }, hAsync("sd-select-v2-trigger", { key: '9f2eaff8ca1ece8bec8fe635372e961a42ec0f80', displayText: this.displayText, placeholder: this.placeholder, disabled: this.disabled, isOpen: this.isOpen, onSdTriggerClick: this.handleTriggerClick })), (this.isOpen || this.isAnimatingOut) && (hAsync("sd-portal", { key: '2b8c31b66ac81a51dbd7657d5bbeeeaeb3ff0c83', ...portalProps }, hAsync("sd-select-v2-listbox", { key: '8d16190fff39d403c74966e197c09afb55e9b9f8', name: this.name, options: this.options, value: this.value, emitValue: this.emitValue, triggerWidth: this.triggerWidth, maxWidth: this.resolvedMaxDropdownWidth, maxHeight: this.resolvedDropdownHeight, onSdOptionSelect: event => this.handleOptionSelect(event.detail) })))));
14084
+ } }, hAsync("sd-select-v2-trigger", { key: 'a22bca400e5d10ee29e569da04d36b9291a1dade', displayText: this.displayText, placeholder: this.placeholder, disabled: this.disabled, isOpen: this.isOpen, onSdTriggerClick: this.handleTriggerClick })), (this.isOpen || this.isAnimatingOut) && (hAsync("sd-portal", { key: '0df4ad35bb284298708a0c1e11ce0e3c28d16ed8', ...portalProps }, hAsync("sd-select-v2-listbox", { key: '90c18612d553342be091a30e05194bab91407c76', name: this.name, options: this.options, value: this.value, emitValue: this.emitValue, triggerWidth: this.triggerWidth, maxWidth: this.resolvedMaxDropdownWidth, maxHeight: this.resolvedDropdownHeight, onSdOptionSelect: event => this.handleOptionSelect(event.detail) })))));
14045
14085
  }
14046
14086
  static get watchers() { return {
14047
14087
  "isOpen": [{
@@ -14061,6 +14101,7 @@ class SdSelectV2 {
14061
14101
  "dropdownHeight": [1, "dropdown-height"],
14062
14102
  "disabled": [4],
14063
14103
  "label": [1],
14104
+ "labelWidth": [8, "label-width"],
14064
14105
  "addonLabel": [1, "addon-label"],
14065
14106
  "error": [1028],
14066
14107
  "hint": [1],
@@ -16101,6 +16142,7 @@ class SdTextarea {
16101
16142
  width = '';
16102
16143
  // props - sd-field
16103
16144
  label = '';
16145
+ labelWidth = '';
16104
16146
  addonLabel = '';
16105
16147
  hint = '';
16106
16148
  errorMessage = '';
@@ -16188,7 +16230,7 @@ class SdTextarea {
16188
16230
  '--sd-system-size-field-sm-height': 'auto',
16189
16231
  '--sd-system-radius-field-sm': `${TEXTAREA_TOKENS.radius}px`,
16190
16232
  };
16191
- return (hAsync("sd-field", { key: '4525a68094b0655721c1d8679ee32bc041cf9677', name: this.name, label: this.label, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: '8a7724f1ff423b44dd9017f0446cfeb1220fda95', class: "sd-textarea__content" }, hAsync("textarea", { key: '3eb2bafbbd31cd36ba5626aa9e0069d24d4634ec', name: this.name, ref: el => (this.nativeEl = el), class: `sd-textarea__native ${this.textareaClass}`, value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readOnly: this.readonly, autofocus: this.autoFocus, maxLength: this.maxLength, rows: this.rows, spellcheck: this.spellcheck, onInput: this.handleInput, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event), style: this.textareaStyle }))));
16233
+ return (hAsync("sd-field", { key: '6b2360f01a356db14659e1ebc53d8c4d8c4f671f', name: this.name, label: this.label, labelWidth: this.labelWidth, addonLabel: this.addonLabel, hint: this.hint, errorMessage: this.errorMessage, width: this.width, rules: this.rules, error: this.error, disabled: this.disabled, focused: this.focused, hovered: this.hovered, status: this.status, icon: this.icon, labelTooltip: this.labelTooltip, labelTooltipProps: this.labelTooltipProps, ref: el => (this.formField = el), onMouseEnter: () => (this.hovered = true), onMouseLeave: () => (this.hovered = false), style: cssVars }, hAsync("div", { key: 'f43279ee861d3502c9130f1de0c47cba61ad0866', class: "sd-textarea__content" }, hAsync("textarea", { key: '0600b577417019ae36a0daba637168ebc5685220', name: this.name, ref: el => (this.nativeEl = el), class: `sd-textarea__native ${this.textareaClass}`, value: this.internalValue || '', placeholder: this.placeholder, disabled: this.disabled, readOnly: this.readonly, autofocus: this.autoFocus, maxLength: this.maxLength, rows: this.rows, spellcheck: this.spellcheck, onInput: this.handleInput, onFocus: event => this.handleFocus('focus', event), onBlur: event => this.handleFocus('blur', event), style: this.textareaStyle }))));
16192
16234
  }
16193
16235
  static get watchers() { return {
16194
16236
  "value": [{
@@ -16215,6 +16257,7 @@ class SdTextarea {
16215
16257
  "spellcheck": [4],
16216
16258
  "width": [8],
16217
16259
  "label": [1],
16260
+ "labelWidth": [8, "label-width"],
16218
16261
  "addonLabel": [1, "addon-label"],
16219
16262
  "hint": [1],
16220
16263
  "errorMessage": [1, "error-message"],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sellmate/design-system",
3
- "version": "1.0.63",
3
+ "version": "1.0.65",
4
4
  "description": "Sellmate Design System - Web Components Library built with Stencil",
5
5
  "keywords": [
6
6
  "web-components",
@@ -1 +0,0 @@
1
- import{p as t,H as s,c as i,h as e,t as o}from"./p-DuYi4aqj.js";const n=t(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.close=i(this,"sdClose",3)}get hostEl(){return this}to="body";parentRef=null;offset=[0,4];viewportPadding=0;zIndex=9999;open=!1;close;container;wrapper;rafId;isInsideClick=!1;closeTransitionTimer;handleObservedScroll=()=>this.updatePosition();resizeObserver;mutationObserver;scrollParents=[];isObserved=!1;handleOpenChange(){this.syncPortalState()}componentDidLoad(){this.container=this.resolveContainer(),this.syncPortalState()}componentDidRender(){this.syncPortalState()}disconnectedCallback(){if(this.closeTransitionTimer&&clearTimeout(this.closeTransitionTimer),this.unobserveParent(),this.wrapper?.parentNode)try{this.wrapper.parentNode.removeChild(this.wrapper)}catch{}}resolveContainer(){const t="string"==typeof this.to?document.querySelector(this.to):this.to;return t instanceof s?t:document.body}createWrapper(){this.wrapper=document.createElement("div"),Object.assign(this.wrapper.style,{position:"absolute",top:"0",left:"0",zIndex:(this.zIndex??9999).toString(),opacity:"0",transition:"opacity 0.15s ease-out",boxSizing:"border-box",visibility:"hidden"}),this.container.appendChild(this.wrapper)}ensureWrapper(){this.wrapper||(this.container||=this.resolveContainer(),this.createWrapper(),this.moveSlotContent())}syncPortalState(){if(!this.open)return this.wrapper&&(this.wrapper.style.transition="opacity 0.15s ease-out",this.wrapper.style.opacity="0",this.wrapper.style.pointerEvents="none",this.closeTransitionTimer&&clearTimeout(this.closeTransitionTimer),this.closeTransitionTimer=setTimeout((()=>{this.wrapper&&!this.open&&(this.wrapper.style.display="none")}),150)),void this.unobserveParent();this.closeTransitionTimer&&clearTimeout(this.closeTransitionTimer),this.ensureWrapper(),this.wrapper&&(this.wrapper.style.display="block",this.wrapper.style.transition="opacity 0.25s ease-out",this.wrapper.style.opacity="0",this.wrapper.style.pointerEvents="",this.observeParent(),this.updatePosition())}moveSlotContent(){this.wrapper&&Array.from(this.hostEl.childNodes).filter((t=>t.nodeType!==Node.COMMENT_NODE)).forEach((t=>this.wrapper.appendChild(t)))}updatePosition(){this.rafId&&cancelAnimationFrame(this.rafId),this.rafId=requestAnimationFrame((()=>{if(!this.parentRef||!this.wrapper)return;const t=this.parentRef.getBoundingClientRect(),s=window.innerWidth,i=window.innerHeight,e=this.offset??[0,4],o=Math.max(0,this.viewportPadding??0),n=Math.max(s-2*o,0),h=Math.max(i-2*o,0);this.wrapper.style.maxWidth=`${n}px`,this.wrapper.style.maxHeight=`${h}px`;const r=this.wrapper.getBoundingClientRect(),a=i-t.bottom-e[1]-o;let d=t.bottom+window.scrollY+e[1],l=t.left+window.scrollX+e[0];a<r.height&&t.top-e[1]-o>a&&(d=t.top+window.scrollY-r.height-e[1]);const c=window.scrollY+o,p=window.scrollY+i-o-r.height;d=p<c?c:Math.min(Math.max(d,c),p),t.left+r.width+e[0]>s-o&&(l=t.right+window.scrollX-r.width-e[0]);const u=window.scrollX+o,w=window.scrollX+s-o-r.width;l=w<u?u:Math.min(Math.max(l,u),w),this.wrapper.style.top=`${d}px`,this.wrapper.style.left=`${l}px`,this.wrapper.style.visibility="visible",this.wrapper.style.opacity="1"}))}observeParent(){this.parentRef&&!this.isObserved&&(this.observeScrollParents(this.parentRef),"undefined"!=typeof ResizeObserver&&(this.resizeObserver=new ResizeObserver((()=>this.updatePosition())),this.resizeObserver.observe(this.parentRef)),"undefined"!=typeof MutationObserver&&(this.mutationObserver=new MutationObserver((()=>this.updatePosition())),this.mutationObserver.observe(document.body,{childList:!0,subtree:!0})),this.isObserved=!0)}unobserveParent(){this.isObserved&&(this.unobserveScrollParents(),this.resizeObserver?.disconnect(),this.resizeObserver=void 0,this.mutationObserver?.disconnect(),this.mutationObserver=void 0,this.isObserved=!1)}observeScrollParents(t){const s=this.getScrollParents(t);s.forEach((t=>{t.addEventListener("scroll",this.handleObservedScroll,{passive:!0})})),this.scrollParents=s}unobserveScrollParents(){this.scrollParents.forEach((t=>{t.removeEventListener("scroll",this.handleObservedScroll)})),this.scrollParents=[]}getScrollParents(t){const s=[];let i=t.parentElement;for(;i;){const{overflow:t,overflowX:e,overflowY:o}=getComputedStyle(i);[t,e,o].some((t=>/(auto|scroll|overlay)/.test(t)))&&s.push(i),i=i.parentElement}return s}handleMouseDown(t){this.isInsideClick=!(!this.wrapper||!this.wrapper.contains(t.target))}handleWindowClick(t){this.isInsideClick?this.isInsideClick=!1:this.wrapper?.contains(t.target)||this.close.emit()}render(){return e("slot",{key:"e9862350592ae8ea0741b4639a94e288f0b302f2"})}static get watchers(){return{open:[{handleOpenChange:0}]}}},[772,"sd-portal",{to:[1],parentRef:[16],offset:[16],viewportPadding:[2,"viewport-padding"],zIndex:[2,"z-index"],open:[4]},[[9,"scroll","updatePosition"],[9,"resize","updatePosition"],[9,"mousedown","handleMouseDown"],[8,"click","handleWindowClick"]],{open:[{handleOpenChange:0}]}]);function h(){"undefined"!=typeof customElements&&["sd-portal"].forEach((t=>{"sd-portal"===t&&(customElements.get(o(t))||customElements.define(o(t),n))}))}export{n as S,h as d}
@@ -1 +0,0 @@
1
- import{p as t,H as n,c as o,h as i,t as e}from"./p-DuYi4aqj.js";const a=t(class t extends n{constructor(t){super(),!1!==t&&this.__registerHost(),this.close=o(this,"sdClose",7)}get el(){return this}to="body";parentRef=null;offset=[0,0];zIndex=9999;placement="bottom";open=!1;close;container;wrapper;rafId;isInsideClick=!1;resizeObserver;mutationObserver;static ARROW_SIZE=11.2;componentDidLoad(){this.container=this.resolveContainer(),this.createWrapper(),this.moveSlotContent(),requestAnimationFrame((()=>{this.updatePosition(),this.wrapper&&(this.wrapper.style.visibility="visible")})),this.observeParent()}componentDidRender(){this.wrapper&&(this.open?(this.wrapper.style.display="block",requestAnimationFrame((()=>{this.updatePosition(),this.wrapper&&(this.wrapper.style.visibility="visible")}))):(this.wrapper.style.display="none",this.wrapper.style.visibility="hidden"))}disconnectedCallback(){this.rafId&&cancelAnimationFrame(this.rafId),this.unobserveParent(),this.wrapper?.remove()}resolveContainer(){const t="string"==typeof this.to?document.querySelector(this.to):this.to;return t instanceof n?t:document.body}createWrapper(){this.wrapper=document.createElement("div"),Object.assign(this.wrapper.style,{position:"absolute",zIndex:(this.zIndex??9999).toString(),transition:"opacity 0.4s",top:"-9999px",left:"-9999px"}),this.container.appendChild(this.wrapper)}moveSlotContent(){this.wrapper&&Array.from(this.el.childNodes).filter((t=>t.nodeType!==Node.COMMENT_NODE)).forEach((t=>this.wrapper.appendChild(t)))}updatePosition(){this.rafId&&cancelAnimationFrame(this.rafId),this.rafId=requestAnimationFrame((()=>{if(!this.parentRef||!this.wrapper)return;const n=this.parentRef.getBoundingClientRect();if(!n.width&&!n.height)return;const[o,i]=this.offset,e=t.ARROW_SIZE;let a=0,s=0;switch(this.placement){case"top":a=n.top+window.scrollY-this.wrapper.offsetHeight+i-e,s=n.left+window.scrollX+n.width/2-this.wrapper.offsetWidth/2+o;break;case"bottom":a=n.bottom+window.scrollY+i+e,s=n.left+window.scrollX+n.width/2-this.wrapper.offsetWidth/2+o;break;case"left":a=n.top+window.scrollY+n.height/2-this.wrapper.offsetHeight/2+i,s=n.left+window.scrollX-this.wrapper.offsetWidth-o-e;break;case"right":a=n.top+window.scrollY+n.height/2-this.wrapper.offsetHeight/2+i,s=n.right+window.scrollX+o+e}Object.assign(this.wrapper.style,{top:`${a}px`,left:`${s}px`})}))}observeParent(){this.parentRef&&(this.resizeObserver=new ResizeObserver((()=>this.updatePosition())),this.resizeObserver.observe(this.parentRef),this.mutationObserver=new MutationObserver((()=>this.updatePosition())),this.mutationObserver.observe(document.body,{childList:!0,subtree:!0}))}unobserveParent(){this.resizeObserver?.disconnect(),this.mutationObserver?.disconnect()}handleMouseDown(t){this.isInsideClick=!!(this.wrapper&&this.wrapper.contains(t.target)||this.parentRef&&this.parentRef.contains(t.target))}handleWindowClick(t){this.isInsideClick?this.isInsideClick=!1:this.wrapper?.contains(t.target)||this.close.emit()}render(){return i("slot",{key:"4f7cf13fe78e7d4e906a2cda47de4258d9ceda74"})}static get style(){return".sd-floating-menu{width:fit-content;padding:12px 16px;border-radius:6px;font-size:12px;font-weight:500;line-height:20px;position:relative;box-sizing:border-box;background:var(--sd-floating-bg, #07284A);color:var(--sd-floating-content, #FFFFFF);animation:sd-floating-fade-in 0.35s ease-out}.sd-floating-menu--top{animation-name:sd-floating-slide-top}.sd-floating-menu--bottom{animation-name:sd-floating-slide-bottom}.sd-floating-menu--left{animation-name:sd-floating-slide-left}.sd-floating-menu--right{animation-name:sd-floating-slide-right}.sd-floating-menu .sd-floating-menu__arrow{color:var(--sd-floating-bg, #07284A)}.sd-floating-menu--default{background:var(--sd-floating-bg, #07284A);color:var(--sd-floating-content, #FFFFFF);font-weight:500}.sd-floating-menu--default .sd-floating-menu__arrow{color:var(--sd-floating-bg, #07284A)}.sd-floating-menu--danger{background:var(--sd-floating-bg, #FCE6E6);color:var(--sd-floating-content, #FB4444);font-weight:700}.sd-floating-menu--danger .sd-floating-menu__arrow{color:var(--sd-floating-bg, #FCE6E6)}.sd-floating-menu--warning{background:var(--sd-floating-bg, #FEF1EA);color:var(--sd-floating-content, #FF6B00);font-weight:700}.sd-floating-menu--warning .sd-floating-menu__arrow{color:var(--sd-floating-bg, #FEF1EA)}.sd-floating-menu--accent{background:var(--sd-floating-bg, #E6F1FF);color:var(--sd-floating-content, #0075FF);font-weight:700}.sd-floating-menu--accent .sd-floating-menu__arrow{color:var(--sd-floating-bg, #E6F1FF)}.sd-floating-menu__arrow{position:absolute;display:flex;width:16px;height:12px}.sd-floating-menu__arrow svg{width:100%;height:100%}.sd-floating-menu__arrow--top{bottom:-12px;left:50%;transform:translateX(-50%)}.sd-floating-menu__arrow--bottom{top:-12px;left:50%;transform:translateX(-50%) rotate(180deg)}.sd-floating-menu__arrow--left{right:-12px;top:50%;transform:translateY(-50%) rotate(-90deg)}.sd-floating-menu__arrow--right{left:-12px;top:50%;transform:translateY(-50%) rotate(90deg)}.sd-floating-menu__content{font-size:12px;line-height:20px}.sd-floating-menu__content .sd-floating-menu__title{font-size:14px;font-weight:700;line-height:24px;margin-bottom:4px}.sd-floating-menu__content .sd-floating-menu__messages{font-weight:500}.sd-floating-menu__content .sd-floating-menu__buttons{margin-top:12px;display:flex;gap:8px;align-items:center}.sd-floating-menu__content .sd-floating-menu__buttons--1{justify-content:flex-end}.sd-floating-menu__content .sd-floating-menu__buttons--2{justify-content:space-between}.sd-floating-menu--popover{padding:16px 20px}.sd-floating-menu--popover .sd-floating-menu__content{gap:4px}.sd-floating-menu--popover .sd-floating-menu__title{font-size:14px;font-weight:700;line-height:24px}.sd-floating-menu--popover .sd-floating-menu__messages{font-size:12px;font-weight:500;line-height:20px}.sd-floating-menu--closing{animation:sd-floating-fade-out 0.15s ease-in forwards}.sd-floating-menu--closing.sd-floating-menu--top{animation-name:sd-floating-slide-out-top}.sd-floating-menu--closing.sd-floating-menu--bottom{animation-name:sd-floating-slide-out-bottom}.sd-floating-menu--closing.sd-floating-menu--left{animation-name:sd-floating-slide-out-left}.sd-floating-menu--closing.sd-floating-menu--right{animation-name:sd-floating-slide-out-right}.sd-floating-menu__close-button{position:absolute;top:12px;right:12px}@keyframes sd-floating-fade-out{from{opacity:1}to{opacity:0}}@keyframes sd-floating-slide-out-top{from{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(4px)}}@keyframes sd-floating-slide-out-bottom{from{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-4px)}}@keyframes sd-floating-slide-out-left{from{opacity:1;transform:translateX(0)}to{opacity:0;transform:translateX(4px)}}@keyframes sd-floating-slide-out-right{from{opacity:1;transform:translateX(0)}to{opacity:0;transform:translateX(-4px)}}@keyframes sd-floating-fade-in{from{opacity:0}to{opacity:1}}@keyframes sd-floating-slide-top{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}@keyframes sd-floating-slide-bottom{from{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}@keyframes sd-floating-slide-left{from{opacity:0;transform:translateX(4px)}to{opacity:1;transform:translateX(0)}}@keyframes sd-floating-slide-right{from{opacity:0;transform:translateX(-4px)}to{opacity:1;transform:translateX(0)}}"}},[772,"sd-floating-portal",{to:[1],parentRef:[16],offset:[16],zIndex:[2,"z-index"],placement:[1],open:[4]},[[9,"scroll","updatePosition"],[9,"resize","updatePosition"],[9,"mousedown","handleMouseDown"],[8,"click","handleWindowClick"]]]);function s(){"undefined"!=typeof customElements&&["sd-floating-portal"].forEach((t=>{"sd-floating-portal"===t&&(customElements.get(e(t))||customElements.define(e(t),a))}))}export{a as S,s as d}
@@ -1 +0,0 @@
1
- import{p as e,H as d,h as s,t as i}from"./p-DuYi4aqj.js";import{d as t}from"./p-BLC3AWW8.js";import{d as l}from"./p-DxzgCf_d.js";import{d as r}from"./p-CGssy8eb.js";import{d as o}from"./p-BZ7V5xV5.js";var a={sm:{height:"28",gap:"6",icon:"12",typography:{fontWeight:"700",fontSize:"12",lineHeight:"20"}},md:{height:"36",gap:"8",icon:"16",typography:{fontWeight:"700",fontSize:"16",lineHeight:"26"}}},n={gap:"6",paddingX:"12",typography:{fontWeight:"500",fontSize:"12",lineHeight:"20"},bg:"#F6F6F6",border:{default:"#AAAAAA",disabled:"#CCCCCC",width:"1"}};const f=a.sm,h=a.md,p={sm:{height:f.height,gap:f.gap,icon:f.icon,fontSize:f.typography.fontSize,lineHeight:f.typography.lineHeight,fontWeight:f.typography.fontWeight},md:{height:h.height,gap:h.gap,icon:h.icon,fontSize:h.typography.fontSize,lineHeight:h.typography.lineHeight,fontWeight:h.typography.fontWeight}},c=["sd-select","sd-select-multiple","sd-select-multiple-group","sd-input","sd-barcode-input","sd-textarea","sd-number-input","sd-select-v2","sd-file-picker","sd-date-picker","sd-date-range-picker"],b=e(class extends d{constructor(e){super(),!1!==e&&this.__registerHost()}get el(){return this}name="";rules=[];error=!1;disabled=!1;hovered=!1;focused=!1;status;hint="";errorMessage="";width="";size="sm";label="";addonLabel="";icon=void 0;labelTooltip="";labelTooltipProps=null;errorMsg="";hostElement=null;get value(){return this.hostElement?.value??null}get fieldStatus(){let e="";return this.disabled?(e="disabled",`sd-field--${e}`):this.focused?(e="focus",`sd-field--${e}`):(this.hovered&&(e="hover"),this.status&&(e=this.status),this.error&&(e="error"),e?`sd-field--${e}`:"")}componentDidLoad(){this.hostElement=this.findHostElement(),this.registerToForm()}disconnectedCallback(){this.unregisterFromForm()}findHostElement(){for(const e of c){const d=this.el.closest(e);if(d&&"value"in d)return d}return null}registerToForm(){const e=this.el.closest("sd-form");e&&"function"==typeof e.componentOnReady&&e.componentOnReady().then((e=>{e.sdRegisterField(this)}))}unregisterFromForm(){if(!this.name)return;const e=this.el.closest("sd-form");e?.componentOnReady().then((e=>{e.sdUnregisterField(this.name)}))}async sdValidate(){if(!this.rules||0===this.rules.length)return!0;for(const e of this.rules){const d=e(this.value??"");if(!0!==d)return this.setError(!0,d),!1}return this.setError(!1,""),!0}async sdReset(){this.hostElement&&(this.hostElement.value=null),this.setError(!1,"")}async sdResetValidation(){this.setError(!1,"")}async sdFocus(){this.hostElement?.focus?.(),this.hostElement?.scrollIntoView({behavior:"smooth",block:"center"})}setError(e,d){this.errorMsg=d,this.hostElement&&(this.hostElement.error=e)}render(){const e=this.addonLabel,d=this.size in p?this.size:"sm",i=p[d],t={"--sd-field-wrapper-height":`var(--sd-system-size-field-${d}-height)`,"--sd-field-control-radius":`var(--sd-system-radius-field-${d})`,"--sd-field-label-margin-right":`var(--sd-system-space-field-${d}-gap)`},l=this.label?{"--sd-field-label-height":`${i.height}px`,"--sd-field-label-gap":`${i.gap}px`,"--sd-field-label-font-size":`${i.fontSize}px`,"--sd-field-label-line-height":`${i.lineHeight}px`,"--sd-field-label-font-weight":i.fontWeight}:{},r=e?{"--sd-field-addon-padding-x":`${n.paddingX}px`,"--sd-field-addon-font-size":`${n.typography.fontSize}px`,"--sd-field-addon-line-height":`${n.typography.lineHeight}px`,"--sd-field-addon-font-weight":n.typography.fontWeight,"--sd-field-addon-bg":n.bg,"--sd-field-addon-border-color":this.disabled?n.border.disabled:n.border.default,"--sd-field-addon-gap":`${n.gap}px`,"--sd-field-addon-border-width":`${n.border.width}px`}:{};return s("div",{key:"72ffdb42c88b90eb60637b10c1330dc509ece812",class:{"sd-field":!0,"sd-field--has-label":!!this.label,"sd-field--has-addon":!!e,[this.fieldStatus]:!!this.fieldStatus},style:{...t,...l,...r}},s("div",{key:"fb5d90aea5a4988ec58984b4a85ed609f032549e",class:"sd-field__wrapper"},this.renderLabel(this.label),s("div",{key:"c0372be3a39ca1d6cebfe5e765d120751e39d03e",class:"sd-field__main",style:this.width?{width:"number"==typeof this.width?`${this.width}px`:this.width,flex:"none"}:{}},s("div",{key:"d203154db0eef4e73908d78ba3667710c51b6595",class:{"sd-field__control":!0,"sd-field__control--has-addon":!!e}},e&&s("div",{key:"851b996010c4f0402df8b6bfe9ced0c8444bc591",class:"sd-field__addon"},e),s("slot",{key:"081b95a99090c3c1d2d28170500ac7be15452876"})),this.errorMsg||this.errorMessage?s("div",{class:"sd-field__error-message"},this.errorMsg||this.errorMessage):this.hint&&s("div",{class:"sd-field__hint"},this.hint))))}renderLabel(e){return e?s("label",{class:"sd-field__label"},this.icon&&s("sd-icon",{name:this.icon.name,size:this.icon.size??Number(p[this.size in p?this.size:"sm"].icon),color:this.icon.color,rotate:this.icon.rotate,class:"sd-field__label__icon"}),s("div",{class:"sd-field__label__text"},e),this.labelTooltip&&s("sd-tooltip",{class:"sd-field__label__tooltip",...this.labelTooltipProps},this.labelTooltip)):null}static get style(){return"sd-field{display:inline-flex;flex-flow:column nowrap;height:fit-content;width:100%}sd-field .sd-field *:focus,sd-field .sd-field *:focus-visible,sd-field .sd-field *:focus-within{outline:none !important}sd-field .sd-field.sd-field--disabled{cursor:not-allowed}sd-field .sd-field.sd-field--disabled .sd-field__wrapper{cursor:not-allowed !important}sd-field .sd-field.sd-field--disabled .sd-field__wrapper .sd-field__label-inside{border-color:#CCCCCC;color:#888888;cursor:not-allowed !important}sd-field .sd-field.sd-field--disabled .sd-field__wrapper .sd-field__control{background-color:#E1E1E1;border-color:#CCCCCC;color:#888888;cursor:not-allowed !important}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label{display:flex;align-items:center;height:var(--sd-field-label-height);margin-right:var(--sd-field-label-margin-right)}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__icon{margin-right:var(--sd-field-label-gap)}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__text{font-size:var(--sd-field-label-font-size);line-height:var(--sd-field-label-line-height);font-weight:var(--sd-field-label-font-weight);color:var(--sd-system-color-field-text-default);white-space:nowrap}sd-field .sd-field--has-label .sd-field__wrapper .sd-field__label__tooltip{margin-left:var(--sd-field-label-gap)}sd-field .sd-field--has-addon .sd-field__control .sd-field__addon{display:flex;gap:var(--sd-field-addon-gap);align-items:center;white-space:nowrap;padding:0 var(--sd-field-addon-padding-x);font-size:var(--sd-field-addon-font-size);line-height:var(--sd-field-addon-line-height);font-weight:var(--sd-field-addon-font-weight);background:var(--sd-field-addon-bg);border-right:var(--sd-field-addon-border-width) solid var(--sd-field-addon-border-color);border-radius:calc(var(--sd-field-control-radius) - 1px) 0 0 calc(var(--sd-field-control-radius) - 1px)}sd-field .sd-field__wrapper{width:100%;display:flex;align-items:flex-start;flex-flow:row nowrap;position:relative;color:var(--sd-system-color-field-text-default);-webkit-user-select:none;user-select:none}sd-field .sd-field__wrapper .sd-field__main{flex:1;min-width:0;display:flex;flex-direction:column}sd-field .sd-field__wrapper .sd-field__control{position:relative;height:var(--sd-field-wrapper-height);display:flex;min-width:0;border:1px solid var(--sd-system-color-field-border-default);border-radius:var(--sd-field-control-radius);background:var(--sd-system-color-field-bg-default)}sd-field .sd-field--error .sd-field__wrapper .sd-field__control:not(:hover){border:1px solid var(--sd-system-color-field-border-danger) !important}sd-field .sd-field.sd-field--pass .sd-field__wrapper .sd-field__control{border:1px solid var(--sd-system-color-field-border-success) !important}sd-field .sd-field:not(.sd-field--disabled) .sd-field__wrapper .sd-field__control:hover{border:1px solid var(--sd-system-color-field-border-focus) !important;box-shadow:0px 0px 4px 0px rgba(0, 113, 255, 0.4)}sd-field .sd-field.sd-field--focus .sd-field__wrapper .sd-field__control{border:1px solid var(--sd-system-color-field-border-focus) !important;box-shadow:0px 0px 4px 0px rgba(0, 113, 255, 0.4)}sd-field .sd-field .sd-field__error-message{color:var(--sd-textinput-textinput-text-error-message);font-size:var(--sd-textinput-textinput-error-message-typography-font-size);line-height:var(--sd-textinput-textinput-error-message-typography-line-height);margin-top:var(--sd-textinput-textinput-contents-gap)}sd-field .sd-field .sd-field__hint{color:var(--sd-textinput-textinput-text-hint);font-size:var(--sd-textinput-textinput-hint-typography-font-size);line-height:var(--sd-textinput-textinput-hint-typography-line-height);margin-top:var(--sd-textinput-textinput-contents-gap)}"}},[772,"sd-field",{name:[1],rules:[16],error:[1028],disabled:[1028],hovered:[1028],focused:[1028],status:[1],hint:[1],errorMessage:[1,"error-message"],width:[8],size:[513],label:[1],addonLabel:[1,"addon-label"],icon:[16],labelTooltip:[1,"label-tooltip"],labelTooltipProps:[16],errorMsg:[32],sdValidate:[64],sdReset:[64],sdResetValidation:[64],sdFocus:[64]}]);function g(){"undefined"!=typeof customElements&&["sd-field","sd-button","sd-floating-portal","sd-icon","sd-tooltip"].forEach((e=>{switch(e){case"sd-field":customElements.get(i(e))||customElements.define(i(e),b);break;case"sd-button":customElements.get(i(e))||t();break;case"sd-floating-portal":customElements.get(i(e))||l();break;case"sd-icon":customElements.get(i(e))||r();break;case"sd-tooltip":customElements.get(i(e))||o()}}))}export{b as S,g as d}