From e816b1bcb5ec5fd649eb07c694539ba3c1ab73b0 Mon Sep 17 00:00:00 2001 From: James <72028410+James-9696@users.noreply.github.com> Date: Wed, 25 Dec 2024 10:08:27 +0800 Subject: [PATCH 1/3] fix(action-sheet): modify mobile problem (#2692) --- examples/sites/demos/apis/actionsheet.js | 23 ++++++++++++++++++- .../demos/mobile/app/actionsheet/clickfn.vue | 1 - .../demos/mobile/app/actionsheet/ellipsis.vue | 1 - .../mobile/app/actionsheet/slot-action.vue | 8 ++++++- .../mobile/app/actionsheet/slot-item.vue | 1 - .../app/actionsheet/webdoc/actionsheet.js | 4 ++-- .../theme-mobile/src/action-sheet/index.less | 7 +++--- 7 files changed, 35 insertions(+), 10 deletions(-) diff --git a/examples/sites/demos/apis/actionsheet.js b/examples/sites/demos/apis/actionsheet.js index 6114afbec9..cde9b6253a 100644 --- a/examples/sites/demos/apis/actionsheet.js +++ b/examples/sites/demos/apis/actionsheet.js @@ -37,6 +37,17 @@ export default { }, mode: ['mobile'], mobileDemo: 'ellipsis' + }, + { + name: 'content-position', + type: 'Boolean', + defaultValue: 'false', + desc: { + 'zh-CN': '是否显示action插槽', + 'en-US': 'Whether to display action slots ' + }, + mode: ['mobile'], + mobileDemo: 'slot-action' } ], events: [ @@ -70,12 +81,22 @@ export default { name: 'action', defaultValue: '', desc: { - 'zh-CN': '

自定义操作项内容

', + 'zh-CN': '

action插槽

', 'en-US': 'Click' }, mode: ['mobile'], mobileDemo: 'slot-action' }, + { + name: 'item', + defaultValue: '', + desc: { + 'zh-CN': '

item插槽

', + 'en-US': 'Click' + }, + mode: ['mobile'], + mobileDemo: 'slot-item' + }, { mode: [] } diff --git a/examples/sites/demos/mobile/app/actionsheet/clickfn.vue b/examples/sites/demos/mobile/app/actionsheet/clickfn.vue index 519991fdca..b83a0ee8d0 100644 --- a/examples/sites/demos/mobile/app/actionsheet/clickfn.vue +++ b/examples/sites/demos/mobile/app/actionsheet/clickfn.vue @@ -11,7 +11,6 @@ :visible="boxVisibility" @update:visible="boxVisibility = $event" @click="clickItem" - content-position > diff --git a/examples/sites/demos/mobile/app/actionsheet/ellipsis.vue b/examples/sites/demos/mobile/app/actionsheet/ellipsis.vue index 70428195f8..b1890a8228 100644 --- a/examples/sites/demos/mobile/app/actionsheet/ellipsis.vue +++ b/examples/sites/demos/mobile/app/actionsheet/ellipsis.vue @@ -11,7 +11,6 @@ ellipsis :visible="boxVisibility" @update:visible="boxVisibility = $event" - content-position > diff --git a/examples/sites/demos/mobile/app/actionsheet/slot-action.vue b/examples/sites/demos/mobile/app/actionsheet/slot-action.vue index 3cc058ec7d..3117eeb4e8 100644 --- a/examples/sites/demos/mobile/app/actionsheet/slot-action.vue +++ b/examples/sites/demos/mobile/app/actionsheet/slot-action.vue @@ -12,7 +12,13 @@ :visible="boxVisibility" @update:visible="boxVisibility = $event" content-position - > + > + + diff --git a/examples/sites/demos/mobile/app/actionsheet/slot-item.vue b/examples/sites/demos/mobile/app/actionsheet/slot-item.vue index b6b2951526..ac0dfc29c7 100644 --- a/examples/sites/demos/mobile/app/actionsheet/slot-item.vue +++ b/examples/sites/demos/mobile/app/actionsheet/slot-item.vue @@ -10,7 +10,6 @@ :menus="menus" :visible="boxVisibility" @update:visible="boxVisibility = $event" - content-position > + + diff --git a/examples/sites/demos/mobile/app/exception/message.vue b/examples/sites/demos/mobile/app/exception/message.vue index 96be4ee71d..01f3792e2b 100644 --- a/examples/sites/demos/mobile/app/exception/message.vue +++ b/examples/sites/demos/mobile/app/exception/message.vue @@ -1,6 +1,6 @@ @@ -12,9 +12,7 @@ export default { TinyException }, data() { - return { - imageUrl: `${import.meta.env.VITE_APP_BUILD_BASE_URL}static/images/planet1.jpg` - } + return {} }, methods: { test() { diff --git a/packages/mobile/components/exception/src/exception.ts b/packages/mobile/components/exception/src/exception.ts index 3ced695aae..3271e08e56 100644 --- a/packages/mobile/components/exception/src/exception.ts +++ b/packages/mobile/components/exception/src/exception.ts @@ -3,6 +3,7 @@ export const exceptionProps = { type: String, default: 'nodata' }, + buttonText: String, message: String, subMessage: String, exceptionClass: String, diff --git a/packages/mobile/components/exception/src/mobile.vue b/packages/mobile/components/exception/src/mobile.vue index dd44b8dd4d..c8b79c12cb 100644 --- a/packages/mobile/components/exception/src/mobile.vue +++ b/packages/mobile/components/exception/src/mobile.vue @@ -17,7 +17,7 @@
- {{ state.message }} + {{ message }}
{{ subMessage }}