uview-plus 3.5.0 → 3.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/changelog.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<view class="u-calendar-month-wrapper" ref="u-calendar-month-wrapper">
|
|
3
3
|
<view v-for="(item, index) in months" :key="index" :class="[`u-calendar-month-${index}`]"
|
|
4
4
|
:ref="`u-calendar-month-${index}`" :id="`month-${index}`">
|
|
5
|
-
<text v-if="index !== 0" class="u-calendar-month__title">{{ item
|
|
5
|
+
<text v-if="index !== 0" class="u-calendar-month__title">{{ monthTitle(item) }}</text>
|
|
6
6
|
<view class="u-calendar-month__days">
|
|
7
7
|
<view v-if="showMark" class="u-calendar-month__days__month-mark-wrapper">
|
|
8
8
|
<text class="u-calendar-month__days__month-mark-wrapper__text">{{ item.month }}</text>
|
|
@@ -307,6 +307,13 @@
|
|
|
307
307
|
})
|
|
308
308
|
})
|
|
309
309
|
},
|
|
310
|
+
monthTitle(item) {
|
|
311
|
+
if (uni.getLocale() == 'zh-Hans' || uni.getLocale() == 'zh-Hant') {
|
|
312
|
+
return item.year + '年' + (item.month < 10 ? '0' + item.month : item.month) + '月'
|
|
313
|
+
} else {
|
|
314
|
+
return (item.month < 10 ? '0' + item.month : item.month) + '/' + item.year
|
|
315
|
+
}
|
|
316
|
+
},
|
|
310
317
|
isForbid(item) {
|
|
311
318
|
let date = dayjs(item.date).format("YYYY-MM-DD")
|
|
312
319
|
if (this.mode !== 'range' && this.forbidDays.includes(date)) {
|
|
@@ -44,6 +44,7 @@
|
|
|
44
44
|
:allowSameDay="allowSameDay"
|
|
45
45
|
:forbidDays="forbidDays"
|
|
46
46
|
:forbidDaysToast="forbidDaysToast"
|
|
47
|
+
:monthFormat="monthFormat"
|
|
47
48
|
ref="month"
|
|
48
49
|
@monthSelected="monthSelected"
|
|
49
50
|
@updateMonthTop="updateMonthTop"
|
|
@@ -186,9 +187,11 @@ export default {
|
|
|
186
187
|
subtitle() {
|
|
187
188
|
// 初始化时,this.months为空数组,所以需要特别判断处理
|
|
188
189
|
if (this.months.length) {
|
|
189
|
-
|
|
190
|
-
this.months[this.monthIndex].month
|
|
191
|
-
}
|
|
190
|
+
if (uni.getLocale() == 'zh-Hans' || uni.getLocale() == 'zh-Hant') {
|
|
191
|
+
return this.months[this.monthIndex].year + '年' + (this.months[this.monthIndex].month < 10 ? '0' + this.months[this.monthIndex].month : this.months[this.monthIndex].month) + '月'
|
|
192
|
+
} else {
|
|
193
|
+
return (this.months[this.monthIndex].month < 10 ? '0' + this.months[this.monthIndex].month : this.months[this.monthIndex].month) + '/' + this.months[this.monthIndex].year
|
|
194
|
+
}
|
|
192
195
|
} else {
|
|
193
196
|
return ''
|
|
194
197
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "uview-plus",
|
|
3
3
|
"name": "uview-plus",
|
|
4
4
|
"displayName": "零云®uview-plus3.0重磅发布,全面的Vue3鸿蒙跨端移动组件库,组件丰富维护更新稳定。",
|
|
5
|
-
"version": "3.5.
|
|
5
|
+
"version": "3.5.1",
|
|
6
6
|
"description": "零云®uview-plus已兼容vue3支持多语言,100+全面的组件和便捷的工具会让您信手拈来。近期新增拖动排序、条码、图片裁剪、下拉刷新、虚拟列表、签名、Markdown等。",
|
|
7
7
|
"keywords": [
|
|
8
8
|
"uview",
|