vanilla-jui 1.7.3 → 1.7.5

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vanilla-jui",
3
- "version": "1.7.3",
3
+ "version": "1.7.5",
4
4
  "private": false,
5
5
  "description": "A lightweight, reactive, and fully customizable vanilla JS UI library.",
6
6
  "keywords": [
@@ -12,9 +12,6 @@
12
12
  display: flex;
13
13
  align-items: center;
14
14
  cursor: pointer;
15
- -webkit-user-select: none;
16
- -moz-user-select: none;
17
- -ms-user-select: none;
18
15
  user-select: none;
19
16
  }
20
17
 
@@ -1,22 +1,14 @@
1
1
  @layer animation {
2
2
  /* none */
3
3
  .animate-none {
4
- -webkit-animation: none;
5
4
  animation: none;
6
5
  }
7
6
 
8
7
  /* spin */
9
8
  .animate-spin {
10
- -webkit-animation: animate-spin 1s linear infinite;
11
9
  animation: animate-spin 1s linear infinite;
12
10
  }
13
11
 
14
- @-webkit-keyframes animate-spin {
15
- to {
16
- transform: rotate(360deg);
17
- }
18
- }
19
-
20
12
  @keyframes animate-spin {
21
13
  to {
22
14
  transform: rotate(360deg);
@@ -25,18 +17,9 @@
25
17
 
26
18
  /* ping */
27
19
  .animate-ping {
28
- -webkit-animation: animate-ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
29
20
  animation: animate-ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
30
21
  }
31
22
 
32
- @-webkit-keyframes animate-ping {
33
- 75%,
34
- 100% {
35
- transform: scale(2);
36
- opacity: 0;
37
- }
38
- }
39
-
40
23
  @keyframes animate-ping {
41
24
  75%,
42
25
  100% {
@@ -47,16 +30,9 @@
47
30
 
48
31
  /* pulse */
49
32
  .animate-pulse {
50
- -webkit-animation: animate-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
51
33
  animation: animate-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
52
34
  }
53
35
 
54
- @-webkit-keyframes animate-pulse {
55
- 50% {
56
- opacity: 0.5;
57
- }
58
- }
59
-
60
36
  @keyframes animate-pulse {
61
37
  50% {
62
38
  opacity: 0.5;
@@ -65,21 +41,19 @@
65
41
 
66
42
  /* bounce */
67
43
  .animate-bounce {
68
- -webkit-animation: animate-bounce 1s infinite;
69
44
  animation: animate-bounce 1s infinite;
70
45
  }
71
46
 
72
- @-webkit-keyframes animate-bounce {
47
+ @keyframes animate-bounce {
73
48
  0%,
74
49
  100% {
75
50
  transform: translateY(-25%);
76
- -webkit-animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
77
51
  animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
78
52
  }
79
53
 
80
54
  50% {
81
55
  transform: translateY(0);
82
- -webkit-animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
56
+
83
57
  animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
84
58
  }
85
59
  }
@@ -88,35 +62,21 @@
88
62
  0%,
89
63
  100% {
90
64
  transform: translateY(-25%);
91
- -webkit-animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
92
65
  animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
93
66
  }
94
67
 
95
68
  50% {
96
69
  transform: translateY(0);
97
- -webkit-animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
70
+
98
71
  animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
99
72
  }
100
73
  }
101
74
 
102
75
  /* fade in */
103
76
  .animate-fade-in {
104
- -webkit-animation: animate-fade-in 0.3s ease-in-out;
105
77
  animation: animate-fade-in 0.3s ease-in-out;
106
78
  }
107
79
 
108
- @-webkit-keyframes animate-fade-in {
109
- 0% {
110
- opacity: 0;
111
- transform: scale(0.8);
112
- }
113
-
114
- 100% {
115
- opacity: 1;
116
- transform: scale(1);
117
- }
118
- }
119
-
120
80
  @keyframes animate-fade-in {
121
81
  0% {
122
82
  opacity: 0;
@@ -131,22 +91,9 @@
131
91
 
132
92
  /* fade out */
133
93
  .animate-fade-out {
134
- -webkit-animation: animate-fade-out 0.3s ease-in-out;
135
94
  animation: animate-fade-out 0.3s ease-in-out;
136
95
  }
137
96
 
138
- @-webkit-keyframes animate-fade-out {
139
- 0% {
140
- opacity: 1;
141
- transform: scale(1);
142
- }
143
-
144
- 100% {
145
- opacity: 0;
146
- transform: scale(0.8);
147
- }
148
- }
149
-
150
97
  @keyframes animate-fade-out {
151
98
  0% {
152
99
  opacity: 1;
@@ -161,11 +108,10 @@
161
108
 
162
109
  /* shake */
163
110
  .animate-shake {
164
- -webkit-animation: animate-shake 0.3s ease-in-out;
165
111
  animation: animate-shake 0.3s ease-in-out;
166
112
  }
167
113
 
168
- @-webkit-keyframes animate-shake {
114
+ @keyframes animate-shake {
169
115
  0%,
170
116
  100% {
171
117
  transform: translateX(0);
@@ -205,20 +151,9 @@
205
151
 
206
152
  /* slide-to-top */
207
153
  .animate-slide-to-top {
208
- -webkit-animation: animate-slide-to-top 0.3s ease-in-out;
209
154
  animation: animate-slide-to-top 0.3s ease-in-out;
210
155
  }
211
156
 
212
- @-webkit-keyframes animate-slide-to-top {
213
- 0% {
214
- transform: translateY(0);
215
- }
216
-
217
- 100% {
218
- transform: translateY(-100%);
219
- }
220
- }
221
-
222
157
  @keyframes animate-slide-to-top {
223
158
  0% {
224
159
  transform: translateY(0);
@@ -231,20 +166,9 @@
231
166
 
232
167
  /* slide-to-right */
233
168
  .animate-slide-to-right {
234
- -webkit-animation: animate-slide-to-right 0.3s ease-in-out;
235
169
  animation: animate-slide-to-right 0.3s ease-in-out;
236
170
  }
237
171
 
238
- @-webkit-keyframes animate-slide-to-right {
239
- 0% {
240
- transform: translateX(0);
241
- }
242
-
243
- 100% {
244
- transform: translateX(100%);
245
- }
246
- }
247
-
248
172
  @keyframes animate-slide-to-right {
249
173
  0% {
250
174
  transform: translateX(0);
@@ -257,20 +181,9 @@
257
181
 
258
182
  /* slide-to-bottom */
259
183
  .animate-slide-to-bottom {
260
- -webkit-animation: animate-slide-to-bottom 0.3s ease-in-out;
261
184
  animation: animate-slide-to-bottom 0.3s ease-in-out;
262
185
  }
263
186
 
264
- @-webkit-keyframes animate-slide-to-bottom {
265
- 0% {
266
- transform: translateY(0);
267
- }
268
-
269
- 100% {
270
- transform: translateY(100%);
271
- }
272
- }
273
-
274
187
  @keyframes animate-slide-to-bottom {
275
188
  0% {
276
189
  transform: translateY(0);
@@ -283,20 +196,9 @@
283
196
 
284
197
  /* slide-to-left */
285
198
  .animate-slide-to-left {
286
- -webkit-animation: animate-slide-to-left 0.3s ease-in-out;
287
199
  animation: animate-slide-to-left 0.3s ease-in-out;
288
200
  }
289
201
 
290
- @-webkit-keyframes animate-slide-to-left {
291
- 0% {
292
- transform: translateX(0);
293
- }
294
-
295
- 100% {
296
- transform: translateX(-100%);
297
- }
298
- }
299
-
300
202
  @keyframes animate-slide-to-left {
301
203
  0% {
302
204
  transform: translateX(0);
@@ -311,26 +213,23 @@
311
213
  [data-reveal] {
312
214
  opacity: 0;
313
215
  transform: translateY(12px);
314
- -webkit-animation: reveal 0.62s ease forwards;
216
+
315
217
  animation: reveal 0.62s ease forwards;
316
218
  }
317
219
 
318
220
  [data-reveal='2'] {
319
- -webkit-animation-delay: 0.08s;
320
221
  animation-delay: 0.08s;
321
222
  }
322
223
 
323
224
  [data-reveal='3'] {
324
- -webkit-animation-delay: 0.14s;
325
225
  animation-delay: 0.14s;
326
226
  }
327
227
 
328
228
  [data-reveal='4'] {
329
- -webkit-animation-delay: 0.2s;
330
229
  animation-delay: 0.2s;
331
230
  }
332
231
 
333
- @-webkit-keyframes reveal {
232
+ @keyframes reveal {
334
233
  to {
335
234
  opacity: 1;
336
235
  transform: translateY(0);
@@ -3,9 +3,6 @@
3
3
  display: inline-block;
4
4
  vertical-align: middle;
5
5
  overflow: hidden;
6
- -webkit-user-select: none;
7
- -moz-user-select: none;
8
- -ms-user-select: none;
9
6
  user-select: none;
10
7
  -o-object-fit: cover;
11
8
  object-fit: cover;
package/src/css/badge.css CHANGED
@@ -3,9 +3,6 @@
3
3
  display: inline-flex;
4
4
  justify-content: center;
5
5
  align-items: center;
6
- -webkit-user-select: none;
7
- -moz-user-select: none;
8
- -ms-user-select: none;
9
6
  user-select: none;
10
7
  }
11
8
  }
@@ -1,9 +1,6 @@
1
1
  @layer components {
2
2
  .j-breadcrumb {
3
3
  white-space: nowrap;
4
- -webkit-user-select: none;
5
- -moz-user-select: none;
6
- -ms-user-select: none;
7
4
  user-select: none;
8
5
  }
9
6
 
@@ -25,7 +22,6 @@
25
22
  }
26
23
 
27
24
  .j-breadcrumb li:first-child a {
28
- -webkit-padding-start: 0;
29
25
  padding-inline-start: 0;
30
26
  }
31
27
 
@@ -6,12 +6,7 @@
6
6
  flex-wrap: nowrap;
7
7
  position: relative;
8
8
  white-space: nowrap;
9
- -webkit-appearance: button;
10
- -moz-appearance: button;
11
9
  appearance: button;
12
- -webkit-user-select: none;
13
- -moz-user-select: none;
14
- -ms-user-select: none;
15
10
  user-select: none;
16
11
  touch-action: manipulation;
17
12
  }
package/src/css/card.css CHANGED
@@ -46,8 +46,6 @@
46
46
  margin: 0;
47
47
  padding: 0;
48
48
  padding: var(--space) var(--s2);
49
- -webkit-appearance: none;
50
- -moz-appearance: none;
51
49
  appearance: none;
52
50
  cursor: pointer;
53
51
  }
@@ -70,7 +68,6 @@
70
68
  .j-card figure img {
71
69
  width: 100%;
72
70
  height: 100%;
73
- -o-object-fit: cover;
74
71
  object-fit: cover;
75
72
  }
76
73
 
@@ -116,7 +116,7 @@
116
116
  .j-editor u {
117
117
  text-decoration: underline;
118
118
  text-decoration-thickness: 4px;
119
- -webkit-text-decoration-color: var(--editor-ring);
119
+
120
120
  text-decoration-color: var(--editor-ring);
121
121
  text-underline-offset: 0.2em;
122
122
  }
@@ -150,9 +150,7 @@
150
150
  }
151
151
 
152
152
  .j-editor abbr[title] {
153
- -webkit-text-decoration: underline dotted;
154
153
  text-decoration: underline dotted;
155
- -webkit-text-decoration-color: var(--tone-muted);
156
154
  text-decoration-color: var(--tone-muted);
157
155
  text-underline-offset: 0.2em;
158
156
  cursor: help;
@@ -178,25 +176,17 @@
178
176
  .j-editor a {
179
177
  color: var(--editor-link);
180
178
  text-decoration: none;
181
- -webkit-text-decoration-color: transparent;
179
+
182
180
  text-decoration-color: transparent;
183
181
  text-underline-offset: 0.15em;
184
- transition:
185
- color 0.15s,
186
- -webkit-text-decoration-color 0.15s;
187
182
  transition:
188
183
  color 0.15s,
189
184
  text-decoration-color 0.15s;
190
- transition:
191
- color 0.15s,
192
- text-decoration-color 0.15s,
193
- -webkit-text-decoration-color 0.15s;
194
185
  }
195
186
 
196
187
  .j-editor a:hover {
197
188
  color: var(--editor-link-hover);
198
189
  text-decoration: underline;
199
- -webkit-text-decoration-color: var(--editor-link-hover);
200
190
  text-decoration-color: var(--editor-link-hover);
201
191
  }
202
192
 
@@ -292,14 +282,11 @@
292
282
  ============================================ */
293
283
  .j-editor blockquote {
294
284
  margin: var(--editor-block-space) 0;
295
- margin-left: 0;
296
- margin-right: 0;
297
285
  padding: 0.75rem 1.25rem;
298
286
  border-left: 3px solid var(--editor-border-tone);
299
287
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
300
288
  background-color: var(--editor-blockquote-bg);
301
289
  color: var(--editor-blockquote-fg);
302
- font-style: italic;
303
290
  }
304
291
 
305
292
  /* .j-editor blockquote p {
@@ -331,7 +318,6 @@
331
318
  Code - 代码
332
319
  ============================================ */
333
320
  code {
334
- -webkit-box-decoration-break: clone;
335
321
  box-decoration-break: clone;
336
322
  }
337
323
 
@@ -415,8 +401,6 @@
415
401
  }
416
402
 
417
403
  .code-block .code-header select {
418
- -webkit-appearance: none;
419
- -moz-appearance: none;
420
404
  appearance: none;
421
405
  background: transparent;
422
406
  border: none;
@@ -581,11 +565,11 @@
581
565
  }
582
566
 
583
567
  .j-editor figcaption {
584
- margin-top: 0.75rem;
568
+ margin-top: 0.5rem;
585
569
  font-size: var(--font-size-md);
586
570
  color: var(--editor-caption-fg);
587
571
  text-align: center;
588
- line-height: 1.5;
572
+ line-height: 1.2;
589
573
  }
590
574
 
591
575
  .j-editor iframe,
@@ -753,7 +737,7 @@
753
737
  .j-editor ul[data-type='taskList'] li {
754
738
  display: flex;
755
739
  align-items: center;
756
- gap: 0.25rem;
740
+ gap: 0.5rem;
757
741
  }
758
742
 
759
743
  .j-editor ul[data-type='taskList'] li label,
@@ -763,9 +747,6 @@
763
747
 
764
748
  .j-editor ul[data-type='taskList'] li > label {
765
749
  flex: none;
766
- -webkit-user-select: none;
767
- -moz-user-select: none;
768
- -ms-user-select: none;
769
750
  user-select: none;
770
751
  }
771
752
 
@@ -787,8 +768,6 @@
787
768
  width: 1rem;
788
769
  height: 1rem;
789
770
  margin: 0;
790
- -webkit-appearance: none;
791
- -moz-appearance: none;
792
771
  appearance: none;
793
772
  transition: all 0.05s ease-in-out;
794
773
  }
@@ -798,6 +777,11 @@
798
777
  border-color: var(--tone-solid);
799
778
  }
800
779
 
780
+ .dark .j-editor input[type='checkbox']:checked {
781
+ background: var(--tone-shade);
782
+ border-color: var(--tone-shade);
783
+ }
784
+
801
785
  .j-editor input[type='checkbox']:checked:before {
802
786
  content: url('data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.83%204.89l1.34.94-5.81%208.38H9.02L5.78%209.67l1.34-1.25%202.57%202.4z%27%20fill%3D%27%23ffffff%27%2F%3E%3C%2Fsvg%3E');
803
787
  display: inline-block;
@@ -805,4 +789,10 @@
805
789
  width: 1.3125rem;
806
790
  height: 1.3125rem;
807
791
  }
792
+
793
+ .j-editor ul[data-type='taskList'] li:has(input[type='checkbox']:checked) p {
794
+ text-decoration: line-through;
795
+ text-decoration-color: var(--ui-fg);
796
+ text-decoration-thickness: 2px;
797
+ }
808
798
  }
package/src/css/form.css CHANGED
@@ -109,8 +109,6 @@
109
109
 
110
110
  /* type file */
111
111
  .j-input[type='file'] {
112
- -webkit-appearance: none;
113
- -moz-appearance: none;
114
112
  appearance: none;
115
113
  background-clip: padding-box;
116
114
  overflow: hidden;
@@ -120,8 +118,6 @@
120
118
 
121
119
  .j-input[type='file']::file-selector-button {
122
120
  color: var(--ui-fg-muted);
123
- -webkit-appearance: none;
124
- -moz-appearance: none;
125
121
  appearance: none;
126
122
  border-width: 0;
127
123
  border-inline-end-width: 1px;
@@ -134,13 +130,11 @@
134
130
 
135
131
  .j-input[type='file']::file-selector-button,
136
132
  html.j-font-sm .j-input[type='file']::file-selector-button {
137
- -webkit-margin-end: var(--s2);
138
133
  margin-inline-end: var(--s2);
139
134
  padding: var(--s2);
140
135
  }
141
136
 
142
137
  html.j-font-md .j-input[type='file']::file-selector-button {
143
- -webkit-margin-end: calc(var(--space) * 2.75);
144
138
  margin-inline-end: calc(var(--space) * 2.75);
145
139
  padding: calc(var(--space) * 2.75);
146
140
  }
@@ -202,8 +196,6 @@
202
196
  }
203
197
 
204
198
  .j-radio label input[type='radio'] {
205
- -webkit-appearance: none;
206
- -moz-appearance: none;
207
199
  appearance: none;
208
200
  width: 1rem;
209
201
  height: 1rem;
@@ -263,7 +255,6 @@
263
255
  /* radio group */
264
256
  .j-radio.is-group input[type='radio'] {
265
257
  clip: rect(0 0 0 0);
266
- -webkit-clip-path: inset(100%);
267
258
  clip-path: inset(100%);
268
259
  height: 1px;
269
260
  overflow: hidden;
@@ -285,9 +276,6 @@
285
276
  justify-content: center;
286
277
  align-items: center;
287
278
  text-align: center;
288
- -webkit-user-select: none;
289
- -moz-user-select: none;
290
- -ms-user-select: none;
291
279
  user-select: none;
292
280
  letter-spacing: 0.5px;
293
281
  }
@@ -361,8 +349,6 @@
361
349
 
362
350
  .j-radio label,
363
351
  .j-checkbox label {
364
- width: -webkit-fit-content;
365
- width: -moz-fit-content;
366
352
  width: fit-content;
367
353
  }
368
354
 
@@ -371,8 +357,6 @@
371
357
  }
372
358
 
373
359
  .j-checkbox input[type='checkbox'] {
374
- -webkit-appearance: none;
375
- -moz-appearance: none;
376
360
  appearance: none;
377
361
  width: 1rem;
378
362
  height: 1rem;
@@ -596,9 +580,6 @@
596
580
  display: flex;
597
581
  align-items: center;
598
582
  padding-inline: var(--s2);
599
- -webkit-user-select: none;
600
- -moz-user-select: none;
601
- -ms-user-select: none;
602
583
  user-select: none;
603
584
  }
604
585
 
@@ -54,8 +54,6 @@
54
54
  }
55
55
 
56
56
  .is-reset:where(button) {
57
- -webkit-appearance: none;
58
- -moz-appearance: none;
59
57
  appearance: none;
60
58
  cursor: default;
61
59
  background-color: transparent;
@@ -104,20 +102,12 @@
104
102
  linear-gradient(to right, var(--ui-surface-subtle) 1px, transparent 1px),
105
103
  linear-gradient(to bottom, var(--ui-surface-subtle) 1px, transparent 1px);
106
104
  background-size: 40px 56px;
107
- -webkit-mask-image: radial-gradient(
108
- ellipse 25% 10% at 50% 0%,
109
- #000 60%,
110
- transparent 300%
111
- );
112
105
  mask-image: radial-gradient(
113
106
  ellipse 25% 10% at 50% 0%,
114
107
  #000 60%,
115
108
  transparent 300%
116
109
  );
117
110
  pointer-events: none;
118
- -webkit-user-select: none;
119
- -moz-user-select: none;
120
- -ms-user-select: none;
121
111
  user-select: none;
122
112
  }
123
113
 
@@ -177,8 +167,6 @@
177
167
 
178
168
  .block-center {
179
169
  margin-inline: auto;
180
- height: -webkit-fit-content;
181
- height: -moz-fit-content;
182
170
  height: fit-content;
183
171
  }
184
172