@keenthemes/ktui 1.0.11 → 1.0.13

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 (123) hide show
  1. package/dist/ktui.js +1687 -1517
  2. package/dist/ktui.min.js +1 -1
  3. package/dist/ktui.min.js.map +1 -1
  4. package/dist/styles.css +5822 -0
  5. package/examples/select/avatar.html +47 -0
  6. package/examples/select/basic-usage.html +39 -0
  7. package/examples/select/combobox-icons_.html +59 -0
  8. package/examples/select/combobox_.html +46 -0
  9. package/examples/select/country.html +43 -0
  10. package/examples/select/description.html +53 -0
  11. package/examples/select/disable-option.html +37 -0
  12. package/examples/select/disable-select.html +35 -0
  13. package/examples/select/icon-multiple.html +50 -0
  14. package/examples/select/icon.html +48 -0
  15. package/examples/select/max-selection.html +38 -0
  16. package/examples/select/modal.html +72 -0
  17. package/examples/select/multiple.html +40 -0
  18. package/examples/select/placeholder.html +40 -0
  19. package/examples/select/remote-data_.html +32 -0
  20. package/examples/select/search.html +57 -0
  21. package/examples/select/sizes.html +94 -0
  22. package/examples/select/tags-icons_.html +58 -0
  23. package/examples/select/tags-selected_.html +59 -0
  24. package/examples/select/tags_.html +58 -0
  25. package/examples/select/template-customization.html +62 -0
  26. package/examples/toast/example.html +427 -0
  27. package/lib/cjs/components/datatable/datatable.js +23 -7
  28. package/lib/cjs/components/datatable/datatable.js.map +1 -1
  29. package/lib/cjs/components/select/combobox.js +94 -141
  30. package/lib/cjs/components/select/combobox.js.map +1 -1
  31. package/lib/cjs/components/select/config.js +4 -18
  32. package/lib/cjs/components/select/config.js.map +1 -1
  33. package/lib/cjs/components/select/dropdown.js +35 -138
  34. package/lib/cjs/components/select/dropdown.js.map +1 -1
  35. package/lib/cjs/components/select/index.js +2 -1
  36. package/lib/cjs/components/select/index.js.map +1 -1
  37. package/lib/cjs/components/select/option.js +56 -6
  38. package/lib/cjs/components/select/option.js.map +1 -1
  39. package/lib/cjs/components/select/remote.js +1 -37
  40. package/lib/cjs/components/select/remote.js.map +1 -1
  41. package/lib/cjs/components/select/search.js +147 -128
  42. package/lib/cjs/components/select/search.js.map +1 -1
  43. package/lib/cjs/components/select/select.js +332 -391
  44. package/lib/cjs/components/select/select.js.map +1 -1
  45. package/lib/cjs/components/select/tags.js +38 -56
  46. package/lib/cjs/components/select/tags.js.map +1 -1
  47. package/lib/cjs/components/select/templates.js +168 -200
  48. package/lib/cjs/components/select/templates.js.map +1 -1
  49. package/lib/cjs/components/select/types.js +0 -12
  50. package/lib/cjs/components/select/types.js.map +1 -1
  51. package/lib/cjs/components/select/utils.js +187 -339
  52. package/lib/cjs/components/select/utils.js.map +1 -1
  53. package/lib/cjs/components/toast/index.js +10 -0
  54. package/lib/cjs/components/toast/index.js.map +1 -0
  55. package/lib/cjs/components/toast/toast.js +543 -0
  56. package/lib/cjs/components/toast/toast.js.map +1 -0
  57. package/lib/cjs/components/toast/types.js +7 -0
  58. package/lib/cjs/components/toast/types.js.map +1 -0
  59. package/lib/cjs/index.js +5 -1
  60. package/lib/cjs/index.js.map +1 -1
  61. package/lib/esm/components/datatable/datatable.js +23 -7
  62. package/lib/esm/components/datatable/datatable.js.map +1 -1
  63. package/lib/esm/components/select/combobox.js +95 -142
  64. package/lib/esm/components/select/combobox.js.map +1 -1
  65. package/lib/esm/components/select/config.js +3 -17
  66. package/lib/esm/components/select/config.js.map +1 -1
  67. package/lib/esm/components/select/dropdown.js +35 -138
  68. package/lib/esm/components/select/dropdown.js.map +1 -1
  69. package/lib/esm/components/select/index.js +1 -1
  70. package/lib/esm/components/select/index.js.map +1 -1
  71. package/lib/esm/components/select/option.js +56 -6
  72. package/lib/esm/components/select/option.js.map +1 -1
  73. package/lib/esm/components/select/remote.js +1 -37
  74. package/lib/esm/components/select/remote.js.map +1 -1
  75. package/lib/esm/components/select/search.js +148 -129
  76. package/lib/esm/components/select/search.js.map +1 -1
  77. package/lib/esm/components/select/select.js +333 -392
  78. package/lib/esm/components/select/select.js.map +1 -1
  79. package/lib/esm/components/select/tags.js +38 -56
  80. package/lib/esm/components/select/tags.js.map +1 -1
  81. package/lib/esm/components/select/templates.js +167 -199
  82. package/lib/esm/components/select/templates.js.map +1 -1
  83. package/lib/esm/components/select/types.js +1 -11
  84. package/lib/esm/components/select/types.js.map +1 -1
  85. package/lib/esm/components/select/utils.js +184 -336
  86. package/lib/esm/components/select/utils.js.map +1 -1
  87. package/lib/esm/components/toast/index.js +6 -0
  88. package/lib/esm/components/toast/index.js.map +1 -0
  89. package/lib/esm/components/toast/toast.js +540 -0
  90. package/lib/esm/components/toast/toast.js.map +1 -0
  91. package/lib/esm/components/toast/types.js +6 -0
  92. package/lib/esm/components/toast/types.js.map +1 -0
  93. package/lib/esm/index.js +3 -0
  94. package/lib/esm/index.js.map +1 -1
  95. package/package.json +14 -9
  96. package/src/components/alert/alert.css +15 -2
  97. package/src/components/datatable/datatable.ts +25 -17
  98. package/src/components/input/input.css +3 -1
  99. package/src/components/link/link.css +2 -2
  100. package/src/components/scrollable/scrollable.css +9 -5
  101. package/src/components/select/combobox.ts +96 -192
  102. package/src/components/select/config.ts +35 -36
  103. package/src/components/select/dropdown.ts +43 -155
  104. package/src/components/select/index.ts +1 -1
  105. package/src/components/select/option.ts +50 -10
  106. package/src/components/select/remote.ts +2 -42
  107. package/src/components/select/search.ts +159 -158
  108. package/src/components/select/select.css +137 -18
  109. package/src/components/select/select.ts +354 -506
  110. package/src/components/select/tags.ts +37 -60
  111. package/src/components/select/templates.ts +254 -328
  112. package/src/components/select/types.ts +0 -10
  113. package/src/components/select/utils.ts +190 -416
  114. package/src/components/textarea/textarea.css +2 -1
  115. package/src/components/toast/index.ts +7 -0
  116. package/src/components/toast/toast.css +60 -0
  117. package/src/components/toast/toast.ts +605 -0
  118. package/src/components/toast/types.ts +169 -0
  119. package/src/index.ts +4 -0
  120. package/styles/main.css +3 -0
  121. package/styles/vars.css +138 -0
  122. package/styles.css +1 -0
  123. package/webpack.config.js +6 -1
@@ -13,31 +13,26 @@ var __assign = (this && this.__assign) || function () {
13
13
  };
14
14
  return __assign.apply(this, arguments);
15
15
  };
16
- import { SelectMode } from './types';
16
+ import { renderTemplateString } from './utils';
17
17
  /**
18
18
  * Default HTML string templates for KTSelect. All UI structure is defined here.
19
19
  * Users can override any template by providing a matching key in the config.templates object.
20
20
  */
21
- var defaultTemplateStrings = {
22
- dropdownContent: "<div data-kt-select-dropdown-content class=\"kt-select-dropdown hidden\" style=\"z-index: {{zindex}};\">{{content}}</div>",
23
- optionsContainer: "<ul role=\"listbox\" aria-label=\"{{label}}\" data-kt-select-options-container style=\"max-height: {{height}}px; overflow-y: auto;\">{{options}}</ul>",
24
- emptyOption: "<option value=\"\">{{placeholder}}</option>",
25
- errorOption: "<option value=\"\" disabled selected>{{errorMessage}}</option>", // Template for error <option>
26
- loadMore: "<li class=\"py-2 px-4 text-center text-gray-600 cursor-pointer hover:bg-gray-100\" data-kt-select-load-more>{{loadMoreText}}</li>",
27
- dropdown: "<div data-kt-select-dropdown-content class=\"absolute z-10 w-full mt-2 bg-white border border-gray-200 rounded-md shadow-md\">\n\t\t{{search}}\n\t\t<ul role=\"listbox\" aria-label=\"{{label}}\" data-kt-select-options-container style=\"max-height: {{height}}px; overflow-y: auto;\">\n\t\t\t{{options}}\n\t\t</ul>\n\t</div>",
28
- error: "<li class=\"px-3 py-2 text-red-500\" role=\"alert\">{{errorMessage}}</li>",
29
- highlight: "<span class=\"highlight\">{{text}}</span>",
30
- main: "<div data-kt-select-wrapper class=\"relative\" data-kt-select-mode=\"{{mode}}\"></div>",
31
- displayCombobox: "<div class=\"relative flex items-center w-full\">\n\t\t<input data-kt-select-search data-kt-select-display data-kt-select-value type=\"text\" class=\"flex-1 w-full items-center justify-between px-3 py-2 border border-gray-300 rounded-md cursor-pointer focus:outline-none focus:ring-2 focus:ring-blue-200 focus:border-blue-400\" placeholder=\"{{placeholder}}\" role=\"searchbox\" aria-label=\"{{label}}\" {{disabled}} />\n\t\t<button type=\"button\" data-kt-select-clear-button class=\"absolute right-3 hidden text-gray-400 hover:text-gray-600\" aria-label=\"Clear selection\">\n\t\t<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n\t\t\t<line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\"></line>\n\t\t\t<line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\"></line>\n\t\t</svg>\n\t\t</button>\n\t</div>",
32
- icon: "<span class=\"option-icon mr-2\"><img src=\"{{icon}}\" class=\"rounded-full w-6 h-6\" /></span>",
33
- description: "<div class=\"option-description text-sm text-gray-500\">{{description}}</div>",
34
- display: "<div data-kt-select-display class=\"flex items-center justify-between px-3 py-2 border border-gray-300 rounded-md cursor-pointer focus:outline-none focus:ring-2 focus:ring-blue-200 focus:border-blue-400\" tabindex=\"{{tabindex}}\" role=\"button\" aria-haspopup=\"listbox\" aria-expanded=\"false\" aria-label=\"{{label}}\" {{disabled}}>\n\t\t<span data-kt-select-value>{{placeholder}}</span>\n\t\t<span data-kt-select-arrow class=\"ml-2\">\n\t\t\t<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n\t\t\t\t<polyline points=\"6 9 12 15 18 9\"></polyline>\n\t\t\t</svg>\n\t\t</span>\n\t</div>",
35
- option: "<li data-kt-select-option data-value=\"{{value}}\" class=\"px-3 py-2 cursor-pointer hover:bg-gray-100 flex items-center{{selectedClass}}{{disabledClass}}\" role=\"option\" {{selected}} {{disabled}}>{{icon}}<div class=\"option-content\"><div class=\"option-title\" data-kt-option-title>{{text}}</div>{{description}}</div></li>",
36
- optionGroup: "<li role=\"group\" aria-label=\"{{label}}\" class=\"py-1\"><div class=\"px-3 py-1 text-xs font-semibold text-gray-500 uppercase\">{{label}}</div><ul>{{optionsHtml}}</ul></li>",
37
- search: "<div class=\"px-3 py-2 border-b border-gray-200\"><input type=\"text\" data-kt-select-search placeholder=\"{{searchPlaceholder}}\" class=\"w-full border-none focus:outline-none text-sm\" role=\"searchbox\" aria-label=\"{{searchPlaceholder}}\"/></div>",
38
- noResults: "<li class=\"px-3 py-2 text-gray-500\" role=\"status\">{{searchNotFoundText}}</li>",
39
- loading: "<li class=\"px-3 py-2 text-gray-500 italic\" role=\"status\" aria-live=\"polite\">{{loadingMessage}}</li>",
40
- tag: "<div data-kt-select-tag class=\"inline-flex items-center bg-blue-50 border border-blue-100 rounded px-2 py-1 text-sm mr-1 mb-1\"><span>{{title}}</span><span data-kt-select-remove-button data-value=\"{{id}}\" class=\"ml-1 text-blue-400 hover:text-blue-600 cursor-pointer\" role=\"button\" aria-label=\"Remove {{safeTitle}}\" tabindex=\"0\"><svg xmlns=\"http://www.w3.org/2000/svg\" width=\"12\" height=\"12\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\"></line><line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\"></line></svg></span></div>",
21
+ export var coreTemplateStrings = {
22
+ dropdown: "<div data-kt-select-dropdown class=\"kt-select-dropdown hidden {{class}}\" style=\"z-index: {{zindex}};\"></div>",
23
+ options: "<ul role=\"listbox\" aria-label=\"{{label}}\" class=\"kt-select-options {{class}}\" data-kt-select-options=\"true\"></ul>",
24
+ error: "<li class=\"kt-select-error\" role=\"alert\"></li>",
25
+ wrapper: "<div data-kt-select-wrapper class=\"kt-select-wrapper {{class}}\"></div>",
26
+ combobox: "\n\t\t<div data-kt-select-combobox data-kt-select-display class=\"kt-select-combobox {{class}}\">\n\t\t\t<div data-kt-select-combobox-values=\"true\" class=\"kt-select-combobox-values\"></div>\n\t\t\t<input class=\"kt-input kt-select-combobox-input\" data-kt-select-search=\"true\" type=\"text\" placeholder=\"{{placeholder}}\" role=\"searchbox\" aria-label=\"{{label}}\" {{disabled}} />\n\t\t\t<button type=\"button\" data-kt-select-clear-button=\"true\" class=\"kt-select-combobox-clear-btn\" aria-label=\"Clear selection\">\n\t\t\t\t<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n\t\t\t\t\t<line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\"></line>\n\t\t\t\t\t<line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\"></line>\n\t\t\t\t</svg>\n\t\t\t</button>\n\t\t</div>\n\t",
27
+ placeholder: "<div data-kt-select-placeholder class=\"kt-select-placeholder {{class}}\"></div>",
28
+ display: "\n\t\t<div data-kt-select-display class=\"kt-select-display {{class}}\" tabindex=\"{{tabindex}}\" role=\"button\" data-selected=\"0\" aria-haspopup=\"listbox\" aria-expanded=\"false\" aria-label=\"{{label}}\" {{disabled}}>\n\t\t\t<div class=\"kt-select-option-text\" data-kt-text-container=\"true\">{{text}}</div>\n\t\t</div>\n\t",
29
+ option: "\n\t\t<li data-kt-select-option data-value=\"{{value}}\" data-text=\"{{text}}\" class=\"kt-select-option {{class}}\" role=\"option\" {{selected}} {{disabled}}>\n\t\t\t<div class=\"kt-select-option-text\" data-kt-text-container=\"true\">{{text}}</div><svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"size-3.5 ms-auto hidden text-primary kt-select-option-selected:block\"><path d=\"M20 6 9 17l-5-5\"/></svg>\n\t\t</li>\n\t",
30
+ search: "<div data-kt-select-search class=\"kt-select-search {{class}}\"><input type=\"text\" data-kt-select-search=\"true\" placeholder=\"{{searchPlaceholder}}\" class=\"kt-input kt-input-ghost\" role=\"searchbox\" aria-label=\"{{searchPlaceholder}}\"/></div>",
31
+ empty: "<li data-kt-select-empty class=\"kt-select-no-result {{class}}\" role=\"status\"></li>",
32
+ loading: "<li class=\"kt-select-loading {{class}}\" role=\"status\" aria-live=\"polite\"></li>",
33
+ tag: "<div data-kt-select-tag=\"true\" class=\"kt-select-tag {{class}}\"></div>",
34
+ loadMore: "<li class=\"kt-select-load-more {{class}}\" data-kt-select-load-more=\"true\"></li>",
35
+ tagRemoveButton: "<button type=\"button\" data-kt-select-remove-button class=\"kt-select-tag-remove\" aria-label=\"Remove tag\" tabindex=\"0\"><svg width=\"12\" height=\"12\" viewBox=\"0 0 12 12\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\"><line x1=\"3\" y1=\"3\" x2=\"9\" y2=\"9\"/><line x1=\"9\" y1=\"3\" x2=\"3\" y2=\"9\"/></svg></button>",
41
36
  };
42
37
  /**
43
38
  * Default templates for KTSelect component
@@ -67,265 +62,238 @@ export function getTemplateStrings(config) {
67
62
  ? config.templates
68
63
  : undefined;
69
64
  if (templates) {
70
- return __assign(__assign(__assign({}, defaultTemplateStrings), userTemplateStrings), templates);
65
+ return __assign(__assign(__assign({}, coreTemplateStrings), userTemplateStrings), templates);
71
66
  }
72
- return __assign(__assign({}, defaultTemplateStrings), userTemplateStrings);
67
+ return __assign(__assign({}, coreTemplateStrings), userTemplateStrings);
73
68
  }
74
69
  /**
75
70
  * Default templates for KTSelect component
76
71
  */
77
72
  export var defaultTemplates = {
78
- /**
79
- * Renders a highlighted text
80
- */
81
- highlight: function (config, text) {
82
- var template = getTemplateStrings(config).highlight;
83
- var html = template.replace('{{text}}', text);
84
- return stringToElement(html);
85
- },
86
73
  /**
87
74
  * Renders the dropdown content
88
75
  */
89
- dropdownContent: function (config) {
90
- var template = getTemplateStrings(config).dropdownContent;
76
+ dropdown: function (config) {
77
+ var _a;
78
+ var template = getTemplateStrings(config).dropdown;
79
+ // If a custom dropdownTemplate is provided, it's responsible for its own content.
80
+ // Otherwise, the base template is used, and content is appended later.
81
+ if (config.dropdownTemplate) {
82
+ var renderedCustomTemplate = renderTemplateString(config.dropdownTemplate, {
83
+ zindex: config.zindex ? String(config.zindex) : '',
84
+ // content: config.content || '', // No longer pass content to custom template directly here
85
+ class: config.dropdownClass || '',
86
+ });
87
+ // The custom template IS the dropdown element
88
+ var customDropdownEl = stringToElement(renderedCustomTemplate);
89
+ if (config.zindex)
90
+ customDropdownEl.style.zIndex = String(config.zindex);
91
+ if (config.dropdownClass)
92
+ (_a = customDropdownEl.classList).add.apply(_a, config.dropdownClass.split(' '));
93
+ return customDropdownEl;
94
+ }
91
95
  var html = template
92
96
  .replace('{{zindex}}', config.zindex ? String(config.zindex) : '')
93
- .replace('{{content}}', config.content || '');
97
+ // .replace('{{content}}', '') // Content is no longer part of the base template string
98
+ .replace('{{class}}', config.dropdownClass || '');
94
99
  return stringToElement(html);
95
100
  },
96
101
  /**
97
102
  * Renders the options container for the dropdown
98
103
  */
99
- optionsContainer: function (config) {
100
- var template = getTemplateStrings(config).optionsContainer;
104
+ options: function (config) {
105
+ var template = getTemplateStrings(config).options;
101
106
  var html = template
102
107
  .replace('{{label}}', config.label || 'Options')
103
108
  .replace('{{height}}', config.height ? String(config.height) : '250')
104
- .replace('{{options}}', config.options || '');
105
- return stringToElement(html);
106
- },
107
- /**
108
- * Renders an empty option in the dropdown
109
- */
110
- emptyOption: function (config) {
111
- var template = getTemplateStrings(config).emptyOption;
112
- var html = template.replace('{{placeholder}}', config.placeholder || 'Select...');
113
- return stringToElement(html);
114
- },
115
- /**
116
- * Renders an error option in the dropdown
117
- */
118
- errorOption: function (config) {
119
- var template = getTemplateStrings(config).errorOption;
120
- var html = template.replace('{{errorMessage}}', config.errorMessage || 'An error occurred');
109
+ // .replace('{{options}}', '') // Options are now appended dynamically
110
+ .replace('{{class}}', config.optionsClass || '');
121
111
  return stringToElement(html);
122
112
  },
123
113
  /**
124
114
  * Renders the load more button for pagination
125
115
  */
126
116
  loadMore: function (config) {
127
- var html = getTemplateStrings(config).loadMore.replace('{{loadMoreText}}', config.loadMoreText || 'Load more...');
128
- return stringToElement(html);
117
+ var html = getTemplateStrings(config)
118
+ .loadMore // .replace('{{loadMoreText}}', config.loadMoreText || 'Load more...') // Content is no longer in template string
119
+ .replace('{{class}}', config.loadMoreClass || '');
120
+ var element = stringToElement(html);
121
+ element.textContent = config.loadMoreText || 'Load more...';
122
+ return element;
129
123
  },
130
124
  /**
131
125
  * Renders an error message in the dropdown
132
126
  */
133
127
  error: function (config) {
128
+ // Changed return type to HTMLElement
134
129
  var template = getTemplateStrings(config).error;
135
- return template.replace('{{errorMessage}}', config.errorMessage || 'An error occurred');
130
+ var html = template
131
+ // .replace('{{errorMessage}}', config.errorMessage || 'An error occurred') // Content is no longer in template string
132
+ .replace('{{class}}', config.errorClass || '');
133
+ var element = stringToElement(html);
134
+ element.textContent = config.errorMessage || 'An error occurred';
135
+ return element;
136
136
  },
137
137
  /**
138
138
  * Renders the main container for the select component
139
139
  */
140
- main: function (config) {
141
- var html = getTemplateStrings(config).main.replace('{{mode}}', config.mode || '');
142
- return stringToElement(html);
140
+ wrapper: function (config) {
141
+ var html = getTemplateStrings(config).wrapper.replace('{{class}}', config.wrapperClass || '');
142
+ var element = stringToElement(html);
143
+ element.setAttribute('data-kt-select-combobox', config.combobox ? 'true' : 'false');
144
+ element.setAttribute('data-kt-select-tags', config.tags ? 'true' : 'false');
145
+ return element;
143
146
  },
144
147
  /**
145
148
  * Renders the display element (trigger) for the select
146
149
  */
147
150
  display: function (config) {
148
- var isCombobox = config.mode === SelectMode.COMBOBOX;
149
- if (isCombobox) {
150
- var html_1 = getTemplateStrings(config)
151
- .displayCombobox.replace(/{{placeholder}}/g, config.placeholder || 'Select...')
152
- .replace(/{{label}}/g, config.label || config.placeholder || 'Select...')
153
- .replace('{{disabled}}', config.disabled ? 'disabled' : '');
154
- return stringToElement(html_1);
155
- }
156
151
  var html = getTemplateStrings(config)
157
152
  .display.replace('{{tabindex}}', config.disabled ? '-1' : '0')
158
153
  .replace('{{label}}', config.label || config.placeholder || 'Select...')
159
154
  .replace('{{disabled}}', config.disabled ? 'aria-disabled="true"' : '')
160
- .replace('{{placeholder}}', config.placeholder || 'Select...');
161
- return stringToElement(html);
162
- },
163
- /**
164
- * Renders the dropdown content container
165
- */
166
- dropdown: function (config, optionsHtml) {
167
- var isCombobox = config.mode === SelectMode.COMBOBOX;
168
- var hasSearch = config.enableSearch && !isCombobox;
169
- var template = getTemplateStrings(config).dropdown;
170
- var searchHtml = '';
171
- if (hasSearch) {
172
- var searchElement = defaultTemplates.search(config);
173
- searchHtml = searchElement.outerHTML;
155
+ .replace('{{placeholder}}', config.placeholder || 'Select...')
156
+ .replace('{{class}}', config.displayClass || '');
157
+ var element = stringToElement(html);
158
+ // Add data-multiple attribute if in multiple select mode
159
+ if (config.multiple) {
160
+ element.setAttribute('data-multiple', 'true');
174
161
  }
175
- var html = template
176
- .replace('{{search}}', searchHtml)
177
- .replace('{{options}}', optionsHtml)
178
- .replace('{{label}}', config.label || 'Options')
179
- .replace('{{height}}', config.height ? String(config.height) : '250');
180
- return stringToElement(html);
162
+ return element;
181
163
  },
182
164
  /**
183
165
  * Renders a single option
184
166
  */
185
167
  option: function (option, config) {
168
+ var _a, _b;
186
169
  var isHtmlOption = option instanceof HTMLOptionElement;
187
- var value = isHtmlOption ? option.value : option.id;
188
- var text = isHtmlOption ? option.text : option.title;
189
- var disabled = isHtmlOption
190
- ? option.disabled
191
- : option.disabled === true;
192
- var selected = isHtmlOption
193
- ? option.selected
194
- : !!option.selected;
195
- // Prefer data-kt-select-option (JSON) if present
196
- var description;
197
- var icon;
170
+ var optionData;
198
171
  if (isHtmlOption) {
199
- var json = option.getAttribute('data-kt-select-option');
200
- if (json) {
201
- try {
202
- var optionData = JSON.parse(json);
203
- description = optionData === null || optionData === void 0 ? void 0 : optionData.description;
204
- icon = optionData === null || optionData === void 0 ? void 0 : optionData.icon;
205
- }
206
- catch (e) {
207
- // fallback to legacy attributes if JSON is invalid
208
- description =
209
- option.getAttribute('data-kt-select-option-description') ||
210
- undefined;
211
- icon = option.getAttribute('data-kt-select-option-icon') || undefined;
212
- }
213
- }
214
- else {
215
- description =
216
- option.getAttribute('data-kt-select-option-description') || undefined;
217
- icon = option.getAttribute('data-kt-select-option-icon') || undefined;
218
- }
172
+ // If it's a plain HTMLOptionElement, construct data similarly to how KTSelectOption would
173
+ // This branch might be less common if KTSelectOption instances are always used for rendering.
174
+ var el = option;
175
+ var textContent = el.textContent || '';
176
+ optionData = __assign({ value: el.value, text: textContent, selected: el.selected, disabled: el.disabled, content: textContent }, (((_a = config.optionsConfig) === null || _a === void 0 ? void 0 : _a[el.value]) || {}));
219
177
  }
220
178
  else {
221
- description = option.description;
222
- icon = option.icon;
179
+ // If it's a KTSelectOption class instance (from './option')
180
+ // which should have the getOptionDataForTemplate method.
181
+ optionData = option.getOptionDataForTemplate();
223
182
  }
224
- // Build option element with proper accessibility attributes
225
- var selectedClass = selected ? ' selected' : '';
226
- var disabledClass = disabled ? ' disabled' : '';
227
- var html = getTemplateStrings(config)
228
- .option.replace('{{value}}', value)
229
- .replace('{{selectedClass}}', selectedClass)
230
- .replace('{{disabledClass}}', disabledClass)
231
- .replace('{{selected}}', selected ? 'aria-selected="true"' : 'aria-selected="false"')
232
- .replace('{{disabled}}', disabled ? 'aria-disabled="true"' : '')
233
- .replace(/{{icon}}/g, icon ? defaultTemplates.icon(icon, config).outerHTML : '')
234
- .replace('{{text}}', text)
235
- .replace(/{{description}}/g, description
236
- ? defaultTemplates.description(description, config).outerHTML
237
- : '');
238
- return stringToElement(html);
239
- },
240
- /**
241
- * Renders an icon
242
- */
243
- icon: function (icon, config) {
244
- var html = getTemplateStrings(config).icon.replace('{{icon}}', icon);
245
- return stringToElement(html);
246
- },
247
- /**
248
- * Renders a description
249
- */
250
- description: function (description, config) {
251
- var html = getTemplateStrings(config).description.replace('{{description}}', description);
252
- return stringToElement(html);
253
- },
254
- /**
255
- * Renders an option group with header
256
- */
257
- optionGroup: function (label, optionsHtml, config) {
258
- var html = getTemplateStrings(config)
259
- .optionGroup.replace(/{{label}}/g, label)
260
- .replace('{{optionsHtml}}', optionsHtml);
261
- return stringToElement(html);
183
+ var content = optionData.text; // Default content to option's text
184
+ if (config.optionTemplate) {
185
+ // Use the user-provided template string, rendering with the full optionData.
186
+ // renderTemplateString will replace {{key}} with values from optionData.
187
+ content = renderTemplateString(config.optionTemplate, optionData);
188
+ }
189
+ else {
190
+ content = optionData.text || optionData.content; // Prefer explicit text, fallback to content
191
+ }
192
+ // Use the core option template string as the base structure.
193
+ var baseTemplate = getTemplateStrings(config).option;
194
+ var optionClasses = [config.optionClass || ''];
195
+ if (optionData.disabled) {
196
+ optionClasses.push('disabled');
197
+ }
198
+ // Populate the base template for the <li> attributes.
199
+ // The actual display content (text or custom HTML) will be set on the inner span later.
200
+ var html = renderTemplateString(baseTemplate, __assign(__assign({}, optionData), { class: optionClasses.join(' ').trim() || '', selected: optionData.selected
201
+ ? 'aria-selected="true"'
202
+ : 'aria-selected="false"', disabled: optionData.disabled ? 'aria-disabled="true"' : '', content: content }));
203
+ var element = stringToElement(html);
204
+ // If a custom option template is provided, replace the element's innerHTML with the content.
205
+ if (config.optionTemplate) {
206
+ element.innerHTML = content;
207
+ }
208
+ // Ensure data-text attribute is set to the original, clean text for searching/filtering
209
+ element.setAttribute('data-text', ((_b = optionData === null || optionData === void 0 ? void 0 : optionData.text) === null || _b === void 0 ? void 0 : _b.trim()) || '');
210
+ return element;
262
211
  },
263
212
  /**
264
213
  * Renders the search input
265
214
  */
266
215
  search: function (config) {
267
- var html = getTemplateStrings(config).search.replace('{{searchPlaceholder}}', config.searchPlaceholder || 'Search...');
216
+ var html = getTemplateStrings(config)
217
+ .search.replace('{{searchPlaceholder}}', config.searchPlaceholder || 'Search...')
218
+ .replace('{{class}}', config.searchClass || '');
268
219
  return stringToElement(html);
269
220
  },
270
221
  /**
271
222
  * Renders the no results message
272
223
  */
273
- noResults: function (config) {
274
- var html = getTemplateStrings(config).noResults.replace('{{searchNotFoundText}}', config.searchNotFoundText || 'No results found');
275
- return stringToElement(html);
224
+ empty: function (config) {
225
+ var html = getTemplateStrings(config).empty.replace('{{class}}', config.emptyClass || '');
226
+ var element = stringToElement(html);
227
+ element.textContent = config.searchNotFoundText || 'No results found';
228
+ return element;
276
229
  },
277
230
  /**
278
231
  * Renders the loading state
279
232
  */
280
233
  loading: function (config, loadingMessage) {
281
- var html = getTemplateStrings(config).loading.replace('{{loadingMessage}}', loadingMessage || 'Loading options...');
282
- return stringToElement(html);
234
+ var html = getTemplateStrings(config).loading.replace('{{class}}', config.loadingClass || '');
235
+ var element = stringToElement(html);
236
+ element.textContent = loadingMessage || 'Loading options...';
237
+ return element;
283
238
  },
284
239
  /**
285
240
  * Renders a tag for multi-select
286
241
  */
287
242
  tag: function (option, config) {
288
- // Escape HTML characters for aria-label to prevent HTML injection
289
- var escapeHTML = function (str) {
290
- return str.replace(/[&<>"']/g, function (match) {
291
- var escapeMap = {
292
- '&': '&amp;',
293
- '<': '&lt;',
294
- '>': '&gt;',
295
- '"': '&quot;',
296
- "'": '&#39;',
297
- };
298
- return escapeMap[match];
243
+ var _a;
244
+ var template = getTemplateStrings(config).tag;
245
+ var preparedContent = option.title; // Default content is the option's title
246
+ if (config.tagTemplate) {
247
+ var tagTemplateString_1 = config.tagTemplate;
248
+ var optionValue = option.getAttribute('data-value') || option.value;
249
+ // Replace all {{varname}} in option.innerHTML with values from _config.optionsConfig
250
+ Object.entries(((_a = config.optionsConfig) === null || _a === void 0 ? void 0 : _a[optionValue]) || {}).forEach(function (_a) {
251
+ var key = _a[0], val = _a[1];
252
+ if (typeof val === 'string' ||
253
+ typeof val === 'number' ||
254
+ typeof val === 'boolean') {
255
+ tagTemplateString_1 = tagTemplateString_1.replace(new RegExp("{{".concat(key, "}}"), 'g'), String(val));
256
+ }
299
257
  });
300
- };
301
- // Ensure we have plain text for the aria-label
302
- var safeTitle = escapeHTML(option.title);
303
- var html = getTemplateStrings(config)
304
- .tag.replace('{{title}}', option.title)
305
- .replace('{{id}}', option.id)
306
- .replace('{{safeTitle}}', safeTitle);
307
- return stringToElement(html);
258
+ // Render the custom tag template with option data
259
+ preparedContent = renderTemplateString(tagTemplateString_1, {
260
+ title: option.title,
261
+ id: option.id,
262
+ class: config.tagClass || '', // This class is for content, not the main tag div
263
+ // content: option.innerHTML, // Avoid direct innerHTML from option due to potential XSS
264
+ text: option.innerText || option.textContent || '',
265
+ value: optionValue,
266
+ });
267
+ }
268
+ // Append the remove button HTML string to the prepared content
269
+ preparedContent += getTemplateStrings(config).tagRemoveButton;
270
+ var html = template
271
+ // .replace('{{title}}', option.title) // Title is part of preparedContent if using custom template
272
+ // .replace('{{id}}', option.id) // ID is part of preparedContent if using custom template
273
+ .replace('{{class}}', config.tagClass || ''); // Class for the main tag div
274
+ var element = stringToElement(html);
275
+ element.innerHTML = preparedContent; // Set the fully prepared content (text/HTML + remove button)
276
+ return element;
308
277
  },
309
278
  /**
310
- * Formats the display of selected values
279
+ * Renders the placeholder for the select
311
280
  */
312
- selectedDisplay: function (selectedOptions, config) {
313
- if (!selectedOptions || selectedOptions.length === 0) {
314
- return config.placeholder || 'Select...';
315
- }
316
- if (config.multiple) {
317
- if (config.renderSelected &&
318
- typeof config.renderSelected === 'function') {
319
- return config.renderSelected(selectedOptions);
320
- }
321
- if (config.showSelectedCount) {
322
- var count = selectedOptions.length;
323
- return "".concat(count, " ").concat(count === 1 ? 'item' : 'items', " selected");
324
- }
325
- return selectedOptions.map(function (option) { return option.title; }).join(', ');
281
+ placeholder: function (config) {
282
+ var html = getTemplateStrings(config).placeholder.replace('{{class}}', config.placeholderClass || '');
283
+ var content = config.placeholder || 'Select...';
284
+ if (config.placeholderTemplate) {
285
+ content = renderTemplateString(config.placeholderTemplate, {
286
+ placeholder: config.placeholder || 'Select...',
287
+ class: config.placeholderClass || '',
288
+ });
289
+ var element = stringToElement(html);
290
+ element.innerHTML = content; // For templates, content can be HTML
291
+ return element;
326
292
  }
327
293
  else {
328
- return selectedOptions[0].title;
294
+ var element = stringToElement(html);
295
+ element.textContent = content; // For simple text, use textContent
296
+ return element;
329
297
  }
330
298
  },
331
299
  };
@@ -1 +1 @@
1
- {"version":3,"file":"templates.js","sourceRoot":"","sources":["../../../../src/components/select/templates.ts"],"names":[],"mappings":"AAAA;;;GAGG;;;;;;;;;;;;AAGH,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC;;;GAGG;AACH,IAAM,sBAAsB,GAAG;IAC9B,eAAe,EAAE,2HAAuH;IACxI,gBAAgB,EAAE,uJAAiJ;IACnK,WAAW,EAAE,6CAA2C;IACxD,WAAW,EAAE,gEAA8D,EAAE,8BAA8B;IAE3G,QAAQ,EAAE,mIAAiI;IAC3I,QAAQ,EAAE,mUAKH;IACP,KAAK,EAAE,2EAAuE;IAE9E,SAAS,EAAE,2CAAyC;IACpD,IAAI,EAAE,wFAAoF;IAC1F,eAAe,EAAE,06BAQV;IAEP,IAAI,EAAE,iGAA2F;IACjG,WAAW,EAAE,+EAA6E;IAE1F,OAAO,EAAE,quBAOF;IACP,MAAM,EAAE,uUAA6T;IAErU,WAAW,EAAE,gLAAwK;IACrL,MAAM,EAAE,4PAAgP;IACxP,SAAS,EAAE,mFAA+E;IAC1F,OAAO,EAAE,2GAAqG;IAC9G,GAAG,EAAE,qpBAAumB;CAC5mB,CAAC;AAoFF;;GAEG;AACH,SAAS,eAAe,CAAC,IAAY;IACpC,IAAM,QAAQ,GAAG,QAAQ,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;IACpD,QAAQ,CAAC,SAAS,GAAG,IAAI,CAAC,IAAI,EAAE,CAAC;IACjC,OAAO,QAAQ,CAAC,OAAO,CAAC,iBAAgC,CAAC;AAC1D,CAAC;AAED;;GAEG;AACH,IAAI,mBAAmB,GAA2C,EAAE,CAAC;AAErE;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CACjC,SAAiD;IAE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AI,EAAE,CAAC,CAAC,CAAC,6BAA6B;QAE5E,IAAM,OAAO,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;QACtC,OAAO,CAAC,SAAS,GAAG,eAAe,CAAC,CAAC,6DAA6D;QAClG,OAAO,OAAO,CAAC;IAChB,CAAC;IAED;;OAEG;IACH,WAAW,EAAE,UAAC,MAA+B;QAC5C,IAAI,IAAI,GAAG,kBAAkB,CAAC,MAAM,CAAC,CAAC,WAAW,CAAC,OAAO,CACxD,WAAW,EACX,MAAM,CAAC,gBAAgB,IAAI,EAAE,CAC7B,CAAC;QAEF,IAAI,OAAO,GAAG,MAAM,CAAC,WAAW,IAAI,WAAW,CAAC;QAEhD,IAAI,MAAM,CAAC,mBAAmB,EAAE,CAAC;YAChC,OAAO,GAAG,oBAAoB,CAAC,MAAM,CAAC,mBAAmB,EAAE;gBAC1D,WAAW,EAAE,MAAM,CAAC,WAAW,IAAI,WAAW;gBAC9C,KAAK,EAAE,MAAM,CAAC,gBAAgB,IAAI,EAAE;aACpC,CAAC,CAAC;YACH,IAAM,OAAO,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;YACtC,OAAO,CAAC,SAAS,GAAG,OAAO,CAAC,CAAC,qCAAqC;YAClE,OAAO,OAAO,CAAC;QAChB,CAAC;aAAM,CAAC;YACP,IAAM,OAAO,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;YACtC,OAAO,CAAC,WAAW,GAAG,OAAO,CAAC,CAAC,mCAAmC;YAClE,OAAO,OAAO,CAAC;QAChB,CAAC;IACF,CAAC;CACD,CAAC"}
@@ -2,15 +2,5 @@
2
2
  * KTUI - Free & Open-Source Tailwind UI Components by Keenthemes
3
3
  * Copyright 2025 by Keenthemes Inc
4
4
  */
5
- /**
6
- * Common type interfaces for the KTSelect component
7
- */
8
- /**
9
- * Select mode options
10
- */
11
- export var SelectMode;
12
- (function (SelectMode) {
13
- SelectMode["TAGS"] = "tags";
14
- SelectMode["COMBOBOX"] = "combobox";
15
- })(SelectMode || (SelectMode = {}));
5
+ export {};
16
6
  //# sourceMappingURL=types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/components/select/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AAEH;;GAEG;AACH,MAAM,CAAN,IAAY,UAGX;AAHD,WAAY,UAAU;IACrB,2BAAa,CAAA;IACb,mCAAqB,CAAA;AACtB,CAAC,EAHW,UAAU,KAAV,UAAU,QAGrB"}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/components/select/types.ts"],"names":[],"mappings":"AAAA;;;GAGG"}