📝(all): 更新日志
更新文档
This commit is contained in:
parent
f446f4ebd7
commit
e658ba92e2
@ -10,8 +10,6 @@ import "./index.less";
|
|||||||
import { String } from "../../types";
|
import { String } from "../../types";
|
||||||
import { CardShadow } from "./interface";
|
import { CardShadow } from "./interface";
|
||||||
|
|
||||||
const slot = useSlots();
|
|
||||||
|
|
||||||
export interface LayCardProps {
|
export interface LayCardProps {
|
||||||
title?: String;
|
title?: String;
|
||||||
shadow?: CardShadow;
|
shadow?: CardShadow;
|
||||||
@ -21,6 +19,8 @@ const props = withDefaults(defineProps<LayCardProps>(), {
|
|||||||
shadow: "always",
|
shadow: "always",
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const slot = useSlots();
|
||||||
|
|
||||||
const classes = computed(() => {
|
const classes = computed(() => {
|
||||||
return {
|
return {
|
||||||
shadow: props.shadow === "always",
|
shadow: props.shadow === "always",
|
||||||
|
@ -6,17 +6,7 @@ export default {
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import "./index.less";
|
import "./index.less";
|
||||||
import {
|
import { withDefaults, provide, useSlots, ref, computed, VNode, Ref, Component, watch } from "vue";
|
||||||
withDefaults,
|
|
||||||
provide,
|
|
||||||
useSlots,
|
|
||||||
ref,
|
|
||||||
computed,
|
|
||||||
VNode,
|
|
||||||
Ref,
|
|
||||||
Component,
|
|
||||||
watch,
|
|
||||||
} from "vue";
|
|
||||||
import CarouselItem from "../carouselItem/index.vue";
|
import CarouselItem from "../carouselItem/index.vue";
|
||||||
|
|
||||||
const slot = useSlots() as any;
|
const slot = useSlots() as any;
|
||||||
@ -74,15 +64,19 @@ const setItemInstanceBySlot = function (nodeList: VNode[]) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
watch(slotsChange, () => {
|
watch(
|
||||||
|
slotsChange,
|
||||||
|
() => {
|
||||||
childrens.value = [];
|
childrens.value = [];
|
||||||
setItemInstanceBySlot((slot.default && slot.default()) as VNode[]);
|
setItemInstanceBySlot((slot.default && slot.default()) as VNode[]);
|
||||||
}, { immediate: true });
|
},
|
||||||
|
{ immediate: true }
|
||||||
|
);
|
||||||
|
|
||||||
provide("active", active);
|
provide("active", active);
|
||||||
provide("slotsChange", slotsChange);
|
provide("slotsChange", slotsChange);
|
||||||
|
|
||||||
const sub = function () {
|
const sub = () => {
|
||||||
for (var i = 0; i < childrens.value.length; i++) {
|
for (var i = 0; i < childrens.value.length; i++) {
|
||||||
if (childrens.value[i].props?.id === active.value) {
|
if (childrens.value[i].props?.id === active.value) {
|
||||||
if (i === 0) {
|
if (i === 0) {
|
||||||
@ -95,7 +89,7 @@ const sub = function () {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const add = function () {
|
const add = () => {
|
||||||
for (var i = 0; i < childrens.value.length; i++) {
|
for (var i = 0; i < childrens.value.length; i++) {
|
||||||
if (childrens.value[i].props?.id === active.value) {
|
if (childrens.value[i].props?.id === active.value) {
|
||||||
if (i === childrens.value.length - 1) {
|
if (i === childrens.value.length - 1) {
|
||||||
@ -154,7 +148,6 @@ watch(
|
|||||||
<button class="layui-icon layui-carousel-arrow" lay-type="sub" @click="sub">
|
<button class="layui-icon layui-carousel-arrow" lay-type="sub" @click="sub">
|
||||||
{{ anim === "updown" ? "" : "" }}
|
{{ anim === "updown" ? "" : "" }}
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<button class="layui-icon layui-carousel-arrow" lay-type="add" @click="add">
|
<button class="layui-icon layui-carousel-arrow" lay-type="add" @click="add">
|
||||||
{{ anim === "updown" ? "" : "" }}
|
{{ anim === "updown" ? "" : "" }}
|
||||||
</button>
|
</button>
|
||||||
|
@ -11,6 +11,19 @@
|
|||||||
<template>
|
<template>
|
||||||
<lay-timeline>
|
<lay-timeline>
|
||||||
<lay-timeline-item title="1.1.x">
|
<lay-timeline-item title="1.1.x">
|
||||||
|
<ul>
|
||||||
|
<a name="1-1-8"></a>
|
||||||
|
<li>
|
||||||
|
<h3>1.1.8 <span class="layui-badge-rim">2022-06-18</span></h3>
|
||||||
|
<ul>
|
||||||
|
<li>[新增] layui-vue-helper 插件, 用于 Visual Studio Code 辅助开发</li>
|
||||||
|
<li>[新增] checkbox 组件 is-indeterminate 属性, 用于展示半选状态, 默认为 false</li>
|
||||||
|
<li>[新增] textarea 组件 show-count 属性, 用于展示输入长度与 max-length, 默认为 false</li>
|
||||||
|
<li>[修复] carousel 组件加载时无法获取 carousel-item 轮播项</li>
|
||||||
|
<li>[修复] input-number 组件 modelValue 属性类型错误</li>
|
||||||
|
</ul>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
<ul>
|
<ul>
|
||||||
<a name="1-1-7"></a>
|
<a name="1-1-7"></a>
|
||||||
<li>
|
<li>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user