hw-cus-ui 1.1.13 → 1.1.14

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.
@@ -3,6 +3,7 @@
3
3
  <view
4
4
  class="draggable-popup-container"
5
5
  :style="{
6
+ backgroundColor: bg,
6
7
  top: popupTop + 'px',
7
8
  position: isDrag ? 'fixed' : 'initial',
8
9
  borderTopLeftRadius: isDrag ? '20rpx' : '0',
@@ -35,6 +36,10 @@ export default {
35
36
  type: String,
36
37
  default: '0.4'
37
38
  },
39
+ bg: {
40
+ type: String,
41
+ default: () => '#ffffff'
42
+ },
38
43
  isDrag: {
39
44
  type: Boolean,
40
45
  default: () => true
@@ -37,7 +37,7 @@
37
37
  @input="changeSelect"
38
38
  />
39
39
  <view class="tki-tree-view-sc" :scroll-y="true">
40
- <HwAppList ref="paging" :fixed="false" v-model="dataList" @query="queryList">
40
+ <z-paging ref="paging" :fixed="false" v-model="dataList" @query="queryList">
41
41
  <block v-for="(item, index) in treeList" :key="index">
42
42
  <view
43
43
  class="tki-tree-item"
@@ -83,7 +83,7 @@
83
83
  </view>
84
84
  </view>
85
85
  </block>
86
- </HwAppList>
86
+ </z-paging>
87
87
  </view>
88
88
  </view>
89
89
  </view>
@@ -92,7 +92,6 @@
92
92
 
93
93
  <script setup>
94
94
  import { ref, onMounted, watch, nextTick } from 'vue';
95
- import HwAppList from '../z-paging';
96
95
 
97
96
  const props = defineProps({
98
97
  range: {
@@ -327,7 +326,7 @@ watch(
327
326
 
328
327
  onMounted(() => {
329
328
  if (!props.request) {
330
- _initTree(newVal);
329
+ _initTree();
331
330
  }
332
331
  });
333
332
 
@@ -352,32 +351,37 @@ function queryList(pageNum, pageSize) {
352
351
  function _show() {
353
352
  if (props.disabled) return;
354
353
  showTree.value = true;
354
+ if (props.request) {
355
+ nextTick().then(() => {
356
+ paging.value && paging.value.reload();
357
+ });
358
+ }
355
359
  }
356
360
 
357
361
  /**
358
362
  * 隐藏树选择器
359
363
  */
360
364
  function _hide() {
361
- temporarySelectedValue = [];
365
+ // temporarySelectedValue = [];
362
366
  showTree.value = false;
367
+ emit('cancel');
363
368
  }
364
369
 
365
370
  /**
366
371
  * 取消选择操作
367
372
  */
368
373
  function _cancel() {
369
- if (!props.multiple) {
370
- curLabel.value = '';
371
- emit('update:modelValue', '');
372
- emit('confirm', '');
373
- } else {
374
- val = val.filter((v) => !temporarySelectedValue.includes(v));
375
- curLabel.value = val.join(',');
376
-
377
- emit('update:modelValue', val);
378
- }
374
+ // if (!props.multiple) {
375
+ // curLabel.value = '';
376
+ // emit('update:modelValue', '');
377
+ // emit('confirm', '');
378
+ // } else {
379
+ // val = val.filter((v) => !temporarySelectedValue.includes(v));
380
+ // curLabel.value = val.join(',');
381
+
382
+ // emit('update:modelValue', val);
383
+ // }
379
384
  _hide();
380
- emit('cancel', []);
381
385
  }
382
386
 
383
387
  /**
package/README.md ADDED
@@ -0,0 +1,8 @@
1
+ # 组件发包
2
+
3
+ - npm login
4
+ - npm publish
5
+
6
+ ## 更新问题版本
7
+
8
+ - 1.1.14版本:修复拖拽背景不能自适应问题
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hw-cus-ui",
3
- "version": "1.1.13",
3
+ "version": "1.1.14",
4
4
  "description": "使用该组件库需安装uniapp插件@dcloudio/uni-ui",
5
5
  "main": "index.ts",
6
6
  "scripts": {