hw-cus-ui 1.1.6 → 1.1.7

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/index.d.ts CHANGED
@@ -7,12 +7,12 @@ import HwInput from './HwInput';
7
7
  import HwFileUpload from './HwFileUpload';
8
8
  import HwCheckbox from './HwCheckbox';
9
9
  import HwTabs from './HwTabs';
10
- import HwAppList from './z-paging/components/z-paging/z-paging.vue';
10
+ import ZPaging from './z-paging';
11
11
 
12
- export { HwBtn, HwDraggableBottomPopup, HwSelect, HwPickerTree, HwInput, HwFileUpload, HwCheckbox, HwTabs, HwAppList };
12
+ export { HwBtn, HwDraggableBottomPopup, HwSelect, HwPickerTree, HwInput, HwFileUpload, HwCheckbox, HwTabs, ZPaging };
13
13
 
14
14
  export declare const hwCusUi: {
15
15
  install: (app: App) => void;
16
16
  };
17
17
 
18
- export default hwCusUi;
18
+ export default hwCusUi;
package/index.ts CHANGED
@@ -8,9 +8,9 @@ import HwInput from './HwInput';
8
8
  import HwFileUpload from './HwFileUpload';
9
9
  import HwCheckbox from './HwCheckbox';
10
10
  import HwTabs from './HwTabs';
11
- import HwAppList from './z-paging/components/z-paging/z-paging.vue';
11
+ import ZPaging from './z-paging';
12
12
 
13
- export { HwBtn, HwDraggableBottomPopup, HwSelect, HwPickerTree, HwInput, HwFileUpload, HwCheckbox, HwTabs, HwAppList };
13
+ export { HwBtn, HwDraggableBottomPopup, HwSelect, HwPickerTree, HwInput, HwFileUpload, HwCheckbox, HwTabs, ZPaging };
14
14
 
15
15
  // 所有组件列表
16
16
  const components = [
@@ -22,7 +22,7 @@ const components = [
22
22
  HwFileUpload,
23
23
  HwCheckbox,
24
24
  HwTabs,
25
- HwAppList
25
+ ZPaging
26
26
  ];
27
27
 
28
28
  // 定义 install 方法
@@ -35,4 +35,4 @@ const hwCusUi = {
35
35
  install
36
36
  };
37
37
 
38
- export default hwCusUi;
38
+ export default hwCusUi;
package/package.json CHANGED
@@ -1,15 +1,24 @@
1
1
  {
2
2
  "name": "hw-cus-ui",
3
- "version": "1.1.6",
3
+ "version": "1.1.7",
4
4
  "description": "使用该组件库需安装uniapp插件@dcloudio/uni-ui",
5
5
  "main": "index.ts",
6
6
  "scripts": {
7
7
  "test": "echo \"Error: no test specified\" && exit 1"
8
8
  },
9
- "keywords": [],
9
+ "keywords": [
10
+ "uniapp",
11
+ "vue",
12
+ "ui",
13
+ "component",
14
+ "pagination",
15
+ "scroll"
16
+ ],
10
17
  "author": "",
11
18
  "license": "ISC",
12
19
  "type": "commonjs",
13
20
  "types": "./index.d.ts",
14
- "dependencies": {}
21
+ "dependencies": {
22
+ "file-saver": "^2.0.5"
23
+ }
15
24
  }
@@ -16,29 +16,16 @@
16
16
  </template>
17
17
 
18
18
  <script>
19
- import zStatic from '../z-paging/js/z-paging-static'
19
+ // #ifdef APP-NVUE
20
+ import zStatic from '../z-paging/js/z-paging-static';
21
+ // #endif
20
22
 
21
- /**
22
- * z-paging-empty-view 空数据组件
23
- * @description 通用的 z-paging 空数据组件
24
- * @tutorial https://z-paging.zxlee.cn/api/sub-components/main.html#z-paging-empty-view配置
25
- * @property {Boolean} emptyViewFixed 空数据图片是否铺满 z-paging,默认为 false。若设置为 true,则为填充满 z-paging 的剩余部分
26
- * @property {String} emptyViewText 空数据图描述文字,默认为 '没有数据哦~'
27
- * @property {String} emptyViewImg 空数据图图片,默认使用 z-paging 内置的图片 (建议使用绝对路径,开头不要添加 "@",请以 "/" 开头)
28
- * @property {String} emptyViewReloadText 空数据图点击重新加载文字,默认为 '重新加载'
29
- * @property {Object} emptyViewStyle 空数据图样式,可设置空数据 view 的 top 等,如: empty-view-style="{'top':'100rpx'}" (如果空数据图不是 fixed 布局,则此处是 margin-top),默认为 {}
30
- * @property {Object} emptyViewImgStyle 空数据图 img 样式,默认为 {}
31
- * @property {Object} emptyViewTitleStyle 空数据图描述文字样式,默认为 {}
32
- * @property {Object} emptyViewReloadStyle 空数据图重新加载按钮样式,默认为 {}
33
- * @property {Boolean} showEmptyViewReload 是否显示空数据图重新加载按钮(无数据时),默认为 false
34
- * @property {Boolean} isLoadFailed 是否是加载失败,默认为 false
35
- * @property {String} unit 空数据图中布局的单位,默认为 'rpx'
36
- * @event {Function} reload 点击了重新加载按钮
37
- * @event {Function} viewClick 点击了空数据图 view
38
- * @example <z-paging-empty-view empty-view-text="暂无数据" />
39
- */
23
+ // #ifndef APP-NVUE
24
+ import zStatic from '../js/z-paging-static';
25
+ // #endif
40
26
  export default {
41
- name: "z-paging-empty-view",
27
+ name: 'z-paging-empty-view',
28
+ mixins: [zStatic],
42
29
  data() {
43
30
  return {
44
31
 
@@ -26,19 +26,15 @@
26
26
  </template>
27
27
 
28
28
  <script>
29
- import commonLayoutModule from '../z-paging/js/modules/common-layout'
29
+ // #ifdef APP-NVUE
30
+ import commonLayoutModule from '../z-paging/js/modules/common-layout';
31
+ // #endif
30
32
 
31
- /**
32
- * z-paging-swiper 组件
33
- * @description 在 swiper 中使用 z-paging 时(左右滑动切换列表),在根节点使用 z-paging-swiper,其相当于一个 view 容器,默认铺满全屏,可免计算高度直接插入 swiper 的视图容器。
34
- * @tutorial https://z-paging.zxlee.cn/api/sub-components/main.html#z-paging-swiper配置
35
- * @property {Boolean} fixed 是否使用 fixed 布局,默认为 true
36
- * @property {Boolean} safeAreaInsetBottom 是否开启底部安全区域适配,默认为 false
37
- * @property {Object} swiperStyle z-paging-swiper 样式,默认为 {}
38
- * @example <z-paging-swiper :safeAreaInsetBottom="true"></z-paging-swiper>
39
- */
33
+ // #ifndef APP-NVUE
34
+ import commonLayoutModule from '../js/modules/common-layout';
35
+ // #endif
40
36
  export default {
41
- name: "z-paging-swiper",
37
+ name: 'z-paging-swiper',
42
38
  mixins: [commonLayoutModule],
43
39
  data() {
44
40
  return {
@@ -25,26 +25,15 @@
25
25
  </template>
26
26
 
27
27
  <script>
28
- import zPaging from '../z-paging/z-paging'
29
- /**
30
- * z-paging-swiper-item 组件
31
- * @description swiper+list极简写法中使用到,实际上就是对普通的swiper+list中swiper-item的包装封装,用以简化写法,但个性化配置局限较多
32
- * @tutorial https://z-paging.zxlee.cn/api/sub-components/main.html#z-paging-swiper-item配置
33
- * @notice 以下为 z-paging-swiper-item 的配置项
34
- * @property {Number} tabIndex 当前组件的 index,也就是当前组件是 swiper 中的第几个,默认为 0
35
- * @property {Number} currentIndex 当前 swiper 切换到第几个 index,默认为 0
36
- * @property {Boolean} useVirtualList 是否使用虚拟列表,默认为 false
37
- * @property {Boolean} useInnerList 是否在 z-paging 内部循环渲染列表(内置列表),默认为 false。若 useVirtualList 为 true,则此项恒为 true
38
- * @property {String} cellKeyName 内置列表 cell 的 key 名称,仅 nvue 有效,在 nvue 中开启 useInnerList 时必须填此项,默认为 ''
39
- * @property {Object} innerListStyle innerList 样式,默认为 {}
40
- * @property {Number|String} preloadPage 预加载的列表可视范围(列表高度)页数,默认为 12。此数值越大,则虚拟列表中加载的 dom 越多,内存消耗越大(会维持在一个稳定值),但增加预加载页面数量可缓解快速滚动短暂白屏问题
41
- * @property {String} cellHeightMode 虚拟列表 cell 高度模式,默认为 'fixed',也就是每个 cell 高度完全相同,将以第一个 cell 高度为准进行计算。可选值【dynamic】,即代表高度是动态非固定的,【dynamic】性能低于【fixed】
42
- * @property {Number|String} virtualListCol 虚拟列表列数,默认为 1。常用于每行有多列的情况,例如每行有 2 列数据,需要将此值设置为 2
43
- * @property {Number|String} virtualScrollFps 虚拟列表 scroll 取样帧率,默认为 60,过高可能出现卡顿等问题
44
- * @example <z-paging-swiper-item ref="swiperItem" :tabIndex="index" :currentIndex="current" @query="queryList" @updateList="updateList"></z-paging-swiper-item>
45
- */
28
+ // #ifdef APP-NVUE
29
+ import zPaging from '../z-paging/z-paging';
30
+ // #endif
31
+
32
+ // #ifndef APP-NVUE
33
+ import zPaging from '../z-paging/z-paging';
34
+ // #endif
46
35
  export default {
47
- name: "z-paging-swiper-item",
36
+ name: 'z-paging-swiper-item',
48
37
  components: { zPaging },
49
38
  data() {
50
39
  return {
@@ -0,0 +1,3 @@
1
+ declare const ZPaging: any;
2
+
3
+ export default ZPaging;
@@ -0,0 +1,7 @@
1
+ import ZPaging from './components/z-paging/z-paging.vue';
2
+
3
+ ZPaging.install = function(Vue: any) {
4
+ Vue.component(ZPaging.name, ZPaging);
5
+ };
6
+
7
+ export default ZPaging;