From 5c6068ee7b37e5b6e4a7cb27b0c0102937a3ef14 Mon Sep 17 00:00:00 2001 From: hanyuxinting Date: Fri, 27 Dec 2024 16:26:57 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20v15=20=E9=80=82=E9=85=8Ddemo=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/pages/index/index.scss | 4 +-- .../nutui-taro-demo/src/pages/index/index.tsx | 2 +- scripts/rn/copy-file.js | 4 +-- scripts/rn/update-taro-entry.js | 4 +-- scripts/sync-to-taro-playground.js | 2 +- scripts/taro/generate-taro-pages.js | 4 +-- src/config.json | 27 +++++++++++++++++-- src/sites/mobile/Links.scss | 4 +-- 8 files changed, 37 insertions(+), 14 deletions(-) diff --git a/packages/nutui-taro-demo/src/pages/index/index.scss b/packages/nutui-taro-demo/src/pages/index/index.scss index 52a41cd2f9..8e55ba56df 100644 --- a/packages/nutui-taro-demo/src/pages/index/index.scss +++ b/packages/nutui-taro-demo/src/pages/index/index.scss @@ -96,7 +96,7 @@ body { } &-components { background: #f7f8fa; - border-radius: 30px 30px 0 0; + border-radius: 12px 12px 0 0; padding: 30px 25px; &-item { margin-bottom: 17px; @@ -116,7 +116,7 @@ body { height: 45px; line-height: 45px; background: rgba(255, 255, 255, 1); - border-radius: 22px; + border-radius: 8px; box-shadow: 0px 1px 4px 0px rgba(102, 102, 102, 0.06); margin-bottom: 13px; &-content { diff --git a/packages/nutui-taro-demo/src/pages/index/index.tsx b/packages/nutui-taro-demo/src/pages/index/index.tsx index 2252ac79f1..0dec1a079c 100644 --- a/packages/nutui-taro-demo/src/pages/index/index.tsx +++ b/packages/nutui-taro-demo/src/pages/index/index.tsx @@ -69,7 +69,7 @@ const Index = () => { {process.env.NODE_ENV === 'development' ? <> - { + { setSearch(e) }} /> diff --git a/scripts/rn/copy-file.js b/scripts/rn/copy-file.js index 0a40f43c3a..8547f99858 100644 --- a/scripts/rn/copy-file.js +++ b/scripts/rn/copy-file.js @@ -11,8 +11,8 @@ console.log('rn copy-file.js args', args) const adaptedArray = [] config.nav.map((item) => { item.packages.forEach((element) => { - const { name, version } = element - if (version !== '3.0.0') return // 未适配不导出 + const { name, version,v15 } = element + if (!v15) return // 未适配不导出 adaptedArray.push({ ...element, lowercaseName: element.name.toLowerCase(), diff --git a/scripts/rn/update-taro-entry.js b/scripts/rn/update-taro-entry.js index 22d1789714..7e087bb050 100644 --- a/scripts/rn/update-taro-entry.js +++ b/scripts/rn/update-taro-entry.js @@ -17,8 +17,8 @@ function specialComponent(name) { const adaptedArray = [] config.nav.map((item) => { item.packages.forEach((element) => { - const { name, version } = element - if (version !== '3.0.0') return // 未适配不导出 + const { name, version,v15 } = element + if (!v15) return // 未适配不导出 if (specialComponent(name)) return adaptedArray.push({ ...element, diff --git a/scripts/sync-to-taro-playground.js b/scripts/sync-to-taro-playground.js index 66885563c9..5224243586 100644 --- a/scripts/sync-to-taro-playground.js +++ b/scripts/sync-to-taro-playground.js @@ -68,7 +68,7 @@ function main() { pages: [], }) nav.packages.forEach((package) => { - if (package.version === '3.0.0' && package.show) { + if (package.v15 && package.show) { const name = package.name.toLowerCase() v3.push(name) subPackages[subPackages.length - 1].pages.push(`pages/${name}/index`) diff --git a/scripts/taro/generate-taro-pages.js b/scripts/taro/generate-taro-pages.js index 9b82f07093..cd87bc4c34 100644 --- a/scripts/taro/generate-taro-pages.js +++ b/scripts/taro/generate-taro-pages.js @@ -7,8 +7,8 @@ const config = require('../../src/config.json') const adaptedArray = [] config.nav.map((item) => { item.packages.forEach((element) => { - const { name, version } = element - if (version !== '3.0.0') return // 未适配不导出 + const { name, version,v15 } = element + if (!v15) return // 未适配不导出 adaptedArray.push(element.name.toLowerCase()) }) }) diff --git a/src/config.json b/src/config.json index 9767d8cab4..3144734c04 100644 --- a/src/config.json +++ b/src/config.json @@ -79,6 +79,7 @@ "sort": 1, "show": true, "taro": true, + "v15": true, "author": "" }, { @@ -90,6 +91,7 @@ "sort": 2, "show": true, "taro": true, + "v15": true, "author": "songsong" }, { @@ -102,6 +104,7 @@ "show": false, "taro": true, "exportEmpty": true, + "v15": true, "author": "songsong" }, { @@ -114,6 +117,7 @@ "show": true, "exportEmpty": true, "taro": true, + "v15": true, "author": "hanyuxinting" }, { @@ -126,6 +130,7 @@ "show": true, "taro": true, "exclude": true, + "v15": true, "author": "oasis-cloud" }, { @@ -138,6 +143,7 @@ "sort": 8, "show": true, "taro": true, + "v15": true, "author": "vickyYE" }, { @@ -149,6 +155,7 @@ "sort": 5, "show": true, "taro": true, + "v15": true, "author": "junjun" } ] @@ -177,6 +184,7 @@ "sort": 7, "show": true, "taro": true, + "v15": true, "author": "vickyYE" }, { @@ -201,6 +209,7 @@ "show": false, "taro": true, "exportEmpty": true, + "v15": true, "author": "yangxiaolu" }, { @@ -308,6 +317,7 @@ "sort": 5, "show": true, "taro": true, + "v15": true, "author": "Ymm0008" }, { @@ -320,6 +330,7 @@ "sort": 5, "show": false, "taro": true, + "v15": true, "author": "Ymm0008" }, { @@ -376,6 +387,7 @@ "sort": 2, "show": true, "taro": true, + "v15": true, "author": "dsj" }, { @@ -386,6 +398,7 @@ "type": "component", "show": false, "taro": true, + "v15": true, "exportEmpty": true, "desc": "标签栏子组件", "author": "dsj" @@ -397,6 +410,7 @@ "cName": "选项卡切换子组件", "type": "component", "show": false, + "v15": true, "exportEmpty": true, "desc": "选项卡切换子组件", "author": "张晶发" @@ -410,6 +424,7 @@ "sort": 12, "show": true, "taro": true, + "v15": true, "author": "oasis" } ] @@ -493,6 +508,7 @@ "desc": "多选按钮组", "sort": 11, "show": false, + "v15": true, "exportEmpty": true, "author": "oasis" }, @@ -551,6 +567,7 @@ "sort": 3, "show": true, "taro": true, + "v15": true, "author": "swag~jun" } ] @@ -625,6 +642,7 @@ "sort": 10, "exportEmpty": true, "show": false, + "v15": true, "author": "oasis" }, { @@ -757,10 +775,11 @@ "sort": 12, "show": true, "taro": true, + "v15": true, "author": "yangjinjun3" }, { - "version": "2.0.0", + "version": "3.0.0", "name": "Drag", "type": "component", "cName": "拖拽", @@ -768,6 +787,7 @@ "sort": 1, "show": true, "taro": true, + "v15": true, "author": "songsong" }, { @@ -816,6 +836,7 @@ "sort": 15, "show": true, "taro": true, + "v15": true, "author": "mike8625" }, { @@ -842,7 +863,7 @@ "author": "vickyYE" }, { - "version": "2.0.0", + "version": "3.0.0", "name": "Popover", "type": "component", "cName": "气泡弹出框", @@ -850,6 +871,7 @@ "sort": 19, "show": true, "taro": true, + "v15": true, "author": "lzz" }, { @@ -874,6 +896,7 @@ "sort": 10, "show": true, "taro": true, + "v15": true, "author": "oasis" }, { diff --git a/src/sites/mobile/Links.scss b/src/sites/mobile/Links.scss index a29172b7bd..94662a28b9 100644 --- a/src/sites/mobile/Links.scss +++ b/src/sites/mobile/Links.scss @@ -34,7 +34,7 @@ } &-components { background: #f7f8fa; - border-radius: 30px 30px 0 0; + border-radius: 12px 12px 0 0; padding: 30px 25px; > ol { margin-bottom: 17px; @@ -52,7 +52,7 @@ height: 45px; line-height: 45px; background: rgba(255, 255, 255, 1); - border-radius: 22px; + border-radius: 8px; box-shadow: 0px 1px 4px 0px rgba(102, 102, 102, 0.06); margin-bottom: 13px; a {