@acorex/styles 4.1.9 → 4.2.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.
package/scss/menu.scss CHANGED
@@ -10,80 +10,28 @@
10
10
  display: block;
11
11
  position: relative;
12
12
  }
13
- .rtl {
14
- .ax {
15
- &.nav-menu {
16
- li.ax-menu-item {
17
- &:hover {
18
- &::after {
19
- right: 0 !important;
20
- left: initial !important;
21
- }
22
- }
23
- }
24
- }
25
- }
26
- }
13
+
27
14
  .ax {
28
15
  &.nav-menu {
29
- li.tooltip {
30
- position: relative; /* making the .tooltip span a container for the tooltip text */
31
-
32
- &:hover {
33
- &::before {
34
- display: block;
35
- }
36
- }
37
- &::before {
38
- content: attr(data-text);
39
- position: absolute;
40
- bottom: -85%;
41
- left: 0;
42
- padding: 0.5rem 1rem;
43
- border-radius: var(--ax-size-border-radius);
44
- background: var(--ax-dark-color);
45
- color: var(--ax-dark-fore-color);
46
- text-align: center;
47
- display: none; /* hide by default */
48
- z-index: 1;
49
- }
50
- }
51
- &.rtl {
52
- ul {
53
- right: -9999px !important;
54
- left: initial !important;
55
-
56
- li {
57
- &:hover {
58
- > ul {
59
- right: 100% !important;
60
- left: initial !important;
61
- }
62
- }
63
- .drop-icon {
64
- position: absolute;
65
- left: 10px;
66
- right: initial;
67
- }
68
- }
16
+ font-size: 0.875rem;
17
+ > li {
18
+ margin-inline-end: 0.5rem;
19
+ border-radius: var(--ax-size-border-radius);
20
+ > .nav-active {
21
+ background-color: rgba(0, 0, 0, 0.05);
69
22
  }
70
23
 
71
- li {
72
-
73
- &:hover {
74
- > ul {
75
- right: 0 !important;
76
- left: initial !important;
77
- }
24
+ :hover {
25
+ > ul {
26
+ inset-inline-start: 100%;
78
27
  }
79
28
  }
80
29
  }
81
-
82
30
  ul {
83
31
  opacity: 0;
84
32
  position: absolute;
85
33
  top: 100%;
86
- left: -9999px;
34
+ inset-inline-start: -9999px;
87
35
  z-index: 50000;
88
36
  -webkit-transition: opacity 0.3s;
89
37
  transition: opacity 0.3s;
@@ -96,76 +44,70 @@
96
44
 
97
45
  .drop-icon {
98
46
  position: absolute;
99
- right: 10px;
100
- left: initial;
47
+ inset-inline-end: 10px;
48
+ inset-inline-start: initial;
101
49
  }
102
50
 
103
51
  &:hover {
104
- // background-color: var(--ax-border-color);
105
-
106
52
  > ul {
107
53
  top: 0;
108
- left: 100%;
54
+ inset-inline-start: 100%;
109
55
  }
110
56
  }
111
57
  }
112
58
  }
113
59
 
114
60
  li {
115
- // cursor: default;
116
- // float: left;
117
61
  white-space: nowrap;
118
62
  cursor: pointer;
119
-
120
63
  &.disabled {
121
- // color: var(--ax-gray-color) !important;
122
- // background-color: var(--ax-gray-trans-light-color) !important;
123
64
  opacity: 0.6;
124
- cursor: not-allowed !important;
125
-
126
- i {
127
- color: var(--ax-gray-dark-color) !important;
128
- }
129
-
130
- // &:hover {
131
- // background: var(--ax-light-light-color) !important;
132
- // border-color: var(--ax-light-light-color) !important;
133
- // color: var(--ax-gray-dark-color) !important;
134
- // cursor: not-allowed !important;
135
- // }
136
65
  }
137
-
138
66
  > ul {
139
- // padding: 0.25rem 0;
140
- li{
67
+ li {
141
68
  border-top: none;
142
69
  border-right: none;
143
70
  border-left: none;
144
71
  }
145
72
  }
146
-
147
73
  &:hover {
148
74
  > ul {
149
- left: 0;
75
+ inset-inline-start: 0;
150
76
  opacity: 1;
151
77
  z-index: 1000;
152
78
  }
153
79
  }
80
+ &.tooltip {
81
+ position: relative;
82
+ &:hover {
83
+ &::before {
84
+ display: block;
85
+ }
86
+ }
87
+ &::before {
88
+ content: attr(data-text);
89
+ font-size: 0.875rem;
90
+ position: absolute;
91
+ bottom: -85%;
92
+ inset-inline-start: 0;
93
+ padding: 0.5rem 1rem;
94
+ border-radius: var(--ax-size-border-radius);
95
+ background: var(--ax-dark-color);
96
+ color: var(--ax-dark-fore-color);
97
+ text-align: center;
98
+ display: none;
99
+ z-index: 1;
100
+ }
101
+ }
154
102
  }
155
103
 
156
104
  span {
157
105
  display: flex;
158
106
  padding: 0 10px;
159
107
  font-weight: normal;
160
- font-size: 1rem;
161
108
  line-height: 40px;
162
109
  text-decoration: none;
163
110
  align-items: center;
164
-
165
- // i {
166
- // margin-inline-end: 0.5em;
167
- // }
168
-
169
111
  span {
170
112
  padding: 0 5px;
171
113
  }
@@ -185,12 +127,7 @@
185
127
  background-color: var(--ax-white-color);
186
128
  ul {
187
129
  top: 0;
188
- left: -9999px;
189
-
190
- [dir="rtl"] & {
191
- right: -9999px !important;
192
- left: initial !important;
193
- }
130
+ inset-inline-start: -9999px;
194
131
  }
195
132
 
196
133
  li {
@@ -199,22 +136,7 @@
199
136
  }
200
137
  }
201
138
 
202
- > li {
203
- > .nav-active {
204
- background-color: rgba(0, 0, 0, 0.05);
205
- }
206
-
207
- :hover {
208
- > ul {
209
- left: 100%;
210
-
211
- [dir="rtl"] & {
212
- right: 100% !important;
213
- left: initial !important;
214
- }
215
- }
216
- }
217
- }
139
+
218
140
  }
219
141
  }
220
142
 
@@ -227,255 +149,5 @@
227
149
  .ax.nav-menu li li span,
228
150
  .ax.nav-menu li:hover li span {
229
151
  padding: 5px 10px;
230
- font-size: 1rem;
231
152
  line-height: normal;
232
153
  }
233
-
234
- /* 2: hover/persistence */
235
- .ax.nav-menu li:hover li span:hover,
236
- .ax.nav-menu li:hover li span:focus,
237
- .ax.nav-menu li:hover li:hover span {
238
- }
239
-
240
- /* 3 */
241
- .ax.nav-menu li:hover li:hover li span {
242
- }
243
-
244
- /* 3: hover/persistence */
245
- .ax.nav-menu li:hover li:hover li span:hover,
246
- .ax.nav-menu li:hover li:hover li span:focus,
247
- .ax.nav-menu li:hover li:hover li:hover span {
248
- }
249
-
250
- /* 4 */
251
- .ax.nav-menu li:hover li:hover li:hover li span {
252
- }
253
-
254
- /* 4: hover */
255
- .ax.nav-menu li:hover li:hover li:hover li span:hover,
256
- .ax.nav-menu li:hover li:hover li:hover li span:focus {
257
- }
258
-
259
- /* vertical */
260
- // .nav-vertical {
261
- // max-width: 220px;
262
- // }
263
-
264
- // .nav-vertical ul {
265
- // top: 0;
266
- // left: -9999px;
267
- // }
268
-
269
- // .nav-vertical li {
270
- // width: 100%;
271
- // float: none;
272
- // }
273
-
274
- // .nav-vertical li:hover>ul {
275
- // left: 100%;
276
- // }
277
- // .nav-menu li:hover>ul {
278
- // left: 0;
279
- // opacity: 1;
280
- // z-index: 1000;
281
- // }
282
-
283
- // .nav-menu ul li:hover>ul {
284
- // top: 0;
285
- // left: 100%;
286
- // }
287
-
288
- // .nav-menu li {
289
- // cursor: default;
290
- // float: left;
291
- // white-space: nowrap;
292
- // }
293
-
294
- // .nav-menu ul li {
295
- // float: none;
296
- // }
297
-
298
- /* sub width */
299
- // .nav-menu ul {
300
- // min-width: 12em;
301
- // -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.25);
302
- // box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.25);
303
- // }
304
-
305
- /* center */
306
- // .nav-center {
307
- // float: right;
308
- // right: 50%;
309
- // }
310
-
311
- // .nav-center>li {
312
- // left: 50%;
313
- // }
314
-
315
- /* root */
316
- // .nav-menu a {
317
- // padding: 0 10px;
318
- // color: #5BC0DE;
319
- // font-weight: normal;
320
- // font-size: 16px;
321
- // line-height: 40px;
322
- // text-decoration: none;
323
- // }
324
-
325
- /* root: active */
326
- // .nav-menu>li>.nav-active {
327
- // background-color: rgba(0, 0, 0, 0.05);
328
- // }
329
-
330
- /* root: hover/persistence */
331
-
332
- // .ax {
333
- // &.menu-container {
334
- // > ul {
335
- // margin: 0;
336
- // padding: 0;
337
- // list-style: none;
338
- // display: flex;
339
-
340
- // li {
341
- // position: relative;
342
- // cursor: pointer;
343
- // height: 25px;
344
-
345
- // &.disabled {
346
- // background: var(--ax-light-light-color) !important;
347
- // border-color: var(--ax-light-light-color) !important;
348
- // color: var(--ax-gray-dark-color) !important;
349
- // cursor: not-allowed;
350
- // }
351
- // .content-side{
352
- // flex: 1;
353
- // text-align: left;
354
- // [dir="rtl"] & {
355
- // text-align: right;
356
- // }
357
- // }
358
- // .sub-icon-side {
359
- // height: 100%;
360
- // display: flex;
361
- // justify-content: center;
362
- // align-items: center;
363
- // padding: 0 0.5em;
364
- // margin: 0.3em -0.5em 0em 0em;
365
- // }
366
-
367
- // i.ax-menu-item-icon {
368
- // position: absolute;
369
- // width: 2em;
370
- // height: 100%;
371
- // background: rgba(0, 0, 0, 0.14);
372
- // bottom: 0;
373
- // padding: 0px 0.5em;
374
- // display: flex;
375
- // align-items: center;
376
- // justify-content: center;
377
- // }
378
-
379
- // &.startIcon {
380
- // padding-inline-start: 2em;
381
-
382
- // i.start-icon {
383
- // left: 0;
384
-
385
- // [dir="rtl"] &{
386
- // right: 0;
387
- // left: initial !important;
388
- // }
389
- // }
390
- // }
391
-
392
- // &.endIcon {
393
- // padding-inline-end: 2em;
394
-
395
- // i.end-icon {
396
- // right: 0;
397
-
398
- // [dir="rtl"] &{
399
- // left: 0;
400
- // right: initial !important;
401
- // }
402
- // }
403
- // }
404
-
405
- // .ax-toolbar-menu-item-text {
406
- // span {
407
- // padding: 0 0.5em;
408
- // }
409
- // }
410
- // }
411
-
412
- // > li {
413
- // //padding: 0.4em 0.2em;
414
- // display: flex;
415
- // position: relative;
416
- // align-items: center;
417
- // overflow: hidden;
418
- // }
419
-
420
- // &.horizontal {
421
- // flex-direction: row;
422
- // align-items: center;
423
-
424
- // > li {
425
- // margin-inline-end: 0.6em;
426
- // -webkit-border-radius: var(--ax-size-border-radius);
427
- // -moz-border-radius: var(--ax-size-border-radius);
428
- // border-radius: var(--ax-size-border-radius);
429
- // }
430
- // }
431
-
432
- // &.vertical {
433
- // flex-direction: column;
434
- // align-items: flex-start;
435
-
436
- // > li {
437
- // margin-block-end: 0.6em;
438
- // width: 100%;
439
- // }
440
- // }
441
-
442
- // .collapsed {
443
- // display: none;
444
- // }
445
-
446
- // .sub-menu {
447
- // background-color: var(--ax-white-color);
448
- // box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
449
- // border: 1px solid -var(--ax-border-color);
450
- // min-width: 120px;
451
- // position: fixed;
452
- // list-style: none;
453
- // padding: 0;
454
- // color: var(--ax-black-color);
455
- // text-align: start;
456
- // z-index: 100;
457
-
458
- // li {
459
- // cursor: pointer;
460
- // padding-top: 0.5em;
461
- // padding-bottom: 0.5em;
462
- // display: flex;
463
- // &.divider {
464
- // border-block-end: 1px solid var(--ax-border-color);
465
- // }
466
- // &.split {
467
- // border-top: 1px solid -var(--ax-border-color);
468
- // }
469
- // }
470
- // }
471
-
472
- // .more {
473
- // padding: 0.6em 0.8em;
474
- // display: flex;
475
- // background-color: var(--ax-light-light-color);
476
- // position: relative;
477
- // align-items: center;
478
- // }
479
- // }
480
- // }
481
- // }
@@ -4,19 +4,19 @@
4
4
 
5
5
  &.vertical {
6
6
  flex-direction: column;
7
- margin-block-end: 1em;
7
+ margin-block-end: 1rem;
8
8
 
9
9
  label {
10
- margin-block-end: 1em;
10
+ margin-block-end: 1rem;
11
11
  }
12
12
  }
13
13
 
14
14
  &.horizontal {
15
15
  flex-direction: row;
16
- margin-block-end: 1em;
16
+ margin-block-end: 1rem;
17
17
 
18
18
  label {
19
- margin-inline-end: 1em;
19
+ margin-inline-end: 1rem;
20
20
  }
21
21
  }
22
22
  }
@@ -25,7 +25,7 @@
25
25
  &.radio {
26
26
  display: block;
27
27
  position: relative;
28
- padding-left: 2em;
28
+ padding-inline-start: 2em;
29
29
  line-height: 1.5em;
30
30
  cursor: pointer;
31
31
  font-size: inherit;
@@ -34,11 +34,6 @@
34
34
  -ms-user-select: none;
35
35
  user-select: none;
36
36
 
37
- [dir="rtl"] &{
38
- padding-left: 0 !important;
39
- padding-right: 2em;
40
- }
41
-
42
37
  &.disabled .checkmark {
43
38
  background: var(--ax-light-light-color) !important;
44
39
  border-color: var(--ax-light-light-color) !important;
@@ -63,7 +58,7 @@
63
58
  &.radio .checkmark {
64
59
  position: absolute;
65
60
  top: 0;
66
- left: 0;
61
+ inset-inline-start: 0;
67
62
  height: 1.5em;
68
63
  width: 1.5em;
69
64
  background-color: var(--ax-white-color);
@@ -73,11 +68,6 @@
73
68
  -webkit-border-radius: 50%;
74
69
  -moz-border-radius: 50%;
75
70
  border-radius: 50%;
76
-
77
- [dir="rtl"] &{
78
- right: 0 !important;
79
- left: inherit !important;
80
- }
81
71
  }
82
72
 
83
73
  /* On mouse-over, add a grey background color */
@@ -3,12 +3,13 @@
3
3
  margin: 0;
4
4
  display: flex;
5
5
  align-items: center;
6
+ font-size: 0.875rem;
6
7
 
7
8
  li {
8
9
  display: inline;
9
10
  padding: 0.5em;
10
11
  border-bottom: 1px solid;
11
- border-color: var(--ax-border-color);
12
+ border-color: var(--ax-gray-color);
12
13
  margin-inline-end: 0.3em;
13
14
  cursor: pointer;
14
15
  background-color: var(--ax-white-color);
package/scss/tab.scss CHANGED
@@ -7,10 +7,10 @@
7
7
  padding: 0;
8
8
  border-bottom: 1px solid var(--ax-border-color);
9
9
  li {
10
+ font-size: 0.875rem;
10
11
  margin-inline-end: 0.5em;
11
- padding: 1em;
12
- background: var(--ax-light-light-color);
13
- border-bottom: 2px solid var(--ax-primary-color);
12
+ padding: 0.5rem 1rem;
13
+ background: var(--ax-gray-color);
14
14
  cursor: pointer;
15
15
  -webkit-border-top-left-radius: var(--ax-size-border-radius);
16
16
  -webkit-border-top-right-radius: var(--ax-size-border-radius);
package/scss/toast.scss CHANGED
@@ -1,24 +1,46 @@
1
1
  @import "./variables.scss";
2
2
  .ax {
3
3
  &.toast {
4
+ font-size: 0.875rem;
5
+
4
6
  &.info {
5
7
  background-color: var(--ax-info-color);
6
8
  color: var(--ax-info-fore-color);
9
+ &:hover,
10
+ &:active,
11
+ &:focus {
12
+ background-color: var(--ax-info-color);
13
+ color: var(--ax-info-fore-color);
14
+ }
7
15
  }
8
16
 
9
17
  &.success {
10
- background-color: var(--ax-success-color);
11
- color: var(--ax-success-fore-color);
18
+ &:hover,
19
+ &:active,
20
+ &:focus {
21
+ background-color: var(--ax-success-color);
22
+ color: var(--ax-success-fore-color);
23
+ }
12
24
  }
13
25
 
14
26
  &.warning {
15
- background-color: var(--ax-warning-color);
16
- color: var(--ax-warning-fore-color);
27
+ &:hover,
28
+ &:active,
29
+ &:focus {
30
+ background-color: var(--ax-warning-color);
31
+ color: var(--ax-warning-fore-color);
32
+ }
17
33
  }
18
34
 
19
35
  &.error {
20
36
  background-color: var(--ax-danger-color);
21
37
  color: var(--ax-danger-fore-color);
38
+ &:hover,
39
+ &:active,
40
+ &:focus {
41
+ background-color: var(--ax-danger-color);
42
+ color: var(--ax-danger-fore-color);
43
+ }
22
44
  }
23
45
  }
24
- }
46
+ }
package/scss/tooltip.scss CHANGED
@@ -1,10 +1,11 @@
1
1
  .ax-tooltip {
2
2
  position: absolute;
3
+ font-size: 0.875rem;
3
4
  max-width: 150px;
4
5
  text-align: center;
5
- color: #fff;
6
+ color: var(--ax-dark-fore-color);
6
7
  padding: 0.5rem 0.7rem;
7
- background: #282a36;
8
+ background: var(--ax-dark-color);
8
9
  border-radius: var(--ax-size-border-radius);
9
10
  z-index: 20000;
10
11
  opacity: 0;
@@ -17,34 +18,34 @@
17
18
 
18
19
  &.ax-tooltip-top:after {
19
20
  top: 100%;
20
- left: 50%;
21
- margin-left: -5px;
21
+ inset-inline-start: 50%;
22
+ margin-inline-start: -5px;
22
23
  border-width: 5px;
23
- border-color: #282a36 transparent transparent transparent;
24
+ border-color: var(--ax-dark-color) transparent transparent transparent;
24
25
  }
25
26
 
26
27
  &.ax-tooltip-bottom:after {
27
28
  bottom: 100%;
28
- left: 50%;
29
- margin-left: -5px;
29
+ inset-inline-start: 50%;
30
+ margin-inline-start: -5px;
30
31
  border-width: 5px;
31
- border-color: transparent transparent #282a36 transparent;
32
+ border-color: transparent transparent var(--ax-dark-color) transparent;
32
33
  }
33
34
 
34
35
  &.ax-tooltip-left:after {
35
36
  top: 50%;
36
- left: 100%;
37
+ inset-inline-start: 100%;
37
38
  margin-top: -5px;
38
39
  border-width: 5px;
39
- border-color: transparent transparent transparent #282a36;
40
+ border-color: transparent transparent transparent var(--ax-dark-color);
40
41
  }
41
42
 
42
43
  &.ax-tooltip-right:after {
43
44
  top: 50%;
44
- right: 100%;
45
+ inset-inline-end: 100%;
45
46
  margin-top: -5px;
46
47
  border-width: 5px;
47
- border-color: transparent #282a36 transparent transparent;
48
+ border-color: transparent var(--ax-dark-color) transparent transparent;
48
49
  }
49
50
 
50
51
  &.ax-tooltip-show {