mn-angular-lib 2.0.34 → 2.0.36
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.
- package/fesm2022/mn-angular-lib-alert.mjs +515 -527
- package/fesm2022/mn-angular-lib-alert.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-bottom-sheet.mjs +264 -357
- package/fesm2022/mn-angular-lib-bottom-sheet.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-button.mjs +819 -382
- package/fesm2022/mn-angular-lib-button.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-calendar-core.mjs +240 -365
- package/fesm2022/mn-angular-lib-calendar-core.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-calendar.mjs +1691 -1545
- package/fesm2022/mn-angular-lib-calendar.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-collection.mjs +2367 -2796
- package/fesm2022/mn-angular-lib-collection.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-core.mjs +693 -1241
- package/fesm2022/mn-angular-lib-core.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-display.mjs +679 -712
- package/fesm2022/mn-angular-lib-display.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-forms.mjs +3671 -4647
- package/fesm2022/mn-angular-lib-forms.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-keyboard.mjs +221 -190
- package/fesm2022/mn-angular-lib-keyboard.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-modal-core.mjs +711 -896
- package/fesm2022/mn-angular-lib-modal-core.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-modal-ui.mjs +2089 -2035
- package/fesm2022/mn-angular-lib-modal-ui.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-modal.mjs +76 -121
- package/fesm2022/mn-angular-lib-modal.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-rich-text-editor.mjs +289 -277
- package/fesm2022/mn-angular-lib-rich-text-editor.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-segmented.mjs +189 -241
- package/fesm2022/mn-angular-lib-segmented.mjs.map +1 -1
- package/fesm2022/mn-angular-lib-tab.mjs +409 -642
- package/fesm2022/mn-angular-lib-tab.mjs.map +1 -1
- package/fesm2022/mn-angular-lib.mjs +16 -29
- package/package.json +1 -1
- package/types/mn-angular-lib-alert.d.ts +239 -241
- package/types/mn-angular-lib-bottom-sheet.d.ts +190 -150
- package/types/mn-angular-lib-button.d.ts +319 -317
- package/types/mn-angular-lib-calendar-core.d.ts +199 -209
- package/types/mn-angular-lib-calendar.d.ts +656 -511
- package/types/mn-angular-lib-collection.d.ts +1649 -1585
- package/types/mn-angular-lib-core.d.ts +524 -535
- package/types/mn-angular-lib-display.d.ts +946 -886
- package/types/mn-angular-lib-forms.d.ts +3012 -3013
- package/types/mn-angular-lib-keyboard.d.ts +125 -85
- package/types/mn-angular-lib-modal-core.d.ts +978 -994
- package/types/mn-angular-lib-modal-ui.d.ts +541 -493
- package/types/mn-angular-lib-modal.d.ts +24 -27
- package/types/mn-angular-lib-rich-text-editor.d.ts +131 -98
- package/types/mn-angular-lib-segmented.d.ts +354 -341
- package/types/mn-angular-lib-tab.d.ts +345 -336
- package/types/mn-angular-lib.d.ts +16 -16
- package/fesm2022/mn-angular-lib.mjs.map +0 -1
|
@@ -1,389 +1,826 @@
|
|
|
1
|
-
import * as i0 from
|
|
2
|
-
import { HostBinding, Input
|
|
3
|
-
import { tv } from
|
|
4
|
-
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { Component, HostBinding, Input } from "@angular/core";
|
|
3
|
+
import { tv } from "tailwind-variants";
|
|
5
4
|
const mnButtonVariants = tv({
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
5
|
+
base: "inline-flex items-center justify-center hover:cursor-pointer transition-[color,background-color,border-color,box-shadow,filter,opacity] duration-300 ease-in-out",
|
|
6
|
+
variants: {
|
|
7
|
+
size: {
|
|
8
|
+
sm: "px-2 py-1 text-sm",
|
|
9
|
+
md: "px-3 py-1.5 text-base",
|
|
10
|
+
lg: "px-4 py-2 text-lg"
|
|
11
|
+
},
|
|
12
|
+
variant: {
|
|
13
|
+
fill: "",
|
|
14
|
+
outline: "bg-transparent border",
|
|
15
|
+
text: "bg-transparent",
|
|
16
|
+
textUnderline: "bg-transparent underline underline-offset-2",
|
|
17
|
+
ghost: "bg-transparent"
|
|
18
|
+
},
|
|
19
|
+
color: {
|
|
20
|
+
primary: "",
|
|
21
|
+
secondary: "",
|
|
22
|
+
danger: "",
|
|
23
|
+
warning: "",
|
|
24
|
+
success: "",
|
|
25
|
+
accent: "",
|
|
26
|
+
gray: ""
|
|
27
|
+
},
|
|
28
|
+
borderRadius: {
|
|
29
|
+
none: "rounded-none",
|
|
30
|
+
xs: "rounded-xs",
|
|
31
|
+
sm: "rounded-sm",
|
|
32
|
+
md: "rounded-md",
|
|
33
|
+
lg: "rounded-lg",
|
|
34
|
+
xl: "rounded-xl",
|
|
35
|
+
two_xl: "rounded-2xl",
|
|
36
|
+
three_xl: "rounded-3xl",
|
|
37
|
+
four_xl: "rounded-4xl",
|
|
38
|
+
full: "rounded-full"
|
|
39
|
+
},
|
|
40
|
+
shape: {
|
|
41
|
+
default: "",
|
|
42
|
+
circle: "p-0 shrink-0 rounded-full",
|
|
43
|
+
square: "p-0 shrink-0 rounded-md"
|
|
44
|
+
},
|
|
45
|
+
disabled: { true: "opacity-50 pointer-events-none" },
|
|
46
|
+
loading: { true: "opacity-50 pointer-events-none cursor-wait" },
|
|
47
|
+
wrap: {
|
|
48
|
+
true: "whitespace-normal",
|
|
49
|
+
false: "whitespace-nowrap"
|
|
50
|
+
},
|
|
51
|
+
hover: { true: "" }
|
|
52
|
+
},
|
|
53
|
+
compoundVariants: [
|
|
54
|
+
{
|
|
55
|
+
variant: "fill",
|
|
56
|
+
color: "primary",
|
|
57
|
+
class: "bg-primary text-primary-content border border-primary"
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
variant: "fill",
|
|
61
|
+
color: "secondary",
|
|
62
|
+
class: "bg-secondary text-secondary-content border border-secondary"
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
variant: "fill",
|
|
66
|
+
color: "danger",
|
|
67
|
+
class: "bg-error text-error-content border border-error"
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
variant: "fill",
|
|
71
|
+
color: "warning",
|
|
72
|
+
class: "bg-warning text-warning-content border border-warning"
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
variant: "fill",
|
|
76
|
+
color: "success",
|
|
77
|
+
class: "bg-success text-success-content border border-success"
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
variant: "fill",
|
|
81
|
+
color: "accent",
|
|
82
|
+
class: "bg-accent text-accent-content border border-accent"
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
variant: "fill",
|
|
86
|
+
color: "gray",
|
|
87
|
+
class: "bg-base-content/10 text-base-content/70 border border-base-content/10"
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
variant: "fill",
|
|
91
|
+
color: "primary",
|
|
92
|
+
hover: true,
|
|
93
|
+
class: "hover:brightness-60"
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
variant: "fill",
|
|
97
|
+
color: "secondary",
|
|
98
|
+
hover: true,
|
|
99
|
+
class: "hover:brightness-60"
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
variant: "fill",
|
|
103
|
+
color: "danger",
|
|
104
|
+
hover: true,
|
|
105
|
+
class: "hover:brightness-60"
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
variant: "fill",
|
|
109
|
+
color: "warning",
|
|
110
|
+
hover: true,
|
|
111
|
+
class: "hover:brightness-60"
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
variant: "fill",
|
|
115
|
+
color: "success",
|
|
116
|
+
hover: true,
|
|
117
|
+
class: "hover:brightness-60"
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
variant: "fill",
|
|
121
|
+
color: "accent",
|
|
122
|
+
hover: true,
|
|
123
|
+
class: "hover:brightness-60"
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
variant: "fill",
|
|
127
|
+
color: "gray",
|
|
128
|
+
hover: true,
|
|
129
|
+
class: "hover:bg-base-content/20"
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
variant: "outline",
|
|
133
|
+
color: "primary",
|
|
134
|
+
class: "border-primary text-primary"
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
variant: "outline",
|
|
138
|
+
color: "secondary",
|
|
139
|
+
class: "border-secondary text-secondary"
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
variant: "outline",
|
|
143
|
+
color: "danger",
|
|
144
|
+
class: "border-error text-error"
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
variant: "outline",
|
|
148
|
+
color: "warning",
|
|
149
|
+
class: "border-warning text-warning"
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
variant: "outline",
|
|
153
|
+
color: "success",
|
|
154
|
+
class: "border-success text-success"
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
variant: "outline",
|
|
158
|
+
color: "accent",
|
|
159
|
+
class: "border-accent text-accent"
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
variant: "outline",
|
|
163
|
+
color: "gray",
|
|
164
|
+
class: "border-base-content/70 text-base-content/70"
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
variant: "outline",
|
|
168
|
+
color: "primary",
|
|
169
|
+
hover: true,
|
|
170
|
+
class: "hover:bg-primary/10"
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
variant: "outline",
|
|
174
|
+
color: "secondary",
|
|
175
|
+
hover: true,
|
|
176
|
+
class: "hover:bg-secondary/10"
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
variant: "outline",
|
|
180
|
+
color: "danger",
|
|
181
|
+
hover: true,
|
|
182
|
+
class: "hover:bg-error/10"
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
variant: "outline",
|
|
186
|
+
color: "warning",
|
|
187
|
+
hover: true,
|
|
188
|
+
class: "hover:bg-warning/10"
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
variant: "outline",
|
|
192
|
+
color: "success",
|
|
193
|
+
hover: true,
|
|
194
|
+
class: "hover:bg-success/10"
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
variant: "outline",
|
|
198
|
+
color: "accent",
|
|
199
|
+
hover: true,
|
|
200
|
+
class: "hover:bg-accent/10"
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
variant: "outline",
|
|
204
|
+
color: "gray",
|
|
205
|
+
hover: true,
|
|
206
|
+
class: "hover:bg-base-content/10"
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
variant: "text",
|
|
210
|
+
color: "primary",
|
|
211
|
+
class: "text-primary"
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
variant: "text",
|
|
215
|
+
color: "secondary",
|
|
216
|
+
class: "text-secondary"
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
variant: "text",
|
|
220
|
+
color: "danger",
|
|
221
|
+
class: "text-error"
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
variant: "text",
|
|
225
|
+
color: "warning",
|
|
226
|
+
class: "text-warning"
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
variant: "text",
|
|
230
|
+
color: "success",
|
|
231
|
+
class: "text-success"
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
variant: "text",
|
|
235
|
+
color: "accent",
|
|
236
|
+
class: "text-accent"
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
variant: "text",
|
|
240
|
+
color: "gray",
|
|
241
|
+
class: "text-base-content/70"
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
variant: "text",
|
|
245
|
+
color: "primary",
|
|
246
|
+
hover: true,
|
|
247
|
+
class: "hover:bg-primary/10"
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
variant: "text",
|
|
251
|
+
color: "secondary",
|
|
252
|
+
hover: true,
|
|
253
|
+
class: "hover:bg-secondary/10"
|
|
254
|
+
},
|
|
255
|
+
{
|
|
256
|
+
variant: "text",
|
|
257
|
+
color: "danger",
|
|
258
|
+
hover: true,
|
|
259
|
+
class: "hover:bg-error/10"
|
|
260
|
+
},
|
|
261
|
+
{
|
|
262
|
+
variant: "text",
|
|
263
|
+
color: "warning",
|
|
264
|
+
hover: true,
|
|
265
|
+
class: "hover:bg-warning/10"
|
|
266
|
+
},
|
|
267
|
+
{
|
|
268
|
+
variant: "text",
|
|
269
|
+
color: "success",
|
|
270
|
+
hover: true,
|
|
271
|
+
class: "hover:bg-success/10"
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
variant: "text",
|
|
275
|
+
color: "accent",
|
|
276
|
+
hover: true,
|
|
277
|
+
class: "hover:bg-accent/10"
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
variant: "text",
|
|
281
|
+
color: "gray",
|
|
282
|
+
hover: true,
|
|
283
|
+
class: "hover:bg-base-content/10"
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
variant: "textUnderline",
|
|
287
|
+
color: "primary",
|
|
288
|
+
class: "text-primary underline underline-offset-2"
|
|
289
|
+
},
|
|
290
|
+
{
|
|
291
|
+
variant: "textUnderline",
|
|
292
|
+
color: "secondary",
|
|
293
|
+
class: "text-secondary underline underline-offset-2"
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
variant: "textUnderline",
|
|
297
|
+
color: "danger",
|
|
298
|
+
class: "text-error underline underline-offset-2"
|
|
299
|
+
},
|
|
300
|
+
{
|
|
301
|
+
variant: "textUnderline",
|
|
302
|
+
color: "warning",
|
|
303
|
+
class: "text-warning underline underline-offset-2"
|
|
304
|
+
},
|
|
305
|
+
{
|
|
306
|
+
variant: "textUnderline",
|
|
307
|
+
color: "success",
|
|
308
|
+
class: "text-success underline underline-offset-2"
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
variant: "textUnderline",
|
|
312
|
+
color: "accent",
|
|
313
|
+
class: "text-accent underline underline-offset-2"
|
|
314
|
+
},
|
|
315
|
+
{
|
|
316
|
+
variant: "textUnderline",
|
|
317
|
+
color: "gray",
|
|
318
|
+
class: "text-base-content/70 underline underline-offset-2"
|
|
319
|
+
},
|
|
320
|
+
{
|
|
321
|
+
variant: "textUnderline",
|
|
322
|
+
color: "primary",
|
|
323
|
+
hover: true,
|
|
324
|
+
class: "hover:bg-primary/10"
|
|
325
|
+
},
|
|
326
|
+
{
|
|
327
|
+
variant: "textUnderline",
|
|
328
|
+
color: "secondary",
|
|
329
|
+
hover: true,
|
|
330
|
+
class: "hover:bg-secondary/10"
|
|
331
|
+
},
|
|
332
|
+
{
|
|
333
|
+
variant: "textUnderline",
|
|
334
|
+
color: "danger",
|
|
335
|
+
hover: true,
|
|
336
|
+
class: "hover:bg-error/10"
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
variant: "textUnderline",
|
|
340
|
+
color: "warning",
|
|
341
|
+
hover: true,
|
|
342
|
+
class: "hover:bg-warning/10"
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
variant: "textUnderline",
|
|
346
|
+
color: "success",
|
|
347
|
+
hover: true,
|
|
348
|
+
class: "hover:bg-success/10"
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
variant: "textUnderline",
|
|
352
|
+
color: "accent",
|
|
353
|
+
hover: true,
|
|
354
|
+
class: "hover:bg-accent/10"
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
variant: "textUnderline",
|
|
358
|
+
color: "gray",
|
|
359
|
+
hover: true,
|
|
360
|
+
class: "hover:bg-base-content/10"
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
variant: "ghost",
|
|
364
|
+
color: "primary",
|
|
365
|
+
class: "text-primary"
|
|
366
|
+
},
|
|
367
|
+
{
|
|
368
|
+
variant: "ghost",
|
|
369
|
+
color: "secondary",
|
|
370
|
+
class: "text-secondary"
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
variant: "ghost",
|
|
374
|
+
color: "danger",
|
|
375
|
+
class: "text-error"
|
|
376
|
+
},
|
|
377
|
+
{
|
|
378
|
+
variant: "ghost",
|
|
379
|
+
color: "warning",
|
|
380
|
+
class: "text-warning"
|
|
381
|
+
},
|
|
382
|
+
{
|
|
383
|
+
variant: "ghost",
|
|
384
|
+
color: "success",
|
|
385
|
+
class: "text-success"
|
|
386
|
+
},
|
|
387
|
+
{
|
|
388
|
+
variant: "ghost",
|
|
389
|
+
color: "accent",
|
|
390
|
+
class: "text-accent"
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
variant: "ghost",
|
|
394
|
+
color: "gray",
|
|
395
|
+
class: "text-base-content"
|
|
396
|
+
},
|
|
397
|
+
{
|
|
398
|
+
variant: "ghost",
|
|
399
|
+
color: "primary",
|
|
400
|
+
hover: true,
|
|
401
|
+
class: "hover:bg-primary/10"
|
|
402
|
+
},
|
|
403
|
+
{
|
|
404
|
+
variant: "ghost",
|
|
405
|
+
color: "secondary",
|
|
406
|
+
hover: true,
|
|
407
|
+
class: "hover:bg-secondary/10"
|
|
408
|
+
},
|
|
409
|
+
{
|
|
410
|
+
variant: "ghost",
|
|
411
|
+
color: "danger",
|
|
412
|
+
hover: true,
|
|
413
|
+
class: "hover:bg-error/10"
|
|
414
|
+
},
|
|
415
|
+
{
|
|
416
|
+
variant: "ghost",
|
|
417
|
+
color: "warning",
|
|
418
|
+
hover: true,
|
|
419
|
+
class: "hover:bg-warning/10"
|
|
420
|
+
},
|
|
421
|
+
{
|
|
422
|
+
variant: "ghost",
|
|
423
|
+
color: "success",
|
|
424
|
+
hover: true,
|
|
425
|
+
class: "hover:bg-success/10"
|
|
426
|
+
},
|
|
427
|
+
{
|
|
428
|
+
variant: "ghost",
|
|
429
|
+
color: "accent",
|
|
430
|
+
hover: true,
|
|
431
|
+
class: "hover:bg-accent/10"
|
|
432
|
+
},
|
|
433
|
+
{
|
|
434
|
+
variant: "ghost",
|
|
435
|
+
color: "gray",
|
|
436
|
+
hover: true,
|
|
437
|
+
class: "hover:bg-base-content/10"
|
|
438
|
+
},
|
|
439
|
+
{
|
|
440
|
+
shape: "circle",
|
|
441
|
+
size: "sm",
|
|
442
|
+
class: "h-8 w-8"
|
|
443
|
+
},
|
|
444
|
+
{
|
|
445
|
+
shape: "circle",
|
|
446
|
+
size: "md",
|
|
447
|
+
class: "h-10 w-10"
|
|
448
|
+
},
|
|
449
|
+
{
|
|
450
|
+
shape: "circle",
|
|
451
|
+
size: "lg",
|
|
452
|
+
class: "h-12 w-12"
|
|
453
|
+
},
|
|
454
|
+
{
|
|
455
|
+
shape: "square",
|
|
456
|
+
size: "sm",
|
|
457
|
+
class: "h-8 w-8"
|
|
458
|
+
},
|
|
459
|
+
{
|
|
460
|
+
shape: "square",
|
|
461
|
+
size: "md",
|
|
462
|
+
class: "h-10 w-10"
|
|
463
|
+
},
|
|
464
|
+
{
|
|
465
|
+
shape: "square",
|
|
466
|
+
size: "lg",
|
|
467
|
+
class: "h-12 w-12"
|
|
468
|
+
}
|
|
469
|
+
],
|
|
470
|
+
defaultVariants: {
|
|
471
|
+
size: "md",
|
|
472
|
+
variant: "fill",
|
|
473
|
+
color: "primary",
|
|
474
|
+
borderRadius: "lg",
|
|
475
|
+
shape: "default",
|
|
476
|
+
disabled: false,
|
|
477
|
+
loading: false,
|
|
478
|
+
wrap: false,
|
|
479
|
+
hover: true
|
|
480
|
+
}
|
|
481
|
+
});
|
|
482
|
+
var MnButton = class MnButton {
|
|
483
|
+
data = {};
|
|
484
|
+
get hostClasses() {
|
|
485
|
+
return mnButtonVariants({
|
|
486
|
+
size: this.data.size,
|
|
487
|
+
variant: this.data.variant,
|
|
488
|
+
color: this.data.color,
|
|
489
|
+
borderRadius: this.data.borderRadius,
|
|
490
|
+
shape: this.data.shape,
|
|
491
|
+
disabled: this.data.disabled,
|
|
492
|
+
loading: this.data.loading,
|
|
493
|
+
wrap: this.data.wrap,
|
|
494
|
+
hover: this.data.hover
|
|
495
|
+
});
|
|
496
|
+
}
|
|
497
|
+
get ariaBusy() {
|
|
498
|
+
return this.data.loading ? "true" : null;
|
|
499
|
+
}
|
|
500
|
+
get ariaDisabled() {
|
|
501
|
+
return this.data.disabled ? "true" : null;
|
|
502
|
+
}
|
|
503
|
+
get disabledAttr() {
|
|
504
|
+
return this.isBlocked ? "" : null;
|
|
505
|
+
}
|
|
506
|
+
get tabIndex() {
|
|
507
|
+
return this.isBlocked ? "-1" : null;
|
|
508
|
+
}
|
|
509
|
+
get isBlocked() {
|
|
510
|
+
return !!(this.data.disabled || this.data.loading);
|
|
511
|
+
}
|
|
512
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
513
|
+
minVersion: "12.0.0",
|
|
514
|
+
version: "22.2.2",
|
|
515
|
+
ngImport: i0,
|
|
516
|
+
type: MnButton,
|
|
517
|
+
deps: [],
|
|
518
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
519
|
+
});
|
|
520
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
521
|
+
minVersion: "17.0.0",
|
|
522
|
+
version: "22.2.2",
|
|
523
|
+
type: MnButton,
|
|
524
|
+
isStandalone: true,
|
|
525
|
+
selector: "button[mnButton], a[mnButton]",
|
|
526
|
+
inputs: { data: "data" },
|
|
527
|
+
host: { properties: {
|
|
528
|
+
"class": "this.hostClasses",
|
|
529
|
+
"attr.aria-busy": "this.ariaBusy",
|
|
530
|
+
"attr.aria-disabled": "this.ariaDisabled",
|
|
531
|
+
"attr.disabled": "this.disabledAttr",
|
|
532
|
+
"attr.tabindex": "this.tabIndex"
|
|
533
|
+
} },
|
|
534
|
+
ngImport: i0,
|
|
535
|
+
template: "@if (data.loading) {\n <span\n aria-hidden=\"true\"\n class=\"inline-block h-4 w-4 shrink-0 mr-2 animate-spin rounded-full border-2 border-current border-r-transparent\"\n ></span>\n}\n<ng-content></ng-content>\n"
|
|
536
|
+
});
|
|
537
|
+
};
|
|
538
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
539
|
+
minVersion: "12.0.0",
|
|
540
|
+
version: "22.2.2",
|
|
541
|
+
ngImport: i0,
|
|
542
|
+
type: MnButton,
|
|
543
|
+
decorators: [{
|
|
544
|
+
type: Component,
|
|
545
|
+
args: [{
|
|
546
|
+
selector: "button[mnButton], a[mnButton]",
|
|
547
|
+
standalone: true,
|
|
548
|
+
template: "@if (data.loading) {\n <span\n aria-hidden=\"true\"\n class=\"inline-block h-4 w-4 shrink-0 mr-2 animate-spin rounded-full border-2 border-current border-r-transparent\"\n ></span>\n}\n<ng-content></ng-content>\n"
|
|
549
|
+
}]
|
|
550
|
+
}],
|
|
551
|
+
propDecorators: {
|
|
552
|
+
data: [{ type: Input }],
|
|
553
|
+
hostClasses: [{
|
|
554
|
+
type: HostBinding,
|
|
555
|
+
args: ["class"]
|
|
556
|
+
}],
|
|
557
|
+
ariaBusy: [{
|
|
558
|
+
type: HostBinding,
|
|
559
|
+
args: ["attr.aria-busy"]
|
|
560
|
+
}],
|
|
561
|
+
ariaDisabled: [{
|
|
562
|
+
type: HostBinding,
|
|
563
|
+
args: ["attr.aria-disabled"]
|
|
564
|
+
}],
|
|
565
|
+
disabledAttr: [{
|
|
566
|
+
type: HostBinding,
|
|
567
|
+
args: ["attr.disabled"]
|
|
568
|
+
}],
|
|
569
|
+
tabIndex: [{
|
|
570
|
+
type: HostBinding,
|
|
571
|
+
args: ["attr.tabindex"]
|
|
572
|
+
}]
|
|
573
|
+
}
|
|
170
574
|
});
|
|
171
|
-
|
|
172
|
-
class MnButton {
|
|
173
|
-
data = {};
|
|
174
|
-
// A loading button is treated as non-interactive: it blocks clicks and is unfocusable,
|
|
175
|
-
// Bind the computed classes to the host element
|
|
176
|
-
get hostClasses() {
|
|
177
|
-
return mnButtonVariants({
|
|
178
|
-
size: this.data.size,
|
|
179
|
-
variant: this.data.variant,
|
|
180
|
-
color: this.data.color,
|
|
181
|
-
borderRadius: this.data.borderRadius,
|
|
182
|
-
shape: this.data.shape,
|
|
183
|
-
disabled: this.data.disabled,
|
|
184
|
-
loading: this.data.loading,
|
|
185
|
-
wrap: this.data.wrap,
|
|
186
|
-
hover: this.data.hover,
|
|
187
|
-
});
|
|
188
|
-
}
|
|
189
|
-
// Signals assistive tech that the control is busy while a loading action runs.
|
|
190
|
-
get ariaBusy() {
|
|
191
|
-
return this.data.loading ? 'true' : null;
|
|
192
|
-
}
|
|
193
|
-
// For accessibility (works for both <button> and <a>)
|
|
194
|
-
get ariaDisabled() {
|
|
195
|
-
return this.data.disabled ? 'true' : null;
|
|
196
|
-
}
|
|
197
|
-
// Only meaningful for <button>. For <a> it does nothing semantically.
|
|
198
|
-
get disabledAttr() {
|
|
199
|
-
return this.isBlocked ? '' : null;
|
|
200
|
-
}
|
|
201
|
-
// Make disabled/loading anchors unfocusable + prevent activation
|
|
202
|
-
get tabIndex() {
|
|
203
|
-
return this.isBlocked ? '-1' : null;
|
|
204
|
-
}
|
|
205
|
-
// so an in-flight action cannot be triggered a second time.
|
|
206
|
-
get isBlocked() {
|
|
207
|
-
return !!(this.data.disabled || this.data.loading);
|
|
208
|
-
}
|
|
209
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: MnButton, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
210
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: MnButton, isStandalone: true, selector: "button[mnButton], a[mnButton]", inputs: { data: "data" }, host: { properties: { "class": "this.hostClasses", "attr.aria-busy": "this.ariaBusy", "attr.aria-disabled": "this.ariaDisabled", "attr.disabled": "this.disabledAttr", "attr.tabindex": "this.tabIndex" } }, ngImport: i0, template: "@if (data.loading) {\n <span\n aria-hidden=\"true\"\n class=\"inline-block h-4 w-4 shrink-0 mr-2 animate-spin rounded-full border-2 border-current border-r-transparent\"\n ></span>\n}\n<ng-content></ng-content>\n" });
|
|
211
|
-
}
|
|
212
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: MnButton, decorators: [{
|
|
213
|
-
type: Component,
|
|
214
|
-
args: [{ selector: 'button[mnButton], a[mnButton]', standalone: true, template: "@if (data.loading) {\n <span\n aria-hidden=\"true\"\n class=\"inline-block h-4 w-4 shrink-0 mr-2 animate-spin rounded-full border-2 border-current border-r-transparent\"\n ></span>\n}\n<ng-content></ng-content>\n" }]
|
|
215
|
-
}], propDecorators: { data: [{
|
|
216
|
-
type: Input
|
|
217
|
-
}], hostClasses: [{
|
|
218
|
-
type: HostBinding,
|
|
219
|
-
args: ['class']
|
|
220
|
-
}], ariaBusy: [{
|
|
221
|
-
type: HostBinding,
|
|
222
|
-
args: ['attr.aria-busy']
|
|
223
|
-
}], ariaDisabled: [{
|
|
224
|
-
type: HostBinding,
|
|
225
|
-
args: ['attr.aria-disabled']
|
|
226
|
-
}], disabledAttr: [{
|
|
227
|
-
type: HostBinding,
|
|
228
|
-
args: ['attr.disabled']
|
|
229
|
-
}], tabIndex: [{
|
|
230
|
-
type: HostBinding,
|
|
231
|
-
args: ['attr.tabindex']
|
|
232
|
-
}] } });
|
|
233
|
-
|
|
234
575
|
const mnBadgeVariants = tv({
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
576
|
+
base: "inline-flex items-center rounded-md border font-semibold",
|
|
577
|
+
variants: {
|
|
578
|
+
size: {
|
|
579
|
+
sm: "px-1.5 py-0.5 text-xs",
|
|
580
|
+
md: "px-2 py-0.5 text-sm",
|
|
581
|
+
lg: "px-2.5 py-1 text-base",
|
|
582
|
+
xl: "px-3 py-1.5 text-lg"
|
|
583
|
+
},
|
|
584
|
+
variant: {
|
|
585
|
+
default: "",
|
|
586
|
+
fill: ""
|
|
587
|
+
},
|
|
588
|
+
wrap: {
|
|
589
|
+
true: "whitespace-normal",
|
|
590
|
+
false: "whitespace-nowrap"
|
|
591
|
+
},
|
|
592
|
+
color: {
|
|
593
|
+
primary: "",
|
|
594
|
+
secondary: "",
|
|
595
|
+
danger: "",
|
|
596
|
+
warning: "",
|
|
597
|
+
success: "",
|
|
598
|
+
accent: "",
|
|
599
|
+
lightgray: ""
|
|
600
|
+
}
|
|
601
|
+
},
|
|
602
|
+
compoundVariants: [
|
|
603
|
+
{
|
|
604
|
+
variant: "default",
|
|
605
|
+
color: "primary",
|
|
606
|
+
class: "bg-primary/10 border-primary/40 text-(--color-primary-text,var(--color-primary))"
|
|
607
|
+
},
|
|
608
|
+
{
|
|
609
|
+
variant: "default",
|
|
610
|
+
color: "secondary",
|
|
611
|
+
class: "bg-secondary/10 border-secondary/40 text-(--color-secondary-text,var(--color-secondary))"
|
|
612
|
+
},
|
|
613
|
+
{
|
|
614
|
+
variant: "default",
|
|
615
|
+
color: "danger",
|
|
616
|
+
class: "bg-error/10 border-error/40 text-(--color-error-text,var(--color-error))"
|
|
617
|
+
},
|
|
618
|
+
{
|
|
619
|
+
variant: "default",
|
|
620
|
+
color: "warning",
|
|
621
|
+
class: "bg-warning/10 border-warning/40 text-(--color-warning-text,var(--color-warning))"
|
|
622
|
+
},
|
|
623
|
+
{
|
|
624
|
+
variant: "default",
|
|
625
|
+
color: "success",
|
|
626
|
+
class: "bg-success/10 border-success/40 text-(--color-success-text,var(--color-success))"
|
|
627
|
+
},
|
|
628
|
+
{
|
|
629
|
+
variant: "default",
|
|
630
|
+
color: "accent",
|
|
631
|
+
class: "bg-accent/10 border-accent/40 text-(--color-accent-text,var(--color-accent))"
|
|
632
|
+
},
|
|
633
|
+
{
|
|
634
|
+
variant: "default",
|
|
635
|
+
color: "lightgray",
|
|
636
|
+
class: "bg-base-content/10 border-base-content/70 text-base-content/70"
|
|
637
|
+
},
|
|
638
|
+
{
|
|
639
|
+
variant: "fill",
|
|
640
|
+
color: "primary",
|
|
641
|
+
class: "bg-primary border-primary text-primary-content"
|
|
642
|
+
},
|
|
643
|
+
{
|
|
644
|
+
variant: "fill",
|
|
645
|
+
color: "secondary",
|
|
646
|
+
class: "bg-secondary border-secondary text-secondary-content"
|
|
647
|
+
},
|
|
648
|
+
{
|
|
649
|
+
variant: "fill",
|
|
650
|
+
color: "danger",
|
|
651
|
+
class: "bg-error border-error text-error-content"
|
|
652
|
+
},
|
|
653
|
+
{
|
|
654
|
+
variant: "fill",
|
|
655
|
+
color: "warning",
|
|
656
|
+
class: "bg-warning border-warning text-warning-content"
|
|
657
|
+
},
|
|
658
|
+
{
|
|
659
|
+
variant: "fill",
|
|
660
|
+
color: "success",
|
|
661
|
+
class: "bg-success border-success text-success-content"
|
|
662
|
+
},
|
|
663
|
+
{
|
|
664
|
+
variant: "fill",
|
|
665
|
+
color: "accent",
|
|
666
|
+
class: "bg-accent border-accent text-accent-content"
|
|
667
|
+
},
|
|
668
|
+
{
|
|
669
|
+
variant: "fill",
|
|
670
|
+
color: "lightgray",
|
|
671
|
+
class: "bg-base-content/70 border-base-content/70 text-base-100"
|
|
672
|
+
}
|
|
673
|
+
],
|
|
674
|
+
defaultVariants: {
|
|
675
|
+
size: "md",
|
|
676
|
+
variant: "default",
|
|
677
|
+
color: "primary",
|
|
678
|
+
wrap: false
|
|
679
|
+
}
|
|
680
|
+
});
|
|
681
|
+
var MnBadge = class MnBadge {
|
|
682
|
+
data = {};
|
|
683
|
+
get hostClasses() {
|
|
684
|
+
return mnBadgeVariants({
|
|
685
|
+
size: this.data.size,
|
|
686
|
+
variant: this.data.variant,
|
|
687
|
+
color: this.data.color,
|
|
688
|
+
wrap: this.data.wrap
|
|
689
|
+
});
|
|
690
|
+
}
|
|
691
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
692
|
+
minVersion: "12.0.0",
|
|
693
|
+
version: "22.2.2",
|
|
694
|
+
ngImport: i0,
|
|
695
|
+
type: MnBadge,
|
|
696
|
+
deps: [],
|
|
697
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
698
|
+
});
|
|
699
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
700
|
+
minVersion: "14.0.0",
|
|
701
|
+
version: "22.2.2",
|
|
702
|
+
type: MnBadge,
|
|
703
|
+
isStandalone: true,
|
|
704
|
+
selector: "span[mnBadge]",
|
|
705
|
+
inputs: { data: "data" },
|
|
706
|
+
host: { properties: { "class": "this.hostClasses" } },
|
|
707
|
+
ngImport: i0,
|
|
708
|
+
template: "<ng-content></ng-content>\n"
|
|
709
|
+
});
|
|
710
|
+
};
|
|
711
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
712
|
+
minVersion: "12.0.0",
|
|
713
|
+
version: "22.2.2",
|
|
714
|
+
ngImport: i0,
|
|
715
|
+
type: MnBadge,
|
|
716
|
+
decorators: [{
|
|
717
|
+
type: Component,
|
|
718
|
+
args: [{
|
|
719
|
+
selector: "span[mnBadge]",
|
|
720
|
+
standalone: true,
|
|
721
|
+
template: "<ng-content></ng-content>\n"
|
|
722
|
+
}]
|
|
723
|
+
}],
|
|
724
|
+
propDecorators: {
|
|
725
|
+
data: [{ type: Input }],
|
|
726
|
+
hostClasses: [{
|
|
727
|
+
type: HostBinding,
|
|
728
|
+
args: ["class"]
|
|
729
|
+
}]
|
|
730
|
+
}
|
|
288
731
|
});
|
|
289
|
-
|
|
290
|
-
class MnBadge {
|
|
291
|
-
data = {};
|
|
292
|
-
get hostClasses() {
|
|
293
|
-
return mnBadgeVariants({
|
|
294
|
-
size: this.data.size,
|
|
295
|
-
variant: this.data.variant,
|
|
296
|
-
color: this.data.color,
|
|
297
|
-
wrap: this.data.wrap,
|
|
298
|
-
});
|
|
299
|
-
}
|
|
300
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: MnBadge, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
301
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.7", type: MnBadge, isStandalone: true, selector: "span[mnBadge]", inputs: { data: "data" }, host: { properties: { "class": "this.hostClasses" } }, ngImport: i0, template: "<ng-content></ng-content>\n" });
|
|
302
|
-
}
|
|
303
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: MnBadge, decorators: [{
|
|
304
|
-
type: Component,
|
|
305
|
-
args: [{ selector: 'span[mnBadge]', standalone: true, template: "<ng-content></ng-content>\n" }]
|
|
306
|
-
}], propDecorators: { data: [{
|
|
307
|
-
type: Input
|
|
308
|
-
}], hostClasses: [{
|
|
309
|
-
type: HostBinding,
|
|
310
|
-
args: ['class']
|
|
311
|
-
}] } });
|
|
312
|
-
|
|
313
732
|
const mnSkeletonVariants = tv({
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
733
|
+
base: "bg-base-300 relative overflow-hidden",
|
|
734
|
+
variants: { shape: {
|
|
735
|
+
rectangle: "rounded-md h-4",
|
|
736
|
+
circle: "rounded-full h-10 w-10",
|
|
737
|
+
text: "rounded h-4"
|
|
738
|
+
} },
|
|
739
|
+
defaultVariants: { shape: "rectangle" }
|
|
740
|
+
});
|
|
741
|
+
var MnSkeleton = class MnSkeleton {
|
|
742
|
+
data = {};
|
|
743
|
+
ariaHidden = "true";
|
|
744
|
+
get hostClasses() {
|
|
745
|
+
return mnSkeletonVariants({ shape: this.data.shape });
|
|
746
|
+
}
|
|
747
|
+
get width() {
|
|
748
|
+
return this.data.width ?? null;
|
|
749
|
+
}
|
|
750
|
+
get height() {
|
|
751
|
+
return this.data.height ?? null;
|
|
752
|
+
}
|
|
753
|
+
get appearDelay() {
|
|
754
|
+
return this.data.appearDelay == null ? null : `${this.data.appearDelay}ms`;
|
|
755
|
+
}
|
|
756
|
+
get isAnimated() {
|
|
757
|
+
return this.data.animated !== false;
|
|
758
|
+
}
|
|
759
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
760
|
+
minVersion: "12.0.0",
|
|
761
|
+
version: "22.2.2",
|
|
762
|
+
ngImport: i0,
|
|
763
|
+
type: MnSkeleton,
|
|
764
|
+
deps: [],
|
|
765
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
766
|
+
});
|
|
767
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
768
|
+
minVersion: "17.0.0",
|
|
769
|
+
version: "22.2.2",
|
|
770
|
+
type: MnSkeleton,
|
|
771
|
+
isStandalone: true,
|
|
772
|
+
selector: "mn-skeleton",
|
|
773
|
+
inputs: { data: "data" },
|
|
774
|
+
host: { properties: {
|
|
775
|
+
"attr.aria-hidden": "this.ariaHidden",
|
|
776
|
+
"class": "this.hostClasses",
|
|
777
|
+
"style.width": "this.width",
|
|
778
|
+
"style.height": "this.height",
|
|
779
|
+
"style.animation-delay": "this.appearDelay"
|
|
780
|
+
} },
|
|
781
|
+
ngImport: i0,
|
|
782
|
+
template: "@if (isAnimated) {\n <span class=\"mn-skeleton-shimmer-bar\"></span>\n}\n",
|
|
783
|
+
styles: [":host{display:block;animation:mn-skeleton-appear .15s ease-out .3s both}@keyframes mn-skeleton-appear{0%{opacity:0}}@keyframes mn-skeleton-shimmer{0%{transform:translate(-150%)}to{transform:translate(150%)}}.mn-skeleton-shimmer-bar{position:absolute;inset:0;background:linear-gradient(90deg,transparent 0%,color-mix(in srgb,var(--color-base-100) 65%,transparent) 50%,transparent 100%);animation:mn-skeleton-shimmer 1.5s ease-in-out infinite}@media(prefers-reduced-motion:reduce){.mn-skeleton-shimmer-bar{animation:none}}\n"]
|
|
784
|
+
});
|
|
785
|
+
};
|
|
786
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
787
|
+
minVersion: "12.0.0",
|
|
788
|
+
version: "22.2.2",
|
|
789
|
+
ngImport: i0,
|
|
790
|
+
type: MnSkeleton,
|
|
791
|
+
decorators: [{
|
|
792
|
+
type: Component,
|
|
793
|
+
args: [{
|
|
794
|
+
selector: "mn-skeleton",
|
|
795
|
+
standalone: true,
|
|
796
|
+
template: "@if (isAnimated) {\n <span class=\"mn-skeleton-shimmer-bar\"></span>\n}\n",
|
|
797
|
+
styles: [":host{display:block;animation:mn-skeleton-appear .15s ease-out .3s both}@keyframes mn-skeleton-appear{0%{opacity:0}}@keyframes mn-skeleton-shimmer{0%{transform:translate(-150%)}to{transform:translate(150%)}}.mn-skeleton-shimmer-bar{position:absolute;inset:0;background:linear-gradient(90deg,transparent 0%,color-mix(in srgb,var(--color-base-100) 65%,transparent) 50%,transparent 100%);animation:mn-skeleton-shimmer 1.5s ease-in-out infinite}@media(prefers-reduced-motion:reduce){.mn-skeleton-shimmer-bar{animation:none}}\n"]
|
|
798
|
+
}]
|
|
799
|
+
}],
|
|
800
|
+
propDecorators: {
|
|
801
|
+
data: [{ type: Input }],
|
|
802
|
+
ariaHidden: [{
|
|
803
|
+
type: HostBinding,
|
|
804
|
+
args: ["attr.aria-hidden"]
|
|
805
|
+
}],
|
|
806
|
+
hostClasses: [{
|
|
807
|
+
type: HostBinding,
|
|
808
|
+
args: ["class"]
|
|
809
|
+
}],
|
|
810
|
+
width: [{
|
|
811
|
+
type: HostBinding,
|
|
812
|
+
args: ["style.width"]
|
|
813
|
+
}],
|
|
814
|
+
height: [{
|
|
815
|
+
type: HostBinding,
|
|
816
|
+
args: ["style.height"]
|
|
817
|
+
}],
|
|
818
|
+
appearDelay: [{
|
|
819
|
+
type: HostBinding,
|
|
820
|
+
args: ["style.animation-delay"]
|
|
821
|
+
}]
|
|
822
|
+
}
|
|
328
823
|
});
|
|
329
|
-
|
|
330
|
-
class MnSkeleton {
|
|
331
|
-
data = {};
|
|
332
|
-
// Skeletons are decorative loading placeholders; hide them from assistive tech.
|
|
333
|
-
// The container that swaps skeleton↔content should carry aria-busy / a live region.
|
|
334
|
-
ariaHidden = 'true';
|
|
335
|
-
get hostClasses() {
|
|
336
|
-
return mnSkeletonVariants({ shape: this.data.shape });
|
|
337
|
-
}
|
|
338
|
-
get width() {
|
|
339
|
-
return this.data.width ?? null;
|
|
340
|
-
}
|
|
341
|
-
get height() {
|
|
342
|
-
return this.data.height ?? null;
|
|
343
|
-
}
|
|
344
|
-
/** The caller's {@link MnSkeletonProps.appearDelay}, overriding the stylesheet's 300 ms. */
|
|
345
|
-
get appearDelay() {
|
|
346
|
-
return this.data.appearDelay == null ? null : `${this.data.appearDelay}ms`;
|
|
347
|
-
}
|
|
348
|
-
get isAnimated() {
|
|
349
|
-
return this.data.animated !== false;
|
|
350
|
-
}
|
|
351
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: MnSkeleton, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
352
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: MnSkeleton, isStandalone: true, selector: "mn-skeleton", inputs: { data: "data" }, host: { properties: { "attr.aria-hidden": "this.ariaHidden", "class": "this.hostClasses", "style.width": "this.width", "style.height": "this.height", "style.animation-delay": "this.appearDelay" } }, ngImport: i0, template: "@if (isAnimated) {\n <span class=\"mn-skeleton-shimmer-bar\"></span>\n}\n", styles: [":host{display:block;animation:mn-skeleton-appear .15s ease-out .3s both}@keyframes mn-skeleton-appear{0%{opacity:0}}@keyframes mn-skeleton-shimmer{0%{transform:translate(-150%)}to{transform:translate(150%)}}.mn-skeleton-shimmer-bar{position:absolute;inset:0;background:linear-gradient(90deg,transparent 0%,color-mix(in srgb,var(--color-base-100) 65%,transparent) 50%,transparent 100%);animation:mn-skeleton-shimmer 1.5s ease-in-out infinite}@media(prefers-reduced-motion:reduce){.mn-skeleton-shimmer-bar{animation:none}}\n"] });
|
|
353
|
-
}
|
|
354
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: MnSkeleton, decorators: [{
|
|
355
|
-
type: Component,
|
|
356
|
-
args: [{ selector: 'mn-skeleton', standalone: true, template: "@if (isAnimated) {\n <span class=\"mn-skeleton-shimmer-bar\"></span>\n}\n", styles: [":host{display:block;animation:mn-skeleton-appear .15s ease-out .3s both}@keyframes mn-skeleton-appear{0%{opacity:0}}@keyframes mn-skeleton-shimmer{0%{transform:translate(-150%)}to{transform:translate(150%)}}.mn-skeleton-shimmer-bar{position:absolute;inset:0;background:linear-gradient(90deg,transparent 0%,color-mix(in srgb,var(--color-base-100) 65%,transparent) 50%,transparent 100%);animation:mn-skeleton-shimmer 1.5s ease-in-out infinite}@media(prefers-reduced-motion:reduce){.mn-skeleton-shimmer-bar{animation:none}}\n"] }]
|
|
357
|
-
}], propDecorators: { data: [{
|
|
358
|
-
type: Input
|
|
359
|
-
}], ariaHidden: [{
|
|
360
|
-
type: HostBinding,
|
|
361
|
-
args: ['attr.aria-hidden']
|
|
362
|
-
}], hostClasses: [{
|
|
363
|
-
type: HostBinding,
|
|
364
|
-
args: ['class']
|
|
365
|
-
}], width: [{
|
|
366
|
-
type: HostBinding,
|
|
367
|
-
args: ['style.width']
|
|
368
|
-
}], height: [{
|
|
369
|
-
type: HostBinding,
|
|
370
|
-
args: ['style.height']
|
|
371
|
-
}], appearDelay: [{
|
|
372
|
-
type: HostBinding,
|
|
373
|
-
args: ['style.animation-delay']
|
|
374
|
-
}] } });
|
|
375
|
-
|
|
376
|
-
/**
|
|
377
|
-
* Public API of the `mn-angular-lib/button` entry point: button, badge and skeleton primitives.
|
|
378
|
-
*
|
|
379
|
-
* Each entry point is its own module in the published package, so a consumer's bundler
|
|
380
|
-
* splits it into the chunk that uses it instead of loading the whole library at startup.
|
|
381
|
-
* The root `mn-angular-lib` entry re-exports every entry point.
|
|
382
|
-
*/
|
|
383
|
-
|
|
384
|
-
/**
|
|
385
|
-
* Generated bundle index. Do not edit.
|
|
386
|
-
*/
|
|
387
|
-
|
|
388
824
|
export { MnBadge, MnButton, MnSkeleton, mnBadgeVariants, mnButtonVariants, mnSkeletonVariants };
|
|
389
|
-
|
|
825
|
+
|
|
826
|
+
//# sourceMappingURL=mn-angular-lib-button.mjs.map
|