@esportsplus/ui 0.49.0 → 0.49.1

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 (41) hide show
  1. package/build/components/accordion/index.d.ts +16 -16
  2. package/build/components/accordion/index.js +15 -16
  3. package/build/components/alert/index.js +42 -50
  4. package/build/components/back/index.d.ts +8 -7
  5. package/build/components/back/index.js +10 -11
  6. package/build/components/button/index.d.ts +22 -21
  7. package/build/components/button/index.js +24 -24
  8. package/build/components/checkbox/index.d.ts +1 -1
  9. package/build/components/checkbox/index.js +18 -20
  10. package/build/components/clipboard/onclick.d.ts +1 -1
  11. package/build/components/clipboard/onclick.js +18 -17
  12. package/build/components/counter/index.d.ts +1 -1
  13. package/build/components/counter/index.js +34 -27
  14. package/build/components/ellipsis/index.js +7 -8
  15. package/build/components/form/action.js +12 -15
  16. package/build/components/highlight/index.d.ts +16 -16
  17. package/build/components/highlight/index.js +13 -14
  18. package/build/components/icon/index.d.ts +11 -10
  19. package/build/components/icon/index.js +9 -6
  20. package/build/components/input/index.d.ts +1 -1
  21. package/build/components/input/index.js +16 -17
  22. package/build/components/loader/index.d.ts +16 -16
  23. package/build/components/loader/index.js +37 -44
  24. package/build/components/loading/index.js +7 -9
  25. package/build/components/range/index.d.ts +1 -1
  26. package/build/components/range/index.js +19 -21
  27. package/build/components/scrollbar/index.d.ts +12 -11
  28. package/build/components/scrollbar/index.js +19 -32
  29. package/build/components/select/index.d.ts +1 -1
  30. package/build/components/select/index.js +83 -88
  31. package/build/components/textarea/index.d.ts +1 -1
  32. package/build/components/textarea/index.js +16 -17
  33. package/build/components/tooltip/menu.d.ts +12 -11
  34. package/build/components/tooltip/menu.js +29 -33
  35. package/build/components/tooltip/onclick.d.ts +1101 -1100
  36. package/build/components/tooltip/onclick.js +12 -14
  37. package/build/components/tooltip/onhover.d.ts +16 -16
  38. package/build/components/tooltip/onhover.js +14 -16
  39. package/build/components/typewriter/index.d.ts +11 -10
  40. package/build/components/typewriter/index.js +12 -10
  41. package/package.json +3 -3
@@ -1,21 +1,21 @@
1
- import { Attributes } from '@esportsplus/frontend';
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
2
2
  import './scss/index.scss';
3
3
  declare const _default: {
4
4
  (): ReturnType<(this: {
5
- attributes?: Attributes | undefined;
6
- content?: import("@esportsplus/frontend").Renderable<any>;
7
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
8
- <T extends Attributes>(attributes: T): ReturnType<(this: {
9
- attributes?: Attributes | undefined;
10
- content?: import("@esportsplus/frontend").Renderable<any>;
11
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
12
- <T extends import("@esportsplus/frontend").Renderable<any>>(content: T): ReturnType<(this: {
13
- attributes?: Attributes | undefined;
14
- content?: import("@esportsplus/frontend").Renderable<any>;
15
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
16
- (attributes: Attributes, content: import("@esportsplus/frontend").Renderable<any>): ReturnType<(this: {
17
- attributes?: Attributes | undefined;
18
- content?: import("@esportsplus/frontend").Renderable<any>;
19
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
5
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
6
+ content?: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>;
7
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
8
+ <T extends template_88a2fd04bc87484a954d07fc771290fa0.Attributes>(attributes: T): ReturnType<(this: {
9
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
10
+ content?: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>;
11
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
12
+ <T extends template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>(content: T): ReturnType<(this: {
13
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
14
+ content?: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>;
15
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
16
+ (attributes: template_88a2fd04bc87484a954d07fc771290fa0.Attributes, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>): ReturnType<(this: {
17
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
18
+ content?: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>;
19
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
20
20
  };
21
21
  export default _default;
@@ -1,33 +1,32 @@
1
- import { html, reactive } from '@esportsplus/frontend';
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
2
+ import { reactive } from '@esportsplus/frontend';
2
3
  import { omit } from '@esportsplus/utilities';
3
4
  import template from '../../components/template/index.js';
4
5
  import './scss/index.scss';
6
+ const template_88a2fd04bc87484a954d07fc771290fa2 = template_88a2fd04bc87484a954d07fc771290fa0.template(`<div><!--$--></div>`);
5
7
  const OMIT = ['state'];
6
8
  let key = Symbol();
7
9
  export default template.factory(function (attributes, content) {
8
10
  let ref, state = attributes.state || reactive({
9
11
  active: 0
10
12
  });
11
- return html `
12
- <div
13
- ${omit(attributes, OMIT)}
14
- ${{
15
- class: () => {
13
+ return (() => {
14
+ let root_88a2fd04bc87484a954d07fc771290fa1 = template_88a2fd04bc87484a954d07fc771290fa2(), element_88a2fd04bc87484a954d07fc771290fa3 = root_88a2fd04bc87484a954d07fc771290fa1.firstChild, element_88a2fd04bc87484a954d07fc771290fa4 = element_88a2fd04bc87484a954d07fc771290fa3.firstChild, attributes_88a2fd04bc87484a954d07fc771290fa5 = {};
15
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fa3, omit(attributes, OMIT), attributes_88a2fd04bc87484a954d07fc771290fa5);
16
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa3, 'class', () => {
16
17
  return state.active && '--active';
17
- },
18
- onrender: (element) => {
18
+ }, attributes_88a2fd04bc87484a954d07fc771290fa5);
19
+ template_88a2fd04bc87484a954d07fc771290fa0.onrender(element_88a2fd04bc87484a954d07fc771290fa3, (element) => {
19
20
  (ref = element)[key] = state;
20
- },
21
- style: () => {
21
+ });
22
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa3, 'style', () => {
22
23
  let parent = ref.closest('accordion');
23
24
  if (parent && key in parent) {
24
25
  parent[key].active = (+parent[key].active) + 1;
25
26
  }
26
27
  return state.active && `--max-height: ${ref.scrollHeight}`;
27
- }
28
- }}
29
- >
30
- ${content}
31
- </div>
32
- `;
28
+ }, attributes_88a2fd04bc87484a954d07fc771290fa5);
29
+ template_88a2fd04bc87484a954d07fc771290fa0.slot(element_88a2fd04bc87484a954d07fc771290fa4, content);
30
+ return root_88a2fd04bc87484a954d07fc771290fa1;
31
+ })();
33
32
  });
@@ -1,11 +1,16 @@
1
1
  import '@esportsplus/vite/global.d.ts';
2
- import { html, reactive, svg } from '@esportsplus/frontend';
2
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
3
+ import { reactive, svg } from '@esportsplus/frontend';
3
4
  import { omit } from '@esportsplus/utilities';
4
5
  import { icon } from '@esportsplus/ui';
5
6
  import check from './svg/check.svg';
6
7
  import close from './svg/close.svg';
7
8
  import e from './svg/error.svg';
8
9
  import './scss/index.scss';
10
+ const template_88a2fd04bc87484a954d07fc771290fa7 = template_88a2fd04bc87484a954d07fc771290fa0.template(`<div class='--flex-vertical'><!--$--></div>`);
11
+ const template_88a2fd04bc87484a954d07fc771290fac = template_88a2fd04bc87484a954d07fc771290fa0.template(`<p><!--$--></p>`);
12
+ const template_88a2fd04bc87484a954d07fc771290fah = template_88a2fd04bc87484a954d07fc771290fa0.template(`<div class='--flex-start'><!--$--></div>`);
13
+ const template_88a2fd04bc87484a954d07fc771290fak = template_88a2fd04bc87484a954d07fc771290fa0.template(`<div class='alert anchor anchor--n --flex-row'><!--$--><div class='alert-messages --flex-column --flex-fill'><!--$--></div><div class="--flex-vertical"><div class='alert-close button --padding-300'><div class="icon" style='--size: 14px;'><!--$--></div></div></div></div>`);
9
14
  const OMIT = ['alert-close', 'alert-messages', 'alert-message'];
10
15
  let modifiers = {
11
16
  error: 'red',
@@ -71,56 +76,43 @@ export default (attributes) => {
71
76
  }), 5);
72
77
  };
73
78
  return {
74
- content: html `
75
- <div
76
- class='alert anchor anchor--n ${() => state.active && '--active'} --flex-row'
77
- ${omit(attributes, OMIT)}
78
- >
79
- ${() => {
80
- let type = state.type;
81
- return html `
82
- <div class='--flex-vertical' style='${`--color: var(--color-${modifiers[type]}-400);`}'>
83
- ${icon({ class: '--size-500' }, type === 'error' ? e : check)}
84
- </div>
85
- `;
86
- }}
87
-
88
- <div
89
- class='alert-messages --flex-column --flex-fill'
90
- ${attributes['alert-messages']}
91
- >
92
- ${() => {
93
- let message = attributes['alert-message'];
94
- return state.rerender && [...state.messages].map((content) => {
95
- if (typeof content === 'string') {
96
- return html `
97
- <p ${message}>
98
- ${content}
99
- </p>
100
- `;
101
- }
102
- return html `
103
- <div class='--flex-start'>
104
- ${content}
105
- </div>
106
- `;
79
+ content: (() => {
80
+ let root_88a2fd04bc87484a954d07fc771290faj = template_88a2fd04bc87484a954d07fc771290fak(), element_88a2fd04bc87484a954d07fc771290fal = root_88a2fd04bc87484a954d07fc771290faj.firstChild, element_88a2fd04bc87484a954d07fc771290fam = element_88a2fd04bc87484a954d07fc771290fal.firstChild, element_88a2fd04bc87484a954d07fc771290fan = element_88a2fd04bc87484a954d07fc771290fal.firstElementChild, element_88a2fd04bc87484a954d07fc771290fao = element_88a2fd04bc87484a954d07fc771290fan.firstChild, element_88a2fd04bc87484a954d07fc771290fap = element_88a2fd04bc87484a954d07fc771290fan.nextElementSibling.firstElementChild, element_88a2fd04bc87484a954d07fc771290faq = element_88a2fd04bc87484a954d07fc771290fap.firstElementChild.firstChild, attributes_88a2fd04bc87484a954d07fc771290far = { "class": "alert anchor anchor--n --flex-row" }, attributes_88a2fd04bc87484a954d07fc771290fas = { "class": "alert-messages --flex-column --flex-fill" }, attributes_88a2fd04bc87484a954d07fc771290fat = { "class": "alert-close button --padding-300" };
81
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fal, 'class', () => state.active && '--active', attributes_88a2fd04bc87484a954d07fc771290far);
82
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fal, omit(attributes, OMIT), attributes_88a2fd04bc87484a954d07fc771290far);
83
+ new template_88a2fd04bc87484a954d07fc771290fa0.EffectSlot(element_88a2fd04bc87484a954d07fc771290fam, () => {
84
+ let type = state.type;
85
+ return (() => {
86
+ let root_88a2fd04bc87484a954d07fc771290fa6 = template_88a2fd04bc87484a954d07fc771290fa7(), element_88a2fd04bc87484a954d07fc771290fa8 = root_88a2fd04bc87484a954d07fc771290fa6.firstChild, element_88a2fd04bc87484a954d07fc771290fa9 = element_88a2fd04bc87484a954d07fc771290fa8.firstChild, attributes_88a2fd04bc87484a954d07fc771290faa = { "class": "--flex-vertical", "style": "" };
87
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa8, 'style', `--color: var(--color-${modifiers[type]}-400);`, attributes_88a2fd04bc87484a954d07fc771290faa);
88
+ template_88a2fd04bc87484a954d07fc771290fa0.slot(element_88a2fd04bc87484a954d07fc771290fa9, icon({ class: '--size-500' }, type === 'error' ? e : check));
89
+ return root_88a2fd04bc87484a954d07fc771290fa6;
90
+ })();
107
91
  });
108
- }}
109
- </div>
110
-
111
- <div class="--flex-vertical">
112
- <div
113
- class='alert-close button --padding-300'
114
- onclick='${() => deactivate(state)}'
115
- ${attributes['alert-close']}
116
- >
117
- <div class="icon" style='--size: 14px;'>
118
- ${svg.sprite(close)}
119
- </div>
120
- </div>
121
- </div>
122
- </div>
123
- `,
92
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fan, attributes['alert-messages'], attributes_88a2fd04bc87484a954d07fc771290fas);
93
+ new template_88a2fd04bc87484a954d07fc771290fa0.EffectSlot(element_88a2fd04bc87484a954d07fc771290fao, () => {
94
+ let message = attributes['alert-message'];
95
+ return state.rerender && [...state.messages].map((content) => {
96
+ if (typeof content === 'string') {
97
+ return (() => {
98
+ let root_88a2fd04bc87484a954d07fc771290fab = template_88a2fd04bc87484a954d07fc771290fac(), element_88a2fd04bc87484a954d07fc771290fad = root_88a2fd04bc87484a954d07fc771290fab.firstChild, element_88a2fd04bc87484a954d07fc771290fae = element_88a2fd04bc87484a954d07fc771290fad.firstChild, attributes_88a2fd04bc87484a954d07fc771290faf = {};
99
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fad, message, attributes_88a2fd04bc87484a954d07fc771290faf);
100
+ template_88a2fd04bc87484a954d07fc771290fa0.slot(element_88a2fd04bc87484a954d07fc771290fae, content);
101
+ return root_88a2fd04bc87484a954d07fc771290fab;
102
+ })();
103
+ }
104
+ return (() => {
105
+ let root_88a2fd04bc87484a954d07fc771290fag = template_88a2fd04bc87484a954d07fc771290fah(), element_88a2fd04bc87484a954d07fc771290fai = root_88a2fd04bc87484a954d07fc771290fag.firstChild.firstChild;
106
+ template_88a2fd04bc87484a954d07fc771290fa0.slot(element_88a2fd04bc87484a954d07fc771290fai, content);
107
+ return root_88a2fd04bc87484a954d07fc771290fag;
108
+ })();
109
+ });
110
+ });
111
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fap, 'click', () => deactivate(state));
112
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fap, attributes['alert-close'], attributes_88a2fd04bc87484a954d07fc771290fat);
113
+ template_88a2fd04bc87484a954d07fc771290fa0.slot(element_88a2fd04bc87484a954d07fc771290faq, svg.sprite(close));
114
+ return root_88a2fd04bc87484a954d07fc771290faj;
115
+ })(),
124
116
  deactivate: () => deactivate(state),
125
117
  error,
126
118
  info: (messages, seconds = 0) => activate('info', messages, seconds, state),
@@ -1,17 +1,18 @@
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
1
2
  import { Attributes } from '@esportsplus/frontend';
2
3
  import './scss/index.scss';
3
4
  declare const _default: {
4
5
  (): ReturnType<(this: {
5
6
  attributes?: Attributes;
6
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
7
- <T extends Attributes>(attributes: T): ReturnType<(this: {
7
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
8
+ <T extends template_88a2fd04bc87484a954d07fc771290fa0.Attributes>(attributes: T): ReturnType<(this: {
8
9
  attributes?: Attributes;
9
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
10
- <T extends import("@esportsplus/frontend").Renderable<any>>(content: T): ReturnType<(this: {
10
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
11
+ <T extends template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>(content: T): ReturnType<(this: {
11
12
  attributes?: Attributes;
12
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
13
- (attributes: Attributes, content: import("@esportsplus/frontend").Renderable<any>): ReturnType<(this: {
13
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
14
+ (attributes: template_88a2fd04bc87484a954d07fc771290fa0.Attributes, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>): ReturnType<(this: {
14
15
  attributes?: Attributes;
15
- }, attributes: Readonly<Attributes>, content: import("@esportsplus/frontend").Renderable<any>) => import("@esportsplus/frontend").Renderable<any>>;
16
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>) => template_88a2fd04bc87484a954d07fc771290fa0.Renderable<any>>;
16
17
  };
17
18
  export default _default;
@@ -1,17 +1,16 @@
1
- import { html } from '@esportsplus/frontend';
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
2
2
  import icon from '../../components/icon/index.js';
3
3
  import template from '../../components/template/index.js';
4
4
  import arrow from './svg/arrow.svg';
5
5
  import './scss/index.scss';
6
+ const template_88a2fd04bc87484a954d07fc771290fav = template_88a2fd04bc87484a954d07fc771290fa0.template(`<a class='back link --padding-0px --flex-vertical'><!--$--><!--$--></a>`);
6
7
  export default template.factory(function (attributes, content) {
7
- return html `
8
- <a
9
- class='back link --padding-0px --flex-vertical'
10
- ${this.attributes}
11
- ${attributes}
12
- >
13
- ${icon({ class: 'back-arrow --margin-right --margin-200' }, arrow)}
14
- ${content}
15
- </a>
16
- `;
8
+ return (() => {
9
+ let root_88a2fd04bc87484a954d07fc771290fau = template_88a2fd04bc87484a954d07fc771290fav(), element_88a2fd04bc87484a954d07fc771290faw = root_88a2fd04bc87484a954d07fc771290fau.firstChild, element_88a2fd04bc87484a954d07fc771290fax = element_88a2fd04bc87484a954d07fc771290faw.firstChild, element_88a2fd04bc87484a954d07fc771290fay = element_88a2fd04bc87484a954d07fc771290fax.nextSibling, attributes_88a2fd04bc87484a954d07fc771290faz = { "class": "back link --padding-0px --flex-vertical" };
10
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290faw, this.attributes, attributes_88a2fd04bc87484a954d07fc771290faz);
11
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290faw, attributes, attributes_88a2fd04bc87484a954d07fc771290faz);
12
+ template_88a2fd04bc87484a954d07fc771290fa0.slot(element_88a2fd04bc87484a954d07fc771290fax, icon({ class: 'back-arrow --margin-right --margin-200' }, arrow));
13
+ template_88a2fd04bc87484a954d07fc771290fa0.slot(element_88a2fd04bc87484a954d07fc771290fay, content);
14
+ return root_88a2fd04bc87484a954d07fc771290fau;
15
+ })();
17
16
  });
@@ -1,23 +1,24 @@
1
- import { type Renderable } from '@esportsplus/frontend';
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
2
+ import { Renderable } from '@esportsplus/frontend';
2
3
  import './scss/index.scss';
3
4
  declare const hold: {
4
5
  (): ReturnType<(this: {
5
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
6
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
6
7
  content?: ((state: {
7
8
  holding: boolean;
8
9
  complete: boolean;
9
10
  }) => Renderable<any>) | undefined;
10
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
11
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
11
12
  holding: boolean;
12
13
  complete: boolean;
13
14
  }) => Renderable<any>) => Renderable<any>>;
14
- <T extends import("@esportsplus/frontend").Attributes>(attributes: T): ReturnType<(this: {
15
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
15
+ <T extends template_88a2fd04bc87484a954d07fc771290fa0.Attributes>(attributes: T): ReturnType<(this: {
16
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
16
17
  content?: ((state: {
17
18
  holding: boolean;
18
19
  complete: boolean;
19
20
  }) => Renderable<any>) | undefined;
20
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
21
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
21
22
  holding: boolean;
22
23
  complete: boolean;
23
24
  }) => Renderable<any>) => Renderable<any>>;
@@ -25,25 +26,25 @@ declare const hold: {
25
26
  holding: boolean;
26
27
  complete: boolean;
27
28
  }) => Renderable<any>>(content: T): ReturnType<(this: {
28
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
29
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
29
30
  content?: ((state: {
30
31
  holding: boolean;
31
32
  complete: boolean;
32
33
  }) => Renderable<any>) | undefined;
33
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
34
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
34
35
  holding: boolean;
35
36
  complete: boolean;
36
37
  }) => Renderable<any>) => Renderable<any>>;
37
- (attributes: import("@esportsplus/frontend").Attributes, content: (state: {
38
+ (attributes: template_88a2fd04bc87484a954d07fc771290fa0.Attributes, content: (state: {
38
39
  holding: boolean;
39
40
  complete: boolean;
40
41
  }) => Renderable<any>): ReturnType<(this: {
41
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
42
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
42
43
  content?: ((state: {
43
44
  holding: boolean;
44
45
  complete: boolean;
45
46
  }) => Renderable<any>) | undefined;
46
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
47
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
47
48
  holding: boolean;
48
49
  complete: boolean;
49
50
  }) => Renderable<any>) => Renderable<any>>;
@@ -51,22 +52,22 @@ declare const hold: {
51
52
  declare const _default: {
52
53
  hold: {
53
54
  (): ReturnType<(this: {
54
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
55
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
55
56
  content?: ((state: {
56
57
  holding: boolean;
57
58
  complete: boolean;
58
59
  }) => Renderable<any>) | undefined;
59
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
60
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
60
61
  holding: boolean;
61
62
  complete: boolean;
62
63
  }) => Renderable<any>) => Renderable<any>>;
63
- <T extends import("@esportsplus/frontend").Attributes>(attributes: T): ReturnType<(this: {
64
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
64
+ <T extends template_88a2fd04bc87484a954d07fc771290fa0.Attributes>(attributes: T): ReturnType<(this: {
65
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
65
66
  content?: ((state: {
66
67
  holding: boolean;
67
68
  complete: boolean;
68
69
  }) => Renderable<any>) | undefined;
69
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
70
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
70
71
  holding: boolean;
71
72
  complete: boolean;
72
73
  }) => Renderable<any>) => Renderable<any>>;
@@ -74,25 +75,25 @@ declare const _default: {
74
75
  holding: boolean;
75
76
  complete: boolean;
76
77
  }) => Renderable<any>>(content: T): ReturnType<(this: {
77
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
78
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
78
79
  content?: ((state: {
79
80
  holding: boolean;
80
81
  complete: boolean;
81
82
  }) => Renderable<any>) | undefined;
82
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
83
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
83
84
  holding: boolean;
84
85
  complete: boolean;
85
86
  }) => Renderable<any>) => Renderable<any>>;
86
- (attributes: import("@esportsplus/frontend").Attributes, content: (state: {
87
+ (attributes: template_88a2fd04bc87484a954d07fc771290fa0.Attributes, content: (state: {
87
88
  holding: boolean;
88
89
  complete: boolean;
89
90
  }) => Renderable<any>): ReturnType<(this: {
90
- attributes?: import("@esportsplus/frontend").Attributes | undefined;
91
+ attributes?: template_88a2fd04bc87484a954d07fc771290fa0.Attributes | undefined;
91
92
  content?: ((state: {
92
93
  holding: boolean;
93
94
  complete: boolean;
94
95
  }) => Renderable<any>) | undefined;
95
- }, attributes: Readonly<import("@esportsplus/frontend").Attributes>, content: (state: {
96
+ }, attributes: Readonly<template_88a2fd04bc87484a954d07fc771290fa0.Attributes>, content: (state: {
96
97
  holding: boolean;
97
98
  complete: boolean;
98
99
  }) => Renderable<any>) => Renderable<any>>;
@@ -1,6 +1,8 @@
1
- import { html, reactive } from '@esportsplus/frontend';
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
2
+ import { reactive } from '@esportsplus/frontend';
2
3
  import template from '../template/index.js';
3
4
  import './scss/index.scss';
5
+ const template_88a2fd04bc87484a954d07fc771290fa11 = template_88a2fd04bc87484a954d07fc771290fa0.template(`<div class='button '><!--$--></div>`);
4
6
  const hold = template.factory(function (attributes, content) {
5
7
  let end = () => {
6
8
  if (!state.complete) {
@@ -10,36 +12,34 @@ const hold = template.factory(function (attributes, content) {
10
12
  complete: false,
11
13
  holding: false
12
14
  });
13
- return html `
14
- <div
15
- class='button ${() => state.holding && 'button--holding'} ${() => state.complete && '--active'}'
16
- onmousedown='${(e) => {
17
- e.preventDefault();
18
- state.holding = true;
19
- }}'
20
- ${attributes}
21
- ${{
22
- onanimationend: (e) => {
15
+ return (() => {
16
+ let root_88a2fd04bc87484a954d07fc771290fa10 = template_88a2fd04bc87484a954d07fc771290fa11(), element_88a2fd04bc87484a954d07fc771290fa12 = root_88a2fd04bc87484a954d07fc771290fa10.firstChild, element_88a2fd04bc87484a954d07fc771290fa13 = element_88a2fd04bc87484a954d07fc771290fa12.firstChild, attributes_88a2fd04bc87484a954d07fc771290fa14 = { "class": "button" };
17
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa12, 'class', () => state.holding && 'button--holding', attributes_88a2fd04bc87484a954d07fc771290fa14);
18
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa12, 'class', () => state.complete && '--active', attributes_88a2fd04bc87484a954d07fc771290fa14);
19
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa12, 'mousedown', (e) => {
20
+ e.preventDefault();
21
+ state.holding = true;
22
+ });
23
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fa12, attributes, attributes_88a2fd04bc87484a954d07fc771290fa14);
24
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa12, 'animationend', (e) => {
23
25
  if (e.animationName === 'buttonHolding') {
24
26
  state.complete = true;
25
27
  }
26
- },
27
- onclick: () => { },
28
- onmousedown: (e) => {
28
+ });
29
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa12, 'click', () => { });
30
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa12, 'mousedown', (e) => {
29
31
  e.preventDefault();
30
32
  state.holding = true;
31
- },
32
- onmouseup: end,
33
- ontouchend: end,
34
- ontouchstart: (e) => {
33
+ });
34
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa12, 'mouseup', end);
35
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa12, 'touchend', end);
36
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa12, 'touchstart', (e) => {
35
37
  e.preventDefault();
36
38
  state.holding = true;
37
- }
38
- }}
39
- >
40
- ${() => content(state)}
41
- </div>
42
- `;
39
+ });
40
+ new template_88a2fd04bc87484a954d07fc771290fa0.EffectSlot(element_88a2fd04bc87484a954d07fc771290fa13, () => content(state));
41
+ return root_88a2fd04bc87484a954d07fc771290fa10;
42
+ })();
43
43
  });
44
44
  export default { hold };
45
45
  export { hold };
@@ -1,4 +1,4 @@
1
- import { type Attributes } from '@esportsplus/frontend';
1
+ import { Attributes } from '@esportsplus/frontend';
2
2
  import './scss/index.scss';
3
3
  declare const factory: (type: string) => (this: {
4
4
  attributes?: Attributes;
@@ -1,7 +1,9 @@
1
- import { html, reactive, root } from '@esportsplus/frontend';
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
2
+ import { reactive, root } from '@esportsplus/frontend';
2
3
  import { omit } from '@esportsplus/utilities';
3
4
  import form from '../../components/form/index.js';
4
5
  import './scss/index.scss';
6
+ const template_88a2fd04bc87484a954d07fc771290fa16 = template_88a2fd04bc87484a954d07fc771290fa0.template(`<div><input></div>`);
5
7
  const OMIT = ['checked', 'value'];
6
8
  const factory = (type) => {
7
9
  function template(attributes) {
@@ -12,26 +14,22 @@ const factory = (type) => {
12
14
  if (attributes?.checked) {
13
15
  state.active = true;
14
16
  }
15
- return html `
16
- <div
17
- class='${type} ${() => state.active && '--active'}'
18
- ${this?.attributes && omit(this.attributes, OMIT)}
19
- ${attributes && omit(attributes, OMIT)}
20
- >
21
- <input
22
- ${{
23
- checked: attributes?.checked || root(() => state.active),
24
- class: `${type}-tag`,
25
- onchange: (e) => {
17
+ return (() => {
18
+ let root_88a2fd04bc87484a954d07fc771290fa15 = template_88a2fd04bc87484a954d07fc771290fa16(), element_88a2fd04bc87484a954d07fc771290fa17 = root_88a2fd04bc87484a954d07fc771290fa15.firstChild, element_88a2fd04bc87484a954d07fc771290fa18 = element_88a2fd04bc87484a954d07fc771290fa17.firstElementChild, attributes_88a2fd04bc87484a954d07fc771290fa19 = { "class": "" }, attributes_88a2fd04bc87484a954d07fc771290fa1a = {};
19
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa17, 'class', type, attributes_88a2fd04bc87484a954d07fc771290fa19);
20
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa17, 'class', () => state.active && '--active', attributes_88a2fd04bc87484a954d07fc771290fa19);
21
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fa17, this?.attributes && omit(this.attributes, OMIT), attributes_88a2fd04bc87484a954d07fc771290fa19);
22
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fa17, attributes && omit(attributes, OMIT), attributes_88a2fd04bc87484a954d07fc771290fa19);
23
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperty(element_88a2fd04bc87484a954d07fc771290fa18, 'checked', attributes?.checked || root(() => state.active));
24
+ template_88a2fd04bc87484a954d07fc771290fa0.setList(element_88a2fd04bc87484a954d07fc771290fa18, 'class', `${type}-tag`, attributes_88a2fd04bc87484a954d07fc771290fa1a);
25
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa18, 'change', (e) => {
26
26
  state.active = e.target.checked;
27
- },
28
- onrender: form.input.onrender(state),
29
- type: type === 'radio' ? 'radio' : 'checkbox',
30
- value: attributes?.value || 1
31
- }}
32
- >
33
- </div>
34
- `;
27
+ });
28
+ template_88a2fd04bc87484a954d07fc771290fa0.onrender(element_88a2fd04bc87484a954d07fc771290fa18, form.input.onrender(state));
29
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperty(element_88a2fd04bc87484a954d07fc771290fa18, 'type', type === 'radio' ? 'radio' : 'checkbox');
30
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperty(element_88a2fd04bc87484a954d07fc771290fa18, 'value', attributes?.value || 1);
31
+ return root_88a2fd04bc87484a954d07fc771290fa15;
32
+ })();
35
33
  }
36
34
  return template;
37
35
  };
@@ -1,4 +1,4 @@
1
- import { type Attributes, type Renderable } from '@esportsplus/frontend';
1
+ import { Attributes, Renderable } from '@esportsplus/frontend';
2
2
  type A = {
3
3
  timeout?: number;
4
4
  value: string;
@@ -1,27 +1,28 @@
1
- import { html, reactive } from '@esportsplus/frontend';
1
+ import * as template_88a2fd04bc87484a954d07fc771290fa0 from '@esportsplus/frontend';
2
+ import { reactive } from '@esportsplus/frontend';
2
3
  import { omit } from '@esportsplus/utilities';
3
4
  import template from '../../components/template/index.js';
4
5
  import write from './write.js';
6
+ const template_88a2fd04bc87484a954d07fc771290fa1c = template_88a2fd04bc87484a954d07fc771290fa0.template(`<div><!--$--></div>`);
5
7
  const OMIT = ['timeout', 'value'];
6
8
  export default template.factory(function (attributes, content) {
7
9
  let state = reactive({
8
10
  copied: false
9
11
  }), timeout = attributes.timeout || 1000 * 2;
10
- return html `
11
- <div
12
- ${omit(attributes, OMIT)}
13
- onclick=${(e) => {
14
- e.preventDefault();
15
- e.stopPropagation();
16
- write(attributes.value).then(() => {
17
- state.copied = true;
18
- setTimeout(() => {
19
- state.copied = false;
20
- }, timeout);
12
+ return (() => {
13
+ let root_88a2fd04bc87484a954d07fc771290fa1b = template_88a2fd04bc87484a954d07fc771290fa1c(), element_88a2fd04bc87484a954d07fc771290fa1d = root_88a2fd04bc87484a954d07fc771290fa1b.firstChild, element_88a2fd04bc87484a954d07fc771290fa1e = element_88a2fd04bc87484a954d07fc771290fa1d.firstChild, attributes_88a2fd04bc87484a954d07fc771290fa1f = {};
14
+ template_88a2fd04bc87484a954d07fc771290fa0.setProperties(element_88a2fd04bc87484a954d07fc771290fa1d, omit(attributes, OMIT), attributes_88a2fd04bc87484a954d07fc771290fa1f);
15
+ template_88a2fd04bc87484a954d07fc771290fa0.delegate(element_88a2fd04bc87484a954d07fc771290fa1d, 'click', (e) => {
16
+ e.preventDefault();
17
+ e.stopPropagation();
18
+ write(attributes.value).then(() => {
19
+ state.copied = true;
20
+ setTimeout(() => {
21
+ state.copied = false;
22
+ }, timeout);
23
+ });
21
24
  });
22
- }}
23
- >
24
- ${() => content(state)}
25
- </div>
26
- `;
25
+ new template_88a2fd04bc87484a954d07fc771290fa0.EffectSlot(element_88a2fd04bc87484a954d07fc771290fa1e, () => content(state));
26
+ return root_88a2fd04bc87484a954d07fc771290fa1b;
27
+ })();
27
28
  });
@@ -1,4 +1,4 @@
1
- import { type Attributes } from '@esportsplus/frontend';
1
+ import { Attributes } from '@esportsplus/frontend';
2
2
  import './scss/index.scss';
3
3
  declare const _default: (attributes: Attributes & {
4
4
  currency?: "IGNORE" | "EUR" | "GBP" | "USD";