(component): 发布 1.7.0-alpha.1 版本

This commit is contained in:
就眠儀式
2022-10-23 21:12:06 +08:00
parent 1f6f25bdfb
commit 91c3d1406d
6 changed files with 9 additions and 12 deletions

View File

@@ -1,6 +1,6 @@
{
"name": "@layui/layui-vue",
"version": "1.7.0-dev.20",
"version": "1.7.0-alpha.1",
"author": "就眠儀式",
"license": "MIT",
"description": "a component library for Vue 3 base on layui-vue",

View File

@@ -43,7 +43,7 @@ const slots = useSlots();
const maxPage = ref(0);
const limits = ref(props.limits);
const pages = Math.floor(props.pages / 2);
const pages = computed(() => Math.floor(props.pages / 2))
const currentPage: Ref<number> = ref(props.modelValue);
const currentPageShow: Ref<number> = ref(currentPage.value);
const inlimit = ref(props.limit);
@@ -62,11 +62,11 @@ const totalPage = computed(() => {
let start =
maxPage.value <= props.pages
? 1
: currentPage.value > pages
? maxPage.value - currentPage.value + 1 < pages
: currentPage.value > pages.value
? maxPage.value - currentPage.value + 1 < pages.value
? currentPage.value -
(pages + (pages - (maxPage.value - currentPage.value + 1)))
: currentPage.value - pages
(pages.value + (pages.value - (maxPage.value - currentPage.value + 1)))
: currentPage.value - pages.value
: 1;
for (let i = start; ; i++) {

View File

@@ -44,5 +44,5 @@ export default {
},
empty: {
description: "无数据",
},
}
};