@neatui/css 1.0.2

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 (226) hide show
  1. package/README.md +1 -0
  2. package/all.scss +22 -0
  3. package/anim/am-loading.scss +220 -0
  4. package/anim/am-rotate.scss +17 -0
  5. package/anim/am-view-aa.scss +91 -0
  6. package/anim/am-view-ab.scss +107 -0
  7. package/anim/am-view-ac.scss +114 -0
  8. package/anim/am-view-ad.scss +109 -0
  9. package/anim/am-view-ae.scss +109 -0
  10. package/anim/am-view-af.scss +104 -0
  11. package/anim/am-view-ag.scss +1789 -0
  12. package/anim/am-view-ah.scss +122 -0
  13. package/anim/am-view-ai.scss +116 -0
  14. package/anim/am-view-aj.scss +112 -0
  15. package/anim/am-view-ak.scss +102 -0
  16. package/anim/am-view-al.scss +98 -0
  17. package/anim/am-view-am.scss +97 -0
  18. package/anim/am-view-an.scss +109 -0
  19. package/anim/am-view-ao.scss +123 -0
  20. package/anim/am-view-ap.scss +108 -0
  21. package/anim/am-view-aq.scss +115 -0
  22. package/anim/am-view-ar.scss +113 -0
  23. package/anim/am-view-as.scss +99 -0
  24. package/anim/am-view-at.scss +103 -0
  25. package/anim/mcui@anim.scss +22 -0
  26. package/anim/package.json +16 -0
  27. package/badge/badge@theme=aa.scss +36 -0
  28. package/badge/package.json +22 -0
  29. package/btns/README.md +79 -0
  30. package/btns/base.scss +152 -0
  31. package/btns/btns@a.scss +469 -0
  32. package/btns/btns@b.scss +187 -0
  33. package/btns/btns@c.scss +169 -0
  34. package/btns/mcui@btns.scss +3 -0
  35. package/btns/package.json +16 -0
  36. package/card/card@a.scss +238 -0
  37. package/card/card@b.scss +75 -0
  38. package/card/mcui@card.scss +2 -0
  39. package/card/package.json +15 -0
  40. package/chat/chat@a.scss +139 -0
  41. package/chat/mcui@chat.scss +1 -0
  42. package/chat/package.json +11 -0
  43. package/cite/cite@a.scss +33 -0
  44. package/cite/package.json +11 -0
  45. package/core/README.md +142 -0
  46. package/core/base.scss +544 -0
  47. package/core/border.scss +307 -0
  48. package/core/color.scss +245 -0
  49. package/core/cols.scss +148 -0
  50. package/core/cover.scss +94 -0
  51. package/core/flex.scss +616 -0
  52. package/core/line.scss +4 -0
  53. package/core/margin.scss +0 -0
  54. package/core/mcui@core.scss +36 -0
  55. package/core/mcui@mobile.scss +37 -0
  56. package/core/media.scss +268 -0
  57. package/core/package.json +16 -0
  58. package/core/padding.scss +0 -0
  59. package/core/pos.scss +252 -0
  60. package/core/reset.scss +165 -0
  61. package/core/scale.scss +24 -0
  62. package/core/scroll.scss +178 -0
  63. package/core/shadow.scss +81 -0
  64. package/core/size.mobile.scss +105 -0
  65. package/core/size.scss +178 -0
  66. package/core/theme.scss +156 -0
  67. package/core/trim.mobile.scss +327 -0
  68. package/core/trim.scss +443 -0
  69. package/core/ux.scss +334 -0
  70. package/demo/demo@a.scss +34 -0
  71. package/demo/mcui@demo.scss +1 -0
  72. package/form/README.md +142 -0
  73. package/form/base.scss +425 -0
  74. package/form/form@a/base.scss +33 -0
  75. package/form/form@a/checkbox.scss +194 -0
  76. package/form/form@a/date.scss +86 -0
  77. package/form/form@a/index.scss +9 -0
  78. package/form/form@a/input.scss +156 -0
  79. package/form/form@a/radio.scss +99 -0
  80. package/form/form@a/select.scss +128 -0
  81. package/form/form@a/switch.scss +83 -0
  82. package/form/form@a/textarea.scss +105 -0
  83. package/form/form@a/upload.scss +162 -0
  84. package/form/form@b/base.scss +33 -0
  85. package/form/form@b/checkbox.scss +86 -0
  86. package/form/form@b/date.scss +107 -0
  87. package/form/form@b/index.scss +9 -0
  88. package/form/form@b/input.scss +163 -0
  89. package/form/form@b/radio.scss +90 -0
  90. package/form/form@b/select.scss +124 -0
  91. package/form/form@b/switch.scss +83 -0
  92. package/form/form@b/textarea.scss +105 -0
  93. package/form/form@b/upload.scss +160 -0
  94. package/form/form@c/base.scss +44 -0
  95. package/form/form@c/checkbox.scss +90 -0
  96. package/form/form@c/date.scss +125 -0
  97. package/form/form@c/index.scss +9 -0
  98. package/form/form@c/input.scss +169 -0
  99. package/form/form@c/radio.scss +84 -0
  100. package/form/form@c/select.scss +121 -0
  101. package/form/form@c/switch.scss +83 -0
  102. package/form/form@c/textarea.scss +85 -0
  103. package/form/form@c/upload.scss +159 -0
  104. package/form/form@d/base.scss +45 -0
  105. package/form/form@d/checkbox.scss +87 -0
  106. package/form/form@d/date.scss +125 -0
  107. package/form/form@d/index.scss +9 -0
  108. package/form/form@d/input.scss +346 -0
  109. package/form/form@d/radio.scss +81 -0
  110. package/form/form@d/select.scss +121 -0
  111. package/form/form@d/switch.scss +83 -0
  112. package/form/form@d/textarea.scss +104 -0
  113. package/form/form@d/upload.scss +160 -0
  114. package/form/mcui@form.scss +4 -0
  115. package/form/package.json +22 -0
  116. package/form/radio@theme=aa.scss +74 -0
  117. package/grid/grid@a.scss +54 -0
  118. package/grid/mcui@grid.scss +1 -0
  119. package/grid/package.json +16 -0
  120. package/icon/icon@add.scss +9 -0
  121. package/icon/icon@close.scss +12 -0
  122. package/icon/icon@down.scss +9 -0
  123. package/icon/icon@download.scss +26 -0
  124. package/icon/icon@drag.scss +9 -0
  125. package/icon/icon@except.scss +9 -0
  126. package/icon/icon@hook.scss +16 -0
  127. package/icon/icon@left.scss +9 -0
  128. package/icon/icon@link.scss +14 -0
  129. package/icon/icon@menu.scss +10 -0
  130. package/icon/icon@minus.scss +7 -0
  131. package/icon/icon@more.scss +8 -0
  132. package/icon/icon@omit.scss +8 -0
  133. package/icon/icon@quit.scss +11 -0
  134. package/icon/icon@refresh.scss +11 -0
  135. package/icon/icon@right.scss +9 -0
  136. package/icon/icon@search.scss +9 -0
  137. package/icon/icon@time.scss +12 -0
  138. package/icon/icon@top.scss +9 -0
  139. package/icon/icon@upload.scss +26 -0
  140. package/icon/icon@view.scss +20 -0
  141. package/icon/mcui@icon.scss +21 -0
  142. package/icon/package.json +15 -0
  143. package/imgs/README.md +78 -0
  144. package/imgs/base.scss +8 -0
  145. package/imgs/imgs@a.scss +171 -0
  146. package/imgs/imgs@b.scss +173 -0
  147. package/imgs/mcui@imgs.scss +1 -0
  148. package/imgs/package.json +16 -0
  149. package/index.js +28 -0
  150. package/line/line@a.scss +51 -0
  151. package/line/line@b.scss +63 -0
  152. package/line/mcui@line.scss +2 -0
  153. package/line/package.json +16 -0
  154. package/list/list@a.scss +62 -0
  155. package/list/list@b.scss +83 -0
  156. package/list/list@c.scss +89 -0
  157. package/list/mcui@list.scss +2 -0
  158. package/list/package.json +16 -0
  159. package/load/README.md +69 -0
  160. package/load/load@a.scss +44 -0
  161. package/load/load@b.scss +56 -0
  162. package/load/load@c.scss +270 -0
  163. package/load/load@d.scss +26 -0
  164. package/load/load@e.scss +24 -0
  165. package/load/load@f.scss +124 -0
  166. package/load/load@g.scss +35 -0
  167. package/load/load@h.scss +51 -0
  168. package/load/load@i.scss +51 -0
  169. package/load/mcui@load.scss +8 -0
  170. package/load/package.json +16 -0
  171. package/menu/mcui@menu.scss +1 -0
  172. package/menu/menu@b.scss +302 -0
  173. package/menu/menu@theme=ab.scss +282 -0
  174. package/menu/package.json +22 -0
  175. package/navs/README.md +30 -0
  176. package/navs/mcui@navs.scss +2 -0
  177. package/navs/navs@a.scss +113 -0
  178. package/navs/navs@b.scss +111 -0
  179. package/navs/package.json +16 -0
  180. package/note/mcui@note.scss +2 -0
  181. package/note/note@a.scss +26 -0
  182. package/note/note@b.scss +33 -0
  183. package/note/package.json +11 -0
  184. package/opts/mcui@opts.scss +1 -0
  185. package/opts/opts@a.scss +52 -0
  186. package/opts/package.json +11 -0
  187. package/package.json +26 -0
  188. package/paging/mc-paging-ui1503.scss +106 -0
  189. package/paging/mc-paging.scss +432 -0
  190. package/paging/paging@theme=aa.scss +45 -0
  191. package/path/README.md +142 -0
  192. package/path/mcui@path.scss +1 -0
  193. package/path/package.json +22 -0
  194. package/path/path@a.scss +38 -0
  195. package/side/mcui@side.scss +0 -0
  196. package/side/side.scss +2 -0
  197. package/steps/mcui@steps.scss +2 -0
  198. package/steps/package.json +17 -0
  199. package/steps/steps@a.scss +89 -0
  200. package/steps/steps@v.scss +122 -0
  201. package/table/base.scss +140 -0
  202. package/table/mcui@table.scss +3 -0
  203. package/table/package.json +22 -0
  204. package/table/table@a.scss +230 -0
  205. package/table/table@b.scss +78 -0
  206. package/table/table@c.scss +18 -0
  207. package/tabs/README.md +62 -0
  208. package/tabs/mcui@tabs.scss +1 -0
  209. package/tabs/package.json +22 -0
  210. package/tabs/tabs@a.scss +62 -0
  211. package/tags/README.md +71 -0
  212. package/tags/mcui@tags.scss +2 -0
  213. package/tags/package.json +22 -0
  214. package/tags/tags@a.scss +125 -0
  215. package/tags/tags@b.scss +131 -0
  216. package/tips/README.md +62 -0
  217. package/tips/base.scss +351 -0
  218. package/tips/mcui@tips.scss +1 -0
  219. package/tips/package.json +22 -0
  220. package/tips/tips@a.scss +52 -0
  221. package/title/mcui@title.scss +2 -0
  222. package/title/package.json +15 -0
  223. package/title/title@a.scss +18 -0
  224. package/title/title@b.scss +7 -0
  225. package/user/mcui@user.scss +0 -0
  226. package/user/user@a.scss +7 -0
@@ -0,0 +1,282 @@
1
+ // 平板
2
+ //@media screen and (min-width: 768px) and (max-width: 1024px) {}
3
+
4
+ // 桌面
5
+ // @media screen and (min-width: 769px) {
6
+ .mc-menu {
7
+ position: relative;
8
+ display: inline-block;
9
+
10
+ // 切换状态
11
+ .mc-menu-switch {
12
+ display: none;
13
+ }
14
+
15
+ // 导航列表
16
+ .mc-menu-list {
17
+ & > label {
18
+ display: none;
19
+ }
20
+
21
+ & > * {
22
+ position: relative;
23
+ display: inline-block;
24
+
25
+ & > * {
26
+ display: inline-block;
27
+ cursor: pointer;
28
+ position: relative;
29
+
30
+ & > a {
31
+ padding: 0 1em;
32
+ }
33
+
34
+ &:hover,
35
+ & .active {
36
+ & > a {
37
+ color: #d52932;
38
+ }
39
+
40
+ .mc-menu-list-two {
41
+ text-align: left;
42
+ opacity: 1;
43
+ transform: translate3d(-50%, 0.5rem, 0);
44
+ pointer-events: auto;
45
+ transition: all 0.5s;
46
+ }
47
+ }
48
+ }
49
+ }
50
+
51
+ .mc-menu-list-two {
52
+ position: absolute;
53
+ min-width: 10rem;
54
+ left: 50%;
55
+ padding: 2rem;
56
+ background: #fff;
57
+ line-height: 3rem;
58
+ transform: translate3d(-50%, 1rem, 0);
59
+ opacity: 0;
60
+ pointer-events: none;
61
+ border-radius: 0.1rem;
62
+ transition: all 0.2s;
63
+
64
+ & > * {
65
+ white-space: nowrap;
66
+
67
+ &:hover {
68
+ color: #d52932;
69
+ }
70
+ }
71
+
72
+ &:before {
73
+ position: absolute;
74
+ content: "";
75
+ display: block;
76
+ border: 0.5rem solid transparent;
77
+ border-bottom-color: #fff;
78
+ width: 1rem;
79
+ height: 1rem;
80
+ left: 50%;
81
+ top: -1rem;
82
+ margin-left: -0.5rem;
83
+ }
84
+
85
+ &:after {
86
+ position: absolute;
87
+ content: "";
88
+ width: 100%;
89
+ height: 1rem;
90
+ top: -1rem;
91
+ left: 0;
92
+ }
93
+ }
94
+
95
+ // 搜索框
96
+ & > .head-search {
97
+ display: none;
98
+ position: absolute;
99
+ width: 100%;
100
+ height: 100%;
101
+ padding: 0;
102
+ left: 0;
103
+ top: 0;
104
+ background: #fff;
105
+
106
+ & > input {
107
+ width: 8rem;
108
+ height: 2.5rem;
109
+ background: #f8f8f8;
110
+ border-radius: 2.5rem;
111
+ }
112
+ }
113
+ }
114
+
115
+ // 导航按钮
116
+ .mc-menu-icon {
117
+ display: none;
118
+ }
119
+ }
120
+ // }
121
+
122
+ // 移动
123
+ @media screen and (max-width: 768px) {
124
+ .mc-menu {
125
+ position: static;
126
+ display: inline-block;
127
+
128
+ // 切换状态
129
+ .mc-menu-switch {
130
+ display: none;
131
+
132
+ // 开启状态
133
+ &:checked + .mc-menu-icon {
134
+ &:after {
135
+ border-radius: 30%;
136
+ background: linear-gradient(45deg, transparent 45%, #454545 45%, #454545 55%, transparent 55%), linear-gradient(-45deg, transparent 45%, #454545 45%, #454545 55%, transparent 55%);
137
+ }
138
+
139
+ & + .mc-menu-list {
140
+ transition: transform 0.35s;
141
+ transform: translate3d(-100%, 0, 1px);
142
+ pointer-events: auto;
143
+
144
+ & > * {
145
+ opacity: 1;
146
+ transform: translate3d(0, 0, 1px);
147
+ }
148
+ }
149
+ }
150
+ }
151
+
152
+ // 导航主体
153
+ .mc-menu-list {
154
+ position: fixed;
155
+ display: block;
156
+ width: 100%;
157
+ left: 100%;
158
+ top: 5rem;
159
+ bottom: 0;
160
+ z-index: 10;
161
+ text-align: center;
162
+ //height: 100%;
163
+ line-height: 3.5rem;
164
+ pointer-events: none;
165
+ transition: transform 0.2s;
166
+ transform: translate3d(0, 0, 1px);
167
+ //background: rgba(0, 0, 0, .85);
168
+ background: #fff;
169
+ padding: 1rem 3rem;
170
+ //color: #fff;
171
+ overflow-x: hidden;
172
+ overflow-y: auto;
173
+ -webkit-overflow-scrolling: touch;
174
+ border-top: 1px solid #dfdfdf;
175
+
176
+ // 开关按钮
177
+ //& > label {
178
+ // width: 100%;
179
+ // height: 100%;
180
+ // position: absolute;
181
+ // top: 0;
182
+ // right: 16rem;
183
+ // z-index: 12;
184
+ //
185
+ // &:after {
186
+ // position: absolute;
187
+ // right: -15rem;
188
+ // top: 1rem;
189
+ // border-radius: 30%;
190
+ // background: linear-gradient(45deg, transparent 45%, #fff 45%, #fff 55%, transparent 55%), linear-gradient(-45deg, transparent 45%, #fff 45%, #fff 55%, transparent 55%);
191
+ // transform: scale3d(1, 1, 1);
192
+ // transition: all .1s;
193
+ // }
194
+ //
195
+ // &:active {
196
+ // &:after {
197
+ // transform: scale3d(.75, .75, 1);
198
+ // }
199
+ // }
200
+ //}
201
+
202
+ // 搜索框
203
+ & > .head-search {
204
+ padding-top: 3rem;
205
+ border-top: 1px solid #dfdfdf;
206
+
207
+ .head-search-list {
208
+ padding: 1em 0;
209
+
210
+ & > * {
211
+ border-bottom: 1px dotted #dfdfdf;
212
+ }
213
+ }
214
+
215
+ input {
216
+ width: 100%;
217
+ height: 3rem;
218
+ border-radius: 3px;
219
+ background: #f8f8f8;
220
+ padding: 1em;
221
+ }
222
+ }
223
+
224
+ // 导航列表
225
+ & > * {
226
+ position: relative;
227
+ width: 100%;
228
+ z-index: 11;
229
+ margin-bottom: 2rem;
230
+
231
+ & > * {
232
+ display: block;
233
+ text-align: left;
234
+ border-bottom: 1px dotted rgba(255, 255, 255, 0.3);
235
+ }
236
+ }
237
+ }
238
+
239
+ // 开关按钮
240
+ .mc-menu-icon {
241
+ position: relative;
242
+ //height: 100%;
243
+ display: inline-block;
244
+ padding: 0.25rem;
245
+ //top: 1px;
246
+ z-index: 11;
247
+ width: 1.5rem;
248
+ height: 1.5rem;
249
+ border: 1px solid #252525;
250
+ border-radius: 0.25rem;
251
+ vertical-align: middle;
252
+ top: -0.1rem;
253
+ right: 0.3em;
254
+
255
+ &:before {
256
+ content: "";
257
+ display: block;
258
+ width: 300%;
259
+ height: 300%;
260
+ position: absolute;
261
+ left: -100%;
262
+ top: -100%;
263
+ }
264
+
265
+ &:after {
266
+ width: 100%;
267
+ height: 100%;
268
+ content: "";
269
+ display: block;
270
+ background: linear-gradient(0deg, transparent 42%, #454545 0%, #454545 57%, transparent 0%), linear-gradient(90deg, transparent 75%, #fff 76%), linear-gradient(0deg, transparent 10%, #454545 0%, #454545 25%, transparent 0%), linear-gradient(0deg, transparent 75%, #454545 0%, #454545 90%, transparent 0%);
271
+ transform: scale3d(1, 1, 1);
272
+ transition: all 0.1s;
273
+ }
274
+
275
+ &:active & .active {
276
+ &:after {
277
+ transform: scale3d(0.75, 0.75, 1);
278
+ }
279
+ }
280
+ }
281
+ }
282
+ }
@@ -0,0 +1,22 @@
1
+ {
2
+ "name": "@neatui/menu",
3
+ "version": "1.0.6",
4
+ "description": "",
5
+ "main": "menu@b.scss",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1"
8
+ },
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "git+https://gitlab.com/mcui/mcui.desktop.git"
12
+ },
13
+ "keywords": [
14
+ "mcui"
15
+ ],
16
+ "author": "xiaojunbo",
17
+ "license": "MIT",
18
+ "bugs": {
19
+ "url": "https://gitlab.com/mcui/mcui.desktop/issues"
20
+ },
21
+ "homepage": "https://gitlab.com/mcui/mcui.desktop#readme"
22
+ }
package/navs/README.md ADDED
@@ -0,0 +1,30 @@
1
+ # @neatui/navs
2
+
3
+ MCUI导航组件,基于MCUI核心@neatui/core, 官网 https://mcui.fekit.cn/
4
+
5
+ ## 安装组件
6
+
7
+ ```
8
+ npm i @neatui/navs
9
+ ```
10
+
11
+ 或
12
+
13
+ ```
14
+ yarn add @neatui/navs
15
+ ```
16
+
17
+ ## 可选主题
18
+
19
+ - navs@a.scss
20
+ - navs@b.scss
21
+
22
+ ## 使用示例
23
+
24
+ ```html
25
+ <ul ui-navs="@a">
26
+ <li class="active"><span>导航一</span></li>
27
+ <li><span>导航二</span></li>
28
+ <li><span>导航三</span></li>
29
+ </ul>
30
+ ```
@@ -0,0 +1,2 @@
1
+ @import './navs@a.scss';
2
+ @import './navs@b.scss';
@@ -0,0 +1,113 @@
1
+ [ui-navs~='@a'] {
2
+ position: relative;
3
+ & > * {
4
+ position: relative;
5
+ display: inline-block;
6
+ cursor: pointer;
7
+ user-select: none;
8
+
9
+ &:hover {
10
+ & > *:first-child {
11
+ text-decoration: underline;
12
+ opacity: 0.8;
13
+ }
14
+ }
15
+ &:active {
16
+ & > *:first-child {
17
+ display: inline-block;
18
+ transform: scale3d(0.95, 0.9, 1);
19
+ }
20
+ }
21
+ }
22
+
23
+ // 主题
24
+ &,
25
+ &[ui-navs~='text'] {
26
+ & > * {
27
+ @include theme {
28
+ color: co(text);
29
+ }
30
+ &.active {
31
+ & > *:first-child {
32
+ @include theme {
33
+ color: co(main);
34
+ }
35
+ }
36
+ }
37
+ }
38
+ }
39
+
40
+ &[ui-navs~='read'] {
41
+ & > * {
42
+ @include theme {
43
+ color: co(read);
44
+ }
45
+ &.active {
46
+ & > *:first-child {
47
+ @include theme {
48
+ color: mix(co(main), co(read), 45%);
49
+ }
50
+ }
51
+ }
52
+ }
53
+ }
54
+
55
+ &[ui-navs~='note'] {
56
+ & > * {
57
+ @include theme {
58
+ color: co(note);
59
+ }
60
+ &.active {
61
+ & > *:first-child {
62
+ @include theme {
63
+ // color: co(main);
64
+ color: mix(co(main), co(back), 45%);
65
+ }
66
+ }
67
+ }
68
+ }
69
+ }
70
+
71
+ &[ui-navs~='back'] {
72
+ & > * {
73
+ @include theme {
74
+ color: rgba(co(back), 0.9);
75
+ }
76
+ &.active {
77
+ & > *:first-child {
78
+ @include theme {
79
+ color: co(back);
80
+ }
81
+ }
82
+ }
83
+ }
84
+ }
85
+
86
+ // 对齐
87
+ & {
88
+ &,
89
+ &[ui-navs~='al'] {
90
+ text-align: left;
91
+ & > * {
92
+ margin-left: 0;
93
+ margin-right: 2em;
94
+ }
95
+ }
96
+
97
+ &[ui-navs~='ac'] {
98
+ text-align: center;
99
+ & > * {
100
+ margin-left: 1em;
101
+ margin-right: 1em;
102
+ }
103
+ }
104
+
105
+ &[ui-navs~='ar'] {
106
+ text-align: right;
107
+ & > * {
108
+ margin-left: 2em;
109
+ margin-right: 0;
110
+ }
111
+ }
112
+ }
113
+ }
@@ -0,0 +1,111 @@
1
+ [ui-navs~='@b'] {
2
+ position: relative;
3
+ & > * {
4
+ position: relative;
5
+ display: inline-block;
6
+ cursor: pointer;
7
+ user-select: none;
8
+
9
+ &:hover {
10
+ & > * {
11
+ @include theme {
12
+ text-decoration: underline;
13
+ opacity: 0.8;
14
+ }
15
+ }
16
+ }
17
+ &:active {
18
+ & > * {
19
+ display: inline-block;
20
+ transform: scale3d(0.95, 0.9, 1);
21
+ }
22
+ }
23
+
24
+ &:not(:last-child):after {
25
+ display: inline-block;
26
+ content: '|';
27
+ margin-left: 1.2em;
28
+ margin-right: 1em;
29
+ opacity: 0.3;
30
+ }
31
+ }
32
+
33
+ // 主题
34
+ &,
35
+ &[ui-navs~='text'] {
36
+ & > * {
37
+ @include theme {
38
+ color: co(text);
39
+ }
40
+ &.active {
41
+ & > *:first-child {
42
+ @include theme {
43
+ color: co(main);
44
+ }
45
+ }
46
+ }
47
+ }
48
+ }
49
+
50
+ &[ui-navs~='read'] {
51
+ & > * {
52
+ @include theme {
53
+ color: co(read);
54
+ }
55
+ &.active {
56
+ & > *:first-child {
57
+ @include theme {
58
+ color: mix(co(main), co(read), 45%);
59
+ }
60
+ }
61
+ }
62
+ }
63
+ }
64
+
65
+ &[ui-navs~='note'] {
66
+ & > * {
67
+ @include theme {
68
+ color: co(note);
69
+ }
70
+ &.active {
71
+ & > *:first-child {
72
+ @include theme {
73
+ // color: co(main);
74
+ color: mix(co(main), co(back), 45%);
75
+ }
76
+ }
77
+ }
78
+ }
79
+ }
80
+
81
+ &[ui-navs~='back'] {
82
+ & > * {
83
+ @include theme {
84
+ color: rgba(co(back), 0.7);
85
+ }
86
+ &.active {
87
+ & > *:first-child {
88
+ @include theme {
89
+ color: co(back);
90
+ }
91
+ }
92
+ }
93
+ }
94
+ }
95
+
96
+ // 对齐
97
+ & {
98
+ &,
99
+ &[ui-navs~='al'] {
100
+ text-align: left;
101
+ }
102
+
103
+ &[ui-navs~='ac'] {
104
+ text-align: center;
105
+ }
106
+
107
+ &[ui-navs~='ar'] {
108
+ text-align: right;
109
+ }
110
+ }
111
+ }
@@ -0,0 +1,16 @@
1
+ {
2
+ "name": "@neatui/navs",
3
+ "version": "1.0.2",
4
+ "description": "",
5
+ "main": "mcui@navs.scss",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1"
8
+ },
9
+ "author": "xiaojunbo",
10
+ "license": "MIT",
11
+ "dependencies": {},
12
+ "keywords": [
13
+ "mcui",
14
+ "ui"
15
+ ]
16
+ }
@@ -0,0 +1,2 @@
1
+ @import './note@a.scss';
2
+ @import './note@b.scss';
@@ -0,0 +1,26 @@
1
+ $cos: 'main', 'well', 'warn', 'risk', 'info';
2
+ [ui-note~='@a'] {
3
+ // 基础
4
+ & {
5
+ width: 100%;
6
+ padding: 0.5em 1em;
7
+ border-radius: 0.25rem;
8
+
9
+ @include theme {
10
+ color: co(read);
11
+ box-shadow: inset 0 0 0 1px co(line);
12
+ background: co(weak);
13
+ }
14
+ }
15
+
16
+ // 颜色
17
+ @each $key in $cos {
18
+ &[ui-note~='#{$key}'] {
19
+ @include theme {
20
+ color: mix(co($key), co(text), 85%);
21
+ box-shadow: inset 0 0 0 1px rgba(co($key), 0.3);
22
+ background: saturate(rgba(co($key), 0.06), 20%);
23
+ }
24
+ }
25
+ }
26
+ }
@@ -0,0 +1,33 @@
1
+ $co: 'main', 'text', 'read', 'well', 'warn', 'risk', 'info';
2
+
3
+ [ui-note~='@b'] {
4
+ width: 100%;
5
+ padding: 0.5em 1em;
6
+ border-radius: 0.1em;
7
+
8
+ @mixin note($co, $bg, $bk) {
9
+ color: $co;
10
+ border-left: 0.15em solid $bk;
11
+ background: $bg;
12
+ }
13
+
14
+ @each $key in $co {
15
+ @include theme {
16
+ $val: co($key);
17
+ $co: mix($val, co(text), 85%);
18
+ $bg: saturate(rgba($val, 0.1), 20%);
19
+ $bk: $val;
20
+
21
+ @if ($key== 'main') {
22
+ &,
23
+ &[ui-note~='#{$key}'] {
24
+ @include note($co, $bg, $bk);
25
+ }
26
+ } @else {
27
+ &[ui-note~='#{$key}'] {
28
+ @include note($co, $bg, $bk);
29
+ }
30
+ }
31
+ }
32
+ }
33
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "name": "@neatui/note",
3
+ "version": "1.0.6",
4
+ "description": "",
5
+ "main": "note@theme=aa.scss",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1"
8
+ },
9
+ "author": "xiaojunbo",
10
+ "license": "MIT"
11
+ }
@@ -0,0 +1 @@
1
+ @import './opts@a.scss';
@@ -0,0 +1,52 @@
1
+ [ui-opts~='@a'] {
2
+ & {
3
+ position: relative;
4
+ padding: 0.5em;
5
+ border-radius: 0.25em;
6
+ cursor: pointer;
7
+ @include theme {
8
+ box-shadow: inset 0 0 0 1px co(case);
9
+ }
10
+
11
+ &.active {
12
+ @include theme {
13
+ box-shadow: inset 0 0 0 1px co(main);
14
+ }
15
+
16
+ &::after {
17
+ position: absolute;
18
+ display: block;
19
+ content: '';
20
+ width: 0.6rem;
21
+ height: 0.6rem;
22
+ max-width: 1rem;
23
+ max-height: 1rem;
24
+ top: 0.2em;
25
+ right: 0.2em;
26
+ border-radius: 0.15rem;
27
+ background-image: radial-gradient(circle at 26% 56%, currentColor 8%, transparent 9%), radial-gradient(circle at 32% 62%, currentColor 8%, transparent 9%),
28
+ radial-gradient(circle at 35% 65%, currentColor 8%, transparent 9%), radial-gradient(circle at 41% 71%, currentColor 8%, transparent 9%),
29
+ radial-gradient(circle at 47% 70%, currentColor 9%, transparent 10%), radial-gradient(circle at 53% 62%, currentColor 9%, transparent 10%),
30
+ radial-gradient(circle at 59% 54%, currentColor 9%, transparent 10%), radial-gradient(circle at 65% 46%, currentColor 9%, transparent 10%),
31
+ radial-gradient(circle at 71% 38%, currentColor 8%, transparent 9%);
32
+ @include theme {
33
+ background-color: co(main);
34
+ color: co(fore);
35
+ }
36
+ -webkit-animation: am-selected 0.2s 0.1s both;
37
+ animation: am-selected 0.2s 0.1s both;
38
+ }
39
+ }
40
+ }
41
+
42
+ & > * {
43
+ transform: scale(1);
44
+ transition: all 0.3s;
45
+ }
46
+
47
+ &:hover {
48
+ & > * {
49
+ transform: scale(0.9);
50
+ }
51
+ }
52
+ }