@kizmann/nano-ui 0.8.37 → 0.9.1
Sign up to get free protection for your applications and to get access to all the features.
- package/bun.lockb +0 -0
- package/demos/overview.html +5 -15
- package/demos/select.html +164 -0
- package/dist/nano-ui.css +1 -1
- package/dist/nano-ui.js +2 -2
- package/dist/nano-ui.js.map +1 -1
- package/dist/themes/light.css +1 -1
- package/docs/README.md +1 -2
- package/docs/_sidebar.md +19 -21
- package/docs/dist/docs.css +2 -0
- package/docs/{data → files/data}/table.md +40 -14
- package/docs/files/form/button.md +122 -0
- package/docs/{form → files/form}/form.md +14 -0
- package/docs/files/form/input.md +90 -0
- package/docs/files/form/switch.md +92 -0
- package/docs/index.html +163 -44
- package/docs/src/scss/docsify/basic/_layout.sass +3 -6
- package/docs/src/scss/docsify/syntax.scss +139 -0
- package/docs/src/scss/docsify/vue.sass +2 -15
- package/docs/src/scss/index.scss +428 -16
- package/package.json +1 -1
- package/src/button/src/button/button.js +1 -9
- package/src/mixins/src/ctor.js +0 -6
- package/src/popover/src/popover/popover.scss +4 -0
- package/src/radio/src/radio-group/radio-group.js +1 -1
- package/src/root/vars.scss +10 -10
- package/src/scrollbar/src/scrollbar/scrollbar.next.js +21 -1
- package/src/select/src/select/select.js +191 -78
- package/src/select/src/select/select.scss +4 -0
- package/src/select/src/select-option/select-option.js +6 -2
- package/src/table/src/table/table.scss +0 -1
- package/src/tags/src/tags-item/tags-item.js +17 -1
- package/src/virtualscroller/src/virtualscroller/virtualscroller.beta.js +12 -2
- package/themes/light/root/vars.scss +10 -10
- package/themes/light/switch/src/switch/switch.scss +1 -1
- package/themes/light/table/src/table/table.scss +1 -1
- package/themes/light/tags/src/tags-item/tags-item.scss +16 -0
- package/webpack.config.js +13 -13
- package/dist/themes/basic.css +0 -2029
- package/dist/themes/flat.css +0 -1806
- package/dist/themes/flat.dark.css +0 -1809
- package/docs/dist/index.css +0 -6977
- package/docs/form/button.md +0 -299
- package/docs/form/input.md +0 -205
- package/docs/form/switch.md +0 -166
- /package/docs/{data → files/data}/draggable.md +0 -0
- /package/docs/{data → files/data}/map.md +0 -0
- /package/docs/{data → files/data}/paginator.md +0 -0
- /package/docs/{data → files/data}/virtualscroller.md +0 -0
- /package/docs/{form → files/form}/cascader.md +0 -0
- /package/docs/{form → files/form}/checkbox.md +0 -0
- /package/docs/{form → files/form}/datepicker.md +0 -0
- /package/docs/{form → files/form}/radio.md +0 -0
- /package/docs/{form → files/form}/select.md +0 -0
- /package/docs/{form → files/form}/textarea.md +0 -0
- /package/docs/{form → files/form}/timepicker.md +0 -0
- /package/docs/{form → files/form}/transfer.md +0 -0
- /package/docs/{others → files/others}/config.md +0 -0
- /package/docs/{others → files/others}/confirm.md +0 -0
- /package/docs/{others → files/others}/loader.md +0 -0
- /package/docs/{others → files/others}/modal.md +0 -0
- /package/docs/{others → files/others}/notification.md +0 -0
- /package/docs/{others → files/others}/popover.md +0 -0
- /package/docs/{others → files/others}/resizer.md +0 -0
- /package/docs/{others → files/others}/scrollbar.md +0 -0
- /package/docs/{others → files/others}/tabs.md +0 -0
package/docs/src/scss/index.scss
CHANGED
@@ -4,33 +4,445 @@
|
|
4
4
|
@import "./mixins/media";
|
5
5
|
@import "./mixins/grid";
|
6
6
|
@import "./mixins/space";
|
7
|
+
@import "./docsify/syntax";
|
8
|
+
|
9
|
+
::selection {
|
10
|
+
background: rgba($color-primary, 0.15);
|
11
|
+
}
|
7
12
|
|
8
13
|
* {
|
9
|
-
outline: none;
|
14
|
+
outline: none !important;
|
15
|
+
}
|
16
|
+
|
17
|
+
div {
|
18
|
+
box-sizing: border-box;
|
10
19
|
}
|
11
20
|
|
12
21
|
html, body {
|
13
|
-
|
14
|
-
|
22
|
+
font-family: 'Roboto', sans-serif;
|
23
|
+
font-size: 15px;
|
15
24
|
font-variant-numeric: normal;
|
16
25
|
font-feature-settings: normal;
|
17
26
|
}
|
18
27
|
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
28
|
+
body {
|
29
|
+
background: #fff linear-gradient(110deg, rgba($color-info, 0.05) 0%, rgba($color-primary, 0.05) 100%);
|
30
|
+
}
|
31
|
+
|
32
|
+
body:before {
|
33
|
+
z-index: 9000;
|
34
|
+
content: '\00a0';
|
35
|
+
position: fixed;
|
36
|
+
top: 0;
|
37
|
+
left: 0;
|
38
|
+
width: 100%;
|
39
|
+
height: 100%;
|
40
|
+
background: #fff linear-gradient(110deg, $color-info 0%, $color-primary 100%);
|
41
|
+
transition: opacity 0.2s 0.4s, transform 0.4s 0.2s;
|
42
|
+
}
|
43
|
+
|
44
|
+
body.ready:before {
|
45
|
+
opacity: 0;
|
46
|
+
transform: translateY(-100vh);
|
47
|
+
}
|
48
|
+
|
49
|
+
body.ready header {
|
50
|
+
opacity: 1;
|
51
|
+
}
|
52
|
+
|
53
|
+
h1 {
|
54
|
+
font-size: 32px;
|
55
|
+
}
|
56
|
+
|
57
|
+
h2 {
|
58
|
+
font-size: 26px;
|
59
|
+
}
|
60
|
+
|
61
|
+
h3 {
|
62
|
+
font-weight: 500;
|
63
|
+
font-size: 16px;
|
64
|
+
}
|
65
|
+
|
66
|
+
p {
|
67
|
+
font-size: 15px;
|
68
|
+
}
|
69
|
+
|
70
|
+
code {
|
71
|
+
font-size: 13.5px;
|
72
|
+
}
|
73
|
+
|
74
|
+
h1, h2, h3, h4, h5, h6 {
|
75
|
+
color: $color-primary;
|
76
|
+
}
|
77
|
+
|
78
|
+
h1 a {
|
79
|
+
transition: color 0.2s;
|
80
|
+
}
|
81
|
+
|
82
|
+
h1 a, h1 a:active, h1 a:visited,
|
83
|
+
h2 a, h2 a:active, h2 a:visited {
|
84
|
+
color: $color-gray-90;
|
85
|
+
}
|
86
|
+
|
87
|
+
h1 a:hover, h2 a:hover {
|
88
|
+
color: $color-primary;
|
89
|
+
}
|
90
|
+
|
91
|
+
h1 a, h2 a {
|
92
|
+
display: inline-flex;
|
93
|
+
align-items: center;
|
94
|
+
}
|
95
|
+
|
96
|
+
h1 a:before, h2 a:before {
|
97
|
+
content: '#';
|
98
|
+
color: $color-primary;
|
99
|
+
margin-right: 15px;
|
100
|
+
font-size: 18px;
|
101
|
+
}
|
102
|
+
|
103
|
+
h1 a:before {
|
104
|
+
font-size: 18px;
|
105
|
+
}
|
106
|
+
|
107
|
+
h2 a:before {
|
108
|
+
font-size: 16px;
|
109
|
+
}
|
110
|
+
|
111
|
+
p {
|
112
|
+
color: $color-gray-65;
|
113
|
+
}
|
114
|
+
|
115
|
+
code {
|
116
|
+
font-family: 'Roboto Mono', Monaco, courier, monospace;
|
117
|
+
color: mix($color-gray-75, $color-primary, 25%);
|
118
|
+
background: mix($color-background, $color-primary, 95%);
|
119
|
+
}
|
120
|
+
|
121
|
+
a, a:active, a:visited {
|
122
|
+
color: $color-primary;
|
123
|
+
text-decoration: none;
|
124
|
+
}
|
125
|
+
|
126
|
+
a:hover {
|
127
|
+
color: $color-primary-dark;
|
128
|
+
}
|
129
|
+
|
130
|
+
table {
|
131
|
+
width: 100%;
|
132
|
+
background: $color-white;
|
133
|
+
border-radius: $lg-radius;
|
134
|
+
border-collapse: collapse;
|
135
|
+
box-shadow: 0 1px 14px rgba($color-shadow, 0.075);
|
136
|
+
}
|
137
|
+
|
138
|
+
table th,
|
139
|
+
table td {
|
140
|
+
min-width: 180px;
|
141
|
+
text-align: left;
|
142
|
+
}
|
143
|
+
|
144
|
+
table thead tr th {
|
145
|
+
padding: 19px 24px;
|
146
|
+
color: $color-gray-90;
|
147
|
+
font-size: 13px;
|
148
|
+
}
|
149
|
+
|
150
|
+
table thead tr th b,
|
151
|
+
table thead tr th strong {
|
152
|
+
font-weight: 500;
|
153
|
+
}
|
154
|
+
|
155
|
+
table thead tr:first-child th:first-child {
|
156
|
+
border-radius: $lg-radius 0 0 0;
|
157
|
+
}
|
158
|
+
|
159
|
+
table thead tr:first-child th:last-child {
|
160
|
+
border-radius: 0 $lg-radius 0 0;
|
161
|
+
}
|
162
|
+
|
163
|
+
table thead tr:last-child th {
|
164
|
+
border-bottom: 1px solid $color-gray-10;
|
165
|
+
}
|
166
|
+
|
167
|
+
table thead tr th:not(:last-child) {
|
168
|
+
border-right: 1px solid $color-gray-10;
|
169
|
+
}
|
170
|
+
|
171
|
+
table tbody tr td {
|
172
|
+
padding: 14px 24px;
|
173
|
+
color: $color-gray-65;
|
174
|
+
font-size: 15px;
|
175
|
+
}
|
176
|
+
|
177
|
+
table tbody tr td code {
|
178
|
+
//color: mix($color-gray-75, $color-info, 25%);
|
179
|
+
}
|
180
|
+
|
181
|
+
table tbody tr td:nth-child(1) code {
|
182
|
+
font-weight: 700;
|
183
|
+
color: mix($color-gray-90, $color-success, 10%);
|
184
|
+
background: mix($color-background, $color-success, 95%);
|
185
|
+
}
|
186
|
+
|
187
|
+
table tbody tr:not(:last-child) td {
|
188
|
+
border-bottom: 1px solid $color-gray-05;
|
189
|
+
}
|
190
|
+
|
191
|
+
header {
|
192
|
+
overflow: hidden;
|
193
|
+
position: relative;
|
194
|
+
width: 100%;
|
195
|
+
border-bottom: 1px solid rgba($color-black, 0.07);
|
196
|
+
}
|
197
|
+
|
198
|
+
header .wrapper {
|
199
|
+
z-index: 100;
|
200
|
+
position: relative;
|
201
|
+
display: flex;
|
202
|
+
flex-direction: row;
|
203
|
+
align-items: center;
|
204
|
+
width: 100%;
|
205
|
+
height: 140px;
|
206
|
+
max-width: 1490px;
|
207
|
+
margin: 0 auto;
|
208
|
+
padding: 0 40px;
|
209
|
+
}
|
210
|
+
|
211
|
+
header .logo {
|
212
|
+
text-align: center;
|
213
|
+
margin-right: auto;
|
214
|
+
}
|
215
|
+
|
216
|
+
header .logo a {
|
217
|
+
display: inline-block;
|
218
|
+
max-width: 130px;
|
219
|
+
}
|
220
|
+
|
221
|
+
header .logo img {
|
222
|
+
display: block;
|
223
|
+
width: 100%;
|
224
|
+
max-height: 100%;
|
225
|
+
}
|
226
|
+
|
227
|
+
header .social:not(:last-child) {
|
228
|
+
margin-right: 30px;
|
229
|
+
}
|
230
|
+
|
231
|
+
header .social a {
|
232
|
+
display: inline-flex;
|
233
|
+
align-items: center;
|
234
|
+
padding: 10px 14px;
|
235
|
+
font-size: 13px;
|
236
|
+
border-radius: 500px;
|
237
|
+
color: $color-gray-70;
|
238
|
+
//background: rgba($color-gray-50, 0.1);
|
239
|
+
}
|
240
|
+
|
241
|
+
header .social.black a {
|
242
|
+
color: rgba($color-white, 0.9);
|
243
|
+
background: $color-black;
|
244
|
+
}
|
245
|
+
|
246
|
+
header .social.blue a {
|
247
|
+
color: rgba($color-white, 0.9);
|
248
|
+
background: $color-primary;
|
249
|
+
}
|
250
|
+
|
251
|
+
header .social a i {
|
252
|
+
opacity: 0.8;
|
253
|
+
margin-right: 12px;
|
254
|
+
}
|
255
|
+
|
256
|
+
main {
|
257
|
+
z-index: 200;
|
258
|
+
position: relative;
|
259
|
+
overflow-x: hidden;
|
260
|
+
display: flex;
|
261
|
+
flex-direction: row;
|
262
|
+
justify-content: center;
|
263
|
+
padding: 35px 0;
|
264
|
+
}
|
265
|
+
|
266
|
+
.sidebar {
|
267
|
+
flex: 0 0 auto;
|
268
|
+
display: none;
|
269
|
+
flex-direction: column;
|
270
|
+
width: 320px;
|
271
|
+
padding: 10px 35px 10px 35px;
|
272
|
+
margin-right: 50px;
|
273
|
+
border-right: 1px solid rgba($color-black, 0.07);
|
274
|
+
|
275
|
+
@include media('lg') {
|
276
|
+
display: flex;
|
277
|
+
}
|
278
|
+
}
|
279
|
+
|
280
|
+
.content {
|
281
|
+
flex: 1 1 auto;
|
282
|
+
width: 100%;
|
283
|
+
max-width: 1120px;
|
284
|
+
padding: 10px 30px;
|
285
|
+
}
|
286
|
+
|
287
|
+
.app-name {
|
288
|
+
display: none;
|
289
|
+
order: 100;
|
290
|
+
width: 100%;
|
291
|
+
padding: 5px 0 20px;
|
292
|
+
text-align: center;
|
293
|
+
}
|
294
|
+
|
295
|
+
.app-name > a {
|
296
|
+
display: inline-block;
|
297
|
+
max-width: 120px;
|
298
|
+
}
|
299
|
+
|
300
|
+
.app-name > a > img {
|
301
|
+
width: 100%;
|
302
|
+
}
|
303
|
+
|
304
|
+
.search {
|
305
|
+
position: relative;
|
306
|
+
order: 200;
|
307
|
+
border: none !important;
|
308
|
+
padding: 8px 4px 12px 12px !important;
|
309
|
+
}
|
310
|
+
|
311
|
+
.search .input-wrap {
|
312
|
+
border-radius: 500px;
|
313
|
+
background: rgba($color-black, 0.05);
|
314
|
+
}
|
315
|
+
|
316
|
+
.search .input-wrap input {
|
317
|
+
height: 44px;
|
318
|
+
line-height: 44px;
|
319
|
+
padding: 0 0 0 24px;
|
320
|
+
}
|
321
|
+
|
322
|
+
.search .input-wrap input,
|
323
|
+
.search .input-wrap input:focus {
|
324
|
+
appearance: none;
|
325
|
+
background: transparent;
|
326
|
+
border: none;
|
327
|
+
box-shadow: none;
|
328
|
+
}
|
329
|
+
|
330
|
+
.results-panel {
|
331
|
+
position: absolute;
|
332
|
+
top: 100%;
|
333
|
+
left: 0;
|
334
|
+
}
|
335
|
+
|
336
|
+
.matching-post > p,
|
337
|
+
.matching-post > a > p {
|
338
|
+
//display: none !important;
|
339
|
+
}
|
340
|
+
|
341
|
+
.sidebar-nav {
|
342
|
+
order: 300;
|
343
|
+
}
|
344
|
+
|
345
|
+
.sidebar-nav p {
|
346
|
+
padding: 4px 12px;
|
347
|
+
font-size: 11px;
|
348
|
+
font-weight: 600;
|
349
|
+
color: $color-gray-80;
|
350
|
+
text-transform: uppercase;
|
351
|
+
}
|
352
|
+
|
353
|
+
.sidebar-nav ul ul {
|
354
|
+
padding: 4px 0 4px 14px;
|
355
|
+
}
|
356
|
+
|
357
|
+
.sidebar-nav a {
|
358
|
+
transition: color 0.2s, background 0.2s;
|
359
|
+
}
|
360
|
+
|
361
|
+
.sidebar-nav a, .sidebar-nav a:active, .sidebar-nav a:visited {
|
362
|
+
display: inline-block;
|
363
|
+
font-size: 14px;
|
364
|
+
color: $color-gray-55;
|
365
|
+
padding: 4px 12px;
|
366
|
+
border-radius: $md-radius;
|
367
|
+
}
|
368
|
+
|
369
|
+
.sidebar-nav ul ul ul > li > a:before {
|
370
|
+
content: '-';
|
371
|
+
color: $color-gray-20;
|
372
|
+
margin-right: 8px;
|
373
|
+
}
|
374
|
+
|
375
|
+
.sidebar-nav a:hover {
|
376
|
+
color: $color-gray-75;
|
377
|
+
}
|
378
|
+
|
379
|
+
.sidebar-nav li > a:has(+ .app-sub-sidebar),
|
380
|
+
.sidebar-nav li > a:active:has(+ .app-sub-sidebar),
|
381
|
+
.sidebar-nav li > a:visited:has(+ .app-sub-sidebar) {
|
382
|
+
color: $color-primary;
|
383
|
+
background: rgba($color-primary, 0.1);
|
384
|
+
}
|
385
|
+
|
386
|
+
.sidebar-nav ul ul ul li.active > a,
|
387
|
+
.sidebar-nav ul ul ul li.active > a:active,
|
388
|
+
.sidebar-nav ul ul ul li.active > a:visited {
|
389
|
+
color: $color-gray-90;
|
390
|
+
}
|
391
|
+
|
392
|
+
.markdown-section h1,
|
393
|
+
.markdown-section h2,
|
394
|
+
.markdown-section h3,
|
395
|
+
.markdown-section h4,
|
396
|
+
.markdown-section h5,
|
397
|
+
.markdown-section h6,
|
398
|
+
.markdown-section p {
|
399
|
+
margin-bottom: 30px;
|
400
|
+
}
|
401
|
+
|
402
|
+
.markdown-section code {
|
403
|
+
background-color: rgba($color-primary, 0.15);
|
404
|
+
border-radius: $md-radius;
|
405
|
+
font-size: 0.8rem;
|
406
|
+
margin: 0 2px;
|
407
|
+
padding: 3px 5px;
|
408
|
+
white-space: pre-wrap;
|
409
|
+
}
|
410
|
+
|
411
|
+
.markdown-section code[data-type] {
|
412
|
+
color: mix($color-gray-90, $color-gray-40, 10%);
|
413
|
+
background: mix($color-background, $color-gray-40, 95%);
|
414
|
+
}
|
415
|
+
|
416
|
+
.markdown-section table {
|
417
|
+
margin-bottom: 30px;
|
418
|
+
}
|
419
|
+
|
420
|
+
.demo-wrapper {
|
421
|
+
overflow: hidden;
|
422
|
+
position: relative;
|
423
|
+
margin-bottom: 30px;
|
424
|
+
border-radius: $lg-radius;
|
425
|
+
background: $color-white;
|
426
|
+
box-shadow: 0 1px 14px rgba($color-shadow, 0.075);
|
427
|
+
}
|
428
|
+
|
429
|
+
.markdown-section .demo-options {
|
430
|
+
padding: 20px 40px 24px;
|
431
|
+
border-bottom: 1px solid $color-gray-10;
|
432
|
+
}
|
433
|
+
|
434
|
+
.markdown-section .demo-options .n-form-item {
|
435
|
+
margin-bottom: 4px;
|
436
|
+
}
|
437
|
+
|
438
|
+
.markdown-section .demo-options .n-select {
|
439
|
+
//width: 220px;
|
24
440
|
}
|
25
441
|
|
26
|
-
.
|
27
|
-
|
28
|
-
height: 80px;
|
29
|
-
margin: 0 auto 20px auto;
|
442
|
+
.markdown-section .demo-display {
|
443
|
+
padding: 40px;
|
30
444
|
}
|
31
445
|
|
32
|
-
.demo-
|
33
|
-
|
34
|
-
border-radius: $radius-medium;
|
35
|
-
box-shadow: 0 1px 3px rgba($color-black, 0.05);
|
446
|
+
.markdown-section .demo-display > .grid:not(:last-child) {
|
447
|
+
margin-bottom: 20px;
|
36
448
|
}
|
package/package.json
CHANGED
@@ -62,14 +62,6 @@ export default {
|
|
62
62
|
type: [String]
|
63
63
|
},
|
64
64
|
|
65
|
-
buttonType: {
|
66
|
-
default()
|
67
|
-
{
|
68
|
-
return 'button';
|
69
|
-
},
|
70
|
-
type: [String]
|
71
|
-
},
|
72
|
-
|
73
65
|
nativeType: {
|
74
66
|
default()
|
75
67
|
{
|
@@ -135,7 +127,7 @@ export default {
|
|
135
127
|
}
|
136
128
|
|
137
129
|
if ( this.$slots.default && ! this.square ) {
|
138
|
-
innerHtml.push(<span>{ this.$slots.default() }</span>);
|
130
|
+
innerHtml.push(<span>{ this.$slots.default && this.$slots.default() }</span>);
|
139
131
|
}
|
140
132
|
|
141
133
|
if ( this.iconPosition === 'after' ) {
|
package/src/mixins/src/ctor.js
CHANGED
@@ -6,12 +6,6 @@ export default {
|
|
6
6
|
{
|
7
7
|
let ctor = Obj.get(this.$options, key.split('.'), -1);
|
8
8
|
|
9
|
-
|
10
|
-
|
11
|
-
//console.log(this.$options, ctor);
|
12
|
-
|
13
|
-
// console.log(ctor);
|
14
|
-
|
15
9
|
// if ( ctor === -1 ) {
|
16
10
|
// ctor = Obj.get(this.$vnode.componentOptions.Ctor,
|
17
11
|
// Arr.merge(['options'], key.split('.')), -1);
|
package/src/root/vars.scss
CHANGED
@@ -21,15 +21,15 @@ $color-gray-85: mix($color-black, $color-white, 0.85 * 100%) !default;
|
|
21
21
|
$color-gray-90: mix($color-black, $color-white, 0.90 * 100%) !default;
|
22
22
|
$color-gray-95: mix($color-black, $color-white, 0.95 * 100%) !default;
|
23
23
|
|
24
|
-
$color-
|
25
|
-
$color-
|
24
|
+
$color-secondary: #ca62f0 !default;
|
25
|
+
$color-primary: #6875ee !default;
|
26
26
|
|
27
|
-
$color-success: #
|
28
|
-
$color-warning: #
|
29
|
-
$color-danger: #
|
30
|
-
$color-info: #
|
27
|
+
$color-success: #06C493 !default;
|
28
|
+
$color-warning: #FFBF3F !default;
|
29
|
+
$color-danger: #F9536E !default;
|
30
|
+
$color-info: #4BD6F9 !default;
|
31
31
|
|
32
|
-
$color-background: #
|
32
|
+
$color-background: #FAFAFB !default;
|
33
33
|
|
34
34
|
$color-shadow: mix($color-black, $color-primary, 80%) !default;
|
35
35
|
|
@@ -95,8 +95,8 @@ $color-background-darker: darken(mix($color-black, $color-background, 20%), 5%
|
|
95
95
|
|
96
96
|
$xs-radius: 2px !default;
|
97
97
|
$sm-radius: 2px !default;
|
98
|
-
$md-radius:
|
99
|
-
$lg-radius:
|
98
|
+
$md-radius: 4px !default;
|
99
|
+
$lg-radius: 6px !default;
|
100
100
|
$xl-radius: 10px !default;
|
101
101
|
|
102
102
|
$form: (
|
@@ -114,7 +114,7 @@ $form: (
|
|
114
114
|
),
|
115
115
|
'md': (
|
116
116
|
'size': 32px,
|
117
|
-
'font':
|
117
|
+
'font': 15px,
|
118
118
|
'radius': $md-radius,
|
119
119
|
'ratio': 0.40,
|
120
120
|
),
|
@@ -277,10 +277,20 @@ export default {
|
|
277
277
|
let innerHeight = this.$refs.content
|
278
278
|
.scrollHeight || 0;
|
279
279
|
|
280
|
+
let virtualHeight = 0;
|
281
|
+
|
282
|
+
Dom.find(this.$refs.content).childs().each((el) => {
|
283
|
+
virtualHeight += Dom.find(el).height() || 0;
|
284
|
+
});
|
285
|
+
|
280
286
|
if ( this.native && ! this.allowNative ) {
|
281
287
|
innerHeight -= 16;
|
282
288
|
}
|
283
289
|
|
290
|
+
if ( virtualHeight > innerHeight ) {
|
291
|
+
innerHeight = virtualHeight;
|
292
|
+
}
|
293
|
+
|
284
294
|
// if ( offsetHeight === 0 && this.overflowX ) {
|
285
295
|
// innerHeight -= 15;
|
286
296
|
// }
|
@@ -363,10 +373,20 @@ export default {
|
|
363
373
|
let innerWidth = this.$refs.content
|
364
374
|
.scrollWidth || 0;
|
365
375
|
|
376
|
+
let virtualWidth = 0;
|
377
|
+
|
378
|
+
Dom.find(this.$refs.content).childs().each((el) => {
|
379
|
+
virtualWidth += Dom.find(el).width() || 0;
|
380
|
+
});
|
381
|
+
|
366
382
|
if ( this.native && ! this.allowNative ) {
|
367
383
|
innerWidth -= 16;
|
368
384
|
}
|
369
385
|
|
386
|
+
if ( virtualWidth > innerWidth ) {
|
387
|
+
innerWidth = virtualWidth;
|
388
|
+
}
|
389
|
+
|
370
390
|
// if ( offsetWidth === 0 && this.overflowY ) {
|
371
391
|
// innerWidth -= 15;
|
372
392
|
// }
|
@@ -437,7 +457,7 @@ export default {
|
|
437
457
|
scroll.left = this.$refs.content.scrollLeft;
|
438
458
|
}
|
439
459
|
|
440
|
-
let vbarTop= Math.ceil((this.outerHeight / this.innerHeight) *
|
460
|
+
let vbarTop = Math.ceil((this.outerHeight / this.innerHeight) *
|
441
461
|
scroll.top * this.heightRatio) || 0;
|
442
462
|
|
443
463
|
if ( ! this.vbarTop || vbarTop !== this.vbarTop ) {
|