uview-ultra 4.5.46 → 4.5.48

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -8,6 +8,7 @@
8
8
  [![Website](https://img.shields.io/badge/nvue-compatible-green)](https://uview-ultra.lingyun.net/)
9
9
  [![Website](https://img.shields.io/badge/vue-compatible-green)](https://uview-ultra.lingyun.net/)
10
10
  [![Website](https://img.shields.io/badge/build-passing-green)](https://uview-ultra.lingyun.net/)
11
+ [![npm](https://img.shields.io/npm/v/uview-ultra.svg)](https://www.npmjs.com/package/uview-ultra)
11
12
 
12
13
 
13
14
 
@@ -61,6 +62,51 @@
61
62
 
62
63
  #### **uni-app插件市场链接** —— [https://ext.dcloud.net.cn/plugin?name=uview-ultra](https://ext.dcloud.net.cn/plugin?name=uview-ultra)
63
64
 
65
+ #### **npm(uni-app CLI 工程)**
66
+
67
+ ```bash
68
+ npm i uview-ultra
69
+ ```
70
+
71
+ npm 方式安装不会自动写入 easycom 规则,需要在 `pages.json` 里自己加一条
72
+ (插件市场安装会自动配好):
73
+
74
+ ```json
75
+ {
76
+ "easycom": {
77
+ "autoscan": true,
78
+ "custom": {
79
+ "^up-(.*)": "uview-ultra/components/up-$1/up-$1.vue"
80
+ }
81
+ }
82
+ }
83
+ ```
84
+
85
+ 并在 `main.js` 里挂载插件、引入全局样式:
86
+
87
+ ```js
88
+ import uviewUltra from 'uview-ultra'
89
+ import 'uview-ultra/index.scss'
90
+
91
+ export function createApp() {
92
+ const app = createSSRApp(App)
93
+ app.use(uviewUltra)
94
+ return { app }
95
+ }
96
+ ```
97
+
98
+ 全局样式也可以不写在 `main.js`,改到 `App.vue` 的 `<style lang="scss">` 里:
99
+
100
+ ```html
101
+ <style lang="scss">
102
+ @import 'uview-ultra/index.scss';
103
+ </style>
104
+ ```
105
+
106
+ > npm 包的入口是 `index.js`(uni-app / Vue3 的实现)。
107
+ > **uni-app x 工程请用插件市场安装** —— 它走的是 `.uvue` 那套实现,
108
+ > 而 npm 包同时包含 `.vue` 与 `.uvue` 两份源码,混用容易装错组件。
109
+
64
110
  ## 快速上手
65
111
 
66
112
  请通过[快速上手](https://uview-ultra.lingyun.net/components/quickstart.html)了解更详细的内容
package/changelog.md CHANGED
@@ -1,3 +1,17 @@
1
+ ## 4.5.48
2
+ fix: 修复 up-tabs-pro、up-novel-reader Vue 版微信小程序编译报错
3
+
4
+ - up-tabs-pro(.vue):移除原生 view 上不受小程序编译器支持的对象形式 v-bind="$attrs",修复 v-bind="" is not supported. 报错。
5
+ - 同时恢复默认根节点属性继承,保留 H5 下 id、data-*、外部 class/style 及原生事件绑定;组件 props、事件、插槽 API 与 .uvue 实现保持不变。
6
+ - up-novel-reader(.vue):error 插槽改为显式传递 error、retry,修复对象形式 v-bind 导致的微信小程序编译报错;保留错误对象、重试回调、默认错误提示和重试按钮,插槽 API 与 .uvue 实现不变。
7
+
8
+ ## 4.5.47
9
+ fix: 修复导航栏胶囊遮挡、条码画布初始化时序并补齐类型导出
10
+
11
+ - up-navbar(.vue / .uvue):新增默认开启的 avoidCapsule,微信小程序右侧文字、图标及插槽内容自动避让原生胶囊;设置 :avoidCapsule="false" 可恢复原布局,其他平台和胶囊信息无效时保持原布局。同步 JS/UTS 默认配置、props 和类型声明。
12
+ - up-barcode:.vue 画布渲染、.uvue 图片生成及导出在创建或查询画布前等待组件宿主视图完成更新,避免全局 nextTick 已结束但画布节点或尺寸尚未提交;.uvue 默认 View 条码展示逻辑不变。
13
+ - 类型入口:补齐 FormValidateError、NumberBoxFocusPayload、NumberBoxChangePayload、PaginationProps、VideoEpisode、VideoAd、VideoDanmu、VideoProps 共 8 个已有类型的导出,修复包入口 import type 报未导出成员及类型导出一致性校验失败。
14
+
1
15
  ## 4.5.46
2
16
  fix: 修复 uni-app Vue3(.js/.vue)侧无法编译与运行的 12 处问题,并补全 168 处导入扩展名
3
17