@marianmeres/stuic 1.82.0 → 1.84.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -193,6 +193,7 @@ $:
193
193
  class={_inputClass}
194
194
  class:cursor-not-allowed={disabled}
195
195
  {name}
196
+ {placeholder}
196
197
  {disabled}
197
198
  {readonly}
198
199
  {required}
@@ -37,7 +37,7 @@ onMount(() => {
37
37
  _el.addEventListener("cancel", _handleCancel);
38
38
  _unsubs.push(() => _el.removeEventListener("cancel", _handleCancel));
39
39
  const _handleKeyDown = (e) => {
40
- if (closeOnEscape && e.key === "Escape") {
40
+ if (_open && closeOnEscape && e.key === "Escape") {
41
41
  e.stopPropagation();
42
42
  close();
43
43
  }
@@ -45,7 +45,7 @@ onMount(() => {
45
45
  document.addEventListener("keydown", _handleKeyDown, true);
46
46
  _unsubs.push(() => document.removeEventListener("keydown", _handleKeyDown, true));
47
47
  const _handleClick = (e) => {
48
- closeOnOutsideClick && /dialog/i.test(e.target?.tagName) && close();
48
+ _open && closeOnOutsideClick && /dialog/i.test(e.target?.tagName) && close();
49
49
  };
50
50
  _el.addEventListener("click", _handleClick);
51
51
  _unsubs.push(() => _el.removeEventListener("click", _handleClick));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@marianmeres/stuic",
3
- "version": "1.82.0",
3
+ "version": "1.84.0",
4
4
  "scripts": {
5
5
  "dev": "vite dev",
6
6
  "build": "vite build && npm run package && node ./scripts/date.js",