@tplc/business 0.7.17 → 0.7.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/CHANGELOG.md CHANGED
@@ -2,6 +2,34 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.7.19](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/compare/v0.7.16...v0.7.19) (2025-12-16)
6
+
7
+
8
+ ### 🐛 Bug Fixes | Bug 修复
9
+
10
+ * 判断错误 ([fd0a01e](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/fd0a01e80f6da304104bfc6c80b194be4c2d38be))
11
+
12
+
13
+ ### 🚀 Chore | 构建/工程依赖/工具
14
+
15
+ * **release:** 0.7.17 ([0ea0d3d](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/0ea0d3dfcd879dfcb305cd4a6bebbc35047c35db))
16
+ * **release:** 0.7.18 ([4d1b01d](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/4d1b01d826671e8fe00ff2807645c995654da817))
17
+ * **release:** 1.0.15 ([d452862](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/d45286238ac5605e828dec27e8b4752a7d8b837e))
18
+
19
+
20
+ ### ✨ Features | 新功能
21
+
22
+ * area 支持接受list数据 ([5abec9c](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/5abec9c777a1bc503f1206378ec60bddf9090c52))
23
+ * fix back top ([d076291](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/d076291dbe5b50549575f5815ad7f14e6ffa57ae))
24
+ * 查看value 是否存在 ([5af5ab0](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/5af5ab0f3591395c8ae12dd9afff711f431d141b))
25
+
26
+ ### [0.7.18](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/compare/v0.7.17...v0.7.18) (2025-12-16)
27
+
28
+
29
+ ### 🐛 Bug Fixes | Bug 修复
30
+
31
+ * 判断错误 ([fd0a01e](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/commit/fd0a01e80f6da304104bfc6c80b194be4c2d38be))
32
+
5
33
  ### [0.7.17](///compare/v0.7.12...v0.7.17) (2025-12-16)
6
34
 
7
35
 
@@ -1,6 +1,14 @@
1
1
  <template>
2
2
  <view
3
- v-if="props.renderMode === 'view'"
3
+ v-if="renderMode === 'noClick'"
4
+ class="lcb-action-btn"
5
+ :class="customClass"
6
+ :style="customStyle"
7
+ >
8
+ <slot />
9
+ </view>
10
+ <view
11
+ v-else-if="renderMode === 'view'"
4
12
  class="lcb-action-btn"
5
13
  :class="customClass"
6
14
  :style="customStyle"
@@ -7,7 +7,7 @@ export type LcbActionViewProps = {
7
7
  urlParams?: string
8
8
  customClass?: string
9
9
  customStyle?: StyleValue
10
- renderMode?: 'view' | 'button'
10
+ renderMode?: 'view' | 'button' | 'noClick'
11
11
  autoJumpSecond?: number
12
12
  /** 弹窗位置 */
13
13
  position?: PopupType
@@ -1,6 +1,9 @@
1
1
  <template>
2
2
  <lcb-block v-bind="$props" v-if="showArea">
3
- <lcb-action-view v-bind="actionProps">
3
+ <lcb-action-view
4
+ v-bind="actionProps"
5
+ :renderMode="actionProps?.jumpType ? 'button' : 'noClick'"
6
+ >
4
7
  <view
5
8
  :style="{
6
9
  display: display,
@@ -27,13 +30,13 @@
27
30
  </template>
28
31
 
29
32
  <script setup lang="ts">
30
- import { computed, inject, Ref, watch } from 'vue'
33
+ import { computed, watch } from 'vue'
31
34
  import { LcbAreaProps } from './types'
32
35
  import { getFlexStyle, transformValueUnit } from '@tplc/business/utils/transform'
33
36
  import { get } from 'lodash-es'
34
- import { PAGE_PROVIDE_KEY } from '@tplc/business/constants'
35
37
  import { dynamicRequest } from '../../utils/request'
36
38
  import { getDynamicData } from '../../utils/utils'
39
+ import useDynamicData from '../../hooks/useDynamicData'
37
40
  defineOptions({
38
41
  name: 'LcbArea',
39
42
  options: {
@@ -47,8 +50,7 @@ const props = withDefaults(defineProps<LcbAreaProps>(), {
47
50
  display: 'flex',
48
51
  overflowX: 'initial',
49
52
  })
50
- const pageInfo = inject(PAGE_PROVIDE_KEY) as Ref<Record<string, any>>
51
- const userStore = uni.$lcb.userStore?.()
53
+ const { userStore, innerDynamicData, pageInfo } = useDynamicData()
52
54
  const innerStyle = computed(() => {
53
55
  if (props.display === 'grid') {
54
56
  return {
@@ -87,12 +89,12 @@ const getData = async () => {
87
89
  /** 处理跳转链接中的动态参数 */
88
90
  const actionProps = computed(() => {
89
91
  if (props.dynamicActionKey) {
90
- return get(pageInfo.value, props.dynamicActionKey)
92
+ return get(innerDynamicData.value, props.dynamicActionKey)
91
93
  }
92
94
  return {
93
95
  ...props.action,
94
96
  jumpUrl: getDynamicData(props.action?.jumpUrl, {
95
- store: pageInfo.value,
97
+ store: innerDynamicData.value,
96
98
  }),
97
99
  }
98
100
  })
@@ -108,7 +110,10 @@ watch(
108
110
  )
109
111
  const showArea = computed(() => {
110
112
  if (props.dependKey) {
111
- const value = get(props.keyFromUser ? userStore?.userInfo : pageInfo.value, props.dependKey)
113
+ const value = get(
114
+ props.keyFromUser ? userStore?.userInfo : innerDynamicData.value,
115
+ props.dependKey,
116
+ )
112
117
 
113
118
  if (props.dependKeyCompareValue) {
114
119
  const compareValue = `${props.dependKeyCompareValue}`
@@ -21,6 +21,7 @@
21
21
  @avatar="onAvatar"
22
22
  @click="handleClick"
23
23
  :customStyle="styleOptions[1]"
24
+ :renderMode="!actionProps?.jumpType && mode !== 'image' ? 'noClick' : 'button'"
24
25
  >
25
26
  <view class="!flex items-center justify-center" :style="`gap: ${iconGap}rpx`">
26
27
  <wd-icon
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tplc/business",
3
- "version": "0.7.17",
3
+ "version": "0.7.19",
4
4
  "keywords": [
5
5
  "业务组件"
6
6
  ],
@@ -2,6 +2,7 @@ import { LcbActionViewProps } from './types'
2
2
  declare function __VLS_template(): {
3
3
  default?(_: {}): any
4
4
  default?(_: {}): any
5
+ default?(_: {}): any
5
6
  }
6
7
  declare const __VLS_component: import('vue').DefineComponent<
7
8
  __VLS_TypePropsToOption<LcbActionViewProps>,
@@ -6,7 +6,7 @@ export type LcbActionViewProps = {
6
6
  urlParams?: string
7
7
  customClass?: string
8
8
  customStyle?: StyleValue
9
- renderMode?: 'view' | 'button'
9
+ renderMode?: 'view' | 'button' | 'noClick'
10
10
  autoJumpSecond?: number
11
11
  /** 弹窗位置 */
12
12
  position?: PopupType
@@ -72,7 +72,7 @@ declare const _default: import('vue').DefineComponent<
72
72
  urlParams?: string
73
73
  customClass?: string
74
74
  customStyle?: import('vue').StyleValue
75
- renderMode?: 'view' | 'button'
75
+ renderMode?: 'view' | 'button' | 'noClick'
76
76
  autoJumpSecond?: number
77
77
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
78
78
  jumpInterceptor?: (
@@ -179,7 +179,7 @@ declare const _default: import('vue').DefineComponent<
179
179
  urlParams?: string
180
180
  customClass?: string
181
181
  customStyle?: import('vue').StyleValue
182
- renderMode?: 'view' | 'button'
182
+ renderMode?: 'view' | 'button' | 'noClick'
183
183
  autoJumpSecond?: number
184
184
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
185
185
  jumpInterceptor?: (
@@ -265,7 +265,7 @@ declare const _default: import('vue').DefineComponent<
265
265
  urlParams?: string
266
266
  customClass?: string
267
267
  customStyle?: import('vue').StyleValue
268
- renderMode?: 'view' | 'button'
268
+ renderMode?: 'view' | 'button' | 'noClick'
269
269
  autoJumpSecond?: number
270
270
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
271
271
  jumpInterceptor?: (
@@ -351,7 +351,7 @@ declare const _default: import('vue').DefineComponent<
351
351
  urlParams?: string
352
352
  customClass?: string
353
353
  customStyle?: import('vue').StyleValue
354
- renderMode?: 'view' | 'button'
354
+ renderMode?: 'view' | 'button' | 'noClick'
355
355
  autoJumpSecond?: number
356
356
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
357
357
  jumpInterceptor?: (
@@ -436,7 +436,7 @@ declare const _default: import('vue').DefineComponent<
436
436
  urlParams?: string
437
437
  customClass?: string
438
438
  customStyle?: import('vue').StyleValue
439
- renderMode?: 'view' | 'button'
439
+ renderMode?: 'view' | 'button' | 'noClick'
440
440
  autoJumpSecond?: number
441
441
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
442
442
  jumpInterceptor?: (
@@ -527,7 +527,7 @@ declare const _default: import('vue').DefineComponent<
527
527
  urlParams?: string
528
528
  customClass?: string
529
529
  customStyle?: import('vue').StyleValue
530
- renderMode?: 'view' | 'button'
530
+ renderMode?: 'view' | 'button' | 'noClick'
531
531
  autoJumpSecond?: number
532
532
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
533
533
  jumpInterceptor?: (
@@ -612,7 +612,7 @@ declare const _default: import('vue').DefineComponent<
612
612
  urlParams?: string
613
613
  customClass?: string
614
614
  customStyle?: import('vue').StyleValue
615
- renderMode?: 'view' | 'button'
615
+ renderMode?: 'view' | 'button' | 'noClick'
616
616
  autoJumpSecond?: number
617
617
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
618
618
  jumpInterceptor?: (
@@ -697,7 +697,7 @@ declare const _default: import('vue').DefineComponent<
697
697
  urlParams?: string
698
698
  customClass?: string
699
699
  customStyle?: import('vue').StyleValue
700
- renderMode?: 'view' | 'button'
700
+ renderMode?: 'view' | 'button' | 'noClick'
701
701
  autoJumpSecond?: number
702
702
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
703
703
  jumpInterceptor?: (
@@ -786,7 +786,7 @@ declare const _default: import('vue').DefineComponent<
786
786
  urlParams?: string
787
787
  customClass?: string
788
788
  customStyle?: import('vue').StyleValue
789
- renderMode?: 'view' | 'button'
789
+ renderMode?: 'view' | 'button' | 'noClick'
790
790
  autoJumpSecond?: number
791
791
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
792
792
  jumpInterceptor?: (
@@ -872,7 +872,7 @@ declare const _default: import('vue').DefineComponent<
872
872
  urlParams?: string
873
873
  customClass?: string
874
874
  customStyle?: import('vue').StyleValue
875
- renderMode?: 'view' | 'button'
875
+ renderMode?: 'view' | 'button' | 'noClick'
876
876
  autoJumpSecond?: number
877
877
  position?: import('@tplc/wot/types/components/wd-popup/types').PopupType
878
878
  jumpInterceptor?: (