@lukso/web-components 1.129.0 → 1.131.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.
Files changed (89) hide show
  1. package/dist/components/index.cjs +8 -7
  2. package/dist/components/index.js +8 -8
  3. package/dist/components/lukso-button/index.cjs +3 -3
  4. package/dist/components/lukso-button/index.js +3 -3
  5. package/dist/components/lukso-card/index.cjs +6 -6
  6. package/dist/components/lukso-card/index.js +6 -6
  7. package/dist/components/lukso-checkbox/index.cjs +3 -3
  8. package/dist/components/lukso-checkbox/index.js +3 -3
  9. package/dist/components/lukso-color-picker/index.cjs +4 -4
  10. package/dist/components/lukso-color-picker/index.js +4 -4
  11. package/dist/components/lukso-dropdown/index.cjs +9 -15
  12. package/dist/components/lukso-dropdown/index.d.ts +1 -1
  13. package/dist/components/lukso-dropdown/index.d.ts.map +1 -1
  14. package/dist/components/lukso-dropdown/index.js +9 -15
  15. package/dist/components/lukso-dropdown-option/index.cjs +3 -9
  16. package/dist/components/lukso-dropdown-option/index.d.ts +1 -1
  17. package/dist/components/lukso-dropdown-option/index.d.ts.map +1 -1
  18. package/dist/components/lukso-dropdown-option/index.js +3 -9
  19. package/dist/components/lukso-footer/index.cjs +2 -2
  20. package/dist/components/lukso-footer/index.js +2 -2
  21. package/dist/components/lukso-icon/index.cjs +3 -3
  22. package/dist/components/lukso-icon/index.js +3 -3
  23. package/dist/components/lukso-image/index.cjs +4 -4
  24. package/dist/components/lukso-image/index.js +4 -4
  25. package/dist/components/lukso-input/index.cjs +22 -21
  26. package/dist/components/lukso-input/index.d.ts +1 -1
  27. package/dist/components/lukso-input/index.d.ts.map +1 -1
  28. package/dist/components/lukso-input/index.js +22 -21
  29. package/dist/components/lukso-modal/index.cjs +14 -10
  30. package/dist/components/lukso-modal/index.d.ts.map +1 -1
  31. package/dist/components/lukso-modal/index.js +14 -10
  32. package/dist/components/lukso-navbar/index.cjs +5 -5
  33. package/dist/components/lukso-navbar/index.js +5 -5
  34. package/dist/components/lukso-pagination/index.cjs +4 -4
  35. package/dist/components/lukso-pagination/index.js +4 -4
  36. package/dist/components/lukso-profile/index.cjs +5 -5
  37. package/dist/components/lukso-profile/index.js +5 -5
  38. package/dist/components/lukso-progress/index.cjs +3 -3
  39. package/dist/components/lukso-progress/index.js +3 -3
  40. package/dist/components/lukso-sanitize/index.cjs +2 -2
  41. package/dist/components/lukso-sanitize/index.js +2 -2
  42. package/dist/components/lukso-search/index.cjs +110 -34
  43. package/dist/components/lukso-search/index.d.ts +17 -4
  44. package/dist/components/lukso-search/index.d.ts.map +1 -1
  45. package/dist/components/lukso-search/index.js +109 -35
  46. package/dist/components/lukso-search/lukso-search.stories.d.ts +1 -0
  47. package/dist/components/lukso-search/lukso-search.stories.d.ts.map +1 -1
  48. package/dist/components/lukso-select/index.cjs +7 -7
  49. package/dist/components/lukso-select/index.js +7 -7
  50. package/dist/components/lukso-share/index.cjs +2 -2
  51. package/dist/components/lukso-share/index.js +2 -2
  52. package/dist/components/lukso-switch/index.cjs +3 -3
  53. package/dist/components/lukso-switch/index.js +3 -3
  54. package/dist/components/lukso-tag/index.cjs +3 -3
  55. package/dist/components/lukso-tag/index.js +3 -3
  56. package/dist/components/lukso-terms/index.cjs +4 -4
  57. package/dist/components/lukso-terms/index.js +4 -4
  58. package/dist/components/lukso-test/index.cjs +2 -2
  59. package/dist/components/lukso-test/index.js +2 -2
  60. package/dist/components/lukso-textarea/index.cjs +4 -4
  61. package/dist/components/lukso-textarea/index.js +4 -4
  62. package/dist/components/lukso-tooltip/index.cjs +4 -4
  63. package/dist/components/lukso-tooltip/index.js +4 -4
  64. package/dist/components/lukso-username/index.cjs +9 -1330
  65. package/dist/components/lukso-username/index.js +6 -1336
  66. package/dist/components/lukso-wizard/index.cjs +2 -2
  67. package/dist/components/lukso-wizard/index.js +2 -2
  68. package/dist/index-2d057f81.js +37 -0
  69. package/dist/{index-da14e190.js → index-38990f38.js} +2 -2
  70. package/dist/{index-b74237f9.js → index-5387057e.js} +1 -1
  71. package/dist/{index-2ffc105b.cjs → index-5df012eb.cjs} +1 -1
  72. package/dist/index-96bba619.cjs +46 -0
  73. package/dist/index-9ba001cb.js +1337 -0
  74. package/dist/{index-e5b0ba18.cjs → index-9c39357d.cjs} +2 -2
  75. package/dist/index-ba49f23a.cjs +1339 -0
  76. package/dist/index.cjs +8 -7
  77. package/dist/index.js +8 -8
  78. package/dist/{property-ff5733e6.js → property-5367c26a.js} +1 -1
  79. package/dist/{property-65ed3fa1.cjs → property-98f7e05b.cjs} +1 -1
  80. package/dist/shared/tailwind-element/index.cjs +1 -1
  81. package/dist/shared/tailwind-element/index.js +1 -1
  82. package/dist/{state-9bdaddc0.js → state-bdfaec36.js} +1 -1
  83. package/dist/{state-ec4491d8.cjs → state-eba8ded5.cjs} +1 -1
  84. package/dist/{style-map-8a1e2472.js → style-map-9e6bb4a6.js} +1 -1
  85. package/dist/{style-map-227a49cb.cjs → style-map-b13b92c1.cjs} +1 -1
  86. package/package.json +1 -1
  87. package/tools/sass/colors.scss +1 -0
  88. package/dist/index-869a59a0.js +0 -37
  89. package/dist/index-b44989bb.cjs +0 -46
@@ -1,12 +1,12 @@
1
- import { T as TailwindStyledElement, x, E } from '../../index-869a59a0.js';
2
- import { n, t } from '../../property-ff5733e6.js';
3
- import { r } from '../../state-9bdaddc0.js';
1
+ import { T as TailwindStyledElement, x, E } from '../../index-2d057f81.js';
2
+ import { n, t } from '../../property-5367c26a.js';
3
+ import { r } from '../../state-bdfaec36.js';
4
4
  import { c as ce } from '../../index-d14b6a34.js';
5
5
  import '../lukso-icon/index.js';
6
+ import '../lukso-sanitize/index.js';
6
7
  import '../../tailwind-config.js';
7
8
  import { c as cn } from '../../cn-90c03edf.js';
8
- import '../lukso-sanitize/index.js';
9
- import '../../style-map-8a1e2472.js';
9
+ import '../../style-map-9e6bb4a6.js';
10
10
  import '../../directive-2bb7789e.js';
11
11
 
12
12
  const style = ":host {\n\n display: inline-flex\n}\n\n:host([is-full-width]) {\n\n display: flex;\n\n width: 100%\n}";
@@ -46,7 +46,7 @@ let LuksoInput = class extends TailwindStyledElement(style) {
46
46
  this.max = void 0;
47
47
  this.min = void 0;
48
48
  this.borderless = false;
49
- this.size = "medium";
49
+ this.size = "large";
50
50
  this.rightIcon = "";
51
51
  this.isRightIconClickable = false;
52
52
  this.keepFocusOnEscape = false;
@@ -105,18 +105,23 @@ let LuksoInput = class extends TailwindStyledElement(style) {
105
105
  },
106
106
  size: {
107
107
  small: {
108
- input: "h-[28px] px-2 py-1 paragraph-inter-12-regular rounded-8",
109
- unit: "h-[28px] paragraph-inter-10-regular px-2 rounded-r-8 before:top-[calc(50%-6px)] before:h-[12px]",
110
- rightIcon: "right-2"
108
+ input: "h-[28px] px-3 py-1 paragraph-inter-12-regular rounded-8",
109
+ unit: "h-[28px] paragraph-inter-12-regular px-2 rounded-r-8 before:top-[calc(50%-6px)] before:h-[12px]",
110
+ rightIcon: "right-3"
111
111
  },
112
112
  medium: {
113
- input: "h-[48px] px-4 py-3 paragraph-inter-14-regular rounded-12",
114
- unit: "h-[48px] paragraph-inter-12-regular px-3.5 rounded-r-12 before:top-[calc(50%-12px)] before:h-[24px]",
115
- rightIcon: "right-3"
113
+ input: "h-[40px] px-3.5 py-2 paragraph-inter-14-regular rounded-[10px]",
114
+ unit: "h-[40px] paragraph-inter-12-regular px-3 rounded-r-[10px] before:top-[calc(50%-12px)] before:h-[24px]",
115
+ rightIcon: "right-4"
116
116
  },
117
117
  large: {
118
- input: "h-[70px] px-4 py-5 paragraph-inter-16-regular rounded-12",
119
- unit: "h-[48px] paragraph-inter-16-semi-bold px-3.5 rounded-r-12 before:top-[calc(50%-12px)] before:h-[24px]",
118
+ input: "h-[48px] px-4 py-2 paragraph-inter-14-regular rounded-12",
119
+ unit: "h-[48px] paragraph-inter-12-regular pl-3 pr-4 rounded-r-12 before:top-[calc(50%-12px)] before:h-[24px]",
120
+ rightIcon: "right-4"
121
+ },
122
+ "x-large": {
123
+ input: "h-[68px] px-5 py-5 paragraph-inter-16-regular rounded-[14px]",
124
+ unit: "h-[68px] paragraph-inter-16-regular pl-3 pr-4 rounded-r-[14px] before:top-[calc(50%-12px)] before:h-[24px]",
120
125
  rightIcon: "right-4"
121
126
  }
122
127
  },
@@ -152,12 +157,7 @@ let LuksoInput = class extends TailwindStyledElement(style) {
152
157
  },
153
158
  {
154
159
  hasRightIcon: true,
155
- size: "large",
156
- class: { input: "pr-10" }
157
- },
158
- {
159
- hasRightIcon: true,
160
- size: "medium",
160
+ size: ["medium", "large", "x-large"],
161
161
  class: { input: "pr-10" }
162
162
  },
163
163
  {
@@ -241,9 +241,10 @@ let LuksoInput = class extends TailwindStyledElement(style) {
241
241
  </div>`;
242
242
  }
243
243
  rightIconTemplate(styles) {
244
+ const iconSize = this.size === "small" ? "small" : "medium";
244
245
  return x`<lukso-icon
245
246
  name=${this.rightIcon}
246
- size=${this.size}
247
+ size=${iconSize}
247
248
  class=${styles}
248
249
  @click=${this.handleRightIconClick}
249
250
  ></lukso-icon>`;
@@ -2,8 +2,8 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- const shared_tailwindElement_index = require('../../index-b44989bb.cjs');
6
- const property = require('../../property-65ed3fa1.cjs');
5
+ const shared_tailwindElement_index = require('../../index-96bba619.cjs');
6
+ const property = require('../../property-98f7e05b.cjs');
7
7
  const index = require('../../index-2b104ecb.cjs');
8
8
 
9
9
  var __defProp = Object.defineProperty;
@@ -25,14 +25,14 @@ exports.LuksoModal = class LuksoModal extends shared_tailwindElement_index.Tailw
25
25
  this.size = "small";
26
26
  this.styles = index.ce({
27
27
  slots: {
28
- wrapper: "opacity-0 fixed z-[1011] transition-opacity top-0 left-0 p-6 overflow-y-auto",
29
- overlay: "bg-[rgba(196,202,206,0.6)] backdrop-blur-sm fixed top-0 left-0 w-[100vw] h-[100vh] z-[1010]",
30
- dialog: "bg-neutral-98 rounded-12 shadow-neutral-shadow-round-3xl z-[1012]"
28
+ wrapper: "opacity-0 fixed z-[1011] transition-opacity inset-0 w-screen h-screen overflow-y-auto overscroll-none touch-none",
29
+ overlay: "bg-[rgba(196,202,206,0.6)] backdrop-blur-sm fixed inset-0 w-[100vw] h-[100vh] z-[1010]",
30
+ dialog: "bg-neutral-98 rounded-12 shadow-neutral-shadow-round-3xl z-[1012] mx-auto"
31
31
  },
32
32
  variants: {
33
33
  isOpen: {
34
34
  true: {
35
- wrapper: "grid opacity-100 visible items-center justify-center w-[100vw] h-[100vh]"
35
+ wrapper: "opacity-100 visible w-[100vw] h-[100vh]"
36
36
  },
37
37
  false: {
38
38
  wrapper: "hidden"
@@ -52,7 +52,7 @@ exports.LuksoModal = class LuksoModal extends shared_tailwindElement_index.Tailw
52
52
  },
53
53
  disableAnimations: {
54
54
  false: {
55
- wrapper: "animation-duration-300 delay-300 ",
55
+ wrapper: "animation-duration-300 delay-300",
56
56
  overlay: "animation-duration-300"
57
57
  }
58
58
  }
@@ -88,9 +88,13 @@ exports.LuksoModal = class LuksoModal extends shared_tailwindElement_index.Tailw
88
88
  });
89
89
  return shared_tailwindElement_index.x`
90
90
  <div data-testid="modal" class=${wrapper()}>
91
- <div class=${overlay()} @click=${this.handleBackdropClick}></div>
92
- <div class=${dialog()}>
93
- <slot></slot>
91
+ <div
92
+ class="min-h-screen flex items-center justify-center pt-6 pb-[120px] sm:pb-6 px-6 w-full"
93
+ >
94
+ <div class=${overlay()} @click=${this.handleBackdropClick}></div>
95
+ <div class=${dialog()}>
96
+ <slot></slot>
97
+ </div>
94
98
  </div>
95
99
  </div>
96
100
  `;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/lukso-modal/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAA;AAE3D,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAA;AAE7D,qBACa,UAAW,SAAQ,eAAe;IAE7C,MAAM,UAAQ;IAGd,iBAAiB,UAAQ;IAGzB,IAAI,EAAE,UAAU,CAAU;IAE1B,OAAO,CAAC,MAAM,CAgDZ;IAEF,OAAO,CAAC,KAAK;YAIC,mBAAmB;IASjC,MAAM;CAgBP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,aAAa,EAAE,UAAU,CAAA;KAC1B;CACF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/lukso-modal/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAA;AAE3D,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAA;AAE7D,qBACa,UAAW,SAAQ,eAAe;IAE7C,MAAM,UAAQ;IAGd,iBAAiB,UAAQ;IAGzB,IAAI,EAAE,UAAU,CAAU;IAE1B,OAAO,CAAC,MAAM,CA+CZ;IAEF,OAAO,CAAC,KAAK;YAIC,mBAAmB;IASjC,MAAM;CAoBP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,aAAa,EAAE,UAAU,CAAA;KAC1B;CACF"}
@@ -1,5 +1,5 @@
1
- import { a as TailwindElement, x } from '../../index-869a59a0.js';
2
- import { n, t } from '../../property-ff5733e6.js';
1
+ import { a as TailwindElement, x } from '../../index-2d057f81.js';
2
+ import { n, t } from '../../property-5367c26a.js';
3
3
  import { c as ce } from '../../index-d14b6a34.js';
4
4
 
5
5
  var __defProp = Object.defineProperty;
@@ -21,14 +21,14 @@ let LuksoModal = class extends TailwindElement {
21
21
  this.size = "small";
22
22
  this.styles = ce({
23
23
  slots: {
24
- wrapper: "opacity-0 fixed z-[1011] transition-opacity top-0 left-0 p-6 overflow-y-auto",
25
- overlay: "bg-[rgba(196,202,206,0.6)] backdrop-blur-sm fixed top-0 left-0 w-[100vw] h-[100vh] z-[1010]",
26
- dialog: "bg-neutral-98 rounded-12 shadow-neutral-shadow-round-3xl z-[1012]"
24
+ wrapper: "opacity-0 fixed z-[1011] transition-opacity inset-0 w-screen h-screen overflow-y-auto overscroll-none touch-none",
25
+ overlay: "bg-[rgba(196,202,206,0.6)] backdrop-blur-sm fixed inset-0 w-[100vw] h-[100vh] z-[1010]",
26
+ dialog: "bg-neutral-98 rounded-12 shadow-neutral-shadow-round-3xl z-[1012] mx-auto"
27
27
  },
28
28
  variants: {
29
29
  isOpen: {
30
30
  true: {
31
- wrapper: "grid opacity-100 visible items-center justify-center w-[100vw] h-[100vh]"
31
+ wrapper: "opacity-100 visible w-[100vw] h-[100vh]"
32
32
  },
33
33
  false: {
34
34
  wrapper: "hidden"
@@ -48,7 +48,7 @@ let LuksoModal = class extends TailwindElement {
48
48
  },
49
49
  disableAnimations: {
50
50
  false: {
51
- wrapper: "animation-duration-300 delay-300 ",
51
+ wrapper: "animation-duration-300 delay-300",
52
52
  overlay: "animation-duration-300"
53
53
  }
54
54
  }
@@ -84,9 +84,13 @@ let LuksoModal = class extends TailwindElement {
84
84
  });
85
85
  return x`
86
86
  <div data-testid="modal" class=${wrapper()}>
87
- <div class=${overlay()} @click=${this.handleBackdropClick}></div>
88
- <div class=${dialog()}>
89
- <slot></slot>
87
+ <div
88
+ class="min-h-screen flex items-center justify-center pt-6 pb-[120px] sm:pb-6 px-6 w-full"
89
+ >
90
+ <div class=${overlay()} @click=${this.handleBackdropClick}></div>
91
+ <div class=${dialog()}>
92
+ <slot></slot>
93
+ </div>
90
94
  </div>
91
95
  </div>
92
96
  `;
@@ -2,15 +2,15 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- const shared_tailwindElement_index = require('../../index-b44989bb.cjs');
6
- const property = require('../../property-65ed3fa1.cjs');
7
- const state = require('../../state-ec4491d8.cjs');
5
+ const shared_tailwindElement_index = require('../../index-96bba619.cjs');
6
+ const property = require('../../property-98f7e05b.cjs');
7
+ const state = require('../../state-eba8ded5.cjs');
8
8
  const index = require('../../index-2b104ecb.cjs');
9
9
  require('../lukso-icon/index.cjs');
10
10
  require('../lukso-tag/index.cjs');
11
- require('../../style-map-227a49cb.cjs');
11
+ require('../../style-map-b13b92c1.cjs');
12
12
  require('../../directive-8278ab14.cjs');
13
- require('../../index-2ffc105b.cjs');
13
+ require('../../index-5df012eb.cjs');
14
14
 
15
15
  var __defProp = Object.defineProperty;
16
16
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -1,12 +1,12 @@
1
- import { a as TailwindElement, x, E } from '../../index-869a59a0.js';
2
- import { n, t } from '../../property-ff5733e6.js';
3
- import { r } from '../../state-9bdaddc0.js';
1
+ import { a as TailwindElement, x, E } from '../../index-2d057f81.js';
2
+ import { n, t } from '../../property-5367c26a.js';
3
+ import { r } from '../../state-bdfaec36.js';
4
4
  import { c as ce } from '../../index-d14b6a34.js';
5
5
  import '../lukso-icon/index.js';
6
6
  import '../lukso-tag/index.js';
7
- import '../../style-map-8a1e2472.js';
7
+ import '../../style-map-9e6bb4a6.js';
8
8
  import '../../directive-2bb7789e.js';
9
- import '../../index-b74237f9.js';
9
+ import '../../index-5387057e.js';
10
10
 
11
11
  var __defProp = Object.defineProperty;
12
12
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
@@ -2,13 +2,13 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- const shared_tailwindElement_index = require('../../index-b44989bb.cjs');
6
- const property = require('../../property-65ed3fa1.cjs');
7
- const state = require('../../state-ec4491d8.cjs');
5
+ const shared_tailwindElement_index = require('../../index-96bba619.cjs');
6
+ const property = require('../../property-98f7e05b.cjs');
7
+ const state = require('../../state-eba8ded5.cjs');
8
8
  const index = require('../../index-2b104ecb.cjs');
9
9
  require('../lukso-icon/index.cjs');
10
10
  require('../lukso-button/index.cjs');
11
- require('../../style-map-227a49cb.cjs');
11
+ require('../../style-map-b13b92c1.cjs');
12
12
  require('../../directive-8278ab14.cjs');
13
13
  require('../../tailwind-config.cjs');
14
14
  require('../../cn-b6daa995.cjs');
@@ -1,10 +1,10 @@
1
- import { T as TailwindStyledElement, x } from '../../index-869a59a0.js';
2
- import { n, t } from '../../property-ff5733e6.js';
3
- import { r } from '../../state-9bdaddc0.js';
1
+ import { T as TailwindStyledElement, x } from '../../index-2d057f81.js';
2
+ import { n, t } from '../../property-5367c26a.js';
3
+ import { r } from '../../state-bdfaec36.js';
4
4
  import { c as ce } from '../../index-d14b6a34.js';
5
5
  import '../lukso-icon/index.js';
6
6
  import '../lukso-button/index.js';
7
- import '../../style-map-8a1e2472.js';
7
+ import '../../style-map-9e6bb4a6.js';
8
8
  import '../../directive-2bb7789e.js';
9
9
  import '../../tailwind-config.js';
10
10
  import '../../cn-90c03edf.js';
@@ -2,13 +2,13 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- require('../../index-b44989bb.cjs');
6
- require('../../property-65ed3fa1.cjs');
7
- const components_luksoProfile_index = require('../../index-e5b0ba18.cjs');
5
+ require('../../index-96bba619.cjs');
6
+ require('../../property-98f7e05b.cjs');
7
+ const components_luksoProfile_index = require('../../index-9c39357d.cjs');
8
8
  require('../../index-2b104ecb.cjs');
9
9
  require('../lukso-image/index.cjs');
10
- require('../../state-ec4491d8.cjs');
11
- require('../../style-map-227a49cb.cjs');
10
+ require('../../state-eba8ded5.cjs');
11
+ require('../../style-map-b13b92c1.cjs');
12
12
  require('../../directive-8278ab14.cjs');
13
13
 
14
14
 
@@ -1,8 +1,8 @@
1
- import '../../index-869a59a0.js';
2
- import '../../property-ff5733e6.js';
3
- export { L as LuksoProfile } from '../../index-da14e190.js';
1
+ import '../../index-2d057f81.js';
2
+ import '../../property-5367c26a.js';
3
+ export { L as LuksoProfile } from '../../index-38990f38.js';
4
4
  import '../../index-d14b6a34.js';
5
5
  import '../lukso-image/index.js';
6
- import '../../state-9bdaddc0.js';
7
- import '../../style-map-8a1e2472.js';
6
+ import '../../state-bdfaec36.js';
7
+ import '../../style-map-9e6bb4a6.js';
8
8
  import '../../directive-2bb7789e.js';
@@ -2,9 +2,9 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- const shared_tailwindElement_index = require('../../index-b44989bb.cjs');
6
- const property = require('../../property-65ed3fa1.cjs');
7
- const styleMap = require('../../style-map-227a49cb.cjs');
5
+ const shared_tailwindElement_index = require('../../index-96bba619.cjs');
6
+ const property = require('../../property-98f7e05b.cjs');
7
+ const styleMap = require('../../style-map-b13b92c1.cjs');
8
8
  require('../../tailwind-config.cjs');
9
9
  const cn = require('../../cn-b6daa995.cjs');
10
10
  require('../../directive-8278ab14.cjs');
@@ -1,6 +1,6 @@
1
- import { a as TailwindElement, x } from '../../index-869a59a0.js';
2
- import { n, t } from '../../property-ff5733e6.js';
3
- import { o } from '../../style-map-8a1e2472.js';
1
+ import { a as TailwindElement, x } from '../../index-2d057f81.js';
2
+ import { n, t } from '../../property-5367c26a.js';
3
+ import { o } from '../../style-map-9e6bb4a6.js';
4
4
  import '../../tailwind-config.js';
5
5
  import { c as cn } from '../../cn-90c03edf.js';
6
6
  import '../../directive-2bb7789e.js';
@@ -2,8 +2,8 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- const shared_tailwindElement_index = require('../../index-b44989bb.cjs');
6
- const property = require('../../property-65ed3fa1.cjs');
5
+ const shared_tailwindElement_index = require('../../index-96bba619.cjs');
6
+ const property = require('../../property-98f7e05b.cjs');
7
7
  const directive = require('../../directive-8278ab14.cjs');
8
8
 
9
9
  /**
@@ -1,5 +1,5 @@
1
- import { E, b as T, a as TailwindElement, x } from '../../index-869a59a0.js';
2
- import { n, t as t$1 } from '../../property-ff5733e6.js';
1
+ import { E, b as T, a as TailwindElement, x } from '../../index-2d057f81.js';
2
+ import { n, t as t$1 } from '../../property-5367c26a.js';
3
3
  import { i, t, e as e$1 } from '../../directive-2bb7789e.js';
4
4
 
5
5
  /**
@@ -2,24 +2,25 @@
2
2
 
3
3
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
4
4
 
5
- const components_luksoProfile_index = require('../../index-e5b0ba18.cjs');
6
- const shared_tailwindElement_index = require('../../index-b44989bb.cjs');
7
- const property = require('../../property-65ed3fa1.cjs');
8
- const state = require('../../state-ec4491d8.cjs');
5
+ const components_luksoProfile_index = require('../../index-9c39357d.cjs');
6
+ const shared_tailwindElement_index = require('../../index-96bba619.cjs');
7
+ const property = require('../../property-98f7e05b.cjs');
8
+ const state = require('../../state-eba8ded5.cjs');
9
9
  const index = require('../../index-2b104ecb.cjs');
10
10
  require('../lukso-dropdown/index.cjs');
11
11
  require('../lukso-dropdown-option/index.cjs');
12
12
  require('../lukso-icon/index.cjs');
13
13
  require('../lukso-input/index.cjs');
14
- require('../lukso-username/index.cjs');
14
+ require('../lukso-tag/index.cjs');
15
+ const components_luksoUsername_index = require('../../index-ba49f23a.cjs');
16
+ require('../../tailwind-config.cjs');
17
+ require('../../cn-b6daa995.cjs');
15
18
  require('../lukso-image/index.cjs');
16
- require('../../style-map-227a49cb.cjs');
19
+ require('../../style-map-b13b92c1.cjs');
17
20
  require('../../directive-8278ab14.cjs');
18
21
  require('../../uniq-id-f0b18085.cjs');
19
- require('../../tailwind-config.cjs');
20
- require('../../cn-b6daa995.cjs');
21
22
  require('../lukso-sanitize/index.cjs');
22
- require('../../index-2ffc105b.cjs');
23
+ require('../../index-5df012eb.cjs');
23
24
 
24
25
  const style = ":host {\n\n display: inline-flex\n}\n\n:host([is-full-width]) {\n\n display: flex;\n\n width: 100%\n}";
25
26
 
@@ -34,6 +35,12 @@ var __decorateClass = (decorators, target, key, kind) => {
34
35
  __defProp(target, key, result);
35
36
  return result;
36
37
  };
38
+ var SearchProfileType = /* @__PURE__ */ ((SearchProfileType2) => {
39
+ SearchProfileType2["UP"] = "up";
40
+ SearchProfileType2["EOA"] = "eoa";
41
+ SearchProfileType2["SmartContract"] = "sc";
42
+ return SearchProfileType2;
43
+ })(SearchProfileType || {});
37
44
  exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.TailwindStyledElement(style) {
38
45
  constructor() {
39
46
  super(...arguments);
@@ -41,6 +48,8 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
41
48
  this.name = "";
42
49
  this.placeholder = "";
43
50
  this.label = "";
51
+ this.availableText = "Available";
52
+ this.unavailableText = "Registered";
44
53
  this.autocomplete = "off";
45
54
  this.id = "";
46
55
  this.description = "";
@@ -61,10 +70,9 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
61
70
  this.hasReset = false;
62
71
  this.keepValueOnEscapeHit = false;
63
72
  this.selected = void 0;
64
- this.size = "medium";
73
+ this.size = "large";
65
74
  this.isDebouncing = false;
66
75
  this.resultsParsed = [];
67
- this.searchTerm = "";
68
76
  this.styles = index.ce({
69
77
  slots: {
70
78
  loading: "bg-neutral-95 w-full animate-pulse animation-delay-none"
@@ -78,6 +86,9 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
78
86
  loading: "h-10 rounded-8"
79
87
  },
80
88
  large: {
89
+ loading: "h-10 rounded-8"
90
+ },
91
+ "x-large": {
81
92
  loading: "h-12 rounded-8"
82
93
  }
83
94
  }
@@ -111,21 +122,34 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
111
122
  }
112
123
  }
113
124
  }
125
+ sizeDropdown() {
126
+ const dropdownSize = this.size === "large" || this.size === "x-large" ? "medium" : this.size;
127
+ return dropdownSize;
128
+ }
114
129
  resultsTemplate() {
115
130
  const resultTemplates = [];
116
131
  this.resultsParsed = JSON.parse(this.results);
117
132
  for (const result of Object.entries(this.resultsParsed)) {
118
133
  const index = Number(result[0]);
119
- if ("value" in result[1]) {
120
- resultTemplates.push(this.resultStringTemplate(result[1], index));
134
+ if ("value" in result[1] && "status" in result[1]) {
135
+ resultTemplates.push(
136
+ this.resultUniversalNameTemplate(
137
+ result[1],
138
+ index
139
+ )
140
+ );
141
+ } else if ("value" in result[1]) {
142
+ resultTemplates.push(
143
+ this.resultStringTemplate(result[1], index)
144
+ );
121
145
  } else if ("address" in result[1]) {
122
146
  resultTemplates.push(this.resultProfileTemplate(result[1], index));
123
- } else {
147
+ } else if ("value" in result[1]) ; else {
124
148
  console.error("Unknown result type", result);
125
149
  }
126
150
  }
127
151
  return shared_tailwindElement_index.x`<lukso-dropdown
128
- size=${this.size}
152
+ size=${this.sizeDropdown()}
129
153
  is-open
130
154
  is-open-on-outside-click
131
155
  is-full-width
@@ -134,7 +158,7 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
134
158
  }
135
159
  noResultsTemplate() {
136
160
  return shared_tailwindElement_index.x`<lukso-dropdown
137
- size=${this.size}
161
+ size=${this.sizeDropdown()}
138
162
  is-open
139
163
  is-open-on-outside-click
140
164
  is-full-width
@@ -149,7 +173,7 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
149
173
  });
150
174
  if (this.showNoResults) {
151
175
  return shared_tailwindElement_index.x`<lukso-dropdown
152
- size=${this.size}
176
+ size=${this.sizeDropdown()}
153
177
  is-open
154
178
  is-open-on-outside-click
155
179
  is-full-width
@@ -162,7 +186,7 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
162
186
  }
163
187
  if (this.resultsParsed.length === 0 || this.resultsParsed.length > 5) {
164
188
  return shared_tailwindElement_index.x`<lukso-dropdown
165
- size=${this.size}
189
+ size=${this.sizeDropdown()}
166
190
  is-open
167
191
  is-open-on-outside-click
168
192
  is-full-width
@@ -174,7 +198,7 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
174
198
  >`;
175
199
  }
176
200
  return shared_tailwindElement_index.x`<lukso-dropdown
177
- size=${this.size}
201
+ size=${this.sizeDropdown()}
178
202
  is-open
179
203
  is-open-on-outside-click
180
204
  is-full-width
@@ -186,16 +210,37 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
186
210
  >`;
187
211
  }
188
212
  resultStringTemplate(result, index) {
213
+ const dropdownSize = this.size === "large" || this.size === "x-large" ? "medium" : this.size;
189
214
  return shared_tailwindElement_index.x`<lukso-dropdown-option
190
215
  data-id="${result.id}"
191
216
  data-index="${index + 1}"
192
217
  ?is-selected=${this.selected === index + 1}
193
- size=${this.size}
218
+ size=${dropdownSize}
194
219
  @click=${() => this.handleSelect(result)}
195
220
  >
196
221
  ${result.value}
197
222
  </lukso-dropdown-option>`;
198
223
  }
224
+ resultUniversalNameTemplate(result, index) {
225
+ const tag = shared_tailwindElement_index.x`<lukso-tag
226
+ is-rounded
227
+ background-color="${result.status ? "green-90" : "neutral-95"}"
228
+ text-color="${result.status ? "green-45" : "neutral-60"}"
229
+ >${!!result.status ? this.availableText : this.unavailableText}</lukso-tag
230
+ >`;
231
+ return shared_tailwindElement_index.x`<lukso-dropdown-option
232
+ data-id="${result.id}"
233
+ data-index="${index + 1}"
234
+ ?is-selected=${this.selected === index + 1}
235
+ size=${this.sizeDropdown()}
236
+ @click=${() => this.handleSelect(result)}
237
+ >
238
+ <div class="flex flex-row items-center justify-between w-full">
239
+ <div class="paragraph-inter-14-semi-bold">${result.value}</div>
240
+ ${tag}
241
+ </div>
242
+ </lukso-dropdown-option>`;
243
+ }
199
244
  resultProfileTemplate(result, index) {
200
245
  const eoaProfilePicture = shared_tailwindElement_index.x`<lukso-profile
201
246
  profile-address="${result.address}"
@@ -208,23 +253,49 @@ exports.LuksoSearch = class LuksoSearch extends shared_tailwindElement_index.Tai
208
253
  size="x-small"
209
254
  has-identicon
210
255
  ></lukso-profile>`;
211
- const profilePicture = result.isEOA ? eoaProfilePicture : lsp3ProfilePicture;
256
+ const type = result.type || "up" /* UP */;
257
+ const profilePicture = type !== "up" /* UP */ ? eoaProfilePicture : lsp3ProfilePicture;
258
+ const upProfileUsername = shared_tailwindElement_index.x`<lukso-username
259
+ name="${result.name?.toLowerCase() || "anonymous-profile"}"
260
+ address="${result.address}"
261
+ name-color="neutral-20"
262
+ max-width="300"
263
+ size="medium"
264
+ ?hide-prefix="${!result.name}"
265
+ class="ml-1"
266
+ ></lukso-username> `;
267
+ const eoaUsername = shared_tailwindElement_index.x`<lukso-username
268
+ name="${components_luksoUsername_index.sliceAddress(result.address, 8)}"
269
+ address="__EOA"
270
+ name-color="neutral-20"
271
+ max-width="300"
272
+ size="medium"
273
+ hide-prefix
274
+ class="ml-1"
275
+ ></lukso-username>`;
276
+ const scUsername = shared_tailwindElement_index.x`<lukso-username
277
+ name=""
278
+ address="${components_luksoUsername_index.sliceAddress(result.address, 8)}"
279
+ name-color="neutral-20"
280
+ max-width="300"
281
+ size="medium"
282
+ hide-prefix
283
+ class="ml-1"
284
+ ></lukso-username>`;
285
+ let profileName = scUsername;
286
+ if (type === "eoa" /* EOA */) {
287
+ profileName = eoaUsername;
288
+ } else if (type === "up" /* UP */) {
289
+ profileName = upProfileUsername;
290
+ }
212
291
  return shared_tailwindElement_index.x`<lukso-dropdown-option
213
292
  data-id="${result.address}"
214
293
  data-index="${index + 1}"
215
294
  ?is-selected=${this.selected === index + 1}
216
- size=${this.size}
295
+ size=${this.sizeDropdown()}
217
296
  @click=${() => this.handleSelect(result)}
218
297
  >
219
- ${profilePicture}
220
- <lukso-username
221
- name="${result.name?.toLowerCase()}"
222
- address="${result.address}"
223
- name-color="neutral-20"
224
- max-width="300"
225
- size="medium"
226
- class="ml-1"
227
- ></lukso-username>
298
+ ${profilePicture} ${profileName}
228
299
  </lukso-dropdown-option>`;
229
300
  }
230
301
  async handleOutsideDropdownClick(event) {
@@ -406,6 +477,12 @@ __decorateClass([
406
477
  __decorateClass([
407
478
  property.n({ type: String })
408
479
  ], exports.LuksoSearch.prototype, "label", 2);
480
+ __decorateClass([
481
+ property.n({ type: String, attribute: "available-text" })
482
+ ], exports.LuksoSearch.prototype, "availableText", 2);
483
+ __decorateClass([
484
+ property.n({ type: String, attribute: "unavailable-text" })
485
+ ], exports.LuksoSearch.prototype, "unavailableText", 2);
409
486
  __decorateClass([
410
487
  property.n({ type: String })
411
488
  ], exports.LuksoSearch.prototype, "autocomplete", 2);
@@ -478,9 +555,8 @@ __decorateClass([
478
555
  __decorateClass([
479
556
  state.r()
480
557
  ], exports.LuksoSearch.prototype, "resultsParsed", 2);
481
- __decorateClass([
482
- state.r()
483
- ], exports.LuksoSearch.prototype, "searchTerm", 2);
484
558
  exports.LuksoSearch = __decorateClass([
485
559
  property.t("lukso-search")
486
560
  ], exports.LuksoSearch);
561
+
562
+ exports.SearchProfileType = SearchProfileType;