snail.vue 2.0.17 → 2.0.19
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/dist/snail.vue.d.ts +36 -83
- package/dist/snail.vue.js +204 -206
- package/dist/snail.vue.umd.js +202 -204
- package/dist/styles/snail.vue.vue.css +26 -26
- package/package.json +2 -2
package/dist/snail.vue.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as snail_core from 'snail.core';
|
|
2
2
|
import { DateFormat, DateValue, TimeValue, IScope, RunResult, IAsyncScope } from 'snail.core';
|
|
3
3
|
import * as snail_view from 'snail.view';
|
|
4
|
-
import { BaseStyle, HeightStyle, FlexBoxStyle, WidthStyle, BorderStyle, PaddingStyle, MarginStyle } from 'snail.view';
|
|
4
|
+
import { ScrollbarOptions, BaseStyle, HeightStyle, FlexBoxStyle, WidthStyle, BorderStyle, PaddingStyle, MarginStyle } from 'snail.view';
|
|
5
5
|
import * as vue from 'vue';
|
|
6
6
|
import { Component, ShallowRef, Ref, WatchSource, App } from 'vue';
|
|
7
7
|
|
|
@@ -380,28 +380,7 @@ type FooterEvents = {
|
|
|
380
380
|
/**
|
|
381
381
|
* 滚动视图配置选项
|
|
382
382
|
*/
|
|
383
|
-
type ScrollOptions = {
|
|
384
|
-
/**
|
|
385
|
-
* x轴是否支持滚动
|
|
386
|
-
* - false(默认值)不支持
|
|
387
|
-
* - true 支持滚动
|
|
388
|
-
*/
|
|
389
|
-
scrollX?: boolean;
|
|
390
|
-
/**
|
|
391
|
-
* y轴是否支持滚动
|
|
392
|
-
* - false(默认值)不支持
|
|
393
|
-
* - true 支持滚动
|
|
394
|
-
*/
|
|
395
|
-
scrollY?: boolean;
|
|
396
|
-
/**
|
|
397
|
-
* 滚动条尺寸
|
|
398
|
-
* - normal :常规,10px
|
|
399
|
-
* - small :小尺寸,宽度 6px
|
|
400
|
-
* - mini :迷你尺寸,宽度 4px
|
|
401
|
-
* - none :无,不显示滚动条,但仍然能够滚动
|
|
402
|
-
*/
|
|
403
|
-
barSize?: "normal" | "small" | "mini" | "none";
|
|
404
|
-
};
|
|
383
|
+
type ScrollOptions = ScrollbarOptions & {};
|
|
405
384
|
/**
|
|
406
385
|
* 滚动视图事件
|
|
407
386
|
*/
|
|
@@ -784,7 +763,7 @@ type TreeNodeSlotOptions<Node> = {
|
|
|
784
763
|
/**
|
|
785
764
|
* Table配置选项
|
|
786
765
|
*/
|
|
787
|
-
type TableOptions = ScrollOptions & {
|
|
766
|
+
type TableOptions = Pick<ScrollOptions, "scroll" | "barSize"> & {
|
|
788
767
|
/**
|
|
789
768
|
* 是否启用表格边框
|
|
790
769
|
*/
|
|
@@ -1241,11 +1220,11 @@ type FlexOptions = {
|
|
|
1241
1220
|
* - - start(默认值) 主轴起点对齐
|
|
1242
1221
|
* - - end 主轴终点对齐
|
|
1243
1222
|
* - - center 主轴居中对齐
|
|
1244
|
-
* - -
|
|
1245
|
-
* - -
|
|
1246
|
-
* - -
|
|
1223
|
+
* - - between 主轴两端对齐,项目之间间隔平均分布
|
|
1224
|
+
* - - around 主轴每个项目两侧间隔平均分布
|
|
1225
|
+
* - - evenly 主轴每个项目之间间隔平均分布
|
|
1247
1226
|
*/
|
|
1248
|
-
|
|
1227
|
+
main?: "start" | "end" | "center" | "between" | "around" | "evenly";
|
|
1249
1228
|
/**
|
|
1250
1229
|
* 交叉轴对齐方式
|
|
1251
1230
|
* - css属性:align-items
|
|
@@ -1256,7 +1235,7 @@ type FlexOptions = {
|
|
|
1256
1235
|
* - - center 交叉轴居中对齐
|
|
1257
1236
|
* - - baseline 交叉轴第一行文字基线对齐
|
|
1258
1237
|
*/
|
|
1259
|
-
|
|
1238
|
+
cross?: "start" | "end" | "center" | "stretch" | "baseline";
|
|
1260
1239
|
/**
|
|
1261
1240
|
* 多行时的交叉轴对齐方式
|
|
1262
1241
|
* - css属性:align-content
|
|
@@ -1265,11 +1244,11 @@ type FlexOptions = {
|
|
|
1265
1244
|
* - - start 交叉轴起点对齐
|
|
1266
1245
|
* - - end 交叉轴终点对齐
|
|
1267
1246
|
* - - center 交叉轴居中对齐
|
|
1268
|
-
* - -
|
|
1269
|
-
* - -
|
|
1270
|
-
* - -
|
|
1247
|
+
* - - between 交叉轴两端对齐,行之间间隔平均分布
|
|
1248
|
+
* - - around 交叉轴每行两侧间隔平均分布
|
|
1249
|
+
* - - evenly 交叉轴每行之间间隔平均分布
|
|
1271
1250
|
*/
|
|
1272
|
-
|
|
1251
|
+
content?: "start" | "end" | "center" | "stretch" | "between" | "around" | "evenly";
|
|
1273
1252
|
/**
|
|
1274
1253
|
* 启用子项修复
|
|
1275
1254
|
* - 在`justify-content`启用`space-`相关属性时,子项之间会有间隔,当子项数量较少时,可能出现空间过大的问题,特别时多行的最后一样时
|
|
@@ -1302,14 +1281,7 @@ type FlexOptions = {
|
|
|
1302
1281
|
/**
|
|
1303
1282
|
* 弹性容器组件 配置选项
|
|
1304
1283
|
*/
|
|
1305
|
-
type ElasticOptions = {
|
|
1306
|
-
/**
|
|
1307
|
-
* 支持滚动的方向
|
|
1308
|
-
* - x :支持水平方向滚动,内容超出时出横向滚动条
|
|
1309
|
-
* - y :支持垂直方向滚动,内容超出时出纵向滚动条
|
|
1310
|
-
* - both :支持水平和垂直方向滚动,内容超出时出横向纵向滚动条
|
|
1311
|
-
*/
|
|
1312
|
-
scroll: "x" | "y" | "both";
|
|
1284
|
+
type ElasticOptions = ScrollOptions & {
|
|
1313
1285
|
/**
|
|
1314
1286
|
* 滚动条弹簧效果
|
|
1315
1287
|
* - x 仅在x轴方向上启用弹簧效果
|
|
@@ -1329,45 +1301,11 @@ type ElasticOptions = {
|
|
|
1329
1301
|
* - 满足上拉加载条件后,触发`more`事件,处理完成后调用resolve函数,通知完成加载数据操作
|
|
1330
1302
|
*/
|
|
1331
1303
|
upMore?: boolean;
|
|
1332
|
-
/**
|
|
1333
|
-
* 滚动条尺寸
|
|
1334
|
-
* - normal :常规,10px
|
|
1335
|
-
* - small :小尺寸,宽度 6px
|
|
1336
|
-
* - mini :迷你尺寸,宽度 4px
|
|
1337
|
-
* - none :无,不显示滚动条,但仍然能够滚动
|
|
1338
|
-
*/
|
|
1339
|
-
barSize?: "normal" | "small" | "mini" | "none";
|
|
1340
1304
|
};
|
|
1341
1305
|
/**
|
|
1342
1306
|
* 弹性容器组件 事件监听
|
|
1343
1307
|
*/
|
|
1344
1308
|
type ElasticEvents = {
|
|
1345
|
-
/**
|
|
1346
|
-
* 【x轴方向】滚动条变化时
|
|
1347
|
-
* @param show 是否显示。true 滚动条显示;false 滚动条隐藏
|
|
1348
|
-
*/
|
|
1349
|
-
xbar: [show: boolean];
|
|
1350
|
-
/**
|
|
1351
|
-
* 【y轴方向】滚动条变化时
|
|
1352
|
-
* @param show 是否显示。true 滚动条显示;false 滚动条隐藏
|
|
1353
|
-
*/
|
|
1354
|
-
ybar: [show: boolean];
|
|
1355
|
-
/**
|
|
1356
|
-
* 【y轴方向】滚到【最顶部】了
|
|
1357
|
-
*/
|
|
1358
|
-
top: [];
|
|
1359
|
-
/**
|
|
1360
|
-
* 【x轴方向】滚到【最右侧】了
|
|
1361
|
-
*/
|
|
1362
|
-
right: [];
|
|
1363
|
-
/**
|
|
1364
|
-
* 【y轴方向】滚到【最底部】了
|
|
1365
|
-
*/
|
|
1366
|
-
bottom: [];
|
|
1367
|
-
/**
|
|
1368
|
-
* 【x轴方向】滚到【最左侧】了
|
|
1369
|
-
*/
|
|
1370
|
-
left: [];
|
|
1371
1309
|
/**
|
|
1372
1310
|
* 刷新数据
|
|
1373
1311
|
* - 配合 `downRefresh`实现下拉刷新功能
|
|
@@ -3060,18 +2998,33 @@ declare const components: {
|
|
|
3060
2998
|
};
|
|
3061
2999
|
});
|
|
3062
3000
|
Elastic: {
|
|
3063
|
-
new (...args: any[]): vue.CreateComponentPublicInstanceWithMixins<Readonly<ElasticOptions> & Readonly<{
|
|
3001
|
+
new (...args: any[]): vue.CreateComponentPublicInstanceWithMixins<Readonly<ElasticOptions> & Readonly<{
|
|
3002
|
+
onRefresh?: (resolve: () => void) => any;
|
|
3003
|
+
onMore?: (resolve: () => void) => any;
|
|
3004
|
+
}>, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
3005
|
+
refresh: (resolve: () => void) => any;
|
|
3006
|
+
more: (resolve: () => void) => any;
|
|
3007
|
+
}, vue.PublicProps, {}, false, {}, {}, vue.GlobalComponents, vue.GlobalDirectives, string, {}, any, vue.ComponentProvideOptions, {
|
|
3064
3008
|
P: {};
|
|
3065
3009
|
B: {};
|
|
3066
3010
|
D: {};
|
|
3067
3011
|
C: {};
|
|
3068
3012
|
M: {};
|
|
3069
3013
|
Defaults: {};
|
|
3070
|
-
}, Readonly<ElasticOptions> & Readonly<{
|
|
3014
|
+
}, Readonly<ElasticOptions> & Readonly<{
|
|
3015
|
+
onRefresh?: (resolve: () => void) => any;
|
|
3016
|
+
onMore?: (resolve: () => void) => any;
|
|
3017
|
+
}>, {}, {}, {}, {}, {}>;
|
|
3071
3018
|
__isFragment?: never;
|
|
3072
3019
|
__isTeleport?: never;
|
|
3073
3020
|
__isSuspense?: never;
|
|
3074
|
-
} & vue.ComponentOptionsBase<Readonly<ElasticOptions> & Readonly<{
|
|
3021
|
+
} & vue.ComponentOptionsBase<Readonly<ElasticOptions> & Readonly<{
|
|
3022
|
+
onRefresh?: (resolve: () => void) => any;
|
|
3023
|
+
onMore?: (resolve: () => void) => any;
|
|
3024
|
+
}>, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
3025
|
+
refresh: (resolve: () => void) => any;
|
|
3026
|
+
more: (resolve: () => void) => any;
|
|
3027
|
+
}, string, {}, {}, string, {}, vue.GlobalComponents, vue.GlobalDirectives, string, vue.ComponentProvideOptions> & vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & (new () => {
|
|
3075
3028
|
$slots: {
|
|
3076
3029
|
'down-refresh'?: (props: {}) => any;
|
|
3077
3030
|
} & {
|
|
@@ -3176,7 +3129,7 @@ declare const components: {
|
|
|
3176
3129
|
$slots: SlotsType<Pick<LayoutOptions, "left" | "right" | "main" | "top" | "bottom">>;
|
|
3177
3130
|
});
|
|
3178
3131
|
Scroll: {
|
|
3179
|
-
new (...args: any[]): vue.CreateComponentPublicInstanceWithMixins<Readonly<
|
|
3132
|
+
new (...args: any[]): vue.CreateComponentPublicInstanceWithMixins<Readonly<snail_view.ScrollbarOptions> & Readonly<{
|
|
3180
3133
|
onLeft?: () => any;
|
|
3181
3134
|
onRight?: () => any;
|
|
3182
3135
|
onTop?: () => any;
|
|
@@ -3193,14 +3146,14 @@ declare const components: {
|
|
|
3193
3146
|
bottom: () => any;
|
|
3194
3147
|
xbar: (show: boolean) => any;
|
|
3195
3148
|
ybar: (show: boolean) => any;
|
|
3196
|
-
}, vue.PublicProps, {},
|
|
3149
|
+
}, vue.PublicProps, {}, false, {}, {}, vue.GlobalComponents, vue.GlobalDirectives, string, {}, any, vue.ComponentProvideOptions, {
|
|
3197
3150
|
P: {};
|
|
3198
3151
|
B: {};
|
|
3199
3152
|
D: {};
|
|
3200
3153
|
C: {};
|
|
3201
3154
|
M: {};
|
|
3202
3155
|
Defaults: {};
|
|
3203
|
-
}, Readonly<
|
|
3156
|
+
}, Readonly<snail_view.ScrollbarOptions> & Readonly<{
|
|
3204
3157
|
onLeft?: () => any;
|
|
3205
3158
|
onRight?: () => any;
|
|
3206
3159
|
onTop?: () => any;
|
|
@@ -3214,7 +3167,7 @@ declare const components: {
|
|
|
3214
3167
|
__isFragment?: never;
|
|
3215
3168
|
__isTeleport?: never;
|
|
3216
3169
|
__isSuspense?: never;
|
|
3217
|
-
} & vue.ComponentOptionsBase<Readonly<
|
|
3170
|
+
} & vue.ComponentOptionsBase<Readonly<snail_view.ScrollbarOptions> & Readonly<{
|
|
3218
3171
|
onLeft?: () => any;
|
|
3219
3172
|
onRight?: () => any;
|
|
3220
3173
|
onTop?: () => any;
|
|
@@ -3322,7 +3275,7 @@ declare const components: {
|
|
|
3322
3275
|
};
|
|
3323
3276
|
});
|
|
3324
3277
|
Table: {
|
|
3325
|
-
new (...args: any[]): vue.CreateComponentPublicInstanceWithMixins<Readonly<TableOptions> & Readonly<{}>, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, vue.PublicProps, {},
|
|
3278
|
+
new (...args: any[]): vue.CreateComponentPublicInstanceWithMixins<Readonly<TableOptions> & Readonly<{}>, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {}, vue.PublicProps, {}, false, {}, {}, vue.GlobalComponents, vue.GlobalDirectives, string, {}, any, vue.ComponentProvideOptions, {
|
|
3326
3279
|
P: {};
|
|
3327
3280
|
B: {};
|
|
3328
3281
|
D: {};
|