⚡️(icon-picker): update
This commit is contained in:
parent
0eaac32664
commit
b72212b659
@ -13,11 +13,11 @@ export interface LayEmptyProps {
|
||||
image?: string;
|
||||
}
|
||||
|
||||
const slots = useSlots();
|
||||
|
||||
const props = withDefaults(defineProps<LayEmptyProps>(), {
|
||||
description: "暂无数据",
|
||||
});
|
||||
|
||||
const slots = useSlots();
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
@ -8,12 +8,11 @@ export default {
|
||||
import "./index.less";
|
||||
import { useSlots } from "vue";
|
||||
|
||||
const slot = useSlots();
|
||||
|
||||
export interface LayFieldProps {
|
||||
title?: string;
|
||||
}
|
||||
|
||||
const slot = useSlots();
|
||||
const props = defineProps<LayFieldProps>();
|
||||
</script>
|
||||
|
||||
@ -24,7 +23,6 @@ const props = defineProps<LayFieldProps>();
|
||||
<slot></slot>
|
||||
</div>
|
||||
</fieldset>
|
||||
|
||||
<fieldset v-else class="layui-field layui-field-title">
|
||||
<legend>
|
||||
<a name="docend">{{ title }}</a>
|
||||
|
@ -37,7 +37,6 @@ const icones: Ref = ref([]);
|
||||
const total = ref(icons.length);
|
||||
const totalPage = ref(total.value / 12);
|
||||
const currentPage: Ref = ref(1);
|
||||
const searchValue = ref();
|
||||
|
||||
if (props.page) {
|
||||
icones.value = icons.slice(0, 12);
|
||||
@ -45,7 +44,7 @@ if (props.page) {
|
||||
icones.value = icons;
|
||||
}
|
||||
|
||||
const next = function () {
|
||||
const next = () => {
|
||||
if (currentPage.value === totalPage.value) {
|
||||
return;
|
||||
}
|
||||
@ -55,7 +54,7 @@ const next = function () {
|
||||
icones.value = icons.slice(start, end);
|
||||
};
|
||||
|
||||
const prev = function () {
|
||||
const prev = () => {
|
||||
if (currentPage.value === 1) {
|
||||
return;
|
||||
}
|
||||
@ -77,7 +76,7 @@ const clear = () => {
|
||||
}
|
||||
};
|
||||
|
||||
const search = function (e: any) {
|
||||
const search = (e: any) => {
|
||||
currentPage.value = 1;
|
||||
const start = (currentPage.value - 1) * 12;
|
||||
const end = start + 12;
|
||||
@ -101,7 +100,7 @@ const search = function (e: any) {
|
||||
}
|
||||
};
|
||||
|
||||
const searchList = function (str: string, container: any) {
|
||||
const searchList = (str: string, container: any) => {
|
||||
var newList = [];
|
||||
var startChar = str.charAt(0);
|
||||
var strLen = str.length;
|
||||
@ -152,7 +151,6 @@ const searchList = function (str: string, container: any) {
|
||||
<lay-input
|
||||
@input="search"
|
||||
@clear="clear"
|
||||
v-model="searchValue"
|
||||
:autocomplete="true"
|
||||
:allow-clear="true"
|
||||
>
|
||||
|
@ -227,7 +227,7 @@ onMounted(() => {
|
||||
<lay-checkbox
|
||||
v-for="column in columns"
|
||||
v-model="tableColumnKeys"
|
||||
skin="primary"
|
||||
skin="primary"
|
||||
:key="column.key"
|
||||
:label="column.key"
|
||||
>{{ column.title }}</lay-checkbox
|
||||
@ -416,4 +416,4 @@ onMounted(() => {
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</template>
|
||||
|
Loading…
Reference in New Issue
Block a user