@esportsplus/ui 0.51.6 → 0.51.7

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 (68) hide show
  1. package/.github/workflows/bump.yml +4 -1
  2. package/.github/workflows/publish.yml +4 -0
  3. package/build/components/accordion/index.d.ts +17 -16
  4. package/build/components/accordion/index.js +16 -16
  5. package/build/components/alert/index.d.ts +7 -7
  6. package/build/components/alert/index.js +42 -42
  7. package/build/components/back/index.d.ts +8 -8
  8. package/build/components/back/index.js +10 -10
  9. package/build/components/button/index.d.ts +22 -22
  10. package/build/components/button/index.js +23 -23
  11. package/build/components/checkbox/index.d.ts +1 -1
  12. package/build/components/checkbox/index.js +23 -23
  13. package/build/components/clipboard/onclick.d.ts +1 -1
  14. package/build/components/clipboard/onclick.js +14 -14
  15. package/build/components/clipboard/write.d.ts +1 -1
  16. package/build/components/counter/index.d.ts +5 -5
  17. package/build/components/counter/index.js +34 -34
  18. package/build/components/ellipsis/index.d.ts +1 -1
  19. package/build/components/ellipsis/index.js +5 -5
  20. package/build/components/form/action.d.ts +3 -3
  21. package/build/components/form/action.js +8 -8
  22. package/build/components/form/index.d.ts +2 -2
  23. package/build/components/form/input.d.ts +8 -6
  24. package/build/components/frame/index.d.ts +10 -10
  25. package/build/components/frame/index.js +1 -1
  26. package/build/components/highlight/index.d.ts +17 -16
  27. package/build/components/highlight/index.js +15 -15
  28. package/build/components/icon/index.d.ts +11 -11
  29. package/build/components/icon/index.js +7 -7
  30. package/build/components/input/index.d.ts +1 -1
  31. package/build/components/input/index.js +21 -21
  32. package/build/components/json/download.d.ts +1 -1
  33. package/build/components/loader/index.d.ts +17 -16
  34. package/build/components/loader/index.js +33 -33
  35. package/build/components/loading/index.d.ts +1 -1
  36. package/build/components/loading/index.js +5 -5
  37. package/build/components/overlay/index.d.ts +10 -10
  38. package/build/components/overlay/index.js +1 -1
  39. package/build/components/radio/index.js +1 -1
  40. package/build/components/range/index.d.ts +1 -1
  41. package/build/components/range/index.js +26 -26
  42. package/build/components/root/index.d.ts +1 -4
  43. package/build/components/root/onclick.d.ts +4 -4
  44. package/build/components/scrollbar/index.d.ts +12 -12
  45. package/build/components/scrollbar/index.js +24 -24
  46. package/build/components/select/index.d.ts +2 -2
  47. package/build/components/select/index.js +44 -44
  48. package/build/components/sidebar/index.d.ts +10 -10
  49. package/build/components/sidebar/index.js +1 -1
  50. package/build/components/site/index.d.ts +10 -10
  51. package/build/components/site/index.js +2 -2
  52. package/build/components/switch/index.js +1 -1
  53. package/build/components/template/index.d.ts +10 -9
  54. package/build/components/textarea/index.d.ts +1 -1
  55. package/build/components/textarea/index.js +21 -21
  56. package/build/components/tooltip/menu.d.ts +11 -12
  57. package/build/components/tooltip/menu.js +21 -21
  58. package/build/components/tooltip/onclick.d.ts +1131 -1131
  59. package/build/components/tooltip/onclick.js +16 -16
  60. package/build/components/tooltip/onhover.d.ts +17 -16
  61. package/build/components/tooltip/onhover.js +16 -16
  62. package/build/components/typewriter/index.d.ts +11 -11
  63. package/build/components/typewriter/index.js +15 -15
  64. package/build/themes/dark/alert.d.ts +1 -1
  65. package/package.json +8 -8
  66. package/pnpm-workspace.yaml +8 -0
  67. package/src/components/alert/index.ts +2 -2
  68. package/src/components/tooltip/onclick.ts +1 -1
@@ -1,45 +1,45 @@
1
- import * as template_0ff113fe0a6246fbbfe92857b2a0303c1 from '@esportsplus/template';
2
- import * as reactivity_0ff113fe0a6246fbbfe92857b2a0303c0 from '@esportsplus/reactivity';
1
+ import * as template_u1 from '@esportsplus/template';
2
+ import * as reactivity_u0 from '@esportsplus/reactivity';
3
3
  import { EMPTY_ARRAY, omit, toArray } from '@esportsplus/utilities';
4
- import form from '../../components/form/index.js';
5
- import root from '../../components/root/index.js';
6
- import scrollbar from '../../components/scrollbar/index.js';
7
- import template from '../../components/template/index.js';
4
+ import form from '../form/index.js';
5
+ import root from '../root/index.js';
6
+ import scrollbar from '../scrollbar/index.js';
7
+ import template from '../template/index.js';
8
8
  import './scss/index.scss';
9
- const template_0ff113fe0a6246fbbfe92857b2a0303c2o = template_0ff113fe0a6246fbbfe92857b2a0303c1.template(`<div class='link select-option '>`);
10
- const template_0ff113fe0a6246fbbfe92857b2a0303c2r = template_0ff113fe0a6246fbbfe92857b2a0303c1.template(`<div class='select tooltip '><!--$--><div class='select-arrow'></div><input class='select-tag' />`);
11
- class ReactiveObject_0ff113fe0a6246fbbfe92857b2a0303c2m extends reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.ReactiveObject {
12
- #active = this[reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.SIGNAL](false);
13
- #error = this[reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.SIGNAL]('');
14
- #render = this[reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.SIGNAL](false);
9
+ const template_167mg1f2 = template_u1.template(`<div class='link select-option ' data-key='' >`);
10
+ const template_167mg1f5 = template_u1.template(`<div class='select tooltip '><!--$--><div class='select-arrow' ></div><input class='select-tag' />`);
11
+ class ReactiveObject_167mg1f0 extends reactivity_u0.ReactiveObject {
12
+ #active = this[reactivity_u0.SIGNAL](false);
13
+ #error = this[reactivity_u0.SIGNAL]('');
14
+ #render = this[reactivity_u0.SIGNAL](false);
15
15
  #selected;
16
16
  constructor(_p0) {
17
17
  super(null);
18
- this.#selected = this[reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.SIGNAL](_p0);
18
+ this.#selected = this[reactivity_u0.SIGNAL](_p0);
19
19
  }
20
20
  get active() {
21
- return reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.read(this.#active);
21
+ return reactivity_u0.read(this.#active);
22
22
  }
23
23
  set active(_v0) {
24
- reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.write(this.#active, _v0);
24
+ reactivity_u0.write(this.#active, _v0);
25
25
  }
26
26
  get error() {
27
- return reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.read(this.#error);
27
+ return reactivity_u0.read(this.#error);
28
28
  }
29
29
  set error(_v1) {
30
- reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.write(this.#error, _v1);
30
+ reactivity_u0.write(this.#error, _v1);
31
31
  }
32
32
  get render() {
33
- return reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.read(this.#render);
33
+ return reactivity_u0.read(this.#render);
34
34
  }
35
35
  set render(_v2) {
36
- reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.write(this.#render, _v2);
36
+ reactivity_u0.write(this.#render, _v2);
37
37
  }
38
38
  get selected() {
39
- return reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.read(this.#selected);
39
+ return reactivity_u0.read(this.#selected);
40
40
  }
41
41
  set selected(_v3) {
42
- reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.write(this.#selected, _v3);
42
+ reactivity_u0.write(this.#selected, _v3);
43
43
  }
44
44
  }
45
45
  const OMIT = [
@@ -78,19 +78,19 @@ function set(current, value) {
78
78
  }
79
79
  }
80
80
  const select = template.factory(function (attributes, content) {
81
- let { options, option } = attributes, state = attributes.state || new ReactiveObject_0ff113fe0a6246fbbfe92857b2a0303c2m(attributes.selected || Object.keys(options)[0]);
81
+ let { options, option } = attributes, state = attributes.state || new ReactiveObject_167mg1f0(attributes.selected || Object.keys(options)[0]);
82
82
  return (() => {
83
- let root_0ff113fe0a6246fbbfe92857b2a0303c2q = template_0ff113fe0a6246fbbfe92857b2a0303c2r(), element_0ff113fe0a6246fbbfe92857b2a0303c2s = root_0ff113fe0a6246fbbfe92857b2a0303c2q.firstChild, element_0ff113fe0a6246fbbfe92857b2a0303c2t = element_0ff113fe0a6246fbbfe92857b2a0303c2s.firstChild, element_0ff113fe0a6246fbbfe92857b2a0303c2u = element_0ff113fe0a6246fbbfe92857b2a0303c2s.firstElementChild, element_0ff113fe0a6246fbbfe92857b2a0303c2v = element_0ff113fe0a6246fbbfe92857b2a0303c2u.nextElementSibling;
84
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setList(element_0ff113fe0a6246fbbfe92857b2a0303c2s, 'class', () => state.active && '--active');
85
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2s, this?.attributes && omit(this.attributes, OMIT));
86
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2s, omit(attributes, OMIT));
87
- template_0ff113fe0a6246fbbfe92857b2a0303c1.delegate(element_0ff113fe0a6246fbbfe92857b2a0303c2s, 'click', () => {
83
+ let root_167mg1f4 = template_167mg1f5(), element_167mg1f6 = root_167mg1f4.firstChild, element_167mg1f7 = element_167mg1f6.firstChild, element_167mg1f8 = element_167mg1f6.firstElementChild, element_167mg1f9 = element_167mg1f8.nextElementSibling;
84
+ template_u1.setList(element_167mg1f6, 'class', () => state.active && '--active');
85
+ template_u1.setProperties(element_167mg1f6, this?.attributes && omit(this.attributes, OMIT));
86
+ template_u1.setProperties(element_167mg1f6, omit(attributes, OMIT));
87
+ template_u1.delegate(element_167mg1f6, 'click', () => {
88
88
  if (state.render) {
89
89
  set(state, !state.active);
90
90
  }
91
91
  state.render = true;
92
92
  });
93
- new template_0ff113fe0a6246fbbfe92857b2a0303c1.EffectSlot(element_0ff113fe0a6246fbbfe92857b2a0303c2t, content ? (() => content(state)) : (() => {
93
+ new template_u1.EffectSlot(element_167mg1f7, content ? (() => content(state)) : (() => {
94
94
  let selected = options[state.selected];
95
95
  if (!selected) {
96
96
  return '-';
@@ -100,17 +100,17 @@ const select = template.factory(function (attributes, content) {
100
100
  }
101
101
  return selected;
102
102
  }));
103
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2u, this?.attributes?.arrow);
104
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2u, attributes.arrow);
105
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperty(element_0ff113fe0a6246fbbfe92857b2a0303c2v, 'name', attributes.name);
106
- template_0ff113fe0a6246fbbfe92857b2a0303c1.delegate(element_0ff113fe0a6246fbbfe92857b2a0303c2v, 'click', () => { });
107
- template_0ff113fe0a6246fbbfe92857b2a0303c1.onrender(element_0ff113fe0a6246fbbfe92857b2a0303c2v, form.input.onrender(state));
108
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperty(element_0ff113fe0a6246fbbfe92857b2a0303c2v, 'value', () => state.selected);
109
- new template_0ff113fe0a6246fbbfe92857b2a0303c1.EffectSlot(element_0ff113fe0a6246fbbfe92857b2a0303c2s, () => {
103
+ template_u1.setProperties(element_167mg1f8, this?.attributes?.arrow);
104
+ template_u1.setProperties(element_167mg1f8, attributes.arrow);
105
+ template_u1.setProperty(element_167mg1f9, 'name', attributes.name);
106
+ template_u1.delegate(element_167mg1f9, 'click', () => { });
107
+ template_u1.onrender(element_167mg1f9, form.input.onrender(state));
108
+ template_u1.setProperty(element_167mg1f9, 'value', () => state.selected);
109
+ new template_u1.EffectSlot(element_167mg1f6, () => {
110
110
  if (!state.render) {
111
111
  return;
112
112
  }
113
- let keys = Object.keys(options), selected = reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.reactive(Object.fromEntries(keys.map(key => [key, false])));
113
+ let keys = Object.keys(options), selected = reactivity_u0.reactive(Object.fromEntries(keys.map(key => [key, false])));
114
114
  return sb({
115
115
  ...this?.attributes?.['tooltip-content'] || EMPTY_ARRAY,
116
116
  ...attributes['tooltip-content'],
@@ -154,17 +154,17 @@ const select = template.factory(function (attributes, content) {
154
154
  content = content.content;
155
155
  }
156
156
  return (() => {
157
- let root_0ff113fe0a6246fbbfe92857b2a0303c2n = template_0ff113fe0a6246fbbfe92857b2a0303c2o(), element_0ff113fe0a6246fbbfe92857b2a0303c2p = root_0ff113fe0a6246fbbfe92857b2a0303c2n.firstChild;
158
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setList(element_0ff113fe0a6246fbbfe92857b2a0303c2p, 'class', () => selected[key] && '--active');
159
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2p, this?.attributes?.option);
160
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2p, option);
161
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperty(element_0ff113fe0a6246fbbfe92857b2a0303c2p, 'data-key', key);
162
- template_0ff113fe0a6246fbbfe92857b2a0303c1.slot(element_0ff113fe0a6246fbbfe92857b2a0303c2p, content, 1);
163
- return root_0ff113fe0a6246fbbfe92857b2a0303c2n;
157
+ let root_167mg1f1 = template_167mg1f2(), element_167mg1f3 = root_167mg1f1.firstChild;
158
+ template_u1.setList(element_167mg1f3, 'class', () => selected[key] && '--active');
159
+ template_u1.setProperties(element_167mg1f3, this?.attributes?.option);
160
+ template_u1.setProperties(element_167mg1f3, option);
161
+ template_u1.setProperty(element_167mg1f3, 'data-key', key);
162
+ template_u1.slot(element_167mg1f3, content, 1);
163
+ return root_167mg1f1;
164
164
  })();
165
165
  }));
166
166
  }, 2);
167
- return root_0ff113fe0a6246fbbfe92857b2a0303c2q;
167
+ return root_167mg1f4;
168
168
  })();
169
169
  });
170
170
  export default select;
@@ -1,20 +1,20 @@
1
1
  import './scss/index.scss';
2
2
  declare const _default: {
3
3
  (): ReturnType<(this: {
4
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
4
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
5
5
  content?: import("@esportsplus/template").Renderable<any>;
6
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
7
- <T extends import("../../components/scrollbar/index.js").Attributes>(attributes: T): ReturnType<(this: {
8
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
6
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
7
+ <T extends import("../scrollbar/index.js").Attributes>(attributes: T): ReturnType<(this: {
8
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
9
9
  content?: import("@esportsplus/template").Renderable<any>;
10
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
10
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
11
11
  <T extends import("@esportsplus/template").Renderable<any>>(content: T): ReturnType<(this: {
12
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
12
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
13
13
  content?: import("@esportsplus/template").Renderable<any>;
14
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
15
- (attributes: import("../../components/scrollbar/index.js").Attributes, content: import("@esportsplus/template").Renderable<any>): ReturnType<(this: {
16
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
14
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
15
+ (attributes: import("../scrollbar/index.js").Attributes, content: import("@esportsplus/template").Renderable<any>): ReturnType<(this: {
16
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
17
17
  content?: import("@esportsplus/template").Renderable<any>;
18
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
18
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
19
19
  };
20
20
  export default _default;
@@ -1,4 +1,4 @@
1
- import scrollbar from '../../components/scrollbar/index.js';
1
+ import scrollbar from '../scrollbar/index.js';
2
2
  import './scss/index.scss';
3
3
  export default scrollbar.bind({
4
4
  attributes: {
@@ -1,20 +1,20 @@
1
1
  import './scss/index.scss';
2
2
  declare const _default: {
3
3
  (): ReturnType<(this: {
4
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
4
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
5
5
  content?: import("@esportsplus/template").Renderable<any>;
6
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
7
- <T extends import("../../components/scrollbar/index.js").Attributes>(attributes: T): ReturnType<(this: {
8
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
6
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
7
+ <T extends import("../scrollbar/index.js").Attributes>(attributes: T): ReturnType<(this: {
8
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
9
9
  content?: import("@esportsplus/template").Renderable<any>;
10
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
10
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
11
11
  <T extends import("@esportsplus/template").Renderable<any>>(content: T): ReturnType<(this: {
12
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
12
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
13
13
  content?: import("@esportsplus/template").Renderable<any>;
14
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
15
- (attributes: import("../../components/scrollbar/index.js").Attributes, content: import("@esportsplus/template").Renderable<any>): ReturnType<(this: {
16
- attributes?: import("../../components/scrollbar/index.js").Attributes | undefined;
14
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
15
+ (attributes: import("../scrollbar/index.js").Attributes, content: import("@esportsplus/template").Renderable<any>): ReturnType<(this: {
16
+ attributes?: import("../scrollbar/index.js").Attributes | undefined;
17
17
  content?: import("@esportsplus/template").Renderable<any>;
18
- }, attributes: Readonly<import("../../components/scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
18
+ }, attributes: Readonly<import("../scrollbar/index.js").Attributes>, content: import("@esportsplus/template").Renderable<any>) => import("@esportsplus/template").Renderable<any>>;
19
19
  };
20
20
  export default _default;
@@ -1,5 +1,5 @@
1
- import { onclick } from '../../components/root/index.js';
2
- import scrollbar from '../../components/scrollbar/index.js';
1
+ import { onclick } from '../root/index.js';
2
+ import scrollbar from '../scrollbar/index.js';
3
3
  import './scss/index.scss';
4
4
  export default scrollbar.bind({
5
5
  attributes: {
@@ -1,3 +1,3 @@
1
- import { factory } from '../../components/checkbox/index.js';
1
+ import { factory } from '../checkbox/index.js';
2
2
  import './scss/index.scss';
3
3
  export default factory('switch');
@@ -1,13 +1,14 @@
1
1
  import { Attributes, Renderable } from '@esportsplus/template';
2
+ declare const factory: <A extends Attributes, C = Renderable<any>, Context = {
3
+ attributes?: A;
4
+ content?: C;
5
+ }>(template: (this: Context, attributes: Readonly<A>, content: C) => Renderable<any>) => {
6
+ (): ReturnType<typeof template>;
7
+ <T extends A>(attributes: T): ReturnType<typeof template>;
8
+ <T extends C>(content: T): ReturnType<typeof template>;
9
+ (attributes: A, content: C): ReturnType<typeof template>;
10
+ };
2
11
  declare const _default: {
3
- factory: <A extends Attributes, C = Renderable<any>, Context = {
4
- attributes?: A;
5
- content?: C;
6
- }>(template: (this: Context, attributes: Readonly<A>, content: C) => Renderable<any>) => {
7
- (): ReturnType<typeof template>;
8
- <T extends A>(attributes: T): ReturnType<typeof template>;
9
- <T extends C>(content: T): ReturnType<typeof template>;
10
- (attributes: A, content: C): ReturnType<typeof template>;
11
- };
12
+ factory: typeof factory;
12
13
  };
13
14
  export default _default;
@@ -1,4 +1,4 @@
1
- import { Attributes } from '@esportsplus/template';
1
+ import { type Attributes } from '@esportsplus/template';
2
2
  import './scss/index.scss';
3
3
  export default function (this: {
4
4
  attributes?: Attributes;
@@ -1,45 +1,45 @@
1
- import * as template_0ff113fe0a6246fbbfe92857b2a0303c1 from '@esportsplus/template';
2
- import * as reactivity_0ff113fe0a6246fbbfe92857b2a0303c0 from '@esportsplus/reactivity';
1
+ import * as template_u1 from '@esportsplus/template';
2
+ import * as reactivity_u0 from '@esportsplus/reactivity';
3
3
  import { omit } from '@esportsplus/utilities';
4
- import form from '../../components/form/index.js';
4
+ import form from '../form/index.js';
5
5
  import './scss/index.scss';
6
- const template_0ff113fe0a6246fbbfe92857b2a0303c2y = template_0ff113fe0a6246fbbfe92857b2a0303c1.template(`<textarea class='textarea'>`);
7
- class ReactiveObject_0ff113fe0a6246fbbfe92857b2a0303c2w extends reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.ReactiveObject {
8
- #active = this[reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.SIGNAL](false);
9
- #error = this[reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.SIGNAL]('');
6
+ const template_1x5yfkx2 = template_u1.template(`<textarea class='textarea' >`);
7
+ class ReactiveObject_1x5yfkx0 extends reactivity_u0.ReactiveObject {
8
+ #active = this[reactivity_u0.SIGNAL](false);
9
+ #error = this[reactivity_u0.SIGNAL]('');
10
10
  constructor() {
11
11
  super(null);
12
12
  }
13
13
  get active() {
14
- return reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.read(this.#active);
14
+ return reactivity_u0.read(this.#active);
15
15
  }
16
16
  set active(_v0) {
17
- reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.write(this.#active, _v0);
17
+ reactivity_u0.write(this.#active, _v0);
18
18
  }
19
19
  get error() {
20
- return reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.read(this.#error);
20
+ return reactivity_u0.read(this.#error);
21
21
  }
22
22
  set error(_v1) {
23
- reactivity_0ff113fe0a6246fbbfe92857b2a0303c0.write(this.#error, _v1);
23
+ reactivity_u0.write(this.#error, _v1);
24
24
  }
25
25
  }
26
26
  const OMIT = ['state'];
27
27
  export default function (attributes) {
28
- let state = attributes.state || new ReactiveObject_0ff113fe0a6246fbbfe92857b2a0303c2w();
28
+ let state = attributes.state || new ReactiveObject_1x5yfkx0();
29
29
  return (() => {
30
- let root_0ff113fe0a6246fbbfe92857b2a0303c2x = template_0ff113fe0a6246fbbfe92857b2a0303c2y(), element_0ff113fe0a6246fbbfe92857b2a0303c2z = root_0ff113fe0a6246fbbfe92857b2a0303c2x.firstChild;
31
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2z, this?.attributes && omit(this.attributes, OMIT));
32
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c2z, omit(attributes, OMIT));
33
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setList(element_0ff113fe0a6246fbbfe92857b2a0303c2z, 'class', () => state.active && '--active');
34
- template_0ff113fe0a6246fbbfe92857b2a0303c1.on(element_0ff113fe0a6246fbbfe92857b2a0303c2z, 'focusin', () => {
30
+ let root_1x5yfkx1 = template_1x5yfkx2(), element_1x5yfkx3 = root_1x5yfkx1.firstChild;
31
+ template_u1.setProperties(element_1x5yfkx3, this?.attributes && omit(this.attributes, OMIT));
32
+ template_u1.setProperties(element_1x5yfkx3, omit(attributes, OMIT));
33
+ template_u1.setList(element_1x5yfkx3, 'class', () => state.active && '--active');
34
+ template_u1.on(element_1x5yfkx3, 'focusin', () => {
35
35
  state.active = true;
36
36
  });
37
- template_0ff113fe0a6246fbbfe92857b2a0303c1.on(element_0ff113fe0a6246fbbfe92857b2a0303c2z, 'focusout', () => {
37
+ template_u1.on(element_1x5yfkx3, 'focusout', () => {
38
38
  state.active = false;
39
39
  });
40
- template_0ff113fe0a6246fbbfe92857b2a0303c1.onrender(element_0ff113fe0a6246fbbfe92857b2a0303c2z, form.input.onrender(state));
41
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperty(element_0ff113fe0a6246fbbfe92857b2a0303c2z, 'value', attributes?.value || '');
42
- return root_0ff113fe0a6246fbbfe92857b2a0303c2x;
40
+ template_u1.onrender(element_1x5yfkx3, form.input.onrender(state));
41
+ template_u1.setProperty(element_1x5yfkx3, 'value', attributes?.value || '');
42
+ return root_1x5yfkx1;
43
43
  })();
44
44
  }
45
45
  ;
@@ -1,5 +1,4 @@
1
- import * as template_0ff113fe0a6246fbbfe92857b2a0303c1 from '@esportsplus/template';
2
- import { Attributes, Renderable } from '@esportsplus/template';
1
+ import { type Attributes, type Renderable } from '@esportsplus/template';
3
2
  type A = Attributes & {
4
3
  options: (Attributes & {
5
4
  content: Renderable<unknown>;
@@ -16,19 +15,19 @@ type A = Attributes & {
16
15
  declare const _default: {
17
16
  (): ReturnType<(this: {
18
17
  attributes?: A | undefined;
19
- content?: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>;
20
- }, attributes: Readonly<A>, content: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>) => Renderable<any>>;
18
+ content?: Renderable<any>;
19
+ }, attributes: Readonly<A>, content: Renderable<any>) => Renderable<any>>;
21
20
  <T extends A>(attributes: T): ReturnType<(this: {
22
21
  attributes?: A | undefined;
23
- content?: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>;
24
- }, attributes: Readonly<A>, content: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>) => Renderable<any>>;
25
- <T extends template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>>(content: T): ReturnType<(this: {
22
+ content?: Renderable<any>;
23
+ }, attributes: Readonly<A>, content: Renderable<any>) => Renderable<any>>;
24
+ <T extends Renderable<any>>(content: T): ReturnType<(this: {
26
25
  attributes?: A | undefined;
27
- content?: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>;
28
- }, attributes: Readonly<A>, content: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>) => Renderable<any>>;
29
- (attributes: A, content: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>): ReturnType<(this: {
26
+ content?: Renderable<any>;
27
+ }, attributes: Readonly<A>, content: Renderable<any>) => Renderable<any>>;
28
+ (attributes: A, content: Renderable<any>): ReturnType<(this: {
30
29
  attributes?: A | undefined;
31
- content?: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>;
32
- }, attributes: Readonly<A>, content: template_0ff113fe0a6246fbbfe92857b2a0303c1.Renderable<any>) => Renderable<any>>;
30
+ content?: Renderable<any>;
31
+ }, attributes: Readonly<A>, content: Renderable<any>) => Renderable<any>>;
33
32
  };
34
33
  export default _default;
@@ -1,38 +1,38 @@
1
- import * as template_0ff113fe0a6246fbbfe92857b2a0303c1 from '@esportsplus/template';
1
+ import * as template_u1 from '@esportsplus/template';
2
2
  import { omit } from '@esportsplus/utilities';
3
- import template from '../../components/template/index.js';
3
+ import template from '../template/index.js';
4
4
  import onclick from './onclick.js';
5
- const template_0ff113fe0a6246fbbfe92857b2a0303c31 = template_0ff113fe0a6246fbbfe92857b2a0303c1.template(`<a class='link --width-full' target='_blank'>`);
6
- const template_0ff113fe0a6246fbbfe92857b2a0303c34 = template_0ff113fe0a6246fbbfe92857b2a0303c1.template(`<div class='link --width-full'>`);
7
- const template_0ff113fe0a6246fbbfe92857b2a0303c37 = template_0ff113fe0a6246fbbfe92857b2a0303c1.template(`<!--$--><div class='tooltip-content '>`);
5
+ const template_0p4v5171 = template_u1.template(`<a class='link --width-full' target='_blank' >`);
6
+ const template_0p4v5174 = template_u1.template(`<div class='link --width-full' >`);
7
+ const template_0p4v5177 = template_u1.template(`<!--$--><div class='tooltip-content ' >`);
8
8
  const OMIT = ['options', 'option', 'tooltip-content'];
9
9
  const OMIT_OPTION = ['content'];
10
10
  const OMIT_TOOLTIP_CONTENT = ['direction'];
11
11
  export default template.factory((attributes, content) => {
12
12
  let options = attributes.options, option = attributes.option, tooltipContent = attributes?.['tooltip-content'], tooltipContentDirection = tooltipContent?.direction || 'nw';
13
13
  return onclick(omit(attributes, OMIT), (() => {
14
- let root_0ff113fe0a6246fbbfe92857b2a0303c36 = template_0ff113fe0a6246fbbfe92857b2a0303c37(), element_0ff113fe0a6246fbbfe92857b2a0303c38 = root_0ff113fe0a6246fbbfe92857b2a0303c36.firstChild, element_0ff113fe0a6246fbbfe92857b2a0303c39 = element_0ff113fe0a6246fbbfe92857b2a0303c38.nextSibling;
15
- template_0ff113fe0a6246fbbfe92857b2a0303c1.slot(element_0ff113fe0a6246fbbfe92857b2a0303c38, content);
16
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setList(element_0ff113fe0a6246fbbfe92857b2a0303c39, 'class', `tooltip-content--${tooltipContentDirection}`);
17
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c39, tooltipContent && omit(tooltipContent, OMIT_TOOLTIP_CONTENT));
18
- template_0ff113fe0a6246fbbfe92857b2a0303c1.slot(element_0ff113fe0a6246fbbfe92857b2a0303c39, options.map((o) => {
14
+ let root_0p4v5176 = template_0p4v5177(), element_0p4v5178 = root_0p4v5176.firstChild, element_0p4v5179 = element_0p4v5178.nextSibling;
15
+ template_u1.slot(element_0p4v5178, content);
16
+ template_u1.setList(element_0p4v5179, 'class', `tooltip-content--${tooltipContentDirection}`);
17
+ template_u1.setProperties(element_0p4v5179, tooltipContent && omit(tooltipContent, OMIT_TOOLTIP_CONTENT));
18
+ template_u1.slot(element_0p4v5179, options.map((o) => {
19
19
  if (o.href) {
20
20
  return (() => {
21
- let root_0ff113fe0a6246fbbfe92857b2a0303c30 = template_0ff113fe0a6246fbbfe92857b2a0303c31(), element_0ff113fe0a6246fbbfe92857b2a0303c32 = root_0ff113fe0a6246fbbfe92857b2a0303c30.firstChild;
22
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c32, omit(o, OMIT_OPTION));
23
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c32, option);
24
- template_0ff113fe0a6246fbbfe92857b2a0303c1.slot(element_0ff113fe0a6246fbbfe92857b2a0303c32, o.content, 1);
25
- return root_0ff113fe0a6246fbbfe92857b2a0303c30;
21
+ let root_0p4v5170 = template_0p4v5171(), element_0p4v5172 = root_0p4v5170.firstChild;
22
+ template_u1.setProperties(element_0p4v5172, omit(o, OMIT_OPTION));
23
+ template_u1.setProperties(element_0p4v5172, option);
24
+ template_u1.slot(element_0p4v5172, o.content, 1);
25
+ return root_0p4v5170;
26
26
  })();
27
27
  }
28
28
  return (() => {
29
- let root_0ff113fe0a6246fbbfe92857b2a0303c33 = template_0ff113fe0a6246fbbfe92857b2a0303c34(), element_0ff113fe0a6246fbbfe92857b2a0303c35 = root_0ff113fe0a6246fbbfe92857b2a0303c33.firstChild;
30
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c35, omit(o, OMIT_OPTION));
31
- template_0ff113fe0a6246fbbfe92857b2a0303c1.setProperties(element_0ff113fe0a6246fbbfe92857b2a0303c35, option);
32
- template_0ff113fe0a6246fbbfe92857b2a0303c1.slot(element_0ff113fe0a6246fbbfe92857b2a0303c35, o.content, 1);
33
- return root_0ff113fe0a6246fbbfe92857b2a0303c33;
29
+ let root_0p4v5173 = template_0p4v5174(), element_0p4v5175 = root_0p4v5173.firstChild;
30
+ template_u1.setProperties(element_0p4v5175, omit(o, OMIT_OPTION));
31
+ template_u1.setProperties(element_0p4v5175, option);
32
+ template_u1.slot(element_0p4v5175, o.content, 1);
33
+ return root_0p4v5173;
34
34
  })();
35
35
  }), 1);
36
- return root_0ff113fe0a6246fbbfe92857b2a0303c36;
36
+ return root_0p4v5176;
37
37
  })());
38
38
  });