@gm-pc/react 1.8.2-alpha.0 → 1.8.6-alpha.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gm-pc/react",
3
- "version": "1.8.2-alpha.0",
3
+ "version": "1.8.6-alpha.0",
4
4
  "description": "观麦前端基础组件库",
5
5
  "author": "liyatang <liyatang@qq.com>",
6
6
  "homepage": "https://github.com/gmfe/gm-pc#readme",
@@ -24,7 +24,7 @@
24
24
  "dependencies": {
25
25
  "@gm-common/hooks": "^2.10.0",
26
26
  "@gm-common/tool": "^2.10.0",
27
- "@gm-pc/locales": "^1.8.2-alpha.0",
27
+ "@gm-pc/locales": "^1.8.6-alpha.0",
28
28
  "big.js": "^6.0.1",
29
29
  "classnames": "^2.2.5",
30
30
  "lodash": "^4.17.19",
@@ -46,5 +46,5 @@
46
46
  "react-dom": "^16.14.0",
47
47
  "react-window": "^1.8.5"
48
48
  },
49
- "gitHead": "e76d58dfbce746845287f32e3bc2e859fba52aff"
49
+ "gitHead": "4886b16c37eaf034b055a5b07e14f13fcdb0e6bc"
50
50
  }
@@ -91,7 +91,7 @@ const Nav: FC<NavProps> = ({
91
91
  ))}
92
92
  {other}
93
93
  </Flex>
94
- <div className='gm-nav-footer-iot'>
94
+ <div className={footerConfig && footerConfig.length > 0 ? 'gm-nav-footer-iot' : ''}>
95
95
  {footerConfig?.map((item) => (
96
96
  <NavItem
97
97
  key={item.link}
@@ -69,6 +69,7 @@ const NavItem: FC<NavItemProps> = ({
69
69
  >
70
70
  <span className='gm-nav-one-icon'>{iconE}</span>
71
71
  <span className='gm-nav-one-text'>{name}</span>
72
+ <i className='gm-nav-one-arrow' />
72
73
  </A>
73
74
  )}
74
75
 
@@ -1,5 +1,5 @@
1
1
  :root {
2
- --gm-nav-popup-item-color: #454545;
2
+ --gm-nav-popup-item-color: #333;
3
3
  --gm-nav-popup-item-hover-color: #0363ff;
4
4
  --gm-nav-background-color: #282c36;
5
5
  }
@@ -21,6 +21,7 @@
21
21
  }
22
22
 
23
23
  .gm-nav-content {
24
+ padding-top: 16px;
24
25
  overflow-y: auto;
25
26
 
26
27
  &::-webkit-scrollbar {
@@ -29,12 +30,6 @@
29
30
  }
30
31
  }
31
32
 
32
- .gm-nav-footer-iot {
33
- width: 100%;
34
- height: 64px;
35
- cursor: pointer;
36
- }
37
-
38
33
  .gm-nav-one {
39
34
  display: flex;
40
35
  align-items: center;
@@ -45,7 +40,7 @@
45
40
 
46
41
  .gm-nav-one-icon {
47
42
  margin-right: 10px;
48
- font-size: 18px;
43
+ font-size: 20px;
49
44
  line-height: 1;
50
45
  }
51
46
 
@@ -53,18 +48,34 @@
53
48
  font-size: 16px;
54
49
  }
55
50
 
56
- &::after {
57
- content: '';
51
+ .gm-nav-one-arrow {
58
52
  position: absolute;
59
- right: 20px;
60
- top: 21px;
61
- height: 7px;
62
- width: 7px;
63
- border: 1px solid #fff;
64
- opacity: 0.36;
65
- border-top: none;
66
- border-left: none;
67
- transform: rotate(-45deg);
53
+ top: 25px;
54
+ right: 16px;
55
+ width: 10px;
56
+ color: rgba(0, 0, 0, 0.85);
57
+ opacity: 0.45;
58
+ transform: rotate(-90deg);
59
+
60
+ &::before {
61
+ content: '';
62
+ position: absolute;
63
+ width: 6px;
64
+ height: 1.5px;
65
+ background-color: #fff;
66
+ border-radius: 2px;
67
+ transform: rotate(-45deg) translateX(2.5px);
68
+ }
69
+
70
+ &::after {
71
+ content: '';
72
+ position: absolute;
73
+ width: 6px;
74
+ height: 1.5px;
75
+ background-color: #fff;
76
+ border-radius: 2px;
77
+ transform: rotate(45deg) translateX(-2.5px);
78
+ }
68
79
  }
69
80
  }
70
81
 
@@ -87,6 +98,7 @@
87
98
  font-size: 16px;
88
99
  font-weight: 600;
89
100
  color: var(--gm-nav-popup-item-color);
101
+ letter-spacing: 0.2px;
90
102
  }
91
103
  }
92
104
 
@@ -94,6 +106,7 @@
94
106
  position: relative;
95
107
  margin-bottom: 8px;
96
108
  background: #f7f7f7;
109
+ border-radius: 2px;
97
110
 
98
111
  &.gm-nav-three-wrap-bg {
99
112
  background-color: #dae7ff;
@@ -102,17 +115,18 @@
102
115
  &.active {
103
116
  color: var(--gm-color-primary-active);
104
117
  background-color: #dae7ff;
118
+ border-radius: 2px;
105
119
  }
106
120
 
107
121
  .gm-nav-three {
108
122
  display: inline-block;
109
123
  padding: 8px;
110
- // width: 100%;
124
+ width: 100%;
111
125
  font-size: 14px;
112
- color: var(--gm-color-default);
126
+ color: #333;
113
127
  text-decoration: none;
114
128
  white-space: nowrap;
115
- border-radius: 2px;
129
+ letter-spacing: 0.2px;
116
130
 
117
131
  &:last-child {
118
132
  margin-bottom: 0;
@@ -137,7 +151,7 @@
137
151
  .gm-nav-three-create {
138
152
  position: absolute;
139
153
  top: 7px;
140
- right: 4px;
154
+ right: 8px;
141
155
  z-index: 10;
142
156
  width: 20px;
143
157
  height: 20px;
@@ -159,7 +173,7 @@
159
173
  // 三角形
160
174
  .gm-nav-one-triangle {
161
175
  position: absolute;
162
- top: 19px;
176
+ top: 21px;
163
177
  right: -1px;
164
178
  display: none;
165
179
  width: 0;
@@ -178,44 +192,55 @@
178
192
  .gm-nav-one-triangle {
179
193
  display: block;
180
194
  }
195
+
196
+ .gm-nav-one-arrow {
197
+ opacity: 1;
198
+ }
181
199
  }
182
200
 
183
201
  &.active {
202
+ display: flex;
203
+ justify-content: center;
204
+ align-items: center;
205
+ width: 136px;
206
+ text-align: center;
207
+ padding-top: 10px;
208
+ padding-bottom: 10px;
209
+
210
+ // active hack
184
211
  .gm-nav-one {
185
- position: relative;
212
+ width: 120px;
213
+ height: 34px;
186
214
  color: #fff;
187
- background: #181b23;
188
- opacity: 1;
189
215
  font-weight: 600;
216
+ background: #0363ff;
217
+ border-radius: 4px;
218
+ padding-left: 12px;
190
219
 
191
- &::before {
192
- content: '';
193
- position: absolute;
194
- left: 0;
195
- top: 0;
196
- height: 100%;
197
- width: 3px;
198
- background-color: #0363ff;
199
- }
200
-
201
- &::after {
202
- content: '';
203
- position: absolute;
204
- right: 20px;
205
- top: 22px;
206
- height: 7px;
207
- width: 7px;
208
- border: 1px solid #fff;
220
+ .gm-nav-one-arrow {
221
+ right: 8px;
222
+ top: 20px;
209
223
  opacity: 1;
210
- border-top: none;
211
- border-left: none;
212
- transform: rotate(-45deg);
213
224
  }
214
225
  }
215
226
 
216
227
  .gm-nav-one-triangle {
217
- display: block;
228
+ display: none;
218
229
  }
219
230
  }
220
231
  }
232
+
233
+ .gm-nav-footer-iot {
234
+ width: 100%;
235
+ height: 64px;
236
+ cursor: pointer;
237
+
238
+ // 兼容 footImage 下的 active 样式不变化
239
+ .gm-nav-one-box.active {
240
+ display: block;
241
+ width: 100%;
242
+ height: 100%;
243
+ padding-top: 0;
244
+ }
245
+ }
221
246
  }