diff --git a/blog-uniapp/.gitignore b/blog-uniapp/.gitignore deleted file mode 100644 index 6f638229..00000000 --- a/blog-uniapp/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -unpackage/ -dist/ -node_modules diff --git a/blog-uniapp/.hbuilderx/launch.json b/blog-uniapp/.hbuilderx/launch.json deleted file mode 100644 index 582561b0..00000000 --- a/blog-uniapp/.hbuilderx/launch.json +++ /dev/null @@ -1,16 +0,0 @@ -{ // launch.json 配置了启动调试时相关设置,configurations下节点名称可为 app-plus/h5/mp-weixin/mp-baidu/mp-alipay/mp-qq/mp-toutiao/mp-360/ - // launchtype项可配置值为local或remote, local代表前端连本地云函数,remote代表前端连云端云函数 - "version": "0.0", - "configurations": [{ - "app-plus" : - { - "launchtype" : "local" - }, - "default" : - { - "launchtype" : "local" - }, - "type" : "uniCloud" - } - ] -} diff --git a/blog-uniapp/.prettierignore b/blog-uniapp/.prettierignore deleted file mode 100644 index b181c360..00000000 --- a/blog-uniapp/.prettierignore +++ /dev/null @@ -1,4 +0,0 @@ -uni_modules/ -unpackage/ -.vite/ -.hbuilderx/ \ No newline at end of file diff --git a/blog-uniapp/.prettierrc b/blog-uniapp/.prettierrc deleted file mode 100644 index a71516f9..00000000 --- a/blog-uniapp/.prettierrc +++ /dev/null @@ -1,11 +0,0 @@ -{ - "htmlWhitespaceSensitivity": "ignore", - - "useTabs": false, - "endOfLine": "auto", - "proseWrap": "preserve", - "quoteProps": "as-needed", - - "insertPragma": false, - "printWidth": 200 -} diff --git a/blog-uniapp/.vite/deps/package.json b/blog-uniapp/.vite/deps/package.json deleted file mode 100644 index 7c34deb5..00000000 --- a/blog-uniapp/.vite/deps/package.json +++ /dev/null @@ -1 +0,0 @@ -{"type":"module"} \ No newline at end of file diff --git a/blog-uniapp/App.vue b/blog-uniapp/App.vue deleted file mode 100644 index 8d19b26f..00000000 --- a/blog-uniapp/App.vue +++ /dev/null @@ -1,33 +0,0 @@ - - - diff --git a/blog-uniapp/ajax.ts b/blog-uniapp/ajax.ts deleted file mode 100644 index e802b661..00000000 --- a/blog-uniapp/ajax.ts +++ /dev/null @@ -1,41 +0,0 @@ -import ajax from '@/uni_modules/u-ajax/js_sdk'; - - -let apiUrl='http://192.168.0.102:2801/v2' -// 创建请求实例 -const instance = ajax.create({ - // 初始配置 - baseURL: apiUrl -}); - -// 添加请求拦截器 -instance.interceptors.request.use( - config => { - // 在发送请求前做些什么 - return config; - }, - error => { - console.log('网络问题'); - console.log(error); - // 对请求错误做些什么 - return Promise.reject(error); - } -); - -// 添加响应拦截器 -instance.interceptors.response.use( - response => { - // 对响应数据做些什么 - let { data } = response; - return data; - }, - error => { - console.log('返回数据'); - console.log(error); - // 对响应错误做些什么 - return Promise.reject(error); - } -); - -// 导出 create 创建后的实例 -export default instance; diff --git a/blog-uniapp/apis/static.ts b/blog-uniapp/apis/static.ts deleted file mode 100644 index c893c145..00000000 --- a/blog-uniapp/apis/static.ts +++ /dev/null @@ -1,8 +0,0 @@ -import ajax from '../ajax' - -export function getMihoyo(){ - return ajax.get('/cat') -} -export function loginApi(username:string,password:string){ - return ajax.post(`/auth/login`,{username,password}) -} \ No newline at end of file diff --git a/blog-uniapp/index.html b/blog-uniapp/index.html deleted file mode 100644 index 59223e60..00000000 --- a/blog-uniapp/index.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - -
- - - diff --git a/blog-uniapp/main.js b/blog-uniapp/main.js deleted file mode 100644 index 6e90b8cb..00000000 --- a/blog-uniapp/main.js +++ /dev/null @@ -1,24 +0,0 @@ -// #ifndef VUE3 -import Vue from "vue"; -import App from "./App"; - -Vue.config.productionTip = false; - -App.mpType = "app"; - -const app = new Vue({ - ...App, -}); -app.$mount(); -// #endif - -// #ifdef VUE3 -import { createSSRApp } from "vue"; -import App from "./App.vue"; -export function createApp() { - const app = createSSRApp(App); - return { - app, - }; -} -// #endif diff --git a/blog-uniapp/manifest.json b/blog-uniapp/manifest.json deleted file mode 100644 index 36bad61d..00000000 --- a/blog-uniapp/manifest.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "name": "ui", - "appid": "__UNI__A02DEB1", - "description": "", - "versionName": "1.0.0", - "versionCode": "100", - "transformPx": false, - "app-plus": { - /* 5+App特有相关 */ - "usingComponents": true, - "nvueCompiler": "uni-app", - "nvueStyleCompiler": "uni-app", - "splashscreen": { - "alwaysShowBeforeRender": true, - "waiting": true, - "autoclose": true, - "delay": 0 - }, - "modules": {}, - /* 模块配置 */ - "distribute": { - /* 应用发布信息 */ - "android": { - /* android打包配置 */ - "permissions": [ - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "", - "" - ] - }, - "ios": {}, - /* ios打包配置 */ - "sdkConfigs": {} - } - }, - /* SDK配置 */ - "quickapp": {}, - /* 快应用特有相关 */ - "mp-weixin": { - /* 小程序特有相关 */ - "appid": "", - "setting": { - "urlCheck": false - }, - "usingComponents": true - }, - "vueVersion": "3" -} diff --git a/blog-uniapp/pages.json b/blog-uniapp/pages.json deleted file mode 100644 index 51843150..00000000 --- a/blog-uniapp/pages.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "pages": [{ - "path": "pages/index/index", - "style": { - "navigationBarTitleText": "uni-app" - } - }, - { - "path": "pages/Demo", - "style": { - "navigationBarTitleText": "demo-page" - } - }, - { - "path": "pages/UploadFile", - "style": { - "navigationBarTitleText": "", - "enablePullDownRefresh": false - } - - } ,{ - "path": "pages/Login", - "style": { - "navigationBarTitleText": "", - "enablePullDownRefresh": false - } - - } - ], - "globalStyle": { - "navigationBarTextStyle": "black", - "navigationBarTitleText": "uni-app", - "navigationBarBackgroundColor": "#F8F8F8", - "backgroundColor": "#F8F8F8", - "app-plus": { - "background": "#efeff4" - } - } -} diff --git a/blog-uniapp/pages/Demo.vue b/blog-uniapp/pages/Demo.vue deleted file mode 100644 index db09de62..00000000 --- a/blog-uniapp/pages/Demo.vue +++ /dev/null @@ -1,32 +0,0 @@ - - - - - diff --git a/blog-uniapp/pages/Login.vue b/blog-uniapp/pages/Login.vue deleted file mode 100644 index 0c64526b..00000000 --- a/blog-uniapp/pages/Login.vue +++ /dev/null @@ -1,43 +0,0 @@ - - - - - diff --git a/blog-uniapp/pages/UploadFile.vue b/blog-uniapp/pages/UploadFile.vue deleted file mode 100644 index 92161c9d..00000000 --- a/blog-uniapp/pages/UploadFile.vue +++ /dev/null @@ -1,240 +0,0 @@ - - - - - - diff --git a/blog-uniapp/pages/index/index.vue b/blog-uniapp/pages/index/index.vue deleted file mode 100644 index ea4e02a6..00000000 --- a/blog-uniapp/pages/index/index.vue +++ /dev/null @@ -1,49 +0,0 @@ - - - - - diff --git a/blog-uniapp/static/c1.png b/blog-uniapp/static/c1.png deleted file mode 100644 index 9d38fdc4..00000000 Binary files a/blog-uniapp/static/c1.png and /dev/null differ diff --git a/blog-uniapp/static/c2.png b/blog-uniapp/static/c2.png deleted file mode 100644 index ce956d76..00000000 Binary files a/blog-uniapp/static/c2.png and /dev/null differ diff --git a/blog-uniapp/static/c3.png b/blog-uniapp/static/c3.png deleted file mode 100644 index 216202ad..00000000 Binary files a/blog-uniapp/static/c3.png and /dev/null differ diff --git a/blog-uniapp/static/c4.png b/blog-uniapp/static/c4.png deleted file mode 100644 index fb8b4770..00000000 Binary files a/blog-uniapp/static/c4.png and /dev/null differ diff --git a/blog-uniapp/static/c5.png b/blog-uniapp/static/c5.png deleted file mode 100644 index 310bfb12..00000000 Binary files a/blog-uniapp/static/c5.png and /dev/null differ diff --git a/blog-uniapp/static/c6.png b/blog-uniapp/static/c6.png deleted file mode 100644 index c3c45d88..00000000 Binary files a/blog-uniapp/static/c6.png and /dev/null differ diff --git a/blog-uniapp/static/c7.png b/blog-uniapp/static/c7.png deleted file mode 100644 index a1e73908..00000000 Binary files a/blog-uniapp/static/c7.png and /dev/null differ diff --git a/blog-uniapp/static/c8.png b/blog-uniapp/static/c8.png deleted file mode 100644 index c32633c0..00000000 Binary files a/blog-uniapp/static/c8.png and /dev/null differ diff --git a/blog-uniapp/static/c9.png b/blog-uniapp/static/c9.png deleted file mode 100644 index 51bcf6a1..00000000 Binary files a/blog-uniapp/static/c9.png and /dev/null differ diff --git a/blog-uniapp/static/customicons.css b/blog-uniapp/static/customicons.css deleted file mode 100644 index 14ed5fa8..00000000 --- a/blog-uniapp/static/customicons.css +++ /dev/null @@ -1,20 +0,0 @@ -@font-face { - font-family: "customicons"; /* Project id 2878519 */ - src:url('/static/customicons.ttf') format('truetype'); -} - -.customicons { - font-family: "customicons" !important; -} - -.youxi:before { - content: "\e60e"; -} - -.wenjian:before { - content: "\e60f"; -} - -.zhuanfa:before { - content: "\e610"; -} diff --git a/blog-uniapp/static/customicons.ttf b/blog-uniapp/static/customicons.ttf deleted file mode 100644 index a3c8ab9f..00000000 Binary files a/blog-uniapp/static/customicons.ttf and /dev/null differ diff --git a/blog-uniapp/static/iconfont/demo.css b/blog-uniapp/static/iconfont/demo.css deleted file mode 100644 index a67054a0..00000000 --- a/blog-uniapp/static/iconfont/demo.css +++ /dev/null @@ -1,539 +0,0 @@ -/* Logo 字体 */ -@font-face { - font-family: "iconfont logo"; - src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834'); - src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834#iefix') format('embedded-opentype'), - url('https://at.alicdn.com/t/font_985780_km7mi63cihi.woff?t=1545807318834') format('woff'), - url('https://at.alicdn.com/t/font_985780_km7mi63cihi.ttf?t=1545807318834') format('truetype'), - url('https://at.alicdn.com/t/font_985780_km7mi63cihi.svg?t=1545807318834#iconfont') format('svg'); -} - -.logo { - font-family: "iconfont logo"; - font-size: 160px; - font-style: normal; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; -} - -/* tabs */ -.nav-tabs { - position: relative; -} - -.nav-tabs .nav-more { - position: absolute; - right: 0; - bottom: 0; - height: 42px; - line-height: 42px; - color: #666; -} - -#tabs { - border-bottom: 1px solid #eee; -} - -#tabs li { - cursor: pointer; - width: 100px; - height: 40px; - line-height: 40px; - text-align: center; - font-size: 16px; - border-bottom: 2px solid transparent; - position: relative; - z-index: 1; - margin-bottom: -1px; - color: #666; -} - - -#tabs .active { - border-bottom-color: #f00; - color: #222; -} - -.tab-container .content { - display: none; -} - -/* 页面布局 */ -.main { - padding: 30px 100px; - width: 960px; - margin: 0 auto; -} - -.main .logo { - color: #333; - text-align: left; - margin-bottom: 30px; - line-height: 1; - height: 110px; - margin-top: -50px; - overflow: hidden; - *zoom: 1; -} - -.main .logo a { - font-size: 160px; - color: #333; -} - -.helps { - margin-top: 40px; -} - -.helps pre { - padding: 20px; - margin: 10px 0; - border: solid 1px #e7e1cd; - background-color: #fffdef; - overflow: auto; -} - -.icon_lists { - width: 100% !important; - overflow: hidden; - *zoom: 1; -} - -.icon_lists li { - width: 100px; - margin-bottom: 10px; - margin-right: 20px; - text-align: center; - list-style: none !important; - cursor: default; -} - -.icon_lists li .code-name { - line-height: 1.2; -} - -.icon_lists .icon { - display: block; - height: 100px; - line-height: 100px; - font-size: 42px; - margin: 10px auto; - color: #333; - -webkit-transition: font-size 0.25s linear, width 0.25s linear; - -moz-transition: font-size 0.25s linear, width 0.25s linear; - transition: font-size 0.25s linear, width 0.25s linear; -} - -.icon_lists .icon:hover { - font-size: 100px; -} - -.icon_lists .svg-icon { - /* 通过设置 font-size 来改变图标大小 */ - width: 1em; - /* 图标和文字相邻时,垂直对齐 */ - vertical-align: -0.15em; - /* 通过设置 color 来改变 SVG 的颜色/fill */ - fill: currentColor; - /* path 和 stroke 溢出 viewBox 部分在 IE 下会显示 - normalize.css 中也包含这行 */ - overflow: hidden; -} - -.icon_lists li .name, -.icon_lists li .code-name { - color: #666; -} - -/* markdown 样式 */ -.markdown { - color: #666; - font-size: 14px; - line-height: 1.8; -} - -.highlight { - line-height: 1.5; -} - -.markdown img { - vertical-align: middle; - max-width: 100%; -} - -.markdown h1 { - color: #404040; - font-weight: 500; - line-height: 40px; - margin-bottom: 24px; -} - -.markdown h2, -.markdown h3, -.markdown h4, -.markdown h5, -.markdown h6 { - color: #404040; - margin: 1.6em 0 0.6em 0; - font-weight: 500; - clear: both; -} - -.markdown h1 { - font-size: 28px; -} - -.markdown h2 { - font-size: 22px; -} - -.markdown h3 { - font-size: 16px; -} - -.markdown h4 { - font-size: 14px; -} - -.markdown h5 { - font-size: 12px; -} - -.markdown h6 { - font-size: 12px; -} - -.markdown hr { - height: 1px; - border: 0; - background: #e9e9e9; - margin: 16px 0; - clear: both; -} - -.markdown p { - margin: 1em 0; -} - -.markdown>p, -.markdown>blockquote, -.markdown>.highlight, -.markdown>ol, -.markdown>ul { - width: 80%; -} - -.markdown ul>li { - list-style: circle; -} - -.markdown>ul li, -.markdown blockquote ul>li { - margin-left: 20px; - padding-left: 4px; -} - -.markdown>ul li p, -.markdown>ol li p { - margin: 0.6em 0; -} - -.markdown ol>li { - list-style: decimal; -} - -.markdown>ol li, -.markdown blockquote ol>li { - margin-left: 20px; - padding-left: 4px; -} - -.markdown code { - margin: 0 3px; - padding: 0 5px; - background: #eee; - border-radius: 3px; -} - -.markdown strong, -.markdown b { - font-weight: 600; -} - -.markdown>table { - border-collapse: collapse; - border-spacing: 0px; - empty-cells: show; - border: 1px solid #e9e9e9; - width: 95%; - margin-bottom: 24px; -} - -.markdown>table th { - white-space: nowrap; - color: #333; - font-weight: 600; -} - -.markdown>table th, -.markdown>table td { - border: 1px solid #e9e9e9; - padding: 8px 16px; - text-align: left; -} - -.markdown>table th { - background: #F7F7F7; -} - -.markdown blockquote { - font-size: 90%; - color: #999; - border-left: 4px solid #e9e9e9; - padding-left: 0.8em; - margin: 1em 0; -} - -.markdown blockquote p { - margin: 0; -} - -.markdown .anchor { - opacity: 0; - transition: opacity 0.3s ease; - margin-left: 8px; -} - -.markdown .waiting { - color: #ccc; -} - -.markdown h1:hover .anchor, -.markdown h2:hover .anchor, -.markdown h3:hover .anchor, -.markdown h4:hover .anchor, -.markdown h5:hover .anchor, -.markdown h6:hover .anchor { - opacity: 1; - display: inline-block; -} - -.markdown>br, -.markdown>p>br { - clear: both; -} - - -.hljs { - display: block; - background: white; - padding: 0.5em; - color: #333333; - overflow-x: auto; -} - -.hljs-comment, -.hljs-meta { - color: #969896; -} - -.hljs-string, -.hljs-variable, -.hljs-template-variable, -.hljs-strong, -.hljs-emphasis, -.hljs-quote { - color: #df5000; -} - -.hljs-keyword, -.hljs-selector-tag, -.hljs-type { - color: #a71d5d; -} - -.hljs-literal, -.hljs-symbol, -.hljs-bullet, -.hljs-attribute { - color: #0086b3; -} - -.hljs-section, -.hljs-name { - color: #63a35c; -} - -.hljs-tag { - color: #333333; -} - -.hljs-title, -.hljs-attr, -.hljs-selector-id, -.hljs-selector-class, -.hljs-selector-attr, -.hljs-selector-pseudo { - color: #795da3; -} - -.hljs-addition { - color: #55a532; - background-color: #eaffea; -} - -.hljs-deletion { - color: #bd2c00; - background-color: #ffecec; -} - -.hljs-link { - text-decoration: underline; -} - -/* 代码高亮 */ -/* PrismJS 1.15.0 -https://prismjs.com/download.html#themes=prism&languages=markup+css+clike+javascript */ -/** - * prism.js default theme for JavaScript, CSS and HTML - * Based on dabblet (http://dabblet.com) - * @author Lea Verou - */ -code[class*="language-"], -pre[class*="language-"] { - color: black; - background: none; - text-shadow: 0 1px white; - font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; - text-align: left; - white-space: pre; - word-spacing: normal; - word-break: normal; - word-wrap: normal; - line-height: 1.5; - - -moz-tab-size: 4; - -o-tab-size: 4; - tab-size: 4; - - -webkit-hyphens: none; - -moz-hyphens: none; - -ms-hyphens: none; - hyphens: none; -} - -pre[class*="language-"]::-moz-selection, -pre[class*="language-"] ::-moz-selection, -code[class*="language-"]::-moz-selection, -code[class*="language-"] ::-moz-selection { - text-shadow: none; - background: #b3d4fc; -} - -pre[class*="language-"]::selection, -pre[class*="language-"] ::selection, -code[class*="language-"]::selection, -code[class*="language-"] ::selection { - text-shadow: none; - background: #b3d4fc; -} - -@media print { - - code[class*="language-"], - pre[class*="language-"] { - text-shadow: none; - } -} - -/* Code blocks */ -pre[class*="language-"] { - padding: 1em; - margin: .5em 0; - overflow: auto; -} - -:not(pre)>code[class*="language-"], -pre[class*="language-"] { - background: #f5f2f0; -} - -/* Inline code */ -:not(pre)>code[class*="language-"] { - padding: .1em; - border-radius: .3em; - white-space: normal; -} - -.token.comment, -.token.prolog, -.token.doctype, -.token.cdata { - color: slategray; -} - -.token.punctuation { - color: #999; -} - -.namespace { - opacity: .7; -} - -.token.property, -.token.tag, -.token.boolean, -.token.number, -.token.constant, -.token.symbol, -.token.deleted { - color: #905; -} - -.token.selector, -.token.attr-name, -.token.string, -.token.char, -.token.builtin, -.token.inserted { - color: #690; -} - -.token.operator, -.token.entity, -.token.url, -.language-css .token.string, -.style .token.string { - color: #9a6e3a; - background: hsla(0, 0%, 100%, .5); -} - -.token.atrule, -.token.attr-value, -.token.keyword { - color: #07a; -} - -.token.function, -.token.class-name { - color: #DD4A68; -} - -.token.regex, -.token.important, -.token.variable { - color: #e90; -} - -.token.important, -.token.bold { - font-weight: bold; -} - -.token.italic { - font-style: italic; -} - -.token.entity { - cursor: help; -} diff --git a/blog-uniapp/static/iconfont/demo_index.html b/blog-uniapp/static/iconfont/demo_index.html deleted file mode 100644 index 089683f4..00000000 --- a/blog-uniapp/static/iconfont/demo_index.html +++ /dev/null @@ -1,3340 +0,0 @@ - - - - - iconfont Demo - - - - - - - - - - - - - -
-

- - -

- -
-
-
    - -
  • - -
    apk
    -
    
    -
  • - -
  • - -
    debian
    -
    
    -
  • - -
  • - -
    JavaScript
    -
    
    -
  • - -
  • - -
    play-next
    -
    
    -
  • - -
  • - -
    play
    -
    
    -
  • - -
  • - -
    playlist
    -
    
    -
  • - -
  • - -
    play-previous
    -
    
    -
  • - -
  • - -
    rewind-forward
    -
    
    -
  • - -
  • - -
    rewind-back
    -
    
    -
  • - -
  • - -
    reload-2
    -
    
    -
  • - -
  • - -
    repeat
    -
    
    -
  • - -
  • - -
    shuffle
    -
    
    -
  • - -
  • - -
    sound-on
    -
    
    -
  • - -
  • - -
    sound-off
    -
    
    -
  • - -
  • - -
    pause
    -
    
    -
  • - -
  • - -
    back
    -
    
    -
  • - -
  • - -
    folder-3
    -
    
    -
  • - -
  • - -
    adobe photoshop
    -
    
    -
  • - -
  • - -
    mkv
    -
    
    -
  • - -
  • - -
    mp4
    -
    
    -
  • - -
  • - -
    txt
    -
    
    -
  • - -
  • - -
    txt
    -
    
    -
  • - -
  • - -
    jsx
    -
    
    -
  • - -
  • - -
    YAML
    -
    
    -
  • - -
  • - -
    shell
    -
    
    -
  • - -
  • - -
    script
    -
    
    -
  • - -
  • - -
    Ruby
    -
    
    -
  • - -
  • - -
    word
    -
    
    -
  • - -
  • - -
    yellowFolder
    -
    
    -
  • - -
  • - -
    outlook
    -
    
    -
  • - -
  • - -
    powerpoint
    -
    
    -
  • - -
  • - -
    audio
    -
    
    -
  • - -
  • - -
    3d
    -
    
    -
  • - -
  • - -
    autohotkey
    -
    
    -
  • - -
  • - -
    autoit
    -
    
    -
  • - -
  • - -
    assembly
    -
    
    -
  • - -
  • - -
    android
    -
    
    -
  • - -
  • - -
    applescript
    -
    
    -
  • - -
  • - -
    actionscript
    -
    
    -
  • - -
  • - -
    changelog
    -
    
    -
  • - -
  • - -
    circleci
    -
    
    -
  • - -
  • - -
    circleci_light
    -
    
    -
  • - -
  • - -
    cmake
    -
    
    -
  • - -
  • - -
    clojure
    -
    
    -
  • - -
  • - -
    babel
    -
    
    -
  • - -
  • - -
    blink
    -
    
    -
  • - -
  • - -
    blink_light
    -
    
    -
  • - -
  • - -
    zip
    -
    
    -
  • - -
  • - -
    browserlist
    -
    
    -
  • - -
  • - -
    c
    -
    
    -
  • - -
  • - -
    edge
    -
    
    -
  • - -
  • - -
    ejs
    -
    
    -
  • - -
  • - -
    email
    -
    
    -
  • - -
  • - -
    erlang
    -
    
    -
  • - -
  • - -
    exe
    -
    
    -
  • - -
  • - -
    firebase
    -
    
    -
  • - -
  • - -
    favicon
    -
    
    -
  • - -
  • - -
    eslint
    -
    
    -
  • - -
  • - -
    coffee
    -
    
    -
  • - -
  • - -
    file
    -
    
    -
  • - -
  • - -
    console
    -
    
    -
  • - -
  • - -
    cpp
    -
    
    -
  • - -
  • - -
    contributing
    -
    
    -
  • - -
  • - -
    csharp
    -
    
    -
  • - -
  • - -
    css
    -
    
    -
  • - -
  • - -
    diff
    -
    
    -
  • - -
  • - -
    database
    -
    
    -
  • - -
  • - -
    document
    -
    
    -
  • - -
  • - -
    django
    -
    
    -
  • - -
  • - -
    dart
    -
    
    -
  • - -
  • - -
    folder-audio
    -
    
    -
  • - -
  • - -
    groovy
    -
    
    -
  • - -
  • - -
    gulp
    -
    
    -
  • - -
  • - -
    haskell
    -
    
    -
  • - -
  • - -
    handlebars
    -
    
    -
  • - -
  • - -
    html
    -
    
    -
  • - -
  • - -
    h
    -
    
    -
  • - -
  • - -
    font
    -
    
    -
  • - -
  • - -
    git
    -
    
    -
  • - -
  • - -
    gradle
    -
    
    -
  • - -
  • - -
    go
    -
    
    -
  • - -
  • - -
    go-mod
    -
    
    -
  • - -
  • - -
    gitlab
    -
    
    -
  • - -
  • - -
    haml
    -
    
    -
  • - -
  • - -
    javascript-map
    -
    
    -
  • - -
  • - -
    json
    -
    
    -
  • - -
  • - -
    lib
    -
    
    -
  • - -
  • - -
    less
    -
    
    -
  • - -
  • - -
    laravel
    -
    
    -
  • - -
  • - -
    lock
    -
    
    -
  • - -
  • - -
    log
    -
    
    -
  • - -
  • - -
    lua
    -
    
    -
  • - -
  • - -
    markdown
    -
    
    -
  • - -
  • - -
    makefile
    -
    
    -
  • - -
  • - -
    livescript
    -
    
    -
  • - -
  • - -
    mdx
    -
    
    -
  • - -
  • - -
    http
    -
    
    -
  • - -
  • - -
    image
    -
    
    -
  • - -
  • - -
    i18n
    -
    
    -
  • - -
  • - -
    java
    -
    
    -
  • - -
  • - -
    javascript
    -
    
    -
  • - -
  • - -
    ionic
    -
    
    -
  • - -
  • - -
    php
    -
    
    -
  • - -
  • - -
    powerpoint
    -
    
    -
  • - -
  • - -
    powershell
    -
    
    -
  • - -
  • - -
    nodejs
    -
    
    -
  • - -
  • - -
    npm
    -
    
    -
  • - -
  • - -
    nunjucks
    -
    
    -
  • - -
  • - -
    nuxt
    -
    
    -
  • - -
  • - -
    pug
    -
    
    -
  • - -
  • - -
    pdf
    -
    
    -
  • - -
  • - -
    postcss
    -
    
    -
  • - -
  • - -
    react
    -
    
    -
  • - -
  • - -
    react_ts
    -
    
    -
  • - -
  • - -
    readme
    -
    
    -
  • - -
  • - -
    python
    -
    
    -
  • - -
  • - -
    r
    -
    
    -
  • - -
  • - -
    rust
    -
    
    -
  • - -
  • - -
    raml
    -
    
    -
  • - -
  • - -
    svg
    -
    
    -
  • - -
  • - -
    svelte
    -
    
    -
  • - -
  • - -
    typescript
    -
    
    -
  • - -
  • - -
    url
    -
    
    -
  • - -
  • - -
    table
    -
    
    -
  • - -
  • - -
    tex
    -
    
    -
  • - -
  • - -
    todo
    -
    
    -
  • - -
  • - -
    word
    -
    
    -
  • - -
  • - -
    xaml
    -
    
    -
  • - -
  • - -
    xml
    -
    
    -
  • - -
  • - -
    vim
    -
    
    -
  • - -
  • - -
    virtual
    -
    
    -
  • - -
  • - -
    visualstudio
    -
    
    -
  • - -
  • - -
    vscode
    -
    
    -
  • - -
  • - -
    vue
    -
    
    -
  • - -
  • - -
    yarn
    -
    
    -
  • - -
  • - -
    zip
    -
    
    -
  • - -
  • - -
    yaml
    -
    
    -
  • - -
-
-

Unicode 引用

-
- -

Unicode 是字体在网页端最原始的应用方式,特点是:

-
    -
  • 支持按字体的方式去动态调整图标大小,颜色等等。
  • -
  • 默认情况下不支持多色,直接添加多色图标会自动去色。
  • -
-
-

注意:新版 iconfont 支持两种方式引用多色图标:SVG symbol 引用方式和彩色字体图标模式。(使用彩色字体图标需要在「编辑项目」中开启「彩色」选项后并重新生成。)

-
-

Unicode 使用步骤如下:

-

第一步:拷贝项目下面生成的 @font-face

-
@font-face {
-  font-family: 'iconfont';
-  src: url('iconfont.woff2?t=1662696995477') format('woff2'),
-       url('iconfont.woff?t=1662696995477') format('woff'),
-       url('iconfont.ttf?t=1662696995477') format('truetype'),
-       url('iconfont.svg?t=1662696995477#iconfont') format('svg');
-}
-
-

第二步:定义使用 iconfont 的样式

-
.iconfont {
-  font-family: "iconfont" !important;
-  font-size: 16px;
-  font-style: normal;
-  -webkit-font-smoothing: antialiased;
-  -moz-osx-font-smoothing: grayscale;
-}
-
-

第三步:挑选相应图标并获取字体编码,应用于页面

-
-<span class="iconfont">&#x33;</span>
-
-
-

"iconfont" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。

-
-
-
-
-
    - -
  • - -
    - apk -
    -
    .icon-apk -
    -
  • - -
  • - -
    - debian -
    -
    .icon-deb -
    -
  • - -
  • - -
    - JavaScript -
    -
    .icon-JavaScript -
    -
  • - -
  • - -
    - play-next -
    -
    .icon-play-next -
    -
  • - -
  • - -
    - play -
    -
    .icon-play -
    -
  • - -
  • - -
    - playlist -
    -
    .icon-playlist -
    -
  • - -
  • - -
    - play-previous -
    -
    .icon-play-prev -
    -
  • - -
  • - -
    - rewind-forward -
    -
    .icon-rewind-forward -
    -
  • - -
  • - -
    - rewind-back -
    -
    .icon-rewind-back -
    -
  • - -
  • - -
    - reload-2 -
    -
    .icon-reload- -
    -
  • - -
  • - -
    - repeat -
    -
    .icon-repeat -
    -
  • - -
  • - -
    - shuffle -
    -
    .icon-shuffle -
    -
  • - -
  • - -
    - sound-on -
    -
    .icon-volumn -
    -
  • - -
  • - -
    - sound-off -
    -
    .icon-sound-off -
    -
  • - -
  • - -
    - pause -
    -
    .icon-play-pause -
    -
  • - -
  • - -
    - back -
    -
    .icon-back -
    -
  • - -
  • - -
    - folder-3 -
    -
    .icon-folder -
    -
  • - -
  • - -
    - adobe photoshop -
    -
    .icon-psd -
    -
  • - -
  • - -
    - mkv -
    -
    .icon-mkv -
    -
  • - -
  • - -
    - mp4 -
    -
    .icon-mp4 -
    -
  • - -
  • - -
    - txt -
    -
    .icon-txt -
    -
  • - -
  • - -
    - txt -
    -
    .icon-text -
    -
  • - -
  • - -
    - jsx -
    -
    .icon-jsx -
    -
  • - -
  • - -
    - YAML -
    -
    .icon-yml -
    -
  • - -
  • - -
    - shell -
    -
    .icon-sh -
    -
  • - -
  • - -
    - script -
    -
    .icon-script -
    -
  • - -
  • - -
    - Ruby -
    -
    .icon-rb -
    -
  • - -
  • - -
    - word -
    -
    .icon-docx -
    -
  • - -
  • - -
    - yellowFolder -
    -
    .icon-yellowFolder -
    -
  • - -
  • - -
    - outlook -
    -
    .icon-outlook -
    -
  • - -
  • - -
    - powerpoint -
    -
    .icon-ppt -
    -
  • - -
  • - -
    - audio -
    -
    .icon-audio -
    -
  • - -
  • - -
    - 3d -
    -
    .icon-d -
    -
  • - -
  • - -
    - autohotkey -
    -
    .icon-autohotkey -
    -
  • - -
  • - -
    - autoit -
    -
    .icon-autoit -
    -
  • - -
  • - -
    - assembly -
    -
    .icon-assembly -
    -
  • - -
  • - -
    - android -
    -
    .icon-android -
    -
  • - -
  • - -
    - applescript -
    -
    .icon-applescript -
    -
  • - -
  • - -
    - actionscript -
    -
    .icon-actionscript -
    -
  • - -
  • - -
    - changelog -
    -
    .icon-changelog -
    -
  • - -
  • - -
    - circleci -
    -
    .icon-circleci -
    -
  • - -
  • - -
    - circleci_light -
    -
    .icon-circleci_light -
    -
  • - -
  • - -
    - cmake -
    -
    .icon-cmake -
    -
  • - -
  • - -
    - clojure -
    -
    .icon-clojure -
    -
  • - -
  • - -
    - babel -
    -
    .icon-babel -
    -
  • - -
  • - -
    - blink -
    -
    .icon-blink -
    -
  • - -
  • - -
    - blink_light -
    -
    .icon-blink_light -
    -
  • - -
  • - -
    - zip -
    -
    .icon-archive -
    -
  • - -
  • - -
    - browserlist -
    -
    .icon-browserlist -
    -
  • - -
  • - -
    - c -
    -
    .icon-c -
    -
  • - -
  • - -
    - edge -
    -
    .icon-edge -
    -
  • - -
  • - -
    - ejs -
    -
    .icon-ejs -
    -
  • - -
  • - -
    - email -
    -
    .icon-email -
    -
  • - -
  • - -
    - erlang -
    -
    .icon-erlang -
    -
  • - -
  • - -
    - exe -
    -
    .icon-exe -
    -
  • - -
  • - -
    - firebase -
    -
    .icon-firebase -
    -
  • - -
  • - -
    - favicon -
    -
    .icon-favicon -
    -
  • - -
  • - -
    - eslint -
    -
    .icon-eslint -
    -
  • - -
  • - -
    - coffee -
    -
    .icon-coffee -
    -
  • - -
  • - -
    - file -
    -
    .icon-file -
    -
  • - -
  • - -
    - console -
    -
    .icon-console -
    -
  • - -
  • - -
    - cpp -
    -
    .icon-cpp -
    -
  • - -
  • - -
    - contributing -
    -
    .icon-contributing -
    -
  • - -
  • - -
    - csharp -
    -
    .icon-csharp -
    -
  • - -
  • - -
    - css -
    -
    .icon-css -
    -
  • - -
  • - -
    - diff -
    -
    .icon-diff -
    -
  • - -
  • - -
    - database -
    -
    .icon-sql -
    -
  • - -
  • - -
    - document -
    -
    .icon-document -
    -
  • - -
  • - -
    - django -
    -
    .icon-django -
    -
  • - -
  • - -
    - dart -
    -
    .icon-dart -
    -
  • - -
  • - -
    - folder-audio -
    -
    .icon-folder-audio -
    -
  • - -
  • - -
    - groovy -
    -
    .icon-groovy -
    -
  • - -
  • - -
    - gulp -
    -
    .icon-gulp -
    -
  • - -
  • - -
    - haskell -
    -
    .icon-haskell -
    -
  • - -
  • - -
    - handlebars -
    -
    .icon-handlebars -
    -
  • - -
  • - -
    - html -
    -
    .icon-html -
    -
  • - -
  • - -
    - h -
    -
    .icon-h -
    -
  • - -
  • - -
    - font -
    -
    .icon-font -
    -
  • - -
  • - -
    - git -
    -
    .icon-git -
    -
  • - -
  • - -
    - gradle -
    -
    .icon-gradle -
    -
  • - -
  • - -
    - go -
    -
    .icon-go -
    -
  • - -
  • - -
    - go-mod -
    -
    .icon-go-mod -
    -
  • - -
  • - -
    - gitlab -
    -
    .icon-gitlab -
    -
  • - -
  • - -
    - haml -
    -
    .icon-haml -
    -
  • - -
  • - -
    - javascript-map -
    -
    .icon-map -
    -
  • - -
  • - -
    - json -
    -
    .icon-json -
    -
  • - -
  • - -
    - lib -
    -
    .icon-lib -
    -
  • - -
  • - -
    - less -
    -
    .icon-less -
    -
  • - -
  • - -
    - laravel -
    -
    .icon-laravel -
    -
  • - -
  • - -
    - lock -
    -
    .icon-lock -
    -
  • - -
  • - -
    - log -
    -
    .icon-log -
    -
  • - -
  • - -
    - lua -
    -
    .icon-lua -
    -
  • - -
  • - -
    - markdown -
    -
    .icon-md -
    -
  • - -
  • - -
    - makefile -
    -
    .icon-makefile -
    -
  • - -
  • - -
    - livescript -
    -
    .icon-livescript -
    -
  • - -
  • - -
    - mdx -
    -
    .icon-mdx -
    -
  • - -
  • - -
    - http -
    -
    .icon-http -
    -
  • - -
  • - -
    - image -
    -
    .icon-image -
    -
  • - -
  • - -
    - i18n -
    -
    .icon-in -
    -
  • - -
  • - -
    - java -
    -
    .icon-java -
    -
  • - -
  • - -
    - javascript -
    -
    .icon-js -
    -
  • - -
  • - -
    - ionic -
    -
    .icon-ionic -
    -
  • - -
  • - -
    - php -
    -
    .icon-php -
    -
  • - -
  • - -
    - powerpoint -
    -
    .icon-powerpoint1 -
    -
  • - -
  • - -
    - powershell -
    -
    .icon-ps1 -
    -
  • - -
  • - -
    - nodejs -
    -
    .icon-node -
    -
  • - -
  • - -
    - npm -
    -
    .icon-npm -
    -
  • - -
  • - -
    - nunjucks -
    -
    .icon-nunjucks -
    -
  • - -
  • - -
    - nuxt -
    -
    .icon-nuxt -
    -
  • - -
  • - -
    - pug -
    -
    .icon-pug -
    -
  • - -
  • - -
    - pdf -
    -
    .icon-pdf -
    -
  • - -
  • - -
    - postcss -
    -
    .icon-postcss -
    -
  • - -
  • - -
    - react -
    -
    .icon-react -
    -
  • - -
  • - -
    - react_ts -
    -
    .icon-tsx -
    -
  • - -
  • - -
    - readme -
    -
    .icon-readme -
    -
  • - -
  • - -
    - python -
    -
    .icon-py -
    -
  • - -
  • - -
    - r -
    -
    .icon-r -
    -
  • - -
  • - -
    - rust -
    -
    .icon-rust -
    -
  • - -
  • - -
    - raml -
    -
    .icon-raml -
    -
  • - -
  • - -
    - svg -
    -
    .icon-svg -
    -
  • - -
  • - -
    - svelte -
    -
    .icon-svelte -
    -
  • - -
  • - -
    - typescript -
    -
    .icon-ts -
    -
  • - -
  • - -
    - url -
    -
    .icon-url -
    -
  • - -
  • - -
    - table -
    -
    .icon-table -
    -
  • - -
  • - -
    - tex -
    -
    .icon-tex -
    -
  • - -
  • - -
    - todo -
    -
    .icon-todo -
    -
  • - -
  • - -
    - word -
    -
    .icon-word1 -
    -
  • - -
  • - -
    - xaml -
    -
    .icon-xaml -
    -
  • - -
  • - -
    - xml -
    -
    .icon-xml -
    -
  • - -
  • - -
    - vim -
    -
    .icon-vim -
    -
  • - -
  • - -
    - virtual -
    -
    .icon-virtual -
    -
  • - -
  • - -
    - visualstudio -
    -
    .icon-visualstudio -
    -
  • - -
  • - -
    - vscode -
    -
    .icon-vscode -
    -
  • - -
  • - -
    - vue -
    -
    .icon-vue -
    -
  • - -
  • - -
    - yarn -
    -
    .icon-yarn -
    -
  • - -
  • - -
    - zip -
    -
    .icon-zip -
    -
  • - -
  • - -
    - yaml -
    -
    .icon-yaml -
    -
  • - -
-
-

font-class 引用

-
- -

font-class 是 Unicode 使用方式的一种变种,主要是解决 Unicode 书写不直观,语意不明确的问题。

-

与 Unicode 使用方式相比,具有如下特点:

-
    -
  • 相比于 Unicode 语意明确,书写更直观。可以很容易分辨这个 icon 是什么。
  • -
  • 因为使用 class 来定义图标,所以当要替换图标时,只需要修改 class 里面的 Unicode 引用。
  • -
-

使用步骤如下:

-

第一步:引入项目下面生成的 fontclass 代码:

-
<link rel="stylesheet" href="./iconfont.css">
-
-

第二步:挑选相应图标并获取类名,应用于页面:

-
<span class="iconfont icon-xxx"></span>
-
-
-

" - iconfont" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。

-
-
-
-
-
    - -
  • - -
    apk
    -
    #icon-apk
    -
  • - -
  • - -
    debian
    -
    #icon-deb
    -
  • - -
  • - -
    JavaScript
    -
    #icon-JavaScript
    -
  • - -
  • - -
    play-next
    -
    #icon-play-next
    -
  • - -
  • - -
    play
    -
    #icon-play
    -
  • - -
  • - -
    playlist
    -
    #icon-playlist
    -
  • - -
  • - -
    play-previous
    -
    #icon-play-prev
    -
  • - -
  • - -
    rewind-forward
    -
    #icon-rewind-forward
    -
  • - -
  • - -
    rewind-back
    -
    #icon-rewind-back
    -
  • - -
  • - -
    reload-2
    -
    #icon-reload-
    -
  • - -
  • - -
    repeat
    -
    #icon-repeat
    -
  • - -
  • - -
    shuffle
    -
    #icon-shuffle
    -
  • - -
  • - -
    sound-on
    -
    #icon-volumn
    -
  • - -
  • - -
    sound-off
    -
    #icon-sound-off
    -
  • - -
  • - -
    pause
    -
    #icon-play-pause
    -
  • - -
  • - -
    back
    -
    #icon-back
    -
  • - -
  • - -
    folder-3
    -
    #icon-folder
    -
  • - -
  • - -
    adobe photoshop
    -
    #icon-psd
    -
  • - -
  • - -
    mkv
    -
    #icon-mkv
    -
  • - -
  • - -
    mp4
    -
    #icon-mp4
    -
  • - -
  • - -
    txt
    -
    #icon-txt
    -
  • - -
  • - -
    txt
    -
    #icon-text
    -
  • - -
  • - -
    jsx
    -
    #icon-jsx
    -
  • - -
  • - -
    YAML
    -
    #icon-yml
    -
  • - -
  • - -
    shell
    -
    #icon-sh
    -
  • - -
  • - -
    script
    -
    #icon-script
    -
  • - -
  • - -
    Ruby
    -
    #icon-rb
    -
  • - -
  • - -
    word
    -
    #icon-docx
    -
  • - -
  • - -
    yellowFolder
    -
    #icon-yellowFolder
    -
  • - -
  • - -
    outlook
    -
    #icon-outlook
    -
  • - -
  • - -
    powerpoint
    -
    #icon-ppt
    -
  • - -
  • - -
    audio
    -
    #icon-audio
    -
  • - -
  • - -
    3d
    -
    #icon-d
    -
  • - -
  • - -
    autohotkey
    -
    #icon-autohotkey
    -
  • - -
  • - -
    autoit
    -
    #icon-autoit
    -
  • - -
  • - -
    assembly
    -
    #icon-assembly
    -
  • - -
  • - -
    android
    -
    #icon-android
    -
  • - -
  • - -
    applescript
    -
    #icon-applescript
    -
  • - -
  • - -
    actionscript
    -
    #icon-actionscript
    -
  • - -
  • - -
    changelog
    -
    #icon-changelog
    -
  • - -
  • - -
    circleci
    -
    #icon-circleci
    -
  • - -
  • - -
    circleci_light
    -
    #icon-circleci_light
    -
  • - -
  • - -
    cmake
    -
    #icon-cmake
    -
  • - -
  • - -
    clojure
    -
    #icon-clojure
    -
  • - -
  • - -
    babel
    -
    #icon-babel
    -
  • - -
  • - -
    blink
    -
    #icon-blink
    -
  • - -
  • - -
    blink_light
    -
    #icon-blink_light
    -
  • - -
  • - -
    zip
    -
    #icon-archive
    -
  • - -
  • - -
    browserlist
    -
    #icon-browserlist
    -
  • - -
  • - -
    c
    -
    #icon-c
    -
  • - -
  • - -
    edge
    -
    #icon-edge
    -
  • - -
  • - -
    ejs
    -
    #icon-ejs
    -
  • - -
  • - -
    email
    -
    #icon-email
    -
  • - -
  • - -
    erlang
    -
    #icon-erlang
    -
  • - -
  • - -
    exe
    -
    #icon-exe
    -
  • - -
  • - -
    firebase
    -
    #icon-firebase
    -
  • - -
  • - -
    favicon
    -
    #icon-favicon
    -
  • - -
  • - -
    eslint
    -
    #icon-eslint
    -
  • - -
  • - -
    coffee
    -
    #icon-coffee
    -
  • - -
  • - -
    file
    -
    #icon-file
    -
  • - -
  • - -
    console
    -
    #icon-console
    -
  • - -
  • - -
    cpp
    -
    #icon-cpp
    -
  • - -
  • - -
    contributing
    -
    #icon-contributing
    -
  • - -
  • - -
    csharp
    -
    #icon-csharp
    -
  • - -
  • - -
    css
    -
    #icon-css
    -
  • - -
  • - -
    diff
    -
    #icon-diff
    -
  • - -
  • - -
    database
    -
    #icon-sql
    -
  • - -
  • - -
    document
    -
    #icon-document
    -
  • - -
  • - -
    django
    -
    #icon-django
    -
  • - -
  • - -
    dart
    -
    #icon-dart
    -
  • - -
  • - -
    folder-audio
    -
    #icon-folder-audio
    -
  • - -
  • - -
    groovy
    -
    #icon-groovy
    -
  • - -
  • - -
    gulp
    -
    #icon-gulp
    -
  • - -
  • - -
    haskell
    -
    #icon-haskell
    -
  • - -
  • - -
    handlebars
    -
    #icon-handlebars
    -
  • - -
  • - -
    html
    -
    #icon-html
    -
  • - -
  • - -
    h
    -
    #icon-h
    -
  • - -
  • - -
    font
    -
    #icon-font
    -
  • - -
  • - -
    git
    -
    #icon-git
    -
  • - -
  • - -
    gradle
    -
    #icon-gradle
    -
  • - -
  • - -
    go
    -
    #icon-go
    -
  • - -
  • - -
    go-mod
    -
    #icon-go-mod
    -
  • - -
  • - -
    gitlab
    -
    #icon-gitlab
    -
  • - -
  • - -
    haml
    -
    #icon-haml
    -
  • - -
  • - -
    javascript-map
    -
    #icon-map
    -
  • - -
  • - -
    json
    -
    #icon-json
    -
  • - -
  • - -
    lib
    -
    #icon-lib
    -
  • - -
  • - -
    less
    -
    #icon-less
    -
  • - -
  • - -
    laravel
    -
    #icon-laravel
    -
  • - -
  • - -
    lock
    -
    #icon-lock
    -
  • - -
  • - -
    log
    -
    #icon-log
    -
  • - -
  • - -
    lua
    -
    #icon-lua
    -
  • - -
  • - -
    markdown
    -
    #icon-md
    -
  • - -
  • - -
    makefile
    -
    #icon-makefile
    -
  • - -
  • - -
    livescript
    -
    #icon-livescript
    -
  • - -
  • - -
    mdx
    -
    #icon-mdx
    -
  • - -
  • - -
    http
    -
    #icon-http
    -
  • - -
  • - -
    image
    -
    #icon-image
    -
  • - -
  • - -
    i18n
    -
    #icon-in
    -
  • - -
  • - -
    java
    -
    #icon-java
    -
  • - -
  • - -
    javascript
    -
    #icon-js
    -
  • - -
  • - -
    ionic
    -
    #icon-ionic
    -
  • - -
  • - -
    php
    -
    #icon-php
    -
  • - -
  • - -
    powerpoint
    -
    #icon-powerpoint1
    -
  • - -
  • - -
    powershell
    -
    #icon-ps1
    -
  • - -
  • - -
    nodejs
    -
    #icon-node
    -
  • - -
  • - -
    npm
    -
    #icon-npm
    -
  • - -
  • - -
    nunjucks
    -
    #icon-nunjucks
    -
  • - -
  • - -
    nuxt
    -
    #icon-nuxt
    -
  • - -
  • - -
    pug
    -
    #icon-pug
    -
  • - -
  • - -
    pdf
    -
    #icon-pdf
    -
  • - -
  • - -
    postcss
    -
    #icon-postcss
    -
  • - -
  • - -
    react
    -
    #icon-react
    -
  • - -
  • - -
    react_ts
    -
    #icon-tsx
    -
  • - -
  • - -
    readme
    -
    #icon-readme
    -
  • - -
  • - -
    python
    -
    #icon-py
    -
  • - -
  • - -
    r
    -
    #icon-r
    -
  • - -
  • - -
    rust
    -
    #icon-rust
    -
  • - -
  • - -
    raml
    -
    #icon-raml
    -
  • - -
  • - -
    svg
    -
    #icon-svg
    -
  • - -
  • - -
    svelte
    -
    #icon-svelte
    -
  • - -
  • - -
    typescript
    -
    #icon-ts
    -
  • - -
  • - -
    url
    -
    #icon-url
    -
  • - -
  • - -
    table
    -
    #icon-table
    -
  • - -
  • - -
    tex
    -
    #icon-tex
    -
  • - -
  • - -
    todo
    -
    #icon-todo
    -
  • - -
  • - -
    word
    -
    #icon-word1
    -
  • - -
  • - -
    xaml
    -
    #icon-xaml
    -
  • - -
  • - -
    xml
    -
    #icon-xml
    -
  • - -
  • - -
    vim
    -
    #icon-vim
    -
  • - -
  • - -
    virtual
    -
    #icon-virtual
    -
  • - -
  • - -
    visualstudio
    -
    #icon-visualstudio
    -
  • - -
  • - -
    vscode
    -
    #icon-vscode
    -
  • - -
  • - -
    vue
    -
    #icon-vue
    -
  • - -
  • - -
    yarn
    -
    #icon-yarn
    -
  • - -
  • - -
    zip
    -
    #icon-zip
    -
  • - -
  • - -
    yaml
    -
    #icon-yaml
    -
  • - -
-
-

Symbol 引用

-
- -

这是一种全新的使用方式,应该说这才是未来的主流,也是平台目前推荐的用法。相关介绍可以参考这篇文章 - 这种用法其实是做了一个 SVG 的集合,与另外两种相比具有如下特点:

-
    -
  • 支持多色图标了,不再受单色限制。
  • -
  • 通过一些技巧,支持像字体那样,通过 font-size, color 来调整样式。
  • -
  • 兼容性较差,支持 IE9+,及现代浏览器。
  • -
  • 浏览器渲染 SVG 的性能一般,还不如 png。
  • -
-

使用步骤如下:

-

第一步:引入项目下面生成的 symbol 代码:

-
<script src="./iconfont.js"></script>
-
-

第二步:加入通用 CSS 代码(引入一次就行):

-
<style>
-.icon {
-  width: 1em;
-  height: 1em;
-  vertical-align: -0.15em;
-  fill: currentColor;
-  overflow: hidden;
-}
-</style>
-
-

第三步:挑选相应图标并获取类名,应用于页面:

-
<svg class="icon" aria-hidden="true">
-  <use xlink:href="#icon-xxx"></use>
-</svg>
-
-
-
- -
-
- - - diff --git a/blog-uniapp/static/iconfont/iconfont.css b/blog-uniapp/static/iconfont/iconfont.css deleted file mode 100644 index 89b68658..00000000 --- a/blog-uniapp/static/iconfont/iconfont.css +++ /dev/null @@ -1,564 +0,0 @@ -@font-face { - font-family: "iconfont"; /* Project id 3291405 */ - src: url('iconfont.woff2?t=1662696995477') format('woff2'), - url('iconfont.woff?t=1662696995477') format('woff'), - url('iconfont.ttf?t=1662696995477') format('truetype'), - url('iconfont.svg?t=1662696995477#iconfont') format('svg'); -} - -.iconfont { - font-family: "iconfont" !important; - font-size: 16px; - font-style: normal; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; -} - -.icon-apk:before { - content: "\e68d"; -} - -.icon-deb:before { - content: "\eb74"; -} - -.icon-JavaScript:before { - content: "\e704"; -} - -.icon-play-next:before { - content: "\e850"; -} - -.icon-play:before { - content: "\e851"; -} - -.icon-playlist:before { - content: "\e852"; -} - -.icon-play-prev:before { - content: "\e853"; -} - -.icon-rewind-forward:before { - content: "\e854"; -} - -.icon-rewind-back:before { - content: "\e855"; -} - -.icon-reload-:before { - content: "\e856"; -} - -.icon-repeat:before { - content: "\e857"; -} - -.icon-shuffle:before { - content: "\e858"; -} - -.icon-volumn:before { - content: "\e859"; -} - -.icon-sound-off:before { - content: "\e85a"; -} - -.icon-play-pause:before { - content: "\e863"; -} - -.icon-back:before { - content: "\e71c"; -} - -.icon-folder:before { - content: "\e722"; -} - -.icon-psd:before { - content: "\e8c1"; -} - -.icon-mkv:before { - content: "\e64c"; -} - -.icon-mp4:before { - content: "\e6c3"; -} - -.icon-txt:before { - content: "\e6c8"; -} - -.icon-text:before { - content: "\e8c2"; -} - -.icon-jsx:before { - content: "\e64b"; -} - -.icon-yml:before { - content: "\e64a"; -} - -.icon-sh:before { - content: "\e68c"; -} - -.icon-script:before { - content: "\e88b"; -} - -.icon-rb:before { - content: "\e6a7"; -} - -.icon-docx:before { - content: "\e601"; -} - -.icon-yellowFolder:before { - content: "\e602"; -} - -.icon-outlook:before { - content: "\e608"; -} - -.icon-ppt:before { - content: "\e60a"; -} - -.icon-audio:before { - content: "\e623"; -} - -.icon-d:before { - content: "\e624"; -} - -.icon-autohotkey:before { - content: "\e625"; -} - -.icon-autoit:before { - content: "\e626"; -} - -.icon-assembly:before { - content: "\e627"; -} - -.icon-android:before { - content: "\e628"; -} - -.icon-applescript:before { - content: "\e629"; -} - -.icon-actionscript:before { - content: "\e62a"; -} - -.icon-changelog:before { - content: "\e62b"; -} - -.icon-circleci:before { - content: "\e62c"; -} - -.icon-circleci_light:before { - content: "\e62d"; -} - -.icon-cmake:before { - content: "\e62e"; -} - -.icon-clojure:before { - content: "\e62f"; -} - -.icon-babel:before { - content: "\e630"; -} - -.icon-blink:before { - content: "\e631"; -} - -.icon-blink_light:before { - content: "\e632"; -} - -.icon-archive:before { - content: "\eb75"; -} - -.icon-browserlist:before { - content: "\e633"; -} - -.icon-c:before { - content: "\e634"; -} - -.icon-edge:before { - content: "\e635"; -} - -.icon-ejs:before { - content: "\e636"; -} - -.icon-email:before { - content: "\e637"; -} - -.icon-erlang:before { - content: "\e638"; -} - -.icon-exe:before { - content: "\e639"; -} - -.icon-firebase:before { - content: "\e63a"; -} - -.icon-favicon:before { - content: "\e63b"; -} - -.icon-eslint:before { - content: "\e63c"; -} - -.icon-coffee:before { - content: "\e63d"; -} - -.icon-file:before { - content: "\e63e"; -} - -.icon-console:before { - content: "\e63f"; -} - -.icon-cpp:before { - content: "\e640"; -} - -.icon-contributing:before { - content: "\e641"; -} - -.icon-csharp:before { - content: "\e642"; -} - -.icon-css:before { - content: "\e643"; -} - -.icon-diff:before { - content: "\e644"; -} - -.icon-sql:before { - content: "\e645"; -} - -.icon-document:before { - content: "\e646"; -} - -.icon-django:before { - content: "\e647"; -} - -.icon-dart:before { - content: "\e648"; -} - -.icon-folder-audio:before { - content: "\e649"; -} - -.icon-groovy:before { - content: "\e652"; -} - -.icon-gulp:before { - content: "\e653"; -} - -.icon-haskell:before { - content: "\e654"; -} - -.icon-handlebars:before { - content: "\e655"; -} - -.icon-html:before { - content: "\e656"; -} - -.icon-h:before { - content: "\e657"; -} - -.icon-font:before { - content: "\e658"; -} - -.icon-git:before { - content: "\e659"; -} - -.icon-gradle:before { - content: "\e65a"; -} - -.icon-go:before { - content: "\e65b"; -} - -.icon-go-mod:before { - content: "\e65c"; -} - -.icon-gitlab:before { - content: "\e65d"; -} - -.icon-haml:before { - content: "\e65e"; -} - -.icon-map:before { - content: "\e65f"; -} - -.icon-json:before { - content: "\e660"; -} - -.icon-lib:before { - content: "\e662"; -} - -.icon-less:before { - content: "\e663"; -} - -.icon-laravel:before { - content: "\e664"; -} - -.icon-lock:before { - content: "\e665"; -} - -.icon-log:before { - content: "\e666"; -} - -.icon-lua:before { - content: "\e667"; -} - -.icon-md:before { - content: "\e668"; -} - -.icon-makefile:before { - content: "\e669"; -} - -.icon-livescript:before { - content: "\e66a"; -} - -.icon-mdx:before { - content: "\e66b"; -} - -.icon-http:before { - content: "\e66c"; -} - -.icon-image:before { - content: "\e66d"; -} - -.icon-in:before { - content: "\e66e"; -} - -.icon-java:before { - content: "\e66f"; -} - -.icon-js:before { - content: "\e670"; -} - -.icon-ionic:before { - content: "\e671"; -} - -.icon-php:before { - content: "\e67e"; -} - -.icon-powerpoint1:before { - content: "\e67f"; -} - -.icon-ps1:before { - content: "\e680"; -} - -.icon-node:before { - content: "\e683"; -} - -.icon-npm:before { - content: "\e685"; -} - -.icon-nunjucks:before { - content: "\e686"; -} - -.icon-nuxt:before { - content: "\e687"; -} - -.icon-pug:before { - content: "\e682"; -} - -.icon-pdf:before { - content: "\e688"; -} - -.icon-postcss:before { - content: "\e681"; -} - -.icon-react:before { - content: "\e689"; -} - -.icon-tsx:before { - content: "\e68a"; -} - -.icon-readme:before { - content: "\e68b"; -} - -.icon-py:before { - content: "\e690"; -} - -.icon-r:before { - content: "\e691"; -} - -.icon-rust:before { - content: "\e68f"; -} - -.icon-raml:before { - content: "\e692"; -} - -.icon-svg:before { - content: "\e698"; -} - -.icon-svelte:before { - content: "\e699"; -} - -.icon-ts:before { - content: "\e6a3"; -} - -.icon-url:before { - content: "\e6a4"; -} - -.icon-table:before { - content: "\e6a5"; -} - -.icon-tex:before { - content: "\e6a9"; -} - -.icon-todo:before { - content: "\e6aa"; -} - -.icon-word1:before { - content: "\e6b0"; -} - -.icon-xaml:before { - content: "\e6b1"; -} - -.icon-xml:before { - content: "\e6b2"; -} - -.icon-vim:before { - content: "\e6b5"; -} - -.icon-virtual:before { - content: "\e6b6"; -} - -.icon-visualstudio:before { - content: "\e6b7"; -} - -.icon-vscode:before { - content: "\e6b8"; -} - -.icon-vue:before { - content: "\e6b9"; -} - -.icon-yarn:before { - content: "\e6bd"; -} - -.icon-zip:before { - content: "\e6be"; -} - -.icon-yaml:before { - content: "\e6bf"; -} - diff --git a/blog-uniapp/static/iconfont/iconfont.js b/blog-uniapp/static/iconfont/iconfont.js deleted file mode 100644 index 439cd646..00000000 --- a/blog-uniapp/static/iconfont/iconfont.js +++ /dev/null @@ -1 +0,0 @@ -window._iconfont_svg_string_3291405='',function(h){var l=(l=document.getElementsByTagName("script"))[l.length-1],c=l.getAttribute("data-injectcss"),l=l.getAttribute("data-disable-injectsvg");if(!l){var a,i,o,t,v,m=function(l,c){c.parentNode.insertBefore(l,c)};if(c&&!h.__iconfont__svg__cssinject__){h.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(l){console&&console.log(l)}}a=function(){var l,c=document.createElement("div");c.innerHTML=h._iconfont_svg_string_3291405,(c=c.getElementsByTagName("svg")[0])&&(c.setAttribute("aria-hidden","true"),c.style.position="absolute",c.style.width=0,c.style.height=0,c.style.overflow="hidden",c=c,(l=document.body).firstChild?m(c,l.firstChild):l.appendChild(c))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(a,0):(i=function(){document.removeEventListener("DOMContentLoaded",i,!1),a()},document.addEventListener("DOMContentLoaded",i,!1)):document.attachEvent&&(o=a,t=h.document,v=!1,s(),t.onreadystatechange=function(){"complete"==t.readyState&&(t.onreadystatechange=null,p())})}function p(){v||(v=!0,o())}function s(){try{t.documentElement.doScroll("left")}catch(l){return void setTimeout(s,50)}p()}}(window); \ No newline at end of file diff --git a/blog-uniapp/static/iconfont/iconfont.json b/blog-uniapp/static/iconfont/iconfont.json deleted file mode 100644 index 55712c01..00000000 --- a/blog-uniapp/static/iconfont/iconfont.json +++ /dev/null @@ -1,968 +0,0 @@ -{ - "id": "3291405", - "name": "zfile", - "font_family": "iconfont", - "css_prefix_text": "icon-", - "description": "", - "glyphs": [ - { - "icon_id": "12601015", - "name": "apk", - "font_class": "apk", - "unicode": "e68d", - "unicode_decimal": 59021 - }, - { - "icon_id": "15378275", - "name": "debian", - "font_class": "deb", - "unicode": "eb74", - "unicode_decimal": 60276 - }, - { - "icon_id": "3970670", - "name": "JavaScript", - "font_class": "JavaScript", - "unicode": "e704", - "unicode_decimal": 59140 - }, - { - "icon_id": "11249796", - "name": "play-next", - "font_class": "play-next", - "unicode": "e850", - "unicode_decimal": 59472 - }, - { - "icon_id": "11249797", - "name": "play", - "font_class": "play", - "unicode": "e851", - "unicode_decimal": 59473 - }, - { - "icon_id": "11249803", - "name": "playlist", - "font_class": "playlist", - "unicode": "e852", - "unicode_decimal": 59474 - }, - { - "icon_id": "11249805", - "name": "play-previous", - "font_class": "play-prev", - "unicode": "e853", - "unicode_decimal": 59475 - }, - { - "icon_id": "11249810", - "name": "rewind-forward", - "font_class": "rewind-forward", - "unicode": "e854", - "unicode_decimal": 59476 - }, - { - "icon_id": "11249812", - "name": "rewind-back", - "font_class": "rewind-back", - "unicode": "e855", - "unicode_decimal": 59477 - }, - { - "icon_id": "11249813", - "name": "reload-2", - "font_class": "reload-", - "unicode": "e856", - "unicode_decimal": 59478 - }, - { - "icon_id": "11249816", - "name": "repeat", - "font_class": "repeat", - "unicode": "e857", - "unicode_decimal": 59479 - }, - { - "icon_id": "11249845", - "name": "shuffle", - "font_class": "shuffle", - "unicode": "e858", - "unicode_decimal": 59480 - }, - { - "icon_id": "11249851", - "name": "sound-on", - "font_class": "volumn", - "unicode": "e859", - "unicode_decimal": 59481 - }, - { - "icon_id": "11249853", - "name": "sound-off", - "font_class": "sound-off", - "unicode": "e85a", - "unicode_decimal": 59482 - }, - { - "icon_id": "11249908", - "name": "pause", - "font_class": "play-pause", - "unicode": "e863", - "unicode_decimal": 59491 - }, - { - "icon_id": "19698192", - "name": "back", - "font_class": "back", - "unicode": "e71c", - "unicode_decimal": 59164 - }, - { - "icon_id": "23994871", - "name": "folder-3", - "font_class": "folder", - "unicode": "e722", - "unicode_decimal": 59170 - }, - { - "icon_id": "22992134", - "name": "adobe photoshop", - "font_class": "psd", - "unicode": "e8c1", - "unicode_decimal": 59585 - }, - { - "icon_id": "12600794", - "name": "mkv", - "font_class": "mkv", - "unicode": "e64c", - "unicode_decimal": 58956 - }, - { - "icon_id": "4318812", - "name": "mp4", - "font_class": "mp4", - "unicode": "e6c3", - "unicode_decimal": 59075 - }, - { - "icon_id": "1005264", - "name": "txt", - "font_class": "txt", - "unicode": "e6c8", - "unicode_decimal": 59080 - }, - { - "icon_id": "28626959", - "name": "txt", - "font_class": "text", - "unicode": "e8c2", - "unicode_decimal": 59586 - }, - { - "icon_id": "12600761", - "name": "jsx", - "font_class": "jsx", - "unicode": "e64b", - "unicode_decimal": 58955 - }, - { - "icon_id": "5916439", - "name": "YAML", - "font_class": "yml", - "unicode": "e64a", - "unicode_decimal": 58954 - }, - { - "icon_id": "5824500", - "name": "shell", - "font_class": "sh", - "unicode": "e68c", - "unicode_decimal": 59020 - }, - { - "icon_id": "1445238", - "name": "script", - "font_class": "script", - "unicode": "e88b", - "unicode_decimal": 59531 - }, - { - "icon_id": "5587560", - "name": "Ruby", - "font_class": "rb", - "unicode": "e6a7", - "unicode_decimal": 59047 - }, - { - "icon_id": "13301799", - "name": "word", - "font_class": "docx", - "unicode": "e601", - "unicode_decimal": 58881 - }, - { - "icon_id": "13301823", - "name": "yellowFolder", - "font_class": "yellowFolder", - "unicode": "e602", - "unicode_decimal": 58882 - }, - { - "icon_id": "13301834", - "name": "outlook", - "font_class": "outlook", - "unicode": "e608", - "unicode_decimal": 58888 - }, - { - "icon_id": "13301840", - "name": "powerpoint", - "font_class": "ppt", - "unicode": "e60a", - "unicode_decimal": 58890 - }, - { - "icon_id": "13302908", - "name": "audio", - "font_class": "audio", - "unicode": "e623", - "unicode_decimal": 58915 - }, - { - "icon_id": "13302910", - "name": "3d", - "font_class": "d", - "unicode": "e624", - "unicode_decimal": 58916 - }, - { - "icon_id": "13302912", - "name": "autohotkey", - "font_class": "autohotkey", - "unicode": "e625", - "unicode_decimal": 58917 - }, - { - "icon_id": "13302916", - "name": "autoit", - "font_class": "autoit", - "unicode": "e626", - "unicode_decimal": 58918 - }, - { - "icon_id": "13302917", - "name": "assembly", - "font_class": "assembly", - "unicode": "e627", - "unicode_decimal": 58919 - }, - { - "icon_id": "13302922", - "name": "android", - "font_class": "android", - "unicode": "e628", - "unicode_decimal": 58920 - }, - { - "icon_id": "13302925", - "name": "applescript", - "font_class": "applescript", - "unicode": "e629", - "unicode_decimal": 58921 - }, - { - "icon_id": "13302927", - "name": "actionscript", - "font_class": "actionscript", - "unicode": "e62a", - "unicode_decimal": 58922 - }, - { - "icon_id": "13302941", - "name": "changelog", - "font_class": "changelog", - "unicode": "e62b", - "unicode_decimal": 58923 - }, - { - "icon_id": "13302942", - "name": "circleci", - "font_class": "circleci", - "unicode": "e62c", - "unicode_decimal": 58924 - }, - { - "icon_id": "13302943", - "name": "circleci_light", - "font_class": "circleci_light", - "unicode": "e62d", - "unicode_decimal": 58925 - }, - { - "icon_id": "13302946", - "name": "cmake", - "font_class": "cmake", - "unicode": "e62e", - "unicode_decimal": 58926 - }, - { - "icon_id": "13302948", - "name": "clojure", - "font_class": "clojure", - "unicode": "e62f", - "unicode_decimal": 58927 - }, - { - "icon_id": "13302950", - "name": "babel", - "font_class": "babel", - "unicode": "e630", - "unicode_decimal": 58928 - }, - { - "icon_id": "13302953", - "name": "blink", - "font_class": "blink", - "unicode": "e631", - "unicode_decimal": 58929 - }, - { - "icon_id": "13302954", - "name": "blink_light", - "font_class": "blink_light", - "unicode": "e632", - "unicode_decimal": 58930 - }, - { - "icon_id": "28664970", - "name": "zip", - "font_class": "archive", - "unicode": "eb75", - "unicode_decimal": 60277 - }, - { - "icon_id": "13302956", - "name": "browserlist", - "font_class": "browserlist", - "unicode": "e633", - "unicode_decimal": 58931 - }, - { - "icon_id": "13302957", - "name": "c", - "font_class": "c", - "unicode": "e634", - "unicode_decimal": 58932 - }, - { - "icon_id": "13303083", - "name": "edge", - "font_class": "edge", - "unicode": "e635", - "unicode_decimal": 58933 - }, - { - "icon_id": "13303086", - "name": "ejs", - "font_class": "ejs", - "unicode": "e636", - "unicode_decimal": 58934 - }, - { - "icon_id": "13303087", - "name": "email", - "font_class": "email", - "unicode": "e637", - "unicode_decimal": 58935 - }, - { - "icon_id": "13303088", - "name": "erlang", - "font_class": "erlang", - "unicode": "e638", - "unicode_decimal": 58936 - }, - { - "icon_id": "13303090", - "name": "exe", - "font_class": "exe", - "unicode": "e639", - "unicode_decimal": 58937 - }, - { - "icon_id": "13303091", - "name": "firebase", - "font_class": "firebase", - "unicode": "e63a", - "unicode_decimal": 58938 - }, - { - "icon_id": "13303092", - "name": "favicon", - "font_class": "favicon", - "unicode": "e63b", - "unicode_decimal": 58939 - }, - { - "icon_id": "13303093", - "name": "eslint", - "font_class": "eslint", - "unicode": "e63c", - "unicode_decimal": 58940 - }, - { - "icon_id": "13303094", - "name": "coffee", - "font_class": "coffee", - "unicode": "e63d", - "unicode_decimal": 58941 - }, - { - "icon_id": "13303095", - "name": "file", - "font_class": "file", - "unicode": "e63e", - "unicode_decimal": 58942 - }, - { - "icon_id": "13303098", - "name": "console", - "font_class": "console", - "unicode": "e63f", - "unicode_decimal": 58943 - }, - { - "icon_id": "13303099", - "name": "cpp", - "font_class": "cpp", - "unicode": "e640", - "unicode_decimal": 58944 - }, - { - "icon_id": "13303102", - "name": "contributing", - "font_class": "contributing", - "unicode": "e641", - "unicode_decimal": 58945 - }, - { - "icon_id": "13303104", - "name": "csharp", - "font_class": "csharp", - "unicode": "e642", - "unicode_decimal": 58946 - }, - { - "icon_id": "13303106", - "name": "css", - "font_class": "css", - "unicode": "e643", - "unicode_decimal": 58947 - }, - { - "icon_id": "13303109", - "name": "diff", - "font_class": "diff", - "unicode": "e644", - "unicode_decimal": 58948 - }, - { - "icon_id": "13303110", - "name": "database", - "font_class": "sql", - "unicode": "e645", - "unicode_decimal": 58949 - }, - { - "icon_id": "13303116", - "name": "document", - "font_class": "document", - "unicode": "e646", - "unicode_decimal": 58950 - }, - { - "icon_id": "13303117", - "name": "django", - "font_class": "django", - "unicode": "e647", - "unicode_decimal": 58951 - }, - { - "icon_id": "13303119", - "name": "dart", - "font_class": "dart", - "unicode": "e648", - "unicode_decimal": 58952 - }, - { - "icon_id": "13303164", - "name": "folder-audio", - "font_class": "folder-audio", - "unicode": "e649", - "unicode_decimal": 58953 - }, - { - "icon_id": "13303476", - "name": "groovy", - "font_class": "groovy", - "unicode": "e652", - "unicode_decimal": 58962 - }, - { - "icon_id": "13303477", - "name": "gulp", - "font_class": "gulp", - "unicode": "e653", - "unicode_decimal": 58963 - }, - { - "icon_id": "13303478", - "name": "haskell", - "font_class": "haskell", - "unicode": "e654", - "unicode_decimal": 58964 - }, - { - "icon_id": "13303482", - "name": "handlebars", - "font_class": "handlebars", - "unicode": "e655", - "unicode_decimal": 58965 - }, - { - "icon_id": "13303484", - "name": "html", - "font_class": "html", - "unicode": "e656", - "unicode_decimal": 58966 - }, - { - "icon_id": "13303485", - "name": "h", - "font_class": "h", - "unicode": "e657", - "unicode_decimal": 58967 - }, - { - "icon_id": "13303491", - "name": "font", - "font_class": "font", - "unicode": "e658", - "unicode_decimal": 58968 - }, - { - "icon_id": "13303493", - "name": "git", - "font_class": "git", - "unicode": "e659", - "unicode_decimal": 58969 - }, - { - "icon_id": "13303497", - "name": "gradle", - "font_class": "gradle", - "unicode": "e65a", - "unicode_decimal": 58970 - }, - { - "icon_id": "13303498", - "name": "go", - "font_class": "go", - "unicode": "e65b", - "unicode_decimal": 58971 - }, - { - "icon_id": "13303502", - "name": "go-mod", - "font_class": "go-mod", - "unicode": "e65c", - "unicode_decimal": 58972 - }, - { - "icon_id": "13303504", - "name": "gitlab", - "font_class": "gitlab", - "unicode": "e65d", - "unicode_decimal": 58973 - }, - { - "icon_id": "13303506", - "name": "haml", - "font_class": "haml", - "unicode": "e65e", - "unicode_decimal": 58974 - }, - { - "icon_id": "13303525", - "name": "javascript-map", - "font_class": "map", - "unicode": "e65f", - "unicode_decimal": 58975 - }, - { - "icon_id": "13303526", - "name": "json", - "font_class": "json", - "unicode": "e660", - "unicode_decimal": 58976 - }, - { - "icon_id": "13303534", - "name": "lib", - "font_class": "lib", - "unicode": "e662", - "unicode_decimal": 58978 - }, - { - "icon_id": "13303535", - "name": "less", - "font_class": "less", - "unicode": "e663", - "unicode_decimal": 58979 - }, - { - "icon_id": "13303536", - "name": "laravel", - "font_class": "laravel", - "unicode": "e664", - "unicode_decimal": 58980 - }, - { - "icon_id": "13303539", - "name": "lock", - "font_class": "lock", - "unicode": "e665", - "unicode_decimal": 58981 - }, - { - "icon_id": "13303541", - "name": "log", - "font_class": "log", - "unicode": "e666", - "unicode_decimal": 58982 - }, - { - "icon_id": "13303542", - "name": "lua", - "font_class": "lua", - "unicode": "e667", - "unicode_decimal": 58983 - }, - { - "icon_id": "13303543", - "name": "markdown", - "font_class": "md", - "unicode": "e668", - "unicode_decimal": 58984 - }, - { - "icon_id": "13303545", - "name": "makefile", - "font_class": "makefile", - "unicode": "e669", - "unicode_decimal": 58985 - }, - { - "icon_id": "13303546", - "name": "livescript", - "font_class": "livescript", - "unicode": "e66a", - "unicode_decimal": 58986 - }, - { - "icon_id": "13303547", - "name": "mdx", - "font_class": "mdx", - "unicode": "e66b", - "unicode_decimal": 58987 - }, - { - "icon_id": "13303552", - "name": "http", - "font_class": "http", - "unicode": "e66c", - "unicode_decimal": 58988 - }, - { - "icon_id": "13303553", - "name": "image", - "font_class": "image", - "unicode": "e66d", - "unicode_decimal": 58989 - }, - { - "icon_id": "13303555", - "name": "i18n", - "font_class": "in", - "unicode": "e66e", - "unicode_decimal": 58990 - }, - { - "icon_id": "13303556", - "name": "java", - "font_class": "java", - "unicode": "e66f", - "unicode_decimal": 58991 - }, - { - "icon_id": "13303558", - "name": "javascript", - "font_class": "js", - "unicode": "e670", - "unicode_decimal": 58992 - }, - { - "icon_id": "13303559", - "name": "ionic", - "font_class": "ionic", - "unicode": "e671", - "unicode_decimal": 58993 - }, - { - "icon_id": "13303933", - "name": "php", - "font_class": "php", - "unicode": "e67e", - "unicode_decimal": 59006 - }, - { - "icon_id": "13303936", - "name": "powerpoint", - "font_class": "powerpoint1", - "unicode": "e67f", - "unicode_decimal": 59007 - }, - { - "icon_id": "13303937", - "name": "powershell", - "font_class": "ps1", - "unicode": "e680", - "unicode_decimal": 59008 - }, - { - "icon_id": "13303942", - "name": "nodejs", - "font_class": "node", - "unicode": "e683", - "unicode_decimal": 59011 - }, - { - "icon_id": "13303947", - "name": "npm", - "font_class": "npm", - "unicode": "e685", - "unicode_decimal": 59013 - }, - { - "icon_id": "13303948", - "name": "nunjucks", - "font_class": "nunjucks", - "unicode": "e686", - "unicode_decimal": 59014 - }, - { - "icon_id": "13303949", - "name": "nuxt", - "font_class": "nuxt", - "unicode": "e687", - "unicode_decimal": 59015 - }, - { - "icon_id": "13303950", - "name": "pug", - "font_class": "pug", - "unicode": "e682", - "unicode_decimal": 59010 - }, - { - "icon_id": "13303952", - "name": "pdf", - "font_class": "pdf", - "unicode": "e688", - "unicode_decimal": 59016 - }, - { - "icon_id": "13303954", - "name": "postcss", - "font_class": "postcss", - "unicode": "e681", - "unicode_decimal": 59009 - }, - { - "icon_id": "13304019", - "name": "react", - "font_class": "react", - "unicode": "e689", - "unicode_decimal": 59017 - }, - { - "icon_id": "13304020", - "name": "react_ts", - "font_class": "tsx", - "unicode": "e68a", - "unicode_decimal": 59018 - }, - { - "icon_id": "13304021", - "name": "readme", - "font_class": "readme", - "unicode": "e68b", - "unicode_decimal": 59019 - }, - { - "icon_id": "13304033", - "name": "python", - "font_class": "py", - "unicode": "e690", - "unicode_decimal": 59024 - }, - { - "icon_id": "13304035", - "name": "r", - "font_class": "r", - "unicode": "e691", - "unicode_decimal": 59025 - }, - { - "icon_id": "13304036", - "name": "rust", - "font_class": "rust", - "unicode": "e68f", - "unicode_decimal": 59023 - }, - { - "icon_id": "13304037", - "name": "raml", - "font_class": "raml", - "unicode": "e692", - "unicode_decimal": 59026 - }, - { - "icon_id": "13304051", - "name": "svg", - "font_class": "svg", - "unicode": "e698", - "unicode_decimal": 59032 - }, - { - "icon_id": "13304052", - "name": "svelte", - "font_class": "svelte", - "unicode": "e699", - "unicode_decimal": 59033 - }, - { - "icon_id": "13304114", - "name": "typescript", - "font_class": "ts", - "unicode": "e6a3", - "unicode_decimal": 59043 - }, - { - "icon_id": "13304115", - "name": "url", - "font_class": "url", - "unicode": "e6a4", - "unicode_decimal": 59044 - }, - { - "icon_id": "13304116", - "name": "table", - "font_class": "table", - "unicode": "e6a5", - "unicode_decimal": 59045 - }, - { - "icon_id": "13304123", - "name": "tex", - "font_class": "tex", - "unicode": "e6a9", - "unicode_decimal": 59049 - }, - { - "icon_id": "13304124", - "name": "todo", - "font_class": "todo", - "unicode": "e6aa", - "unicode_decimal": 59050 - }, - { - "icon_id": "13304134", - "name": "word", - "font_class": "word1", - "unicode": "e6b0", - "unicode_decimal": 59056 - }, - { - "icon_id": "13304135", - "name": "xaml", - "font_class": "xaml", - "unicode": "e6b1", - "unicode_decimal": 59057 - }, - { - "icon_id": "13304136", - "name": "xml", - "font_class": "xml", - "unicode": "e6b2", - "unicode_decimal": 59058 - }, - { - "icon_id": "13304140", - "name": "vim", - "font_class": "vim", - "unicode": "e6b5", - "unicode_decimal": 59061 - }, - { - "icon_id": "13304141", - "name": "virtual", - "font_class": "virtual", - "unicode": "e6b6", - "unicode_decimal": 59062 - }, - { - "icon_id": "13304142", - "name": "visualstudio", - "font_class": "visualstudio", - "unicode": "e6b7", - "unicode_decimal": 59063 - }, - { - "icon_id": "13304144", - "name": "vscode", - "font_class": "vscode", - "unicode": "e6b8", - "unicode_decimal": 59064 - }, - { - "icon_id": "13304145", - "name": "vue", - "font_class": "vue", - "unicode": "e6b9", - "unicode_decimal": 59065 - }, - { - "icon_id": "13304153", - "name": "yarn", - "font_class": "yarn", - "unicode": "e6bd", - "unicode_decimal": 59069 - }, - { - "icon_id": "13304154", - "name": "zip", - "font_class": "zip", - "unicode": "e6be", - "unicode_decimal": 59070 - }, - { - "icon_id": "13304156", - "name": "yaml", - "font_class": "yaml", - "unicode": "e6bf", - "unicode_decimal": 59071 - } - ] -} diff --git a/blog-uniapp/static/iconfont/iconfont.svg b/blog-uniapp/static/iconfont/iconfont.svg deleted file mode 100644 index 8f52daee..00000000 --- a/blog-uniapp/static/iconfont/iconfont.svg +++ /dev/null @@ -1,293 +0,0 @@ - - - - Created by iconfont - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/blog-uniapp/static/iconfont/iconfont.ttf b/blog-uniapp/static/iconfont/iconfont.ttf deleted file mode 100644 index dba79104..00000000 Binary files a/blog-uniapp/static/iconfont/iconfont.ttf and /dev/null differ diff --git a/blog-uniapp/static/iconfont/iconfont.woff b/blog-uniapp/static/iconfont/iconfont.woff deleted file mode 100644 index d5b406b9..00000000 Binary files a/blog-uniapp/static/iconfont/iconfont.woff and /dev/null differ diff --git a/blog-uniapp/static/iconfont/iconfont.woff2 b/blog-uniapp/static/iconfont/iconfont.woff2 deleted file mode 100644 index 5118a0a9..00000000 Binary files a/blog-uniapp/static/iconfont/iconfont.woff2 and /dev/null differ diff --git a/blog-uniapp/static/logo.png b/blog-uniapp/static/logo.png deleted file mode 100644 index b5771e20..00000000 Binary files a/blog-uniapp/static/logo.png and /dev/null differ diff --git a/blog-uniapp/static/uni.png b/blog-uniapp/static/uni.png deleted file mode 100644 index 8e3a80f4..00000000 Binary files a/blog-uniapp/static/uni.png and /dev/null differ diff --git a/blog-uniapp/uni.scss b/blog-uniapp/uni.scss deleted file mode 100644 index ec6f7c51..00000000 --- a/blog-uniapp/uni.scss +++ /dev/null @@ -1 +0,0 @@ -@import "@/uni_modules/uni-scss/variables.scss"; diff --git a/blog-uniapp/uni_modules/u-ajax/README.md b/blog-uniapp/uni_modules/u-ajax/README.md deleted file mode 100644 index d4860037..00000000 --- a/blog-uniapp/uni_modules/u-ajax/README.md +++ /dev/null @@ -1,81 +0,0 @@ -## ✨ 特性 - -- 支持 Promise API -- 支持 Typescript 开发 -- 拦截请求和响应 -- 自定义配置请求实例 -- 多种 Method 方法请求 -- 支持 RequestTask 操作 - -## 🍟 文档 - -**[uniajax.ponjs.com](https://uniajax.ponjs.com)** - -## 🥗 安装 - -**插件市场** - -在插件市场右上角选择 `使用HBuilder X 导入插件` 或者 `下载插件ZIP` - -**NPM** - -```bash -# 如果您的项目是HBuilder X创建的,根目录又没有package.json文件的话,请先执行如下命令: -# npm init -y - -# 安装 -npm install uni-ajax - -# 更新 -npm update uni-ajax -``` - -## 🥐 实例 - -新建 `ajax.js` 文件(文件名可自定义)用于处理拦截器、接口根地址、默认配置等,详细配置请[查看文档](https://uniajax.ponjs.com/instance/create.html) - -```JavaScript -// ajax.js - -import ajax from 'uni-ajax' // 引入 uni-ajax 模块 - -const instance = ajax.create(config) // 创建请求实例 - -instance.interceptors.request.use(onFulfilled, onRejected) // 添加请求拦截器 -instance.interceptors.response.use(onFulfilled, onRejected) // 添加响应拦截器 - -export default instance // 导出创建后的实例 -``` - -## 🥪 使用 - -**请求方法** - -```JavaScript -// 常规方法 -ajax() - -// 请求方法别名 -ajax.get() -ajax.post() -ajax.put() -ajax.delete() -``` - -**RequestTask** - -```JavaScript -const request = ajax() // 请求方法每项皆可 - -request.abort() // 中断请求任务 -request.onHeadersReceived(callback) // 监听 HTTP Response Header 事件 -request.offHeadersReceived(callback) // 取消监听 HTTP Response Header 事件 -``` - -**其他属性方法** - -```JavaScript -ajax.defaults // 全局默认配置 -ajax.config // 当前实例配置 -ajax.getURL(config) // 获取实例请求地址 -``` diff --git a/blog-uniapp/uni_modules/u-ajax/changelog.md b/blog-uniapp/uni_modules/u-ajax/changelog.md deleted file mode 100644 index db1bbff0..00000000 --- a/blog-uniapp/uni_modules/u-ajax/changelog.md +++ /dev/null @@ -1,26 +0,0 @@ -## 2.4.5(2022-07-08) -- 优化使用拦截器的 Typescript 类型 [详情](https://uniajax.ponjs.com/api#interceptors) - -## 2.4.4(2022-04-01) -- 修复 params 参数被转成 JSON 字符串问题 [详情](https://uniajax.ponjs.com/api/config#params) - -## 2.4.3(2022-02-24) -- 兼容支付宝小程序不支持 `class extends Promise` 错误 -- 去除多余的 defaults 默认值 [详情](https://uniajax.ponjs.com/api#defaults) - -## 2.4.2(2022-02-01) -- 修改 params 配置参数 [详情](https://uniajax.ponjs.com/api/config#params) -- 新增 query 配置参数 [详情](https://uniajax.ponjs.com/api/config#query) -- 优化 create 方法的 TypeScript 参数类型 - -## 2.4.1(2022-01-15) - -- 全新的获取实例配置机制 [详情](https://uniajax.ponjs.com/guide/instance#实例配置) -- 新增全局默认配置 [详情](https://uniajax.ponjs.com/guide/instance#全局配置) -- 新增获取请求地址方法 [详情](https://uniajax.ponjs.com/api#geturl) -- 去除获取 baseURL 和 origin 属性 - -## 2.4.0(2022-01-15) - -**全新版本发布** -注意 2.4.x 版本与 2.3.x 以下版本存在些许差异! diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/index.d.ts b/blog-uniapp/uni_modules/u-ajax/js_sdk/index.d.ts deleted file mode 100644 index d06f9a62..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/index.d.ts +++ /dev/null @@ -1,105 +0,0 @@ -export interface AnyObject { - [x: string]: any -} - -export type Data = string | AnyObject | ArrayBuffer -export type Method = 'GET' | 'POST' | 'PUT' | 'DELETE' | 'CONNECT' | 'HEAD' | 'OPTIONS' | 'TRACE' -export type DataType = 'json' | 'text' | 'html' -export type ResponseType = 'text' | 'arraybuffer' -export type Callback = (result: T) => void - -export interface Request extends Promise, AjaxRequestTask> {} - -export interface RequestConstructor extends PromiseConstructor { - readonly prototype: Request - new (executor: (resolve: (value: T | PromiseLike) => void, reject: (reason?: any) => void) => void): Request - task: AjaxRequestTask | null - aborted: boolean - onHeadersReceivedCallback: Callback | null - offHeadersReceivedCallback: Callback | null - onHeadersReceived(callback: Callback): void - offHeadersReceived(callback: Callback): void -} - -export interface AjaxRequestTask { - abort(): T - onHeadersReceived(callback: Callback): T - offHeadersReceived(callback: Callback): T -} - -export interface AjaxRequestConfig { - baseURL?: string - url?: string - data?: Data - query?: AnyObject - params?: AnyObject - header?: any - method?: Method - timeout?: number - dataType?: DataType - responseType?: ResponseType - sslVerify?: boolean - withCredentials?: boolean - firstIpv4?: boolean - xhr?: (task: AjaxRequestTask, config: AjaxRequestConfig) => void - validateStatus?: ((statusCode?: number) => boolean) | null - adapter?: (config: AjaxRequestConfig, Request: RequestConstructor) => Promise -} - -export type AjaxConfigType = - | AjaxRequestConfig - | (() => AjaxRequestConfig) - | (() => Promise) - | undefined - -export interface AjaxCallbackConfig extends AjaxRequestConfig { - success?: Callback - fail?: Callback - complete?: Callback -} - -export interface AjaxResponse { - data: T - statusCode: number - header: any - config: AjaxRequestConfig - errMsg: string - cookies: string[] -} - -export interface AjaxInterceptorManager { - use(onFulfilled?: (value: V) => T | Promise, onRejected?: (error: any) => any): number - eject(id: number): void -} - -export interface AjaxInvoke { - >(config?: AjaxRequestConfig): Request - >(config?: AjaxCallbackConfig): Request - >(url?: string, data?: Data, config?: AjaxRequestConfig): Request -} - -export interface AjaxInstance extends AjaxInvoke { - get: AjaxInvoke - post: AjaxInvoke - put: AjaxInvoke - delete: AjaxInvoke - connect: AjaxInvoke - head: AjaxInvoke - options: AjaxInvoke - trace: AjaxInvoke - getURL(config?: AjaxConfigType): Promise - readonly defaults: AjaxRequestConfig - readonly config: T - interceptors: { - request: AjaxInterceptorManager - response: AjaxInterceptorManager - } -} - -export interface AjaxStatic extends AjaxInstance { - create(config?: T): AjaxInstance -} - -declare const Ajax: AjaxStatic - -export default Ajax diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/index.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/index.js deleted file mode 100644 index 30e4f163..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/index.js +++ /dev/null @@ -1,9 +0,0 @@ -import Ajax from './lib/core/Ajax' - -const ajax = Ajax() - -ajax.create = function create(instanceConfig) { - return Ajax(instanceConfig) -} - -export default ajax diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/adapters/Request.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/adapters/Request.js deleted file mode 100644 index 3d35733c..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/adapters/Request.js +++ /dev/null @@ -1,58 +0,0 @@ -export default function RequestConstructor() { - const Request = function Request(executor) { - return Reflect.construct(Promise, [executor], Request) - } - Object.setPrototypeOf(Request, Promise) - Request.prototype = Object.create(Promise.prototype) - Request.prototype.constructor = Request - - // RequestTask 对象 - Request.task = null - // 请求任务是否被中断 - Request.aborted = false - // 监听 HTTP Response Header 事件回调函数 - Request.onHeadersReceivedCallback = null - // 取消监听 HTTP Response Header 事件回调函数 - Request.offHeadersReceivedCallback = null - - // 监听 HTTP Response Header 事件执行函数 - Request.onHeadersReceived = function onHeadersReceived(fn) { - if (typeof fn === 'function') { - Request.onHeadersReceivedCallback = fn - } - if (Request.onHeadersReceivedCallback && Request.task) { - Request.task.onHeadersReceived?.(Request.onHeadersReceivedCallback) - } - } - - // 取消监听 HTTP Response Header 事件执行函数 - Request.offHeadersReceived = function offHeadersReceived(fn) { - if (typeof fn === 'function') { - Request.offHeadersReceivedCallback = fn - } - if (Request.offHeadersReceivedCallback && Request.task) { - Request.task.offHeadersReceived?.(Request.offHeadersReceivedCallback) - } - } - - // 中断请求任务 - Request.prototype.abort = function abort() { - Request.aborted = true - Request.task?.abort() - return this - } - - // 监听 HTTP Response Header 事件 - Request.prototype.onHeadersReceived = function onHeadersReceived(fn) { - Request.onHeadersReceived(fn) - return this - } - - // 取消监听 HTTP Response Header 事件 - Request.prototype.offHeadersReceived = function offHeadersReceived(fn) { - Request.offHeadersReceived(fn) - return this - } - - return Request -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/adapters/http.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/adapters/http.js deleted file mode 100644 index 547fd793..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/adapters/http.js +++ /dev/null @@ -1,30 +0,0 @@ -export default function adapter(config, Request) { - return new Promise((resolve, reject) => { - // 判断是否被取消请求 - if (Request.aborted) { - return reject({ - config, - errMsg: 'request:fail abort' - }) - } - - // 发起请求,并挂载 RequestTask - Request.task = uni.request({ - ...config, - complete: result => { - // 根据状态码判断要执行的触发的状态 - const response = { config, ...result } - !config.validateStatus || config.validateStatus(result.statusCode) - ? resolve(response) - : reject(response) - } - }) - - // 请求类内部判断是否执行监听 HTTP Response Header 事件 - Request.onHeadersReceived() - Request.offHeadersReceived() - - // 根据配置的 xhr 属性执行获取 RequestTask - config.xhr?.(Request.task, config) - }) -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/Ajax.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/Ajax.js deleted file mode 100644 index 0fc4e3ce..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/Ajax.js +++ /dev/null @@ -1,89 +0,0 @@ -import InterceptorManager from './InterceptorManager' -import RequestConstructor from '../adapters/Request' -import buildURL from '../helpers/buildURL' -import detachConfig from '../helpers/detachConfig' -import mergeConfig from '../helpers/mergeConfig' -import dispatchRequest from './dispatchRequest' -import { detachCancel, dispatchCancel, interceptCancel } from './handleCancel' -import defaults, { METHOD } from '../defaults' -import { forEach, merge } from '../utils' - -export default function Ajax(defaultConfig) { - // 挂载当前实例配置 - const config = typeof defaultConfig === 'object' ? merge(defaultConfig) : defaultConfig - ajax.config = Object.freeze(config) - - // 挂载全局默认配置引用 - ajax.defaults = defaults - - // 挂载拦截器 - ajax.interceptors = { - request: new InterceptorManager(), - response: new InterceptorManager() - } - - // 挂载获取实例请求地址方法 - ajax.getURL = async function getURL(config) { - const combineConfig = await mergeConfig(defaults, defaultConfig, config) - return buildURL(combineConfig).replace(/^\?/, '') - } - - // 挂载对应的 method 方法 - forEach(METHOD, method => { - ajax[method] = function (url, data, config) { - if (typeof url === 'string') return ajax(url, data, { ...config, method }) - return ajax({ ...url, method }) - } - }) - - function ajax(...args) { - // 分类请求参数 - const { callback, config } = detachConfig(...args) - - // 创建请求类 - const Request = RequestConstructor() - - // 声明 Promise 链 - const chain = [dispatchRequest(Request), dispatchCancel] - - // 将请求拦截遍历添加到链前面 - ajax.interceptors.request.forEach.desc(({ fulfilled, rejected }) => - chain.unshift(fulfilled, rejected) - ) - - // 将响应拦截遍历添加到链后面 - ajax.interceptors.response.forEach.asc(({ fulfilled, rejected }) => - chain.push(fulfilled, interceptCancel(rejected)) - ) - - // 先执行获取 config 请求配置 - chain.unshift(config => mergeConfig(defaults, defaultConfig, config), undefined) - - // 处理发起请求前的错误数据 - chain.push(undefined, detachCancel) - - // 调用请求方法后,且拦截器触发完成后,判断回调参数的执行 - chain.push( - response => { - if (!callback) return response - callback.success?.(response) - callback.complete?.(response) - }, - error => { - if (!callback) return Promise.reject(error) - callback.fail?.(error) - callback.complete?.(error) - } - ) - - // 创建请求Promise,遍历链将链上方法传递到then回调 - let request = Request.resolve(config) - while (chain.length) { - request = request.then(chain.shift(), chain.shift()) - } - - return request - } - - return ajax -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/InterceptorManager.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/InterceptorManager.js deleted file mode 100644 index 63ca12a2..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/InterceptorManager.js +++ /dev/null @@ -1,34 +0,0 @@ -/** - * 拦截器类 - */ -export default class InterceptorManager { - handlers = [] - - constructor() { - this.forEach = { - asc: fn => { - for (let i = 0, l = this.handlers.length; i < l; i++) { - this.handlers[i] !== null && fn(this.handlers[i]) - } - }, - desc: fn => { - for (let i = this.handlers.length - 1; i >= 0; i--) { - this.handlers[i] !== null && fn(this.handlers[i]) - } - } - } - } - - use(fulfilled, rejected) { - this.handlers.push({ - fulfilled, - rejected - }) - return this.handlers.length - 1 - } - eject(id) { - if (this.handlers[id]) { - this.handlers[id] = null - } - } -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/dispatchRequest.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/dispatchRequest.js deleted file mode 100644 index c9c38217..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/dispatchRequest.js +++ /dev/null @@ -1,35 +0,0 @@ -import buildURL from '../helpers/buildURL' -import isCallback from '../helpers/isCallback' -import { forEach, isPlainObject, merge } from '../utils' -import { HEADER } from '../defaults' - -/** - * 派发请求方法 - * @param {*} Request 请求类 - * @returns {Promise} 执行请求方法Promise - */ -export default function dispatchRequest(Request) { - return config => { - // 拼接 url - config.url = buildURL(config) - - // 请求方法转大写 - config.method = (config.method || 'get').toUpperCase() - - // 调整 header 优先级 - config.header = merge( - config.header.common, - config.header[config.method.toLowerCase()], - config.header - ) - - // 清除多余的请求头 - forEach(HEADER, h => isPlainObject(config.header[h]) && delete config.header[h]) - - // 清除回调函数 - forEach(config, (val, key) => isCallback(key) && delete config[key]) - - // 执行请求方法 - return config.adapter(config, Request) - } -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/handleCancel.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/handleCancel.js deleted file mode 100644 index 96f3df44..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/core/handleCancel.js +++ /dev/null @@ -1,35 +0,0 @@ -const CANCEL = Symbol('$$cancel') - -function hasCancel(target) { - return target === null || target === undefined - ? false - : Object.prototype.hasOwnProperty.call(target, CANCEL) -} - -/** - * 派发请求拒绝方法,处理发起请求前错误,取消执行请求,并防止进入响应拦截器 - * @param {*} reason 错误原因 - * @returns {Promise} 封装了 CANCEL 的失败对象 - */ -export function dispatchCancel(reason) { - return Promise.reject({ [CANCEL]: reason }) -} - -/** - * 拦截失败对象 - * @param {Function} rejected 响应错误拦截器 - */ -export function interceptCancel(rejected) { - // 判断发起请求前是否发生错误,如果发生错误则不执行后面的响应错误拦截器 - return ( - rejected && (response => (hasCancel(response) ? Promise.reject(response) : rejected(response))) - ) -} - -/** - * 分离失败对象 - * @param {*} response 封装了 CANCEL 的失败对象 - */ -export function detachCancel(error) { - return Promise.reject(hasCancel(error) ? error[CANCEL] : error) -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/defaults.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/defaults.js deleted file mode 100644 index a4ff0883..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/defaults.js +++ /dev/null @@ -1,22 +0,0 @@ -import adapter from './adapters/http' -import { forEach } from './utils' - -export const METHOD = ['get', 'post', 'put', 'delete', 'connect', 'head', 'options', 'trace'] -export const HEADER = ['common', ...METHOD] - -const defaults = { - adapter, - header: {}, - method: 'GET', - // timeout: 60000, - // dataType: 'json', - // responseType: 'text', - // sslVerify: true, - // withCredentials: false, - // firstIpv4: false, - validateStatus: statusCode => statusCode >= 200 && statusCode < 300 -} - -forEach(HEADER, h => (defaults.header[h] = {})) - -export default defaults diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/buildURL.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/buildURL.js deleted file mode 100644 index f9332ffa..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/buildURL.js +++ /dev/null @@ -1,83 +0,0 @@ -import { forEach, isArray } from '../utils' - -/** - * 根据 baseURL 和 url 拼接 - * @param {string} baseURL 请求根地址 - * @param {string} relativeURL 请求参数地址 - * @returns {string} 拼接后的地址 - */ -function combineURL(baseURL = '', relativeURL = '') { - // 判断是否 http:// 或 https:// 开头 - if (/^https?:\/\//.test(relativeURL)) return relativeURL - // 去除 baseURL 结尾斜杠,去除 relativeURL 开头斜杠,再判断拼接 - return relativeURL ? baseURL.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') : baseURL -} - -function encode(val) { - return encodeURIComponent(val) - .replace(/%3A/gi, ':') - .replace(/%24/g, '$') - .replace(/%2C/gi, ',') - .replace(/%20/g, '+') - .replace(/%5B/gi, '[') - .replace(/%5D/gi, ']') -} - -function querystring(url, params) { - let query - - const parts = [] - forEach(params, (val, key) => { - if (val === null || typeof val === 'undefined') return - - if (isArray(val)) key = key + '[]' - else val = [val] - - forEach(val, v => { - if (v !== null && typeof v === 'object') { - v = JSON.stringify(v) - } - parts.push(encode(key) + '=' + encode(v)) - }) - }) - query = parts.join('&') - - if (query) { - const hashmarkIndex = url.indexOf('#') - hashmarkIndex !== -1 && (url = url.slice(0, hashmarkIndex)) - url += (url.indexOf('?') === -1 ? '?' : '&') + query - } - - return url -} - -/** - * 根据 baseURL、url、params query 编译请求URL - * @returns {string} 处理后的地址 - */ -export default function buildURL({ baseURL, url: relativeURL, params, query } = {}) { - let url = combineURL(baseURL, relativeURL) - - if (!params && !query) { - return url - } - - if (params) { - if (/\/:/.test(url)) { - // 是否是 params 参数地址,并对应设置 - forEach(params, (val, key) => { - url = url.replace(`/:${key}`, `/${encode(String(val))}`) - }) - } else if (!query) { - // 兼容旧的 params 属性设置 query - url = querystring(url, params) - } - } - - // 设置 query 参数 - if (query) { - url = querystring(url, query) - } - - return url -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/detachConfig.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/detachConfig.js deleted file mode 100644 index 441f18fd..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/detachConfig.js +++ /dev/null @@ -1,36 +0,0 @@ -import isCallback from './isCallback' -import { forEach, tryCatch } from '../utils' - -/** - * 分离请求对象 - * @param {string|object} [url] 请求地址 / 请求配置 - * @param {string|object} [data] 请求参数 - * @param {object} [config] 请求配置 - * @returns {object} 回调函数对象 去除回调的请求参数 - */ -export default function detachConfig(url, data, config) { - // 回调函数对象 - let callback = null - // 去除回调的请求参数对象 - const options = {} - - // 是否传入单个参数 - const isSingle = typeof url === 'object' - - // 请求参数对象 - const value = isSingle ? url : { ...config, url, data } - - // 分离请求参数 - forEach(value, (val, key) => { - if (isSingle && isCallback(key)) { - ;(callback || (callback = {}))[key] = tryCatch(val) - } else { - options[key] = val - } - }) - - return { - callback, - config: options - } -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/isCallback.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/isCallback.js deleted file mode 100644 index 3bdf921e..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/isCallback.js +++ /dev/null @@ -1,8 +0,0 @@ -/** - * 判断参数是否含有回调参数 success / fail / complete 之一 - * @param {string} field 参数的 Key 值字符串 - * @returns {boolean} 返回判断值 - */ -export default function isCallback(field) { - return ['success', 'fail', 'complete'].includes(field) -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/mergeConfig.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/mergeConfig.js deleted file mode 100644 index 26131eff..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/helpers/mergeConfig.js +++ /dev/null @@ -1,41 +0,0 @@ -import { assign, forEach } from '../utils' - -/** - * 深度合并,且不合并 undefined 值 - * @param {object} obj1 前对象 - * @param {object} obj2 后对象 - * @returns {object} 合并后的对象 - */ -function merge(obj1 = {}, obj2 = {}) { - const obj = {} - - const objKeys = Object.keys({ ...obj1, ...obj2 }) - - forEach(objKeys, prop => { - if (obj2[prop] !== undefined) { - obj[prop] = assign(obj1[prop], obj2[prop]) - } else if (obj1[prop] !== undefined) { - obj[prop] = assign(undefined, obj1[prop]) - } - }) - - return obj -} - -/** - * 合并请求配置 - * @param {...object|function} args 请求配置 - * @returns {object} 合并后的请求配置 - */ -export default async function mergeConfig(...args) { - let config = {} - - for (let i = 0, l = args.length; i < l; i++) { - const current = typeof args[i] === 'function' ? await args[i]() : args[i] - config = merge(config, current) - } - - config.method = config.method.toUpperCase() - - return config -} diff --git a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/utils.js b/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/utils.js deleted file mode 100644 index 77f83f80..00000000 --- a/blog-uniapp/uni_modules/u-ajax/js_sdk/lib/utils.js +++ /dev/null @@ -1,92 +0,0 @@ -/** - * 获取值的原始类型字符串,例如 [object Object] - */ -const _toString = Object.prototype.toString - -/** - * 判断是否为数组 - * @param {*} val 要判断的值 - * @returns {boolean} 返回判断结果 - */ -export function isArray(val) { - return _toString.call(val) === '[object Array]' -} - -/** - * 判断是否为普通对象 - * @param {*} val 要判断的值 - * @returns {boolean} 返回判断结果 - */ -export function isPlainObject(val) { - return _toString.call(val) === '[object Object]' -} - -/** - * 遍历 - * @param {object|array} obj 要迭代的对象 - * @param {function} fn 为每个项调用的回调 - */ -export function forEach(obj, fn) { - if (obj === null || obj === undefined) return - if (typeof obj !== 'object') obj = [obj] - if (isArray(obj)) { - for (let i = 0, l = obj.length; i < l; i++) { - fn.call(null, obj[i], i, obj) - } - } else { - for (const k in obj) { - if (Object.prototype.hasOwnProperty.call(obj, k)) { - fn.call(null, obj[k], k, obj) - } - } - } -} - -/** - * 对象深合并 - * @param {...object} args 对象 - * @returns {object} 合并后的对象 - */ -export function merge(...args) { - const result = {} - for (let i = 0, l = args.length; i < l; i++) { - if (isPlainObject(args[i])) { - forEach(args[i], (val, key) => { - result[key] = assign(result[key], val) - }) - } - } - return result -} - -/** - * 合并分配到目标对象 - * @param {*} target 目标对象 - * @param {*} source 源对象 - * @returns {*} 目标对象 - */ -export function assign(target, source) { - if (isPlainObject(target) && isPlainObject(source)) { - return merge(target, source) - } else if (isPlainObject(source)) { - return merge({}, source) - } else if (isArray(source)) { - return source.slice() - } - return source -} - -/** - * trycatch 封装函数 - * @param {function} fn 函数 - * @returns {function} 封装 trycatch 后的函数 - */ -export function tryCatch(fn) { - return function (...args) { - try { - return fn.apply(fn, args) - } catch (error) { - console.error(error) - } - } -} diff --git a/blog-uniapp/uni_modules/u-ajax/package.json b/blog-uniapp/uni_modules/u-ajax/package.json deleted file mode 100644 index 8e76d28f..00000000 --- a/blog-uniapp/uni_modules/u-ajax/package.json +++ /dev/null @@ -1,71 +0,0 @@ -{ - "id": "u-ajax", - "displayName": "ajax request 请求", - "version": "2.4.5", - "description": "封装 uni.request,支持拦截器、接口根地址、默认配置、中断请求等功能", - "keywords": [ - "ajax", - "http", - "promise", - "request", - "task" -], - "repository": "https://github.com/ponjs/uni-ajax", - "dcloudext": { - "category": [ - "JS SDK", - "通用 SDK" - ], - "declaration": { - "ads": "无", - "data": "插件不采集任何数据", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/uni-ajax", - "contact": { - "qq": "" - } - }, - "uni_modules": { - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "y", - "联盟": "y" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-badge/changelog.md b/blog-uniapp/uni_modules/uni-badge/changelog.md deleted file mode 100644 index 544ecc13..00000000 --- a/blog-uniapp/uni_modules/uni-badge/changelog.md +++ /dev/null @@ -1,29 +0,0 @@ -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-badge](https://uniapp.dcloud.io/component/uniui/uni-badge) -## 1.1.7(2021-11-08) -- 优化 升级ui -- 修改 size 属性默认值调整为 small -- 修改 type 属性,默认值调整为 error,info 替换 default -## 1.1.6(2021-09-22) -- 修复 在字节小程序上样式不生效的 bug -## 1.1.5(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.1.4(2021-07-29) -- 修复 去掉 nvue 不支持css 的 align-self 属性,nvue 下不暂支持 absolute 属性 -## 1.1.3(2021-06-24) -- 优化 示例项目 -## 1.1.1(2021-05-12) -- 新增 组件示例地址 -## 1.1.0(2021-05-12) -- 新增 uni-badge 的 absolute 属性,支持定位 -- 新增 uni-badge 的 offset 属性,支持定位偏移 -- 新增 uni-badge 的 is-dot 属性,支持仅显示有一个小点 -- 新增 uni-badge 的 max-num 属性,支持自定义封顶的数字值,超过 99 显示99+ -- 优化 uni-badge 属性 custom-style, 支持以对象形式自定义样式 -## 1.0.7(2021-05-07) -- 修复 uni-badge 在 App 端,数字小于10时不是圆形的bug -- 修复 uni-badge 在父元素不是 flex 布局时,宽度缩小的bug -- 新增 uni-badge 属性 custom-style, 支持自定义样式 -## 1.0.6(2021-02-04) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-badge/components/uni-badge/uni-badge.vue b/blog-uniapp/uni_modules/uni-badge/components/uni-badge/uni-badge.vue deleted file mode 100644 index fcbfe938..00000000 --- a/blog-uniapp/uni_modules/uni-badge/components/uni-badge/uni-badge.vue +++ /dev/null @@ -1,268 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-badge/package.json b/blog-uniapp/uni_modules/uni-badge/package.json deleted file mode 100644 index 4e9e631a..00000000 --- a/blog-uniapp/uni_modules/uni-badge/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-badge", - "displayName": "uni-badge 数字角标", - "version": "1.2.0", - "description": "数字角标(徽章)组件,在元素周围展示消息提醒,一般用于列表、九宫格、按钮等地方。", - "keywords": [ - "", - "badge", - "uni-ui", - "uniui", - "数字角标", - "徽章" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "y", - "联盟": "y" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-badge/readme.md b/blog-uniapp/uni_modules/uni-badge/readme.md deleted file mode 100644 index bdf175da..00000000 --- a/blog-uniapp/uni_modules/uni-badge/readme.md +++ /dev/null @@ -1,10 +0,0 @@ -## Badge 数字角标 -> **组件名:uni-badge** -> 代码块: `uBadge` - -数字角标一般和其它控件(列表、9宫格等)配合使用,用于进行数量提示,默认为实心灰色背景, - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-badge) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-breadcrumb/changelog.md b/blog-uniapp/uni_modules/uni-breadcrumb/changelog.md deleted file mode 100644 index 016e6cee..00000000 --- a/blog-uniapp/uni_modules/uni-breadcrumb/changelog.md +++ /dev/null @@ -1,6 +0,0 @@ -## 0.1.2(2022-06-08) -- 修复 微信小程序 separator 不显示问题 -## 0.1.1(2022-06-02) -- 新增 支持 uni.scss 修改颜色 -## 0.1.0(2022-04-21) -- 初始化 diff --git a/blog-uniapp/uni_modules/uni-breadcrumb/components/uni-breadcrumb-item/uni-breadcrumb-item.vue b/blog-uniapp/uni_modules/uni-breadcrumb/components/uni-breadcrumb-item/uni-breadcrumb-item.vue deleted file mode 100644 index b9edbd62..00000000 --- a/blog-uniapp/uni_modules/uni-breadcrumb/components/uni-breadcrumb-item/uni-breadcrumb-item.vue +++ /dev/null @@ -1,121 +0,0 @@ - - - diff --git a/blog-uniapp/uni_modules/uni-breadcrumb/components/uni-breadcrumb/uni-breadcrumb.vue b/blog-uniapp/uni_modules/uni-breadcrumb/components/uni-breadcrumb/uni-breadcrumb.vue deleted file mode 100644 index 94493a21..00000000 --- a/blog-uniapp/uni_modules/uni-breadcrumb/components/uni-breadcrumb/uni-breadcrumb.vue +++ /dev/null @@ -1,41 +0,0 @@ - - - diff --git a/blog-uniapp/uni_modules/uni-breadcrumb/package.json b/blog-uniapp/uni_modules/uni-breadcrumb/package.json deleted file mode 100644 index 0a04e503..00000000 --- a/blog-uniapp/uni_modules/uni-breadcrumb/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-breadcrumb", - "displayName": "uni-breadcrumb 面包屑", - "version": "0.1.2", - "description": "Breadcrumb 面包屑", - "keywords": [ - "uni-breadcrumb", - "breadcrumb", - "uni-ui", - "面包屑导航", - "面包屑" -], - "repository": "", - "engines": { - "HBuilderX": "^3.1.0" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "" - }, - "uni_modules": { - "dependencies": [], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "Vue": { - "vue2": "y", - "vue3": "y" - }, - "App": { - "app-vue": "y", - "app-nvue": "n" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "u", - "百度": "u", - "字节跳动": "u", - "QQ": "u", - "京东": "u" - }, - "快应用": { - "华为": "u", - "联盟": "u" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-breadcrumb/readme.md b/blog-uniapp/uni_modules/uni-breadcrumb/readme.md deleted file mode 100644 index 6976b8d7..00000000 --- a/blog-uniapp/uni_modules/uni-breadcrumb/readme.md +++ /dev/null @@ -1,66 +0,0 @@ - -## breadcrumb 面包屑导航 -> **组件名:uni-breadcrumb** -> 代码块: `ubreadcrumb` - -显示当前页面的路径,快速返回之前的任意页面。 - -### 安装方式 - -本组件符合[easycom](https://uniapp.dcloud.io/collocation/pages?id=easycom)规范,`HBuilderX 2.5.5`起,只需将本组件导入项目,在页面`template`中即可直接使用,无需在页面中`import`和注册`components`。 - -如需通过`npm`方式使用`uni-ui`组件,另见文档:[https://ext.dcloud.net.cn/plugin?id=55](https://ext.dcloud.net.cn/plugin?id=55) - -### 基本用法 - -在 ``template`` 中使用组件 - -```html - - {{route.name}} - -``` - -```js -export default { - name: "uni-stat-breadcrumb", - data() { - return { - routes: [{ - to: '/A', - name: 'A页面' - }, { - to: '/B', - name: 'B页面' - }, { - to: '/C', - name: 'C页面' - }] - }; - } - } -``` - - -## API - -### Breadcrumb Props - -|属性名 |类型 |默认值 |说明 | -|:-: |:-: |:-: |:-: | -|separator |String |斜杠'/' |分隔符 | -|separatorClass |String | |图标分隔符 class | - -### Breadcrumb Item Props - -|属性名 |类型 |默认值 |说明 | -|:-: |:-: |:-: |:-: | -|to |String | |路由跳转页面路径 | -|replace|Boolean | |在使用 to 进行路由跳转时,启用 replace 将不会向 history 添加新记录(仅 h5 支持) | - - - - -## 组件示例 - -点击查看:[https://hellouniapp.dcloud.net.cn/pages/extUI/breadcrumb/breadcrumb](https://hellouniapp.dcloud.net.cn/pages/extUI/breadcrumb/breadcrumb) \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-calendar/changelog.md b/blog-uniapp/uni_modules/uni-calendar/changelog.md deleted file mode 100644 index 6df4493e..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/changelog.md +++ /dev/null @@ -1,16 +0,0 @@ -## 1.4.5(2022-02-25) -- 修复 条件编译 nvue 不支持的 css 样式 -## 1.4.4(2022-02-25) -- 修复 条件编译 nvue 不支持的 css 样式 -## 1.4.3(2021-09-22) -- 修复 startDate、 endDate 属性失效的 bug -## 1.4.2(2021-08-24) -- 新增 支持国际化 -## 1.4.1(2021-08-05) -- 修复 弹出层被 tabbar 遮盖 bug -## 1.4.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.3.16(2021-05-12) -- 新增 组件示例地址 -## 1.3.15(2021-02-04) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/calendar.js b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/calendar.js deleted file mode 100644 index b8d7d6fc..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/calendar.js +++ /dev/null @@ -1,546 +0,0 @@ -/** -* @1900-2100区间内的公历、农历互转 -* @charset UTF-8 -* @github https://github.com/jjonline/calendar.js -* @Author Jea杨(JJonline@JJonline.Cn) -* @Time 2014-7-21 -* @Time 2016-8-13 Fixed 2033hex、Attribution Annals -* @Time 2016-9-25 Fixed lunar LeapMonth Param Bug -* @Time 2017-7-24 Fixed use getTerm Func Param Error.use solar year,NOT lunar year -* @Version 1.0.3 -* @公历转农历:calendar.solar2lunar(1987,11,01); //[you can ignore params of prefix 0] -* @农历转公历:calendar.lunar2solar(1987,09,10); //[you can ignore params of prefix 0] -*/ -/* eslint-disable */ -var calendar = { - - /** - * 农历1900-2100的润大小信息表 - * @Array Of Property - * @return Hex - */ - lunarInfo: [0x04bd8, 0x04ae0, 0x0a570, 0x054d5, 0x0d260, 0x0d950, 0x16554, 0x056a0, 0x09ad0, 0x055d2, // 1900-1909 - 0x04ae0, 0x0a5b6, 0x0a4d0, 0x0d250, 0x1d255, 0x0b540, 0x0d6a0, 0x0ada2, 0x095b0, 0x14977, // 1910-1919 - 0x04970, 0x0a4b0, 0x0b4b5, 0x06a50, 0x06d40, 0x1ab54, 0x02b60, 0x09570, 0x052f2, 0x04970, // 1920-1929 - 0x06566, 0x0d4a0, 0x0ea50, 0x06e95, 0x05ad0, 0x02b60, 0x186e3, 0x092e0, 0x1c8d7, 0x0c950, // 1930-1939 - 0x0d4a0, 0x1d8a6, 0x0b550, 0x056a0, 0x1a5b4, 0x025d0, 0x092d0, 0x0d2b2, 0x0a950, 0x0b557, // 1940-1949 - 0x06ca0, 0x0b550, 0x15355, 0x04da0, 0x0a5b0, 0x14573, 0x052b0, 0x0a9a8, 0x0e950, 0x06aa0, // 1950-1959 - 0x0aea6, 0x0ab50, 0x04b60, 0x0aae4, 0x0a570, 0x05260, 0x0f263, 0x0d950, 0x05b57, 0x056a0, // 1960-1969 - 0x096d0, 0x04dd5, 0x04ad0, 0x0a4d0, 0x0d4d4, 0x0d250, 0x0d558, 0x0b540, 0x0b6a0, 0x195a6, // 1970-1979 - 0x095b0, 0x049b0, 0x0a974, 0x0a4b0, 0x0b27a, 0x06a50, 0x06d40, 0x0af46, 0x0ab60, 0x09570, // 1980-1989 - 0x04af5, 0x04970, 0x064b0, 0x074a3, 0x0ea50, 0x06b58, 0x05ac0, 0x0ab60, 0x096d5, 0x092e0, // 1990-1999 - 0x0c960, 0x0d954, 0x0d4a0, 0x0da50, 0x07552, 0x056a0, 0x0abb7, 0x025d0, 0x092d0, 0x0cab5, // 2000-2009 - 0x0a950, 0x0b4a0, 0x0baa4, 0x0ad50, 0x055d9, 0x04ba0, 0x0a5b0, 0x15176, 0x052b0, 0x0a930, // 2010-2019 - 0x07954, 0x06aa0, 0x0ad50, 0x05b52, 0x04b60, 0x0a6e6, 0x0a4e0, 0x0d260, 0x0ea65, 0x0d530, // 2020-2029 - 0x05aa0, 0x076a3, 0x096d0, 0x04afb, 0x04ad0, 0x0a4d0, 0x1d0b6, 0x0d250, 0x0d520, 0x0dd45, // 2030-2039 - 0x0b5a0, 0x056d0, 0x055b2, 0x049b0, 0x0a577, 0x0a4b0, 0x0aa50, 0x1b255, 0x06d20, 0x0ada0, // 2040-2049 - /** Add By JJonline@JJonline.Cn**/ - 0x14b63, 0x09370, 0x049f8, 0x04970, 0x064b0, 0x168a6, 0x0ea50, 0x06b20, 0x1a6c4, 0x0aae0, // 2050-2059 - 0x0a2e0, 0x0d2e3, 0x0c960, 0x0d557, 0x0d4a0, 0x0da50, 0x05d55, 0x056a0, 0x0a6d0, 0x055d4, // 2060-2069 - 0x052d0, 0x0a9b8, 0x0a950, 0x0b4a0, 0x0b6a6, 0x0ad50, 0x055a0, 0x0aba4, 0x0a5b0, 0x052b0, // 2070-2079 - 0x0b273, 0x06930, 0x07337, 0x06aa0, 0x0ad50, 0x14b55, 0x04b60, 0x0a570, 0x054e4, 0x0d160, // 2080-2089 - 0x0e968, 0x0d520, 0x0daa0, 0x16aa6, 0x056d0, 0x04ae0, 0x0a9d4, 0x0a2d0, 0x0d150, 0x0f252, // 2090-2099 - 0x0d520], // 2100 - - /** - * 公历每个月份的天数普通表 - * @Array Of Property - * @return Number - */ - solarMonth: [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], - - /** - * 天干地支之天干速查表 - * @Array Of Property trans["甲","乙","丙","丁","戊","己","庚","辛","壬","癸"] - * @return Cn string - */ - Gan: ['\u7532', '\u4e59', '\u4e19', '\u4e01', '\u620a', '\u5df1', '\u5e9a', '\u8f9b', '\u58ec', '\u7678'], - - /** - * 天干地支之地支速查表 - * @Array Of Property - * @trans["子","丑","寅","卯","辰","巳","午","未","申","酉","戌","亥"] - * @return Cn string - */ - Zhi: ['\u5b50', '\u4e11', '\u5bc5', '\u536f', '\u8fb0', '\u5df3', '\u5348', '\u672a', '\u7533', '\u9149', '\u620c', '\u4ea5'], - - /** - * 天干地支之地支速查表<=>生肖 - * @Array Of Property - * @trans["鼠","牛","虎","兔","龙","蛇","马","羊","猴","鸡","狗","猪"] - * @return Cn string - */ - Animals: ['\u9f20', '\u725b', '\u864e', '\u5154', '\u9f99', '\u86c7', '\u9a6c', '\u7f8a', '\u7334', '\u9e21', '\u72d7', '\u732a'], - - /** - * 24节气速查表 - * @Array Of Property - * @trans["小寒","大寒","立春","雨水","惊蛰","春分","清明","谷雨","立夏","小满","芒种","夏至","小暑","大暑","立秋","处暑","白露","秋分","寒露","霜降","立冬","小雪","大雪","冬至"] - * @return Cn string - */ - solarTerm: ['\u5c0f\u5bd2', '\u5927\u5bd2', '\u7acb\u6625', '\u96e8\u6c34', '\u60ca\u86f0', '\u6625\u5206', '\u6e05\u660e', '\u8c37\u96e8', '\u7acb\u590f', '\u5c0f\u6ee1', '\u8292\u79cd', '\u590f\u81f3', '\u5c0f\u6691', '\u5927\u6691', '\u7acb\u79cb', '\u5904\u6691', '\u767d\u9732', '\u79cb\u5206', '\u5bd2\u9732', '\u971c\u964d', '\u7acb\u51ac', '\u5c0f\u96ea', '\u5927\u96ea', '\u51ac\u81f3'], - - /** - * 1900-2100各年的24节气日期速查表 - * @Array Of Property - * @return 0x string For splice - */ - sTermInfo: ['9778397bd097c36b0b6fc9274c91aa', '97b6b97bd19801ec9210c965cc920e', '97bcf97c3598082c95f8c965cc920f', - '97bd0b06bdb0722c965ce1cfcc920f', 'b027097bd097c36b0b6fc9274c91aa', '97b6b97bd19801ec9210c965cc920e', - '97bcf97c359801ec95f8c965cc920f', '97bd0b06bdb0722c965ce1cfcc920f', 'b027097bd097c36b0b6fc9274c91aa', - '97b6b97bd19801ec9210c965cc920e', '97bcf97c359801ec95f8c965cc920f', '97bd0b06bdb0722c965ce1cfcc920f', - 'b027097bd097c36b0b6fc9274c91aa', '9778397bd19801ec9210c965cc920e', '97b6b97bd19801ec95f8c965cc920f', - '97bd09801d98082c95f8e1cfcc920f', '97bd097bd097c36b0b6fc9210c8dc2', '9778397bd197c36c9210c9274c91aa', - '97b6b97bd19801ec95f8c965cc920e', '97bd09801d98082c95f8e1cfcc920f', '97bd097bd097c36b0b6fc9210c8dc2', - '9778397bd097c36c9210c9274c91aa', '97b6b97bd19801ec95f8c965cc920e', '97bcf97c3598082c95f8e1cfcc920f', - '97bd097bd097c36b0b6fc9210c8dc2', '9778397bd097c36c9210c9274c91aa', '97b6b97bd19801ec9210c965cc920e', - '97bcf97c3598082c95f8c965cc920f', '97bd097bd097c35b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', - '97b6b97bd19801ec9210c965cc920e', '97bcf97c3598082c95f8c965cc920f', '97bd097bd097c35b0b6fc920fb0722', - '9778397bd097c36b0b6fc9274c91aa', '97b6b97bd19801ec9210c965cc920e', '97bcf97c359801ec95f8c965cc920f', - '97bd097bd097c35b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', '97b6b97bd19801ec9210c965cc920e', - '97bcf97c359801ec95f8c965cc920f', '97bd097bd097c35b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', - '97b6b97bd19801ec9210c965cc920e', '97bcf97c359801ec95f8c965cc920f', '97bd097bd07f595b0b6fc920fb0722', - '9778397bd097c36b0b6fc9210c8dc2', '9778397bd19801ec9210c9274c920e', '97b6b97bd19801ec95f8c965cc920f', - '97bd07f5307f595b0b0bc920fb0722', '7f0e397bd097c36b0b6fc9210c8dc2', '9778397bd097c36c9210c9274c920e', - '97b6b97bd19801ec95f8c965cc920f', '97bd07f5307f595b0b0bc920fb0722', '7f0e397bd097c36b0b6fc9210c8dc2', - '9778397bd097c36c9210c9274c91aa', '97b6b97bd19801ec9210c965cc920e', '97bd07f1487f595b0b0bc920fb0722', - '7f0e397bd097c36b0b6fc9210c8dc2', '9778397bd097c36b0b6fc9274c91aa', '97b6b97bd19801ec9210c965cc920e', - '97bcf7f1487f595b0b0bb0b6fb0722', '7f0e397bd097c35b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', - '97b6b97bd19801ec9210c965cc920e', '97bcf7f1487f595b0b0bb0b6fb0722', '7f0e397bd097c35b0b6fc920fb0722', - '9778397bd097c36b0b6fc9274c91aa', '97b6b97bd19801ec9210c965cc920e', '97bcf7f1487f531b0b0bb0b6fb0722', - '7f0e397bd097c35b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', '97b6b97bd19801ec9210c965cc920e', - '97bcf7f1487f531b0b0bb0b6fb0722', '7f0e397bd07f595b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', - '97b6b97bd19801ec9210c9274c920e', '97bcf7f0e47f531b0b0bb0b6fb0722', '7f0e397bd07f595b0b0bc920fb0722', - '9778397bd097c36b0b6fc9210c91aa', '97b6b97bd197c36c9210c9274c920e', '97bcf7f0e47f531b0b0bb0b6fb0722', - '7f0e397bd07f595b0b0bc920fb0722', '9778397bd097c36b0b6fc9210c8dc2', '9778397bd097c36c9210c9274c920e', - '97b6b7f0e47f531b0723b0b6fb0722', '7f0e37f5307f595b0b0bc920fb0722', '7f0e397bd097c36b0b6fc9210c8dc2', - '9778397bd097c36b0b70c9274c91aa', '97b6b7f0e47f531b0723b0b6fb0721', '7f0e37f1487f595b0b0bb0b6fb0722', - '7f0e397bd097c35b0b6fc9210c8dc2', '9778397bd097c36b0b6fc9274c91aa', '97b6b7f0e47f531b0723b0b6fb0721', - '7f0e27f1487f595b0b0bb0b6fb0722', '7f0e397bd097c35b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', - '97b6b7f0e47f531b0723b0b6fb0721', '7f0e27f1487f531b0b0bb0b6fb0722', '7f0e397bd097c35b0b6fc920fb0722', - '9778397bd097c36b0b6fc9274c91aa', '97b6b7f0e47f531b0723b0b6fb0721', '7f0e27f1487f531b0b0bb0b6fb0722', - '7f0e397bd097c35b0b6fc920fb0722', '9778397bd097c36b0b6fc9274c91aa', '97b6b7f0e47f531b0723b0b6fb0721', - '7f0e27f1487f531b0b0bb0b6fb0722', '7f0e397bd07f595b0b0bc920fb0722', '9778397bd097c36b0b6fc9274c91aa', - '97b6b7f0e47f531b0723b0787b0721', '7f0e27f0e47f531b0b0bb0b6fb0722', '7f0e397bd07f595b0b0bc920fb0722', - '9778397bd097c36b0b6fc9210c91aa', '97b6b7f0e47f149b0723b0787b0721', '7f0e27f0e47f531b0723b0b6fb0722', - '7f0e397bd07f595b0b0bc920fb0722', '9778397bd097c36b0b6fc9210c8dc2', '977837f0e37f149b0723b0787b0721', - '7f07e7f0e47f531b0723b0b6fb0722', '7f0e37f5307f595b0b0bc920fb0722', '7f0e397bd097c35b0b6fc9210c8dc2', - '977837f0e37f14998082b0787b0721', '7f07e7f0e47f531b0723b0b6fb0721', '7f0e37f1487f595b0b0bb0b6fb0722', - '7f0e397bd097c35b0b6fc9210c8dc2', '977837f0e37f14998082b0787b06bd', '7f07e7f0e47f531b0723b0b6fb0721', - '7f0e27f1487f531b0b0bb0b6fb0722', '7f0e397bd097c35b0b6fc920fb0722', '977837f0e37f14998082b0787b06bd', - '7f07e7f0e47f531b0723b0b6fb0721', '7f0e27f1487f531b0b0bb0b6fb0722', '7f0e397bd097c35b0b6fc920fb0722', - '977837f0e37f14998082b0787b06bd', '7f07e7f0e47f531b0723b0b6fb0721', '7f0e27f1487f531b0b0bb0b6fb0722', - '7f0e397bd07f595b0b0bc920fb0722', '977837f0e37f14998082b0787b06bd', '7f07e7f0e47f531b0723b0b6fb0721', - '7f0e27f1487f531b0b0bb0b6fb0722', '7f0e397bd07f595b0b0bc920fb0722', '977837f0e37f14998082b0787b06bd', - '7f07e7f0e47f149b0723b0787b0721', '7f0e27f0e47f531b0b0bb0b6fb0722', '7f0e397bd07f595b0b0bc920fb0722', - '977837f0e37f14998082b0723b06bd', '7f07e7f0e37f149b0723b0787b0721', '7f0e27f0e47f531b0723b0b6fb0722', - '7f0e397bd07f595b0b0bc920fb0722', '977837f0e37f14898082b0723b02d5', '7ec967f0e37f14998082b0787b0721', - '7f07e7f0e47f531b0723b0b6fb0722', '7f0e37f1487f595b0b0bb0b6fb0722', '7f0e37f0e37f14898082b0723b02d5', - '7ec967f0e37f14998082b0787b0721', '7f07e7f0e47f531b0723b0b6fb0722', '7f0e37f1487f531b0b0bb0b6fb0722', - '7f0e37f0e37f14898082b0723b02d5', '7ec967f0e37f14998082b0787b06bd', '7f07e7f0e47f531b0723b0b6fb0721', - '7f0e37f1487f531b0b0bb0b6fb0722', '7f0e37f0e37f14898082b072297c35', '7ec967f0e37f14998082b0787b06bd', - '7f07e7f0e47f531b0723b0b6fb0721', '7f0e27f1487f531b0b0bb0b6fb0722', '7f0e37f0e37f14898082b072297c35', - '7ec967f0e37f14998082b0787b06bd', '7f07e7f0e47f531b0723b0b6fb0721', '7f0e27f1487f531b0b0bb0b6fb0722', - '7f0e37f0e366aa89801eb072297c35', '7ec967f0e37f14998082b0787b06bd', '7f07e7f0e47f149b0723b0787b0721', - '7f0e27f1487f531b0b0bb0b6fb0722', '7f0e37f0e366aa89801eb072297c35', '7ec967f0e37f14998082b0723b06bd', - '7f07e7f0e47f149b0723b0787b0721', '7f0e27f0e47f531b0723b0b6fb0722', '7f0e37f0e366aa89801eb072297c35', - '7ec967f0e37f14998082b0723b06bd', '7f07e7f0e37f14998083b0787b0721', '7f0e27f0e47f531b0723b0b6fb0722', - '7f0e37f0e366aa89801eb072297c35', '7ec967f0e37f14898082b0723b02d5', '7f07e7f0e37f14998082b0787b0721', - '7f07e7f0e47f531b0723b0b6fb0722', '7f0e36665b66aa89801e9808297c35', '665f67f0e37f14898082b0723b02d5', - '7ec967f0e37f14998082b0787b0721', '7f07e7f0e47f531b0723b0b6fb0722', '7f0e36665b66a449801e9808297c35', - '665f67f0e37f14898082b0723b02d5', '7ec967f0e37f14998082b0787b06bd', '7f07e7f0e47f531b0723b0b6fb0721', - '7f0e36665b66a449801e9808297c35', '665f67f0e37f14898082b072297c35', '7ec967f0e37f14998082b0787b06bd', - '7f07e7f0e47f531b0723b0b6fb0721', '7f0e26665b66a449801e9808297c35', '665f67f0e37f1489801eb072297c35', - '7ec967f0e37f14998082b0787b06bd', '7f07e7f0e47f531b0723b0b6fb0721', '7f0e27f1487f531b0b0bb0b6fb0722'], - - /** - * 数字转中文速查表 - * @Array Of Property - * @trans ['日','一','二','三','四','五','六','七','八','九','十'] - * @return Cn string - */ - nStr1: ['\u65e5', '\u4e00', '\u4e8c', '\u4e09', '\u56db', '\u4e94', '\u516d', '\u4e03', '\u516b', '\u4e5d', '\u5341'], - - /** - * 日期转农历称呼速查表 - * @Array Of Property - * @trans ['初','十','廿','卅'] - * @return Cn string - */ - nStr2: ['\u521d', '\u5341', '\u5eff', '\u5345'], - - /** - * 月份转农历称呼速查表 - * @Array Of Property - * @trans ['正','一','二','三','四','五','六','七','八','九','十','冬','腊'] - * @return Cn string - */ - nStr3: ['\u6b63', '\u4e8c', '\u4e09', '\u56db', '\u4e94', '\u516d', '\u4e03', '\u516b', '\u4e5d', '\u5341', '\u51ac', '\u814a'], - - /** - * 返回农历y年一整年的总天数 - * @param lunar Year - * @return Number - * @eg:var count = calendar.lYearDays(1987) ;//count=387 - */ - lYearDays: function (y) { - var i; var sum = 348 - for (i = 0x8000; i > 0x8; i >>= 1) { sum += (this.lunarInfo[y - 1900] & i) ? 1 : 0 } - return (sum + this.leapDays(y)) - }, - - /** - * 返回农历y年闰月是哪个月;若y年没有闰月 则返回0 - * @param lunar Year - * @return Number (0-12) - * @eg:var leapMonth = calendar.leapMonth(1987) ;//leapMonth=6 - */ - leapMonth: function (y) { // 闰字编码 \u95f0 - return (this.lunarInfo[y - 1900] & 0xf) - }, - - /** - * 返回农历y年闰月的天数 若该年没有闰月则返回0 - * @param lunar Year - * @return Number (0、29、30) - * @eg:var leapMonthDay = calendar.leapDays(1987) ;//leapMonthDay=29 - */ - leapDays: function (y) { - if (this.leapMonth(y)) { - return ((this.lunarInfo[y - 1900] & 0x10000) ? 30 : 29) - } - return (0) - }, - - /** - * 返回农历y年m月(非闰月)的总天数,计算m为闰月时的天数请使用leapDays方法 - * @param lunar Year - * @return Number (-1、29、30) - * @eg:var MonthDay = calendar.monthDays(1987,9) ;//MonthDay=29 - */ - monthDays: function (y, m) { - if (m > 12 || m < 1) { return -1 }// 月份参数从1至12,参数错误返回-1 - return ((this.lunarInfo[y - 1900] & (0x10000 >> m)) ? 30 : 29) - }, - - /** - * 返回公历(!)y年m月的天数 - * @param solar Year - * @return Number (-1、28、29、30、31) - * @eg:var solarMonthDay = calendar.leapDays(1987) ;//solarMonthDay=30 - */ - solarDays: function (y, m) { - if (m > 12 || m < 1) { return -1 } // 若参数错误 返回-1 - var ms = m - 1 - if (ms == 1) { // 2月份的闰平规律测算后确认返回28或29 - return (((y % 4 == 0) && (y % 100 != 0) || (y % 400 == 0)) ? 29 : 28) - } else { - return (this.solarMonth[ms]) - } - }, - - /** - * 农历年份转换为干支纪年 - * @param lYear 农历年的年份数 - * @return Cn string - */ - toGanZhiYear: function (lYear) { - var ganKey = (lYear - 3) % 10 - var zhiKey = (lYear - 3) % 12 - if (ganKey == 0) ganKey = 10// 如果余数为0则为最后一个天干 - if (zhiKey == 0) zhiKey = 12// 如果余数为0则为最后一个地支 - return this.Gan[ganKey - 1] + this.Zhi[zhiKey - 1] - }, - - /** - * 公历月、日判断所属星座 - * @param cMonth [description] - * @param cDay [description] - * @return Cn string - */ - toAstro: function (cMonth, cDay) { - var s = '\u9b54\u7faf\u6c34\u74f6\u53cc\u9c7c\u767d\u7f8a\u91d1\u725b\u53cc\u5b50\u5de8\u87f9\u72ee\u5b50\u5904\u5973\u5929\u79e4\u5929\u874e\u5c04\u624b\u9b54\u7faf' - var arr = [20, 19, 21, 21, 21, 22, 23, 23, 23, 23, 22, 22] - return s.substr(cMonth * 2 - (cDay < arr[cMonth - 1] ? 2 : 0), 2) + '\u5ea7'// 座 - }, - - /** - * 传入offset偏移量返回干支 - * @param offset 相对甲子的偏移量 - * @return Cn string - */ - toGanZhi: function (offset) { - return this.Gan[offset % 10] + this.Zhi[offset % 12] - }, - - /** - * 传入公历(!)y年获得该年第n个节气的公历日期 - * @param y公历年(1900-2100);n二十四节气中的第几个节气(1~24);从n=1(小寒)算起 - * @return day Number - * @eg:var _24 = calendar.getTerm(1987,3) ;//_24=4;意即1987年2月4日立春 - */ - getTerm: function (y, n) { - if (y < 1900 || y > 2100) { return -1 } - if (n < 1 || n > 24) { return -1 } - var _table = this.sTermInfo[y - 1900] - var _info = [ - parseInt('0x' + _table.substr(0, 5)).toString(), - parseInt('0x' + _table.substr(5, 5)).toString(), - parseInt('0x' + _table.substr(10, 5)).toString(), - parseInt('0x' + _table.substr(15, 5)).toString(), - parseInt('0x' + _table.substr(20, 5)).toString(), - parseInt('0x' + _table.substr(25, 5)).toString() - ] - var _calday = [ - _info[0].substr(0, 1), - _info[0].substr(1, 2), - _info[0].substr(3, 1), - _info[0].substr(4, 2), - - _info[1].substr(0, 1), - _info[1].substr(1, 2), - _info[1].substr(3, 1), - _info[1].substr(4, 2), - - _info[2].substr(0, 1), - _info[2].substr(1, 2), - _info[2].substr(3, 1), - _info[2].substr(4, 2), - - _info[3].substr(0, 1), - _info[3].substr(1, 2), - _info[3].substr(3, 1), - _info[3].substr(4, 2), - - _info[4].substr(0, 1), - _info[4].substr(1, 2), - _info[4].substr(3, 1), - _info[4].substr(4, 2), - - _info[5].substr(0, 1), - _info[5].substr(1, 2), - _info[5].substr(3, 1), - _info[5].substr(4, 2) - ] - return parseInt(_calday[n - 1]) - }, - - /** - * 传入农历数字月份返回汉语通俗表示法 - * @param lunar month - * @return Cn string - * @eg:var cnMonth = calendar.toChinaMonth(12) ;//cnMonth='腊月' - */ - toChinaMonth: function (m) { // 月 => \u6708 - if (m > 12 || m < 1) { return -1 } // 若参数错误 返回-1 - var s = this.nStr3[m - 1] - s += '\u6708'// 加上月字 - return s - }, - - /** - * 传入农历日期数字返回汉字表示法 - * @param lunar day - * @return Cn string - * @eg:var cnDay = calendar.toChinaDay(21) ;//cnMonth='廿一' - */ - toChinaDay: function (d) { // 日 => \u65e5 - var s - switch (d) { - case 10: - s = '\u521d\u5341'; break - case 20: - s = '\u4e8c\u5341'; break - break - case 30: - s = '\u4e09\u5341'; break - break - default : - s = this.nStr2[Math.floor(d / 10)] - s += this.nStr1[d % 10] - } - return (s) - }, - - /** - * 年份转生肖[!仅能大致转换] => 精确划分生肖分界线是“立春” - * @param y year - * @return Cn string - * @eg:var animal = calendar.getAnimal(1987) ;//animal='兔' - */ - getAnimal: function (y) { - return this.Animals[(y - 4) % 12] - }, - - /** - * 传入阳历年月日获得详细的公历、农历object信息 <=>JSON - * @param y solar year - * @param m solar month - * @param d solar day - * @return JSON object - * @eg:console.log(calendar.solar2lunar(1987,11,01)); - */ - solar2lunar: function (y, m, d) { // 参数区间1900.1.31~2100.12.31 - // 年份限定、上限 - if (y < 1900 || y > 2100) { - return -1// undefined转换为数字变为NaN - } - // 公历传参最下限 - if (y == 1900 && m == 1 && d < 31) { - return -1 - } - // 未传参 获得当天 - if (!y) { - var objDate = new Date() - } else { - var objDate = new Date(y, parseInt(m) - 1, d) - } - var i; var leap = 0; var temp = 0 - // 修正ymd参数 - var y = objDate.getFullYear() - var m = objDate.getMonth() + 1 - var d = objDate.getDate() - var offset = (Date.UTC(objDate.getFullYear(), objDate.getMonth(), objDate.getDate()) - Date.UTC(1900, 0, 31)) / 86400000 - for (i = 1900; i < 2101 && offset > 0; i++) { - temp = this.lYearDays(i) - offset -= temp - } - if (offset < 0) { - offset += temp; i-- - } - - // 是否今天 - var isTodayObj = new Date() - var isToday = false - if (isTodayObj.getFullYear() == y && isTodayObj.getMonth() + 1 == m && isTodayObj.getDate() == d) { - isToday = true - } - // 星期几 - var nWeek = objDate.getDay() - var cWeek = this.nStr1[nWeek] - // 数字表示周几顺应天朝周一开始的惯例 - if (nWeek == 0) { - nWeek = 7 - } - // 农历年 - var year = i - var leap = this.leapMonth(i) // 闰哪个月 - var isLeap = false - - // 效验闰月 - for (i = 1; i < 13 && offset > 0; i++) { - // 闰月 - if (leap > 0 && i == (leap + 1) && isLeap == false) { - --i - isLeap = true; temp = this.leapDays(year) // 计算农历闰月天数 - } else { - temp = this.monthDays(year, i)// 计算农历普通月天数 - } - // 解除闰月 - if (isLeap == true && i == (leap + 1)) { isLeap = false } - offset -= temp - } - // 闰月导致数组下标重叠取反 - if (offset == 0 && leap > 0 && i == leap + 1) { - if (isLeap) { - isLeap = false - } else { - isLeap = true; --i - } - } - if (offset < 0) { - offset += temp; --i - } - // 农历月 - var month = i - // 农历日 - var day = offset + 1 - // 天干地支处理 - var sm = m - 1 - var gzY = this.toGanZhiYear(year) - - // 当月的两个节气 - // bugfix-2017-7-24 11:03:38 use lunar Year Param `y` Not `year` - var firstNode = this.getTerm(y, (m * 2 - 1))// 返回当月「节」为几日开始 - var secondNode = this.getTerm(y, (m * 2))// 返回当月「节」为几日开始 - - // 依据12节气修正干支月 - var gzM = this.toGanZhi((y - 1900) * 12 + m + 11) - if (d >= firstNode) { - gzM = this.toGanZhi((y - 1900) * 12 + m + 12) - } - - // 传入的日期的节气与否 - var isTerm = false - var Term = null - if (firstNode == d) { - isTerm = true - Term = this.solarTerm[m * 2 - 2] - } - if (secondNode == d) { - isTerm = true - Term = this.solarTerm[m * 2 - 1] - } - // 日柱 当月一日与 1900/1/1 相差天数 - var dayCyclical = Date.UTC(y, sm, 1, 0, 0, 0, 0) / 86400000 + 25567 + 10 - var gzD = this.toGanZhi(dayCyclical + d - 1) - // 该日期所属的星座 - var astro = this.toAstro(m, d) - - return { 'lYear': year, 'lMonth': month, 'lDay': day, 'Animal': this.getAnimal(year), 'IMonthCn': (isLeap ? '\u95f0' : '') + this.toChinaMonth(month), 'IDayCn': this.toChinaDay(day), 'cYear': y, 'cMonth': m, 'cDay': d, 'gzYear': gzY, 'gzMonth': gzM, 'gzDay': gzD, 'isToday': isToday, 'isLeap': isLeap, 'nWeek': nWeek, 'ncWeek': '\u661f\u671f' + cWeek, 'isTerm': isTerm, 'Term': Term, 'astro': astro } - }, - - /** - * 传入农历年月日以及传入的月份是否闰月获得详细的公历、农历object信息 <=>JSON - * @param y lunar year - * @param m lunar month - * @param d lunar day - * @param isLeapMonth lunar month is leap or not.[如果是农历闰月第四个参数赋值true即可] - * @return JSON object - * @eg:console.log(calendar.lunar2solar(1987,9,10)); - */ - lunar2solar: function (y, m, d, isLeapMonth) { // 参数区间1900.1.31~2100.12.1 - var isLeapMonth = !!isLeapMonth - var leapOffset = 0 - var leapMonth = this.leapMonth(y) - var leapDay = this.leapDays(y) - if (isLeapMonth && (leapMonth != m)) { return -1 }// 传参要求计算该闰月公历 但该年得出的闰月与传参的月份并不同 - if (y == 2100 && m == 12 && d > 1 || y == 1900 && m == 1 && d < 31) { return -1 }// 超出了最大极限值 - var day = this.monthDays(y, m) - var _day = day - // bugFix 2016-9-25 - // if month is leap, _day use leapDays method - if (isLeapMonth) { - _day = this.leapDays(y, m) - } - if (y < 1900 || y > 2100 || d > _day) { return -1 }// 参数合法性效验 - - // 计算农历的时间差 - var offset = 0 - for (var i = 1900; i < y; i++) { - offset += this.lYearDays(i) - } - var leap = 0; var isAdd = false - for (var i = 1; i < m; i++) { - leap = this.leapMonth(y) - if (!isAdd) { // 处理闰月 - if (leap <= i && leap > 0) { - offset += this.leapDays(y); isAdd = true - } - } - offset += this.monthDays(y, i) - } - // 转换闰月农历 需补充该年闰月的前一个月的时差 - if (isLeapMonth) { offset += day } - // 1900年农历正月一日的公历时间为1900年1月30日0时0分0秒(该时间也是本农历的最开始起始点) - var stmap = Date.UTC(1900, 1, 30, 0, 0, 0) - var calObj = new Date((offset + d - 31) * 86400000 + stmap) - var cY = calObj.getUTCFullYear() - var cM = calObj.getUTCMonth() + 1 - var cD = calObj.getUTCDate() - - return this.solar2lunar(cY, cM, cD) - } -} - -export default calendar diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/en.json b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/en.json deleted file mode 100644 index fcbd13cf..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/en.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "uni-calender.ok": "ok", - "uni-calender.cancel": "cancel", - "uni-calender.today": "today", - "uni-calender.MON": "MON", - "uni-calender.TUE": "TUE", - "uni-calender.WED": "WED", - "uni-calender.THU": "THU", - "uni-calender.FRI": "FRI", - "uni-calender.SAT": "SAT", - "uni-calender.SUN": "SUN" -} diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/index.js b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/zh-Hans.json deleted file mode 100644 index 1ca43de0..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/zh-Hans.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "uni-calender.ok": "确定", - "uni-calender.cancel": "取消", - "uni-calender.today": "今日", - "uni-calender.SUN": "日", - "uni-calender.MON": "一", - "uni-calender.TUE": "二", - "uni-calender.WED": "三", - "uni-calender.THU": "四", - "uni-calender.FRI": "五", - "uni-calender.SAT": "六" -} diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/zh-Hant.json deleted file mode 100644 index e0fe33b9..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/i18n/zh-Hant.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "uni-calender.ok": "確定", - "uni-calender.cancel": "取消", - "uni-calender.today": "今日", - "uni-calender.SUN": "日", - "uni-calender.MON": "一", - "uni-calender.TUE": "二", - "uni-calender.WED": "三", - "uni-calender.THU": "四", - "uni-calender.FRI": "五", - "uni-calender.SAT": "六" -} diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/uni-calendar-item.vue b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/uni-calendar-item.vue deleted file mode 100644 index 30bd6c84..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/uni-calendar-item.vue +++ /dev/null @@ -1,188 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/uni-calendar.vue b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/uni-calendar.vue deleted file mode 100644 index 88381db7..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/uni-calendar.vue +++ /dev/null @@ -1,562 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/util.js b/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/util.js deleted file mode 100644 index 2d6100bf..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/components/uni-calendar/util.js +++ /dev/null @@ -1,350 +0,0 @@ -import CALENDAR from './calendar.js' - -class Calendar { - constructor({ - date, - selected, - startDate, - endDate, - range - } = {}) { - // 当前日期 - this.date = this.getDate(new Date()) // 当前初入日期 - // 打点信息 - this.selected = selected || []; - // 范围开始 - this.startDate = startDate - // 范围结束 - this.endDate = endDate - this.range = range - // 多选状态 - this.cleanMultipleStatus() - // 每周日期 - this.weeks = {} - // this._getWeek(this.date.fullDate) - } - /** - * 设置日期 - * @param {Object} date - */ - setDate(date) { - this.selectDate = this.getDate(date) - this._getWeek(this.selectDate.fullDate) - } - - /** - * 清理多选状态 - */ - cleanMultipleStatus() { - this.multipleStatus = { - before: '', - after: '', - data: [] - } - } - - /** - * 重置开始日期 - */ - resetSatrtDate(startDate) { - // 范围开始 - this.startDate = startDate - - } - - /** - * 重置结束日期 - */ - resetEndDate(endDate) { - // 范围结束 - this.endDate = endDate - } - - /** - * 获取任意时间 - */ - getDate(date, AddDayCount = 0, str = 'day') { - if (!date) { - date = new Date() - } - if (typeof date !== 'object') { - date = date.replace(/-/g, '/') - } - const dd = new Date(date) - switch (str) { - case 'day': - dd.setDate(dd.getDate() + AddDayCount) // 获取AddDayCount天后的日期 - break - case 'month': - if (dd.getDate() === 31) { - dd.setDate(dd.getDate() + AddDayCount) - } else { - dd.setMonth(dd.getMonth() + AddDayCount) // 获取AddDayCount天后的日期 - } - break - case 'year': - dd.setFullYear(dd.getFullYear() + AddDayCount) // 获取AddDayCount天后的日期 - break - } - const y = dd.getFullYear() - const m = dd.getMonth() + 1 < 10 ? '0' + (dd.getMonth() + 1) : dd.getMonth() + 1 // 获取当前月份的日期,不足10补0 - const d = dd.getDate() < 10 ? '0' + dd.getDate() : dd.getDate() // 获取当前几号,不足10补0 - return { - fullDate: y + '-' + m + '-' + d, - year: y, - month: m, - date: d, - day: dd.getDay() - } - } - - - /** - * 获取上月剩余天数 - */ - _getLastMonthDays(firstDay, full) { - let dateArr = [] - for (let i = firstDay; i > 0; i--) { - const beforeDate = new Date(full.year, full.month - 1, -i + 1).getDate() - dateArr.push({ - date: beforeDate, - month: full.month - 1, - lunar: this.getlunar(full.year, full.month - 1, beforeDate), - disable: true - }) - } - return dateArr - } - /** - * 获取本月天数 - */ - _currentMonthDys(dateData, full) { - let dateArr = [] - let fullDate = this.date.fullDate - for (let i = 1; i <= dateData; i++) { - let nowDate = full.year + '-' + (full.month < 10 ? - full.month : full.month) + '-' + (i < 10 ? - '0' + i : i) - // 是否今天 - let isDay = fullDate === nowDate - // 获取打点信息 - let info = this.selected && this.selected.find((item) => { - if (this.dateEqual(nowDate, item.date)) { - return item - } - }) - - // 日期禁用 - let disableBefore = true - let disableAfter = true - if (this.startDate) { - // let dateCompBefore = this.dateCompare(this.startDate, fullDate) - // disableBefore = this.dateCompare(dateCompBefore ? this.startDate : fullDate, nowDate) - disableBefore = this.dateCompare(this.startDate, nowDate) - } - - if (this.endDate) { - // let dateCompAfter = this.dateCompare(fullDate, this.endDate) - // disableAfter = this.dateCompare(nowDate, dateCompAfter ? this.endDate : fullDate) - disableAfter = this.dateCompare(nowDate, this.endDate) - } - let multiples = this.multipleStatus.data - let checked = false - let multiplesStatus = -1 - if (this.range) { - if (multiples) { - multiplesStatus = multiples.findIndex((item) => { - return this.dateEqual(item, nowDate) - }) - } - if (multiplesStatus !== -1) { - checked = true - } - } - let data = { - fullDate: nowDate, - year: full.year, - date: i, - multiple: this.range ? checked : false, - beforeMultiple: this.dateEqual(this.multipleStatus.before, nowDate), - afterMultiple: this.dateEqual(this.multipleStatus.after, nowDate), - month: full.month, - lunar: this.getlunar(full.year, full.month, i), - disable: !(disableBefore && disableAfter), - isDay - } - if (info) { - data.extraInfo = info - } - - dateArr.push(data) - } - return dateArr - } - /** - * 获取下月天数 - */ - _getNextMonthDays(surplus, full) { - let dateArr = [] - for (let i = 1; i < surplus + 1; i++) { - dateArr.push({ - date: i, - month: Number(full.month) + 1, - lunar: this.getlunar(full.year, Number(full.month) + 1, i), - disable: true - }) - } - return dateArr - } - - /** - * 获取当前日期详情 - * @param {Object} date - */ - getInfo(date) { - if (!date) { - date = new Date() - } - const dateInfo = this.canlender.find(item => item.fullDate === this.getDate(date).fullDate) - return dateInfo - } - - /** - * 比较时间大小 - */ - dateCompare(startDate, endDate) { - // 计算截止时间 - startDate = new Date(startDate.replace('-', '/').replace('-', '/')) - // 计算详细项的截止时间 - endDate = new Date(endDate.replace('-', '/').replace('-', '/')) - if (startDate <= endDate) { - return true - } else { - return false - } - } - - /** - * 比较时间是否相等 - */ - dateEqual(before, after) { - // 计算截止时间 - before = new Date(before.replace('-', '/').replace('-', '/')) - // 计算详细项的截止时间 - after = new Date(after.replace('-', '/').replace('-', '/')) - if (before.getTime() - after.getTime() === 0) { - return true - } else { - return false - } - } - - - /** - * 获取日期范围内所有日期 - * @param {Object} begin - * @param {Object} end - */ - geDateAll(begin, end) { - var arr = [] - var ab = begin.split('-') - var ae = end.split('-') - var db = new Date() - db.setFullYear(ab[0], ab[1] - 1, ab[2]) - var de = new Date() - de.setFullYear(ae[0], ae[1] - 1, ae[2]) - var unixDb = db.getTime() - 24 * 60 * 60 * 1000 - var unixDe = de.getTime() - 24 * 60 * 60 * 1000 - for (var k = unixDb; k <= unixDe;) { - k = k + 24 * 60 * 60 * 1000 - arr.push(this.getDate(new Date(parseInt(k))).fullDate) - } - return arr - } - /** - * 计算阴历日期显示 - */ - getlunar(year, month, date) { - return CALENDAR.solar2lunar(year, month, date) - } - /** - * 设置打点 - */ - setSelectInfo(data, value) { - this.selected = value - this._getWeek(data) - } - - /** - * 获取多选状态 - */ - setMultiple(fullDate) { - let { - before, - after - } = this.multipleStatus - - if (!this.range) return - if (before && after) { - this.multipleStatus.before = '' - this.multipleStatus.after = '' - this.multipleStatus.data = [] - } else { - if (!before) { - this.multipleStatus.before = fullDate - } else { - this.multipleStatus.after = fullDate - if (this.dateCompare(this.multipleStatus.before, this.multipleStatus.after)) { - this.multipleStatus.data = this.geDateAll(this.multipleStatus.before, this.multipleStatus.after); - } else { - this.multipleStatus.data = this.geDateAll(this.multipleStatus.after, this.multipleStatus.before); - } - } - } - this._getWeek(fullDate) - } - - /** - * 获取每周数据 - * @param {Object} dateData - */ - _getWeek(dateData) { - const { - year, - month - } = this.getDate(dateData) - let firstDay = new Date(year, month - 1, 1).getDay() - let currentDay = new Date(year, month, 0).getDate() - let dates = { - lastMonthDays: this._getLastMonthDays(firstDay, this.getDate(dateData)), // 上个月末尾几天 - currentMonthDys: this._currentMonthDys(currentDay, this.getDate(dateData)), // 本月天数 - nextMonthDays: [], // 下个月开始几天 - weeks: [] - } - let canlender = [] - const surplus = 42 - (dates.lastMonthDays.length + dates.currentMonthDys.length) - dates.nextMonthDays = this._getNextMonthDays(surplus, this.getDate(dateData)) - canlender = canlender.concat(dates.lastMonthDays, dates.currentMonthDys, dates.nextMonthDays) - let weeks = {} - // 拼接数组 上个月开始几天 + 本月天数+ 下个月开始几天 - for (let i = 0; i < canlender.length; i++) { - if (i % 7 === 0) { - weeks[parseInt(i / 7)] = new Array(7) - } - weeks[parseInt(i / 7)][i % 7] = canlender[i] - } - this.canlender = canlender - this.weeks = weeks - } - - //静态方法 - // static init(date) { - // if (!this.instance) { - // this.instance = new Calendar(date); - // } - // return this.instance; - // } -} - - -export default Calendar diff --git a/blog-uniapp/uni_modules/uni-calendar/package.json b/blog-uniapp/uni_modules/uni-calendar/package.json deleted file mode 100644 index 40455c87..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-calendar", - "displayName": "uni-calendar 日历", - "version": "1.4.5", - "description": "日历组件", - "keywords": [ - "uni-ui", - "uniui", - "日历", - "", - "打卡", - "日历选择" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-calendar/readme.md b/blog-uniapp/uni_modules/uni-calendar/readme.md deleted file mode 100644 index 4f3ca0e8..00000000 --- a/blog-uniapp/uni_modules/uni-calendar/readme.md +++ /dev/null @@ -1,103 +0,0 @@ - - -## Calendar 日历 -> **组件名:uni-calendar** -> 代码块: `uCalendar` - - -日历组件 - -> **注意事项** -> 为了避免错误使用,给大家带来不好的开发体验,请在使用组件前仔细阅读下面的注意事项,可以帮你避免一些错误。 -> - 本组件农历转换使用的js是 [@1900-2100区间内的公历、农历互转](https://github.com/jjonline/calendar.js) -> - 仅支持自定义组件模式 -> - `date`属性传入的应该是一个 String ,如: 2019-06-27 ,而不是 new Date() -> - 通过 `insert` 属性来确定当前的事件是 @change 还是 @confirm 。理应合并为一个事件,但是为了区分模式,现使用两个事件,这里需要注意 -> - 弹窗模式下无法阻止后面的元素滚动,如有需要阻止,请在弹窗弹出后,手动设置滚动元素为不可滚动 - - -### 安装方式 - -本组件符合[easycom](https://uniapp.dcloud.io/collocation/pages?id=easycom)规范,`HBuilderX 2.5.5`起,只需将本组件导入项目,在页面`template`中即可直接使用,无需在页面中`import`和注册`components`。 - -如需通过`npm`方式使用`uni-ui`组件,另见文档:[https://ext.dcloud.net.cn/plugin?id=55](https://ext.dcloud.net.cn/plugin?id=55) - -### 基本用法 - -在 ``template`` 中使用组件 - -```html - - - -``` - -### 通过方法打开日历 - -需要设置 `insert` 为 `false` - -```html - - - - -``` - -```javascript - -export default { - data() { - return {}; - }, - methods: { - open(){ - this.$refs.calendar.open(); - }, - confirm(e) { - console.log(e); - } - } -}; - -``` - - -## API - -### Calendar Props - -| 属性名 | 类型 | 默认值| 说明 | -| | | -| date | String |- | 自定义当前时间,默认为今天 | -| lunar | Boolean | false | 显示农历 | -| startDate | String |- | 日期选择范围-开始日期 | -| endDate | String |- | 日期选择范围-结束日期 | -| range | Boolean | false | 范围选择 | -| insert | Boolean | false | 插入模式,可选值,ture:插入模式;false:弹窗模式;默认为插入模式 | -|clearDate |Boolean |true |弹窗模式是否清空上次选择内容 | -| selected | Array |- | 打点,期待格式[{date: '2019-06-27', info: '签到', data: { custom: '自定义信息', name: '自定义消息头',xxx:xxx... }}] | -|showMonth | Boolean | true | 是否显示月份为背景 | - -### Calendar Events - -| 事件名 | 说明 |返回值| -| | | | -| open | 弹出日历组件,`insert :false` 时生效|- | - - - - - -## 组件示例 - -点击查看:[https://hellouniapp.dcloud.net.cn/pages/extUI/calendar/calendar](https://hellouniapp.dcloud.net.cn/pages/extUI/calendar/calendar) \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-card/changelog.md b/blog-uniapp/uni_modules/uni-card/changelog.md deleted file mode 100644 index c3cd8c45..00000000 --- a/blog-uniapp/uni_modules/uni-card/changelog.md +++ /dev/null @@ -1,26 +0,0 @@ -## 1.3.1(2021-12-20) -- 修复 在vue页面下略缩图显示不正常的bug -## 1.3.0(2021-11-19) -- 重构插槽的用法 ,header 替换为 title -- 新增 actions 插槽 -- 新增 cover 封面图属性和插槽 -- 新增 padding 内容默认内边距离 -- 新增 margin 卡片默认外边距离 -- 新增 spacing 卡片默认内边距 -- 新增 shadow 卡片阴影属性 -- 取消 mode 属性,可使用组合插槽代替 -- 取消 note 属性 ,使用actions插槽代替 -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-card](https://uniapp.dcloud.io/component/uniui/uni-card) -## 1.2.1(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.2.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.1.8(2021-07-01) -- 优化 图文卡片无图片加载时,提供占位图标 -- 新增 header 插槽,自定义卡片头部( 图文卡片 mode="style" 时,不支持) -- 修复 thumbnail 不存在仍然占位的 bug -## 1.1.7(2021-05-12) -- 新增 组件示例地址 -## 1.1.6(2021-02-04) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-card/components/uni-card/uni-card.vue b/blog-uniapp/uni_modules/uni-card/components/uni-card/uni-card.vue deleted file mode 100644 index 38cf594c..00000000 --- a/blog-uniapp/uni_modules/uni-card/components/uni-card/uni-card.vue +++ /dev/null @@ -1,270 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-card/package.json b/blog-uniapp/uni_modules/uni-card/package.json deleted file mode 100644 index f16224de..00000000 --- a/blog-uniapp/uni_modules/uni-card/package.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "uni-card", - "displayName": "uni-card 卡片", - "version": "1.3.1", - "description": "Card 组件,提供常见的卡片样式。", - "keywords": [ - "uni-ui", - "uniui", - "card", - "", - "卡片" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-icons", - "uni-scss" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-card/readme.md b/blog-uniapp/uni_modules/uni-card/readme.md deleted file mode 100644 index 7434e71d..00000000 --- a/blog-uniapp/uni_modules/uni-card/readme.md +++ /dev/null @@ -1,12 +0,0 @@ - - -## Card 卡片 -> **组件名:uni-card** -> 代码块: `uCard` - -卡片视图组件。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-card) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-collapse/changelog.md b/blog-uniapp/uni_modules/uni-collapse/changelog.md deleted file mode 100644 index 292e4c79..00000000 --- a/blog-uniapp/uni_modules/uni-collapse/changelog.md +++ /dev/null @@ -1,36 +0,0 @@ -## 1.4.3(2022-01-25) -- 修复 初始化的时候 ,open 属性失效的bug -## 1.4.2(2022-01-21) -- 修复 微信小程序resize后组件收起的bug -## 1.4.1(2021-11-22) -- 修复 vue3中个别scss变量无法找到的问题 -## 1.4.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-collapse](https://uniapp.dcloud.io/component/uniui/uni-collapse) -## 1.3.3(2021-08-17) -- 优化 show-arrow 属性默认为true -## 1.3.2(2021-08-17) -- 新增 show-arrow 属性,控制是否显示右侧箭头 -## 1.3.1(2021-07-30) -- 优化 vue3下小程序事件警告的问题 -## 1.3.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.2.2(2021-07-21) -- 修复 由1.2.0版本引起的 change 事件返回 undefined 的Bug -## 1.2.1(2021-07-21) -- 优化 组件示例 -## 1.2.0(2021-07-21) -- 新增 组件折叠动画 -- 新增 value\v-model 属性 ,动态修改面板折叠状态 -- 新增 title 插槽 ,可定义面板标题 -- 新增 border 属性 ,显示隐藏面板内容分隔线 -- 新增 title-border 属性 ,显示隐藏面板标题分隔线 -- 修复 resize 方法失效的Bug -- 修复 change 事件返回参数不正确的Bug -- 优化 H5、App 平台自动更具内容更新高度,无需调用 reszie() 方法 -## 1.1.7(2021-05-12) -- 新增 组件示例地址 -## 1.1.6(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 -## 1.1.5(2021-02-05) -- 调整为uni_modules目录规范 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-collapse/components/uni-collapse-item/uni-collapse-item.vue b/blog-uniapp/uni_modules/uni-collapse/components/uni-collapse-item/uni-collapse-item.vue deleted file mode 100644 index d62a6a71..00000000 --- a/blog-uniapp/uni_modules/uni-collapse/components/uni-collapse-item/uni-collapse-item.vue +++ /dev/null @@ -1,402 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-collapse/components/uni-collapse/uni-collapse.vue b/blog-uniapp/uni_modules/uni-collapse/components/uni-collapse/uni-collapse.vue deleted file mode 100644 index 384c39a9..00000000 --- a/blog-uniapp/uni_modules/uni-collapse/components/uni-collapse/uni-collapse.vue +++ /dev/null @@ -1,147 +0,0 @@ - - - diff --git a/blog-uniapp/uni_modules/uni-collapse/package.json b/blog-uniapp/uni_modules/uni-collapse/package.json deleted file mode 100644 index 65349cf9..00000000 --- a/blog-uniapp/uni_modules/uni-collapse/package.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "id": "uni-collapse", - "displayName": "uni-collapse 折叠面板", - "version": "1.4.3", - "description": "Collapse 组件,可以折叠 / 展开的内容区域。", - "keywords": [ - "uni-ui", - "折叠", - "折叠面板", - "手风琴" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-collapse/readme.md b/blog-uniapp/uni_modules/uni-collapse/readme.md deleted file mode 100644 index bc758ebc..00000000 --- a/blog-uniapp/uni_modules/uni-collapse/readme.md +++ /dev/null @@ -1,12 +0,0 @@ - - -## Collapse 折叠面板 -> **组件名:uni-collapse** -> 代码块: `uCollapse` -> 关联组件:`uni-collapse-item`、`uni-icons`。 - - -折叠面板用来折叠/显示过长的内容或者是列表。通常是在多内容分类项使用,折叠不重要的内容,显示重要内容。点击可以展开折叠部分。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-collapse) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-combox/changelog.md b/blog-uniapp/uni_modules/uni-combox/changelog.md deleted file mode 100644 index 23c27485..00000000 --- a/blog-uniapp/uni_modules/uni-combox/changelog.md +++ /dev/null @@ -1,15 +0,0 @@ -## 1.0.1(2021-11-23) -- 优化 label、label-width 属性 -## 1.0.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-combox](https://uniapp.dcloud.io/component/uniui/uni-combox) -## 0.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 0.0.6(2021-05-12) -- 新增 组件示例地址 -## 0.0.5(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 0.0.4(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 -## 0.0.3(2021-02-04) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-combox/components/uni-combox/uni-combox.vue b/blog-uniapp/uni_modules/uni-combox/components/uni-combox/uni-combox.vue deleted file mode 100644 index 500b6f88..00000000 --- a/blog-uniapp/uni_modules/uni-combox/components/uni-combox/uni-combox.vue +++ /dev/null @@ -1,275 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-combox/package.json b/blog-uniapp/uni_modules/uni-combox/package.json deleted file mode 100644 index 4a05c3ff..00000000 --- a/blog-uniapp/uni_modules/uni-combox/package.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "uni-combox", - "displayName": "uni-combox 组合框", - "version": "1.0.1", - "description": "可以选择也可以输入的表单项 ", - "keywords": [ - "uni-ui", - "uniui", - "combox", - "组合框", - "select" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "n" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-combox/readme.md b/blog-uniapp/uni_modules/uni-combox/readme.md deleted file mode 100644 index ffa2cc86..00000000 --- a/blog-uniapp/uni_modules/uni-combox/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -## Combox 组合框 -> **组件名:uni-combox** -> 代码块: `uCombox` - - -组合框组件。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-combox) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-countdown/changelog.md b/blog-uniapp/uni_modules/uni-countdown/changelog.md deleted file mode 100644 index f25beefc..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/changelog.md +++ /dev/null @@ -1,24 +0,0 @@ -## 1.2.2(2022-01-19) -- 修复 在微信小程序中样式不生效的bug -## 1.2.1(2022-01-18) -- 新增 update 方法 ,在动态更新时间后,刷新组件 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-countdown](https://uniapp.dcloud.io/component/uniui/uni-countdown) -## 1.1.3(2021-10-18) -- 重构 -- 新增 font-size 支持自定义字体大小 -## 1.1.2(2021-08-24) -- 新增 支持国际化 -## 1.1.1(2021-07-30) -- 优化 vue3下小程序事件警告的问题 -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.5(2021-06-18) -- 修复 uni-countdown 重复赋值跳两秒的 bug -## 1.0.4(2021-05-12) -- 新增 组件示例地址 -## 1.0.3(2021-05-08) -- 修复 uni-countdown 不能控制倒计时的 bug -## 1.0.2(2021-02-04) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/en.json b/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/en.json deleted file mode 100644 index 06309cb0..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/en.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "uni-countdown.day": "day", - "uni-countdown.h": "h", - "uni-countdown.m": "m", - "uni-countdown.s": "s" -} diff --git a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/index.js b/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/zh-Hans.json deleted file mode 100644 index 358cdd16..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/zh-Hans.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "uni-countdown.day": "天", - "uni-countdown.h": "时", - "uni-countdown.m": "分", - "uni-countdown.s": "秒" -} diff --git a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/zh-Hant.json deleted file mode 100644 index e5a63dea..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/i18n/zh-Hant.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "uni-countdown.day": "天", - "uni-countdown.h": "時", - "uni-countdown.m": "分", - "uni-countdown.s": "秒" -} diff --git a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/uni-countdown.vue b/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/uni-countdown.vue deleted file mode 100644 index 1f8ef4eb..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/components/uni-countdown/uni-countdown.vue +++ /dev/null @@ -1,271 +0,0 @@ - - - diff --git a/blog-uniapp/uni_modules/uni-countdown/package.json b/blog-uniapp/uni_modules/uni-countdown/package.json deleted file mode 100644 index 70e99ee7..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/package.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "id": "uni-countdown", - "displayName": "uni-countdown 倒计时", - "version": "1.2.2", - "description": "CountDown 倒计时组件", - "keywords": [ - "uni-ui", - "uniui", - "countdown", - "倒计时" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-countdown/readme.md b/blog-uniapp/uni_modules/uni-countdown/readme.md deleted file mode 100644 index 4bcb1aa7..00000000 --- a/blog-uniapp/uni_modules/uni-countdown/readme.md +++ /dev/null @@ -1,10 +0,0 @@ - - -## CountDown 倒计时 -> **组件名:uni-countdown** -> 代码块: `uCountDown` - -倒计时组件。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-countdown) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-data-checkbox/changelog.md b/blog-uniapp/uni_modules/uni-data-checkbox/changelog.md deleted file mode 100644 index dbc517a3..00000000 --- a/blog-uniapp/uni_modules/uni-data-checkbox/changelog.md +++ /dev/null @@ -1,43 +0,0 @@ -## 1.0.2(2022-06-30) -- 优化 在 uni-forms 中的依赖注入方式 -## 1.0.1(2022-02-07) -- 修复 multiple 为 true 时,v-model 的值为 null 报错的 bug -## 1.0.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-data-checkbox](https://uniapp.dcloud.io/component/uniui/uni-data-checkbox) -## 0.2.5(2021-08-23) -- 修复 在uni-forms中 modelValue 中不存在当前字段,当前字段必填写也不参与校验的问题 -## 0.2.4(2021-08-17) -- 修复 单选 list 模式下 ,icon 为 left 时,选中图标不显示的问题 -## 0.2.3(2021-08-11) -- 修复 在 uni-forms 中重置表单,错误信息无法清除的问题 -## 0.2.2(2021-07-30) -- 优化 在uni-forms组件,与label不对齐的问题 -## 0.2.1(2021-07-27) -- 修复 单选默认值为0不能选中的Bug -## 0.2.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 0.1.11(2021-07-06) -- 优化 删除无用日志 -## 0.1.10(2021-07-05) -- 修复 由 0.1.9 引起的非 nvue 端图标不显示的问题 -## 0.1.9(2021-07-05) -- 修复 nvue 黑框样式问题 -## 0.1.8(2021-06-28) -- 修复 selectedTextColor 属性不生效的Bug -## 0.1.7(2021-06-02) -- 新增 map 属性,可以方便映射text/value属性 -## 0.1.6(2021-05-26) -- 修复 不关联服务空间的情况下组件报错的Bug -## 0.1.5(2021-05-12) -- 新增 组件示例地址 -## 0.1.4(2021-04-09) -- 修复 nvue 下无法选中的问题 -## 0.1.3(2021-03-22) -- 新增 disabled属性 -## 0.1.2(2021-02-24) -- 优化 默认颜色显示 -## 0.1.1(2021-02-24) -- 新增 支持nvue -## 0.1.0(2021-02-18) -- “暂无数据”显示居中 diff --git a/blog-uniapp/uni_modules/uni-data-checkbox/components/uni-data-checkbox/uni-data-checkbox.vue b/blog-uniapp/uni_modules/uni-data-checkbox/components/uni-data-checkbox/uni-data-checkbox.vue deleted file mode 100644 index 2e517123..00000000 --- a/blog-uniapp/uni_modules/uni-data-checkbox/components/uni-data-checkbox/uni-data-checkbox.vue +++ /dev/null @@ -1,817 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-data-checkbox/package.json b/blog-uniapp/uni_modules/uni-data-checkbox/package.json deleted file mode 100644 index 51470a95..00000000 --- a/blog-uniapp/uni_modules/uni-data-checkbox/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-data-checkbox", - "displayName": "uni-data-checkbox 数据选择器", - "version": "1.0.2", - "description": "通过数据驱动的单选框和复选框", - "keywords": [ - "uni-ui", - "checkbox", - "单选", - "多选", - "单选多选" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "^3.1.1" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-load-more","uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-data-checkbox/readme.md b/blog-uniapp/uni_modules/uni-data-checkbox/readme.md deleted file mode 100644 index 6eb253d4..00000000 --- a/blog-uniapp/uni_modules/uni-data-checkbox/readme.md +++ /dev/null @@ -1,18 +0,0 @@ - - -## DataCheckbox 数据驱动的单选复选框 -> **组件名:uni-data-checkbox** -> 代码块: `uDataCheckbox` - - -本组件是基于uni-app基础组件checkbox的封装。本组件要解决问题包括: - -1. 数据绑定型组件:给本组件绑定一个data,会自动渲染一组候选内容。再以往,开发者需要编写不少代码实现类似功能 -2. 自动的表单校验:组件绑定了data,且符合[uni-forms](https://ext.dcloud.net.cn/plugin?id=2773)组件的表单校验规范,搭配使用会自动实现表单校验 -3. 本组件合并了单选多选 -4. 本组件有若干风格选择,如普通的单选多选框、并列button风格、tag风格。开发者可以快速选择需要的风格。但作为一个封装组件,样式代码虽然不用自己写了,却会牺牲一定的样式自定义性 - -在uniCloud开发中,`DB Schema`中配置了enum枚举等类型后,在web控制台的[自动生成表单](https://uniapp.dcloud.io/uniCloud/schema?id=autocode)功能中,会自动生成``uni-data-checkbox``组件并绑定好data - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-data-checkbox) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-data-picker/changelog.md b/blog-uniapp/uni_modules/uni-data-picker/changelog.md deleted file mode 100644 index 083e521f..00000000 --- a/blog-uniapp/uni_modules/uni-data-picker/changelog.md +++ /dev/null @@ -1,64 +0,0 @@ -## 1.0.7(2022-07-06) -- 优化 pc端图标位置不正确的问题 -## 1.0.6(2022-07-05) -- 优化 显示样式 -## 1.0.5(2022-07-04) -- 修复 uni-data-picker 在 uni-forms-item 中宽度不正确的bug -## 1.0.4(2022-04-19) -- 修复 字节小程序 本地数据无法选择下一级的Bug -## 1.0.3(2022-02-25) -- 修复 nvue 不支持的 v-show 的 bug -## 1.0.2(2022-02-25) -- 修复 条件编译 nvue 不支持的 css 样式 -## 1.0.1(2021-11-23) -- 修复 由上个版本引发的map、v-model等属性不生效的bug -## 1.0.0(2021-11-19) -- 优化 组件 UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-data-picker](https://uniapp.dcloud.io/component/uniui/uni-data-picker) -## 0.4.9(2021-10-28) -- 修复 VUE2 v-model 概率无效的 bug -## 0.4.8(2021-10-27) -- 修复 v-model 概率无效的 bug -## 0.4.7(2021-10-25) -- 新增 属性 spaceInfo 服务空间配置 HBuilderX 3.2.11+ -- 修复 树型 uniCloud 数据类型为 int 时报错的 bug -## 0.4.6(2021-10-19) -- 修复 非 VUE3 v-model 为 0 时无法选中的 bug -## 0.4.5(2021-09-26) -- 新增 清除已选项的功能(通过 clearIcon 属性配置是否显示按钮),同时提供 clear 方法以供调用,二者等效 -- 修复 readonly 为 true 时报错的 bug -## 0.4.4(2021-09-26) -- 修复 上一版本造成的 map 属性失效的 bug -- 新增 ellipsis 属性,支持配置 tab 选项长度过长时是否自动省略 -## 0.4.3(2021-09-24) -- 修复 某些情况下级联未触发的 bug -## 0.4.2(2021-09-23) -- 新增 提供 show 和 hide 方法,开发者可以通过 ref 调用 -- 新增 选项内容过长自动添加省略号 -## 0.4.1(2021-09-15) -- 新增 map 属性 字段映射,将 text/value 映射到数据中的其他字段 -## 0.4.0(2021-07-13) -- 组件兼容 vue3,如何创建 vue3 项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 0.3.5(2021-06-04) -- 修复 无法加载云端数据的问题 -## 0.3.4(2021-05-28) -- 修复 v-model 无效问题 -- 修复 loaddata 为空数据组时加载时间过长问题 -- 修复 上个版本引出的本地数据无法选择带有 children 的 2 级节点 -## 0.3.3(2021-05-12) -- 新增 组件示例地址 -## 0.3.2(2021-04-22) -- 修复 非树形数据有 where 属性查询报错的问题 -## 0.3.1(2021-04-15) -- 修复 本地数据概率无法回显时问题 -## 0.3.0(2021-04-07) -- 新增 支持云端非树形表结构数据 -- 修复 根节点 parent_field 字段等于 null 时选择界面错乱问题 -## 0.2.0(2021-03-15) -- 修复 nodeclick、popupopened、popupclosed 事件无法触发的问题 -## 0.1.9(2021-03-09) -- 修复 微信小程序某些情况下无法选择的问题 -## 0.1.8(2021-02-05) -- 优化 部分样式在 nvue 上的兼容表现 -## 0.1.7(2021-02-05) -- 调整为 uni_modules 目录规范 diff --git a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-picker/keypress.js b/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-picker/keypress.js deleted file mode 100644 index 6ef26a26..00000000 --- a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-picker/keypress.js +++ /dev/null @@ -1,45 +0,0 @@ -// #ifdef H5 -export default { - name: 'Keypress', - props: { - disable: { - type: Boolean, - default: false - } - }, - mounted () { - const keyNames = { - esc: ['Esc', 'Escape'], - tab: 'Tab', - enter: 'Enter', - space: [' ', 'Spacebar'], - up: ['Up', 'ArrowUp'], - left: ['Left', 'ArrowLeft'], - right: ['Right', 'ArrowRight'], - down: ['Down', 'ArrowDown'], - delete: ['Backspace', 'Delete', 'Del'] - } - const listener = ($event) => { - if (this.disable) { - return - } - const keyName = Object.keys(keyNames).find(key => { - const keyName = $event.key - const value = keyNames[key] - return value === keyName || (Array.isArray(value) && value.includes(keyName)) - }) - if (keyName) { - // 避免和其他按键事件冲突 - setTimeout(() => { - this.$emit(keyName, {}) - }, 0) - } - } - document.addEventListener('keyup', listener) - this.$once('hook:beforeDestroy', () => { - document.removeEventListener('keyup', listener) - }) - }, - render: () => {} -} -// #endif diff --git a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue b/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue deleted file mode 100644 index 45536275..00000000 --- a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue +++ /dev/null @@ -1,554 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.js b/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.js deleted file mode 100644 index c12fd54b..00000000 --- a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.js +++ /dev/null @@ -1,563 +0,0 @@ -export default { - props: { - localdata: { - type: [Array, Object], - default () { - return [] - } - }, - spaceInfo: { - type: Object, - default () { - return {} - } - }, - collection: { - type: String, - default: '' - }, - action: { - type: String, - default: '' - }, - field: { - type: String, - default: '' - }, - orderby: { - type: String, - default: '' - }, - where: { - type: [String, Object], - default: '' - }, - pageData: { - type: String, - default: 'add' - }, - pageCurrent: { - type: Number, - default: 1 - }, - pageSize: { - type: Number, - default: 20 - }, - getcount: { - type: [Boolean, String], - default: false - }, - getone: { - type: [Boolean, String], - default: false - }, - gettree: { - type: [Boolean, String], - default: false - }, - manual: { - type: Boolean, - default: false - }, - value: { - type: [Array, String, Number], - default () { - return [] - } - }, - modelValue: { - type: [Array, String, Number], - default () { - return [] - } - }, - preload: { - type: Boolean, - default: false - }, - stepSearh: { - type: Boolean, - default: true - }, - selfField: { - type: String, - default: '' - }, - parentField: { - type: String, - default: '' - }, - multiple: { - type: Boolean, - default: false - }, - map: { - type: Object, - default() { - return { - text: "text", - value: "value" - } - } - } - }, - data() { - return { - loading: false, - errorMessage: '', - loadMore: { - contentdown: '', - contentrefresh: '', - contentnomore: '' - }, - dataList: [], - selected: [], - selectedIndex: 0, - page: { - current: this.pageCurrent, - size: this.pageSize, - count: 0 - } - } - }, - computed: { - isLocaldata() { - return !this.collection.length - }, - postField() { - let fields = [this.field]; - if (this.parentField) { - fields.push(`${this.parentField} as parent_value`); - } - return fields.join(','); - }, - dataValue() { - let isModelValue = Array.isArray(this.modelValue) ? (this.modelValue.length > 0) : (this.modelValue !== null || this.modelValue !== undefined) - return isModelValue ? this.modelValue : this.value - }, - hasValue() { - if (typeof this.dataValue === 'number') { - return true - } - return (this.dataValue != null) && (this.dataValue.length > 0) - } - }, - created() { - this.$watch(() => { - var al = []; - ['pageCurrent', - 'pageSize', - 'spaceInfo', - 'value', - 'modelValue', - 'localdata', - 'collection', - 'action', - 'field', - 'orderby', - 'where', - 'getont', - 'getcount', - 'gettree' - ].forEach(key => { - al.push(this[key]) - }); - return al - }, (newValue, oldValue) => { - let needReset = false - for (let i = 2; i < newValue.length; i++) { - if (newValue[i] != oldValue[i]) { - needReset = true - break - } - } - if (newValue[0] != oldValue[0]) { - this.page.current = this.pageCurrent - } - this.page.size = this.pageSize - - this.onPropsChange() - }) - this._treeData = [] - }, - methods: { - onPropsChange() { - this._treeData = [] - }, - getCommand(options = {}) { - /* eslint-disable no-undef */ - let db = uniCloud.database(this.spaceInfo) - - const action = options.action || this.action - if (action) { - db = db.action(action) - } - - const collection = options.collection || this.collection - db = db.collection(collection) - - const where = options.where || this.where - if (!(!where || !Object.keys(where).length)) { - db = db.where(where) - } - - const field = options.field || this.field - if (field) { - db = db.field(field) - } - - const orderby = options.orderby || this.orderby - if (orderby) { - db = db.orderBy(orderby) - } - - const current = options.pageCurrent !== undefined ? options.pageCurrent : this.page.current - const size = options.pageSize !== undefined ? options.pageSize : this.page.size - const getCount = options.getcount !== undefined ? options.getcount : this.getcount - const getTree = options.gettree !== undefined ? options.gettree : this.gettree - - const getOptions = { - getCount, - getTree - } - if (options.getTreePath) { - getOptions.getTreePath = options.getTreePath - } - - db = db.skip(size * (current - 1)).limit(size).get(getOptions) - - return db - }, - getNodeData(callback) { - if (this.loading) { - return - } - this.loading = true - this.getCommand({ - field: this.postField, - where: this._pathWhere() - }).then((res) => { - this.loading = false - this.selected = res.result.data - callback && callback() - }).catch((err) => { - this.loading = false - this.errorMessage = err - }) - }, - getTreePath(callback) { - if (this.loading) { - return - } - this.loading = true - - this.getCommand({ - field: this.postField, - getTreePath: { - startWith: `${this.selfField}=='${this.dataValue}'` - } - }).then((res) => { - this.loading = false - let treePath = [] - this._extractTreePath(res.result.data, treePath) - this.selected = treePath - callback && callback() - }).catch((err) => { - this.loading = false - this.errorMessage = err - }) - }, - loadData() { - if (this.isLocaldata) { - this._processLocalData() - return - } - - if (this.dataValue != null) { - this._loadNodeData((data) => { - this._treeData = data - this._updateBindData() - this._updateSelected() - }) - return - } - - if (this.stepSearh) { - this._loadNodeData((data) => { - this._treeData = data - this._updateBindData() - }) - } else { - this._loadAllData((data) => { - this._treeData = [] - this._extractTree(data, this._treeData, null) - this._updateBindData() - }) - } - }, - _loadAllData(callback) { - if (this.loading) { - return - } - this.loading = true - - this.getCommand({ - field: this.postField, - gettree: true, - startwith: `${this.selfField}=='${this.dataValue}'` - }).then((res) => { - this.loading = false - callback(res.result.data) - this.onDataChange() - }).catch((err) => { - this.loading = false - this.errorMessage = err - }) - }, - _loadNodeData(callback, pw) { - if (this.loading) { - return - } - this.loading = true - - this.getCommand({ - field: this.postField, - where: pw || this._postWhere(), - pageSize: 500 - }).then((res) => { - this.loading = false - callback(res.result.data) - this.onDataChange() - }).catch((err) => { - this.loading = false - this.errorMessage = err - }) - }, - _pathWhere() { - let result = [] - let where_field = this._getParentNameByField(); - if (where_field) { - result.push(`${where_field} == '${this.dataValue}'`) - } - - if (this.where) { - return `(${this.where}) && (${result.join(' || ')})` - } - - return result.join(' || ') - }, - _postWhere() { - let result = [] - let selected = this.selected - let parentField = this.parentField - if (parentField) { - result.push(`${parentField} == null || ${parentField} == ""`) - } - if (selected.length) { - for (var i = 0; i < selected.length - 1; i++) { - result.push(`${parentField} == '${selected[i].value}'`) - } - } - - let where = [] - if (this.where) { - where.push(`(${this.where})`) - } - if (result.length) { - where.push(`(${result.join(' || ')})`) - } - - return where.join(' && ') - }, - _nodeWhere() { - let result = [] - let selected = this.selected - if (selected.length) { - result.push(`${this.parentField} == '${selected[selected.length - 1].value}'`) - } - - if (this.where) { - return `(${this.where}) && (${result.join(' || ')})` - } - - return result.join(' || ') - }, - _getParentNameByField() { - const fields = this.field.split(','); - let where_field = null; - for (let i = 0; i < fields.length; i++) { - const items = fields[i].split('as'); - if (items.length < 2) { - continue; - } - if (items[1].trim() === 'value') { - where_field = items[0].trim(); - break; - } - } - return where_field - }, - _isTreeView() { - return (this.parentField && this.selfField) - }, - _updateSelected() { - var dl = this.dataList - var sl = this.selected - let textField = this.map.text - let valueField = this.map.value - for (var i = 0; i < sl.length; i++) { - var value = sl[i].value - var dl2 = dl[i] - for (var j = 0; j < dl2.length; j++) { - var item2 = dl2[j] - if (item2[valueField] === value) { - sl[i].text = item2[textField] - break - } - } - } - }, - _updateBindData(node) { - const { - dataList, - hasNodes - } = this._filterData(this._treeData, this.selected) - - let isleaf = this._stepSearh === false && !hasNodes - - if (node) { - node.isleaf = isleaf - } - - this.dataList = dataList - this.selectedIndex = dataList.length - 1 - - if (!isleaf && this.selected.length < dataList.length) { - this.selected.push({ - value: null, - text: "请选择" - }) - } - - return { - isleaf, - hasNodes - } - }, - _filterData(data, paths) { - let dataList = [] - let hasNodes = true - - dataList.push(data.filter((item) => { - return (item.parent_value === null || item.parent_value === undefined || item.parent_value === '') - })) - for (let i = 0; i < paths.length; i++) { - var value = paths[i].value - var nodes = data.filter((item) => { - return item.parent_value === value - }) - - if (nodes.length) { - dataList.push(nodes) - } else { - hasNodes = false - } - } - - return { - dataList, - hasNodes - } - }, - _extractTree(nodes, result, parent_value) { - let list = result || [] - let valueField = this.map.value - for (let i = 0; i < nodes.length; i++) { - let node = nodes[i] - - let child = {} - for (let key in node) { - if (key !== 'children') { - child[key] = node[key] - } - } - if (parent_value !== null && parent_value !== undefined && parent_value !== '') { - child.parent_value = parent_value - } - result.push(child) - - let children = node.children - if (children) { - this._extractTree(children, result, node[valueField]) - } - } - }, - _extractTreePath(nodes, result) { - let list = result || [] - for (let i = 0; i < nodes.length; i++) { - let node = nodes[i] - - let child = {} - for (let key in node) { - if (key !== 'children') { - child[key] = node[key] - } - } - result.push(child) - - let children = node.children - if (children) { - this._extractTreePath(children, result) - } - } - }, - _findNodePath(key, nodes, path = []) { - let textField = this.map.text - let valueField = this.map.value - for (let i = 0; i < nodes.length; i++) { - let node = nodes[i] - let children = node.children - let text = node[textField] - let value = node[valueField] - - path.push({ - value, - text - }) - - if (value === key) { - return path - } - - if (children) { - const p = this._findNodePath(key, children, path) - if (p.length) { - return p - } - } - - path.pop() - } - return [] - }, - _processLocalData() { - this._treeData = [] - this._extractTree(this.localdata, this._treeData) - - var inputValue = this.dataValue - if (inputValue === undefined) { - return - } - - if (Array.isArray(inputValue)) { - inputValue = inputValue[inputValue.length - 1] - if (typeof inputValue === 'object' && inputValue[this.map.value]) { - inputValue = inputValue[this.map.value] - } - } - - this.selected = this._findNodePath(inputValue, this.localdata) - } - } -} diff --git a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-pickerview.vue b/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-pickerview.vue deleted file mode 100644 index 065aac2b..00000000 --- a/blog-uniapp/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-pickerview.vue +++ /dev/null @@ -1,333 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-data-picker/package.json b/blog-uniapp/uni_modules/uni-data-picker/package.json deleted file mode 100644 index 99003802..00000000 --- a/blog-uniapp/uni_modules/uni-data-picker/package.json +++ /dev/null @@ -1,93 +0,0 @@ -{ - "id": "uni-data-picker", - "displayName": "uni-data-picker 数据驱动的picker选择器", - "version": "1.0.7", - "description": "单列、多列级联选择器,常用于省市区城市选择、公司部门选择、多级分类等场景", - "keywords": [ - "uni-ui", - "uniui", - "picker", - "级联", - "省市区", - "" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-load-more", - "uni-icons", - "uni-scss" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y", - "京东": "u" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-data-picker/readme.md b/blog-uniapp/uni_modules/uni-data-picker/readme.md deleted file mode 100644 index 6cda2240..00000000 --- a/blog-uniapp/uni_modules/uni-data-picker/readme.md +++ /dev/null @@ -1,22 +0,0 @@ -## DataPicker 级联选择 -> **组件名:uni-data-picker** -> 代码块: `uDataPicker` -> 关联组件:`uni-data-pickerview`、`uni-load-more`。 - - -`` 是一个选择类[datacom组件](https://uniapp.dcloud.net.cn/component/datacom)。 - -支持单列、和多列级联选择。列数没有限制,如果屏幕显示不全,顶部tab区域会左右滚动。 - -候选数据支持一次性加载完毕,也支持懒加载,比如示例图中,选择了“北京”后,动态加载北京的区县数据。 - -`` 组件尤其适用于地址选择、分类选择等选择类。 - -`` 支持本地数据、云端静态数据(json),uniCloud云数据库数据。 - -`` 可以通过JQL直连uniCloud云数据库,配套[DB Schema](https://uniapp.dcloud.net.cn/uniCloud/schema),可在schema2code中自动生成前端页面,还支持服务器端校验。 - -在uniCloud数据表中新建表“uni-id-address”和“opendb-city-china”,这2个表的schema自带foreignKey关联。在“uni-id-address”表的表结构页面使用schema2code生成前端页面,会自动生成地址管理的维护页面,自动从“opendb-city-china”表包含的中国所有省市区信息里选择地址。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-data-picker) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-data-select/changelog.md b/blog-uniapp/uni_modules/uni-data-select/changelog.md deleted file mode 100644 index d5beaa35..00000000 --- a/blog-uniapp/uni_modules/uni-data-select/changelog.md +++ /dev/null @@ -1,16 +0,0 @@ -## 0.1.6(2022-07-06) -- 修复 pc端宽度异常的bug -## 0.1.5 -- 修复 pc端宽度异常的bug -## 0.1.4(2022-07-05) -- 优化 显示样式 -## 0.1.3(2022-06-02) -- 修复 localdata 赋值不生效的 bug -- 新增 支持 uni.scss 修改颜色 -- 新增 支持选项禁用(数据选项设置 disabled: true 即禁用) -## 0.1.2(2022-05-08) -- 修复 当 value 为 0 时选择不生效的 bug -## 0.1.1(2022-05-07) -- 新增 记住上次的选项(仅 collection 存在时有效) -## 0.1.0(2022-04-22) -- 初始化 diff --git a/blog-uniapp/uni_modules/uni-data-select/components/uni-data-select/uni-data-select.vue b/blog-uniapp/uni_modules/uni-data-select/components/uni-data-select/uni-data-select.vue deleted file mode 100644 index 16995bd6..00000000 --- a/blog-uniapp/uni_modules/uni-data-select/components/uni-data-select/uni-data-select.vue +++ /dev/null @@ -1,426 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-data-select/package.json b/blog-uniapp/uni_modules/uni-data-select/package.json deleted file mode 100644 index 1ebd8dd4..00000000 --- a/blog-uniapp/uni_modules/uni-data-select/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-data-select", - "displayName": "uni-data-select 下拉框选择器", - "version": "0.1.6", - "description": "通过数据驱动的下拉框选择器", - "keywords": [ - "uni-ui", - "select", - "uni-data-select", - "下拉框", - "下拉选" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "^3.1.1" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-load-more"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "u", - "app-nvue": "n" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "u", - "百度": "u", - "字节跳动": "u", - "QQ": "u", - "京东": "u" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-data-select/readme.md b/blog-uniapp/uni_modules/uni-data-select/readme.md deleted file mode 100644 index eb58de30..00000000 --- a/blog-uniapp/uni_modules/uni-data-select/readme.md +++ /dev/null @@ -1,8 +0,0 @@ -## DataSelect 下拉框选择器 -> **组件名:uni-data-select** -> 代码块: `uDataSelect` - -当选项过多时,使用下拉菜单展示并选择内容 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-data-select) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 diff --git a/blog-uniapp/uni_modules/uni-dateformat/changelog.md b/blog-uniapp/uni_modules/uni-dateformat/changelog.md deleted file mode 100644 index d551d7b8..00000000 --- a/blog-uniapp/uni_modules/uni-dateformat/changelog.md +++ /dev/null @@ -1,10 +0,0 @@ -## 1.0.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-dateformat](https://uniapp.dcloud.io/component/uniui/uni-dateformat) -## 0.0.5(2021-07-08) -- 调整 默认时间不再是当前时间,而是显示'-'字符 -## 0.0.4(2021-05-12) -- 新增 组件示例地址 -## 0.0.3(2021-02-04) -- 调整为uni_modules目录规范 -- 修复 iOS 平台日期格式化出错的问题 diff --git a/blog-uniapp/uni_modules/uni-dateformat/components/uni-dateformat/date-format.js b/blog-uniapp/uni_modules/uni-dateformat/components/uni-dateformat/date-format.js deleted file mode 100644 index e00d5597..00000000 --- a/blog-uniapp/uni_modules/uni-dateformat/components/uni-dateformat/date-format.js +++ /dev/null @@ -1,200 +0,0 @@ -// yyyy-MM-dd hh:mm:ss.SSS 所有支持的类型 -function pad(str, length = 2) { - str += '' - while (str.length < length) { - str = '0' + str - } - return str.slice(-length) -} - -const parser = { - yyyy: (dateObj) => { - return pad(dateObj.year, 4) - }, - yy: (dateObj) => { - return pad(dateObj.year) - }, - MM: (dateObj) => { - return pad(dateObj.month) - }, - M: (dateObj) => { - return dateObj.month - }, - dd: (dateObj) => { - return pad(dateObj.day) - }, - d: (dateObj) => { - return dateObj.day - }, - hh: (dateObj) => { - return pad(dateObj.hour) - }, - h: (dateObj) => { - return dateObj.hour - }, - mm: (dateObj) => { - return pad(dateObj.minute) - }, - m: (dateObj) => { - return dateObj.minute - }, - ss: (dateObj) => { - return pad(dateObj.second) - }, - s: (dateObj) => { - return dateObj.second - }, - SSS: (dateObj) => { - return pad(dateObj.millisecond, 3) - }, - S: (dateObj) => { - return dateObj.millisecond - }, -} - -// 这都n年了iOS依然不认识2020-12-12,需要转换为2020/12/12 -function getDate(time) { - if (time instanceof Date) { - return time - } - switch (typeof time) { - case 'string': - { - // 2020-12-12T12:12:12.000Z、2020-12-12T12:12:12.000 - if (time.indexOf('T') > -1) { - return new Date(time) - } - return new Date(time.replace(/-/g, '/')) - } - default: - return new Date(time) - } -} - -export function formatDate(date, format = 'yyyy/MM/dd hh:mm:ss') { - if (!date && date !== 0) { - return '' - } - date = getDate(date) - const dateObj = { - year: date.getFullYear(), - month: date.getMonth() + 1, - day: date.getDate(), - hour: date.getHours(), - minute: date.getMinutes(), - second: date.getSeconds(), - millisecond: date.getMilliseconds() - } - const tokenRegExp = /yyyy|yy|MM|M|dd|d|hh|h|mm|m|ss|s|SSS|SS|S/ - let flag = true - let result = format - while (flag) { - flag = false - result = result.replace(tokenRegExp, function(matched) { - flag = true - return parser[matched](dateObj) - }) - } - return result -} - -export function friendlyDate(time, { - locale = 'zh', - threshold = [60000, 3600000], - format = 'yyyy/MM/dd hh:mm:ss' -}) { - if (time === '-') { - return time - } - if (!time && time !== 0) { - return '' - } - const localeText = { - zh: { - year: '年', - month: '月', - day: '天', - hour: '小时', - minute: '分钟', - second: '秒', - ago: '前', - later: '后', - justNow: '刚刚', - soon: '马上', - template: '{num}{unit}{suffix}' - }, - en: { - year: 'year', - month: 'month', - day: 'day', - hour: 'hour', - minute: 'minute', - second: 'second', - ago: 'ago', - later: 'later', - justNow: 'just now', - soon: 'soon', - template: '{num} {unit} {suffix}' - } - } - const text = localeText[locale] || localeText.zh - let date = getDate(time) - let ms = date.getTime() - Date.now() - let absMs = Math.abs(ms) - if (absMs < threshold[0]) { - return ms < 0 ? text.justNow : text.soon - } - if (absMs >= threshold[1]) { - return formatDate(date, format) - } - let num - let unit - let suffix = text.later - if (ms < 0) { - suffix = text.ago - ms = -ms - } - const seconds = Math.floor((ms) / 1000) - const minutes = Math.floor(seconds / 60) - const hours = Math.floor(minutes / 60) - const days = Math.floor(hours / 24) - const months = Math.floor(days / 30) - const years = Math.floor(months / 12) - switch (true) { - case years > 0: - num = years - unit = text.year - break - case months > 0: - num = months - unit = text.month - break - case days > 0: - num = days - unit = text.day - break - case hours > 0: - num = hours - unit = text.hour - break - case minutes > 0: - num = minutes - unit = text.minute - break - default: - num = seconds - unit = text.second - break - } - - if (locale === 'en') { - if (num === 1) { - num = 'a' - } else { - unit += 's' - } - } - - return text.template.replace(/{\s*num\s*}/g, num + '').replace(/{\s*unit\s*}/g, unit).replace(/{\s*suffix\s*}/g, - suffix) -} diff --git a/blog-uniapp/uni_modules/uni-dateformat/components/uni-dateformat/uni-dateformat.vue b/blog-uniapp/uni_modules/uni-dateformat/components/uni-dateformat/uni-dateformat.vue deleted file mode 100644 index c5ed0307..00000000 --- a/blog-uniapp/uni_modules/uni-dateformat/components/uni-dateformat/uni-dateformat.vue +++ /dev/null @@ -1,88 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-dateformat/package.json b/blog-uniapp/uni_modules/uni-dateformat/package.json deleted file mode 100644 index 786a670b..00000000 --- a/blog-uniapp/uni_modules/uni-dateformat/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-dateformat", - "displayName": "uni-dateformat 日期格式化", - "version": "1.0.0", - "description": "日期格式化组件,可以将日期格式化为1分钟前、刚刚等形式", - "keywords": [ - "uni-ui", - "uniui", - "日期格式化", - "时间格式化", - "格式化时间", - "" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "y", - "联盟": "y" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-dateformat/readme.md b/blog-uniapp/uni_modules/uni-dateformat/readme.md deleted file mode 100644 index 37ddb6ec..00000000 --- a/blog-uniapp/uni_modules/uni-dateformat/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -### DateFormat 日期格式化 -> **组件名:uni-dateformat** -> 代码块: `uDateformat` - - -日期格式化组件。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-dateformat) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/changelog.md b/blog-uniapp/uni_modules/uni-datetime-picker/changelog.md deleted file mode 100644 index 5c9735a1..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/changelog.md +++ /dev/null @@ -1,93 +0,0 @@ -## 2.2.6(2022-06-30) -- 优化 组件样式,调整了组件图标大小、高度、颜色等,与uni-ui风格保持一致 -## 2.2.5(2022-06-24) -- 修复 日历顶部年月及底部确认未国际化 bug -## 2.2.4(2022-03-31) -- 修复 Vue3 下动态赋值,单选类型未响应的 bug -## 2.2.3(2022-03-28) -- 修复 Vue3 下动态赋值未响应的 bug -## 2.2.2(2021-12-10) -- 修复 clear-icon 属性在小程序平台不生效的 bug -## 2.2.1(2021-12-10) -- 修复 日期范围选在小程序平台,必须多点击一次才能取消选中状态的 bug -## 2.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-datetime-picker](https://uniapp.dcloud.io/component/uniui/uni-datetime-picker) -## 2.1.5(2021-11-09) -- 新增 提供组件设计资源,组件样式调整 -## 2.1.4(2021-09-10) -- 修复 hide-second 在移动端的 bug -- 修复 单选赋默认值时,赋值日期未高亮的 bug -- 修复 赋默认值时,移动端未正确显示时间的 bug -## 2.1.3(2021-09-09) -- 新增 hide-second 属性,支持只使用时分,隐藏秒 -## 2.1.2(2021-09-03) -- 优化 取消选中时(范围选)直接开始下一次选择, 避免多点一次 -- 优化 移动端支持清除按钮,同时支持通过 ref 调用组件的 clear 方法 -- 优化 调整字号大小,美化日历界面 -- 修复 因国际化导致的 placeholder 失效的 bug -## 2.1.1(2021-08-24) -- 新增 支持国际化 -- 优化 范围选择器在 pc 端过宽的问题 -## 2.1.0(2021-08-09) -- 新增 适配 vue3 -## 2.0.19(2021-08-09) -- 新增 支持作为 uni-forms 子组件相关功能 -- 修复 在 uni-forms 中使用时,选择时间报 NAN 错误的 bug -## 2.0.18(2021-08-05) -- 修复 type 属性动态赋值无效的 bug -- 修复 ‘确认’按钮被 tabbar 遮盖 bug -- 修复 组件未赋值时范围选左、右日历相同的 bug -## 2.0.17(2021-08-04) -- 修复 范围选未正确显示当前值的 bug -- 修复 h5 平台(移动端)报错 'cale' of undefined 的 bug -## 2.0.16(2021-07-21) -- 新增 return-type 属性支持返回 date 日期对象 -## 2.0.15(2021-07-14) -- 修复 单选日期类型,初始赋值后不在当前日历的 bug -- 新增 clearIcon 属性,显示框的清空按钮可配置显示隐藏(仅 pc 有效) -- 优化 移动端移除显示框的清空按钮,无实际用途 -## 2.0.14(2021-07-14) -- 修复 组件赋值为空,界面未更新的 bug -- 修复 start 和 end 不能动态赋值的 bug -- 修复 范围选类型,用户选择后再次选择右侧日历(结束日期)显示不正确的 bug -## 2.0.13(2021-07-08) -- 修复 范围选择不能动态赋值的 bug -## 2.0.12(2021-07-08) -- 修复 范围选择的初始时间在一个月内时,造成无法选择的bug -## 2.0.11(2021-07-08) -- 优化 弹出层在超出视窗边缘定位不准确的问题 -## 2.0.10(2021-07-08) -- 修复 范围起始点样式的背景色与今日样式的字体前景色融合,导致日期字体看不清的 bug -- 优化 弹出层在超出视窗边缘被遮盖的问题 -## 2.0.9(2021-07-07) -- 新增 maskClick 事件 -- 修复 特殊情况日历 rpx 布局错误的 bug,rpx -> px -- 修复 范围选择时清空返回值不合理的bug,['', ''] -> [] -## 2.0.8(2021-07-07) -- 新增 日期时间显示框支持插槽 -## 2.0.7(2021-07-01) -- 优化 添加 uni-icons 依赖 -## 2.0.6(2021-05-22) -- 修复 图标在小程序上不显示的 bug -- 优化 重命名引用组件,避免潜在组件命名冲突 -## 2.0.5(2021-05-20) -- 优化 代码目录扁平化 -## 2.0.4(2021-05-12) -- 新增 组件示例地址 -## 2.0.3(2021-05-10) -- 修复 ios 下不识别 '-' 日期格式的 bug -- 优化 pc 下弹出层添加边框和阴影 -## 2.0.2(2021-05-08) -- 修复 在 admin 中获取弹出层定位错误的bug -## 2.0.1(2021-05-08) -- 修复 type 属性向下兼容,默认值从 date 变更为 datetime -## 2.0.0(2021-04-30) -- 支持日历形式的日期+时间的范围选择 - > 注意:此版本不向后兼容,不再支持单独时间选择(type=time)及相关的 hide-second 属性(时间选可使用内置组件 picker) -## 1.0.6(2021-03-18) -- 新增 hide-second 属性,时间支持仅选择时、分 -- 修复 选择跟显示的日期不一样的 bug -- 修复 chang事件触发2次的 bug -- 修复 分、秒 end 范围错误的 bug -- 优化 更好的 nvue 适配 diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue deleted file mode 100644 index 3d2dbeac..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar-item.vue +++ /dev/null @@ -1,185 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue deleted file mode 100644 index 8f7f1815..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/calendar.vue +++ /dev/null @@ -1,907 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/en.json b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/en.json deleted file mode 100644 index 9acf1ab0..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/en.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "uni-datetime-picker.selectDate": "select date", - "uni-datetime-picker.selectTime": "select time", - "uni-datetime-picker.selectDateTime": "select datetime", - "uni-datetime-picker.startDate": "start date", - "uni-datetime-picker.endDate": "end date", - "uni-datetime-picker.startTime": "start time", - "uni-datetime-picker.endTime": "end time", - "uni-datetime-picker.ok": "ok", - "uni-datetime-picker.clear": "clear", - "uni-datetime-picker.cancel": "cancel", - "uni-datetime-picker.year": "-", - "uni-datetime-picker.month": "", - "uni-calender.MON": "MON", - "uni-calender.TUE": "TUE", - "uni-calender.WED": "WED", - "uni-calender.THU": "THU", - "uni-calender.FRI": "FRI", - "uni-calender.SAT": "SAT", - "uni-calender.SUN": "SUN", - "uni-calender.confirm": "confirm" -} diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/index.js b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hans.json deleted file mode 100644 index d2df5e72..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hans.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "uni-datetime-picker.selectDate": "选择日期", - "uni-datetime-picker.selectTime": "选择时间", - "uni-datetime-picker.selectDateTime": "选择日期时间", - "uni-datetime-picker.startDate": "开始日期", - "uni-datetime-picker.endDate": "结束日期", - "uni-datetime-picker.startTime": "开始时间", - "uni-datetime-picker.endTime": "结束时间", - "uni-datetime-picker.ok": "确定", - "uni-datetime-picker.clear": "清除", - "uni-datetime-picker.cancel": "取消", - "uni-datetime-picker.year": "年", - "uni-datetime-picker.month": "月", - "uni-calender.SUN": "日", - "uni-calender.MON": "一", - "uni-calender.TUE": "二", - "uni-calender.WED": "三", - "uni-calender.THU": "四", - "uni-calender.FRI": "五", - "uni-calender.SAT": "六", - "uni-calender.confirm": "确认" -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hant.json deleted file mode 100644 index d23fa3c3..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/i18n/zh-Hant.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "uni-datetime-picker.selectDate": "選擇日期", - "uni-datetime-picker.selectTime": "選擇時間", - "uni-datetime-picker.selectDateTime": "選擇日期時間", - "uni-datetime-picker.startDate": "開始日期", - "uni-datetime-picker.endDate": "結束日期", - "uni-datetime-picker.startTime": "開始时间", - "uni-datetime-picker.endTime": "結束时间", - "uni-datetime-picker.ok": "確定", - "uni-datetime-picker.clear": "清除", - "uni-datetime-picker.cancel": "取消", - "uni-datetime-picker.year": "年", - "uni-datetime-picker.month": "月", - "uni-calender.SUN": "日", - "uni-calender.MON": "一", - "uni-calender.TUE": "二", - "uni-calender.WED": "三", - "uni-calender.THU": "四", - "uni-calender.FRI": "五", - "uni-calender.SAT": "六", - "uni-calender.confirm": "確認" -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/keypress.js b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/keypress.js deleted file mode 100644 index 9601abae..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/keypress.js +++ /dev/null @@ -1,45 +0,0 @@ -// #ifdef H5 -export default { - name: 'Keypress', - props: { - disable: { - type: Boolean, - default: false - } - }, - mounted () { - const keyNames = { - esc: ['Esc', 'Escape'], - tab: 'Tab', - enter: 'Enter', - space: [' ', 'Spacebar'], - up: ['Up', 'ArrowUp'], - left: ['Left', 'ArrowLeft'], - right: ['Right', 'ArrowRight'], - down: ['Down', 'ArrowDown'], - delete: ['Backspace', 'Delete', 'Del'] - } - const listener = ($event) => { - if (this.disable) { - return - } - const keyName = Object.keys(keyNames).find(key => { - const keyName = $event.key - const value = keyNames[key] - return value === keyName || (Array.isArray(value) && value.includes(keyName)) - }) - if (keyName) { - // 避免和其他按键事件冲突 - setTimeout(() => { - this.$emit(keyName, {}) - }, 0) - } - } - document.addEventListener('keyup', listener) - this.$once('hook:beforeDestroy', () => { - document.removeEventListener('keyup', listener) - }) - }, - render: () => {} -} -// #endif \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/time-picker.vue b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/time-picker.vue deleted file mode 100644 index 699aa639..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/time-picker.vue +++ /dev/null @@ -1,927 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue deleted file mode 100644 index 9bdf8bca..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/uni-datetime-picker.vue +++ /dev/null @@ -1,1012 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js b/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js deleted file mode 100644 index efa5773a..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/components/uni-datetime-picker/util.js +++ /dev/null @@ -1,410 +0,0 @@ -class Calendar { - constructor({ - date, - selected, - startDate, - endDate, - range, - // multipleStatus - } = {}) { - // 当前日期 - this.date = this.getDate(new Date()) // 当前初入日期 - // 打点信息 - this.selected = selected || []; - // 范围开始 - this.startDate = startDate - // 范围结束 - this.endDate = endDate - this.range = range - // 多选状态 - this.cleanMultipleStatus() - // 每周日期 - this.weeks = {} - // this._getWeek(this.date.fullDate) - // this.multipleStatus = multipleStatus - this.lastHover = false - } - /** - * 设置日期 - * @param {Object} date - */ - setDate(date) { - this.selectDate = this.getDate(date) - this._getWeek(this.selectDate.fullDate) - } - - /** - * 清理多选状态 - */ - cleanMultipleStatus() { - this.multipleStatus = { - before: '', - after: '', - data: [] - } - } - - /** - * 重置开始日期 - */ - resetSatrtDate(startDate) { - // 范围开始 - this.startDate = startDate - - } - - /** - * 重置结束日期 - */ - resetEndDate(endDate) { - // 范围结束 - this.endDate = endDate - } - - /** - * 获取任意时间 - */ - getDate(date, AddDayCount = 0, str = 'day') { - if (!date) { - date = new Date() - } - if (typeof date !== 'object') { - date = date.replace(/-/g, '/') - } - const dd = new Date(date) - switch (str) { - case 'day': - dd.setDate(dd.getDate() + AddDayCount) // 获取AddDayCount天后的日期 - break - case 'month': - if (dd.getDate() === 31) { - dd.setDate(dd.getDate() + AddDayCount) - } else { - dd.setMonth(dd.getMonth() + AddDayCount) // 获取AddDayCount天后的日期 - } - break - case 'year': - dd.setFullYear(dd.getFullYear() + AddDayCount) // 获取AddDayCount天后的日期 - break - } - const y = dd.getFullYear() - const m = dd.getMonth() + 1 < 10 ? '0' + (dd.getMonth() + 1) : dd.getMonth() + 1 // 获取当前月份的日期,不足10补0 - const d = dd.getDate() < 10 ? '0' + dd.getDate() : dd.getDate() // 获取当前几号,不足10补0 - return { - fullDate: y + '-' + m + '-' + d, - year: y, - month: m, - date: d, - day: dd.getDay() - } - } - - - /** - * 获取上月剩余天数 - */ - _getLastMonthDays(firstDay, full) { - let dateArr = [] - for (let i = firstDay; i > 0; i--) { - const beforeDate = new Date(full.year, full.month - 1, -i + 1).getDate() - dateArr.push({ - date: beforeDate, - month: full.month - 1, - disable: true - }) - } - return dateArr - } - /** - * 获取本月天数 - */ - _currentMonthDys(dateData, full) { - let dateArr = [] - let fullDate = this.date.fullDate - for (let i = 1; i <= dateData; i++) { - let isinfo = false - let nowDate = full.year + '-' + (full.month < 10 ? - full.month : full.month) + '-' + (i < 10 ? - '0' + i : i) - // 是否今天 - let isDay = fullDate === nowDate - // 获取打点信息 - let info = this.selected && this.selected.find((item) => { - if (this.dateEqual(nowDate, item.date)) { - return item - } - }) - - // 日期禁用 - let disableBefore = true - let disableAfter = true - if (this.startDate) { - // let dateCompBefore = this.dateCompare(this.startDate, fullDate) - // disableBefore = this.dateCompare(dateCompBefore ? this.startDate : fullDate, nowDate) - disableBefore = this.dateCompare(this.startDate, nowDate) - } - - if (this.endDate) { - // let dateCompAfter = this.dateCompare(fullDate, this.endDate) - // disableAfter = this.dateCompare(nowDate, dateCompAfter ? this.endDate : fullDate) - disableAfter = this.dateCompare(nowDate, this.endDate) - } - let multiples = this.multipleStatus.data - let checked = false - let multiplesStatus = -1 - if (this.range) { - if (multiples) { - multiplesStatus = multiples.findIndex((item) => { - return this.dateEqual(item, nowDate) - }) - } - if (multiplesStatus !== -1) { - checked = true - } - } - let data = { - fullDate: nowDate, - year: full.year, - date: i, - multiple: this.range ? checked : false, - beforeMultiple: this.isLogicBefore(nowDate, this.multipleStatus.before, this.multipleStatus.after), - afterMultiple: this.isLogicAfter(nowDate, this.multipleStatus.before, this.multipleStatus.after), - month: full.month, - disable: !(disableBefore && disableAfter), - isDay, - userChecked: false - } - if (info) { - data.extraInfo = info - } - - dateArr.push(data) - } - return dateArr - } - /** - * 获取下月天数 - */ - _getNextMonthDays(surplus, full) { - let dateArr = [] - for (let i = 1; i < surplus + 1; i++) { - dateArr.push({ - date: i, - month: Number(full.month) + 1, - disable: true - }) - } - return dateArr - } - - /** - * 获取当前日期详情 - * @param {Object} date - */ - getInfo(date) { - if (!date) { - date = new Date() - } - const dateInfo = this.canlender.find(item => item.fullDate === this.getDate(date).fullDate) - return dateInfo - } - - /** - * 比较时间大小 - */ - dateCompare(startDate, endDate) { - // 计算截止时间 - startDate = new Date(startDate.replace('-', '/').replace('-', '/')) - // 计算详细项的截止时间 - endDate = new Date(endDate.replace('-', '/').replace('-', '/')) - if (startDate <= endDate) { - return true - } else { - return false - } - } - - /** - * 比较时间是否相等 - */ - dateEqual(before, after) { - // 计算截止时间 - before = new Date(before.replace('-', '/').replace('-', '/')) - // 计算详细项的截止时间 - after = new Date(after.replace('-', '/').replace('-', '/')) - if (before.getTime() - after.getTime() === 0) { - return true - } else { - return false - } - } - - /** - * 比较真实起始日期 - */ - - isLogicBefore(currentDay, before, after) { - let logicBefore = before - if (before && after) { - logicBefore = this.dateCompare(before, after) ? before : after - } - return this.dateEqual(logicBefore, currentDay) - } - - isLogicAfter(currentDay, before, after) { - let logicAfter = after - if (before && after) { - logicAfter = this.dateCompare(before, after) ? after : before - } - return this.dateEqual(logicAfter, currentDay) - } - - /** - * 获取日期范围内所有日期 - * @param {Object} begin - * @param {Object} end - */ - geDateAll(begin, end) { - var arr = [] - var ab = begin.split('-') - var ae = end.split('-') - var db = new Date() - db.setFullYear(ab[0], ab[1] - 1, ab[2]) - var de = new Date() - de.setFullYear(ae[0], ae[1] - 1, ae[2]) - var unixDb = db.getTime() - 24 * 60 * 60 * 1000 - var unixDe = de.getTime() - 24 * 60 * 60 * 1000 - for (var k = unixDb; k <= unixDe;) { - k = k + 24 * 60 * 60 * 1000 - arr.push(this.getDate(new Date(parseInt(k))).fullDate) - } - return arr - } - - /** - * 获取多选状态 - */ - setMultiple(fullDate) { - let { - before, - after - } = this.multipleStatus - if (!this.range) return - if (before && after) { - if (!this.lastHover) { - this.lastHover = true - return - } - this.multipleStatus.before = fullDate - this.multipleStatus.after = '' - this.multipleStatus.data = [] - this.multipleStatus.fulldate = '' - this.lastHover = false - } else { - if (!before) { - this.multipleStatus.before = fullDate - this.lastHover = false - } else { - this.multipleStatus.after = fullDate - if (this.dateCompare(this.multipleStatus.before, this.multipleStatus.after)) { - this.multipleStatus.data = this.geDateAll(this.multipleStatus.before, this.multipleStatus - .after); - } else { - this.multipleStatus.data = this.geDateAll(this.multipleStatus.after, this.multipleStatus - .before); - } - this.lastHover = true - } - } - this._getWeek(fullDate) - } - - /** - * 鼠标 hover 更新多选状态 - */ - setHoverMultiple(fullDate) { - let { - before, - after - } = this.multipleStatus - - if (!this.range) return - if (this.lastHover) return - - if (!before) { - this.multipleStatus.before = fullDate - } else { - this.multipleStatus.after = fullDate - if (this.dateCompare(this.multipleStatus.before, this.multipleStatus.after)) { - this.multipleStatus.data = this.geDateAll(this.multipleStatus.before, this.multipleStatus.after); - } else { - this.multipleStatus.data = this.geDateAll(this.multipleStatus.after, this.multipleStatus.before); - } - } - this._getWeek(fullDate) - } - - /** - * 更新默认值多选状态 - */ - setDefaultMultiple(before, after) { - this.multipleStatus.before = before - this.multipleStatus.after = after - if (before && after) { - if (this.dateCompare(before, after)) { - this.multipleStatus.data = this.geDateAll(before, after); - this._getWeek(after) - } else { - this.multipleStatus.data = this.geDateAll(after, before); - this._getWeek(before) - } - } - } - - /** - * 获取每周数据 - * @param {Object} dateData - */ - _getWeek(dateData) { - const { - fullDate, - year, - month, - date, - day - } = this.getDate(dateData) - let firstDay = new Date(year, month - 1, 1).getDay() - let currentDay = new Date(year, month, 0).getDate() - let dates = { - lastMonthDays: this._getLastMonthDays(firstDay, this.getDate(dateData)), // 上个月末尾几天 - currentMonthDys: this._currentMonthDys(currentDay, this.getDate(dateData)), // 本月天数 - nextMonthDays: [], // 下个月开始几天 - weeks: [] - } - let canlender = [] - const surplus = 42 - (dates.lastMonthDays.length + dates.currentMonthDys.length) - dates.nextMonthDays = this._getNextMonthDays(surplus, this.getDate(dateData)) - canlender = canlender.concat(dates.lastMonthDays, dates.currentMonthDys, dates.nextMonthDays) - let weeks = {} - // 拼接数组 上个月开始几天 + 本月天数+ 下个月开始几天 - for (let i = 0; i < canlender.length; i++) { - if (i % 7 === 0) { - weeks[parseInt(i / 7)] = new Array(7) - } - weeks[parseInt(i / 7)][i % 7] = canlender[i] - } - this.canlender = canlender - this.weeks = weeks - } - - //静态方法 - // static init(date) { - // if (!this.instance) { - // this.instance = new Calendar(date); - // } - // return this.instance; - // } -} - - -export default Calendar diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/package.json b/blog-uniapp/uni_modules/uni-datetime-picker/package.json deleted file mode 100644 index 60fa1d02..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/package.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "uni-datetime-picker", - "displayName": "uni-datetime-picker 日期选择器", - "version": "2.2.6", - "description": "uni-datetime-picker 日期时间选择器,支持日历,支持范围选择", - "keywords": [ - "uni-datetime-picker", - "uni-ui", - "uniui", - "日期时间选择器", - "日期时间" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "n" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-datetime-picker/readme.md b/blog-uniapp/uni_modules/uni-datetime-picker/readme.md deleted file mode 100644 index 162fbefa..00000000 --- a/blog-uniapp/uni_modules/uni-datetime-picker/readme.md +++ /dev/null @@ -1,21 +0,0 @@ - - -> `重要通知:组件升级更新 2.0.0 后,支持日期+时间范围选择,组件 ui 将使用日历选择日期,ui 变化较大,同时支持 PC 和 移动端。此版本不向后兼容,不再支持单独的时间选择(type=time)及相关的 hide-second 属性(时间选可使用内置组件 picker)。若仍需使用旧版本,可在插件市场下载*非uni_modules版本*,旧版本将不再维护` - -## DatetimePicker 时间选择器 - -> **组件名:uni-datetime-picker** -> 代码块: `uDatetimePicker` - - -该组件的优势是,支持**时间戳**输入和输出(起始时间、终止时间也支持时间戳),可**同时选择**日期和时间。 - -若只是需要单独选择日期和时间,不需要时间戳输入和输出,可使用原生的 picker 组件。 - -**_点击 picker 默认值规则:_** - -- 若设置初始值 value, 会显示在 picker 显示框中 -- 若无初始值 value,则初始值 value 为当前本地时间 Date.now(), 但不会显示在 picker 显示框中 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-datetime-picker) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-drawer/changelog.md b/blog-uniapp/uni_modules/uni-drawer/changelog.md deleted file mode 100644 index 6d2488c3..00000000 --- a/blog-uniapp/uni_modules/uni-drawer/changelog.md +++ /dev/null @@ -1,13 +0,0 @@ -## 1.2.1(2021-11-22) -- 修复 vue3中个别scss变量无法找到的问题 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-drawer](https://uniapp.dcloud.io/component/uniui/uni-drawer) -## 1.1.1(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.1.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.7(2021-05-12) -- 新增 组件示例地址 -## 1.0.6(2021-02-04) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-drawer/components/uni-drawer/keypress.js b/blog-uniapp/uni_modules/uni-drawer/components/uni-drawer/keypress.js deleted file mode 100644 index 62dda461..00000000 --- a/blog-uniapp/uni_modules/uni-drawer/components/uni-drawer/keypress.js +++ /dev/null @@ -1,45 +0,0 @@ -// #ifdef H5 -export default { - name: 'Keypress', - props: { - disable: { - type: Boolean, - default: false - } - }, - mounted () { - const keyNames = { - esc: ['Esc', 'Escape'], - tab: 'Tab', - enter: 'Enter', - space: [' ', 'Spacebar'], - up: ['Up', 'ArrowUp'], - left: ['Left', 'ArrowLeft'], - right: ['Right', 'ArrowRight'], - down: ['Down', 'ArrowDown'], - delete: ['Backspace', 'Delete', 'Del'] - } - const listener = ($event) => { - if (this.disable) { - return - } - const keyName = Object.keys(keyNames).find(key => { - const keyName = $event.key - const value = keyNames[key] - return value === keyName || (Array.isArray(value) && value.includes(keyName)) - }) - if (keyName) { - // 避免和其他按键事件冲突 - setTimeout(() => { - this.$emit(keyName, {}) - }, 0) - } - } - document.addEventListener('keyup', listener) - // this.$once('hook:beforeDestroy', () => { - // document.removeEventListener('keyup', listener) - // }) - }, - render: () => {} -} -// #endif diff --git a/blog-uniapp/uni_modules/uni-drawer/components/uni-drawer/uni-drawer.vue b/blog-uniapp/uni_modules/uni-drawer/components/uni-drawer/uni-drawer.vue deleted file mode 100644 index 82331a81..00000000 --- a/blog-uniapp/uni_modules/uni-drawer/components/uni-drawer/uni-drawer.vue +++ /dev/null @@ -1,183 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-drawer/package.json b/blog-uniapp/uni_modules/uni-drawer/package.json deleted file mode 100644 index dd056e4c..00000000 --- a/blog-uniapp/uni_modules/uni-drawer/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-drawer", - "displayName": "uni-drawer 抽屉", - "version": "1.2.1", - "description": "抽屉式导航,用于展示侧滑菜单,侧滑导航。", - "keywords": [ - "uni-ui", - "uniui", - "drawer", - "抽屉", - "侧滑导航" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-drawer/readme.md b/blog-uniapp/uni_modules/uni-drawer/readme.md deleted file mode 100644 index dcf6e6b2..00000000 --- a/blog-uniapp/uni_modules/uni-drawer/readme.md +++ /dev/null @@ -1,10 +0,0 @@ - - -## Drawer 抽屉 -> **组件名:uni-drawer** -> 代码块: `uDrawer` - -抽屉侧滑菜单。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-drawer) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-easyinput/changelog.md b/blog-uniapp/uni_modules/uni-easyinput/changelog.md deleted file mode 100644 index 1e8c6f91..00000000 --- a/blog-uniapp/uni_modules/uni-easyinput/changelog.md +++ /dev/null @@ -1,47 +0,0 @@ -## 1.1.0(2022-06-30) -- 新增 在 uni-forms 1.4.0 中使用可以在 blur 时校验内容 -- 新增 clear 事件,点击右侧叉号图标触发 -- 新增 change 事件 ,仅在输入框失去焦点或用户按下回车时触发 -- 优化 组件样式,组件获取焦点时高亮显示,图标颜色调整等 -- -## 1.0.5(2022-06-07) -- 优化 clearable 显示策略 -## 1.0.4(2022-06-07) -- 优化 clearable 显示策略 -## 1.0.3(2022-05-20) -- 修复 关闭图标某些情况下无法取消的bug -## 1.0.2(2022-04-12) -- 修复 默认值不生效的bug -## 1.0.1(2022-04-02) -- 修复 value不能为0的bug -## 1.0.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-easyinput](https://uniapp.dcloud.io/component/uniui/uni-easyinput) -## 0.1.4(2021-08-20) -- 修复 在 uni-forms 的动态表单中默认值校验不通过的 bug -## 0.1.3(2021-08-11) -- 修复 在 uni-forms 中重置表单,错误信息无法清除的问题 -## 0.1.2(2021-07-30) -- 优化 vue3下事件警告的问题 -## 0.1.1 -- 优化 errorMessage 属性支持 Boolean 类型 -## 0.1.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 0.0.16(2021-06-29) -- 修复 confirmType 属性(仅 type="text" 生效)导致多行文本框无法换行的 bug -## 0.0.15(2021-06-21) -- 修复 passwordIcon 属性拼写错误的 bug -## 0.0.14(2021-06-18) -- 新增 passwordIcon 属性,当type=password时是否显示小眼睛图标 -- 修复 confirmType 属性不生效的问题 -## 0.0.13(2021-06-04) -- 修复 disabled 状态可清出内容的 bug -## 0.0.12(2021-05-12) -- 新增 组件示例地址 -## 0.0.11(2021-05-07) -- 修复 input-border 属性不生效的问题 -## 0.0.10(2021-04-30) -- 修复 ios 遮挡文字、显示一半的问题 -## 0.0.9(2021-02-05) -- 调整为uni_modules目录规范 -- 优化 兼容 nvue 页面 diff --git a/blog-uniapp/uni_modules/uni-easyinput/components/uni-easyinput/common.js b/blog-uniapp/uni_modules/uni-easyinput/components/uni-easyinput/common.js deleted file mode 100644 index df9abe1d..00000000 --- a/blog-uniapp/uni_modules/uni-easyinput/components/uni-easyinput/common.js +++ /dev/null @@ -1,56 +0,0 @@ -/** - * @desc 函数防抖 - * @param func 目标函数 - * @param wait 延迟执行毫秒数 - * @param immediate true - 立即执行, false - 延迟执行 - */ -export const debounce = function(func, wait = 1000, immediate = true) { - let timer; - console.log(1); - return function() { - console.log(123); - let context = this, - args = arguments; - if (timer) clearTimeout(timer); - if (immediate) { - let callNow = !timer; - timer = setTimeout(() => { - timer = null; - }, wait); - if (callNow) func.apply(context, args); - } else { - timer = setTimeout(() => { - func.apply(context, args); - }, wait) - } - } -} -/** - * @desc 函数节流 - * @param func 函数 - * @param wait 延迟执行毫秒数 - * @param type 1 使用表时间戳,在时间段开始的时候触发 2 使用表定时器,在时间段结束的时候触发 - */ -export const throttle = (func, wait = 1000, type = 1) => { - let previous = 0; - let timeout; - return function() { - let context = this; - let args = arguments; - if (type === 1) { - let now = Date.now(); - - if (now - previous > wait) { - func.apply(context, args); - previous = now; - } - } else if (type === 2) { - if (!timeout) { - timeout = setTimeout(() => { - timeout = null; - func.apply(context, args) - }, wait) - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.vue b/blog-uniapp/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.vue deleted file mode 100644 index 5818d7fa..00000000 --- a/blog-uniapp/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.vue +++ /dev/null @@ -1,593 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-easyinput/package.json b/blog-uniapp/uni_modules/uni-easyinput/package.json deleted file mode 100644 index 3cc793e6..00000000 --- a/blog-uniapp/uni_modules/uni-easyinput/package.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "uni-easyinput", - "displayName": "uni-easyinput 增强输入框", - "version": "1.1.0", - "description": "Easyinput 组件是对原生input组件的增强", - "keywords": [ - "uni-ui", - "uniui", - "input", - "uni-easyinput", - "输入框" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-easyinput/readme.md b/blog-uniapp/uni_modules/uni-easyinput/readme.md deleted file mode 100644 index f1faf8fb..00000000 --- a/blog-uniapp/uni_modules/uni-easyinput/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -### Easyinput 增强输入框 -> **组件名:uni-easyinput** -> 代码块: `uEasyinput` - - -easyinput 组件是对原生input组件的增强 ,是专门为配合表单组件[uni-forms](https://ext.dcloud.net.cn/plugin?id=2773)而设计的,easyinput 内置了边框,图标等,同时包含 input 所有功能 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-easyinput) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-fab/changelog.md b/blog-uniapp/uni_modules/uni-fab/changelog.md deleted file mode 100644 index 24e26b16..00000000 --- a/blog-uniapp/uni_modules/uni-fab/changelog.md +++ /dev/null @@ -1,17 +0,0 @@ -## 1.2.2(2021-12-29) -- 更新 组件依赖 -## 1.2.1(2021-11-19) -- 修复 阴影颜色不正确的bug -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-fab](https://uniapp.dcloud.io/component/uniui/uni-fab) -## 1.1.1(2021-11-09) -- 新增 提供组件设计资源,组件样式调整 -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.7(2021-05-12) -- 新增 组件示例地址 -## 1.0.6(2021-02-05) -- 调整为uni_modules目录规范 -- 优化 按钮背景色调整 -- 优化 兼容pc端 diff --git a/blog-uniapp/uni_modules/uni-fab/components/uni-fab/uni-fab.vue b/blog-uniapp/uni_modules/uni-fab/components/uni-fab/uni-fab.vue deleted file mode 100644 index bef97f11..00000000 --- a/blog-uniapp/uni_modules/uni-fab/components/uni-fab/uni-fab.vue +++ /dev/null @@ -1,475 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-fab/package.json b/blog-uniapp/uni_modules/uni-fab/package.json deleted file mode 100644 index 0f27daa5..00000000 --- a/blog-uniapp/uni_modules/uni-fab/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-fab", - "displayName": "uni-fab 悬浮按钮", - "version": "1.2.2", - "description": "悬浮按钮 fab button ,点击可展开一个图标按钮菜单。", - "keywords": [ - "uni-ui", - "uniui", - "按钮", - "悬浮按钮", - "fab" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss","uni-icons"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-fab/readme.md b/blog-uniapp/uni_modules/uni-fab/readme.md deleted file mode 100644 index 9a444e88..00000000 --- a/blog-uniapp/uni_modules/uni-fab/readme.md +++ /dev/null @@ -1,9 +0,0 @@ -## Fab 悬浮按钮 -> **组件名:uni-fab** -> 代码块: `uFab` - - -点击可展开一个图形按钮菜单 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-fab) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-fav/changelog.md b/blog-uniapp/uni_modules/uni-fav/changelog.md deleted file mode 100644 index d8a08d43..00000000 --- a/blog-uniapp/uni_modules/uni-fav/changelog.md +++ /dev/null @@ -1,19 +0,0 @@ -## 1.2.1(2022-05-30) -- 新增 stat 属性 ,是否开启uni统计功能 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-fav](https://uniapp.dcloud.io/component/uniui/uni-fav) -## 1.1.1(2021-08-24) -- 新增 支持国际化 -## 1.1.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.6(2021-05-12) -- 新增 组件示例地址 -## 1.0.5(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 1.0.4(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 -## 1.0.3(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 -## 1.0.2(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/en.json b/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/en.json deleted file mode 100644 index 9a0759e0..00000000 --- a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/en.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-fav.collect": "collect", - "uni-fav.collected": "collected" -} diff --git a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/index.js b/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hans.json deleted file mode 100644 index 67c89bfc..00000000 --- a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hans.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-fav.collect": "收藏", - "uni-fav.collected": "已收藏" -} diff --git a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hant.json deleted file mode 100644 index 67c89bfc..00000000 --- a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/i18n/zh-Hant.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-fav.collect": "收藏", - "uni-fav.collected": "已收藏" -} diff --git a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/uni-fav.vue b/blog-uniapp/uni_modules/uni-fav/components/uni-fav/uni-fav.vue deleted file mode 100644 index d2c58df9..00000000 --- a/blog-uniapp/uni_modules/uni-fav/components/uni-fav/uni-fav.vue +++ /dev/null @@ -1,161 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-fav/package.json b/blog-uniapp/uni_modules/uni-fav/package.json deleted file mode 100644 index cc146971..00000000 --- a/blog-uniapp/uni_modules/uni-fav/package.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "id": "uni-fav", - "displayName": "uni-fav 收藏按钮", - "version": "1.2.1", - "description": " Fav 收藏组件,可自定义颜色、大小。", - "keywords": [ - "fav", - "uni-ui", - "uniui", - "收藏" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-fav/readme.md b/blog-uniapp/uni_modules/uni-fav/readme.md deleted file mode 100644 index 4de125d2..00000000 --- a/blog-uniapp/uni_modules/uni-fav/readme.md +++ /dev/null @@ -1,10 +0,0 @@ - - -## Fav 收藏按钮 -> **组件名:uni-fav** -> 代码块: `uFav` - -用于收藏功能,可点击切换选中、不选中的状态。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-fav) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-file-picker/changelog.md b/blog-uniapp/uni_modules/uni-file-picker/changelog.md deleted file mode 100644 index 5c810268..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/changelog.md +++ /dev/null @@ -1,63 +0,0 @@ -## 1.0.2(2022-07-04) -- 修复 在uni-forms下样式不生效的bug -## 1.0.1(2021-11-23) -- 修复 参数为对象的情况下,url在某些情况显示错误的bug -## 1.0.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-file-picker](https://uniapp.dcloud.io/component/uniui/uni-file-picker) -## 0.2.16(2021-11-08) -- 修复 传入空对象 ,显示错误的Bug -## 0.2.15(2021-08-30) -- 修复 return-type="object" 时且存在v-model时,无法删除文件的Bug -## 0.2.14(2021-08-23) -- 新增 参数中返回 fileID 字段 -## 0.2.13(2021-08-23) -- 修复 腾讯云传入fileID 不能回显的bug -- 修复 选择图片后,不能放大的问题 -## 0.2.12(2021-08-17) -- 修复 由于 0.2.11 版本引起的不能回显图片的Bug -## 0.2.11(2021-08-16) -- 新增 clearFiles(index) 方法,可以手动删除指定文件 -- 修复 v-model 值设为 null 报错的Bug -## 0.2.10(2021-08-13) -- 修复 return-type="object" 时,无法删除文件的Bug -## 0.2.9(2021-08-03) -- 修复 auto-upload 属性失效的Bug -## 0.2.8(2021-07-31) -- 修复 fileExtname属性不指定值报错的Bug -## 0.2.7(2021-07-31) -- 修复 在某种场景下图片不回显的Bug -## 0.2.6(2021-07-30) -- 修复 return-type为object下,返回值不正确的Bug -## 0.2.5(2021-07-30) -- 修复(重要) H5 平台下如果和uni-forms组件一同使用导致页面卡死的问题 -## 0.2.3(2021-07-28) -- 优化 调整示例代码 -## 0.2.2(2021-07-27) -- 修复 vue3 下赋值错误的Bug -- 优化 h5平台下上传文件导致页面卡死的问题 -## 0.2.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 0.1.1(2021-07-02) -- 修复 sourceType 缺少默认值导致 ios 无法选择文件 -## 0.1.0(2021-06-30) -- 优化 解耦与uniCloud的强绑定关系 ,如不绑定服务空间,默认autoUpload为false且不可更改 -## 0.0.11(2021-06-30) -- 修复 由 0.0.10 版本引发的 returnType 属性失效的问题 -## 0.0.10(2021-06-29) -- 优化 文件上传后进度条消失时机 -## 0.0.9(2021-06-29) -- 修复 在uni-forms 中,删除文件 ,获取的值不对的Bug -## 0.0.8(2021-06-15) -- 修复 删除文件时无法触发 v-model 的Bug -## 0.0.7(2021-05-12) -- 新增 组件示例地址 -## 0.0.6(2021-04-09) -- 修复 选择的文件非 file-extname 字段指定的扩展名报错的Bug -## 0.0.5(2021-04-09) -- 优化 更新组件示例 -## 0.0.4(2021-04-09) -- 优化 file-extname 字段支持字符串写法,多个扩展名需要用逗号分隔 -## 0.0.3(2021-02-05) -- 调整为uni_modules目录规范 -- 修复 微信小程序不指定 fileExtname 属性选择失败的Bug diff --git a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/choose-and-upload-file.js b/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/choose-and-upload-file.js deleted file mode 100644 index 24a07f57..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/choose-and-upload-file.js +++ /dev/null @@ -1,224 +0,0 @@ -'use strict'; - -const ERR_MSG_OK = 'chooseAndUploadFile:ok'; -const ERR_MSG_FAIL = 'chooseAndUploadFile:fail'; - -function chooseImage(opts) { - const { - count, - sizeType = ['original', 'compressed'], - sourceType = ['album', 'camera'], - extension - } = opts - return new Promise((resolve, reject) => { - uni.chooseImage({ - count, - sizeType, - sourceType, - extension, - success(res) { - resolve(normalizeChooseAndUploadFileRes(res, 'image')); - }, - fail(res) { - reject({ - errMsg: res.errMsg.replace('chooseImage:fail', ERR_MSG_FAIL), - }); - }, - }); - }); -} - -function chooseVideo(opts) { - const { - camera, - compressed, - maxDuration, - sourceType = ['album', 'camera'], - extension - } = opts; - return new Promise((resolve, reject) => { - uni.chooseVideo({ - camera, - compressed, - maxDuration, - sourceType, - extension, - success(res) { - const { - tempFilePath, - duration, - size, - height, - width - } = res; - resolve(normalizeChooseAndUploadFileRes({ - errMsg: 'chooseVideo:ok', - tempFilePaths: [tempFilePath], - tempFiles: [ - { - name: (res.tempFile && res.tempFile.name) || '', - path: tempFilePath, - size, - type: (res.tempFile && res.tempFile.type) || '', - width, - height, - duration, - fileType: 'video', - cloudPath: '', - }, ], - }, 'video')); - }, - fail(res) { - reject({ - errMsg: res.errMsg.replace('chooseVideo:fail', ERR_MSG_FAIL), - }); - }, - }); - }); -} - -function chooseAll(opts) { - const { - count, - extension - } = opts; - return new Promise((resolve, reject) => { - let chooseFile = uni.chooseFile; - if (typeof wx !== 'undefined' && - typeof wx.chooseMessageFile === 'function') { - chooseFile = wx.chooseMessageFile; - } - if (typeof chooseFile !== 'function') { - return reject({ - errMsg: ERR_MSG_FAIL + ' 请指定 type 类型,该平台仅支持选择 image 或 video。', - }); - } - chooseFile({ - type: 'all', - count, - extension, - success(res) { - resolve(normalizeChooseAndUploadFileRes(res)); - }, - fail(res) { - reject({ - errMsg: res.errMsg.replace('chooseFile:fail', ERR_MSG_FAIL), - }); - }, - }); - }); -} - -function normalizeChooseAndUploadFileRes(res, fileType) { - res.tempFiles.forEach((item, index) => { - if (!item.name) { - item.name = item.path.substring(item.path.lastIndexOf('/') + 1); - } - if (fileType) { - item.fileType = fileType; - } - item.cloudPath = - Date.now() + '_' + index + item.name.substring(item.name.lastIndexOf('.')); - }); - if (!res.tempFilePaths) { - res.tempFilePaths = res.tempFiles.map((file) => file.path); - } - return res; -} - -function uploadCloudFiles(files, max = 5, onUploadProgress) { - files = JSON.parse(JSON.stringify(files)) - const len = files.length - let count = 0 - let self = this - return new Promise(resolve => { - while (count < max) { - next() - } - - function next() { - let cur = count++ - if (cur >= len) { - !files.find(item => !item.url && !item.errMsg) && resolve(files) - return - } - const fileItem = files[cur] - const index = self.files.findIndex(v => v.uuid === fileItem.uuid) - fileItem.url = '' - delete fileItem.errMsg - - uniCloud - .uploadFile({ - filePath: fileItem.path, - cloudPath: fileItem.cloudPath, - fileType: fileItem.fileType, - onUploadProgress: res => { - res.index = index - onUploadProgress && onUploadProgress(res) - } - }) - .then(res => { - fileItem.url = res.fileID - fileItem.index = index - if (cur < len) { - next() - } - }) - .catch(res => { - fileItem.errMsg = res.errMsg || res.message - fileItem.index = index - if (cur < len) { - next() - } - }) - } - }) -} - - - - - -function uploadFiles(choosePromise, { - onChooseFile, - onUploadProgress -}) { - return choosePromise - .then((res) => { - if (onChooseFile) { - const customChooseRes = onChooseFile(res); - if (typeof customChooseRes !== 'undefined') { - return Promise.resolve(customChooseRes).then((chooseRes) => typeof chooseRes === 'undefined' ? - res : chooseRes); - } - } - return res; - }) - .then((res) => { - if (res === false) { - return { - errMsg: ERR_MSG_OK, - tempFilePaths: [], - tempFiles: [], - }; - } - return res - }) -} - -function chooseAndUploadFile(opts = { - type: 'all' -}) { - if (opts.type === 'image') { - return uploadFiles(chooseImage(opts), opts); - } - else if (opts.type === 'video') { - return uploadFiles(chooseVideo(opts), opts); - } - return uploadFiles(chooseAll(opts), opts); -} - -export { - chooseAndUploadFile, - uploadCloudFiles -}; diff --git a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue b/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue deleted file mode 100644 index 0928a41a..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/uni-file-picker.vue +++ /dev/null @@ -1,656 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/upload-file.vue b/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/upload-file.vue deleted file mode 100644 index 625d92ec..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/upload-file.vue +++ /dev/null @@ -1,325 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/upload-image.vue b/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/upload-image.vue deleted file mode 100644 index 2a29bc23..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/upload-image.vue +++ /dev/null @@ -1,292 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/utils.js b/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/utils.js deleted file mode 100644 index 60aaa3e4..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/components/uni-file-picker/utils.js +++ /dev/null @@ -1,109 +0,0 @@ -/** - * 获取文件名和后缀 - * @param {String} name - */ -export const get_file_ext = (name) => { - const last_len = name.lastIndexOf('.') - const len = name.length - return { - name: name.substring(0, last_len), - ext: name.substring(last_len + 1, len) - } -} - -/** - * 获取扩展名 - * @param {Array} fileExtname - */ -export const get_extname = (fileExtname) => { - if (!Array.isArray(fileExtname)) { - let extname = fileExtname.replace(/(\[|\])/g, '') - return extname.split(',') - } else { - return fileExtname - } - return [] -} - -/** - * 获取文件和检测是否可选 - */ -export const get_files_and_is_max = (res, _extname) => { - let filePaths = [] - let files = [] - if(!_extname || _extname.length === 0){ - return { - filePaths, - files - } - } - res.tempFiles.forEach(v => { - let fileFullName = get_file_ext(v.name) - const extname = fileFullName.ext.toLowerCase() - if (_extname.indexOf(extname) !== -1) { - files.push(v) - filePaths.push(v.path) - } - }) - if (files.length !== res.tempFiles.length) { - uni.showToast({ - title: `当前选择了${res.tempFiles.length}个文件 ,${res.tempFiles.length - files.length} 个文件格式不正确`, - icon: 'none', - duration: 5000 - }) - } - - return { - filePaths, - files - } -} - - -/** - * 获取图片信息 - * @param {Object} filepath - */ -export const get_file_info = (filepath) => { - return new Promise((resolve, reject) => { - uni.getImageInfo({ - src: filepath, - success(res) { - resolve(res) - }, - fail(err) { - reject(err) - } - }) - }) -} -/** - * 获取封装数据 - */ -export const get_file_data = async (files, type = 'image') => { - // 最终需要上传数据库的数据 - let fileFullName = get_file_ext(files.name) - const extname = fileFullName.ext.toLowerCase() - let filedata = { - name: files.name, - uuid: files.uuid, - extname: extname || '', - cloudPath: files.cloudPath, - fileType: files.fileType, - url: files.path || files.path, - size: files.size, //单位是字节 - image: {}, - path: files.path, - video: {} - } - if (type === 'image') { - const imageinfo = await get_file_info(files.path) - delete filedata.video - filedata.image.width = imageinfo.width - filedata.image.height = imageinfo.height - filedata.image.location = imageinfo.path - } else { - delete filedata.image - } - return filedata -} diff --git a/blog-uniapp/uni_modules/uni-file-picker/package.json b/blog-uniapp/uni_modules/uni-file-picker/package.json deleted file mode 100644 index 08bd66ec..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/package.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "id": "uni-file-picker", - "displayName": "uni-file-picker 文件选择上传", - "version": "1.0.2", - "description": "文件选择上传组件,可以选择图片、视频等任意文件并上传到当前绑定的服务空间", - "keywords": [ - "uni-ui", - "uniui", - "图片上传", - "文件上传" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "n" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-file-picker/readme.md b/blog-uniapp/uni_modules/uni-file-picker/readme.md deleted file mode 100644 index c8399a5e..00000000 --- a/blog-uniapp/uni_modules/uni-file-picker/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - -## FilePicker 文件选择上传 - -> **组件名:uni-file-picker** -> 代码块: `uFilePicker` - - -文件选择上传组件,可以选择图片、视频等任意文件并上传到当前绑定的服务空间 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-file-picker) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-forms/changelog.md b/blog-uniapp/uni_modules/uni-forms/changelog.md deleted file mode 100644 index 5a4bb79a..00000000 --- a/blog-uniapp/uni_modules/uni-forms/changelog.md +++ /dev/null @@ -1,86 +0,0 @@ -## 1.4.6(2022-07-13) -- 修复 model 需要校验的值没有声明对应字段时,导致第一次不触发校验的bug -## 1.4.5(2022-07-05) -- 新增 更多表单示例 -- 优化 子表单组件过期提示的问题 -- 优化 子表单组件uni-datetime-picker、uni-data-select、uni-data-picker的显示样式 -## 1.4.4(2022-07-04) -- 更新 删除组件日志 -## 1.4.3(2022-07-04) -- 修复 由 1.4.0 引发的 label 插槽不生效的bug -## 1.4.2(2022-07-04) -- 修复 子组件找不到 setValue 报错的bug -## 1.4.1(2022-07-04) -- 修复 uni-data-picker 在 uni-forms-item 中报错的bug -- 修复 uni-data-picker 在 uni-forms-item 中宽度不正确的bug -## 1.4.0(2022-06-30) -- 【重要】组件逻辑重构,部分用法用旧版本不兼容,请注意兼容问题 -- 【重要】组件使用 Provide/Inject 方式注入依赖,提供了自定义表单组件调用 uni-forms 校验表单的能力 -- 新增 model 属性,等同于原 value/modelValue 属性,旧属性即将废弃 -- 新增 validateTrigger 属性的 blur 值,仅 uni-easyinput 生效 -- 新增 onFieldChange 方法,可以对子表单进行校验,可替代binddata方法 -- 新增 子表单的 setRules 方法,配合自定义校验函数使用 -- 新增 uni-forms-item 的 setRules 方法,配置动态表单使用可动态更新校验规则 -- 优化 动态表单校验方式,废弃拼接name的方式 -## 1.3.3(2022-06-22) -- 修复 表单校验顺序无序问题 -## 1.3.2(2021-12-09) -- -## 1.3.1(2021-11-19) -- 修复 label 插槽不生效的bug -## 1.3.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-forms](https://uniapp.dcloud.io/component/uniui/uni-forms) -## 1.2.7(2021-08-13) -- 修复 没有添加校验规则的字段依然报错的Bug -## 1.2.6(2021-08-11) -- 修复 重置表单错误信息无法清除的问题 -## 1.2.5(2021-08-11) -- 优化 组件文档 -## 1.2.4(2021-08-11) -- 修复 表单验证只生效一次的问题 -## 1.2.3(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.2.2(2021-07-26) -- 修复 vue2 下条件编译导致destroyed生命周期失效的Bug -- 修复 1.2.1 引起的示例在小程序平台报错的Bug -## 1.2.1(2021-07-22) -- 修复 动态校验表单,默认值为空的情况下校验失效的Bug -- 修复 不指定name属性时,运行报错的Bug -- 优化 label默认宽度从65调整至70,使required为true且四字时不换行 -- 优化 组件示例,新增动态校验示例代码 -- 优化 组件文档,使用方式更清晰 -## 1.2.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.1.2(2021-06-25) -- 修复 pattern 属性在微信小程序平台无效的问题 -## 1.1.1(2021-06-22) -- 修复 validate-trigger属性为submit且err-show-type属性为toast时不能弹出的Bug -## 1.1.0(2021-06-22) -- 修复 只写setRules方法而导致校验不生效的Bug -- 修复 由上个办法引发的错误提示文字错位的Bug -## 1.0.48(2021-06-21) -- 修复 不设置 label 属性 ,无法设置label插槽的问题 -## 1.0.47(2021-06-21) -- 修复 不设置label属性,label-width属性不生效的bug -- 修复 setRules 方法与rules属性冲突的问题 -## 1.0.46(2021-06-04) -- 修复 动态删减数据导致报错的问题 -## 1.0.45(2021-06-04) -- 新增 modelValue 属性 ,value 即将废弃 -## 1.0.44(2021-06-02) -- 新增 uni-forms-item 可以设置单独的 rules -- 新增 validate 事件增加 keepitem 参数,可以选择那些字段不过滤 -- 优化 submit 事件重命名为 validate -## 1.0.43(2021-05-12) -- 新增 组件示例地址 -## 1.0.42(2021-04-30) -- 修复 自定义检验器失效的问题 -## 1.0.41(2021-03-05) -- 更新 校验器 -- 修复 表单规则设置类型为 number 的情况下,值为0校验失败的Bug -## 1.0.40(2021-03-04) -- 修复 动态显示uni-forms-item的情况下,submit 方法获取值错误的Bug -## 1.0.39(2021-02-05) -- 调整为uni_modules目录规范 -- 修复 校验器传入 int 等类型 ,返回String类型的Bug diff --git a/blog-uniapp/uni_modules/uni-forms/components/uni-forms-item/uni-forms-item.vue b/blog-uniapp/uni_modules/uni-forms/components/uni-forms-item/uni-forms-item.vue deleted file mode 100644 index 250ed875..00000000 --- a/blog-uniapp/uni_modules/uni-forms/components/uni-forms-item/uni-forms-item.vue +++ /dev/null @@ -1,627 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-forms/components/uni-forms/uni-forms.vue b/blog-uniapp/uni_modules/uni-forms/components/uni-forms/uni-forms.vue deleted file mode 100644 index ed2f6d97..00000000 --- a/blog-uniapp/uni_modules/uni-forms/components/uni-forms/uni-forms.vue +++ /dev/null @@ -1,397 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-forms/components/uni-forms/utils.js b/blog-uniapp/uni_modules/uni-forms/components/uni-forms/utils.js deleted file mode 100644 index 6da24216..00000000 --- a/blog-uniapp/uni_modules/uni-forms/components/uni-forms/utils.js +++ /dev/null @@ -1,293 +0,0 @@ -/** - * 简单处理对象拷贝 - * @param {Obejct} 被拷贝对象 - * @@return {Object} 拷贝对象 - */ -export const deepCopy = (val) => { - return JSON.parse(JSON.stringify(val)) -} -/** - * 过滤数字类型 - * @param {String} format 数字类型 - * @@return {Boolean} 返回是否为数字类型 - */ -export const typeFilter = (format) => { - return format === 'int' || format === 'double' || format === 'number' || format === 'timestamp'; -} - -/** - * 把 value 转换成指定的类型,用于处理初始值,原因是初始值需要入库不能为 undefined - * @param {String} key 字段名 - * @param {any} value 字段值 - * @param {Object} rules 表单校验规则 - */ -export const getValue = (key, value, rules) => { - const isRuleNumType = rules.find(val => val.format && typeFilter(val.format)); - const isRuleBoolType = rules.find(val => (val.format && val.format === 'boolean') || val.format === 'bool'); - // 输入类型为 number - if (!!isRuleNumType) { - if (!value && value !== 0) { - value = null - } else { - value = isNumber(Number(value)) ? Number(value) : value - } - } - - // 输入类型为 boolean - if (!!isRuleBoolType) { - value = isBoolean(value) ? value : false - } - - return value; -} - -/** - * 获取表单数据 - * @param {String|Array} name 真实名称,需要使用 realName 获取 - * @param {Object} data 原始数据 - * @param {any} value 需要设置的值 - */ -export const setDataValue = (field, formdata, value) => { - formdata[field] = value - return value || '' -} - -/** - * 获取表单数据 - * @param {String|Array} field 真实名称,需要使用 realName 获取 - * @param {Object} data 原始数据 - */ -export const getDataValue = (field, data) => { - return objGet(data, field) -} - -/** - * 获取表单类型 - * @param {String|Array} field 真实名称,需要使用 realName 获取 - */ -export const getDataValueType = (field, data) => { - const value = getDataValue(field, data) - return { - type: type(value), - value - } -} - -/** - * 获取表单可用的真实name - * @param {String|Array} name 表单name - * @@return {String} 表单可用的真实name - */ -export const realName = (name, data = {}) => { - const base_name = _basePath(name) - if (typeof base_name === 'object' && Array.isArray(base_name) && base_name.length > 1) { - const realname = base_name.reduce((a, b) => a += `#${b}`, '_formdata_') - return realname - } - return base_name[0] || name -} - -/** - * 判断是否表单可用的真实name - * @param {String|Array} name 表单name - * @@return {String} 表单可用的真实name - */ -export const isRealName = (name) => { - const reg = /^_formdata_#*/ - return reg.test(name) -} - -/** - * 获取表单数据的原始格式 - * @@return {Object|Array} object 需要解析的数据 - */ -export const rawData = (object = {}, name) => { - let newData = JSON.parse(JSON.stringify(object)) - let formData = {} - for(let i in newData){ - let path = name2arr(i) - objSet(formData,path,newData[i]) - } - return formData -} - -/** - * 真实name还原为 array - * @param {*} name - */ -export const name2arr = (name) => { - let field = name.replace('_formdata_#', '') - field = field.split('#').map(v => (isNumber(v) ? Number(v) : v)) - return field -} - -/** - * 对象中设置值 - * @param {Object|Array} object 源数据 - * @param {String| Array} path 'a.b.c' 或 ['a',0,'b','c'] - * @param {String} value 需要设置的值 - */ -export const objSet = (object, path, value) => { - if (typeof object !== 'object') return object; - _basePath(path).reduce((o, k, i, _) => { - if (i === _.length - 1) { - // 若遍历结束直接赋值 - o[k] = value - return null - } else if (k in o) { - // 若存在对应路径,则返回找到的对象,进行下一次遍历 - return o[k] - } else { - // 若不存在对应路径,则创建对应对象,若下一路径是数字,新对象赋值为空数组,否则赋值为空对象 - o[k] = /^[0-9]{1,}$/.test(_[i + 1]) ? [] : {} - return o[k] - } - }, object) - // 返回object - return object; -} - -// 处理 path, path有三种形式:'a[0].b.c'、'a.0.b.c' 和 ['a','0','b','c'],需要统一处理成数组,便于后续使用 -function _basePath(path) { - // 若是数组,则直接返回 - if (Array.isArray(path)) return path - // 若有 '[',']',则替换成将 '[' 替换成 '.',去掉 ']' - return path.replace(/\[/g, '.').replace(/\]/g, '').split('.') -} - -/** - * 从对象中获取值 - * @param {Object|Array} object 源数据 - * @param {String| Array} path 'a.b.c' 或 ['a',0,'b','c'] - * @param {String} defaultVal 如果无法从调用链中获取值的默认值 - */ -export const objGet = (object, path, defaultVal = 'undefined') => { - // 先将path处理成统一格式 - let newPath = _basePath(path) - // 递归处理,返回最后结果 - let val = newPath.reduce((o, k) => { - return (o || {})[k] - }, object); - return !val || val !== undefined ? val : defaultVal -} - - -/** - * 是否为 number 类型 - * @param {any} num 需要判断的值 - * @return {Boolean} 是否为 number - */ -export const isNumber = (num) => { - return !isNaN(Number(num)) -} - -/** - * 是否为 boolean 类型 - * @param {any} bool 需要判断的值 - * @return {Boolean} 是否为 boolean - */ -export const isBoolean = (bool) => { - return (typeof bool === 'boolean') -} -/** - * 是否有必填字段 - * @param {Object} rules 规则 - * @return {Boolean} 是否有必填字段 - */ -export const isRequiredField = (rules) => { - let isNoField = false; - for (let i = 0; i < rules.length; i++) { - const ruleData = rules[i]; - if (ruleData.required) { - isNoField = true; - break; - } - } - return isNoField; -} - - -/** - * 获取数据类型 - * @param {Any} obj 需要获取数据类型的值 - */ -export const type = (obj) => { - var class2type = {}; - - // 生成class2type映射 - "Boolean Number String Function Array Date RegExp Object Error".split(" ").map(function(item, index) { - class2type["[object " + item + "]"] = item.toLowerCase(); - }) - if (obj == null) { - return obj + ""; - } - return typeof obj === "object" || typeof obj === "function" ? - class2type[Object.prototype.toString.call(obj)] || "object" : - typeof obj; -} - -/** - * 判断两个值是否相等 - * @param {any} a 值 - * @param {any} b 值 - * @return {Boolean} 是否相等 - */ -export const isEqual = (a, b) => { - //如果a和b本来就全等 - if (a === b) { - //判断是否为0和-0 - return a !== 0 || 1 / a === 1 / b; - } - //判断是否为null和undefined - if (a == null || b == null) { - return a === b; - } - //接下来判断a和b的数据类型 - var classNameA = toString.call(a), - classNameB = toString.call(b); - //如果数据类型不相等,则返回false - if (classNameA !== classNameB) { - return false; - } - //如果数据类型相等,再根据不同数据类型分别判断 - switch (classNameA) { - case '[object RegExp]': - case '[object String]': - //进行字符串转换比较 - return '' + a === '' + b; - case '[object Number]': - //进行数字转换比较,判断是否为NaN - if (+a !== +a) { - return +b !== +b; - } - //判断是否为0或-0 - return +a === 0 ? 1 / +a === 1 / b : +a === +b; - case '[object Date]': - case '[object Boolean]': - return +a === +b; - } - //如果是对象类型 - if (classNameA == '[object Object]') { - //获取a和b的属性长度 - var propsA = Object.getOwnPropertyNames(a), - propsB = Object.getOwnPropertyNames(b); - if (propsA.length != propsB.length) { - return false; - } - for (var i = 0; i < propsA.length; i++) { - var propName = propsA[i]; - //如果对应属性对应值不相等,则返回false - if (a[propName] !== b[propName]) { - return false; - } - } - return true; - } - //如果是数组类型 - if (classNameA == '[object Array]') { - if (a.toString() == b.toString()) { - return true; - } - return false; - } -} diff --git a/blog-uniapp/uni_modules/uni-forms/components/uni-forms/validate.js b/blog-uniapp/uni_modules/uni-forms/components/uni-forms/validate.js deleted file mode 100644 index 1834c6cf..00000000 --- a/blog-uniapp/uni_modules/uni-forms/components/uni-forms/validate.js +++ /dev/null @@ -1,486 +0,0 @@ -var pattern = { - email: /^\S+?@\S+?\.\S+?$/, - idcard: /^[1-9]\d{5}(18|19|([23]\d))\d{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$/, - url: new RegExp( - "^(?!mailto:)(?:(?:http|https|ftp)://|//)(?:\\S+(?::\\S*)?@)?(?:(?:(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[0-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)(?:\\.(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)*(?:\\.(?:[a-z\\u00a1-\\uffff]{2,})))|localhost)(?::\\d{2,5})?(?:(/|\\?|#)[^\\s]*)?$", - 'i') -}; - -const FORMAT_MAPPING = { - "int": 'integer', - "bool": 'boolean', - "double": 'number', - "long": 'number', - "password": 'string' - // "fileurls": 'array' -} - -function formatMessage(args, resources = '') { - var defaultMessage = ['label'] - defaultMessage.forEach((item) => { - if (args[item] === undefined) { - args[item] = '' - } - }) - - let str = resources - for (let key in args) { - let reg = new RegExp('{' + key + '}') - str = str.replace(reg, args[key]) - } - return str -} - -function isEmptyValue(value, type) { - if (value === undefined || value === null) { - return true; - } - - if (typeof value === 'string' && !value) { - return true; - } - - if (Array.isArray(value) && !value.length) { - return true; - } - - if (type === 'object' && !Object.keys(value).length) { - return true; - } - - return false; -} - -const types = { - integer(value) { - return types.number(value) && parseInt(value, 10) === value; - }, - string(value) { - return typeof value === 'string'; - }, - number(value) { - if (isNaN(value)) { - return false; - } - return typeof value === 'number'; - }, - "boolean": function(value) { - return typeof value === 'boolean'; - }, - "float": function(value) { - return types.number(value) && !types.integer(value); - }, - array(value) { - return Array.isArray(value); - }, - object(value) { - return typeof value === 'object' && !types.array(value); - }, - date(value) { - return value instanceof Date; - }, - timestamp(value) { - if (!this.integer(value) || Math.abs(value).toString().length > 16) { - return false - } - return true; - }, - file(value) { - return typeof value.url === 'string'; - }, - email(value) { - return typeof value === 'string' && !!value.match(pattern.email) && value.length < 255; - }, - url(value) { - return typeof value === 'string' && !!value.match(pattern.url); - }, - pattern(reg, value) { - try { - return new RegExp(reg).test(value); - } catch (e) { - return false; - } - }, - method(value) { - return typeof value === 'function'; - }, - idcard(value) { - return typeof value === 'string' && !!value.match(pattern.idcard); - }, - 'url-https'(value) { - return this.url(value) && value.startsWith('https://'); - }, - 'url-scheme'(value) { - return value.startsWith('://'); - }, - 'url-web'(value) { - return false; - } -} - -class RuleValidator { - - constructor(message) { - this._message = message - } - - async validateRule(fieldKey, fieldValue, value, data, allData) { - var result = null - - let rules = fieldValue.rules - - let hasRequired = rules.findIndex((item) => { - return item.required - }) - if (hasRequired < 0) { - if (value === null || value === undefined) { - return result - } - if (typeof value === 'string' && !value.length) { - return result - } - } - - var message = this._message - - if (rules === undefined) { - return message['default'] - } - - for (var i = 0; i < rules.length; i++) { - let rule = rules[i] - let vt = this._getValidateType(rule) - - Object.assign(rule, { - label: fieldValue.label || `["${fieldKey}"]` - }) - - if (RuleValidatorHelper[vt]) { - result = RuleValidatorHelper[vt](rule, value, message) - if (result != null) { - break - } - } - - if (rule.validateExpr) { - let now = Date.now() - let resultExpr = rule.validateExpr(value, allData, now) - if (resultExpr === false) { - result = this._getMessage(rule, rule.errorMessage || this._message['default']) - break - } - } - - if (rule.validateFunction) { - result = await this.validateFunction(rule, value, data, allData, vt) - if (result !== null) { - break - } - } - } - - if (result !== null) { - result = message.TAG + result - } - - return result - } - - async validateFunction(rule, value, data, allData, vt) { - let result = null - try { - let callbackMessage = null - const res = await rule.validateFunction(rule, value, allData || data, (message) => { - callbackMessage = message - }) - if (callbackMessage || (typeof res === 'string' && res) || res === false) { - result = this._getMessage(rule, callbackMessage || res, vt) - } - } catch (e) { - result = this._getMessage(rule, e.message, vt) - } - return result - } - - _getMessage(rule, message, vt) { - return formatMessage(rule, message || rule.errorMessage || this._message[vt] || message['default']) - } - - _getValidateType(rule) { - var result = '' - if (rule.required) { - result = 'required' - } else if (rule.format) { - result = 'format' - } else if (rule.arrayType) { - result = 'arrayTypeFormat' - } else if (rule.range) { - result = 'range' - } else if (rule.maximum !== undefined || rule.minimum !== undefined) { - result = 'rangeNumber' - } else if (rule.maxLength !== undefined || rule.minLength !== undefined) { - result = 'rangeLength' - } else if (rule.pattern) { - result = 'pattern' - } else if (rule.validateFunction) { - result = 'validateFunction' - } - return result - } -} - -const RuleValidatorHelper = { - required(rule, value, message) { - if (rule.required && isEmptyValue(value, rule.format || typeof value)) { - return formatMessage(rule, rule.errorMessage || message.required); - } - - return null - }, - - range(rule, value, message) { - const { - range, - errorMessage - } = rule; - - let list = new Array(range.length); - for (let i = 0; i < range.length; i++) { - const item = range[i]; - if (types.object(item) && item.value !== undefined) { - list[i] = item.value; - } else { - list[i] = item; - } - } - - let result = false - if (Array.isArray(value)) { - result = (new Set(value.concat(list)).size === list.length); - } else { - if (list.indexOf(value) > -1) { - result = true; - } - } - - if (!result) { - return formatMessage(rule, errorMessage || message['enum']); - } - - return null - }, - - rangeNumber(rule, value, message) { - if (!types.number(value)) { - return formatMessage(rule, rule.errorMessage || message.pattern.mismatch); - } - - let { - minimum, - maximum, - exclusiveMinimum, - exclusiveMaximum - } = rule; - let min = exclusiveMinimum ? value <= minimum : value < minimum; - let max = exclusiveMaximum ? value >= maximum : value > maximum; - - if (minimum !== undefined && min) { - return formatMessage(rule, rule.errorMessage || message['number'][exclusiveMinimum ? - 'exclusiveMinimum' : 'minimum' - ]) - } else if (maximum !== undefined && max) { - return formatMessage(rule, rule.errorMessage || message['number'][exclusiveMaximum ? - 'exclusiveMaximum' : 'maximum' - ]) - } else if (minimum !== undefined && maximum !== undefined && (min || max)) { - return formatMessage(rule, rule.errorMessage || message['number'].range) - } - - return null - }, - - rangeLength(rule, value, message) { - if (!types.string(value) && !types.array(value)) { - return formatMessage(rule, rule.errorMessage || message.pattern.mismatch); - } - - let min = rule.minLength; - let max = rule.maxLength; - let val = value.length; - - if (min !== undefined && val < min) { - return formatMessage(rule, rule.errorMessage || message['length'].minLength) - } else if (max !== undefined && val > max) { - return formatMessage(rule, rule.errorMessage || message['length'].maxLength) - } else if (min !== undefined && max !== undefined && (val < min || val > max)) { - return formatMessage(rule, rule.errorMessage || message['length'].range) - } - - return null - }, - - pattern(rule, value, message) { - if (!types['pattern'](rule.pattern, value)) { - return formatMessage(rule, rule.errorMessage || message.pattern.mismatch); - } - - return null - }, - - format(rule, value, message) { - var customTypes = Object.keys(types); - var format = FORMAT_MAPPING[rule.format] ? FORMAT_MAPPING[rule.format] : (rule.format || rule.arrayType); - - if (customTypes.indexOf(format) > -1) { - if (!types[format](value)) { - return formatMessage(rule, rule.errorMessage || message.typeError); - } - } - - return null - }, - - arrayTypeFormat(rule, value, message) { - if (!Array.isArray(value)) { - return formatMessage(rule, rule.errorMessage || message.typeError); - } - - for (let i = 0; i < value.length; i++) { - const element = value[i]; - let formatResult = this.format(rule, element, message) - if (formatResult !== null) { - return formatResult - } - } - - return null - } -} - -class SchemaValidator extends RuleValidator { - - constructor(schema, options) { - super(SchemaValidator.message); - - this._schema = schema - this._options = options || null - } - - updateSchema(schema) { - this._schema = schema - } - - async validate(data, allData) { - let result = this._checkFieldInSchema(data) - if (!result) { - result = await this.invokeValidate(data, false, allData) - } - return result.length ? result[0] : null - } - - async validateAll(data, allData) { - let result = this._checkFieldInSchema(data) - if (!result) { - result = await this.invokeValidate(data, true, allData) - } - return result - } - - async validateUpdate(data, allData) { - let result = this._checkFieldInSchema(data) - if (!result) { - result = await this.invokeValidateUpdate(data, false, allData) - } - return result.length ? result[0] : null - } - - async invokeValidate(data, all, allData) { - let result = [] - let schema = this._schema - for (let key in schema) { - let value = schema[key] - let errorMessage = await this.validateRule(key, value, data[key], data, allData) - if (errorMessage != null) { - result.push({ - key, - errorMessage - }) - if (!all) break - } - } - return result - } - - async invokeValidateUpdate(data, all, allData) { - let result = [] - for (let key in data) { - let errorMessage = await this.validateRule(key, this._schema[key], data[key], data, allData) - if (errorMessage != null) { - result.push({ - key, - errorMessage - }) - if (!all) break - } - } - return result - } - - _checkFieldInSchema(data) { - var keys = Object.keys(data) - var keys2 = Object.keys(this._schema) - if (new Set(keys.concat(keys2)).size === keys2.length) { - return '' - } - - var noExistFields = keys.filter((key) => { - return keys2.indexOf(key) < 0; - }) - var errorMessage = formatMessage({ - field: JSON.stringify(noExistFields) - }, SchemaValidator.message.TAG + SchemaValidator.message['defaultInvalid']) - return [{ - key: 'invalid', - errorMessage - }] - } -} - -function Message() { - return { - TAG: "", - default: '验证错误', - defaultInvalid: '提交的字段{field}在数据库中并不存在', - validateFunction: '验证无效', - required: '{label}必填', - 'enum': '{label}超出范围', - timestamp: '{label}格式无效', - whitespace: '{label}不能为空', - typeError: '{label}类型无效', - date: { - format: '{label}日期{value}格式无效', - parse: '{label}日期无法解析,{value}无效', - invalid: '{label}日期{value}无效' - }, - length: { - minLength: '{label}长度不能少于{minLength}', - maxLength: '{label}长度不能超过{maxLength}', - range: '{label}必须介于{minLength}和{maxLength}之间' - }, - number: { - minimum: '{label}不能小于{minimum}', - maximum: '{label}不能大于{maximum}', - exclusiveMinimum: '{label}不能小于等于{minimum}', - exclusiveMaximum: '{label}不能大于等于{maximum}', - range: '{label}必须介于{minimum}and{maximum}之间' - }, - pattern: { - mismatch: '{label}格式不匹配' - } - }; -} - - -SchemaValidator.message = new Message(); - -export default SchemaValidator diff --git a/blog-uniapp/uni_modules/uni-forms/package.json b/blog-uniapp/uni_modules/uni-forms/package.json deleted file mode 100644 index e69d39b5..00000000 --- a/blog-uniapp/uni_modules/uni-forms/package.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "id": "uni-forms", - "displayName": "uni-forms 表单", - "version": "1.4.6", - "description": "由输入框、选择器、单选框、多选框等控件组成,用以收集、校验、提交数据", - "keywords": [ - "uni-ui", - "表单", - "校验", - "表单校验", - "表单验证" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y", - "京东": "u" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-forms/readme.md b/blog-uniapp/uni_modules/uni-forms/readme.md deleted file mode 100644 index 63d5a043..00000000 --- a/blog-uniapp/uni_modules/uni-forms/readme.md +++ /dev/null @@ -1,23 +0,0 @@ - - -## Forms 表单 - -> **组件名:uni-forms** -> 代码块: `uForms`、`uni-forms-item` -> 关联组件:`uni-forms-item`、`uni-easyinput`、`uni-data-checkbox`、`uni-group`。 - - -uni-app的内置组件已经有了 `
`组件,用于提交表单内容。 - -然而几乎每个表单都需要做表单验证,为了方便做表单验证,减少重复开发,`uni ui` 又基于 ``组件封装了 ``组件,内置了表单验证功能。 - -`` 提供了 `rules`属性来描述校验规则、``子组件来包裹具体的表单项,以及给原生或三方组件提供了 `binddata()` 来设置表单值。 - -每个要校验的表单项,不管input还是checkbox,都必须放在``组件中,且一个``组件只能放置一个表单项。 - -``组件内部预留了显示error message的区域,默认是在表单项的底部。 - -另外,``组件下面的各个表单项,可以通过``包裹为不同的分组。同一``下的不同表单项目将聚拢在一起,同其他group保持垂直间距。``仅影响视觉效果。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-forms) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-goods-nav/changelog.md b/blog-uniapp/uni_modules/uni-goods-nav/changelog.md deleted file mode 100644 index c6264c67..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/changelog.md +++ /dev/null @@ -1,18 +0,0 @@ -## 1.2.1(2022-05-30) -- 新增 stat属性,是否开启uni统计功能 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-goods-nav](https://uniapp.dcloud.io/component/uniui/uni-goods-nav) -## 1.1.1(2021-08-24) -- 新增 支持国际化 -## 1.1.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.7(2021-05-12) -- 新增 组件示例地址 -## 1.0.6(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 1.0.5(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.4(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/en.json b/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/en.json deleted file mode 100644 index dcdba41c..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/en.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "uni-goods-nav.options.shop": "shop", - "uni-goods-nav.options.cart": "cart", - "uni-goods-nav.buttonGroup.addToCart": "add to cart", - "uni-goods-nav.buttonGroup.buyNow": "buy now" -} diff --git a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/index.js b/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/zh-Hans.json deleted file mode 100644 index 48ee344c..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/zh-Hans.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "uni-goods-nav.options.shop": "店铺", - "uni-goods-nav.options.cart": "购物车", - "uni-goods-nav.buttonGroup.addToCart": "加入购物车", - "uni-goods-nav.buttonGroup.buyNow": "立即购买" -} diff --git a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/zh-Hant.json deleted file mode 100644 index d0a0255c..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/i18n/zh-Hant.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "uni-goods-nav.options.shop": "店鋪", - "uni-goods-nav.options.cart": "購物車", - "uni-goods-nav.buttonGroup.addToCart": "加入購物車", - "uni-goods-nav.buttonGroup.buyNow": "立即購買" -} diff --git a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/uni-goods-nav.vue b/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/uni-goods-nav.vue deleted file mode 100644 index 8a16b175..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/components/uni-goods-nav/uni-goods-nav.vue +++ /dev/null @@ -1,229 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-goods-nav/package.json b/blog-uniapp/uni_modules/uni-goods-nav/package.json deleted file mode 100644 index 636e45e7..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-goods-nav", - "displayName": "uni-goods-nav 商品导航", - "version": "1.2.1", - "description": "商品导航组件主要用于电商类应用底部导航,可自定义加入购物车,购买等操作", - "keywords": [ - "uni-ui", - "uniui", - "商品导航" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-goods-nav/readme.md b/blog-uniapp/uni_modules/uni-goods-nav/readme.md deleted file mode 100644 index 07df93f5..00000000 --- a/blog-uniapp/uni_modules/uni-goods-nav/readme.md +++ /dev/null @@ -1,10 +0,0 @@ - - -## GoodsNav 商品导航 -> **组件名:uni-goods-nav** -> 代码块: `uGoodsNav` - -商品加入购物车,立即购买等。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-goods-nav) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-grid/changelog.md b/blog-uniapp/uni_modules/uni-grid/changelog.md deleted file mode 100644 index d301166c..00000000 --- a/blog-uniapp/uni_modules/uni-grid/changelog.md +++ /dev/null @@ -1,13 +0,0 @@ -## 1.4.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-grid](https://uniapp.dcloud.io/component/uniui/uni-grid) -## 1.3.2(2021-11-09) -- 新增 提供组件设计资源,组件样式调整 -## 1.3.1(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.3.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.2.4(2021-05-12) -- 新增 组件示例地址 -## 1.2.3(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-grid/components/uni-grid-item/uni-grid-item.vue b/blog-uniapp/uni_modules/uni-grid/components/uni-grid-item/uni-grid-item.vue deleted file mode 100644 index 20fd54e5..00000000 --- a/blog-uniapp/uni_modules/uni-grid/components/uni-grid-item/uni-grid-item.vue +++ /dev/null @@ -1,127 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-grid/components/uni-grid/uni-grid.vue b/blog-uniapp/uni_modules/uni-grid/components/uni-grid/uni-grid.vue deleted file mode 100644 index 96a412f6..00000000 --- a/blog-uniapp/uni_modules/uni-grid/components/uni-grid/uni-grid.vue +++ /dev/null @@ -1,142 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-grid/package.json b/blog-uniapp/uni_modules/uni-grid/package.json deleted file mode 100644 index ccb2c917..00000000 --- a/blog-uniapp/uni_modules/uni-grid/package.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "id": "uni-grid", - "displayName": "uni-grid 宫格", - "version": "1.4.0", - "description": "Grid 宫格组件,提供移动端常见的宫格布局,如九宫格。", - "keywords": [ - "uni-ui", - "uniui", - "九宫格", - "表格" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss","uni-icons"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-grid/readme.md b/blog-uniapp/uni_modules/uni-grid/readme.md deleted file mode 100644 index 0aa44cc1..00000000 --- a/blog-uniapp/uni_modules/uni-grid/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -## Grid 宫格 -> **组件名:uni-grid** -> 代码块: `uGrid` - - -宫格组件。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-grid) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-group/changelog.md b/blog-uniapp/uni_modules/uni-group/changelog.md deleted file mode 100644 index a7024fdf..00000000 --- a/blog-uniapp/uni_modules/uni-group/changelog.md +++ /dev/null @@ -1,16 +0,0 @@ -## 1.2.2(2022-05-30) -- 新增 stat属性,是否开启uni统计功能 -## 1.2.1(2021-11-22) -- 修复 vue3中某些scss变量无法找到的问题 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-group](https://uniapp.dcloud.io/component/uniui/uni-group) -## 1.1.7(2021-11-08) -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -- 优化 组件文档 -## 1.0.3(2021-05-12) -- 新增 组件示例地址 -## 1.0.2(2021-02-05) -- 调整为uni_modules目录规范 -- 优化 兼容 nvue 页面 diff --git a/blog-uniapp/uni_modules/uni-group/components/uni-group/uni-group.vue b/blog-uniapp/uni_modules/uni-group/components/uni-group/uni-group.vue deleted file mode 100644 index 3425ecd3..00000000 --- a/blog-uniapp/uni_modules/uni-group/components/uni-group/uni-group.vue +++ /dev/null @@ -1,134 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-group/package.json b/blog-uniapp/uni_modules/uni-group/package.json deleted file mode 100644 index ea00a08c..00000000 --- a/blog-uniapp/uni_modules/uni-group/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-group", - "displayName": "uni-group 分组", - "version": "1.2.2", - "description": "分组组件可用于将组件用于分组,添加间隔,以产生明显的区块", - "keywords": [ - "uni-ui", - "uniui", - "group", - "分组", - "" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-group/readme.md b/blog-uniapp/uni_modules/uni-group/readme.md deleted file mode 100644 index bae67f46..00000000 --- a/blog-uniapp/uni_modules/uni-group/readme.md +++ /dev/null @@ -1,9 +0,0 @@ - -## Group 分组 -> **组件名:uni-group** -> 代码块: `uGroup` - -分组组件可用于将组件分组,添加间隔,以产生明显的区块。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-group) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-icons/changelog.md b/blog-uniapp/uni_modules/uni-icons/changelog.md deleted file mode 100644 index 64498853..00000000 --- a/blog-uniapp/uni_modules/uni-icons/changelog.md +++ /dev/null @@ -1,22 +0,0 @@ -## 1.3.5(2022-01-24) -- 优化 size 属性可以传入不带单位的字符串数值 -## 1.3.4(2022-01-24) -- 优化 size 支持其他单位 -## 1.3.3(2022-01-17) -- 修复 nvue 有些图标不显示的bug,兼容老版本图标 -## 1.3.2(2021-12-01) -- 优化 示例可复制图标名称 -## 1.3.1(2021-11-23) -- 优化 兼容旧组件 type 值 -## 1.3.0(2021-11-19) -- 新增 更多图标 -- 优化 自定义图标使用方式 -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-icons](https://uniapp.dcloud.io/component/uniui/uni-icons) -## 1.1.7(2021-11-08) -## 1.2.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.1.5(2021-05-12) -- 新增 组件示例地址 -## 1.1.4(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/icons.js b/blog-uniapp/uni_modules/uni-icons/components/uni-icons/icons.js deleted file mode 100644 index 78899364..00000000 --- a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/icons.js +++ /dev/null @@ -1,1169 +0,0 @@ -export default { - "id": "2852637", - "name": "uniui图标库", - "font_family": "uniicons", - "css_prefix_text": "uniui-", - "description": "", - "glyphs": [ - { - "icon_id": "25027049", - "name": "yanse", - "font_class": "color", - "unicode": "e6cf", - "unicode_decimal": 59087 - }, - { - "icon_id": "25027048", - "name": "wallet", - "font_class": "wallet", - "unicode": "e6b1", - "unicode_decimal": 59057 - }, - { - "icon_id": "25015720", - "name": "settings-filled", - "font_class": "settings-filled", - "unicode": "e6ce", - "unicode_decimal": 59086 - }, - { - "icon_id": "25015434", - "name": "shimingrenzheng-filled", - "font_class": "auth-filled", - "unicode": "e6cc", - "unicode_decimal": 59084 - }, - { - "icon_id": "24934246", - "name": "shop-filled", - "font_class": "shop-filled", - "unicode": "e6cd", - "unicode_decimal": 59085 - }, - { - "icon_id": "24934159", - "name": "staff-filled-01", - "font_class": "staff-filled", - "unicode": "e6cb", - "unicode_decimal": 59083 - }, - { - "icon_id": "24932461", - "name": "VIP-filled", - "font_class": "vip-filled", - "unicode": "e6c6", - "unicode_decimal": 59078 - }, - { - "icon_id": "24932462", - "name": "plus_circle_fill", - "font_class": "plus-filled", - "unicode": "e6c7", - "unicode_decimal": 59079 - }, - { - "icon_id": "24932463", - "name": "folder_add-filled", - "font_class": "folder-add-filled", - "unicode": "e6c8", - "unicode_decimal": 59080 - }, - { - "icon_id": "24932464", - "name": "yanse-filled", - "font_class": "color-filled", - "unicode": "e6c9", - "unicode_decimal": 59081 - }, - { - "icon_id": "24932465", - "name": "tune-filled", - "font_class": "tune-filled", - "unicode": "e6ca", - "unicode_decimal": 59082 - }, - { - "icon_id": "24932455", - "name": "a-rilidaka-filled", - "font_class": "calendar-filled", - "unicode": "e6c0", - "unicode_decimal": 59072 - }, - { - "icon_id": "24932456", - "name": "notification-filled", - "font_class": "notification-filled", - "unicode": "e6c1", - "unicode_decimal": 59073 - }, - { - "icon_id": "24932457", - "name": "wallet-filled", - "font_class": "wallet-filled", - "unicode": "e6c2", - "unicode_decimal": 59074 - }, - { - "icon_id": "24932458", - "name": "paihangbang-filled", - "font_class": "medal-filled", - "unicode": "e6c3", - "unicode_decimal": 59075 - }, - { - "icon_id": "24932459", - "name": "gift-filled", - "font_class": "gift-filled", - "unicode": "e6c4", - "unicode_decimal": 59076 - }, - { - "icon_id": "24932460", - "name": "fire-filled", - "font_class": "fire-filled", - "unicode": "e6c5", - "unicode_decimal": 59077 - }, - { - "icon_id": "24928001", - "name": "refreshempty", - "font_class": "refreshempty", - "unicode": "e6bf", - "unicode_decimal": 59071 - }, - { - "icon_id": "24926853", - "name": "location-ellipse", - "font_class": "location-filled", - "unicode": "e6af", - "unicode_decimal": 59055 - }, - { - "icon_id": "24926735", - "name": "person-filled", - "font_class": "person-filled", - "unicode": "e69d", - "unicode_decimal": 59037 - }, - { - "icon_id": "24926703", - "name": "personadd-filled", - "font_class": "personadd-filled", - "unicode": "e698", - "unicode_decimal": 59032 - }, - { - "icon_id": "24923351", - "name": "back", - "font_class": "back", - "unicode": "e6b9", - "unicode_decimal": 59065 - }, - { - "icon_id": "24923352", - "name": "forward", - "font_class": "forward", - "unicode": "e6ba", - "unicode_decimal": 59066 - }, - { - "icon_id": "24923353", - "name": "arrowthinright", - "font_class": "arrow-right", - "unicode": "e6bb", - "unicode_decimal": 59067 - }, - { - "icon_id": "24923353", - "name": "arrowthinright", - "font_class": "arrowthinright", - "unicode": "e6bb", - "unicode_decimal": 59067 - }, - { - "icon_id": "24923354", - "name": "arrowthinleft", - "font_class": "arrow-left", - "unicode": "e6bc", - "unicode_decimal": 59068 - }, - { - "icon_id": "24923354", - "name": "arrowthinleft", - "font_class": "arrowthinleft", - "unicode": "e6bc", - "unicode_decimal": 59068 - }, - { - "icon_id": "24923355", - "name": "arrowthinup", - "font_class": "arrow-up", - "unicode": "e6bd", - "unicode_decimal": 59069 - }, - { - "icon_id": "24923355", - "name": "arrowthinup", - "font_class": "arrowthinup", - "unicode": "e6bd", - "unicode_decimal": 59069 - }, - { - "icon_id": "24923356", - "name": "arrowthindown", - "font_class": "arrow-down", - "unicode": "e6be", - "unicode_decimal": 59070 - },{ - "icon_id": "24923356", - "name": "arrowthindown", - "font_class": "arrowthindown", - "unicode": "e6be", - "unicode_decimal": 59070 - }, - { - "icon_id": "24923349", - "name": "arrowdown", - "font_class": "bottom", - "unicode": "e6b8", - "unicode_decimal": 59064 - },{ - "icon_id": "24923349", - "name": "arrowdown", - "font_class": "arrowdown", - "unicode": "e6b8", - "unicode_decimal": 59064 - }, - { - "icon_id": "24923346", - "name": "arrowright", - "font_class": "right", - "unicode": "e6b5", - "unicode_decimal": 59061 - }, - { - "icon_id": "24923346", - "name": "arrowright", - "font_class": "arrowright", - "unicode": "e6b5", - "unicode_decimal": 59061 - }, - { - "icon_id": "24923347", - "name": "arrowup", - "font_class": "top", - "unicode": "e6b6", - "unicode_decimal": 59062 - }, - { - "icon_id": "24923347", - "name": "arrowup", - "font_class": "arrowup", - "unicode": "e6b6", - "unicode_decimal": 59062 - }, - { - "icon_id": "24923348", - "name": "arrowleft", - "font_class": "left", - "unicode": "e6b7", - "unicode_decimal": 59063 - }, - { - "icon_id": "24923348", - "name": "arrowleft", - "font_class": "arrowleft", - "unicode": "e6b7", - "unicode_decimal": 59063 - }, - { - "icon_id": "24923334", - "name": "eye", - "font_class": "eye", - "unicode": "e651", - "unicode_decimal": 58961 - }, - { - "icon_id": "24923335", - "name": "eye-filled", - "font_class": "eye-filled", - "unicode": "e66a", - "unicode_decimal": 58986 - }, - { - "icon_id": "24923336", - "name": "eye-slash", - "font_class": "eye-slash", - "unicode": "e6b3", - "unicode_decimal": 59059 - }, - { - "icon_id": "24923337", - "name": "eye-slash-filled", - "font_class": "eye-slash-filled", - "unicode": "e6b4", - "unicode_decimal": 59060 - }, - { - "icon_id": "24923305", - "name": "info-filled", - "font_class": "info-filled", - "unicode": "e649", - "unicode_decimal": 58953 - }, - { - "icon_id": "24923299", - "name": "reload-01", - "font_class": "reload", - "unicode": "e6b2", - "unicode_decimal": 59058 - }, - { - "icon_id": "24923195", - "name": "mic_slash_fill", - "font_class": "micoff-filled", - "unicode": "e6b0", - "unicode_decimal": 59056 - }, - { - "icon_id": "24923165", - "name": "map-pin-ellipse", - "font_class": "map-pin-ellipse", - "unicode": "e6ac", - "unicode_decimal": 59052 - }, - { - "icon_id": "24923166", - "name": "map-pin", - "font_class": "map-pin", - "unicode": "e6ad", - "unicode_decimal": 59053 - }, - { - "icon_id": "24923167", - "name": "location", - "font_class": "location", - "unicode": "e6ae", - "unicode_decimal": 59054 - }, - { - "icon_id": "24923064", - "name": "starhalf", - "font_class": "starhalf", - "unicode": "e683", - "unicode_decimal": 59011 - }, - { - "icon_id": "24923065", - "name": "star", - "font_class": "star", - "unicode": "e688", - "unicode_decimal": 59016 - }, - { - "icon_id": "24923066", - "name": "star-filled", - "font_class": "star-filled", - "unicode": "e68f", - "unicode_decimal": 59023 - }, - { - "icon_id": "24899646", - "name": "a-rilidaka", - "font_class": "calendar", - "unicode": "e6a0", - "unicode_decimal": 59040 - }, - { - "icon_id": "24899647", - "name": "fire", - "font_class": "fire", - "unicode": "e6a1", - "unicode_decimal": 59041 - }, - { - "icon_id": "24899648", - "name": "paihangbang", - "font_class": "medal", - "unicode": "e6a2", - "unicode_decimal": 59042 - }, - { - "icon_id": "24899649", - "name": "font", - "font_class": "font", - "unicode": "e6a3", - "unicode_decimal": 59043 - }, - { - "icon_id": "24899650", - "name": "gift", - "font_class": "gift", - "unicode": "e6a4", - "unicode_decimal": 59044 - }, - { - "icon_id": "24899651", - "name": "link", - "font_class": "link", - "unicode": "e6a5", - "unicode_decimal": 59045 - }, - { - "icon_id": "24899652", - "name": "notification", - "font_class": "notification", - "unicode": "e6a6", - "unicode_decimal": 59046 - }, - { - "icon_id": "24899653", - "name": "staff", - "font_class": "staff", - "unicode": "e6a7", - "unicode_decimal": 59047 - }, - { - "icon_id": "24899654", - "name": "VIP", - "font_class": "vip", - "unicode": "e6a8", - "unicode_decimal": 59048 - }, - { - "icon_id": "24899655", - "name": "folder_add", - "font_class": "folder-add", - "unicode": "e6a9", - "unicode_decimal": 59049 - }, - { - "icon_id": "24899656", - "name": "tune", - "font_class": "tune", - "unicode": "e6aa", - "unicode_decimal": 59050 - }, - { - "icon_id": "24899657", - "name": "shimingrenzheng", - "font_class": "auth", - "unicode": "e6ab", - "unicode_decimal": 59051 - }, - { - "icon_id": "24899565", - "name": "person", - "font_class": "person", - "unicode": "e699", - "unicode_decimal": 59033 - }, - { - "icon_id": "24899566", - "name": "email-filled", - "font_class": "email-filled", - "unicode": "e69a", - "unicode_decimal": 59034 - }, - { - "icon_id": "24899567", - "name": "phone-filled", - "font_class": "phone-filled", - "unicode": "e69b", - "unicode_decimal": 59035 - }, - { - "icon_id": "24899568", - "name": "phone", - "font_class": "phone", - "unicode": "e69c", - "unicode_decimal": 59036 - }, - { - "icon_id": "24899570", - "name": "email", - "font_class": "email", - "unicode": "e69e", - "unicode_decimal": 59038 - }, - { - "icon_id": "24899571", - "name": "personadd", - "font_class": "personadd", - "unicode": "e69f", - "unicode_decimal": 59039 - }, - { - "icon_id": "24899558", - "name": "chatboxes-filled", - "font_class": "chatboxes-filled", - "unicode": "e692", - "unicode_decimal": 59026 - }, - { - "icon_id": "24899559", - "name": "contact", - "font_class": "contact", - "unicode": "e693", - "unicode_decimal": 59027 - }, - { - "icon_id": "24899560", - "name": "chatbubble-filled", - "font_class": "chatbubble-filled", - "unicode": "e694", - "unicode_decimal": 59028 - }, - { - "icon_id": "24899561", - "name": "contact-filled", - "font_class": "contact-filled", - "unicode": "e695", - "unicode_decimal": 59029 - }, - { - "icon_id": "24899562", - "name": "chatboxes", - "font_class": "chatboxes", - "unicode": "e696", - "unicode_decimal": 59030 - }, - { - "icon_id": "24899563", - "name": "chatbubble", - "font_class": "chatbubble", - "unicode": "e697", - "unicode_decimal": 59031 - }, - { - "icon_id": "24881290", - "name": "upload-filled", - "font_class": "upload-filled", - "unicode": "e68e", - "unicode_decimal": 59022 - }, - { - "icon_id": "24881292", - "name": "upload", - "font_class": "upload", - "unicode": "e690", - "unicode_decimal": 59024 - }, - { - "icon_id": "24881293", - "name": "weixin", - "font_class": "weixin", - "unicode": "e691", - "unicode_decimal": 59025 - }, - { - "icon_id": "24881274", - "name": "compose", - "font_class": "compose", - "unicode": "e67f", - "unicode_decimal": 59007 - }, - { - "icon_id": "24881275", - "name": "qq", - "font_class": "qq", - "unicode": "e680", - "unicode_decimal": 59008 - }, - { - "icon_id": "24881276", - "name": "download-filled", - "font_class": "download-filled", - "unicode": "e681", - "unicode_decimal": 59009 - }, - { - "icon_id": "24881277", - "name": "pengyouquan", - "font_class": "pyq", - "unicode": "e682", - "unicode_decimal": 59010 - }, - { - "icon_id": "24881279", - "name": "sound", - "font_class": "sound", - "unicode": "e684", - "unicode_decimal": 59012 - }, - { - "icon_id": "24881280", - "name": "trash-filled", - "font_class": "trash-filled", - "unicode": "e685", - "unicode_decimal": 59013 - }, - { - "icon_id": "24881281", - "name": "sound-filled", - "font_class": "sound-filled", - "unicode": "e686", - "unicode_decimal": 59014 - }, - { - "icon_id": "24881282", - "name": "trash", - "font_class": "trash", - "unicode": "e687", - "unicode_decimal": 59015 - }, - { - "icon_id": "24881284", - "name": "videocam-filled", - "font_class": "videocam-filled", - "unicode": "e689", - "unicode_decimal": 59017 - }, - { - "icon_id": "24881285", - "name": "spinner-cycle", - "font_class": "spinner-cycle", - "unicode": "e68a", - "unicode_decimal": 59018 - }, - { - "icon_id": "24881286", - "name": "weibo", - "font_class": "weibo", - "unicode": "e68b", - "unicode_decimal": 59019 - }, - { - "icon_id": "24881288", - "name": "videocam", - "font_class": "videocam", - "unicode": "e68c", - "unicode_decimal": 59020 - }, - { - "icon_id": "24881289", - "name": "download", - "font_class": "download", - "unicode": "e68d", - "unicode_decimal": 59021 - }, - { - "icon_id": "24879601", - "name": "help", - "font_class": "help", - "unicode": "e679", - "unicode_decimal": 59001 - }, - { - "icon_id": "24879602", - "name": "navigate-filled", - "font_class": "navigate-filled", - "unicode": "e67a", - "unicode_decimal": 59002 - }, - { - "icon_id": "24879603", - "name": "plusempty", - "font_class": "plusempty", - "unicode": "e67b", - "unicode_decimal": 59003 - }, - { - "icon_id": "24879604", - "name": "smallcircle", - "font_class": "smallcircle", - "unicode": "e67c", - "unicode_decimal": 59004 - }, - { - "icon_id": "24879605", - "name": "minus-filled", - "font_class": "minus-filled", - "unicode": "e67d", - "unicode_decimal": 59005 - }, - { - "icon_id": "24879606", - "name": "micoff", - "font_class": "micoff", - "unicode": "e67e", - "unicode_decimal": 59006 - }, - { - "icon_id": "24879588", - "name": "closeempty", - "font_class": "closeempty", - "unicode": "e66c", - "unicode_decimal": 58988 - }, - { - "icon_id": "24879589", - "name": "clear", - "font_class": "clear", - "unicode": "e66d", - "unicode_decimal": 58989 - }, - { - "icon_id": "24879590", - "name": "navigate", - "font_class": "navigate", - "unicode": "e66e", - "unicode_decimal": 58990 - }, - { - "icon_id": "24879591", - "name": "minus", - "font_class": "minus", - "unicode": "e66f", - "unicode_decimal": 58991 - }, - { - "icon_id": "24879592", - "name": "image", - "font_class": "image", - "unicode": "e670", - "unicode_decimal": 58992 - }, - { - "icon_id": "24879593", - "name": "mic", - "font_class": "mic", - "unicode": "e671", - "unicode_decimal": 58993 - }, - { - "icon_id": "24879594", - "name": "paperplane", - "font_class": "paperplane", - "unicode": "e672", - "unicode_decimal": 58994 - }, - { - "icon_id": "24879595", - "name": "close", - "font_class": "close", - "unicode": "e673", - "unicode_decimal": 58995 - }, - { - "icon_id": "24879596", - "name": "help-filled", - "font_class": "help-filled", - "unicode": "e674", - "unicode_decimal": 58996 - }, - { - "icon_id": "24879597", - "name": "plus-filled", - "font_class": "paperplane-filled", - "unicode": "e675", - "unicode_decimal": 58997 - }, - { - "icon_id": "24879598", - "name": "plus", - "font_class": "plus", - "unicode": "e676", - "unicode_decimal": 58998 - }, - { - "icon_id": "24879599", - "name": "mic-filled", - "font_class": "mic-filled", - "unicode": "e677", - "unicode_decimal": 58999 - }, - { - "icon_id": "24879600", - "name": "image-filled", - "font_class": "image-filled", - "unicode": "e678", - "unicode_decimal": 59000 - }, - { - "icon_id": "24855900", - "name": "locked-filled", - "font_class": "locked-filled", - "unicode": "e668", - "unicode_decimal": 58984 - }, - { - "icon_id": "24855901", - "name": "info", - "font_class": "info", - "unicode": "e669", - "unicode_decimal": 58985 - }, - { - "icon_id": "24855903", - "name": "locked", - "font_class": "locked", - "unicode": "e66b", - "unicode_decimal": 58987 - }, - { - "icon_id": "24855884", - "name": "camera-filled", - "font_class": "camera-filled", - "unicode": "e658", - "unicode_decimal": 58968 - }, - { - "icon_id": "24855885", - "name": "chat-filled", - "font_class": "chat-filled", - "unicode": "e659", - "unicode_decimal": 58969 - }, - { - "icon_id": "24855886", - "name": "camera", - "font_class": "camera", - "unicode": "e65a", - "unicode_decimal": 58970 - }, - { - "icon_id": "24855887", - "name": "circle", - "font_class": "circle", - "unicode": "e65b", - "unicode_decimal": 58971 - }, - { - "icon_id": "24855888", - "name": "checkmarkempty", - "font_class": "checkmarkempty", - "unicode": "e65c", - "unicode_decimal": 58972 - }, - { - "icon_id": "24855889", - "name": "chat", - "font_class": "chat", - "unicode": "e65d", - "unicode_decimal": 58973 - }, - { - "icon_id": "24855890", - "name": "circle-filled", - "font_class": "circle-filled", - "unicode": "e65e", - "unicode_decimal": 58974 - }, - { - "icon_id": "24855891", - "name": "flag", - "font_class": "flag", - "unicode": "e65f", - "unicode_decimal": 58975 - }, - { - "icon_id": "24855892", - "name": "flag-filled", - "font_class": "flag-filled", - "unicode": "e660", - "unicode_decimal": 58976 - }, - { - "icon_id": "24855893", - "name": "gear-filled", - "font_class": "gear-filled", - "unicode": "e661", - "unicode_decimal": 58977 - }, - { - "icon_id": "24855894", - "name": "home", - "font_class": "home", - "unicode": "e662", - "unicode_decimal": 58978 - }, - { - "icon_id": "24855895", - "name": "home-filled", - "font_class": "home-filled", - "unicode": "e663", - "unicode_decimal": 58979 - }, - { - "icon_id": "24855896", - "name": "gear", - "font_class": "gear", - "unicode": "e664", - "unicode_decimal": 58980 - }, - { - "icon_id": "24855897", - "name": "smallcircle-filled", - "font_class": "smallcircle-filled", - "unicode": "e665", - "unicode_decimal": 58981 - }, - { - "icon_id": "24855898", - "name": "map-filled", - "font_class": "map-filled", - "unicode": "e666", - "unicode_decimal": 58982 - }, - { - "icon_id": "24855899", - "name": "map", - "font_class": "map", - "unicode": "e667", - "unicode_decimal": 58983 - }, - { - "icon_id": "24855825", - "name": "refresh-filled", - "font_class": "refresh-filled", - "unicode": "e656", - "unicode_decimal": 58966 - }, - { - "icon_id": "24855826", - "name": "refresh", - "font_class": "refresh", - "unicode": "e657", - "unicode_decimal": 58967 - }, - { - "icon_id": "24855808", - "name": "cloud-upload", - "font_class": "cloud-upload", - "unicode": "e645", - "unicode_decimal": 58949 - }, - { - "icon_id": "24855809", - "name": "cloud-download-filled", - "font_class": "cloud-download-filled", - "unicode": "e646", - "unicode_decimal": 58950 - }, - { - "icon_id": "24855810", - "name": "cloud-download", - "font_class": "cloud-download", - "unicode": "e647", - "unicode_decimal": 58951 - }, - { - "icon_id": "24855811", - "name": "cloud-upload-filled", - "font_class": "cloud-upload-filled", - "unicode": "e648", - "unicode_decimal": 58952 - }, - { - "icon_id": "24855813", - "name": "redo", - "font_class": "redo", - "unicode": "e64a", - "unicode_decimal": 58954 - }, - { - "icon_id": "24855814", - "name": "images-filled", - "font_class": "images-filled", - "unicode": "e64b", - "unicode_decimal": 58955 - }, - { - "icon_id": "24855815", - "name": "undo-filled", - "font_class": "undo-filled", - "unicode": "e64c", - "unicode_decimal": 58956 - }, - { - "icon_id": "24855816", - "name": "more", - "font_class": "more", - "unicode": "e64d", - "unicode_decimal": 58957 - }, - { - "icon_id": "24855817", - "name": "more-filled", - "font_class": "more-filled", - "unicode": "e64e", - "unicode_decimal": 58958 - }, - { - "icon_id": "24855818", - "name": "undo", - "font_class": "undo", - "unicode": "e64f", - "unicode_decimal": 58959 - }, - { - "icon_id": "24855819", - "name": "images", - "font_class": "images", - "unicode": "e650", - "unicode_decimal": 58960 - }, - { - "icon_id": "24855821", - "name": "paperclip", - "font_class": "paperclip", - "unicode": "e652", - "unicode_decimal": 58962 - }, - { - "icon_id": "24855822", - "name": "settings", - "font_class": "settings", - "unicode": "e653", - "unicode_decimal": 58963 - }, - { - "icon_id": "24855823", - "name": "search", - "font_class": "search", - "unicode": "e654", - "unicode_decimal": 58964 - }, - { - "icon_id": "24855824", - "name": "redo-filled", - "font_class": "redo-filled", - "unicode": "e655", - "unicode_decimal": 58965 - }, - { - "icon_id": "24841702", - "name": "list", - "font_class": "list", - "unicode": "e644", - "unicode_decimal": 58948 - }, - { - "icon_id": "24841489", - "name": "mail-open-filled", - "font_class": "mail-open-filled", - "unicode": "e63a", - "unicode_decimal": 58938 - }, - { - "icon_id": "24841491", - "name": "hand-thumbsdown-filled", - "font_class": "hand-down-filled", - "unicode": "e63c", - "unicode_decimal": 58940 - }, - { - "icon_id": "24841492", - "name": "hand-thumbsdown", - "font_class": "hand-down", - "unicode": "e63d", - "unicode_decimal": 58941 - }, - { - "icon_id": "24841493", - "name": "hand-thumbsup-filled", - "font_class": "hand-up-filled", - "unicode": "e63e", - "unicode_decimal": 58942 - }, - { - "icon_id": "24841494", - "name": "hand-thumbsup", - "font_class": "hand-up", - "unicode": "e63f", - "unicode_decimal": 58943 - }, - { - "icon_id": "24841496", - "name": "heart-filled", - "font_class": "heart-filled", - "unicode": "e641", - "unicode_decimal": 58945 - }, - { - "icon_id": "24841498", - "name": "mail-open", - "font_class": "mail-open", - "unicode": "e643", - "unicode_decimal": 58947 - }, - { - "icon_id": "24841488", - "name": "heart", - "font_class": "heart", - "unicode": "e639", - "unicode_decimal": 58937 - }, - { - "icon_id": "24839963", - "name": "loop", - "font_class": "loop", - "unicode": "e633", - "unicode_decimal": 58931 - }, - { - "icon_id": "24839866", - "name": "pulldown", - "font_class": "pulldown", - "unicode": "e632", - "unicode_decimal": 58930 - }, - { - "icon_id": "24813798", - "name": "scan", - "font_class": "scan", - "unicode": "e62a", - "unicode_decimal": 58922 - }, - { - "icon_id": "24813786", - "name": "bars", - "font_class": "bars", - "unicode": "e627", - "unicode_decimal": 58919 - }, - { - "icon_id": "24813788", - "name": "cart-filled", - "font_class": "cart-filled", - "unicode": "e629", - "unicode_decimal": 58921 - }, - { - "icon_id": "24813790", - "name": "checkbox", - "font_class": "checkbox", - "unicode": "e62b", - "unicode_decimal": 58923 - }, - { - "icon_id": "24813791", - "name": "checkbox-filled", - "font_class": "checkbox-filled", - "unicode": "e62c", - "unicode_decimal": 58924 - }, - { - "icon_id": "24813794", - "name": "shop", - "font_class": "shop", - "unicode": "e62f", - "unicode_decimal": 58927 - }, - { - "icon_id": "24813795", - "name": "headphones", - "font_class": "headphones", - "unicode": "e630", - "unicode_decimal": 58928 - }, - { - "icon_id": "24813796", - "name": "cart", - "font_class": "cart", - "unicode": "e631", - "unicode_decimal": 58929 - } - ] -} diff --git a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uni-icons.vue b/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uni-icons.vue deleted file mode 100644 index 86e74445..00000000 --- a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uni-icons.vue +++ /dev/null @@ -1,96 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uniicons.css b/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uniicons.css deleted file mode 100644 index 2f56eabd..00000000 --- a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uniicons.css +++ /dev/null @@ -1,663 +0,0 @@ -.uniui-color:before { - content: "\e6cf"; -} - -.uniui-wallet:before { - content: "\e6b1"; -} - -.uniui-settings-filled:before { - content: "\e6ce"; -} - -.uniui-auth-filled:before { - content: "\e6cc"; -} - -.uniui-shop-filled:before { - content: "\e6cd"; -} - -.uniui-staff-filled:before { - content: "\e6cb"; -} - -.uniui-vip-filled:before { - content: "\e6c6"; -} - -.uniui-plus-filled:before { - content: "\e6c7"; -} - -.uniui-folder-add-filled:before { - content: "\e6c8"; -} - -.uniui-color-filled:before { - content: "\e6c9"; -} - -.uniui-tune-filled:before { - content: "\e6ca"; -} - -.uniui-calendar-filled:before { - content: "\e6c0"; -} - -.uniui-notification-filled:before { - content: "\e6c1"; -} - -.uniui-wallet-filled:before { - content: "\e6c2"; -} - -.uniui-medal-filled:before { - content: "\e6c3"; -} - -.uniui-gift-filled:before { - content: "\e6c4"; -} - -.uniui-fire-filled:before { - content: "\e6c5"; -} - -.uniui-refreshempty:before { - content: "\e6bf"; -} - -.uniui-location-filled:before { - content: "\e6af"; -} - -.uniui-person-filled:before { - content: "\e69d"; -} - -.uniui-personadd-filled:before { - content: "\e698"; -} - -.uniui-back:before { - content: "\e6b9"; -} - -.uniui-forward:before { - content: "\e6ba"; -} - -.uniui-arrow-right:before { - content: "\e6bb"; -} - -.uniui-arrowthinright:before { - content: "\e6bb"; -} - -.uniui-arrow-left:before { - content: "\e6bc"; -} - -.uniui-arrowthinleft:before { - content: "\e6bc"; -} - -.uniui-arrow-up:before { - content: "\e6bd"; -} - -.uniui-arrowthinup:before { - content: "\e6bd"; -} - -.uniui-arrow-down:before { - content: "\e6be"; -} - -.uniui-arrowthindown:before { - content: "\e6be"; -} - -.uniui-bottom:before { - content: "\e6b8"; -} - -.uniui-arrowdown:before { - content: "\e6b8"; -} - -.uniui-right:before { - content: "\e6b5"; -} - -.uniui-arrowright:before { - content: "\e6b5"; -} - -.uniui-top:before { - content: "\e6b6"; -} - -.uniui-arrowup:before { - content: "\e6b6"; -} - -.uniui-left:before { - content: "\e6b7"; -} - -.uniui-arrowleft:before { - content: "\e6b7"; -} - -.uniui-eye:before { - content: "\e651"; -} - -.uniui-eye-filled:before { - content: "\e66a"; -} - -.uniui-eye-slash:before { - content: "\e6b3"; -} - -.uniui-eye-slash-filled:before { - content: "\e6b4"; -} - -.uniui-info-filled:before { - content: "\e649"; -} - -.uniui-reload:before { - content: "\e6b2"; -} - -.uniui-micoff-filled:before { - content: "\e6b0"; -} - -.uniui-map-pin-ellipse:before { - content: "\e6ac"; -} - -.uniui-map-pin:before { - content: "\e6ad"; -} - -.uniui-location:before { - content: "\e6ae"; -} - -.uniui-starhalf:before { - content: "\e683"; -} - -.uniui-star:before { - content: "\e688"; -} - -.uniui-star-filled:before { - content: "\e68f"; -} - -.uniui-calendar:before { - content: "\e6a0"; -} - -.uniui-fire:before { - content: "\e6a1"; -} - -.uniui-medal:before { - content: "\e6a2"; -} - -.uniui-font:before { - content: "\e6a3"; -} - -.uniui-gift:before { - content: "\e6a4"; -} - -.uniui-link:before { - content: "\e6a5"; -} - -.uniui-notification:before { - content: "\e6a6"; -} - -.uniui-staff:before { - content: "\e6a7"; -} - -.uniui-vip:before { - content: "\e6a8"; -} - -.uniui-folder-add:before { - content: "\e6a9"; -} - -.uniui-tune:before { - content: "\e6aa"; -} - -.uniui-auth:before { - content: "\e6ab"; -} - -.uniui-person:before { - content: "\e699"; -} - -.uniui-email-filled:before { - content: "\e69a"; -} - -.uniui-phone-filled:before { - content: "\e69b"; -} - -.uniui-phone:before { - content: "\e69c"; -} - -.uniui-email:before { - content: "\e69e"; -} - -.uniui-personadd:before { - content: "\e69f"; -} - -.uniui-chatboxes-filled:before { - content: "\e692"; -} - -.uniui-contact:before { - content: "\e693"; -} - -.uniui-chatbubble-filled:before { - content: "\e694"; -} - -.uniui-contact-filled:before { - content: "\e695"; -} - -.uniui-chatboxes:before { - content: "\e696"; -} - -.uniui-chatbubble:before { - content: "\e697"; -} - -.uniui-upload-filled:before { - content: "\e68e"; -} - -.uniui-upload:before { - content: "\e690"; -} - -.uniui-weixin:before { - content: "\e691"; -} - -.uniui-compose:before { - content: "\e67f"; -} - -.uniui-qq:before { - content: "\e680"; -} - -.uniui-download-filled:before { - content: "\e681"; -} - -.uniui-pyq:before { - content: "\e682"; -} - -.uniui-sound:before { - content: "\e684"; -} - -.uniui-trash-filled:before { - content: "\e685"; -} - -.uniui-sound-filled:before { - content: "\e686"; -} - -.uniui-trash:before { - content: "\e687"; -} - -.uniui-videocam-filled:before { - content: "\e689"; -} - -.uniui-spinner-cycle:before { - content: "\e68a"; -} - -.uniui-weibo:before { - content: "\e68b"; -} - -.uniui-videocam:before { - content: "\e68c"; -} - -.uniui-download:before { - content: "\e68d"; -} - -.uniui-help:before { - content: "\e679"; -} - -.uniui-navigate-filled:before { - content: "\e67a"; -} - -.uniui-plusempty:before { - content: "\e67b"; -} - -.uniui-smallcircle:before { - content: "\e67c"; -} - -.uniui-minus-filled:before { - content: "\e67d"; -} - -.uniui-micoff:before { - content: "\e67e"; -} - -.uniui-closeempty:before { - content: "\e66c"; -} - -.uniui-clear:before { - content: "\e66d"; -} - -.uniui-navigate:before { - content: "\e66e"; -} - -.uniui-minus:before { - content: "\e66f"; -} - -.uniui-image:before { - content: "\e670"; -} - -.uniui-mic:before { - content: "\e671"; -} - -.uniui-paperplane:before { - content: "\e672"; -} - -.uniui-close:before { - content: "\e673"; -} - -.uniui-help-filled:before { - content: "\e674"; -} - -.uniui-paperplane-filled:before { - content: "\e675"; -} - -.uniui-plus:before { - content: "\e676"; -} - -.uniui-mic-filled:before { - content: "\e677"; -} - -.uniui-image-filled:before { - content: "\e678"; -} - -.uniui-locked-filled:before { - content: "\e668"; -} - -.uniui-info:before { - content: "\e669"; -} - -.uniui-locked:before { - content: "\e66b"; -} - -.uniui-camera-filled:before { - content: "\e658"; -} - -.uniui-chat-filled:before { - content: "\e659"; -} - -.uniui-camera:before { - content: "\e65a"; -} - -.uniui-circle:before { - content: "\e65b"; -} - -.uniui-checkmarkempty:before { - content: "\e65c"; -} - -.uniui-chat:before { - content: "\e65d"; -} - -.uniui-circle-filled:before { - content: "\e65e"; -} - -.uniui-flag:before { - content: "\e65f"; -} - -.uniui-flag-filled:before { - content: "\e660"; -} - -.uniui-gear-filled:before { - content: "\e661"; -} - -.uniui-home:before { - content: "\e662"; -} - -.uniui-home-filled:before { - content: "\e663"; -} - -.uniui-gear:before { - content: "\e664"; -} - -.uniui-smallcircle-filled:before { - content: "\e665"; -} - -.uniui-map-filled:before { - content: "\e666"; -} - -.uniui-map:before { - content: "\e667"; -} - -.uniui-refresh-filled:before { - content: "\e656"; -} - -.uniui-refresh:before { - content: "\e657"; -} - -.uniui-cloud-upload:before { - content: "\e645"; -} - -.uniui-cloud-download-filled:before { - content: "\e646"; -} - -.uniui-cloud-download:before { - content: "\e647"; -} - -.uniui-cloud-upload-filled:before { - content: "\e648"; -} - -.uniui-redo:before { - content: "\e64a"; -} - -.uniui-images-filled:before { - content: "\e64b"; -} - -.uniui-undo-filled:before { - content: "\e64c"; -} - -.uniui-more:before { - content: "\e64d"; -} - -.uniui-more-filled:before { - content: "\e64e"; -} - -.uniui-undo:before { - content: "\e64f"; -} - -.uniui-images:before { - content: "\e650"; -} - -.uniui-paperclip:before { - content: "\e652"; -} - -.uniui-settings:before { - content: "\e653"; -} - -.uniui-search:before { - content: "\e654"; -} - -.uniui-redo-filled:before { - content: "\e655"; -} - -.uniui-list:before { - content: "\e644"; -} - -.uniui-mail-open-filled:before { - content: "\e63a"; -} - -.uniui-hand-down-filled:before { - content: "\e63c"; -} - -.uniui-hand-down:before { - content: "\e63d"; -} - -.uniui-hand-up-filled:before { - content: "\e63e"; -} - -.uniui-hand-up:before { - content: "\e63f"; -} - -.uniui-heart-filled:before { - content: "\e641"; -} - -.uniui-mail-open:before { - content: "\e643"; -} - -.uniui-heart:before { - content: "\e639"; -} - -.uniui-loop:before { - content: "\e633"; -} - -.uniui-pulldown:before { - content: "\e632"; -} - -.uniui-scan:before { - content: "\e62a"; -} - -.uniui-bars:before { - content: "\e627"; -} - -.uniui-cart-filled:before { - content: "\e629"; -} - -.uniui-checkbox:before { - content: "\e62b"; -} - -.uniui-checkbox-filled:before { - content: "\e62c"; -} - -.uniui-shop:before { - content: "\e62f"; -} - -.uniui-headphones:before { - content: "\e630"; -} - -.uniui-cart:before { - content: "\e631"; -} diff --git a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uniicons.ttf b/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uniicons.ttf deleted file mode 100644 index 835f33bc..00000000 Binary files a/blog-uniapp/uni_modules/uni-icons/components/uni-icons/uniicons.ttf and /dev/null differ diff --git a/blog-uniapp/uni_modules/uni-icons/package.json b/blog-uniapp/uni_modules/uni-icons/package.json deleted file mode 100644 index d1c4e77d..00000000 --- a/blog-uniapp/uni_modules/uni-icons/package.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "id": "uni-icons", - "displayName": "uni-icons 图标", - "version": "1.3.5", - "description": "图标组件,用于展示移动端常见的图标,可自定义颜色、大小。", - "keywords": [ - "uni-ui", - "uniui", - "icon", - "图标" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "^3.2.14" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-icons/readme.md b/blog-uniapp/uni_modules/uni-icons/readme.md deleted file mode 100644 index 86234ba1..00000000 --- a/blog-uniapp/uni_modules/uni-icons/readme.md +++ /dev/null @@ -1,8 +0,0 @@ -## Icons 图标 -> **组件名:uni-icons** -> 代码块: `uIcons` - -用于展示 icons 图标 。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-icons) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 diff --git a/blog-uniapp/uni_modules/uni-indexed-list/changelog.md b/blog-uniapp/uni_modules/uni-indexed-list/changelog.md deleted file mode 100644 index 08fa71cb..00000000 --- a/blog-uniapp/uni_modules/uni-indexed-list/changelog.md +++ /dev/null @@ -1,17 +0,0 @@ -## 1.2.1(2021-11-22) -- 修复 vue3中某些scss变量无法找到的问题 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-indexed-list](https://uniapp.dcloud.io/component/uniui/uni-indexed-list) -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.11(2021-05-12) -- 新增 组件示例地址 -## 1.0.10(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 1.0.9(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.8(2021-02-05) -- 调整为uni_modules目录规范 -- 新增 支持 PC 端 diff --git a/blog-uniapp/uni_modules/uni-indexed-list/components/uni-indexed-list/uni-indexed-list-item.vue b/blog-uniapp/uni_modules/uni-indexed-list/components/uni-indexed-list/uni-indexed-list-item.vue deleted file mode 100644 index 2f13baec..00000000 --- a/blog-uniapp/uni_modules/uni-indexed-list/components/uni-indexed-list/uni-indexed-list-item.vue +++ /dev/null @@ -1,144 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-indexed-list/components/uni-indexed-list/uni-indexed-list.vue b/blog-uniapp/uni_modules/uni-indexed-list/components/uni-indexed-list/uni-indexed-list.vue deleted file mode 100644 index 35e168c2..00000000 --- a/blog-uniapp/uni_modules/uni-indexed-list/components/uni-indexed-list/uni-indexed-list.vue +++ /dev/null @@ -1,367 +0,0 @@ - - - diff --git a/blog-uniapp/uni_modules/uni-indexed-list/package.json b/blog-uniapp/uni_modules/uni-indexed-list/package.json deleted file mode 100644 index 125c0e7f..00000000 --- a/blog-uniapp/uni_modules/uni-indexed-list/package.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "id": "uni-indexed-list", - "displayName": "uni-indexed-list 索引列表", - "version": "1.2.1", - "description": "索引列表组件,右侧带索引的列表,方便快速定位到具体内容,通常用于城市/机场选择等场景", - "keywords": [ - "uni-ui", - "索引列表", - "索引", - "列表" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-indexed-list/readme.md b/blog-uniapp/uni_modules/uni-indexed-list/readme.md deleted file mode 100644 index 44ad84b2..00000000 --- a/blog-uniapp/uni_modules/uni-indexed-list/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -## IndexedList 索引列表 -> **组件名:uni-indexed-list** -> 代码块: `uIndexedList` - - -用于展示索引列表。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-indexed-list) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 diff --git a/blog-uniapp/uni_modules/uni-link/changelog.md b/blog-uniapp/uni_modules/uni-link/changelog.md deleted file mode 100644 index 2cfbf591..00000000 --- a/blog-uniapp/uni_modules/uni-link/changelog.md +++ /dev/null @@ -1,17 +0,0 @@ -## 1.0.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-link](https://uniapp.dcloud.io/component/uniui/uni-link) -## 1.1.7(2021-11-08) -## 0.0.7(2021-09-03) -- 修复 在 nvue 下不显示的 bug -## 0.0.6(2021-07-30) -- 新增 支持自定义插槽 -## 0.0.5(2021-06-21) -- 新增 download 属性,H5平台下载文件名 -## 0.0.4(2021-05-12) -- 新增 组件示例地址 -## 0.0.3(2021-03-09) -- 新增 href 属性支持 tel:|mailto: - -## 0.0.2(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-link/components/uni-link/uni-link.vue b/blog-uniapp/uni_modules/uni-link/components/uni-link/uni-link.vue deleted file mode 100644 index 27c5468e..00000000 --- a/blog-uniapp/uni_modules/uni-link/components/uni-link/uni-link.vue +++ /dev/null @@ -1,128 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-link/package.json b/blog-uniapp/uni_modules/uni-link/package.json deleted file mode 100644 index 77b19865..00000000 --- a/blog-uniapp/uni_modules/uni-link/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-link", - "displayName": "uni-link 超链接", - "version": "1.0.0", - "description": "uni-link是一个外部网页超链接组件,在小程序内复制url,在app内打开外部浏览器,在h5端打", - "keywords": [ - "uni-ui", - "uniui", - "link", - "超链接", - "" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "y", - "联盟": "y" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-link/readme.md b/blog-uniapp/uni_modules/uni-link/readme.md deleted file mode 100644 index 7f09e941..00000000 --- a/blog-uniapp/uni_modules/uni-link/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -## Link 链接 -> **组件名:uni-link** -> 代码块: `uLink` - - -uni-link是一个外部网页超链接组件,在小程序内复制url,在app内打开外部浏览器,在h5端打开新网页。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-link) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-list/changelog.md b/blog-uniapp/uni_modules/uni-list/changelog.md deleted file mode 100644 index 6aa6e4e0..00000000 --- a/blog-uniapp/uni_modules/uni-list/changelog.md +++ /dev/null @@ -1,20 +0,0 @@ -## 1.2.1(2022-03-30) -- 删除无用文件 -## 1.2.0(2021-11-23) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-list](https://uniapp.dcloud.io/component/uniui/uni-list) -## 1.1.3(2021-08-30) -- 修复 在vue3中to属性在发行应用的时候报错的bug -## 1.1.2(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.1.1(2021-07-21) -- 修复 与其他组件嵌套使用时,点击失效的Bug -## 1.1.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.17(2021-05-12) -- 新增 组件示例地址 -## 1.0.16(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 -## 1.0.15(2021-02-05) -- 调整为uni_modules目录规范 -- 修复 uni-list-chat 角标显示不正常的问题 diff --git a/blog-uniapp/uni_modules/uni-list/components/uni-list-ad/uni-list-ad.vue b/blog-uniapp/uni_modules/uni-list/components/uni-list-ad/uni-list-ad.vue deleted file mode 100644 index b9349c29..00000000 --- a/blog-uniapp/uni_modules/uni-list/components/uni-list-ad/uni-list-ad.vue +++ /dev/null @@ -1,107 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-list/components/uni-list-chat/uni-list-chat.scss b/blog-uniapp/uni_modules/uni-list/components/uni-list-chat/uni-list-chat.scss deleted file mode 100644 index 311f8d9f..00000000 --- a/blog-uniapp/uni_modules/uni-list/components/uni-list-chat/uni-list-chat.scss +++ /dev/null @@ -1,58 +0,0 @@ -/** - * 这里是 uni-list 组件内置的常用样式变量 - * 如果需要覆盖样式,这里提供了基本的组件样式变量,您可以尝试修改这里的变量,去完成样式替换,而不用去修改源码 - * - */ - -// 背景色 -$background-color : #fff; -// 分割线颜色 -$divide-line-color : #e5e5e5; - -// 默认头像大小,如需要修改此值,注意同步修改 js 中的值 const avatarWidth = xx ,目前只支持方形头像 -// nvue 页面不支持修改头像大小 -$avatar-width : 45px ; - -// 头像边框 -$avatar-border-radius: 5px; -$avatar-border-color: #eee; -$avatar-border-width: 1px; - -// 标题文字样式 -$title-size : 16px; -$title-color : #3b4144; -$title-weight : normal; - -// 描述文字样式 -$note-size : 12px; -$note-color : #999; -$note-weight : normal; - -// 右侧额外内容默认样式 -$right-text-size : 12px; -$right-text-color : #999; -$right-text-weight : normal; - -// 角标样式 -// nvue 页面不支持修改圆点位置以及大小 -// 角标在左侧时,角标的位置,默认为 0 ,负数左/下移动,正数右/上移动 -$badge-left: 0px; -$badge-top: 0px; - -// 显示圆点时,圆点大小 -$dot-width: 10px; -$dot-height: 10px; - -// 显示角标时,角标大小和字体大小 -$badge-size : 18px; -$badge-font : 12px; -// 显示角标时,角标前景色 -$badge-color : #fff; -// 显示角标时,角标背景色 -$badge-background-color : #ff5a5f; -// 显示角标时,角标左右间距 -$badge-space : 6px; - -// 状态样式 -// 选中颜色 -$hover : #f5f5f5; diff --git a/blog-uniapp/uni_modules/uni-list/components/uni-list-chat/uni-list-chat.vue b/blog-uniapp/uni_modules/uni-list/components/uni-list-chat/uni-list-chat.vue deleted file mode 100644 index 2b310085..00000000 --- a/blog-uniapp/uni_modules/uni-list/components/uni-list-chat/uni-list-chat.vue +++ /dev/null @@ -1,538 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-list/components/uni-list-item/uni-list-item.vue b/blog-uniapp/uni_modules/uni-list/components/uni-list-item/uni-list-item.vue deleted file mode 100644 index 2c7d9ea7..00000000 --- a/blog-uniapp/uni_modules/uni-list/components/uni-list-item/uni-list-item.vue +++ /dev/null @@ -1,454 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-list.vue b/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-list.vue deleted file mode 100644 index ecda6765..00000000 --- a/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-list.vue +++ /dev/null @@ -1,108 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-refresh.vue b/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-refresh.vue deleted file mode 100644 index 3b4c5a23..00000000 --- a/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-refresh.vue +++ /dev/null @@ -1,65 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-refresh.wxs b/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-refresh.wxs deleted file mode 100644 index 818a6b72..00000000 --- a/blog-uniapp/uni_modules/uni-list/components/uni-list/uni-refresh.wxs +++ /dev/null @@ -1,87 +0,0 @@ -var pullDown = { - threshold: 95, - maxHeight: 200, - callRefresh: 'onrefresh', - callPullingDown: 'onpullingdown', - refreshSelector: '.uni-refresh' -}; - -function ready(newValue, oldValue, ownerInstance, instance) { - var state = instance.getState() - state.canPullDown = newValue; - // console.log(newValue); -} - -function touchStart(e, instance) { - var state = instance.getState(); - state.refreshInstance = instance.selectComponent(pullDown.refreshSelector); - state.canPullDown = (state.refreshInstance != null && state.refreshInstance != undefined); - if (!state.canPullDown) { - return - } - - // console.log("touchStart"); - - state.height = 0; - state.touchStartY = e.touches[0].pageY || e.changedTouches[0].pageY; - state.refreshInstance.setStyle({ - 'height': 0 - }); - state.refreshInstance.callMethod("onchange", true); -} - -function touchMove(e, ownerInstance) { - var instance = e.instance; - var state = instance.getState(); - if (!state.canPullDown) { - return - } - - var oldHeight = state.height; - var endY = e.touches[0].pageY || e.changedTouches[0].pageY; - var height = endY - state.touchStartY; - if (height > pullDown.maxHeight) { - return; - } - - var refreshInstance = state.refreshInstance; - refreshInstance.setStyle({ - 'height': height + 'px' - }); - - height = height < pullDown.maxHeight ? height : pullDown.maxHeight; - state.height = height; - refreshInstance.callMethod(pullDown.callPullingDown, { - height: height - }); -} - -function touchEnd(e, ownerInstance) { - var state = e.instance.getState(); - if (!state.canPullDown) { - return - } - - state.refreshInstance.callMethod("onchange", false); - - var refreshInstance = state.refreshInstance; - if (state.height > pullDown.threshold) { - refreshInstance.callMethod(pullDown.callRefresh); - return; - } - - refreshInstance.setStyle({ - 'height': 0 - }); -} - -function propObserver(newValue, oldValue, instance) { - pullDown = newValue; -} - -module.exports = { - touchmove: touchMove, - touchstart: touchStart, - touchend: touchEnd, - propObserver: propObserver -} diff --git a/blog-uniapp/uni_modules/uni-list/package.json b/blog-uniapp/uni_modules/uni-list/package.json deleted file mode 100644 index 66e8bef0..00000000 --- a/blog-uniapp/uni_modules/uni-list/package.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "id": "uni-list", - "displayName": "uni-list 列表", - "version": "1.2.1", - "description": "List 组件 ,帮助使用者快速构建列表。", - "keywords": [ - "", - "uni-ui", - "uniui", - "列表", - "", - "list" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-badge", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-list/readme.md b/blog-uniapp/uni_modules/uni-list/readme.md deleted file mode 100644 index 32c28654..00000000 --- a/blog-uniapp/uni_modules/uni-list/readme.md +++ /dev/null @@ -1,346 +0,0 @@ -## List 列表 -> **组件名:uni-list** -> 代码块: `uList`、`uListItem` -> 关联组件:`uni-list-item`、`uni-badge`、`uni-icons`、`uni-list-chat`、`uni-list-ad` - - -List 列表组件,包含基本列表样式、可扩展插槽机制、长列表性能优化、多端兼容。 - -在vue页面里,它默认使用页面级滚动。在app-nvue页面里,它默认使用原生list组件滚动。这样的长列表,在滚动出屏幕外后,系统会回收不可见区域的渲染内存资源,不会造成滚动越长手机越卡的问题。 - -uni-list组件是父容器,里面的核心是uni-list-item子组件,它代表列表中的一个可重复行,子组件可以无限循环。 - -uni-list-item有很多风格,uni-list-item组件通过内置的属性,满足一些常用的场景。当内置属性不满足需求时,可以通过扩展插槽来自定义列表内容。 - -内置属性可以覆盖的场景包括:导航列表、设置列表、小图标列表、通信录列表、聊天记录列表。 - -涉及很多大图或丰富内容的列表,比如类今日头条的新闻列表、类淘宝的电商列表,需要通过扩展插槽实现。 - -下文均有样例给出。 - -uni-list不包含下拉刷新和上拉翻页。上拉翻页另见组件:[uni-load-more](https://ext.dcloud.net.cn/plugin?id=29) - - -### 安装方式 - -本组件符合[easycom](https://uniapp.dcloud.io/collocation/pages?id=easycom)规范,`HBuilderX 2.5.5`起,只需将本组件导入项目,在页面`template`中即可直接使用,无需在页面中`import`和注册`components`。 - -如需通过`npm`方式使用`uni-ui`组件,另见文档:[https://ext.dcloud.net.cn/plugin?id=55](https://ext.dcloud.net.cn/plugin?id=55) - -> **注意事项** -> 为了避免错误使用,给大家带来不好的开发体验,请在使用组件前仔细阅读下面的注意事项,可以帮你避免一些错误。 -> - 组件需要依赖 `sass` 插件 ,请自行手动安装 -> - 组件内部依赖 `'uni-icons'` 、`uni-badge` 组件 -> - `uni-list` 和 `uni-list-item` 需要配套使用,暂不支持单独使用 `uni-list-item` -> - 只有开启点击反馈后,会有点击选中效果 -> - 使用插槽时,可以完全自定义内容 -> - note 、rightText 属性暂时没做限制,不支持文字溢出隐藏,使用时应该控制长度显示或通过默认插槽自行扩展 -> - 支付宝小程序平台需要在支付宝小程序开发者工具里开启 component2 编译模式,开启方式: 详情 --> 项目配置 --> 启用 component2 编译 -> - 如果需要修改 `switch`、`badge` 样式,请使用插槽自定义 -> - 在 `HBuilderX` 低版本中,可能会出现组件显示 `undefined` 的问题,请升级最新的 `HBuilderX` 或者 `cli` -> - 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - -### 基本用法 - -- 设置 `title` 属性,可以显示列表标题 -- 设置 `disabled` 属性,可以禁用当前项 - -```html - - - - - -``` - -### 多行内容显示 - -- 设置 `note` 属性 ,可以在第二行显示描述文本信息 - -```html - - - - - -``` - -### 右侧显示角标、switch - -- 设置 `show-badge` 属性 ,可以显示角标内容 -- 设置 `show-switch` 属性,可以显示 switch 开关 - -```html - - - - - -``` - -### 左侧显示略缩图、图标 - -- 设置 `thumb` 属性 ,可以在列表左侧显示略缩图 -- 设置 `show-extra-icon` 属性,并指定 `extra-icon` 可以在左侧显示图标 - -```html - - - - -``` - -### 开启点击反馈和右侧箭头 -- 设置 `clickable` 为 `true` ,则表示这是一个可点击的列表,会默认给一个点击效果,并可以监听 `click` 事件 -- 设置 `link` 属性,会自动开启点击反馈,并给列表右侧添加一个箭头 -- 设置 `to` 属性,可以跳转页面,`link` 的值表示跳转方式,如果不指定,默认为 `navigateTo` - -```html - - - - - - - -``` - - -### 聊天列表示例 -- 设置 `clickable` 为 `true` ,则表示这是一个可点击的列表,会默认给一个点击效果,并可以监听 `click` 事件 -- 设置 `link` 属性,会自动开启点击反馈,`link` 的值表示跳转方式,如果不指定,默认为 `navigateTo` -- 设置 `to` 属性,可以跳转页面 -- `time` 属性,通常会设置成时间显示,但是这个属性不仅仅可以设置时间,你可以传入任何文本,注意文本长度可能会影响显示 -- `avatar` 和 `avatarList` 属性同时只会有一个生效,同时设置的话,`avatarList` 属性的长度大于1 ,`avatar` 属性将失效 -- 可以通过默认插槽自定义列表右侧内容 - -```html - - - - - - - - - - - - - - - - - 刚刚 - - - - - - - -``` - -```javascript - -export default { - components: {}, - data() { - return { - avatarList: [{ - url: 'https://vkceyugu.cdn.bspapp.com/VKCEYUGU-dc-site/460d46d0-4fcc-11eb-8ff1-d5dcf8779628.png' - }, { - url: 'https://vkceyugu.cdn.bspapp.com/VKCEYUGU-dc-site/460d46d0-4fcc-11eb-8ff1-d5dcf8779628.png' - }, { - url: 'https://vkceyugu.cdn.bspapp.com/VKCEYUGU-dc-site/460d46d0-4fcc-11eb-8ff1-d5dcf8779628.png' - }] - } - } -} - -``` - - -```css - -.chat-custom-right { - flex: 1; - /* #ifndef APP-NVUE */ - display: flex; - /* #endif */ - flex-direction: column; - justify-content: space-between; - align-items: flex-end; -} - -.chat-custom-text { - font-size: 12px; - color: #999; -} - -``` - -## API - -### List Props - -属性名 |类型 |默认值 | 说明 -:-: |:-: |:-: | :-: -border |Boolean |true | 是否显示边框 - - -### ListItem Props - -属性名 |类型 |默认值 | 说明 -:-: |:-: |:-: | :-: -title |String |- | 标题 -note |String |- | 描述 -ellipsis |Number |0 | title 是否溢出隐藏,可选值,0:默认; 1:显示一行; 2:显示两行;【nvue 暂不支持】 -thumb |String |- | 左侧缩略图,若thumb有值,则不会显示扩展图标 -thumbSize |String |medium | 略缩图尺寸,可选值,lg:大图; medium:一般; sm:小图; -showBadge |Boolean |false | 是否显示数字角标 -badgeText |String |- | 数字角标内容 -badgeType |String |- | 数字角标类型,参考[uni-icons](https://ext.dcloud.net.cn/plugin?id=21) -badgeStyle |Object |- | 数字角标样式,使用uni-badge的custom-style参数 -rightText |String |- | 右侧文字内容 -disabled |Boolean |false | 是否禁用 -showArrow |Boolean |true | 是否显示箭头图标 -link |String |navigateTo | 新页面跳转方式,可选值见下表 -to |String |- | 新页面跳转地址,如填写此属性,click 会返回页面是否跳转成功 -clickable |Boolean |false | 是否开启点击反馈 -showSwitch |Boolean |false | 是否显示Switch -switchChecked |Boolean |false | Switch是否被选中 -showExtraIcon |Boolean |false | 左侧是否显示扩展图标 -extraIcon |Object |- | 扩展图标参数,格式为 ``{color: '#4cd964',size: '22',type: 'spinner'}``,参考 [uni-icons](https://ext.dcloud.net.cn/plugin?id=28) -direction | String |row | 排版方向,可选值,row:水平排列; column:垂直排列; 3个插槽是水平排还是垂直排,也受此属性控制 - - -#### Link Options - -属性名 | 说明 -:-: | :-: -navigateTo | 同 uni.navigateTo() -redirectTo | 同 uni.reLaunch() -reLaunch | 同 uni.reLaunch() -switchTab | 同 uni.switchTab() - -### ListItem Events - -事件称名 |说明 |返回参数 -:-: |:-: |:-: -click |点击 uniListItem 触发事件,需开启点击反馈 |- -switchChange |点击切换 Switch 时触发,需显示 switch |e={value:checked} - - - -### ListItem Slots - -名称 | 说明 -:-: | :-: -header | 左/上内容插槽,可完全自定义默认显示 -body | 中间内容插槽,可完全自定义中间内容 -footer | 右/下内容插槽,可完全自定义右侧内容 - - -> **通过插槽扩展** -> 需要注意的是当使用插槽时,内置样式将会失效,只保留排版样式,此时的样式需要开发者自己实现 -> 如果 `uni-list-item` 组件内置属性样式无法满足需求,可以使用插槽来自定义uni-list-item里的内容。 -> uni-list-item提供了3个可扩展的插槽:`header`、`body`、`footer` -> - 当 `direction` 属性为 `row` 时表示水平排列,此时 `header` 表示列表的左边部分,`body` 表示列表的中间部分,`footer` 表示列表的右边部分 -> - 当 `direction` 属性为 `column` 时表示垂直排列,此时 `header` 表示列表的上边部分,`body` 表示列表的中间部分,`footer` 表示列表的下边部分 -> 开发者可以只用1个插槽,也可以3个一起使用。在插槽中可自主编写view标签,实现自己所需的效果。 - - -**示例** - -```html - - - - - - - - - 自定义插槽 - - - - -``` - - - - - -### ListItemChat Props - -属性名 |类型 |默认值 | 说明 -:-: |:-: |:-: | :-: -title |String |- | 标题 -note |String |- | 描述 -clickable |Boolean |false | 是否开启点击反馈 -badgeText |String |- | 数字角标内容,设置为 `dot` 将显示圆点 -badgePositon |String |right | 角标位置 -link |String |navigateTo | 是否展示右侧箭头并开启点击反馈,可选值见下表 -clickable |Boolean |false | 是否开启点击反馈 -to |String |- | 跳转页面地址,如填写此属性,click 会返回页面是否跳转成功 -time |String |- | 右侧时间显示 -avatarCircle |Boolean |false | 是否显示圆形头像 -avatar |String |- | 头像地址,avatarCircle 不填时生效 -avatarList |Array |- | 头像组,格式为 [{url:''}] - -#### Link Options - -属性名 | 说明 -:-: | :-: -navigateTo | 同 uni.navigateTo() -redirectTo | 同 uni.reLaunch() -reLaunch | 同 uni.reLaunch() -switchTab | 同 uni.switchTab() - -### ListItemChat Slots - -名称 | 说明 -:- | :- -default | 自定义列表右侧内容(包括时间和角标显示) - -### ListItemChat Events -事件称名 | 说明 | 返回参数 -:-: | :-: | :-: -@click | 点击 uniListChat 触发事件 | {data:{}} ,如有 to 属性,会返回页面跳转信息 - - - - - - -## 基于uni-list扩展的页面模板 - -通过扩展插槽,可实现多种常见样式的列表 - -**新闻列表类** - -1. 云端一体混合布局:[https://ext.dcloud.net.cn/plugin?id=2546](https://ext.dcloud.net.cn/plugin?id=2546) -2. 云端一体垂直布局,大图模式:[https://ext.dcloud.net.cn/plugin?id=2583](https://ext.dcloud.net.cn/plugin?id=2583) -3. 云端一体垂直布局,多行图文混排:[https://ext.dcloud.net.cn/plugin?id=2584](https://ext.dcloud.net.cn/plugin?id=2584) -4. 云端一体垂直布局,多图模式:[https://ext.dcloud.net.cn/plugin?id=2585](https://ext.dcloud.net.cn/plugin?id=2585) -5. 云端一体水平布局,左图右文:[https://ext.dcloud.net.cn/plugin?id=2586](https://ext.dcloud.net.cn/plugin?id=2586) -6. 云端一体水平布局,左文右图:[https://ext.dcloud.net.cn/plugin?id=2587](https://ext.dcloud.net.cn/plugin?id=2587) -7. 云端一体垂直布局,无图模式,主标题+副标题:[https://ext.dcloud.net.cn/plugin?id=2588](https://ext.dcloud.net.cn/plugin?id=2588) - -**商品列表类** - -1. 云端一体列表/宫格视图互切:[https://ext.dcloud.net.cn/plugin?id=2651](https://ext.dcloud.net.cn/plugin?id=2651) -2. 云端一体列表(宫格模式):[https://ext.dcloud.net.cn/plugin?id=2671](https://ext.dcloud.net.cn/plugin?id=2671) -3. 云端一体列表(列表模式):[https://ext.dcloud.net.cn/plugin?id=2672](https://ext.dcloud.net.cn/plugin?id=2672) - -## 组件示例 - -点击查看:[https://hellouniapp.dcloud.net.cn/pages/extUI/list/list](https://hellouniapp.dcloud.net.cn/pages/extUI/list/list) \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-load-more/changelog.md b/blog-uniapp/uni_modules/uni-load-more/changelog.md deleted file mode 100644 index 8f03f1d5..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/changelog.md +++ /dev/null @@ -1,19 +0,0 @@ -## 1.3.3(2022-01-20) -- 新增 showText属性 ,是否显示文本 -## 1.3.2(2022-01-19) -- 修复 nvue 平台下不显示文本的bug -## 1.3.1(2022-01-19) -- 修复 微信小程序平台样式选择器报警告的问题 -## 1.3.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-load-more](https://uniapp.dcloud.io/component/uniui/uni-load-more) -## 1.2.1(2021-08-24) -- 新增 支持国际化 -## 1.2.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.1.8(2021-05-12) -- 新增 组件示例地址 -## 1.1.7(2021-03-30) -- 修复 uni-load-more 在首页使用时,h5 平台报 'uni is not defined' 的 bug -## 1.1.6(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/en.json b/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/en.json deleted file mode 100644 index a4f14a54..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/en.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "uni-load-more.contentdown": "Pull up to show more", - "uni-load-more.contentrefresh": "loading...", - "uni-load-more.contentnomore": "No more data" -} diff --git a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/index.js b/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/zh-Hans.json deleted file mode 100644 index f15d5105..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/zh-Hans.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "uni-load-more.contentdown": "上拉显示更多", - "uni-load-more.contentrefresh": "正在加载...", - "uni-load-more.contentnomore": "没有更多数据了" -} diff --git a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/zh-Hant.json deleted file mode 100644 index a255c6de..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/i18n/zh-Hant.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "uni-load-more.contentdown": "上拉顯示更多", - "uni-load-more.contentrefresh": "正在加載...", - "uni-load-more.contentnomore": "沒有更多數據了" -} diff --git a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/uni-load-more.vue b/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/uni-load-more.vue deleted file mode 100644 index e5eff4d6..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/components/uni-load-more/uni-load-more.vue +++ /dev/null @@ -1,399 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-load-more/package.json b/blog-uniapp/uni_modules/uni-load-more/package.json deleted file mode 100644 index 2fa6f040..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/package.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "id": "uni-load-more", - "displayName": "uni-load-more 加载更多", - "version": "1.3.3", - "description": "LoadMore 组件,常用在列表里面,做滚动加载使用。", - "keywords": [ - "uni-ui", - "uniui", - "加载更多", - "load-more" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-load-more/readme.md b/blog-uniapp/uni_modules/uni-load-more/readme.md deleted file mode 100644 index 54dc1fad..00000000 --- a/blog-uniapp/uni_modules/uni-load-more/readme.md +++ /dev/null @@ -1,14 +0,0 @@ - - -### LoadMore 加载更多 -> **组件名:uni-load-more** -> 代码块: `uLoadMore` - - -用于列表中,做滚动加载使用,展示 loading 的各种状态。 - - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-load-more) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-nav-bar/changelog.md b/blog-uniapp/uni_modules/uni-nav-bar/changelog.md deleted file mode 100644 index f0f6b566..00000000 --- a/blog-uniapp/uni_modules/uni-nav-bar/changelog.md +++ /dev/null @@ -1,41 +0,0 @@ -## 1.3.6(2022-06-30) -- 修复 组件示例中插槽用法无法显示内容的bug -## 1.3.5(2022-05-24) -- 新增 stat 属性 ,可开启统计title 上报 ,仅使用了title 属性且项目开启了uni统计生效 -## 1.3.4(2022-01-24) -- 更新 组件示例 -## 1.3.3(2022-01-24) -- 新增 left-width/right-width属性 ,可修改左右两侧的宽度 -## 1.3.2(2022-01-18) -- 修复 在vue下,标题不垂直居中的bug -## 1.3.1(2022-01-18) -- 修复 height 属性类型错误 -## 1.3.0(2022-01-18) -- 新增 height 属性,可修改组件高度 -- 新增 dark 属性可可开启暗黑模式 -- 优化 标题字数过多显示省略号 -- 优化 插槽,插入内容可完全覆盖 -## 1.2.1(2022-01-10) -- 修复 color 属性不生效的bug -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-nav-bar](https://uniapp.dcloud.io/component/uniui/uni-nav-bar) -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.11(2021-05-12) -- 新增 组件示例地址 -## 1.0.10(2021-04-30) -- 修复 在nvue下fixed为true,宽度不能撑满的Bug -## 1.0.9(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 1.0.8(2021-04-14) -- uni-ui 修复 uni-nav-bar 当 fixed 属性为 true 时铺不满屏幕的 bug - -## 1.0.7(2021-02-25) -- 修复 easycom 下,找不到 uni-status-bar 的bug - -## 1.0.6(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.5(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-nav-bar/components/uni-nav-bar/uni-nav-bar.vue b/blog-uniapp/uni_modules/uni-nav-bar/components/uni-nav-bar/uni-nav-bar.vue deleted file mode 100644 index cbfc1685..00000000 --- a/blog-uniapp/uni_modules/uni-nav-bar/components/uni-nav-bar/uni-nav-bar.vue +++ /dev/null @@ -1,348 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-nav-bar/components/uni-nav-bar/uni-status-bar.vue b/blog-uniapp/uni_modules/uni-nav-bar/components/uni-nav-bar/uni-status-bar.vue deleted file mode 100644 index 6a688744..00000000 --- a/blog-uniapp/uni_modules/uni-nav-bar/components/uni-nav-bar/uni-status-bar.vue +++ /dev/null @@ -1,27 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-nav-bar/package.json b/blog-uniapp/uni_modules/uni-nav-bar/package.json deleted file mode 100644 index e3fe073d..00000000 --- a/blog-uniapp/uni_modules/uni-nav-bar/package.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "id": "uni-nav-bar", - "displayName": "uni-nav-bar 自定义导航栏", - "version": "1.3.6", - "description": "自定义导航栏组件,主要用于头部导航。", - "keywords": [ - "uni-ui", - "导航", - "导航栏", - "自定义导航栏" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-nav-bar/readme.md b/blog-uniapp/uni_modules/uni-nav-bar/readme.md deleted file mode 100644 index 3934b327..00000000 --- a/blog-uniapp/uni_modules/uni-nav-bar/readme.md +++ /dev/null @@ -1,15 +0,0 @@ - - -## NavBar 导航栏 -> **组件名:uni-nav-bar** -> 代码块: `uNavBar` - -导航栏组件,主要用于头部导航。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-nav-bar) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - - - - diff --git a/blog-uniapp/uni_modules/uni-notice-bar/changelog.md b/blog-uniapp/uni_modules/uni-notice-bar/changelog.md deleted file mode 100644 index 9ee75a01..00000000 --- a/blog-uniapp/uni_modules/uni-notice-bar/changelog.md +++ /dev/null @@ -1,16 +0,0 @@ -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-notice-bar](https://uniapp.dcloud.io/component/uniui/uni-notice-bar) -## 1.1.1(2021-11-09) -- 新增 提供组件设计资源,组件样式调整 -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.9(2021-05-12) -- 新增 组件示例地址 -## 1.0.8(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 1.0.7(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.6(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-notice-bar/components/uni-notice-bar/uni-notice-bar.vue b/blog-uniapp/uni_modules/uni-notice-bar/components/uni-notice-bar/uni-notice-bar.vue deleted file mode 100644 index 1d2ac1dc..00000000 --- a/blog-uniapp/uni_modules/uni-notice-bar/components/uni-notice-bar/uni-notice-bar.vue +++ /dev/null @@ -1,395 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-notice-bar/package.json b/blog-uniapp/uni_modules/uni-notice-bar/package.json deleted file mode 100644 index 97719a0f..00000000 --- a/blog-uniapp/uni_modules/uni-notice-bar/package.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "uni-notice-bar", - "displayName": "uni-notice-bar 通告栏", - "version": "1.2.0", - "description": "NoticeBar 通告栏组件,常用于展示公告信息,可设为滚动公告", - "keywords": [ - "uni-ui", - "uniui", - "通告栏", - "公告", - "跑马灯" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-notice-bar/readme.md b/blog-uniapp/uni_modules/uni-notice-bar/readme.md deleted file mode 100644 index fb2ede24..00000000 --- a/blog-uniapp/uni_modules/uni-notice-bar/readme.md +++ /dev/null @@ -1,13 +0,0 @@ - - -## NoticeBar 通告栏 -> **组件名:uni-notice-bar** -> 代码块: `uNoticeBar` - - -通告栏组件 。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-notice-bar) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-number-box/changelog.md b/blog-uniapp/uni_modules/uni-number-box/changelog.md deleted file mode 100644 index 5925c32a..00000000 --- a/blog-uniapp/uni_modules/uni-number-box/changelog.md +++ /dev/null @@ -1,25 +0,0 @@ -## 1.2.1(2021-11-22) -- 修复 vue3中某些scss变量无法找到的问题 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-number-box](https://uniapp.dcloud.io/component/uniui/uni-number-box) -## 1.1.2(2021-11-09) -- 新增 提供组件设计资源,组件样式调整 -## 1.1.1(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.1.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.7(2021-05-12) -- 新增 组件示例地址 -## 1.0.6(2021-04-20) -- 修复 uni-number-box 浮点数运算不精确的 bug -- 修复 uni-number-box change 事件触发不正确的 bug -- 新增 uni-number-box v-model 双向绑定 -## 1.0.5(2021-02-05) -- 调整为uni_modules目录规范 - -## 1.0.7(2021-02-05) -- 调整为uni_modules目录规范 -- 新增 支持 v-model -- 新增 支持 focus、blur 事件 -- 新增 支持 PC 端 diff --git a/blog-uniapp/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue b/blog-uniapp/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue deleted file mode 100644 index e91c0321..00000000 --- a/blog-uniapp/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.vue +++ /dev/null @@ -1,221 +0,0 @@ - - - diff --git a/blog-uniapp/uni_modules/uni-number-box/package.json b/blog-uniapp/uni_modules/uni-number-box/package.json deleted file mode 100644 index ad823368..00000000 --- a/blog-uniapp/uni_modules/uni-number-box/package.json +++ /dev/null @@ -1,85 +0,0 @@ -{ - "id": "uni-number-box", - "displayName": "uni-number-box 数字输入框", - "version": "1.2.1", - "description": "NumberBox 带加减按钮的数字输入框组件,用户可以控制每次点击增加的数值,支持小数。", - "keywords": [ - "uni-ui", - "uniui", - "数字输入框" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-number-box/readme.md b/blog-uniapp/uni_modules/uni-number-box/readme.md deleted file mode 100644 index affc56fa..00000000 --- a/blog-uniapp/uni_modules/uni-number-box/readme.md +++ /dev/null @@ -1,13 +0,0 @@ - - -## NumberBox 数字输入框 -> **组件名:uni-number-box** -> 代码块: `uNumberBox` - - -带加减按钮的数字输入框。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-number-box) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-pagination/changelog.md b/blog-uniapp/uni_modules/uni-pagination/changelog.md deleted file mode 100644 index 336c2ba6..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/changelog.md +++ /dev/null @@ -1,20 +0,0 @@ -## 1.2.1(2021-11-22) -- 修复 vue3中某些scss变量无法找到的问题 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-pagination](https://uniapp.dcloud.io/component/uniui/uni-pagination) -## 1.1.2(2021-10-08) -- 修复 current 、value 属性未监听,导致高亮样式失效的 bug -## 1.1.1(2021-08-20) -- 新增 支持国际化 -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.7(2021-05-12) -- 新增 组件示例地址 -## 1.0.6(2021-04-12) -- 新增 PC 和 移动端适配不同的 ui -## 1.0.5(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.4(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/en.json b/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/en.json deleted file mode 100644 index a57becdc..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/en.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-pagination.prevText": "prev", - "uni-pagination.nextText": "next" -} diff --git a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/es.json b/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/es.json deleted file mode 100644 index ccbba2f6..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/es.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-pagination.prevText": "anterior", - "uni-pagination.nextText": "próxima" -} diff --git a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/fr.json b/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/fr.json deleted file mode 100644 index 9b5f2d92..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/fr.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-pagination.prevText": "précédente", - "uni-pagination.nextText": "suivante" -} diff --git a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/index.js b/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/index.js deleted file mode 100644 index 2469dd02..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/index.js +++ /dev/null @@ -1,12 +0,0 @@ -import en from './en.json' -import es from './es.json' -import fr from './fr.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - es, - fr, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/zh-Hans.json deleted file mode 100644 index fedbe82a..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/zh-Hans.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-pagination.prevText": "上一页", - "uni-pagination.nextText": "下一页" -} diff --git a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/zh-Hant.json deleted file mode 100644 index 133b3404..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/i18n/zh-Hant.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-pagination.prevText": "上一頁", - "uni-pagination.nextText": "下一頁" -} diff --git a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/uni-pagination.vue b/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/uni-pagination.vue deleted file mode 100644 index 79db4b88..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/components/uni-pagination/uni-pagination.vue +++ /dev/null @@ -1,409 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-pagination/package.json b/blog-uniapp/uni_modules/uni-pagination/package.json deleted file mode 100644 index adce6704..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/package.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "id": "uni-pagination", - "displayName": "uni-pagination 分页器", - "version": "1.2.1", - "description": "Pagination 分页器组件,用于展示页码、请求数据等。", - "keywords": [ - "uni-ui", - "uniui", - "分页器", - "页码" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss","uni-icons"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-pagination/readme.md b/blog-uniapp/uni_modules/uni-pagination/readme.md deleted file mode 100644 index eefa2634..00000000 --- a/blog-uniapp/uni_modules/uni-pagination/readme.md +++ /dev/null @@ -1,13 +0,0 @@ - - -## Pagination 分页器 -> **组件名:uni-pagination** -> 代码块: `uPagination` - - -分页器组件,用于展示页码、请求数据等。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-pagination) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-popup/changelog.md b/blog-uniapp/uni_modules/uni-popup/changelog.md deleted file mode 100644 index a9e2d668..00000000 --- a/blog-uniapp/uni_modules/uni-popup/changelog.md +++ /dev/null @@ -1,60 +0,0 @@ -## 1.7.9(2022-04-02) -- 修复 弹出层内部无法滚动的bug -## 1.7.8(2022-03-28) -- 修复 小程序中高度错误的bug -## 1.7.7(2022-03-17) -- 修复 快速调用open出现问题的Bug -## 1.7.6(2022-02-14) -- 修复 safeArea 属性不能设置为false的bug -## 1.7.5(2022-01-19) -- 修复 isMaskClick 失效的bug -## 1.7.4(2022-01-19) -- 新增 cancelText \ confirmText 属性 ,可自定义文本 -- 新增 maskBackgroundColor 属性 ,可以修改蒙版颜色 -- 优化 maskClick属性 更新为 isMaskClick ,解决微信小程序警告的问题 -## 1.7.3(2022-01-13) -- 修复 设置 safeArea 属性不生效的bug -## 1.7.2(2021-11-26) -- 优化 组件示例 -## 1.7.1(2021-11-26) -- 修复 vuedoc 文字错误 -## 1.7.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-popup](https://uniapp.dcloud.io/component/uniui/uni-popup) -## 1.6.2(2021-08-24) -- 新增 支持国际化 -## 1.6.1(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.6.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.5.0(2021-06-23) -- 新增 mask-click 遮罩层点击事件 -## 1.4.5(2021-06-22) -- 修复 nvue 平台中间弹出后,点击内容,再点击遮罩无法关闭的Bug -## 1.4.4(2021-06-18) -- 修复 H5平台中间弹出后,点击内容,再点击遮罩无法关闭的Bug -## 1.4.3(2021-06-08) -- 修复 错误的 watch 字段 -- 修复 safeArea 属性不生效的问题 -- 修复 点击内容,再点击遮罩无法关闭的Bug -## 1.4.2(2021-05-12) -- 新增 组件示例地址 -## 1.4.1(2021-04-29) -- 修复 组件内放置 input 、textarea 组件,无法聚焦的问题 -## 1.4.0 (2021-04-29) -- 新增 type 属性的 left\right 值,支持左右弹出 -- 新增 open(String:type) 方法参数 ,可以省略 type 属性 ,直接传入类型打开指定弹窗 -- 新增 backgroundColor 属性,可定义主窗口背景色,默认不显示背景色 -- 新增 safeArea 属性,是否适配底部安全区 -- 修复 App\h5\微信小程序底部安全区占位不对的Bug -- 修复 App 端弹出等待的Bug -- 优化 提升低配设备性能,优化动画卡顿问题 -- 优化 更简单的组件自定义方式 -## 1.2.9(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 -## 1.2.8(2021-02-05) -- 调整为uni_modules目录规范 -## 1.2.7(2021-02-05) -- 调整为uni_modules目录规范 -- 新增 支持 PC 端 -- 新增 uni-popup-message 、uni-popup-dialog扩展组件支持 PC 端 diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-dialog/keypress.js b/blog-uniapp/uni_modules/uni-popup/components/uni-popup-dialog/keypress.js deleted file mode 100644 index 6ef26a26..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-dialog/keypress.js +++ /dev/null @@ -1,45 +0,0 @@ -// #ifdef H5 -export default { - name: 'Keypress', - props: { - disable: { - type: Boolean, - default: false - } - }, - mounted () { - const keyNames = { - esc: ['Esc', 'Escape'], - tab: 'Tab', - enter: 'Enter', - space: [' ', 'Spacebar'], - up: ['Up', 'ArrowUp'], - left: ['Left', 'ArrowLeft'], - right: ['Right', 'ArrowRight'], - down: ['Down', 'ArrowDown'], - delete: ['Backspace', 'Delete', 'Del'] - } - const listener = ($event) => { - if (this.disable) { - return - } - const keyName = Object.keys(keyNames).find(key => { - const keyName = $event.key - const value = keyNames[key] - return value === keyName || (Array.isArray(value) && value.includes(keyName)) - }) - if (keyName) { - // 避免和其他按键事件冲突 - setTimeout(() => { - this.$emit(keyName, {}) - }, 0) - } - } - document.addEventListener('keyup', listener) - this.$once('hook:beforeDestroy', () => { - document.removeEventListener('keyup', listener) - }) - }, - render: () => {} -} -// #endif diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-dialog/uni-popup-dialog.vue b/blog-uniapp/uni_modules/uni-popup/components/uni-popup-dialog/uni-popup-dialog.vue deleted file mode 100644 index a5d0f2a2..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-dialog/uni-popup-dialog.vue +++ /dev/null @@ -1,271 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-message/uni-popup-message.vue b/blog-uniapp/uni_modules/uni-popup/components/uni-popup-message/uni-popup-message.vue deleted file mode 100644 index 91370a82..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-message/uni-popup-message.vue +++ /dev/null @@ -1,143 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue b/blog-uniapp/uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue deleted file mode 100644 index 5be76247..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue +++ /dev/null @@ -1,187 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/en.json b/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/en.json deleted file mode 100644 index 7f1bd06a..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/en.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "uni-popup.cancel": "cancel", - "uni-popup.ok": "ok", - "uni-popup.placeholder": "pleace enter", - "uni-popup.title": "Hint", - "uni-popup.shareTitle": "Share to" -} diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/index.js b/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hans.json deleted file mode 100644 index 5e3003ca..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hans.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "uni-popup.cancel": "取消", - "uni-popup.ok": "确定", - "uni-popup.placeholder": "请输入", - "uni-popup.title": "提示", - "uni-popup.shareTitle": "分享到" -} diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hant.json deleted file mode 100644 index 13e39eba..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hant.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "uni-popup.cancel": "取消", - "uni-popup.ok": "確定", - "uni-popup.placeholder": "請輸入", - "uni-popup.title": "提示", - "uni-popup.shareTitle": "分享到" -} diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/keypress.js b/blog-uniapp/uni_modules/uni-popup/components/uni-popup/keypress.js deleted file mode 100644 index 62dda461..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/keypress.js +++ /dev/null @@ -1,45 +0,0 @@ -// #ifdef H5 -export default { - name: 'Keypress', - props: { - disable: { - type: Boolean, - default: false - } - }, - mounted () { - const keyNames = { - esc: ['Esc', 'Escape'], - tab: 'Tab', - enter: 'Enter', - space: [' ', 'Spacebar'], - up: ['Up', 'ArrowUp'], - left: ['Left', 'ArrowLeft'], - right: ['Right', 'ArrowRight'], - down: ['Down', 'ArrowDown'], - delete: ['Backspace', 'Delete', 'Del'] - } - const listener = ($event) => { - if (this.disable) { - return - } - const keyName = Object.keys(keyNames).find(key => { - const keyName = $event.key - const value = keyNames[key] - return value === keyName || (Array.isArray(value) && value.includes(keyName)) - }) - if (keyName) { - // 避免和其他按键事件冲突 - setTimeout(() => { - this.$emit(keyName, {}) - }, 0) - } - } - document.addEventListener('keyup', listener) - // this.$once('hook:beforeDestroy', () => { - // document.removeEventListener('keyup', listener) - // }) - }, - render: () => {} -} -// #endif diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/popup.js b/blog-uniapp/uni_modules/uni-popup/components/uni-popup/popup.js deleted file mode 100644 index c4e5781d..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/popup.js +++ /dev/null @@ -1,26 +0,0 @@ - -export default { - data() { - return { - - } - }, - created(){ - this.popup = this.getParent() - }, - methods:{ - /** - * 获取父元素实例 - */ - getParent(name = 'uniPopup') { - let parent = this.$parent; - let parentName = parent.$options.name; - while (parentName !== name) { - parent = parent.$parent; - if (!parent) return false - parentName = parent.$options.name; - } - return parent; - }, - } -} diff --git a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/uni-popup.vue b/blog-uniapp/uni_modules/uni-popup/components/uni-popup/uni-popup.vue deleted file mode 100644 index db90c599..00000000 --- a/blog-uniapp/uni_modules/uni-popup/components/uni-popup/uni-popup.vue +++ /dev/null @@ -1,474 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-popup/package.json b/blog-uniapp/uni_modules/uni-popup/package.json deleted file mode 100644 index 069e9ce5..00000000 --- a/blog-uniapp/uni_modules/uni-popup/package.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "id": "uni-popup", - "displayName": "uni-popup 弹出层", - "version": "1.7.9", - "description": " Popup 组件,提供常用的弹层", - "keywords": [ - "uni-ui", - "弹出层", - "弹窗", - "popup", - "弹框" - ], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-transition" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-popup/readme.md b/blog-uniapp/uni_modules/uni-popup/readme.md deleted file mode 100644 index fdad4b3d..00000000 --- a/blog-uniapp/uni_modules/uni-popup/readme.md +++ /dev/null @@ -1,17 +0,0 @@ - - -## Popup 弹出层 -> **组件名:uni-popup** -> 代码块: `uPopup` -> 关联组件:`uni-transition` - - -弹出层组件,在应用中弹出一个消息提示窗口、提示框等 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-popup) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - - - - diff --git a/blog-uniapp/uni_modules/uni-rate/changelog.md b/blog-uniapp/uni_modules/uni-rate/changelog.md deleted file mode 100644 index 8a98a612..00000000 --- a/blog-uniapp/uni_modules/uni-rate/changelog.md +++ /dev/null @@ -1,25 +0,0 @@ -## 1.3.1(2022-02-25) -- 修复 条件判断 `NaN` 错误的 bug -## 1.3.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-rate](https://uniapp.dcloud.io/component/uniui/uni-rate) -## 1.2.2(2021-09-10) -- 优化 默认值修改为 0 颗星 -## 1.2.1(2021-07-30) -- 优化 vue3下事件警告的问题 -## 1.2.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.1.2(2021-05-12) -- 新增 组件示例地址 -## 1.1.1(2021-04-21) -- 修复 布局变化后 uni-rate 星星计算不准确的 bug -- 优化 添加依赖 uni-icons, 导入 uni-rate 自动下载依赖 -## 1.1.0(2021-04-16) -- 修复 uni-rate 属性 margin 值为 string 组件失效的 bug - -## 1.0.9(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.8(2021-02-05) -- 调整为uni_modules目录规范 -- 支持 pc 端 diff --git a/blog-uniapp/uni_modules/uni-rate/components/uni-rate/uni-rate.vue b/blog-uniapp/uni_modules/uni-rate/components/uni-rate/uni-rate.vue deleted file mode 100644 index 857f5f9c..00000000 --- a/blog-uniapp/uni_modules/uni-rate/components/uni-rate/uni-rate.vue +++ /dev/null @@ -1,361 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-rate/package.json b/blog-uniapp/uni_modules/uni-rate/package.json deleted file mode 100644 index 64e8e332..00000000 --- a/blog-uniapp/uni_modules/uni-rate/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-rate", - "displayName": "uni-rate 评分", - "version": "1.3.1", - "description": "Rate 评分组件,可自定义评分星星图标的大小、间隔、评分数。", - "keywords": [ - "uni-ui", - "uniui", - "评分" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-rate/readme.md b/blog-uniapp/uni_modules/uni-rate/readme.md deleted file mode 100644 index eae7b5ce..00000000 --- a/blog-uniapp/uni_modules/uni-rate/readme.md +++ /dev/null @@ -1,12 +0,0 @@ - - -## Rate 评分 -> **组件名:uni-rate** -> 代码块: `uRate` -> 关联组件:`uni-icons` - - -评分组件,多用于购买商品后,对商品进行评价等场景 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-rate) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-row/changelog.md b/blog-uniapp/uni_modules/uni-row/changelog.md deleted file mode 100644 index 5b465bc6..00000000 --- a/blog-uniapp/uni_modules/uni-row/changelog.md +++ /dev/null @@ -1,10 +0,0 @@ -## 1.0.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-row](https://uniapp.dcloud.io/component/uniui/uni-row) -## 0.1.0(2021-07-13) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 0.0.4(2021-05-12) -- 新增 组件示例地址 -## 0.0.3(2021-02-05) -- 调整为uni_modules目录规范 -- 新增uni-row组件 diff --git a/blog-uniapp/uni_modules/uni-row/components/uni-col/uni-col.vue b/blog-uniapp/uni_modules/uni-row/components/uni-col/uni-col.vue deleted file mode 100644 index d5f37283..00000000 --- a/blog-uniapp/uni_modules/uni-row/components/uni-col/uni-col.vue +++ /dev/null @@ -1,317 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-row/components/uni-row/uni-row.vue b/blog-uniapp/uni_modules/uni-row/components/uni-row/uni-row.vue deleted file mode 100644 index c7d93701..00000000 --- a/blog-uniapp/uni_modules/uni-row/components/uni-row/uni-row.vue +++ /dev/null @@ -1,190 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-row/package.json b/blog-uniapp/uni_modules/uni-row/package.json deleted file mode 100644 index 3f52fa64..00000000 --- a/blog-uniapp/uni_modules/uni-row/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-row", - "displayName": "uni-row 布局-行", - "version": "1.0.0", - "description": "流式栅格系统,随着屏幕或视口分为 24 份,可以迅速简便地创建布局。", - "keywords": [ - "uni-ui", - "uniui", - "栅格", - "布局", - "layout" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "u" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-row/readme.md b/blog-uniapp/uni_modules/uni-row/readme.md deleted file mode 100644 index 3c9c8b99..00000000 --- a/blog-uniapp/uni_modules/uni-row/readme.md +++ /dev/null @@ -1,10 +0,0 @@ -## Layout 布局 - -> **组件名 uni-row、uni-col** -> 代码块: `uRow`、`uCol` - - -流式栅格系统,随着屏幕或视口分为 24 份,可以迅速简便地创建布局。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-row) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-scss/changelog.md b/blog-uniapp/uni_modules/uni-scss/changelog.md deleted file mode 100644 index b863bb0f..00000000 --- a/blog-uniapp/uni_modules/uni-scss/changelog.md +++ /dev/null @@ -1,8 +0,0 @@ -## 1.0.3(2022-01-21) -- 优化 组件示例 -## 1.0.2(2021-11-22) -- 修复 / 符号在 vue 不同版本兼容问题引起的报错问题 -## 1.0.1(2021-11-22) -- 修复 vue3中scss语法兼容问题 -## 1.0.0(2021-11-18) -- init diff --git a/blog-uniapp/uni_modules/uni-scss/index.scss b/blog-uniapp/uni_modules/uni-scss/index.scss deleted file mode 100644 index 1744a5f9..00000000 --- a/blog-uniapp/uni_modules/uni-scss/index.scss +++ /dev/null @@ -1 +0,0 @@ -@import './styles/index.scss'; diff --git a/blog-uniapp/uni_modules/uni-scss/package.json b/blog-uniapp/uni_modules/uni-scss/package.json deleted file mode 100644 index 7cc0ccb7..00000000 --- a/blog-uniapp/uni_modules/uni-scss/package.json +++ /dev/null @@ -1,82 +0,0 @@ -{ - "id": "uni-scss", - "displayName": "uni-scss 辅助样式", - "version": "1.0.3", - "description": "uni-sass是uni-ui提供的一套全局样式 ,通过一些简单的类名和sass变量,实现简单的页面布局操作,比如颜色、边距、圆角等。", - "keywords": [ - "uni-scss", - "uni-ui", - "辅助样式" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "^3.1.0" - }, - "dcloudext": { - "category": [ - "JS SDK", - "通用 SDK" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "u" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "n", - "联盟": "n" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-scss/readme.md b/blog-uniapp/uni_modules/uni-scss/readme.md deleted file mode 100644 index b7d1c25f..00000000 --- a/blog-uniapp/uni_modules/uni-scss/readme.md +++ /dev/null @@ -1,4 +0,0 @@ -`uni-sass` 是 `uni-ui`提供的一套全局样式 ,通过一些简单的类名和`sass`变量,实现简单的页面布局操作,比如颜色、边距、圆角等。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-sass) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-scss/styles/index.scss b/blog-uniapp/uni_modules/uni-scss/styles/index.scss deleted file mode 100644 index ffac4fec..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/index.scss +++ /dev/null @@ -1,7 +0,0 @@ -@import './setting/_variables.scss'; -@import './setting/_border.scss'; -@import './setting/_color.scss'; -@import './setting/_space.scss'; -@import './setting/_radius.scss'; -@import './setting/_text.scss'; -@import './setting/_styles.scss'; diff --git a/blog-uniapp/uni_modules/uni-scss/styles/setting/_border.scss b/blog-uniapp/uni_modules/uni-scss/styles/setting/_border.scss deleted file mode 100644 index 12a11c32..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/setting/_border.scss +++ /dev/null @@ -1,3 +0,0 @@ -.uni-border { - border: 1px $uni-border-1 solid; -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-scss/styles/setting/_color.scss b/blog-uniapp/uni_modules/uni-scss/styles/setting/_color.scss deleted file mode 100644 index 1ededd94..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/setting/_color.scss +++ /dev/null @@ -1,66 +0,0 @@ - -// TODO 暂时不需要 class ,需要用户使用变量实现 ,如果使用类名其实并不推荐 -// @mixin get-styles($k,$c) { -// @if $k == size or $k == weight{ -// font-#{$k}:#{$c} -// }@else{ -// #{$k}:#{$c} -// } -// } -$uni-ui-color:( - // 主色 - primary: $uni-primary, - primary-disable: $uni-primary-disable, - primary-light: $uni-primary-light, - // 辅助色 - success: $uni-success, - success-disable: $uni-success-disable, - success-light: $uni-success-light, - warning: $uni-warning, - warning-disable: $uni-warning-disable, - warning-light: $uni-warning-light, - error: $uni-error, - error-disable: $uni-error-disable, - error-light: $uni-error-light, - info: $uni-info, - info-disable: $uni-info-disable, - info-light: $uni-info-light, - // 中性色 - main-color: $uni-main-color, - base-color: $uni-base-color, - secondary-color: $uni-secondary-color, - extra-color: $uni-extra-color, - // 背景色 - bg-color: $uni-bg-color, - // 边框颜色 - border-1: $uni-border-1, - border-2: $uni-border-2, - border-3: $uni-border-3, - border-4: $uni-border-4, - // 黑色 - black:$uni-black, - // 白色 - white:$uni-white, - // 透明 - transparent:$uni-transparent -) !default; -@each $key, $child in $uni-ui-color { - .uni-#{"" + $key} { - color: $child; - } - .uni-#{"" + $key}-bg { - background-color: $child; - } -} -.uni-shadow-sm { - box-shadow: $uni-shadow-sm; -} -.uni-shadow-base { - box-shadow: $uni-shadow-base; -} -.uni-shadow-lg { - box-shadow: $uni-shadow-lg; -} -.uni-mask { - background-color:$uni-mask; -} diff --git a/blog-uniapp/uni_modules/uni-scss/styles/setting/_radius.scss b/blog-uniapp/uni_modules/uni-scss/styles/setting/_radius.scss deleted file mode 100644 index 9a0428bb..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/setting/_radius.scss +++ /dev/null @@ -1,55 +0,0 @@ -@mixin radius($r,$d:null ,$important: false){ - $radius-value:map-get($uni-radius, $r) if($important, !important, null); - // Key exists within the $uni-radius variable - @if (map-has-key($uni-radius, $r) and $d){ - @if $d == t { - border-top-left-radius:$radius-value; - border-top-right-radius:$radius-value; - }@else if $d == r { - border-top-right-radius:$radius-value; - border-bottom-right-radius:$radius-value; - }@else if $d == b { - border-bottom-left-radius:$radius-value; - border-bottom-right-radius:$radius-value; - }@else if $d == l { - border-top-left-radius:$radius-value; - border-bottom-left-radius:$radius-value; - }@else if $d == tl { - border-top-left-radius:$radius-value; - }@else if $d == tr { - border-top-right-radius:$radius-value; - }@else if $d == br { - border-bottom-right-radius:$radius-value; - }@else if $d == bl { - border-bottom-left-radius:$radius-value; - } - }@else{ - border-radius:$radius-value; - } -} - -@each $key, $child in $uni-radius { - @if($key){ - .uni-radius-#{"" + $key} { - @include radius($key) - } - }@else{ - .uni-radius { - @include radius($key) - } - } -} - -@each $direction in t, r, b, l,tl, tr, br, bl { - @each $key, $child in $uni-radius { - @if($key){ - .uni-radius-#{"" + $direction}-#{"" + $key} { - @include radius($key,$direction,false) - } - }@else{ - .uni-radius-#{$direction} { - @include radius($key,$direction,false) - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-scss/styles/setting/_space.scss b/blog-uniapp/uni_modules/uni-scss/styles/setting/_space.scss deleted file mode 100644 index 3c895289..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/setting/_space.scss +++ /dev/null @@ -1,56 +0,0 @@ - -@mixin fn($space,$direction,$size,$n) { - @if $n { - #{$space}-#{$direction}: #{$size*$uni-space-root}px - } @else { - #{$space}-#{$direction}: #{-$size*$uni-space-root}px - } -} -@mixin get-styles($direction,$i,$space,$n){ - @if $direction == t { - @include fn($space, top,$i,$n); - } - @if $direction == r { - @include fn($space, right,$i,$n); - } - @if $direction == b { - @include fn($space, bottom,$i,$n); - } - @if $direction == l { - @include fn($space, left,$i,$n); - } - @if $direction == x { - @include fn($space, left,$i,$n); - @include fn($space, right,$i,$n); - } - @if $direction == y { - @include fn($space, top,$i,$n); - @include fn($space, bottom,$i,$n); - } - @if $direction == a { - @if $n { - #{$space}:#{$i*$uni-space-root}px; - } @else { - #{$space}:#{-$i*$uni-space-root}px; - } - } -} - -@each $orientation in m,p { - $space: margin; - @if $orientation == m { - $space: margin; - } @else { - $space: padding; - } - @for $i from 0 through 16 { - @each $direction in t, r, b, l, x, y, a { - .uni-#{$orientation}#{$direction}-#{$i} { - @include get-styles($direction,$i,$space,true); - } - .uni-#{$orientation}#{$direction}-n#{$i} { - @include get-styles($direction,$i,$space,false); - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-scss/styles/setting/_styles.scss b/blog-uniapp/uni_modules/uni-scss/styles/setting/_styles.scss deleted file mode 100644 index 689afec6..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/setting/_styles.scss +++ /dev/null @@ -1,167 +0,0 @@ -/* #ifndef APP-NVUE */ - -$-color-white:#fff; -$-color-black:#000; -@mixin base-style($color) { - color: #fff; - background-color: $color; - border-color: mix($-color-black, $color, 8%); - &:not([hover-class]):active { - background: mix($-color-black, $color, 10%); - border-color: mix($-color-black, $color, 20%); - color: $-color-white; - outline: none; - } -} -@mixin is-color($color) { - @include base-style($color); - &[loading] { - @include base-style($color); - &::before { - margin-right:5px; - } - } - &[disabled] { - &, - &[loading], - &:not([hover-class]):active { - color: $-color-white; - border-color: mix(darken($color,10%), $-color-white); - background-color: mix($color, $-color-white); - } - } - -} -@mixin base-plain-style($color) { - color:$color; - background-color: mix($-color-white, $color, 90%); - border-color: mix($-color-white, $color, 70%); - &:not([hover-class]):active { - background: mix($-color-white, $color, 80%); - color: $color; - outline: none; - border-color: mix($-color-white, $color, 50%); - } -} -@mixin is-plain($color){ - &[plain] { - @include base-plain-style($color); - &[loading] { - @include base-plain-style($color); - &::before { - margin-right:5px; - } - } - &[disabled] { - &, - &:active { - color: mix($-color-white, $color, 40%); - background-color: mix($-color-white, $color, 90%); - border-color: mix($-color-white, $color, 80%); - } - } - } -} - - -.uni-btn { - margin: 5px; - color: #393939; - border:1px solid #ccc; - font-size: 16px; - font-weight: 200; - background-color: #F9F9F9; - // TODO 暂时处理边框隐藏一边的问题 - overflow: visible; - &::after{ - border: none; - } - - &:not([type]),&[type=default] { - color: #999; - &[loading] { - background: none; - &::before { - margin-right:5px; - } - } - - - - &[disabled]{ - color: mix($-color-white, #999, 60%); - &, - &[loading], - &:active { - color: mix($-color-white, #999, 60%); - background-color: mix($-color-white,$-color-black , 98%); - border-color: mix($-color-white, #999, 85%); - } - } - - &[plain] { - color: #999; - background: none; - border-color: $uni-border-1; - &:not([hover-class]):active { - background: none; - color: mix($-color-white, $-color-black, 80%); - border-color: mix($-color-white, $-color-black, 90%); - outline: none; - } - &[disabled]{ - &, - &[loading], - &:active { - background: none; - color: mix($-color-white, #999, 60%); - border-color: mix($-color-white, #999, 85%); - } - } - } - } - - &:not([hover-class]):active { - color: mix($-color-white, $-color-black, 50%); - } - - &[size=mini] { - font-size: 16px; - font-weight: 200; - border-radius: 8px; - } - - - - &.uni-btn-small { - font-size: 14px; - } - &.uni-btn-mini { - font-size: 12px; - } - - &.uni-btn-radius { - border-radius: 999px; - } - &[type=primary] { - @include is-color($uni-primary); - @include is-plain($uni-primary) - } - &[type=success] { - @include is-color($uni-success); - @include is-plain($uni-success) - } - &[type=error] { - @include is-color($uni-error); - @include is-plain($uni-error) - } - &[type=warning] { - @include is-color($uni-warning); - @include is-plain($uni-warning) - } - &[type=info] { - @include is-color($uni-info); - @include is-plain($uni-info) - } -} -/* #endif */ diff --git a/blog-uniapp/uni_modules/uni-scss/styles/setting/_text.scss b/blog-uniapp/uni_modules/uni-scss/styles/setting/_text.scss deleted file mode 100644 index a34d08f3..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/setting/_text.scss +++ /dev/null @@ -1,24 +0,0 @@ -@mixin get-styles($k,$c) { - @if $k == size or $k == weight{ - font-#{$k}:#{$c} - }@else{ - #{$k}:#{$c} - } -} - -@each $key, $child in $uni-headings { - /* #ifndef APP-NVUE */ - .uni-#{$key} { - @each $k, $c in $child { - @include get-styles($k,$c) - } - } - /* #endif */ - /* #ifdef APP-NVUE */ - .container .uni-#{$key} { - @each $k, $c in $child { - @include get-styles($k,$c) - } - } - /* #endif */ -} diff --git a/blog-uniapp/uni_modules/uni-scss/styles/setting/_variables.scss b/blog-uniapp/uni_modules/uni-scss/styles/setting/_variables.scss deleted file mode 100644 index 557d3d7c..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/setting/_variables.scss +++ /dev/null @@ -1,146 +0,0 @@ -// @use "sass:math"; -@import '../tools/functions.scss'; -// 间距基础倍数 -$uni-space-root: 2 !default; -// 边框半径默认值 -$uni-radius-root:5px !default; -$uni-radius: () !default; -// 边框半径断点 -$uni-radius: map-deep-merge( - ( - 0: 0, - // TODO 当前版本暂时不支持 sm 属性 - // 'sm': math.div($uni-radius-root, 2), - null: $uni-radius-root, - 'lg': $uni-radius-root * 2, - 'xl': $uni-radius-root * 6, - 'pill': 9999px, - 'circle': 50% - ), - $uni-radius -); -// 字体家族 -$body-font-family: 'Roboto', sans-serif !default; -// 文本 -$heading-font-family: $body-font-family !default; -$uni-headings: () !default; -$letterSpacing: -0.01562em; -$uni-headings: map-deep-merge( - ( - 'h1': ( - size: 32px, - weight: 300, - line-height: 50px, - // letter-spacing:-0.01562em - ), - 'h2': ( - size: 28px, - weight: 300, - line-height: 40px, - // letter-spacing: -0.00833em - ), - 'h3': ( - size: 24px, - weight: 400, - line-height: 32px, - // letter-spacing: normal - ), - 'h4': ( - size: 20px, - weight: 400, - line-height: 30px, - // letter-spacing: 0.00735em - ), - 'h5': ( - size: 16px, - weight: 400, - line-height: 24px, - // letter-spacing: normal - ), - 'h6': ( - size: 14px, - weight: 500, - line-height: 18px, - // letter-spacing: 0.0125em - ), - 'subtitle': ( - size: 12px, - weight: 400, - line-height: 20px, - // letter-spacing: 0.00937em - ), - 'body': ( - font-size: 14px, - font-weight: 400, - line-height: 22px, - // letter-spacing: 0.03125em - ), - 'caption': ( - 'size': 12px, - 'weight': 400, - 'line-height': 20px, - // 'letter-spacing': 0.03333em, - // 'text-transform': false - ) - ), - $uni-headings -); - - - -// 主色 -$uni-primary: #2979ff !default; -$uni-primary-disable:lighten($uni-primary,20%) !default; -$uni-primary-light: lighten($uni-primary,25%) !default; - -// 辅助色 -// 除了主色外的场景色,需要在不同的场景中使用(例如危险色表示危险的操作)。 -$uni-success: #18bc37 !default; -$uni-success-disable:lighten($uni-success,20%) !default; -$uni-success-light: lighten($uni-success,25%) !default; - -$uni-warning: #f3a73f !default; -$uni-warning-disable:lighten($uni-warning,20%) !default; -$uni-warning-light: lighten($uni-warning,25%) !default; - -$uni-error: #e43d33 !default; -$uni-error-disable:lighten($uni-error,20%) !default; -$uni-error-light: lighten($uni-error,25%) !default; - -$uni-info: #8f939c !default; -$uni-info-disable:lighten($uni-info,20%) !default; -$uni-info-light: lighten($uni-info,25%) !default; - -// 中性色 -// 中性色用于文本、背景和边框颜色。通过运用不同的中性色,来表现层次结构。 -$uni-main-color: #3a3a3a !default; // 主要文字 -$uni-base-color: #6a6a6a !default; // 常规文字 -$uni-secondary-color: #909399 !default; // 次要文字 -$uni-extra-color: #c7c7c7 !default; // 辅助说明 - -// 边框颜色 -$uni-border-1: #F0F0F0 !default; -$uni-border-2: #EDEDED !default; -$uni-border-3: #DCDCDC !default; -$uni-border-4: #B9B9B9 !default; - -// 常规色 -$uni-black: #000000 !default; -$uni-white: #ffffff !default; -$uni-transparent: rgba($color: #000000, $alpha: 0) !default; - -// 背景色 -$uni-bg-color: #f7f7f7 !default; - -/* 水平间距 */ -$uni-spacing-sm: 8px !default; -$uni-spacing-base: 15px !default; -$uni-spacing-lg: 30px !default; - -// 阴影 -$uni-shadow-sm:0 0 5px rgba($color: #d8d8d8, $alpha: 0.5) !default; -$uni-shadow-base:0 1px 8px 1px rgba($color: #a5a5a5, $alpha: 0.2) !default; -$uni-shadow-lg:0px 1px 10px 2px rgba($color: #a5a4a4, $alpha: 0.5) !default; - -// 蒙版 -$uni-mask: rgba($color: #000000, $alpha: 0.4) !default; diff --git a/blog-uniapp/uni_modules/uni-scss/styles/tools/functions.scss b/blog-uniapp/uni_modules/uni-scss/styles/tools/functions.scss deleted file mode 100644 index ac6f63e5..00000000 --- a/blog-uniapp/uni_modules/uni-scss/styles/tools/functions.scss +++ /dev/null @@ -1,19 +0,0 @@ -// 合并 map -@function map-deep-merge($parent-map, $child-map){ - $result: $parent-map; - @each $key, $child in $child-map { - $parent-has-key: map-has-key($result, $key); - $parent-value: map-get($result, $key); - $parent-type: type-of($parent-value); - $child-type: type-of($child); - $parent-is-map: $parent-type == map; - $child-is-map: $child-type == map; - - @if (not $parent-has-key) or ($parent-type != $child-type) or (not ($parent-is-map and $child-is-map)){ - $result: map-merge($result, ( $key: $child )); - }@else { - $result: map-merge($result, ( $key: map-deep-merge($parent-value, $child) )); - } - } - @return $result; -}; diff --git a/blog-uniapp/uni_modules/uni-scss/theme.scss b/blog-uniapp/uni_modules/uni-scss/theme.scss deleted file mode 100644 index 80ee62f7..00000000 --- a/blog-uniapp/uni_modules/uni-scss/theme.scss +++ /dev/null @@ -1,31 +0,0 @@ -// 间距基础倍数 -$uni-space-root: 2; -// 边框半径默认值 -$uni-radius-root:5px; -// 主色 -$uni-primary: #2979ff; -// 辅助色 -$uni-success: #4cd964; -// 警告色 -$uni-warning: #f0ad4e; -// 错误色 -$uni-error: #dd524d; -// 描述色 -$uni-info: #909399; -// 中性色 -$uni-main-color: #303133; -$uni-base-color: #606266; -$uni-secondary-color: #909399; -$uni-extra-color: #C0C4CC; -// 背景色 -$uni-bg-color: #f5f5f5; -// 边框颜色 -$uni-border-1: #DCDFE6; -$uni-border-2: #E4E7ED; -$uni-border-3: #EBEEF5; -$uni-border-4: #F2F6FC; - -// 常规色 -$uni-black: #000000; -$uni-white: #ffffff; -$uni-transparent: rgba($color: #000000, $alpha: 0); diff --git a/blog-uniapp/uni_modules/uni-scss/variables.scss b/blog-uniapp/uni_modules/uni-scss/variables.scss deleted file mode 100644 index 1c062d42..00000000 --- a/blog-uniapp/uni_modules/uni-scss/variables.scss +++ /dev/null @@ -1,62 +0,0 @@ -@import './styles/setting/_variables.scss'; -// 间距基础倍数 -$uni-space-root: 2; -// 边框半径默认值 -$uni-radius-root:5px; - -// 主色 -$uni-primary: #2979ff; -$uni-primary-disable:mix(#fff,$uni-primary,50%); -$uni-primary-light: mix(#fff,$uni-primary,80%); - -// 辅助色 -// 除了主色外的场景色,需要在不同的场景中使用(例如危险色表示危险的操作)。 -$uni-success: #18bc37; -$uni-success-disable:mix(#fff,$uni-success,50%); -$uni-success-light: mix(#fff,$uni-success,80%); - -$uni-warning: #f3a73f; -$uni-warning-disable:mix(#fff,$uni-warning,50%); -$uni-warning-light: mix(#fff,$uni-warning,80%); - -$uni-error: #e43d33; -$uni-error-disable:mix(#fff,$uni-error,50%); -$uni-error-light: mix(#fff,$uni-error,80%); - -$uni-info: #8f939c; -$uni-info-disable:mix(#fff,$uni-info,50%); -$uni-info-light: mix(#fff,$uni-info,80%); - -// 中性色 -// 中性色用于文本、背景和边框颜色。通过运用不同的中性色,来表现层次结构。 -$uni-main-color: #3a3a3a; // 主要文字 -$uni-base-color: #6a6a6a; // 常规文字 -$uni-secondary-color: #909399; // 次要文字 -$uni-extra-color: #c7c7c7; // 辅助说明 - -// 边框颜色 -$uni-border-1: #F0F0F0; -$uni-border-2: #EDEDED; -$uni-border-3: #DCDCDC; -$uni-border-4: #B9B9B9; - -// 常规色 -$uni-black: #000000; -$uni-white: #ffffff; -$uni-transparent: rgba($color: #000000, $alpha: 0); - -// 背景色 -$uni-bg-color: #f7f7f7; - -/* 水平间距 */ -$uni-spacing-sm: 8px; -$uni-spacing-base: 15px; -$uni-spacing-lg: 30px; - -// 阴影 -$uni-shadow-sm:0 0 5px rgba($color: #d8d8d8, $alpha: 0.5); -$uni-shadow-base:0 1px 8px 1px rgba($color: #a5a5a5, $alpha: 0.2); -$uni-shadow-lg:0px 1px 10px 2px rgba($color: #a5a4a4, $alpha: 0.5); - -// 蒙版 -$uni-mask: rgba($color: #000000, $alpha: 0.4); diff --git a/blog-uniapp/uni_modules/uni-search-bar/changelog.md b/blog-uniapp/uni_modules/uni-search-bar/changelog.md deleted file mode 100644 index b41fdd3b..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/changelog.md +++ /dev/null @@ -1,33 +0,0 @@ -## 1.2.3(2022-05-24) -- 新增 readonly 属性,组件只读 -## 1.2.2(2022-05-06) -- 修复 vue3 input 事件不生效的bug -## 1.2.1(2022-05-06) -- 修复 多余代码导致的bug -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-search-bar](https://uniapp.dcloud.io/component/uniui/uni-search-bar) -## 1.1.2(2021-08-30) -- 修复 value 属性与 modelValue 属性不兼容的Bug -## 1.1.1(2021-08-24) -- 新增 支持国际化 -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.9(2021-05-12) -- 新增 项目示例地址 -## 1.0.8(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 1.0.7(2021-04-15) -- uni-ui 新增 uni-search-bar 的 focus 事件 - -## 1.0.6(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.5(2021-02-05) -- 调整为uni_modules目录规范 -- 新增 支持双向绑定 -- 更改 input 事件的返回值,e={value:Number} --> e=value -- 新增 支持图标插槽 -- 新增 支持 clear、blur 事件 -- 新增 支持 focus 属性 -- 去掉组件背景色 diff --git a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/en.json b/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/en.json deleted file mode 100644 index dd083a53..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/en.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-search-bar.cancel": "cancel", - "uni-search-bar.placeholder": "Search enter content" -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/index.js b/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/index.js deleted file mode 100644 index de7509c8..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/index.js +++ /dev/null @@ -1,8 +0,0 @@ -import en from './en.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/zh-Hans.json deleted file mode 100644 index d4e5c120..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/zh-Hans.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-search-bar.cancel": "cancel", - "uni-search-bar.placeholder": "请输入搜索内容" -} diff --git a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/zh-Hant.json deleted file mode 100644 index 318b6ef1..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/i18n/zh-Hant.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "uni-search-bar.cancel": "cancel", - "uni-search-bar.placeholder": "請輸入搜索內容" -} diff --git a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/uni-search-bar.vue b/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/uni-search-bar.vue deleted file mode 100644 index 5a518a8c..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/components/uni-search-bar/uni-search-bar.vue +++ /dev/null @@ -1,298 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-search-bar/package.json b/blog-uniapp/uni_modules/uni-search-bar/package.json deleted file mode 100644 index 9352c574..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/package.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "id": "uni-search-bar", - "displayName": "uni-search-bar 搜索栏", - "version": "1.2.3", - "description": "搜索栏组件,通常用于搜索商品、文章等", - "keywords": [ - "uni-ui", - "uniui", - "搜索框", - "搜索栏" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-search-bar/readme.md b/blog-uniapp/uni_modules/uni-search-bar/readme.md deleted file mode 100644 index 253092f0..00000000 --- a/blog-uniapp/uni_modules/uni-search-bar/readme.md +++ /dev/null @@ -1,14 +0,0 @@ - - -## SearchBar 搜索栏 - -> **组件名:uni-search-bar** -> 代码块: `uSearchBar` - - -搜索栏组件 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-search-bar) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-section/changelog.md b/blog-uniapp/uni_modules/uni-section/changelog.md deleted file mode 100644 index 738f2b32..00000000 --- a/blog-uniapp/uni_modules/uni-section/changelog.md +++ /dev/null @@ -1,2 +0,0 @@ -## 0.0.1(2022-07-22) -- 初始化 diff --git a/blog-uniapp/uni_modules/uni-section/components/uni-section/uni-section.vue b/blog-uniapp/uni_modules/uni-section/components/uni-section/uni-section.vue deleted file mode 100644 index 9a52e0b8..00000000 --- a/blog-uniapp/uni_modules/uni-section/components/uni-section/uni-section.vue +++ /dev/null @@ -1,167 +0,0 @@ - - - - diff --git a/blog-uniapp/uni_modules/uni-section/package.json b/blog-uniapp/uni_modules/uni-section/package.json deleted file mode 100644 index 0a31fb55..00000000 --- a/blog-uniapp/uni_modules/uni-section/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-section", - "displayName": "uni-section 标题栏", - "version": "0.0.1", - "description": "标题栏组件", - "keywords": [ - "uni-ui", - "uniui", - "标题栏" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-section/readme.md b/blog-uniapp/uni_modules/uni-section/readme.md deleted file mode 100644 index d47faab7..00000000 --- a/blog-uniapp/uni_modules/uni-section/readme.md +++ /dev/null @@ -1,8 +0,0 @@ -## Section 标题栏 -> **组件名:uni-section** -> 代码块: `uSection` - -uni-section 组件主要用于文章、列表详情等标题展示 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-section) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 diff --git a/blog-uniapp/uni_modules/uni-segmented-control/changelog.md b/blog-uniapp/uni_modules/uni-segmented-control/changelog.md deleted file mode 100644 index a44385d7..00000000 --- a/blog-uniapp/uni_modules/uni-segmented-control/changelog.md +++ /dev/null @@ -1,9 +0,0 @@ -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-segmented-control](https://uniapp.dcloud.io/component/uniui/uni-segmented-control) -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.5(2021-05-12) -- 新增 项目示例地址 -## 1.0.4(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-segmented-control/components/uni-segmented-control/uni-segmented-control.vue b/blog-uniapp/uni_modules/uni-segmented-control/components/uni-segmented-control/uni-segmented-control.vue deleted file mode 100644 index ddbcf884..00000000 --- a/blog-uniapp/uni_modules/uni-segmented-control/components/uni-segmented-control/uni-segmented-control.vue +++ /dev/null @@ -1,145 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-segmented-control/package.json b/blog-uniapp/uni_modules/uni-segmented-control/package.json deleted file mode 100644 index 6cae41db..00000000 --- a/blog-uniapp/uni_modules/uni-segmented-control/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-segmented-control", - "displayName": "uni-segmented-control 分段器", - "version": "1.2.0", - "description": "分段器由至少 2 个分段控件组成,用作不同视图的显示", - "keywords": [ - "uni-ui", - "uniui", - "分段器", - "segement", - "顶部选择" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-segmented-control/readme.md b/blog-uniapp/uni_modules/uni-segmented-control/readme.md deleted file mode 100644 index 3527b03f..00000000 --- a/blog-uniapp/uni_modules/uni-segmented-control/readme.md +++ /dev/null @@ -1,13 +0,0 @@ - - -## SegmentedControl 分段器 -> **组件名:uni-segmented-control** -> 代码块: `uSegmentedControl` - - -用作不同视图的显示 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-segmented-control) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-steps/changelog.md b/blog-uniapp/uni_modules/uni-steps/changelog.md deleted file mode 100644 index cb9d3679..00000000 --- a/blog-uniapp/uni_modules/uni-steps/changelog.md +++ /dev/null @@ -1,16 +0,0 @@ -## 1.1.1(2021-11-22) -- 修复 vue3中某些scss变量无法找到的问题 -## 1.1.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-steps](https://uniapp.dcloud.io/component/uniui/uni-steps) -## 1.0.8(2021-05-12) -- 新增 项目示例地址 -## 1.0.7(2021-05-06) -- 修复 uni-steps 横向布局时,多行文字高度不合理的 bug -## 1.0.6(2021-04-21) -- 优化 添加依赖 uni-icons, 导入后自动下载依赖 -## 1.0.5(2021-02-05) -- 优化 组件引用关系,通过uni_modules引用组件 - -## 1.0.4(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-steps/components/uni-steps/uni-steps.vue b/blog-uniapp/uni_modules/uni-steps/components/uni-steps/uni-steps.vue deleted file mode 100644 index a6c8f287..00000000 --- a/blog-uniapp/uni_modules/uni-steps/components/uni-steps/uni-steps.vue +++ /dev/null @@ -1,269 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-steps/package.json b/blog-uniapp/uni_modules/uni-steps/package.json deleted file mode 100644 index c687b40a..00000000 --- a/blog-uniapp/uni_modules/uni-steps/package.json +++ /dev/null @@ -1,89 +0,0 @@ -{ - "id": "uni-steps", - "displayName": "uni-steps 步骤条", - "version": "1.1.1", - "description": "步骤条组件,提供横向和纵向两种布局格式。", - "keywords": [ - "uni-ui", - "uniui", - "步骤条", - "时间轴" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-scss", - "uni-icons" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-steps/readme.md b/blog-uniapp/uni_modules/uni-steps/readme.md deleted file mode 100644 index da7a4bfa..00000000 --- a/blog-uniapp/uni_modules/uni-steps/readme.md +++ /dev/null @@ -1,13 +0,0 @@ - - -## Steps 步骤条 -> **组件名:uni-steps** -> 代码块: `uSteps` - - -步骤条,常用于显示进度 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-steps) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-swipe-action/changelog.md b/blog-uniapp/uni_modules/uni-swipe-action/changelog.md deleted file mode 100644 index c007cb5c..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/changelog.md +++ /dev/null @@ -1,41 +0,0 @@ -## 1.3.7(2022-06-06) -- 修复 vue3 下使用组件不能正常运行的Bug -## 1.3.6(2022-05-31) -- 修复 h5端点击click触发两次的Bug -## 1.3.5(2022-05-23) -- 修复 isPC 找不到的Bug -## 1.3.4(2022-05-19) -- 修复 在 nvue 下 disabled 失效的bug -## 1.3.3(2022-03-31) -- 修复 按钮字体大小不能设置的bug -## 1.3.2(2022-03-16) -- 修复 h5和app端下报el错误的bug -## 1.3.1(2022-03-07) -- 修复 HBuilderX 1.4.X 版本中,h5和app端下报错的bug -## 1.3.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-swipe-action](https://uniapp.dcloud.io/component/uniui/uni-swipe-action) -## 1.2.4(2021-08-20) -- 优化 close-all 方法 -## 1.2.3(2021-08-20) -- 新增 close-all 方法,关闭所有已打开的组件 -## 1.2.2(2021-08-17) -- 新增 resize() 方法,在非微信小程序、h5、app-vue端出现不能滑动的问题的时候,重置组件 -- 修复 app 端偶尔出现类似 Page[x][-x,xx;-x,xx,x,x-x] 的问题 -- 优化 微信小程序、h5、app-vue 滑动逻辑,避免出现动态新增组件后不能滑动的问题 -## 1.2.1(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -- 修复 跨页面修改组件数据 ,导致不能滑动的问题 -## 1.1.10(2021-06-17) -- 修复 按钮点击执行两次的bug -## 1.1.9(2021-05-12) -- 新增 项目示例地址 -## 1.1.8(2021-03-26) -- 修复 微信小程序 nv_navigator is not defined 报错的bug -## 1.1.7(2021-02-05) -- 调整为uni_modules目录规范 -- 新增 左侧滑动 -- 新增 插槽使用方式 -- 新增 threshold 属性,可以控制滑动缺省值 -- 优化 长列表滚动性能 -- 修复 滚动页面时触发组件滑动的Bug diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/bindingx.js b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/bindingx.js deleted file mode 100644 index 755c97c9..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/bindingx.js +++ /dev/null @@ -1,302 +0,0 @@ -let bindIngXMixins = {} - -// #ifdef APP-NVUE -const BindingX = uni.requireNativePlugin('bindingx'); -const dom = uni.requireNativePlugin('dom'); -const animation = uni.requireNativePlugin('animation'); - -bindIngXMixins = { - data() { - return {} - }, - - watch: { - show(newVal) { - if (this.autoClose) return - if (this.stop) return - this.stop = true - if (newVal) { - this.open(newVal) - } else { - this.close() - } - }, - leftOptions() { - this.getSelectorQuery() - this.init() - }, - rightOptions(newVal) { - this.init() - } - }, - created() { - this.swipeaction = this.getSwipeAction() - if (this.swipeaction.children !== undefined) { - this.swipeaction.children.push(this) - } - }, - mounted() { - this.box = this.getEl(this.$refs['selector-box--hock']) - this.selector = this.getEl(this.$refs['selector-content--hock']); - this.leftButton = this.getEl(this.$refs['selector-left-button--hock']); - this.rightButton = this.getEl(this.$refs['selector-right-button--hock']); - this.init() - }, - // beforeDestroy() { - // this.swipeaction.children.forEach((item, index) => { - // if (item === this) { - // this.swipeaction.children.splice(index, 1) - // } - // }) - // }, - methods: { - init() { - this.$nextTick(() => { - this.x = 0 - this.button = { - show: false - } - setTimeout(() => { - this.getSelectorQuery() - }, 200) - }) - }, - onClick(index, item, position) { - this.$emit('click', { - content: item, - index, - position - }) - }, - touchstart(e) { - // fix by mehaotian 禁止滑动 - if (this.disabled) return - // 每次只触发一次,避免多次监听造成闪烁 - if (this.stop) return - this.stop = true - if (this.autoClose) { - this.swipeaction.closeOther(this) - } - - const leftWidth = this.button.left.width - const rightWidth = this.button.right.width - let expression = this.range(this.x, -rightWidth, leftWidth) - let leftExpression = this.range(this.x - leftWidth, -leftWidth, 0) - let rightExpression = this.range(this.x + rightWidth, 0, rightWidth) - - this.eventpan = BindingX.bind({ - anchor: this.box, - eventType: 'pan', - props: [{ - element: this.selector, - property: 'transform.translateX', - expression - }, { - element: this.leftButton, - property: 'transform.translateX', - expression: leftExpression - }, { - element: this.rightButton, - property: 'transform.translateX', - expression: rightExpression - }, ] - }, (e) => { - // nope - if (e.state === 'end') { - this.x = e.deltaX + this.x; - this.isclick = true - this.bindTiming(e.deltaX) - } - }); - }, - touchend(e) { - if (this.isopen !== 'none' && !this.isclick) { - this.open('none') - } - }, - bindTiming(x) { - const left = this.x - const leftWidth = this.button.left.width - const rightWidth = this.button.right.width - const threshold = this.threshold - if (!this.isopen || this.isopen === 'none') { - if (left > threshold) { - this.open('left') - } else if (left < -threshold) { - this.open('right') - } else { - this.open('none') - } - } else { - if ((x > -leftWidth && x < 0) || x > rightWidth) { - if ((x > -threshold && x < 0) || (x - rightWidth > threshold)) { - this.open('left') - } else { - this.open('none') - } - } else { - if ((x < threshold && x > 0) || (x + leftWidth < -threshold)) { - this.open('right') - } else { - this.open('none') - } - } - } - }, - - /** - * 移动范围 - * @param {Object} num - * @param {Object} mix - * @param {Object} max - */ - range(num, mix, max) { - return `min(max(x+${num}, ${mix}), ${max})` - }, - - /** - * 开启swipe - */ - open(type) { - this.animation(type) - }, - - /** - * 关闭swipe - */ - close() { - this.animation('none') - }, - - /** - * 开启关闭动画 - * @param {Object} type - */ - animation(type) { - const time = 300 - const leftWidth = this.button.left.width - const rightWidth = this.button.right.width - if (this.eventpan && this.eventpan.token) { - BindingX.unbind({ - token: this.eventpan.token, - eventType: 'pan' - }) - } - - switch (type) { - case 'left': - Promise.all([ - this.move(this.selector, leftWidth), - this.move(this.leftButton, 0), - this.move(this.rightButton, rightWidth * 2) - ]).then(() => { - this.setEmit(leftWidth, type) - }) - break - case 'right': - Promise.all([ - this.move(this.selector, -rightWidth), - this.move(this.leftButton, -leftWidth * 2), - this.move(this.rightButton, 0) - ]).then(() => { - this.setEmit(-rightWidth, type) - }) - break - default: - Promise.all([ - this.move(this.selector, 0), - this.move(this.leftButton, -leftWidth), - this.move(this.rightButton, rightWidth) - ]).then(() => { - this.setEmit(0, type) - }) - - } - }, - setEmit(x, type) { - const leftWidth = this.button.left.width - const rightWidth = this.button.right.width - this.isopen = this.isopen || 'none' - this.stop = false - this.isclick = false - // 只有状态不一致才会返回结果 - if (this.isopen !== type && this.x !== x) { - if (type === 'left' && leftWidth > 0) { - this.$emit('change', 'left') - } - if (type === 'right' && rightWidth > 0) { - this.$emit('change', 'right') - } - if (type === 'none') { - this.$emit('change', 'none') - } - } - this.x = x - this.isopen = type - }, - move(ref, value) { - return new Promise((resolve, reject) => { - animation.transition(ref, { - styles: { - transform: `translateX(${value})`, - }, - duration: 150, //ms - timingFunction: 'linear', - needLayout: false, - delay: 0 //ms - }, function(res) { - resolve(res) - }) - }) - - }, - - /** - * 获取ref - * @param {Object} el - */ - getEl(el) { - return el.ref - }, - /** - * 获取节点信息 - */ - getSelectorQuery() { - Promise.all([ - this.getDom('left'), - this.getDom('right'), - ]).then((data) => { - let show = 'none' - if (this.autoClose) { - show = 'none' - } else { - show = this.show - } - - if (show === 'none') { - // this.close() - } else { - this.open(show) - } - - }) - - }, - getDom(str) { - return new Promise((resolve, reject) => { - dom.getComponentRect(this.$refs[`selector-${str}-button--hock`], (data) => { - if (data) { - this.button[str] = data.size - resolve(data) - } else { - reject() - } - }) - }) - } - } -} - -// #endif - -export default bindIngXMixins diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/isPC.js b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/isPC.js deleted file mode 100644 index 917cb489..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/isPC.js +++ /dev/null @@ -1,12 +0,0 @@ -export function isPC() { - var userAgentInfo = navigator.userAgent; - var Agents = ["Android", "iPhone", "SymbianOS", "Windows Phone", "iPad", "iPod"]; - var flag = true; - for (let v = 0; v < Agents.length - 1; v++) { - if (userAgentInfo.indexOf(Agents[v]) > 0) { - flag = false; - break; - } - } - return flag; -} diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpalipay.js b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpalipay.js deleted file mode 100644 index 43cd56bd..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpalipay.js +++ /dev/null @@ -1,193 +0,0 @@ -export default { - data() { - return { - x: 0, - transition: false, - width: 0, - viewWidth: 0, - swipeShow: 0 - } - }, - watch: { - show(newVal) { - if (this.autoClose) return - if (newVal && newVal !== 'none') { - this.transition = true - this.open(newVal) - } else { - this.close() - } - } - }, - created() { - this.swipeaction = this.getSwipeAction() - if (this.swipeaction.children !== undefined) { - this.swipeaction.children.push(this) - } - }, - mounted() { - this.isopen = false - setTimeout(() => { - this.getQuerySelect() - }, 50) - }, - methods: { - appTouchStart(e) { - const { - clientX - } = e.changedTouches[0] - this.clientX = clientX - this.timestamp = new Date().getTime() - }, - appTouchEnd(e, index, item, position) { - const { - clientX - } = e.changedTouches[0] - // fixed by xxxx 模拟点击事件,解决 ios 13 点击区域错位的问题 - let diff = Math.abs(this.clientX - clientX) - let time = (new Date().getTime()) - this.timestamp - if (diff < 40 && time < 300) { - this.$emit('click', { - content: item, - index, - position - }) - } - }, - /** - * 移动触发 - * @param {Object} e - */ - onChange(e) { - this.moveX = e.detail.x - this.isclose = false - }, - touchstart(e) { - this.transition = false - this.isclose = true - this.autoClose && this.swipeaction.closeOther(this) - }, - touchmove(e) {}, - touchend(e) { - // 0的位置什么都不执行 - if (this.isclose && this.isopen === 'none') return - if (this.isclose && this.isopen !== 'none') { - this.transition = true - this.close() - } else { - this.move(this.moveX + this.leftWidth) - } - }, - - /** - * 移动 - * @param {Object} moveX - */ - move(moveX) { - // 打开关闭的处理逻辑不太一样 - this.transition = true - // 未打开状态 - if (!this.isopen || this.isopen === 'none') { - if (moveX > this.threshold) { - this.open('left') - } else if (moveX < -this.threshold) { - this.open('right') - } else { - this.close() - } - } else { - if (moveX < 0 && moveX < this.rightWidth) { - const rightX = this.rightWidth + moveX - if (rightX < this.threshold) { - this.open('right') - } else { - this.close() - } - } else if (moveX > 0 && moveX < this.leftWidth) { - const leftX = this.leftWidth - moveX - if (leftX < this.threshold) { - this.open('left') - } else { - this.close() - } - } - - } - - }, - - /** - * 打开 - */ - open(type) { - this.x = this.moveX - this.animation(type) - }, - - /** - * 关闭 - */ - close() { - this.x = this.moveX - // TODO 解决 x 值不更新的问题,所以会多触发一次 nextTick ,待优化 - this.$nextTick(() => { - this.x = -this.leftWidth - if (this.isopen !== 'none') { - this.$emit('change', 'none') - } - this.isopen = 'none' - }) - }, - - /** - * 执行结束动画 - * @param {Object} type - */ - animation(type) { - this.$nextTick(() => { - if (type === 'left') { - this.x = 0 - } else { - this.x = -this.rightWidth - this.leftWidth - } - - if (this.isopen !== type) { - this.$emit('change', type) - } - this.isopen = type - }) - - }, - getSlide(x) {}, - getQuerySelect() { - const query = uni.createSelectorQuery().in(this); - query.selectAll('.movable-view--hock').boundingClientRect(data => { - this.leftWidth = data[1].width - this.rightWidth = data[2].width - this.width = data[0].width - this.viewWidth = this.width + this.rightWidth + this.leftWidth - if (this.leftWidth === 0) { - // TODO 疑似bug ,初始化的时候如果x 是0,会导致移动位置错误,所以让元素超出一点 - this.x = -0.1 - } else { - this.x = -this.leftWidth - } - this.moveX = this.x - this.$nextTick(() => { - this.swipeShow = 1 - }) - - if (!this.buttonWidth) { - this.disabledView = true - } - - if (this.autoClose) return - if (this.show !== 'none') { - this.transition = true - this.open(this.shows) - } - }).exec(); - - } - } -} diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpother.js b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpother.js deleted file mode 100644 index 9a8bcbb6..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpother.js +++ /dev/null @@ -1,259 +0,0 @@ -let otherMixins = {} - -// #ifndef APP-PLUS|| MP-WEIXIN || H5 -const MIN_DISTANCE = 10; -otherMixins = { - data() { - // TODO 随机生生元素ID,解决百度小程序获取同一个元素位置信息的bug - const elClass = `Uni_${Math.ceil(Math.random() * 10e5).toString(36)}` - return { - uniShow: false, - left: 0, - buttonShow: 'none', - ani: false, - moveLeft: '', - elClass - } - }, - watch: { - show(newVal) { - if (this.autoClose) return - this.openState(newVal) - }, - left() { - this.moveLeft = `translateX(${this.left}px)` - }, - buttonShow(newVal) { - if (this.autoClose) return - this.openState(newVal) - }, - leftOptions() { - this.init() - }, - rightOptions() { - this.init() - } - }, - mounted() { - this.swipeaction = this.getSwipeAction() - if (this.swipeaction.children !== undefined) { - this.swipeaction.children.push(this) - } - this.init() - }, - methods: { - init() { - clearTimeout(this.timer) - this.timer = setTimeout(() => { - this.getSelectorQuery() - }, 100) - // 移动距离 - this.left = 0 - this.x = 0 - }, - - closeSwipe(e) { - if (!this.autoClose) return - this.swipeaction.closeOther(this) - }, - appTouchStart(e) { - const { - clientX - } = e.changedTouches[0] - this.clientX = clientX - this.timestamp = new Date().getTime() - }, - appTouchEnd(e, index, item, position) { - const { - clientX - } = e.changedTouches[0] - // fixed by xxxx 模拟点击事件,解决 ios 13 点击区域错位的问题 - let diff = Math.abs(this.clientX - clientX) - let time = (new Date().getTime()) - this.timestamp - if (diff < 40 && time < 300) { - this.$emit('click', { - content: item, - index, - position - }) - } - }, - touchstart(e) { - if (this.disabled) return - this.ani = false - this.x = this.left || 0 - this.stopTouchStart(e) - this.autoClose && this.closeSwipe() - }, - touchmove(e) { - if (this.disabled) return - // 是否可以滑动页面 - this.stopTouchMove(e); - if (this.direction !== 'horizontal') { - return; - } - this.move(this.x + this.deltaX) - return false - }, - touchend() { - if (this.disabled) return - this.moveDirection(this.left) - }, - /** - * 设置移动距离 - * @param {Object} value - */ - move(value) { - value = value || 0 - const leftWidth = this.leftWidth - const rightWidth = this.rightWidth - // 获取可滑动范围 - this.left = this.range(value, -rightWidth, leftWidth); - }, - - /** - * 获取范围 - * @param {Object} num - * @param {Object} min - * @param {Object} max - */ - range(num, min, max) { - return Math.min(Math.max(num, min), max); - }, - /** - * 移动方向判断 - * @param {Object} left - * @param {Object} value - */ - moveDirection(left) { - const threshold = this.threshold - const isopen = this.isopen || 'none' - const leftWidth = this.leftWidth - const rightWidth = this.rightWidth - if (this.deltaX === 0) { - this.openState('none') - return - } - if ((isopen === 'none' && rightWidth > 0 && -left > threshold) || (isopen !== 'none' && rightWidth > - 0 && rightWidth + - left < threshold)) { - // right - this.openState('right') - } else if ((isopen === 'none' && leftWidth > 0 && left > threshold) || (isopen !== 'none' && leftWidth > - 0 && - leftWidth - left < threshold)) { - // left - this.openState('left') - } else { - // default - this.openState('none') - } - }, - - /** - * 开启状态 - * @param {Boolean} type - */ - openState(type) { - const leftWidth = this.leftWidth - const rightWidth = this.rightWidth - let left = '' - this.isopen = this.isopen ? this.isopen : 'none' - switch (type) { - case "left": - left = leftWidth - break - case "right": - left = -rightWidth - break - default: - left = 0 - } - - - if (this.isopen !== type) { - this.throttle = true - this.$emit('change', type) - } - - this.isopen = type - // 添加动画类 - this.ani = true - this.$nextTick(() => { - this.move(left) - }) - // 设置最终移动位置,理论上只要进入到这个函数,肯定是要打开的 - }, - close() { - this.openState('none') - }, - getDirection(x, y) { - if (x > y && x > MIN_DISTANCE) { - return 'horizontal'; - } - if (y > x && y > MIN_DISTANCE) { - return 'vertical'; - } - return ''; - }, - - /** - * 重置滑动状态 - * @param {Object} event - */ - resetTouchStatus() { - this.direction = ''; - this.deltaX = 0; - this.deltaY = 0; - this.offsetX = 0; - this.offsetY = 0; - }, - - /** - * 设置滑动开始位置 - * @param {Object} event - */ - stopTouchStart(event) { - this.resetTouchStatus(); - const touch = event.touches[0]; - this.startX = touch.clientX; - this.startY = touch.clientY; - }, - - /** - * 滑动中,是否禁止打开 - * @param {Object} event - */ - stopTouchMove(event) { - const touch = event.touches[0]; - this.deltaX = touch.clientX - this.startX; - this.deltaY = touch.clientY - this.startY; - this.offsetX = Math.abs(this.deltaX); - this.offsetY = Math.abs(this.deltaY); - this.direction = this.direction || this.getDirection(this.offsetX, this.offsetY); - }, - - getSelectorQuery() { - const views = uni.createSelectorQuery().in(this) - views - .selectAll('.' + this.elClass) - .boundingClientRect(data => { - if (data.length === 0) return - let show = 'none' - if (this.autoClose) { - show = 'none' - } else { - show = this.show - } - this.leftWidth = data[0].width || 0 - this.rightWidth = data[1].width || 0 - this.buttonShow = show - }) - .exec() - } - } -} - -// #endif - -export default otherMixins diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpwxs.js b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpwxs.js deleted file mode 100644 index 435e0fbc..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/mpwxs.js +++ /dev/null @@ -1,83 +0,0 @@ -let mpMixins = {} -let is_pc = null -// #ifdef H5 -import { - isPC -} from "./isPC" -is_pc = isPC() -// #endif -// #ifdef APP-VUE|| MP-WEIXIN || H5 - -mpMixins = { - data() { - return { - is_show: 'none' - } - }, - watch: { - show(newVal) { - this.is_show = this.show - } - }, - created() { - this.swipeaction = this.getSwipeAction() - if (this.swipeaction.children !== undefined) { - this.swipeaction.children.push(this) - } - }, - mounted() { - this.is_show = this.show - }, - methods: { - // wxs 中调用 - closeSwipe(e) { - if (!this.autoClose) return - this.swipeaction.closeOther(this) - }, - - change(e) { - this.$emit('change', e.open) - if (this.is_show !== e.open) { - this.is_show = e.open - } - }, - - appTouchStart(e) { - if (is_pc) return - const { - clientX - } = e.changedTouches[0] - this.clientX = clientX - this.timestamp = new Date().getTime() - }, - appTouchEnd(e, index, item, position) { - if (is_pc) return - const { - clientX - } = e.changedTouches[0] - // fixed by xxxx 模拟点击事件,解决 ios 13 点击区域错位的问题 - let diff = Math.abs(this.clientX - clientX) - let time = (new Date().getTime()) - this.timestamp - if (diff < 40 && time < 300) { - this.$emit('click', { - content: item, - index, - position - }) - } - }, - onClickForPC(index, item, position) { - if (!is_pc) return - // #ifdef H5 - this.$emit('click', { - content: item, - index, - position - }) - // #endif - } - } -} - -// #endif -export default mpMixins diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/render.js b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/render.js deleted file mode 100644 index 78f0ec60..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/render.js +++ /dev/null @@ -1,270 +0,0 @@ -const MIN_DISTANCE = 10; -export default { - showWatch(newVal, oldVal, ownerInstance, instance, self) { - var state = self.state - var $el = ownerInstance.$el || ownerInstance.$vm && ownerInstance.$vm.$el - if (!$el) return - this.getDom(instance, ownerInstance, self) - if (newVal && newVal !== 'none') { - this.openState(newVal, instance, ownerInstance, self) - return - } - - if (state.left) { - this.openState('none', instance, ownerInstance, self) - } - this.resetTouchStatus(instance, self) - }, - - /** - * 开始触摸操作 - * @param {Object} e - * @param {Object} ins - */ - touchstart(e, ownerInstance, self) { - let instance = e.instance; - let disabled = instance.getDataset().disabled - let state = self.state; - this.getDom(instance, ownerInstance, self) - // fix by mehaotian, TODO 兼容 app-vue 获取dataset为字符串 , h5 获取 为 undefined 的问题,待框架修复 - disabled = this.getDisabledType(disabled) - if (disabled) return - // 开始触摸时移除动画类 - instance.requestAnimationFrame(function() { - instance.removeClass('ani'); - ownerInstance.callMethod('closeSwipe'); - }) - - // 记录上次的位置 - state.x = state.left || 0 - // 计算滑动开始位置 - this.stopTouchStart(e, ownerInstance, self) - }, - - /** - * 开始滑动操作 - * @param {Object} e - * @param {Object} ownerInstance - */ - touchmove(e, ownerInstance, self) { - let instance = e.instance; - // 删除之后已经那不到实例了 - if (!instance) return; - let disabled = instance.getDataset().disabled - let state = self.state - // fix by mehaotian, TODO 兼容 app-vue 获取dataset为字符串 , h5 获取 为 undefined 的问题,待框架修复 - disabled = this.getDisabledType(disabled) - if (disabled) return - // 是否可以滑动页面 - this.stopTouchMove(e, self); - if (state.direction !== 'horizontal') { - return; - } - if (e.preventDefault) { - // 阻止页面滚动 - e.preventDefault() - } - let x = state.x + state.deltaX - this.move(x, instance, ownerInstance, self) - }, - - /** - * 结束触摸操作 - * @param {Object} e - * @param {Object} ownerInstance - */ - touchend(e, ownerInstance, self) { - let instance = e.instance; - let disabled = instance.getDataset().disabled - let state = self.state - // fix by mehaotian, TODO 兼容 app-vue 获取dataset为字符串 , h5 获取 为 undefined 的问题,待框架修复 - disabled = this.getDisabledType(disabled) - - if (disabled) return - // 滑动过程中触摸结束,通过阙值判断是开启还是关闭 - // fixed by mehaotian 定时器解决点击按钮,touchend 触发比 click 事件时机早的问题 ,主要是 ios13 - this.moveDirection(state.left, instance, ownerInstance, self) - - }, - - /** - * 设置移动距离 - * @param {Object} value - * @param {Object} instance - * @param {Object} ownerInstance - */ - move(value, instance, ownerInstance, self) { - value = value || 0 - let state = self.state - let leftWidth = state.leftWidth - let rightWidth = state.rightWidth - // 获取可滑动范围 - state.left = this.range(value, -rightWidth, leftWidth); - instance.requestAnimationFrame(function() { - instance.setStyle({ - transform: 'translateX(' + state.left + 'px)', - '-webkit-transform': 'translateX(' + state.left + 'px)' - }) - }) - - }, - - /** - * 获取元素信息 - * @param {Object} instance - * @param {Object} ownerInstance - */ - getDom(instance, ownerInstance, self) { - var state = self.state - var $el = ownerInstance.$el || ownerInstance.$vm && ownerInstance.$vm.$el - var leftDom = $el.querySelector('.button-group--left') - var rightDom = $el.querySelector('.button-group--right') - - state.leftWidth = leftDom.offsetWidth || 0 - state.rightWidth = rightDom.offsetWidth || 0 - state.threshold = instance.getDataset().threshold - }, - - getDisabledType(value) { - return (typeof(value) === 'string' ? JSON.parse(value) : value) || false; - }, - - /** - * 获取范围 - * @param {Object} num - * @param {Object} min - * @param {Object} max - */ - range(num, min, max) { - return Math.min(Math.max(num, min), max); - }, - - - /** - * 移动方向判断 - * @param {Object} left - * @param {Object} value - * @param {Object} ownerInstance - * @param {Object} ins - */ - moveDirection(left, ins, ownerInstance, self) { - var state = self.state - var threshold = state.threshold - var position = state.position - var isopen = state.isopen || 'none' - var leftWidth = state.leftWidth - var rightWidth = state.rightWidth - if (state.deltaX === 0) { - this.openState('none', ins, ownerInstance, self) - return - } - if ((isopen === 'none' && rightWidth > 0 && -left > threshold) || (isopen !== 'none' && rightWidth > 0 && - rightWidth + - left < threshold)) { - // right - this.openState('right', ins, ownerInstance, self) - } else if ((isopen === 'none' && leftWidth > 0 && left > threshold) || (isopen !== 'none' && leftWidth > 0 && - leftWidth - left < threshold)) { - // left - this.openState('left', ins, ownerInstance, self) - } else { - // default - this.openState('none', ins, ownerInstance, self) - } - }, - - - /** - * 开启状态 - * @param {Boolean} type - * @param {Object} ins - * @param {Object} ownerInstance - */ - openState(type, ins, ownerInstance, self) { - let state = self.state - let leftWidth = state.leftWidth - let rightWidth = state.rightWidth - let left = '' - state.isopen = state.isopen ? state.isopen : 'none' - switch (type) { - case "left": - left = leftWidth - break - case "right": - left = -rightWidth - break - default: - left = 0 - } - - // && !state.throttle - - if (state.isopen !== type) { - state.throttle = true - ownerInstance.callMethod('change', { - open: type - }) - - } - - state.isopen = type - // 添加动画类 - ins.requestAnimationFrame(() => { - ins.addClass('ani'); - this.move(left, ins, ownerInstance, self) - }) - }, - - - getDirection(x, y) { - if (x > y && x > MIN_DISTANCE) { - return 'horizontal'; - } - if (y > x && y > MIN_DISTANCE) { - return 'vertical'; - } - return ''; - }, - - /** - * 重置滑动状态 - * @param {Object} event - */ - resetTouchStatus(instance, self) { - let state = self.state; - state.direction = ''; - state.deltaX = 0; - state.deltaY = 0; - state.offsetX = 0; - state.offsetY = 0; - }, - - /** - * 设置滑动开始位置 - * @param {Object} event - */ - stopTouchStart(event, ownerInstance, self) { - let instance = event.instance; - let state = self.state - this.resetTouchStatus(instance, self); - var touch = event.touches[0]; - state.startX = touch.clientX; - state.startY = touch.clientY; - }, - - /** - * 滑动中,是否禁止打开 - * @param {Object} event - */ - stopTouchMove(event, self) { - let instance = event.instance; - let state = self.state; - let touch = event.touches[0]; - - state.deltaX = touch.clientX - state.startX; - state.deltaY = touch.clientY - state.startY; - state.offsetY = Math.abs(state.deltaY); - state.offsetX = Math.abs(state.deltaX); - state.direction = state.direction || this.getDirection(state.offsetX, state.offsetY); - } -} diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/uni-swipe-action-item.vue b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/uni-swipe-action-item.vue deleted file mode 100644 index d79c2979..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/uni-swipe-action-item.vue +++ /dev/null @@ -1,347 +0,0 @@ - - - - - - diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/wx.wxs b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/wx.wxs deleted file mode 100644 index b394244f..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action-item/wx.wxs +++ /dev/null @@ -1,341 +0,0 @@ -var MIN_DISTANCE = 10; - -/** - * 判断当前是否为H5、app-vue - */ -var IS_HTML5 = false -if (typeof window === 'object') IS_HTML5 = true - -/** - * 监听页面内值的变化,主要用于动态开关swipe-action - * @param {Object} newValue - * @param {Object} oldValue - * @param {Object} ownerInstance - * @param {Object} instance - */ -function showWatch(newVal, oldVal, ownerInstance, instance) { - var state = instance.getState() - getDom(instance, ownerInstance) - if (newVal && newVal !== 'none') { - openState(newVal, instance, ownerInstance) - return - } - - if (state.left) { - openState('none', instance, ownerInstance) - } - resetTouchStatus(instance) -} - -/** - * 开始触摸操作 - * @param {Object} e - * @param {Object} ins - */ -function touchstart(e, ownerInstance) { - var instance = e.instance; - var disabled = instance.getDataset().disabled - var state = instance.getState(); - getDom(instance, ownerInstance) - // fix by mehaotian, TODO 兼容 app-vue 获取dataset为字符串 , h5 获取 为 undefined 的问题,待框架修复 - disabled = (typeof(disabled) === 'string' ? JSON.parse(disabled) : disabled) || false; - if (disabled) return - // 开始触摸时移除动画类 - instance.requestAnimationFrame(function() { - instance.removeClass('ani'); - ownerInstance.callMethod('closeSwipe'); - }) - - // 记录上次的位置 - state.x = state.left || 0 - // 计算滑动开始位置 - stopTouchStart(e, ownerInstance) -} - -/** - * 开始滑动操作 - * @param {Object} e - * @param {Object} ownerInstance - */ -function touchmove(e, ownerInstance) { - var instance = e.instance; - var disabled = instance.getDataset().disabled - var state = instance.getState() - // fix by mehaotian, TODO 兼容 app-vue 获取dataset为字符串 , h5 获取 为 undefined 的问题,待框架修复 - disabled = (typeof(disabled) === 'string' ? JSON.parse(disabled) : disabled) || false; - if (disabled) return - // 是否可以滑动页面 - stopTouchMove(e); - if (state.direction !== 'horizontal') { - return; - } - - if (e.preventDefault) { - // 阻止页面滚动 - e.preventDefault() - } - - move(state.x + state.deltaX, instance, ownerInstance) -} - -/** - * 结束触摸操作 - * @param {Object} e - * @param {Object} ownerInstance - */ -function touchend(e, ownerInstance) { - var instance = e.instance; - var disabled = instance.getDataset().disabled - var state = instance.getState() - // fix by mehaotian, TODO 兼容 app-vue 获取dataset为字符串 , h5 获取 为 undefined 的问题,待框架修复 - disabled = (typeof(disabled) === 'string' ? JSON.parse(disabled) : disabled) || false; - - if (disabled) return - // 滑动过程中触摸结束,通过阙值判断是开启还是关闭 - // fixed by mehaotian 定时器解决点击按钮,touchend 触发比 click 事件时机早的问题 ,主要是 ios13 - moveDirection(state.left, instance, ownerInstance) - -} - -/** - * 设置移动距离 - * @param {Object} value - * @param {Object} instance - * @param {Object} ownerInstance - */ -function move(value, instance, ownerInstance) { - value = value || 0 - var state = instance.getState() - var leftWidth = state.leftWidth - var rightWidth = state.rightWidth - // 获取可滑动范围 - state.left = range(value, -rightWidth, leftWidth); - instance.requestAnimationFrame(function() { - instance.setStyle({ - transform: 'translateX(' + state.left + 'px)', - '-webkit-transform': 'translateX(' + state.left + 'px)' - }) - }) - -} - -/** - * 获取元素信息 - * @param {Object} instance - * @param {Object} ownerInstance - */ -function getDom(instance, ownerInstance) { - var state = instance.getState() - var leftDom = ownerInstance.selectComponent('.button-group--left') - var rightDom = ownerInstance.selectComponent('.button-group--right') - var leftStyles = { - width: 0 - } - var rightStyles = { - width: 0 - } - leftStyles = leftDom.getBoundingClientRect() - rightStyles = rightDom.getBoundingClientRect() - - state.leftWidth = leftStyles.width || 0 - state.rightWidth = rightStyles.width || 0 - state.threshold = instance.getDataset().threshold -} - -/** - * 获取范围 - * @param {Object} num - * @param {Object} min - * @param {Object} max - */ -function range(num, min, max) { - return Math.min(Math.max(num, min), max); -} - - -/** - * 移动方向判断 - * @param {Object} left - * @param {Object} value - * @param {Object} ownerInstance - * @param {Object} ins - */ -function moveDirection(left, ins, ownerInstance) { - var state = ins.getState() - var threshold = state.threshold - var position = state.position - var isopen = state.isopen || 'none' - var leftWidth = state.leftWidth - var rightWidth = state.rightWidth - if (state.deltaX === 0) { - openState('none', ins, ownerInstance) - return - } - if ((isopen === 'none' && rightWidth > 0 && -left > threshold) || (isopen !== 'none' && rightWidth > 0 && - rightWidth + - left < threshold)) { - // right - openState('right', ins, ownerInstance) - } else if ((isopen === 'none' && leftWidth > 0 && left > threshold) || (isopen !== 'none' && leftWidth > 0 && - leftWidth - left < threshold)) { - // left - openState('left', ins, ownerInstance) - } else { - // default - openState('none', ins, ownerInstance) - } -} - - -/** - * 开启状态 - * @param {Boolean} type - * @param {Object} ins - * @param {Object} ownerInstance - */ -function openState(type, ins, ownerInstance) { - var state = ins.getState() - var leftWidth = state.leftWidth - var rightWidth = state.rightWidth - var left = '' - state.isopen = state.isopen ? state.isopen : 'none' - switch (type) { - case "left": - left = leftWidth - break - case "right": - left = -rightWidth - break - default: - left = 0 - } - - // && !state.throttle - - if (state.isopen !== type) { - state.throttle = true - ownerInstance.callMethod('change', { - open: type - }) - - } - - state.isopen = type - // 添加动画类 - ins.requestAnimationFrame(function() { - ins.addClass('ani'); - move(left, ins, ownerInstance) - }) - // 设置最终移动位置,理论上只要进入到这个函数,肯定是要打开的 -} - - -function getDirection(x, y) { - if (x > y && x > MIN_DISTANCE) { - return 'horizontal'; - } - if (y > x && y > MIN_DISTANCE) { - return 'vertical'; - } - return ''; -} - -/** - * 重置滑动状态 - * @param {Object} event - */ -function resetTouchStatus(instance) { - var state = instance.getState(); - state.direction = ''; - state.deltaX = 0; - state.deltaY = 0; - state.offsetX = 0; - state.offsetY = 0; -} - -/** - * 设置滑动开始位置 - * @param {Object} event - */ -function stopTouchStart(event) { - var instance = event.instance; - var state = instance.getState(); - resetTouchStatus(instance); - var touch = event.touches[0]; - if (IS_HTML5 && isPC()) { - touch = event; - } - state.startX = touch.clientX; - state.startY = touch.clientY; -} - -/** - * 滑动中,是否禁止打开 - * @param {Object} event - */ -function stopTouchMove(event) { - var instance = event.instance; - var state = instance.getState(); - var touch = event.touches[0]; - if (IS_HTML5 && isPC()) { - touch = event; - } - state.deltaX = touch.clientX - state.startX; - state.deltaY = touch.clientY - state.startY; - state.offsetY = Math.abs(state.deltaY); - state.offsetX = Math.abs(state.deltaX); - state.direction = state.direction || getDirection(state.offsetX, state.offsetY); -} - -function isPC() { - var userAgentInfo = navigator.userAgent; - var Agents = ["Android", "iPhone", "SymbianOS", "Windows Phone", "iPad", "iPod"]; - var flag = true; - for (var v = 0; v < Agents.length - 1; v++) { - if (userAgentInfo.indexOf(Agents[v]) > 0) { - flag = false; - break; - } - } - return flag; -} - -var movable = false - -function mousedown(e, ins) { - if (!IS_HTML5) return - if (!isPC()) return - touchstart(e, ins) - movable = true -} - -function mousemove(e, ins) { - if (!IS_HTML5) return - if (!isPC()) return - if (!movable) return - touchmove(e, ins) -} - -function mouseup(e, ins) { - if (!IS_HTML5) return - if (!isPC()) return - touchend(e, ins) - movable = false -} - -function mouseleave(e, ins) { - if (!IS_HTML5) return - if (!isPC()) return - movable = false -} - -module.exports = { - showWatch: showWatch, - touchstart: touchstart, - touchmove: touchmove, - touchend: touchend, - mousedown: mousedown, - mousemove: mousemove, - mouseup: mouseup, - mouseleave: mouseleave -} diff --git a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action/uni-swipe-action.vue b/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action/uni-swipe-action.vue deleted file mode 100644 index 49717824..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/components/uni-swipe-action/uni-swipe-action.vue +++ /dev/null @@ -1,60 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-swipe-action/package.json b/blog-uniapp/uni_modules/uni-swipe-action/package.json deleted file mode 100644 index c8998d9d..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-swipe-action", - "displayName": "uni-swipe-action 滑动操作", - "version": "1.3.7", - "description": "SwipeAction 滑动操作操作组件", - "keywords": [ - "", - "uni-ui", - "uniui", - "滑动删除", - "侧滑删除" - ], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "y", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-swipe-action/readme.md b/blog-uniapp/uni_modules/uni-swipe-action/readme.md deleted file mode 100644 index 93a5cac6..00000000 --- a/blog-uniapp/uni_modules/uni-swipe-action/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -## SwipeAction 滑动操作 -> **组件名:uni-swipe-action** -> 代码块: `uSwipeAction`、`uSwipeActionItem` - - -通过滑动触发选项的容器 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-swipe-action) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-swiper-dot/changelog.md b/blog-uniapp/uni_modules/uni-swiper-dot/changelog.md deleted file mode 100644 index 85cf54d2..00000000 --- a/blog-uniapp/uni_modules/uni-swiper-dot/changelog.md +++ /dev/null @@ -1,12 +0,0 @@ -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-swiper-dot](https://uniapp.dcloud.io/component/uniui/uni-swiper-dot) -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.6(2021-05-12) -- 新增 示例地址 -- 修复 示例项目缺少组件的Bug -## 1.0.5(2021-02-05) -- 调整为uni_modules目录规范 -- 新增 clickItem 事件,支持指示点控制轮播 -- 新增 支持 pc 可用 diff --git a/blog-uniapp/uni_modules/uni-swiper-dot/components/uni-swiper-dot/uni-swiper-dot.vue b/blog-uniapp/uni_modules/uni-swiper-dot/components/uni-swiper-dot/uni-swiper-dot.vue deleted file mode 100644 index 46eb8c1f..00000000 --- a/blog-uniapp/uni_modules/uni-swiper-dot/components/uni-swiper-dot/uni-swiper-dot.vue +++ /dev/null @@ -1,218 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-swiper-dot/package.json b/blog-uniapp/uni_modules/uni-swiper-dot/package.json deleted file mode 100644 index f2dd8d2a..00000000 --- a/blog-uniapp/uni_modules/uni-swiper-dot/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-swiper-dot", - "displayName": "uni-swiper-dot 轮播图指示点", - "version": "1.2.0", - "description": "自定义轮播图指示点组件", - "keywords": [ - "uni-ui", - "uniui", - "轮播图指示点", - "dot", - "swiper" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-swiper-dot/readme.md b/blog-uniapp/uni_modules/uni-swiper-dot/readme.md deleted file mode 100644 index 7d397e2c..00000000 --- a/blog-uniapp/uni_modules/uni-swiper-dot/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -## SwiperDot 轮播图指示点 -> **组件名:uni-swiper-dot** -> 代码块: `uSwiperDot` - - -自定义轮播图指示点 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-swiper-dot) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-table/changelog.md b/blog-uniapp/uni_modules/uni-table/changelog.md deleted file mode 100644 index 8233b20f..00000000 --- a/blog-uniapp/uni_modules/uni-table/changelog.md +++ /dev/null @@ -1,23 +0,0 @@ -## 1.2.1(2022-06-06) -- 修复 微信小程序存在无使用组件的问题 -## 1.2.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-table](https://uniapp.dcloud.io/component/uniui/uni-table) -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.7(2021-07-08) -- 新增 uni-th 支持 date 日期筛选范围 -## 1.0.6(2021-07-05) -- 新增 uni-th 支持 range 筛选范围 -## 1.0.5(2021-06-28) -- 新增 uni-th 筛选功能 -## 1.0.4(2021-05-12) -- 新增 示例地址 -- 修复 示例项目缺少组件的Bug -## 1.0.3(2021-04-16) -- 新增 sortable 属性,是否开启单列排序 -- 优化 表格多选逻辑 -## 1.0.2(2021-03-22) -- uni-tr 添加 disabled 属性,用于 type=selection 时,设置某行是否可由全选按钮控制 -## 1.0.1(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-table/uni-table.vue b/blog-uniapp/uni_modules/uni-table/components/uni-table/uni-table.vue deleted file mode 100644 index 91b74fa7..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-table/uni-table.vue +++ /dev/null @@ -1,455 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-tbody/uni-tbody.vue b/blog-uniapp/uni_modules/uni-table/components/uni-tbody/uni-tbody.vue deleted file mode 100644 index fbe1bdcb..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-tbody/uni-tbody.vue +++ /dev/null @@ -1,29 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-td/uni-td.vue b/blog-uniapp/uni_modules/uni-table/components/uni-td/uni-td.vue deleted file mode 100644 index 9ce93e93..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-td/uni-td.vue +++ /dev/null @@ -1,90 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-th/filter-dropdown.vue b/blog-uniapp/uni_modules/uni-table/components/uni-th/filter-dropdown.vue deleted file mode 100644 index bc9a0e3b..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-th/filter-dropdown.vue +++ /dev/null @@ -1,503 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-th/uni-th.vue b/blog-uniapp/uni_modules/uni-table/components/uni-th/uni-th.vue deleted file mode 100644 index 883e3f2a..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-th/uni-th.vue +++ /dev/null @@ -1,278 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-thead/uni-thead.vue b/blog-uniapp/uni_modules/uni-table/components/uni-thead/uni-thead.vue deleted file mode 100644 index 0dd18cd8..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-thead/uni-thead.vue +++ /dev/null @@ -1,129 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-tr/table-checkbox.vue b/blog-uniapp/uni_modules/uni-table/components/uni-tr/table-checkbox.vue deleted file mode 100644 index 158f3ffd..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-tr/table-checkbox.vue +++ /dev/null @@ -1,179 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/components/uni-tr/uni-tr.vue b/blog-uniapp/uni_modules/uni-table/components/uni-tr/uni-tr.vue deleted file mode 100644 index f9b96716..00000000 --- a/blog-uniapp/uni_modules/uni-table/components/uni-tr/uni-tr.vue +++ /dev/null @@ -1,171 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-table/i18n/en.json b/blog-uniapp/uni_modules/uni-table/i18n/en.json deleted file mode 100644 index e32023cc..00000000 --- a/blog-uniapp/uni_modules/uni-table/i18n/en.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "filter-dropdown.reset": "Reset", - "filter-dropdown.search": "Search", - "filter-dropdown.submit": "Submit", - "filter-dropdown.filter": "Filter", - "filter-dropdown.gt": "Greater or equal to", - "filter-dropdown.lt": "Less than or equal to", - "filter-dropdown.date": "Date" -} diff --git a/blog-uniapp/uni_modules/uni-table/i18n/es.json b/blog-uniapp/uni_modules/uni-table/i18n/es.json deleted file mode 100644 index 9afd04bb..00000000 --- a/blog-uniapp/uni_modules/uni-table/i18n/es.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "filter-dropdown.reset": "Reiniciar", - "filter-dropdown.search": "Búsqueda", - "filter-dropdown.submit": "Entregar", - "filter-dropdown.filter": "Filtrar", - "filter-dropdown.gt": "Mayor o igual a", - "filter-dropdown.lt": "Menos que o igual a", - "filter-dropdown.date": "Fecha" -} diff --git a/blog-uniapp/uni_modules/uni-table/i18n/fr.json b/blog-uniapp/uni_modules/uni-table/i18n/fr.json deleted file mode 100644 index b0062371..00000000 --- a/blog-uniapp/uni_modules/uni-table/i18n/fr.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "filter-dropdown.reset": "Réinitialiser", - "filter-dropdown.search": "Chercher", - "filter-dropdown.submit": "Soumettre", - "filter-dropdown.filter": "Filtre", - "filter-dropdown.gt": "Supérieur ou égal à", - "filter-dropdown.lt": "Inférieur ou égal à", - "filter-dropdown.date": "Date" -} diff --git a/blog-uniapp/uni_modules/uni-table/i18n/index.js b/blog-uniapp/uni_modules/uni-table/i18n/index.js deleted file mode 100644 index 2469dd02..00000000 --- a/blog-uniapp/uni_modules/uni-table/i18n/index.js +++ /dev/null @@ -1,12 +0,0 @@ -import en from './en.json' -import es from './es.json' -import fr from './fr.json' -import zhHans from './zh-Hans.json' -import zhHant from './zh-Hant.json' -export default { - en, - es, - fr, - 'zh-Hans': zhHans, - 'zh-Hant': zhHant -} diff --git a/blog-uniapp/uni_modules/uni-table/i18n/zh-Hans.json b/blog-uniapp/uni_modules/uni-table/i18n/zh-Hans.json deleted file mode 100644 index 862af179..00000000 --- a/blog-uniapp/uni_modules/uni-table/i18n/zh-Hans.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "filter-dropdown.reset": "重置", - "filter-dropdown.search": "搜索", - "filter-dropdown.submit": "确定", - "filter-dropdown.filter": "筛选", - "filter-dropdown.gt": "大于等于", - "filter-dropdown.lt": "小于等于", - "filter-dropdown.date": "日期范围" -} diff --git a/blog-uniapp/uni_modules/uni-table/i18n/zh-Hant.json b/blog-uniapp/uni_modules/uni-table/i18n/zh-Hant.json deleted file mode 100644 index 64f80615..00000000 --- a/blog-uniapp/uni_modules/uni-table/i18n/zh-Hant.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "filter-dropdown.reset": "重置", - "filter-dropdown.search": "搜索", - "filter-dropdown.submit": "確定", - "filter-dropdown.filter": "篩選", - "filter-dropdown.gt": "大於等於", - "filter-dropdown.lt": "小於等於", - "filter-dropdown.date": "日期範圍" -} diff --git a/blog-uniapp/uni_modules/uni-table/package.json b/blog-uniapp/uni_modules/uni-table/package.json deleted file mode 100644 index f224ab72..00000000 --- a/blog-uniapp/uni_modules/uni-table/package.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "id": "uni-table", - "displayName": "uni-table 表格", - "version": "1.2.1", - "description": "表格组件,多用于展示多条结构类似的数据,如", - "keywords": [ - "uni-ui", - "uniui", - "table", - "表格" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss","uni-datetime-picker"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "n" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "n", - "QQ": "y" - }, - "快应用": { - "华为": "n", - "联盟": "n" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-table/readme.md b/blog-uniapp/uni_modules/uni-table/readme.md deleted file mode 100644 index bb08c791..00000000 --- a/blog-uniapp/uni_modules/uni-table/readme.md +++ /dev/null @@ -1,13 +0,0 @@ - - -## Table 表单 -> 组件名:``uni-table``,代码块: `uTable`。 - -用于展示多条结构类似的数据 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-table) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - - - diff --git a/blog-uniapp/uni_modules/uni-tag/changelog.md b/blog-uniapp/uni_modules/uni-tag/changelog.md deleted file mode 100644 index c0c5839b..00000000 --- a/blog-uniapp/uni_modules/uni-tag/changelog.md +++ /dev/null @@ -1,21 +0,0 @@ -## 2.1.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-tag](https://uniapp.dcloud.io/component/uniui/uni-tag) -## 2.0.0(2021-11-09) -- 新增 提供组件设计资源,组件样式调整 -- 移除 插槽 -- 移除 type 属性的 royal 选项 -## 1.1.1(2021-08-11) -- type 不是 default 时,size 为 small 字体大小显示不正确 -## 1.1.0(2021-07-30) -- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.0.7(2021-06-18) -- 修复 uni-tag 在字节跳动小程序上 css 类名编译错误的 bug -## 1.0.6(2021-06-04) -- 修复 未定义 sass 变量 "$uni-color-royal" 的bug -## 1.0.5(2021-05-10) -- 修复 royal 类型无效的bug -- 修复 uni-tag 宽度不自适应的bug -- 新增 uni-tag 支持属性 custom-style 自定义样式 -## 1.0.4(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-tag/components/uni-tag/uni-tag.vue b/blog-uniapp/uni_modules/uni-tag/components/uni-tag/uni-tag.vue deleted file mode 100644 index 6378a0b9..00000000 --- a/blog-uniapp/uni_modules/uni-tag/components/uni-tag/uni-tag.vue +++ /dev/null @@ -1,252 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-tag/package.json b/blog-uniapp/uni_modules/uni-tag/package.json deleted file mode 100644 index 18780886..00000000 --- a/blog-uniapp/uni_modules/uni-tag/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-tag", - "displayName": "uni-tag 标签", - "version": "2.1.0", - "description": "Tag 组件,用于展示1个或多个文字标签,可点击切换选中、不选中的状态。", - "keywords": [ - "uni-ui", - "uniui", - "", - "tag", - "标签" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-tag/readme.md b/blog-uniapp/uni_modules/uni-tag/readme.md deleted file mode 100644 index 6e78ff5e..00000000 --- a/blog-uniapp/uni_modules/uni-tag/readme.md +++ /dev/null @@ -1,13 +0,0 @@ - - -## Tag 标签 -> **组件名:uni-tag** -> 代码块: `uTag` - - -用于展示1个或多个文字标签,可点击切换选中、不选中的状态 。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-tag) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - diff --git a/blog-uniapp/uni_modules/uni-test/changelog.md b/blog-uniapp/uni_modules/uni-test/changelog.md deleted file mode 100644 index 2f3b102c..00000000 --- a/blog-uniapp/uni_modules/uni-test/changelog.md +++ /dev/null @@ -1,39 +0,0 @@ -## 2.0.13(2021-11-18) -邱 -## 2.0.12(2021-11-18) -123123 -## 2.0.11(2021-11-18) -0000 -## 2.0.10(2021-11-18) -111234 -## 2.0.9(2021-11-18) -3333 -## 2.0.8(2021-11-18) -=== -## 2.0.7(2021-11-18) -111 -## 2.0.6(2021-05-26) -- test -## 0.0.37(2021-03-23) -- uni-forms 更新 校验器 -- uni-forms 修复 表单规则设置类型为 number 的情况下,值为0校验失败的Bug - - -## 0.0.36(2021-03-23) -- uni-forms 更新 校验器 -- uni-forms 修复 表单规则设置类型为 number 的情况下,值为0校验失败的Bug - - -## 0.0.35(2021-03-23) -- uni-forms 更新 校验器 -- uni-forms 修复 表单规则设置类型为 number 的情况下,值为0校验失败的Bug - - -## 0.0.34(2021-03-23) -- 测试新同步插件 -## 0.0.33(2021-03-09) -- test -## 0.0.32(2021-02-24) -- 更新 read 2 -## 0.0.31(2021-02-24) -- 同步 readme.md diff --git a/blog-uniapp/uni_modules/uni-test/components/uni-test/uni-test.vue b/blog-uniapp/uni_modules/uni-test/components/uni-test/uni-test.vue deleted file mode 100644 index 9ea8aaf7..00000000 --- a/blog-uniapp/uni_modules/uni-test/components/uni-test/uni-test.vue +++ /dev/null @@ -1,26 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-test/package.json b/blog-uniapp/uni_modules/uni-test/package.json deleted file mode 100644 index 9a3c4c42..00000000 --- a/blog-uniapp/uni_modules/uni-test/package.json +++ /dev/null @@ -1,83 +0,0 @@ -{ - "id": "uni-test", - "displayName": "Test 测试插件", - "version": "2.0.13", - "description": "测试插件 ", - "keywords": [ - "test" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "^3.1.3" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "y", - "联盟": "y" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} diff --git a/blog-uniapp/uni_modules/uni-test/readme.md b/blog-uniapp/uni_modules/uni-test/readme.md deleted file mode 100644 index ddb24c62..00000000 --- a/blog-uniapp/uni_modules/uni-test/readme.md +++ /dev/null @@ -1,10 +0,0 @@ - - -## DataCheckbox 数据驱动的单选复选框 -> **组件名:uni-data-checkbox** -> 代码块: `uDataCheckbox` - - -本组件是基于uni-app基础组件checkbox的封装。本组件要解决问题包括: - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-card) \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-title/changelog.md b/blog-uniapp/uni_modules/uni-title/changelog.md deleted file mode 100644 index 76262165..00000000 --- a/blog-uniapp/uni_modules/uni-title/changelog.md +++ /dev/null @@ -1,10 +0,0 @@ -## 1.1.1(2022-05-19) -- 修改组件描述 -## 1.1.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-title](https://uniapp.dcloud.io/component/uniui/uni-title) -## 1.0.2(2021-05-12) -- 新增 示例地址 -- 修复 示例项目缺少组件的Bug -## 1.0.1(2021-02-05) -- 调整为uni_modules目录规范 diff --git a/blog-uniapp/uni_modules/uni-title/components/uni-title/uni-title.vue b/blog-uniapp/uni_modules/uni-title/components/uni-title/uni-title.vue deleted file mode 100644 index bf4f9265..00000000 --- a/blog-uniapp/uni_modules/uni-title/components/uni-title/uni-title.vue +++ /dev/null @@ -1,171 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-title/package.json b/blog-uniapp/uni_modules/uni-title/package.json deleted file mode 100644 index 2249f5a1..00000000 --- a/blog-uniapp/uni_modules/uni-title/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-title", - "displayName": "uni-title 章节标题", - "version": "1.1.1", - "description": "章节标题,通常用于记录页面标题,使用当前组件,uni-app 如果开启统计,将会自动统计页面标题", - "keywords": [ - "uni-ui", - "uniui", - "标题", - "章节", - "章节标题", - "" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-title/readme.md b/blog-uniapp/uni_modules/uni-title/readme.md deleted file mode 100644 index 0e60b1b9..00000000 --- a/blog-uniapp/uni_modules/uni-title/readme.md +++ /dev/null @@ -1,14 +0,0 @@ - - -## Title 标题 -> **组件名:uni-title** -> 代码块: `uTitle` - - -章节标题,通常用于记录页面标题,使用当前组件,uni-app 如果开启统计,将会自动统计页面标题 。 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-title) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 - - - diff --git a/blog-uniapp/uni_modules/uni-tooltip/changelog.md b/blog-uniapp/uni_modules/uni-tooltip/changelog.md deleted file mode 100644 index 00f1572d..00000000 --- a/blog-uniapp/uni_modules/uni-tooltip/changelog.md +++ /dev/null @@ -1,10 +0,0 @@ -## 0.2.1(2022-05-09) -- 修复 content 为空时仍然弹出的bug -## 0.2.0(2022-05-07) -**注意:破坏性更新** -- 更新 text 属性变更为 content -- 更新 移除 width 属性 -## 0.1.1(2022-04-27) -- 修复 组件根 text 嵌套组件 warning -## 0.1.0(2022-04-21) -- 初始化 diff --git a/blog-uniapp/uni_modules/uni-tooltip/components/uni-tooltip/uni-tooltip.vue b/blog-uniapp/uni_modules/uni-tooltip/components/uni-tooltip/uni-tooltip.vue deleted file mode 100644 index ffbb6fa5..00000000 --- a/blog-uniapp/uni_modules/uni-tooltip/components/uni-tooltip/uni-tooltip.vue +++ /dev/null @@ -1,68 +0,0 @@ - - - - - - diff --git a/blog-uniapp/uni_modules/uni-tooltip/package.json b/blog-uniapp/uni_modules/uni-tooltip/package.json deleted file mode 100644 index e88ecf8d..00000000 --- a/blog-uniapp/uni_modules/uni-tooltip/package.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "id": "uni-tooltip", - "displayName": "uni-tooltip 提示文字", - "version": "0.2.1", - "description": "Tooltip 提示文字", - "keywords": [ - "uni-tooltip", - "uni-ui", - "tooltip", - "tip", - "文字提示" - ], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无 ", - "data": "无", - "permissions": "无" - }, - "npmurl": "" - }, - "uni_modules": { - "dependencies": [], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "Vue": { - "vue2": "y", - "vue3": "y" - }, - "App": { - "app-vue": "y", - "app-nvue": "u" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "u", - "百度": "u", - "字节跳动": "u", - "QQ": "u", - "京东": "u" - }, - "快应用": { - "华为": "u", - "联盟": "u" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-tooltip/readme.md b/blog-uniapp/uni_modules/uni-tooltip/readme.md deleted file mode 100644 index faafa2ec..00000000 --- a/blog-uniapp/uni_modules/uni-tooltip/readme.md +++ /dev/null @@ -1,8 +0,0 @@ -## Badge 数字角标 -> **组件名:uni-tooltip** -> 代码块: `uTooltip` - -数字角标一般和其它控件(列表、9宫格等)配合使用,用于进行数量提示,默认为实心灰色背景, - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-tooltip) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 diff --git a/blog-uniapp/uni_modules/uni-transition/changelog.md b/blog-uniapp/uni_modules/uni-transition/changelog.md deleted file mode 100644 index b1a824b8..00000000 --- a/blog-uniapp/uni_modules/uni-transition/changelog.md +++ /dev/null @@ -1,20 +0,0 @@ -## 1.3.1(2021-11-23) -- 修复 init 方法初始化问题 -## 1.3.0(2021-11-19) -- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-transition](https://uniapp.dcloud.io/component/uniui/uni-transition) -## 1.2.1(2021-09-27) -- 修复 init 方法不生效的 Bug -## 1.2.0(2021-07-30) -- 组件兼容 vue3,如何创建 vue3 项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -## 1.1.1(2021-05-12) -- 新增 示例地址 -- 修复 示例项目缺少组件的 Bug -## 1.1.0(2021-04-22) -- 新增 通过方法自定义动画 -- 新增 custom-class 非 NVUE 平台支持自定义 class 定制样式 -- 优化 动画触发逻辑,使动画更流畅 -- 优化 支持单独的动画类型 -- 优化 文档示例 -## 1.0.2(2021-02-05) -- 调整为 uni_modules 目录规范 diff --git a/blog-uniapp/uni_modules/uni-transition/components/uni-transition/createAnimation.js b/blog-uniapp/uni_modules/uni-transition/components/uni-transition/createAnimation.js deleted file mode 100644 index 5f54365e..00000000 --- a/blog-uniapp/uni_modules/uni-transition/components/uni-transition/createAnimation.js +++ /dev/null @@ -1,128 +0,0 @@ -// const defaultOption = { -// duration: 300, -// timingFunction: 'linear', -// delay: 0, -// transformOrigin: '50% 50% 0' -// } -// #ifdef APP-NVUE -const nvueAnimation = uni.requireNativePlugin('animation') -// #endif -class MPAnimation { - constructor(options, _this) { - this.options = options - this.animation = uni.createAnimation(options) - this.currentStepAnimates = {} - this.next = 0 - this.$ = _this - - } - - _nvuePushAnimates(type, args) { - let aniObj = this.currentStepAnimates[this.next] - let styles = {} - if (!aniObj) { - styles = { - styles: {}, - config: {} - } - } else { - styles = aniObj - } - if (animateTypes1.includes(type)) { - if (!styles.styles.transform) { - styles.styles.transform = '' - } - let unit = '' - if(type === 'rotate'){ - unit = 'deg' - } - styles.styles.transform += `${type}(${args+unit}) ` - } else { - styles.styles[type] = `${args}` - } - this.currentStepAnimates[this.next] = styles - } - _animateRun(styles = {}, config = {}) { - let ref = this.$.$refs['ani'].ref - if (!ref) return - return new Promise((resolve, reject) => { - nvueAnimation.transition(ref, { - styles, - ...config - }, res => { - resolve() - }) - }) - } - - _nvueNextAnimate(animates, step = 0, fn) { - let obj = animates[step] - if (obj) { - let { - styles, - config - } = obj - this._animateRun(styles, config).then(() => { - step += 1 - this._nvueNextAnimate(animates, step, fn) - }) - } else { - this.currentStepAnimates = {} - typeof fn === 'function' && fn() - this.isEnd = true - } - } - - step(config = {}) { - // #ifndef APP-NVUE - this.animation.step(config) - // #endif - // #ifdef APP-NVUE - this.currentStepAnimates[this.next].config = Object.assign({}, this.options, config) - this.currentStepAnimates[this.next].styles.transformOrigin = this.currentStepAnimates[this.next].config.transformOrigin - this.next++ - // #endif - return this - } - - run(fn) { - // #ifndef APP-NVUE - this.$.animationData = this.animation.export() - this.$.timer = setTimeout(() => { - typeof fn === 'function' && fn() - }, this.$.durationTime) - // #endif - // #ifdef APP-NVUE - this.isEnd = false - let ref = this.$.$refs['ani'] && this.$.$refs['ani'].ref - if(!ref) return - this._nvueNextAnimate(this.currentStepAnimates, 0, fn) - this.next = 0 - // #endif - } -} - - -const animateTypes1 = ['matrix', 'matrix3d', 'rotate', 'rotate3d', 'rotateX', 'rotateY', 'rotateZ', 'scale', 'scale3d', - 'scaleX', 'scaleY', 'scaleZ', 'skew', 'skewX', 'skewY', 'translate', 'translate3d', 'translateX', 'translateY', - 'translateZ' -] -const animateTypes2 = ['opacity', 'backgroundColor'] -const animateTypes3 = ['width', 'height', 'left', 'right', 'top', 'bottom'] -animateTypes1.concat(animateTypes2, animateTypes3).forEach(type => { - MPAnimation.prototype[type] = function(...args) { - // #ifndef APP-NVUE - this.animation[type](...args) - // #endif - // #ifdef APP-NVUE - this._nvuePushAnimates(type, args) - // #endif - return this - } -}) - -export function createAnimation(option, _this) { - if(!_this) return - clearTimeout(_this.timer) - return new MPAnimation(option, _this) -} diff --git a/blog-uniapp/uni_modules/uni-transition/components/uni-transition/uni-transition.vue b/blog-uniapp/uni_modules/uni-transition/components/uni-transition/uni-transition.vue deleted file mode 100644 index 0d739bd5..00000000 --- a/blog-uniapp/uni_modules/uni-transition/components/uni-transition/uni-transition.vue +++ /dev/null @@ -1,277 +0,0 @@ - - - - - diff --git a/blog-uniapp/uni_modules/uni-transition/package.json b/blog-uniapp/uni_modules/uni-transition/package.json deleted file mode 100644 index d15fdf01..00000000 --- a/blog-uniapp/uni_modules/uni-transition/package.json +++ /dev/null @@ -1,87 +0,0 @@ -{ - "id": "uni-transition", - "displayName": "uni-transition 过渡动画", - "version": "1.3.1", - "description": "元素的简单过渡动画", - "keywords": [ - "uni-ui", - "uniui", - "动画", - "过渡", - "过渡动画" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": ["uni-scss"], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-transition/readme.md b/blog-uniapp/uni_modules/uni-transition/readme.md deleted file mode 100644 index 2f8a77e1..00000000 --- a/blog-uniapp/uni_modules/uni-transition/readme.md +++ /dev/null @@ -1,11 +0,0 @@ - - -## Transition 过渡动画 -> **组件名:uni-transition** -> 代码块: `uTransition` - - -元素过渡动画 - -### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-transition) -#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-ui/changelog.md b/blog-uniapp/uni_modules/uni-ui/changelog.md deleted file mode 100644 index 95958c2e..00000000 --- a/blog-uniapp/uni_modules/uni-ui/changelog.md +++ /dev/null @@ -1,447 +0,0 @@ -## 1.4.20(2022-07-25) -- uni-section 新增组件 -- uni-forms 修复 model 需要校验的值没有声明对应字段时,导致第一次不触发校验的bug - -## 1.4.19(2022-07-07) -- uni-data-picker 优化 pc端图标位置不正确的问题 -- uni-data-select 修复 pc端宽度异常的bug -## 1.4.18(2022-07-06) -- uni-forms 【重要】组件逻辑重构,部分用法旧版本不兼容,请注意兼容问题 -- uni-forms 【重要】组件使用 Provide/Inject 方式注入依赖,提供了自定义表单组件调用 uni-forms 校验表单的能力 -- uni-forms 新增 更多表单示例 -- uni-forms 新增 model 属性,等同于原 value/modelValue 属性,旧属性即将废弃 -- uni-forms 新增 validateTrigger 属性的 blur 值,仅 uni-easyinput 生效 -- uni-forms 新增 onFieldChange 方法,可以对子表单进行校验,可替代binddata方法 -- uni-forms 新增 子表单的 setRules 方法,配合自定义校验函数使用 -- uni-forms 新增 uni-forms-item 的 setRules 方法,配置动态表单使用可动态更新校验规则 -- uni-forms 修复 由 1.4.0 引发的 label 插槽不生效的bug -- uni-forms 修复 子组件找不到 setValue 报错的bug -- uni-forms 修复 uni-data-picker 在 uni-forms-item 中报错的bug -- uni-forms 修复 uni-data-picker 在 uni-forms-item 中宽度不正确的bug -- uni-forms 修复 表单校验顺序无序问题 -- uni-forms 优化 子表单组件uni-datetime-picker、uni-data-select、uni-data-picker的显示样式 -- uni-forms 优化 动态表单校验方式,废弃拼接name的方式 -- uni-breadcrumb 修复 微信小程序 separator 不显示问题 -- uni-data-checkbox 优化 在 uni-forms 中的依赖注入方式 -- uni-data-picker 修复 uni-data-picker 在 uni-forms-item 中宽度不正确的bug -- uni-data-picker 优化 显示样式 -- uni-data-select 优化 显示样式 -- uni-datetime-picker 修复 日历顶部年月及底部确认未国际化 bug -- uni-datetime-picker 优化 组件样式,调整了组件图标大小、高度、颜色等,与uni-ui风格保持一致 -- uni-easyinput 新增 在 uni-forms 1.4.0 中使用可以在 blur 时校验内容 -- uni-easyinput 新增 clear 事件,点击右侧叉号图标触发 -- uni-easyinput 新增 change 事件 ,仅在输入框失去焦点或用户按下回车时触发 -- uni-easyinput 优化 组件样式,组件获取焦点时高亮显示,图标颜色调整等 -- uni-easyinput 优化 clearable 显示策略 -- uni-file-picker 修复 在uni-forms下样式不生效的bug -- uni-nav-bar 修复 组件示例中插槽用法无法显示内容的bug -- uni-swipe-action 修复 vue3 下使用组件不能正常运行的Bug -- uni-swipe-action 修复 h5端点击click触发两次的Bug -- uni-table 修复 微信小程序存在无使用组件的问题 -## 1.4.17(2022-06-30) -- 支持 ios 安全区 -## 1.4.16(2022-06-06) -- uni-breadcrumb 新增 支持 uni.scss 修改颜色 -- uni-data-select 修复 localdata 赋值不生效的 bug -- uni-data-select 新增 支持选项禁用(数据选项设置 disabled: true 即禁用) -- uni-data-select 修复 当 value 为 0 时选择不生效的 bug -- uni-easyinput 修复 关闭图标某些情况下无法取消的bug -- uni-fav 新增 stat 属性 ,是否开启uni统计功能 -- uni-goods-nav 新增 stat属性,是否开启uni统计功能 -- uni-group 新增 stat属性,是否开启uni统计功能 -- uni-nav-bar 新增 stat 属性 ,可开启统计 title 上报 ,仅使用了title 属性且项目开启了uni统计生效 -- uni-search-bar 新增 readonly 属性,组件只读 -- uni-swipe-action 修复 isPC 找不到的Bug -- uni-swipe-action 修复 在 nvue 下 disabled 失效的bug -- uni-tooltip 修复 content 为空时仍然弹出的bug -## 1.4.15(2022-05-07) -- uni-data-picker 修复 字节小程序 本地数据无法选择下一级的Bug -- uni-data-select 新增 记住上次的选项(仅 collection 存在时有效) -- uni-search-bar 修复 vue3 input 事件不生效的bug -- uni-search-bar 修复 多余代码导致的bug -- uni-tooltip 更新 text 属性变更为 content -- uni-tooltip 更新 移除 width 属性 -- uni-tooltip 修复 组件根 text 嵌套组件 warning -## 1.4.14(2022-04-18) -- uni-datetime-picker 修复 Vue3 下动态赋值,单选类型未响应的 bug -- uni-easyinput 修复 默认值不生效的bug -## 1.4.13(2022-04-02) -- uni-calendar 修复 条件编译 nvue 不支持的 css 样式 -- uni-calendar 修复 startDate、 endDate 属性失效的 bug -- uni-data-picker 修复 nvue 不支持的 v-show 的 bug -- uni-data-picker 修复 条件编译 nvue 不支持的 css 样式 -- uni-datetime-picker 修复 Vue3 下动态赋值未响应的 bug -- uni-easyinput 修复 value不能为0的bug -- uni-popup 修复 弹出层内部无法滚动的bug -- uni-popup 修复 小程序中高度错误的bug -- uni-popup 修复 快速调用open出现问题的Bug -- uni-rate 修复 条件判断 `NaN` 错误的 bug -- uni-swipe-action 修复 按钮字体大小不能设置的bug -- uni-swipe-action 修复 h5和app端下报el错误的bug -- uni-swipe-action 修复 HBuilderX 1.4.X 版本中,h5和app端下报错的bug -## 1.4.12(2022-02-19) -- uni-collapse 修复 初始化的时候 ,open 属性失效的bug -- uni-data-checkbox 修复 multiple 为 true 时,v-model 的值为 null 报错的 bug -- uni-icons 优化 size 属性可以传入不带单位的字符串数值 -- uni-icons 优化 size 支持其他单位 -- uni-nav-bar 新增 left-width/right-width属性 ,可修改左右两侧的宽度 -- uni-popup 修复 safeArea 属性不能设置为false的bug -## 1.4.11(2022-01-21) -- uni-collapse 修复 微信小程序resize后组件收起的bug -- uni-countdown 修复 在微信小程序中样式不生效的bug -- uni-countdown 新增 update 方法 ,在动态更新时间后,刷新组件 -- uni-load-more 新增 showText属性 ,是否显示文本 -- uni-load-more 修复 nvue 平台下不显示文本的bug -- uni-load-more 修复 微信小程序平台样式选择器报警告的问题 -- uni-nav-bar 修复 在vue下,标题不垂直居中的bug -- uni-nav-bar 修复 height 属性类型错误 -- uni-nav-bar 新增 height 属性,可修改组件高度 -- uni-nav-bar 新增 dark 属性可可开启暗黑模式 -- uni-nav-bar 优化 标题字数过多显示省略号 -- uni-nav-bar 优化 插槽,插入内容可完全覆盖 -- uni-popup 修复 isMaskClick 失效的bug -- uni-popup 新增 cancelText \ confirmText 属性 ,可自定义文本 -- uni-popup 新增 maskBackgroundColor 属性 ,可以修改蒙版颜色 -- uni-popup 优化 maskClick属性 更新为 isMaskClick ,解决微信小程序警告的问题 - -## 1.4.10(2022-01-17) -- uni-card 修复 在vue页面下略缩图显示不正常的bug -- uni-datetime-picker 修复 clear-icon 属性在小程序平台不生效的 bug -- uni-datetime-picker 修复 日期范围选在小程序平台,必须多点击一次才能取消选中状态的 bug -- uni-fab 更新 组件依赖 -- -- uni-icons 修复 nvue 有些图标不显示的bug,兼容老版本图标 -- uni-icons 优化 示例可复制图标名称 -- uni-nav-bar 修复 color 属性不生效的bug -- uni-popup 修复 设置 safeArea 属性不生效的bug -- uni-popup 优化 组件示例 -- uni-popup 修复 vuedoc 文字错误 -## 1.4.9(2021-11-23) -- uni-ui 修复 vue3中某些scss变量无法找到的问题 -- uni-combox 优化 label、label-width 属性 -- uni-data-picker 修复 由上个版本引发的map、v-model等属性不生效的bug -- uni-file-picker 修复 参数为对象的情况下,url在某些情况显示错误的bug -- uni-icons 优化 兼容旧组件 type 值 -- uni-list 修复 在vue3中to属性在发行应用的时候报错的bug -- uni-scss 修复 vue3中scss语法兼容问题 -- uni-transition 修复 init 方法初始化问题 -## 1.4.8(2021-11-19) -- uni-fab 修复 阴影颜色不正确的bug -## 1.4.7(2021-11-19) -- uni-ui 新增 支持国际化 -- uni-ui 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) -- uni-ui 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-ui](https://uniapp.dcloud.io/component/uniui/uni-ui) -- uni-badge 修改 size 属性默认值调整为 small -- uni-badge 修改 type 属性,默认值调整为 error,info 替换 default -- uni-badge 修复 在字节小程序上样式不生效的 bug -- uni-calendar 修复 弹出层被 tabbar 遮盖 bug -- uni-card 重构插槽的用法 ,header 替换为 title -- uni-card 新增 actions 插槽 -- uni-card 新增 cover 封面图属性和插槽 -- uni-card 新增 padding 内容默认内边距离 -- uni-card 新增 margin 卡片默认外边距离 -- uni-card 新增 spacing 卡片默认内边距 -- uni-card 新增 shadow 卡片阴影属性 -- uni-card 取消 mode 属性,可使用组合插槽代替 -- uni-card 取消 note 属性 ,使用actions插槽代替 -- uni-collapse 优化 show-arrow 属性默认为true -- uni-collapse 新增 show-arrow 属性,控制是否显示右侧箭头 -- uni-countdown 新增 font-size 支持自定义字体大小 -- uni-data-checkbox 修复 在uni-forms中 modelValue 中不存在当前字段,当前字段必填写也不参与校验的问题 -- uni-data-checkbox 修复 单选 list 模式下 ,icon 为 left 时,选中图标不显示的问题 -- uni-data-checkbox 修复 在 uni-forms 中重置表单,错误信息无法清除的问题 -- uni-dateformat 优化 默认时间不再是当前时间,而是显示'-'字符 -- uni-datetime-picker 修复 hide-second 在移动端的 bug -- uni-datetime-picker 修复 单选赋默认值时,赋值日期未高亮的 bug -- uni-datetime-picker 修复 赋默认值时,移动端未正确显示时间的 bug -- uni-datetime-picker 新增 hide-second 属性,支持只使用时分,隐藏秒 -- uni-datetime-picker 优化 取消选中时(范围选)直接开始下一次选择, 避免多点一次 -- uni-datetime-picker 优化 移动端支持清除按钮,同时支持通过 ref 调用组件的 clear 方法 -- uni-datetime-picker 优化 调整字号大小,美化日历界面 -- uni-datetime-picker 优化 范围选择器在 pc 端过宽的问题 -- uni-datetime-picker 新增 支持作为 uni-forms 子组件相关功能 -- uni-datetime-picker 修复 在 uni-forms 中使用时,选择时间报 NAN 错误的 bug -- uni-datetime-picker 修复 type 属性动态赋值无效的 bug -- uni-datetime-picker 修复 ‘确认’按钮被 tabbar 遮盖 bug -- uni-datetime-picker 修复 组件未赋值时范围选左、右日历相同的 bug -- uni-datetime-picker 修复 范围选未正确显示当前值的 bug -- uni-datetime-picker 修复 h5 平台(移动端)报错 'cale' of undefined 的 bug -- uni-easyinput 修复 在 uni-forms 的动态表单中默认值校验不通过的 bug -- uni-easyinput 修复 在 uni-forms 中重置表单,错误信息无法清除的问题 -- uni-file-picker 新增 参数中返回 fileID 字段 -- uni-file-picker 修复 腾讯云传入fileID 不能回显的bug -- uni-file-picker 修复 选择图片后,不能放大的问题 -- uni-file-picker 修复 由于 0.2.11 版本引起的不能回显图片的Bug -- uni-file-picker 新增 clearFiles(index) 方法,可以手动删除指定文件 -- uni-file-picker 修复 v-model 值设为 null 报错的Bug -- uni-file-picker 修复 return-type="object" 时,无法删除文件的Bug -- uni-file-picker 修复 auto-upload 属性失效的Bug -- uni-forms 修复 label 插槽不生效的bug -- uni-forms 修复 没有添加校验规则的字段依然报错的Bug -- uni-forms 修复 重置表单错误信息无法清除的问题 -- uni-forms 修复 表单验证只生效一次的问题 -- uni-icons 新增 更多图标 -- uni-icons 优化 自定义图标使用方式 -- uni-link 修复 在 nvue 下不显示的 bug -- uni-pagination 修复 current 、value 属性未监听,导致高亮样式失效的 bug -- uni-rate 优化 默认值修改为 0 颗星 -- uni-search-bar 修复 value 属性与 modelValue 属性不兼容的Bug -- uni-swipe-action 新增 close-all 方法,关闭所有已打开的组件 -- uni-swipe-action 新增 resize() 方法,在非微信小程序、h5、app-vue端出现不能滑动的问题的时候,重置组件 -- uni-swipe-action 修复 app 端偶尔出现类似 Page[x][-x,xx;-x,xx,x,x-x] 的问题 -- uni-swipe-action 优化 微信小程序、h5、app-vue 滑动逻辑,避免出现动态新增组件后不能滑动的问题 -- uni-tag 新增 提供组件设计资源,组件样式调整 -- uni-tag 移除 插槽 -- uni-tag 移除 type 属性的 royal 选项 -- uni-tag type 不是 default 时,size 为 small 字体大小显示不正确 -## 1.4.2(2021-08-20) -- 新增 uni-ui 组件支持国际化 i18n -- uni-collapse 优化 show-arrow 属性默认为true -- uni-collapse 新增 show-arrow 属性,控制是否显示右侧箭头 -- uni-data-checkbox 修复 单选 list 模式下 ,icon 为 left 时,选中图标不显示的问题 -- uni-easyinput 修复 在 uni-forms 的动态表单中默认值校验不通过的 bug -- uni-file-picker 修复 由于 0.2.11 版本引起的不能回显图片的Bug -- uni-file-picker 新增 clearFiles(index) 方法,可以手动删除指定文件 -- uni-file-picker 修复 v-model 值设为 null 报错的Bug -- uni-swipe-action 新增 close-all 方法,关闭所有已打开的组件 -- uni-swipe-action 新增 resize() 方法,在非微信小程序、h5、app-vue端出现不能滑动的问题的时候,重置组件 -- uni-swipe-action 修复 app 端偶尔出现类似 Page[x][-x,xx;-x,xx,x,x-x] 的问题 -- uni-swipe-action 优化 微信小程序、h5、app-vue 滑动逻辑,避免出现动态新增组件后不能滑动的问题 -## 1.4.0(2021-08-13) -- uni-calendar 修复 弹出层被 tabbar 遮盖 bug -- uni-data-checkbox 修复 在 uni-forms 中重置表单,错误信息无法清除的问题 -- uni-dateformat 调整 默认时间不再是当前时间,而是显示'-'字符 -- uni-datetime-picker 新增 适配 vue3 -- uni-datetime-picker 新增 支持作为 uni-forms 子组件相关功能 -- uni-datetime-picker 修复 在 uni-forms 中使用时,选择时间报 NAN 错误的 bug -- uni-datetime-picker 修复 type 属性动态赋值无效的 bug -- uni-datetime-picker 修复 ‘确认’按钮被 tabbar 遮盖 bug -- uni-datetime-picker 修复 组件未赋值时范围选左、右日历相同的 bug -- uni-datetime-picker 修复 范围选未正确显示当前值的 bug -- uni-datetime-picker 修复 h5 平台(移动端)报错 'cale' of undefined 的 bug -- uni-easyinput 修复 在 uni-forms 中重置表单,错误信息无法清除的问题 -- uni-file-picker 修复 return-type="object" 时,无法删除文件的Bug -- uni-file-picker 修复 auto-upload 属性失效的Bug -- uni-forms 修复 没有添加校验规则的字段依然报错的Bug -- uni-forms 修复 重置表单错误信息无法清除的问题 -- uni-forms 优化 组件文档 -- uni-forms 修复 表单验证只生效一次的问题 -- uni-tag type 不是 default 时,size 为 small 字体大小显示不正确 -## 1.3.9(2021-08-02) -- uni-datetime-picker 新增 return-type 属性支持返回 date 日期对象 -- uni-file-picker 修复 fileExtname属性不指定值报错的Bug -- uni-file-picker 修复 在某种场景下图片不回显的Bug -- uni-link 支持自定义插槽 -## 1.3.8(2021-07-31) -- uni-ui 组件兼容 vue3 -- uni-collapse 修复 由1.2.0版本引起的 change 事件返回 undefined 的Bug -- uni-collapse 优化 组件示例 -- uni-collapse 新增 组件折叠动画 -- uni-collapse 新增 value\v-model 属性 ,动态修改面板折叠状态 -- uni-collapse 新增 title 插槽 ,可定义面板标题 -- uni-collapse 新增 border 属性 ,显示隐藏面板内容分隔线 -- uni-collapse 新增 title-border 属性 ,显示隐藏面板标题分隔线 -- uni-collapse 修复 resize 方法失效的Bug -- uni-collapse 修复 change 事件返回参数不正确的Bug -- uni-collapse 优化 H5、App 平台自动更具内容更新高度,无需调用 reszie() 方法 -- uni-data-checkbox 优化 在uni-forms组件,与label不对齐的问题 -- uni-data-checkbox 修复 单选默认值为0不能选中的Bug -- uni-easyinput 优化 errorMessage 属性支持 Boolean 类型 -- uni-file-picker 修复 return-type为object下,返回值不正确的Bug -- uni-file-picker 修复(重要) H5 平台下如果和uni-forms组件一同使用导致页面卡死的问题 -- uni-file-picker 优化 h5平台下上传文件导致页面卡死的问题 -- uni-forms 修复 vue2 下条件编译导致destroyed生命周期失效的Bug -- uni-forms 修复 1.2.1 引起的示例在小程序平台报错的Bug -- uni-forms 修复 动态校验表单,默认值为空的情况下校验失效的Bug -- uni-forms 修复 不指定name属性时,运行报错的Bug -- uni-forms 优化 label默认宽度从65调整至70,使required为true且四字时不换行 -- uni-forms 优化 组件示例,新增动态校验示例代码 -- uni-forms 优化 组件文档,使用方式更清晰 -- uni-list 修复 与其他组件嵌套使用时,点击失效的Bug -- uni-swipe-action 修复 跨页面修改组件数据 ,导致不能滑动的问题 -## 1.3.7(2021-07-16) -- uni-ui 兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) -- uni-datetime-picker 修复 单选日期类型,初始赋值后不在当前日历的 bug -- uni-datetime-picker 新增 clearIcon 属性,显示框的清空按钮可配置显示隐藏(仅 pc 有效) -- uni-datetime-picker 优化 移动端移除显示框的清空按钮,无实际用途 -- uni-datetime-picker 修复 组件赋值为空,界面未更新的 bug -- uni-datetime-picker 修复 start 和 end 不能动态赋值的 bug -- uni-datetime-picker 修复 范围选类型,用户选择后再次选择右侧日历(结束日期)显示不正确的 bug -## 1.3.6(2021-07-09) -- uni-data-checkbox 优化 删除无用日志 -- uni-data-checkbox 修复 由 0.1.9 引起的非 nvue 端图标不显示的问题 -- uni-data-checkbox 修复 nvue 黑框样式问题 -- uni-datetime-picker 修复 范围选择不能动态赋值的 bug -- uni-datetime-picker 修复 范围选择的初始时间在一个月内时,造成无法选择的bug -- uni-datetime-picker 优化 弹出层在超出视窗边缘定位不准确的问题 -- uni-datetime-picker 修复 范围起始点样式的背景色与今日样式的字体前景色融合,导致日期字体看不清的 bug -- uni-datetime-picker 优化 弹出层在超出视窗边缘被遮盖的问题 -- uni-datetime-picker 新增 maskClick 事件 -- uni-datetime-picker 修复 特殊情况日历 rpx 布局错误的 bug,rpx -> px -- uni-datetime-picker 修复 范围选择时清空返回值不合理的bug,['', ''] -> [] -- uni-datetime-picker 新增 日期时间显示框支持插槽 -- uni-file-picker 修复 sourceType 缺少默认值导致 ios 无法选择文件 -- uni-file-picker 优化 解耦与uniCloud的强绑定关系 ,如不绑定服务空间,默认autoUpload为false且不可更改 -- uni-table 新增 uni-th 支持 date 日期筛选范围 -- uni-table 新增 uni-th 支持 range 筛选范围 -- uni-table 新增 uni-th 筛选功能 -## 1.3.5(2021-07-02) -- uni-card 优化 图文卡片无图片加载时,提供占位图标 -- uni-card 新增 header 插槽,自定义卡片头部( 图文卡片 mode="style" 时,不支持) -- uni-card 修复 thumbnail 不存在仍然占位的 bug -- uni-data-checkbox 修复 selectedTextColor 属性不生效的Bug -- uni-datetime-picker 优化 添加 uni-icons 依赖 -- uni-easyinput 修复 confirmType 属性(仅 type="text" 生效)导致多行文本框无法换行的 bug -- uni-file-picker 修复 由 0.0.10 版本引发的 returnType 属性失效的问题 -- uni-file-picker 优化 文件上传后进度条消失时机 -- uni-file-picker 修复 在uni-forms 中,删除文件 ,获取的值不对的Bug -- uni-forms 修复 pattern 属性在微信小程序平台无效的问题 -## 1.3.4(2021-06-25) -- uni-badge 优化 示例项目 -- uni-countdown 修复 uni-countdown 重复赋值跳两秒的 bug -- uni-easyinput 修复 passwordIcon 属性拼写错误的 bug -- uni-forms 修复 validate-trigger属性为submit且err-show-type属性为toast时不能弹出的Bug -- uni-forms 修复 只写setRules方法而导致校验不生效的Bug -- uni-forms 修复 由上个办法引发的错误提示文字错位的Bug -- uni-forms 修复 不设置 label 属性 ,无法设置label插槽的问题 -- uni-forms 修复 不设置label属性,label-width属性不生效的bug -- uni-forms 修复 setRules 方法与rules属性冲突的问题 -- uni-link 新增 download 属性,H5平台下载文件名 -- uni-popup 新增 mask-click 遮罩层点击事件 -- uni-popup 修复 nvue 平台中间弹出后,点击内容,再点击遮罩无法关闭的Bug -- uni-tag 修复 uni-tag 在字节跳动小程序上 css 类名编译错误的 bug -## 1.3.3(2021-06-18) -- uni-easyinput 新增 passwordIcon 属性,当type=password时是否显示小眼睛图标 -- uni-easyinput 修复 confirmType 属性不生效的问题 -- uni-easyinput 修复 disabled 状态可清出内容的 bug -- uni-file-picker 修复 删除文件时无法触发 v-model 的Bug -- uni-popup 修复 H5平台中间弹出后,点击内容,再点击遮罩无法关闭的Bug -- uni-popup 修复 错误的 watch 字段 -- uni-popup 修复 safeArea 属性不生效的问题 -- uni-popup 修复 点击内容,再点击遮罩无法关闭的Bug -## 1.3.2(2021-06-04) -- uni-data-checkbox 新增 map 属性,可以方便映射text/value属性 -- uni-data-checkbox 修复 不关联服务空间的情况下组件报错的Bug -- uni-data-picker 修复 上个版本引出的本地数据无法选择带有children的2级节点 -- uni-forms 修复 动态删减数据导致报错的问题 -- uni-forms 新增 modelValue 属性 ,value 即将废弃 -- uni-forms 新增 uni-forms-item 可以设置单独的 rules -- uni-forms 新增 validate 事件增加 keepitem 参数,可以选择那些字段不过滤 -- uni-forms 优化 submit 事件重命名为 validate -- uni-data-picker 修复 无法加载云端数据的问题 -- uni-data-picker 修复 v-model无效问题 -- uni-data-picker 修复 loaddata 为空数据组时加载时间过长问题 -- uni-datetime-picker 修复 图标在小程序上不显示的 bug -- uni-datetime-picker 优化 重命名引用组件,避免潜在组件命名冲突 -- uni-datetime-picker 优化 代码目录扁平化 -- uni-tag 修复 未定义 sass 变量 "$uni-color-royal" 的bug -## 1.3.1(2021-05-14) -- uni-badge 新增 uni-badge 的 absolute 属性,支持定位 -- uni-badge 新增 uni-badge 的 offset 属性,支持定位偏移 -- uni-badge 新增 uni-badge 的 is-dot 属性,支持仅显示有一个小点 -- uni-badge 新增 uni-badge 的 max-num 属性,支持自定义封顶的数字值,超过 99 显示99+ -- uni-badge 优化 uni-badge 属性 custom-style, 支持以对象形式自定义样式 -- uni-badge 修复 uni-badge 在 App 端,数字小于10时不是圆形的bug -- uni-badge 修复 uni-badge 在父元素不是 flex 布局时,宽度缩小的bug -- uni-badge 新增 uni-badge 属性 custom-style, 支持自定义样式 -- uni-datetime-picker 修复 ios 下不识别 '-' 日期格式的 bug -- uni-datetime-picker 优化 pc 下弹出层添加边框和阴影 -- uni-datetime-picker 修复 在 admin 中获取弹出层定位错误的bug -- uni-datetime-picker 修复 type 属性向下兼容,默认值从 date 变更为 datetime -- uni-datetime-picker 支持日历形式的日期+时间的范围选择 -- uni-steps 修复 uni-steps 横向布局时,多行文字高度不合理的 bug -- uni-countdown 修复 uni-countdown 不能控制倒计时的 bug -- uni-tag 修复 royal 类型无效的bug -- uni-tag 修复 uni-tag 宽度不自适应的bug -- uni-tag 新增 uni-tag 支持属性 custom-style 自定义样式 -- uni-link 新增 href 属性支持 tel:|mailto: -- uni-popup 修复 组件内放置 input 、textarea 组件,无法聚焦的问题 -- uni-popup 新增 type 属性的 left\right 值,支持左右弹出 -- uni-popup 新增 open(String:type) 方法参数 ,可以省略 type 属性 ,直接传入类型打开指定弹窗 -- uni-popup 新增 backgroundColor 属性,可定义主窗口背景色,默认不显示背景色 -- uni-popup 新增 safeArea 属性,是否适配底部安全区 -- uni-popup 修复 App\h5\微信小程序底部安全区占位不对的Bug -- uni-popup 修复 App 端弹出等待的Bug -- uni-popup 优化 提升低配设备性能,优化动画卡顿问题 -- uni-popup 优化 更简单的组件自定义方式 -- uni-table 修复 示例项目缺少组件的Bug -- uni-forms 修复 自定义检验器失效的问题 -- uni-title 修复 示例项目缺少组件的Bug -- uni-transition 修复 示例项目缺少组件的Bug -- uni-swiper-dot 修复 示例项目缺少组件的Bug -- uni-ui 新增 组件示例地址 -## 1.3.0(2021-04-23) -- uni-combox 优化 添加依赖 uni-icons, 导入后自动下载依赖 -- uni-data-picker 修复 非树形数据有 where 属性查询报错的问题 -- uni-fav 优化 添加依赖 uni-icons, 导入后自动下载依赖 -- uni-goods-nav 优化 添加依赖 uni-icons, 导入后自动下载依赖 -- uni-nav-bar 优化 添加依赖 uni-icons, 导入后自动下载依赖 -- uni-notice-bar 优化 添加依赖 uni-icons, 导入后自动下载依赖 -- uni-number-box 修复 uni-number-box 浮点数运算不精确的 bug -- uni-number-box 修复 uni-number-box change 事件触发不正确的 bug -- uni-number-box 新增 uni-number-box v-model 双向绑定 -- uni-rate 修复 布局变化后 uni-rate 星星计算不准确的 bug -- uni-rate 优化 添加依赖 uni-icons, 导入 uni-rate 自动下载依赖 -- uni-search-bar 优化 添加依赖 uni-icons, 导入后自动下载依赖 -- uni-steps 优化 添加依赖 uni-icons, 导入后自动下载依赖 -- uni-transition 新增 通过方法自定义动画 -- uni-transition 新增 custom-class 非 NVUE 平台支持自定义 class 定制样式 -- uni-transition 优化 动画触发逻辑,使动画更流畅 -- uni-transition 优化 支持单独的动画类型 -- uni-transition 优化 文档示例 -## 1.2.13(2021-04-16) -- uni-ui 新增 uni-data-picker 支持云端非树形表结构数据 -- uni-ui 修复 uni-data-checkbox nvue 下无法选中的问题 -- uni-ui 修复 uni-data-picker 根节点 parent_field 字段等于null时选择界面错乱问题 -- uni-ui 修复 uni-file-picker 选择的文件非 file-extname 字段指定的扩展名报错的Bug -- uni-ui 修复 uni-swipe-action 报错 nv_navigator is not defined 的bug -- uni-ui 修复 uni-load-more 在首页使用时,h5 平台报 'uni is not defined' 的 bug -- uni-ui 优化 uni-file-picker file-extname 字段支持字符串写法,多个扩展名需要用逗号分隔 -- uni-ui 优化 uni-pagination PC 和 移动端适配不同的 ui -- uni-ui 更新 uni-file-picker 组件示例 -- uni-ui 修复 uni-nav-bar 当 fixed 属性为 true 时铺不满屏幕的 bug -- uni-ui 新增 uni-search-bar 的 focus 事件 -- uni-ui 修复 uni-rate 属性 margin 值为 string 组件失效的 bug -- uni-data-picker 修复 本地数据概率无法回显时问题 -- uni-table 新增 sortable 属性,是否开启单列排序 -- uni-table 优化 表格多选逻辑 -## 1.2.12(2021-03-23) -- uni-ui 新增 uni-datetime-picker 的 hide-second 属性、border 属性; -- uni-ui 修复 uni-datetime-picker 选择跟显示的日期不一样的 bug, -- uni-ui 修复 uni-datetime-picker change事件触发2次的 bug -- uni-ui 修复 uni-datetime-picker 分、秒 end 范围错误的 bug -- uni-ui 新增 uni-tr selectable 属性,用于 type=selection 时,设置某行是否可由全选按钮控制 -- uni-ui 新增 uni-data-checkbox 新增 disabled属性,支持nvue -- uni-ui 优化 uni-data-checkbox 无选项时提示“暂无数据” -- uni-ui 优化 uni-data-checkbox 默认颜色显示 -- uni-ui 新增 uni-link href 属性支持 tel:|mailto: -- uni-ui 新增 uni-table 示例demo -- uni-ui 修复 uni-data-picker 微信小程序某些情况下无法选择的问题,事件无法触发的问题 -- uni-ui 修复 uni-nav-bar easycom 下,找不到 uni-status-bar 的bug -- uni-ui 修复 uni-easyinput 示例在 qq 小程序上的bug -- uni-ui 修复 uni-forms 动态显示uni-forms-item的情况下,submit 方法获取值错误的Bug -- uni-ui 调整 cli 项目 建议使用 easycom 方式引用组件,如使用按需引用,需手动维护组件内部引用 - -## 1.2.11(2021-02-24) -- 调整为uni_modules目录规范 -- uni-data-picker 新增 数据驱动的picker选择器 -- uni-file-picker 新增 文件选择上传 -- uni-row 新增 栅格系统 -- uni-data-checkbox 优化 支持 nvue -- uni-forms 修复 偶发性获取表单值错误的Bug -- uni-forms 修复 校验 uni-data-picker value 为 0 时,返回值错误的Bug -- uni-forms 修复 uni-forms-item 组件隐藏时依然触发校验的bug -- uni-forms 优化 实时校验 -- uni-forms 优化 兼容nvue页面 -- uni-easyinput 优化 兼容nvue页面 -- uni-group 优化 兼容nvue页面 -- uni-popup 优化 组件适配 PC -- uni-fab 优化 适配 PC -- uni-swiper-dot 优化 适配 PC -- uni-rate 优化 适配 PC -- uni-notice-bar 优化 适配 PC -- uni-indexed-list 优化 适配 PC -- uni-combox 优化 适配 PC -- uni-transition 优化 适配 PC -- uni-nav-bar 优化 适配 PC -- uni-swipe-action 优化 适配 PC diff --git a/blog-uniapp/uni_modules/uni-ui/components/uni-ui/uni-ui.vue b/blog-uniapp/uni_modules/uni-ui/components/uni-ui/uni-ui.vue deleted file mode 100644 index 0970892f..00000000 --- a/blog-uniapp/uni_modules/uni-ui/components/uni-ui/uni-ui.vue +++ /dev/null @@ -1,7 +0,0 @@ - - - diff --git a/blog-uniapp/uni_modules/uni-ui/package.json b/blog-uniapp/uni_modules/uni-ui/package.json deleted file mode 100644 index f9c152e5..00000000 --- a/blog-uniapp/uni_modules/uni-ui/package.json +++ /dev/null @@ -1,129 +0,0 @@ -{ - "id": "uni-ui", - "displayName": "uni-ui", - "version": "1.4.20", - "description": "uni-ui 是基于uni-app的、全端兼容的、高性能UI框架", - "keywords": [ - "uni-ui", - "uniui", - "UI组件库", - "ui框架", - "ui库" -], - "repository": "https://github.com/dcloudio/uni-ui", - "engines": { - "HBuilderX": "^3.2.10" - }, - "directories": { - "example": "../../temps/example_temps" - }, - "dcloudext": { - "category": [ - "前端组件", - "通用组件" - ], - "sale": { - "regular": { - "price": "0.00" - }, - "sourcecode": { - "price": "0.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" - }, - "uni_modules": { - "dependencies": [ - "uni-badge", - "uni-calendar", - "uni-card", - "uni-collapse", - "uni-combox", - "uni-countdown", - "uni-data-checkbox", - "uni-data-picker", - "uni-dateformat", - "uni-datetime-picker", - "uni-drawer", - "uni-easyinput", - "uni-fab", - "uni-fav", - "uni-file-picker", - "uni-forms", - "uni-goods-nav", - "uni-grid", - "uni-group", - "uni-icons", - "uni-indexed-list", - "uni-link", - "uni-list", - "uni-load-more", - "uni-nav-bar", - "uni-notice-bar", - "uni-number-box", - "uni-pagination", - "uni-popup", - "uni-rate", - "uni-row", - "uni-search-bar", - "uni-segmented-control", - "uni-steps", - "uni-swipe-action", - "uni-swiper-dot", - "uni-table", - "uni-tag", - "uni-title", - "uni-transition" - ], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "y", - "aliyun": "y" - }, - "client": { - "App": { - "app-vue": "y", - "app-nvue": "y" - }, - "H5-mobile": { - "Safari": "y", - "Android Browser": "y", - "微信浏览器(Android)": "y", - "QQ浏览器(Android)": "y" - }, - "H5-pc": { - "Chrome": "y", - "IE": "y", - "Edge": "y", - "Firefox": "y", - "Safari": "y" - }, - "小程序": { - "微信": "y", - "阿里": "y", - "百度": "y", - "字节跳动": "y", - "QQ": "y", - "京东": "u" - }, - "快应用": { - "华为": "u", - "联盟": "u" - }, - "Vue": { - "vue2": "y", - "vue3": "y" - } - } - } - } -} \ No newline at end of file diff --git a/blog-uniapp/uni_modules/uni-ui/readme.md b/blog-uniapp/uni_modules/uni-ui/readme.md deleted file mode 100644 index 23f84568..00000000 --- a/blog-uniapp/uni_modules/uni-ui/readme.md +++ /dev/null @@ -1,247 +0,0 @@ -> 当前插件不包含示例页面 ,如需示例请在 HBuiderX 中新建 `hello uni-app > 扩展组件` 中查看 -> -> 代码示例地址 :[https://ext.dcloud.net.cn/plugin?id=4941](https://ext.dcloud.net.cn/plugin?id=4941) -> -> 组件演示地址:[https://hellouniapp.dcloud.net.cn](https://hellouniapp.dcloud.net.cn/pages/extUI/badge/badge) -> -> 组件文档地址:[https://uniapp.dcloud.io/component/uniui/uni-ui](https://uniapp.dcloud.io/component/uniui/uni-ui) - -# uni-ui 介绍 - -## uni-ui产品特点 - -### 1. 高性能 - -目前为止,在小程序和混合app领域,暂时还没有比 `uni-ui` 更高性能的框架。 -- 自动差量更新数据 - -虽然uni-app支持小程序自定义组件,所有小程序的ui库都可以用。但小程序自定义组件的ui库都需要使用setData手动更新数据,在大数据量时、或高频更新数据时,很容易产生性能问题。 - -而 `uni-ui` 属于vue组件,uni-app引擎底层自动diff更新数据。当然其实插件市场里众多vue组件都具备这个特点。 -- 优化逻辑层和视图层通讯折损 - -非H5,不管是小程序还是App,不管是app的webview渲染还是原生渲染,全都是逻辑层和视图层分离的。这里就有一个逻辑层和视图层通讯的折损问题。 -比如在视图层拖动一个可跟手的组件,由于通讯的损耗,用js监听很难做到实时跟手。 - -这时就需要使用css动画以及平台底层提供的wxs、bindingx等技术。不过这些技术都比较复杂,所以 `uni-ui` 里做了封装,在需要跟手式操作的ui组件,比如swiperaction列表项左滑菜单,就在底层使用了这些技术,实现了高性能的交互体验 -- 背景停止 - -很多ui组件是会一直动的,比如轮播图、跑马灯。即便这个窗体被新窗体挡住,它在背景层仍然在消耗着硬件资源。在Android的webview版本为chrome66以上,背景操作ui会引发很严重的性能问题,造成前台界面明显卡顿。 - -而 `uni-ui` 的组件,会自动判断自己的显示状态,在组件不再可见时,不会再消耗硬件资源。 - -### 2. 全端 - - `uni-ui` 的组件都是多端自适应的,底层会抹平很多小程序平台的差异或bug。 - -比如导航栏navbar组件,会自动处理不同端的状态栏。 -比如swiperaction组件,在app和微信小程序上会使用交互体验更好的wxs技术,但在不支持wxs的其他小程序端会使用js模拟类似效果。 - - `uni-ui` 还支持nvue原生渲染,[详见](https://github.com/dcloudio/uni-ui/tree/nvue-uni-ui) - -未来 `uni-ui` 还会支持pc等大屏设备。 - -### 3. 与uni统计自动集成实现免打点 - -uni统计是优秀的多端统计平台,见[tongji.dcloud.net.cn](https://tongji.dcloud.net.cn)。 - -除了一张报表看全端,它的另一个重要特点是免打点。 -比如使用 `uni-ui` 的navbar标题栏、收藏、购物车等组件,均可实现自动打点,统计页面标题等各种行为数据。 -当然你也可以关闭uni统计,这不是强制的。 - -### 4. 主题扩展 - - `uni-ui` 支持[uni.scss](https://uniapp.dcloud.io/collocation/uni-scss),可以方便的切换App的风格。 - -ui是一种需求非常发散的产品,DCloud官方也无意用 `uni-ui` 压制第三方ui插件的空间,但官方有义务在性能和多端方面提供一个开源的标杆给大家。 - -我们欢迎更多优秀的ui组件出现,也欢迎更多人贡献 `uni-ui` 的主题风格,满足更多用户的需求。 - - -## 快速开始 - -uni-ui支持 HBuilderX直接新建项目模板、npm安装和单独导入个别组件等多种使用方式 - -### 在HBuilderX 新建uni-app项目的模板中,选择uni-ui模板 -![HBuilderX内创建uni-ui项目](https://img.cdn.aliyun.dcloud.net.cn/uni-app/doc/create-uni-ui-project.jpg) - -由于uni-app独特的[easycom](https://uniapp.dcloud.io/collocation/pages?id=easycom)技术,可以免引用、注册,直接使用各种符合规则的vue组件。 - -在代码区键入`u`,拉出各种内置或uni-ui的组件列表,选择其中一个,即可使用该组件。 - -光标放在组件名称上,按F1,可以查阅组件的文档。 - -![uni-ui代码块](https://img.cdn.aliyun.dcloud.net.cn/uni-app/doc/uni-ui-snippet.jpg) - -### 通过 uni_modules 单独安装组件 -如果你没有创建uni-ui项目模板,也可以在你的工程里,通过 uni_modules 单独安装需要的某个组件。下表为uni-ui的扩展组件清单,点击每个组件在详情页面可以导入组件到项目下,导入后直接使用即可,无需import和注册。 - -|组件名|组件说明| -|---|---| -|uni-badge|[数字角标](https://ext.dcloud.net.cn/plugin?name=uni-badge)| -|uni-calendar|[日历](https://ext.dcloud.net.cn/plugin?name=uni-calendar)| -|uni-card|[卡片](https://ext.dcloud.net.cn/plugin?name=uni-card)| -|uni-collapse|[折叠面板](https://ext.dcloud.net.cn/plugin?name=uni-collapse)| -|uni-combox|[组合框](https://ext.dcloud.net.cn/plugin?name=uni-combox)| -|uni-countdown|[倒计时](https://ext.dcloud.net.cn/plugin?name=uni-countdown)| -|uni-data-checkbox|[数据选择器](https://ext.dcloud.net.cn/plugin?name=uni-data-checkbox)| -|uni-data-picker|[数据驱动的picker选择器](https://ext.dcloud.net.cn/plugin?name=uni-data-picker)| -|uni-dateformat|[日期格式化](https://ext.dcloud.net.cn/plugin?name=uni-dateformat)| -|uni-datetime-picker|[日期选择器](https://ext.dcloud.net.cn/plugin?name=uni-datetime-picker)| -|uni-drawer|[抽屉](https://ext.dcloud.net.cn/plugin?name=uni-drawer)| -|uni-easyinput|[增强输入框](https://ext.dcloud.net.cn/plugin?name=uni-easyinput)| -|uni-fab|[悬浮按钮](https://ext.dcloud.net.cn/plugin?name=uni-fab)| -|uni-fav|[收藏按钮](https://ext.dcloud.net.cn/plugin?name=uni-fav)| -|uni-file-picker|[文件选择上传](https://ext.dcloud.net.cn/plugin?name=uni-file-picker)| -|uni-forms|[表单](https://ext.dcloud.net.cn/plugin?name=uni-forms)| -|uni-goods-nav|[商品导航](https://ext.dcloud.net.cn/plugin?name=uni-goods-nav)| -|uni-grid|[宫格](https://ext.dcloud.net.cn/plugin?name=uni-grid)| -|uni-group|[分组](https://ext.dcloud.net.cn/plugin?name=uni-group)| -|uni-icons|[图标](https://ext.dcloud.net.cn/plugin?name=uni-icons)| -|uni-indexed-list|[索引列表](https://ext.dcloud.net.cn/plugin?name=uni-indexed-list)| -|uni-link|[超链接](https://ext.dcloud.net.cn/plugin?name=uni-link)| -|uni-list|[列表](https://ext.dcloud.net.cn/plugin?name=uni-list)| -|uni-load-more|[加载更多](https://ext.dcloud.net.cn/plugin?name=uni-load-more)| -|uni-nav-bar|[自定义导航栏](https://ext.dcloud.net.cn/plugin?name=uni-nav-bar)| -|uni-notice-bar|[通告栏](https://ext.dcloud.net.cn/plugin?name=uni-notice-bar)| -|uni-number-box|[数字输入框](https://ext.dcloud.net.cn/plugin?name=uni-number-box)| -|uni-pagination|[分页器](https://ext.dcloud.net.cn/plugin?name=uni-pagination)| -|uni-popup|[弹出层](https://ext.dcloud.net.cn/plugin?name=uni-popup)| -|uni-rate|[评分](https://ext.dcloud.net.cn/plugin?name=uni-rate)| -|uni-row|[布局-行](https://ext.dcloud.net.cn/plugin?name=uni-row)| -|uni-search-bar|[搜索栏](https://ext.dcloud.net.cn/plugin?name=uni-search-bar)| -|uni-segmented-control|[分段器](https://ext.dcloud.net.cn/plugin?name=uni-segmented-control)| -|uni-steps|[步骤条](https://ext.dcloud.net.cn/plugin?name=uni-steps)| -|uni-swipe-action|[滑动操作](https://ext.dcloud.net.cn/plugin?name=uni-swipe-action)| -|uni-swiper-dot|[轮播图指示点](https://ext.dcloud.net.cn/plugin?name=uni-swiper-dot)| -|uni-table|[表格](https://ext.dcloud.net.cn/plugin?name=uni-table)| -|uni-tag|[标签](https://ext.dcloud.net.cn/plugin?name=uni-tag)| -|uni-title|[章节标题](https://ext.dcloud.net.cn/plugin?name=uni-title)| -|uni-transition|[过渡动画](https://ext.dcloud.net.cn/plugin?name=uni-transition)| - - -使用 `uni_modules` 方式安装组件库,可以直接通过插件市场导入,通过右键菜单快速更新组件,不需要引用、注册,直接在页面中使用 `uni-ui` 组件。[点击安装 uni-ui 组件库](https://ext.dcloud.net.cn/plugin?id=55) - -**注意:下载最新的组件目前仅支持 uni_modules ,非 uni_modules 版本最高支持到组件的1.2.10版本** - -如不能升级到 `uni_modules` 版本,可以使用 `uni_modules` 安装好对应组件,将组件拷贝到对应目录。 - -例如需更新 `uni-list`和`uni-badge` ,将 `uni_modules>uni-list>components`和`uni_modules>uni-badege>components`下所有目录拷贝到如下目录即可: - - -**目录示例** - -```json -┌─components 组件目录 -│ ├─uni-list list 列表目录 -│ │ └─uni-list.vue list 组件文件 -│ ├─uni-list-item list-item 列表目录 -│ │ └─uni-list-item.vue list 组件文件 -│ ├─uni-badge badge 角标目录 -│ │ └─uni-badge.vue badge 组件文件 -│ └─ //.... 更多组件文件 -├─pages 业务页面文件存放的目录 -│ ├─index -│ │ └─index.vue index示例页面 -├─main.js Vue初始化入口文件 -├─App.vue 应用配置,用来配置App全局样式以及监听 应用生命周期 -├─manifest.json 配置应用名称、appid、logo、版本等打包信息,详见 -└─pages.json 配置页 - -``` - -### 通过 `uni_modules` 导入全部组件 -如果想一次把所有uni-ui组件导入到项目中,只需要导入一个 `uni-ui` 组件即可 [点击去导入](https://ext.dcloud.net.cn/plugin?id=55)。 - -如果没有自动导入其他组件,可以在 uni-ui 组件目录上右键选择 `安装三方插件依赖` 即可。 - - - -### npm安装 -在 `vue-cli` 项目中可以使用 `npm` 安装 `uni-ui` 库 ,或者直接在 `HBuilderX` 项目中使用 `npm` 。 - -> **注意** -> cli 项目默认是不编译 `node_modules` 下的组件的,导致条件编译等功能失效 ,导致组件异常 -> 需要在根目录创建 `vue.config.js` 文件 ,增加 `@dcloudio/uni-ui` 包的编译即可正常 -> ```javascript -> // vue.config.js -> module.exports = { -> transpileDependencies:['@dcloudio/uni-ui'] -> } -> ``` - - - -**准备 sass** - -`vue-cli` 项目请先安装 sass 及 sass-loader,如在 HBuliderX 中使用,可跳过此步。 - -- 安装 sass -``` - npm i sass -D 或 yarn add sass -D -``` - -- 安装 sass-loader -``` -npm i sass-loader@10.1.1 -D 或 yarn add sass-loader@10.1.1 -D -``` - -> 如果 `node` 版本小于 16 ,sass-loader 请使用低于 @11.0.0 的版本,[sass-loader@11.0.0 不支持 vue@2.6.12 ](https://stackoverflow.com/questions/66082397/typeerror-this-getoptions-is-not-a-function) -> 如果 `node` 版本大于 16 , `sass-loader` 建议使用 `v8.x` 版本 - -**安装 uni-ui** - -``` -npm i @dcloudio/uni-ui 或 yarn add @dcloudio/uni-ui -``` - - - -**配置easycom** - -使用 `npm` 安装好 `uni-ui` 之后,需要配置 `easycom` 规则,让 `npm` 安装的组件支持 `easycom` - -打开项目根目录下的 `pages.json` 并添加 `easycom` 节点: - -```javascript -// pages.json -{ - "easycom": { - "autoscan": true, - "custom": { - // uni-ui 规则如下配置 - "^uni-(.*)": "@dcloudio/uni-ui/lib/uni-$1/uni-$1.vue" - } - }, - - // 其他内容 - pages:[ - // ... - ] -} - -``` - -在 ``template`` 中使用组件: - -```html - - - -``` - - **注意** - - uni-ui 现在只推荐使用 `easycom` ,如自己引用组件,可能会出现组件找不到的问题 - - 使用 npm 安装的组件,默认情况下 babel-loader 会忽略所有 node_modules 中的文件 ,导致条件编译失效,需要通过配置 `vue.config.js` 解决: - ```javascript - // 在根目录创建 vue.config.js 文件,并配置如下 - module.exports = { - transpileDependencies: ['@dcloudio/uni-ui'] - } - ``` - - uni-ui 是uni-app内置组件的扩展。注意与web开发不同,uni-ui不包括基础组件,它是基础组件的补充。web开发中有的开发者习惯用一个ui库完成所有开发,但在uni-app体系中,推荐开发者首先使用性能更高的基础组件,然后按需引入必要的扩展组件。 - - `uni-ui` 不支持使用 `Vue.use()` 的方式安装 - - -### 贡献代码 -在使用 `uni-ui` 中,如遇到无法解决的问题,请提 [Issues](https://github.com/dcloudio/uni-ui/issues) 给我们,假如您有更好的点子或更好的实现方式,也欢迎给我们提交 [PR](https://github.com/dcloudio/uni-ui/pulls) \ No newline at end of file diff --git a/myblog-kt/build.gradle.kts b/myblog-kt/build.gradle.kts index baf7d8d3..334ea2d5 100644 --- a/myblog-kt/build.gradle.kts +++ b/myblog-kt/build.gradle.kts @@ -1,10 +1,11 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile plugins { - id("org.springframework.boot") version "3.1.0" - id("io.spring.dependency-management") version "1.1.0" - kotlin("jvm") version "1.8.21" - kotlin("plugin.spring") version "1.8.21" + alias(libs.plugins.springboot) + alias(libs.plugins.springDependency) + alias(libs.plugins.kapt) + kotlin("jvm") version libs.versions.kotlin + kotlin("plugin.spring") version libs.versions.kotlin } group = "com.site.blog" @@ -19,8 +20,8 @@ configurations { dependencies { - compileOnly ("org.projectlombok:lombok:1.18.24") - annotationProcessor ("org.projectlombok:lombok:1.18.24") + compileOnly ("org.projectlombok:lombok") + annotationProcessor ("org.projectlombok:lombok") implementation("org.springframework.boot:spring-boot-starter-thymeleaf") implementation("org.springframework.boot:spring-boot-starter-web") implementation("org.springframework.boot:spring-boot-starter-aop") @@ -32,11 +33,11 @@ dependencies { implementation("org.jetbrains.kotlin:kotlin-reflect") implementation("org.jetbrains.kotlin:kotlin-stdlib") // https://mvnrepository.com/artifact/com.baomidou/mybatis-plus-boot-starter - implementation("com.baomidou:mybatis-plus-boot-starter:3.5.3.1") + implementation(libs.mybatisPlusBoot) implementation("io.pebbletemplates:pebble-spring-boot-starter:3.2.0") - implementation("org.springdoc:springdoc-openapi-starter-webmvc-ui:2.0.2") + implementation(libs.bundles.utils) // https://mvnrepository.com/artifact/cn.hutool/hutool-all - implementation("cn.hutool:hutool-all:5.8.12") + implementation(libs.hutool) // https://mvnrepository.com/artifact/com.alibaba/druid-spring-boot-starter implementation("com.alibaba:druid-spring-boot-starter:1.2.15") // https://mvnrepository.com/artifact/net.coobird/thumbnailator @@ -56,9 +57,6 @@ dependencies { testImplementation("org.springframework.boot:spring-boot-starter-test") } -repositories { - mavenCentral() -} tasks.withType { kotlinOptions { diff --git a/myblog-kt/gradle/libs.versions.toml b/myblog-kt/gradle/libs.versions.toml new file mode 100644 index 00000000..c63732f1 --- /dev/null +++ b/myblog-kt/gradle/libs.versions.toml @@ -0,0 +1,120 @@ +[versions] +agp = "8.1.1" + +kotlin = "1.9.22" + +[libraries] + +# utils +## network +okhttp3 = { group = "com.squareup.okhttp3", name = "okhttp", version = "4.+" } +okhttp3-logging = "com.squareup.okhttp3:logging-interceptor:4.+" +retrofit = "com.squareup.retrofit2:retrofit:2.9.0" +retrofit-gson = "com.squareup.retrofit2:converter-gson:2.9.0" +mockwebserver = "com.squareup.okhttp3:mockwebserver:4.10.0" +okio = "com.squareup.okio:okio:3.5.0" +netAwesome = "com.github.liangjingkanji:Net:3.6.1" +# apache commons +apiVersion = "com.github.lkqm:spring-api-versioning:1.4.0" +commonsIo = "commons-io:commons-io:2.11.0" +commonsLang3 = "org.apache.commons:commons-lang3:3.13.0" +commonsText = "org.apache.commons:commons-text:1.10.0" +commonsCollections = "org.apache.commons:commons-collections4:4.4" +commonsCodec = "commons-codec:commons-codec:1.16.0" +# // https://mvnrepository.com/artifact/commons-net/commons-net +commonsNet = "commons-net:commons-net:3.10.0" +commonsFileupload="commons-fileupload:commons-fileupload:1.5" + + +fakedata="net.datafaker:datafaker:2.0.2" +httpclient4 = { module = "org.apache.httpcomponents:httpclient" } +httpclient5 = "org.apache.httpcomponents.client5:httpclient5:5.2.1" +httpclient5Fluent = "org.apache.httpcomponents.client5:httpclient5-fluent:5.2.1" +guava = "com.google.guava:guava:31.1-jre" +thumbnailator = "net.coobird:thumbnailator:0.4.20" +jsoup = "org.jsoup:jsoup:1.16.1" + +#dromara +#// https://mvnrepository.com/artifact/cn.hutool/hutool-all +hutool = 'cn.hutool:hutool-all:5.8.22' +satokenBoot = "cn.dev33:sa-token-spring-boot-starter:1.36.0" +satokenBoot3 = "cn.dev33:sa-token-spring-boot3-starter:1.37.0" +satokenRedis = "cn.dev33:sa-token-redis-jackson:1.37.0" +forestBoot = "com.dtflys.forest:forest-spring-boot-starter:1.5.33" +xfileStoreBoot="org.dromara.x-file-storage:x-file-storage-spring:2.0.0" +javaassist="org.javassist:javassist:3.29.2-GA" +lombokModule = { module = "org.projectlombok:lombok", version = "1.18.30" } +springdoc = "org.springdoc:springdoc-openapi-starter-webmvc-ui:2.3.0" +springdoc1 = "org.springdoc:springdoc-openapi-ui:1.7.0" +springDevtools={module="org.springframework.boot:spring-boot-devtools"} +## aop +aspectjTools = "org.aspectj:aspectjtools:1.9.20" +#// https://mvnrepository.com/artifact/org.aspectj/aspectjrt +aspectjrt = "org.aspectj:aspectjrt:1.9.20" + +# json +gson = "com.google.code.gson:gson:latest.release" +# https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind +jackson = "com.fasterxml.jackson.core:jackson-databind:2.15.2" +fastjson = "com.alibaba.fastjson2:fastjson2:2.0.41" + +rxjava3 = "io.reactivex.rxjava3:rxjava:3.1.5" +mybatisPlusBoot = "com.baomidou:mybatis-plus-boot-starter:3.5.5" +mybatisFlexBoot3="com.mybatis-flex:mybatis-flex-spring-boot3-starter:1.7.7" +mybatisFlexBoot="com.mybatis-flex:mybatis-flex-spring-boot-starter:1.7.7" +mybatisFlexAnno="com.mybatis-flex:mybatis-flex-processor:1.7.7" +hikra="com.zaxxer:HikariCP:5.0.1" +#// https://mvnrepository.com/artifact/com.alibaba/druid-spring-boot-starter +druidSpringboot = "com.alibaba:druid-spring-boot-starter:1.2.19" +mapstruct = "org.mapstruct:mapstruct:1.5.5.Final" +# https://mvnrepository.com/artifact/org.mapstruct/mapstruct-processor +mapstructAnno = "org.mapstruct:mapstruct-processor:1.5.5.Final" +javaJwt = "com.auth0:java-jwt:4.3.0" + +# https://mvnrepository.com/artifact/io.jsonwebtoken/jjwt-api +jjwtApi="io.jsonwebtoken:jjwt-api:0.12.3" + +jjwtImpl='io.jsonwebtoken:jjwt-impl:0.12.3' +jjwtJackson='io.jsonwebtoken:jjwt-jackson:0.12.3' +# https://mvnrepository.com/artifact/org.apache.shiro/shiro-spring-boot-web-starter +shiroBoot = "org.apache.shiro:shiro-spring-boot-web-starter:2.0.0-alpha-4" +shiroBoot1Module = { module = "org.apache.shiro:shiro-spring-boot-web-starter" } +problemBoot2 = { module = "org.zalando:problem-spring-web", version = "0.27.0" } +problemBoot3 = { module = "org.zalando:problem-spring-web", version = "0.29.1" } + +#// JSON序列化库, 首选推荐使用 +kotlinxSeriJson = "org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.0" +#// protobuf序列化 +kotlinSeriproto = "org.jetbrains.kotlinx:kotlinx-serialization-protobuf:1.6.0" +#// JSON序列化库, 强校验, JSON字段缺失会导致解析异常, 故不推荐 +moshi = "com.squareup.moshi:moshi-kotlin:1.14.0" +kotlinReflect = { group = "org.jetbrains.kotlin", name = "kotlin-reflect", version.ref = "kotlin" } +kotlinStdlib = { group = "org.jetbrains.kotlin", name = "kotlin-stdlib", version.ref = "kotlin" } +kotlinx-coroutinescore = "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.4" +kotlinx-coroutines-android = "org.jetbrains.kotlinx:kotlinx-coroutines-android:1.6.4" +# rxjava +rxjava2 = "io.reactivex.rxjava2:rxjava:2.2.21" +# picture +nettyAll="io.netty:netty-all:4.1.105.Final" +[plugins] +springDependency = { id = "io.spring.dependency-management", version = "1.1.4" } +springDependency2 = { id = "io.spring.dependency-management", version = "1.0.15.RELEASE" } +springboot2 = { id = "org.springframework.boot", version = "2.7.17" } +springboot = { id = "org.springframework.boot", version = "3.2.1" } +springPlugin = { id = "org.jetbrains.kotlin.plugin.spring", version.ref = "kotlin" } +shadowJar = { id = "com.github.johnrengelman.shadow", version = "8.1.1" } +ksp = { id = "com.google.devtools.ksp", version = "1.9.21-1.0.15" } +jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" } +kapt = { id = "org.jetbrains.kotlin.kapt", version.ref = "kotlin" } +[bundles] +commons = [ + "commonsIo", + "commonsCollections", + "commonsLang3", + "commonsText", + "commonsNet", + "commonsFileupload", + "commonsCodec", + "fakedata" +] +utils = ["springdoc", "apiVersion", "hutool", "guava", "httpclient5Fluent"] diff --git a/myblog-kt/gradle/wrapper/gradle-wrapper.properties b/myblog-kt/gradle/wrapper/gradle-wrapper.properties index fc10b601..829e1a5a 100644 --- a/myblog-kt/gradle/wrapper/gradle-wrapper.properties +++ b/myblog-kt/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-all.zip networkTimeout=10000 zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/myblog-kt/settings.gradle.kts b/myblog-kt/settings.gradle.kts index 81379cfe..195295af 100644 --- a/myblog-kt/settings.gradle.kts +++ b/myblog-kt/settings.gradle.kts @@ -1 +1,17 @@ +pluginManagement { + repositories { + gradlePluginPortal() + google() + mavenCentral() + } +} +dependencyResolutionManagement { + repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) + repositories { + google() + mavenCentral() + } + //注意,重点在这里 + +} rootProject.name = "BlogApp" diff --git a/myblog-server/.vscode/settings.json b/myblog-server/.vscode/settings.json new file mode 100644 index 00000000..0ca4d0be --- /dev/null +++ b/myblog-server/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "java.compile.nullAnalysis.mode": "automatic" +} \ No newline at end of file diff --git a/myblog-server/pom.xml b/myblog-server/pom.xml index 7ecc1e3e..17597dbf 100644 --- a/myblog-server/pom.xml +++ b/myblog-server/pom.xml @@ -13,7 +13,7 @@ org.springframework.boot - 3.1.0 + 3.1.4 spring-boot-starter-parent @@ -21,7 +21,8 @@ UTF-8 UTF-8 - 17 + 21 + 21 true @@ -200,14 +201,14 @@ - - org.apache.maven.plugins - maven-compiler-plugin - - 17 - 17 - - + + + + + + + + org.springframework.boot spring-boot-maven-plugin diff --git a/myblog-server/src/main/java/com/site/blog/mapper/BlogInfoMapper.java b/myblog-server/src/main/java/com/site/blog/mapper/BlogInfoMapper.java index ebaa950d..2a972972 100644 --- a/myblog-server/src/main/java/com/site/blog/mapper/BlogInfoMapper.java +++ b/myblog-server/src/main/java/com/site/blog/mapper/BlogInfoMapper.java @@ -26,4 +26,6 @@ public interface BlogInfoMapper extends BaseMapper { */ @Select("select sum(blog_views) FROM blog_info") Integer getViews(); + + } diff --git a/myblog-server/src/main/java/com/site/blog/mapper/ImgMapper.java b/myblog-server/src/main/java/com/site/blog/mapper/ImgMapper.java index 2f22fb33..c2bf0616 100644 --- a/myblog-server/src/main/java/com/site/blog/mapper/ImgMapper.java +++ b/myblog-server/src/main/java/com/site/blog/mapper/ImgMapper.java @@ -1,5 +1,7 @@ package com.site.blog.mapper; +import java.util.List; + import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.site.blog.model.entity.Img; @@ -9,4 +11,8 @@ * @modified By: */ public interface ImgMapper extends BaseMapper { + + + Integer selectCount(); + List imgs(); } diff --git a/myblog-server/src/main/resources/mapper/ImgMapper.xml b/myblog-server/src/main/resources/mapper/ImgMapper.xml new file mode 100644 index 00000000..69947d22 --- /dev/null +++ b/myblog-server/src/main/resources/mapper/ImgMapper.xml @@ -0,0 +1,17 @@ + + + + + + + + + + + + + diff --git a/myblog-web/package.json b/myblog-web/package.json index 717e534a..d78fa77c 100644 --- a/myblog-web/package.json +++ b/myblog-web/package.json @@ -11,36 +11,36 @@ "dependencies": { "@element-plus/icons-vue": "^2.1.0", "@iconify/vue": "^4.1.1", - "@types/lodash": "^4.14.195", - "@vitejs/plugin-vue": "^4.2.3", - "@vueuse/core": "^10.1.2", - "axios": "^1.4.0", - "dayjs": "^1.11.8", - "echarts": "^5.4.2", - "element-plus": "2.3.6", + "@types/lodash": "^4.14.199", + "@vitejs/plugin-vue": "^4.3.4", + "@vueuse/core": "^10.4.1", + "axios": "^1.5.1", + "dayjs": "^1.11.10", + "echarts": "^5.4.3", + "element-plus": "2.3.14", "filepond": "^4.30.4", "filepond-plugin-file-validate-type": "^1.2.8", "filepond-plugin-image-preview": "^4.6.11", - "md-editor-v3": "^4.1.0", - "pinia": "^2.1.3", - "prettier": "^2.8.8", + "md-editor-v3": "^4.7.0", + "pinia": "^2.1.6", + "prettier": "^3.0.3", "qs": "^6.11.2", "sass": "latest", - "typescript": "^5.1.3", - "unplugin-auto-import": "^0.16.4", - "unplugin-icons": "^0.16.3", - "unplugin-vue-components": "^0.25.1", + "typescript": "^5.2.2", + "unplugin-auto-import": "^0.16.6", + "unplugin-icons": "^0.17.0", + "unplugin-vue-components": "^0.25.2", "v-viewer": "^3.0.11", - "viewerjs": "^1.11.3", + "viewerjs": "^1.11.6", "vue": "^3.3.4", - "vue-cropper": "^1.0.9", - "vue-filepond": "^7.0.3", - "vue-router": "^4.2.2" + "vue-cropper": "^1.1.1", + "vue-filepond": "^7.0.4", + "vue-router": "^4.2.5" }, "devDependencies": { - "@types/node": "^20.3.0", - "@types/qs": "^6.9.7", - "vite": "^4.3.9", - "vue-tsc": "^1.6.5" + "@types/node": "^20.8.0", + "@types/qs": "^6.9.8", + "vite": "^4.4.9", + "vue-tsc": "^1.8.15" } }