@neatui/css 1.0.21 → 1.0.22

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.
@@ -1 +1,3 @@
1
1
  @import './tabs@a.scss';
2
+ @import './tabs@b.scss';
3
+ @import './tabs@c.scss';
@@ -18,14 +18,14 @@ $sz: 'xs', 's', 'm', 'l', 'xl';
18
18
  position: relative;
19
19
  display: inline-block;
20
20
  cursor: pointer;
21
- margin-left: 1rem;
22
- margin-right: 1rem;
21
+ margin-left: 1em;
22
+ margin-right: 1em;
23
23
 
24
24
  &:first-child {
25
- margin-left: 0;
25
+ margin-left: 0 !important;
26
26
  }
27
27
  &:last-child {
28
- margin-right: 0;
28
+ margin-right: 0 !important;
29
29
  }
30
30
 
31
31
  &.active {
@@ -50,12 +50,17 @@ $sz: 'xs', 's', 'm', 'l', 'xl';
50
50
  }
51
51
 
52
52
  // 尺寸
53
- $base: 2em;
53
+ $base: 1.5em;
54
54
  @each $i in $sz {
55
55
  // @debug $i;
56
56
  &[ui-tabs~='#{$i}'] {
57
57
  height: $base;
58
58
  line-height: $base;
59
+
60
+ & > * {
61
+ margin-left: $base * 0.5 - 0.5em;
62
+ margin-right: $base * 0.5 - 0.5em;
63
+ }
59
64
  }
60
65
  $base: $base + 0.5;
61
66
  }
@@ -0,0 +1,65 @@
1
+ $co: 'main', 'well', 'warn', 'risk', 'info';
2
+ $sz: 'xs', 's', 'm', 'l', 'xl';
3
+
4
+ [ui-tabs~='@b'] {
5
+ position: relative;
6
+ display: inline-flex;
7
+ max-width: 100%;
8
+ height: 2.5em;
9
+ white-space: nowrap;
10
+ overflow-x: auto;
11
+ overflow-y: hidden;
12
+ padding: 3px;
13
+ border-radius: 0.5em;
14
+
15
+ @include theme {
16
+ border: 1px solid co(line);
17
+ }
18
+
19
+ & > * {
20
+ cursor: pointer;
21
+ display: flex;
22
+ align-items: center;
23
+ justify-content: center;
24
+ border-radius: 0.25em;
25
+ padding: 0.5em 1em;
26
+ &.active {
27
+ @include theme {
28
+ color: co(fore);
29
+ background: co(main);
30
+ }
31
+ }
32
+ }
33
+
34
+ // 对齐
35
+ &,
36
+ &[ui-tabs~='al'] {
37
+ text-align: left;
38
+ }
39
+ &[ui-tabs~='ac'] {
40
+ text-align: center;
41
+ }
42
+ &[ui-tabs~='ar'] {
43
+ text-align: right;
44
+ }
45
+
46
+ // 尺寸
47
+ $base: 1.5em;
48
+ @each $i in $sz {
49
+ &[ui-tabs~='#{$i}'] {
50
+ height: $base;
51
+
52
+ & > * {
53
+ padding: 0.5em $base - 1.25em;
54
+ }
55
+ }
56
+ $base: $base + 0.5;
57
+ }
58
+
59
+ &[ui-tabs~=':round'] {
60
+ border-radius: 100em;
61
+ & > * {
62
+ border-radius: 100em;
63
+ }
64
+ }
65
+ }
@@ -0,0 +1,65 @@
1
+ $co: 'main', 'well', 'warn', 'risk', 'info';
2
+ $sz: 'xs', 's', 'm', 'l', 'xl';
3
+
4
+ [ui-tabs~='@c'] {
5
+ position: relative;
6
+ display: inline-flex;
7
+ max-width: 100%;
8
+ height: 2.5em;
9
+ white-space: nowrap;
10
+ overflow-x: auto;
11
+ overflow-y: hidden;
12
+ padding: 3px;
13
+ border-radius: 0.5em;
14
+
15
+ @include theme {
16
+ background: co(weak);
17
+ }
18
+
19
+ & > * {
20
+ cursor: pointer;
21
+ display: flex;
22
+ align-items: center;
23
+ justify-content: center;
24
+ border-radius: 0.25em;
25
+ padding: 0.5em 1em;
26
+ &.active {
27
+ @include theme {
28
+ color: co(main);
29
+ background: co(fore);
30
+ }
31
+ }
32
+ }
33
+
34
+ // 对齐
35
+ &,
36
+ &[ui-tabs~='al'] {
37
+ text-align: left;
38
+ }
39
+ &[ui-tabs~='ac'] {
40
+ text-align: center;
41
+ }
42
+ &[ui-tabs~='ar'] {
43
+ text-align: right;
44
+ }
45
+
46
+ // 尺寸
47
+ $base: 1.5em;
48
+ @each $i in $sz {
49
+ &[ui-tabs~='#{$i}'] {
50
+ height: $base;
51
+
52
+ & > * {
53
+ padding: 0.5em $base - 1.25em;
54
+ }
55
+ }
56
+ $base: $base + 0.5;
57
+ }
58
+
59
+ &[ui-tabs~=':round'] {
60
+ border-radius: 100em;
61
+ & > * {
62
+ border-radius: 100em;
63
+ }
64
+ }
65
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@neatui/css",
3
- "version": "1.0.21",
3
+ "version": "1.0.22",
4
4
  "description": "neatui",
5
5
  "main": "./neatui.scss",
6
6
  "license": "MIT",