This commit is contained in:
2022-12-09 16:41:41 +08:00
parent c1cce5a7c2
commit ff7aa8774f
2003 changed files with 156639 additions and 140 deletions

View File

@@ -0,0 +1,2 @@
x<01>Tmo<6D>0<10>g~ʼnO<C589>u<><75>j <0B> <09><11>!A$T<>B<><18><16><>q<EFBFBD>P<EFBFBD><EFBFBD><7F><EFBFBD>!C<>ƇB<C687><42><EFBFBD><EFBFBD><EFBFBD><1E>:<3A>kh<6B>?<3F> 1e<1C>`<60>h<1C><>d<1A>|<7C><><EFBFBD><19><><1E><><EFBFBD>>$<1C><><EFBFBD><EFBFBD>۵"<22>OE*<11><06><>4<EFBFBD><34><EFBFBD>;<3B>8)r<>i<EFBFBD><69><EFBFBD>" <0C><11><>} x<><78><EFBFBD><1C><>k<>l<EFBFBD><6C>:-<2D><><EFBFBD>g0I<0F><><EFBFBD>#<><7F><d<> <09>=x<><78>!<21><>s<EFBFBD><73><EFBFBD><1D>g<EFBFBD><67><EFBFBD>d<EFBFBD>ع<EFBFBD><D8B9>{]<5D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>{<7B>}<7D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>/ު?[<5B><19>E<EFBFBD><45><EFBFBD><EFBFBD>7<EFBFBD><37><EFBFBD><EFBFBD><EFBFBD>
<15>Z<EFBFBD><5A><EFBFBD>T]O<><4F>:<3A><><EFBFBD><EFBFBD>*<2A><><EFBFBD>)<29>]<5D>Qo*<2A><><EFBFBD><EFBFBD>9sk<73>zAh<41><68>Y<EFBFBD><59>,<2C><>Re.a/h<><15>V<EFBFBD>y=<3D>

View File

@@ -0,0 +1,110 @@
<script lang="ts">
export default {
name: "LayCarouselItem",
};
</script>
<script setup lang="ts">
import {
inject,
Ref,
computed,
ref,
ComputedRef,
WritableComputedRef,
} from "vue";
export interface CarouselItemProps {
id: string;
}
const props = defineProps<CarouselItemProps>();
const active = inject("active") as WritableComputedRef<string>;
const slotsChange: Ref<boolean> = inject("slotsChange") as Ref<boolean>;
slotsChange.value = !slotsChange.value;
const anim = inject("anim") as ComputedRef<string>;
const item = ref();
const getStyle = computed<any>(() => {
if (item.value) {
let allChild = item.value.parentNode.children;
let allChildNum = allChild.length;
let activeIndex = 0;
let currentIndex = 0;
for (let index = 0; index < allChild.length; index++) {
const element = allChild[index];
if (element.getAttribute("data-id") === active.value) {
activeIndex = index;
}
if (element.getAttribute("data-id") === props.id) {
currentIndex = index;
}
}
let prevIndex = activeIndex > 0 ? activeIndex - 1 : allChildNum - 1;
let nextIndex = activeIndex + 1 < allChildNum ? activeIndex + 1 : 0;
let animation = anim.value;
if (activeIndex === currentIndex) {
if (animation === "updown") {
return {
transform: "translateY(0)",
visibility: "inherit",
};
} else if (animation.includes("fade")) {
return {
opacity: 1,
visibility: "inherit",
};
} else {
return {
transform: "translateX(0)",
visibility: "inherit",
};
}
}
if (prevIndex === currentIndex) {
if (animation === "updown") {
return {
transform: "translateY(-100%)",
};
} else if (animation.includes("fade")) {
return {
opacity: 0,
};
} else {
return {
transform: "translateX(-100%)",
};
}
}
if (nextIndex === currentIndex) {
if (animation === "updown") {
return {
transform: "translateY(100%)",
};
} else if (animation.includes("fade")) {
return {
opacity: 0,
};
} else {
return {
transform: "translateX(100%)",
};
}
}
return {
display: "none",
};
}
});
</script>
<template>
<li ref="item" :style="getStyle" :data-id="id">
<slot></slot>
</li>
</template>

View File

@@ -0,0 +1,30 @@
import { w as withInstall } from "../badge/index2.js";
import { defineComponent, computed, openBlock, createElementBlock, normalizeClass, unref, renderSlot } from "vue";
var index = /* @__PURE__ */ (() => ":root{--panel-border-color: var(--global-neutral-color-3);--panel-border-radius: var(--global-border-radius)}.layui-panel{border-width:1px;border-style:solid;margin-bottom:15px;border-radius:var(--panel-border-radius);border-color:var(--panel-border-color);background-color:#fff;padding:20px}.layui-panel.is-hover-shadow:hover,.layui-panel.shadow{box-shadow:1px 1px 4px #00000014}\n")();
const __default__ = {
name: "LayPanel"
};
const _sfc_main = defineComponent({
...__default__,
props: {
shadow: { default: "always" }
},
setup(__props) {
const props = __props;
const classes = computed(() => {
return {
shadow: props.shadow === "always",
"is-hover-shadow": props.shadow === "hover"
};
});
return (_ctx, _cache) => {
return openBlock(), createElementBlock("div", {
class: normalizeClass(["layui-panel", unref(classes)])
}, [
renderSlot(_ctx.$slots, "default")
], 2);
};
}
});
const component = withInstall(_sfc_main);
export { component as default };

View File

@@ -0,0 +1,20 @@
<script lang="ts">
export default {
name: "SnowflakeIcon",
};
</script>
<script setup lang="ts">
import LayIcon from "../component/icon/index";
const props = defineProps<{
color?: string;
size?: string;
}>();
</script>
<template>
<lay-icon
:color="props.color"
:size="props.size"
type="layui-icon-snowflake"
/>
</template>

View File

@@ -0,0 +1,45 @@
<script lang="ts">
export default {
name: "LaySkeleton",
};
</script>
<script setup lang="ts">
import "./index.less";
import { withDefaults } from "vue";
import LaySkeletonItem from "../skeletonItem/index.vue";
export interface SkeletonProps {
rows?: number;
loading?: boolean;
animated?: boolean;
}
const props = withDefaults(defineProps<SkeletonProps>(), {
rows: 4,
loading: false,
animated: false,
});
</script>
<template>
<div
:class="['lay-skeleton', animated ? 'lay-skeleton-animated' : '']"
v-bind="$attrs"
>
<template v-if="loading">
<slot name="skeleton">
<lay-skeleton-item
v-for="item in rows"
:key="item"
:class="[
item === 1 ? 'lay-skeleton-first' : '',
item === rows ? 'lay-skeleton-last' : '',
]"
type="p"
></lay-skeleton-item>
</slot>
</template>
<slot v-else></slot>
</div>
</template>

View File

@@ -0,0 +1,100 @@
import type { App } from "vue";
import "./theme/index.less";
import "@layui/layer-vue/lib/index.css";
import "@layui/icons-vue/lib/index.css";
import { layer } from "@layui/layer-vue";
import { useI18n } from "./language";
import LayBacktop from "./component/backTop/index";
import LayAvatar from "./component/avatar/index";
import LayAvatarList from "./component/avatarList/index";
import LayRadio from "./component/radio/index";
import LayRadioGroup from "./component/radioGroup/index";
import LayButton from "./component/button/index";
import LayButtonContainer from "./component/buttonContainer/index";
import LayButtonGroup from "./component/buttonGroup/index";
import LayIcon from "./component/icon/index";
import LayIconPicker from "./component/iconPicker/index";
import LayCard from "./component/card/index";
import LayLayout from "./component/layout/index";
import LaySide from "./component/side/index";
import LayBody from "./component/body/index";
import LayHeader from "./component/header/index";
import LayFooter from "./component/footer/index";
import LayLogo from "./component/logo/index";
import LayPanel from "./component/panel/index";
import LayProgress from "./component/progress/index";
import LayCol from "./component/col/index";
import LayRow from "./component/row/index";
import LayInput from "./component/input/index";
import LayBadge from "./component/badge/index";
import LayQuote from "./component/quote/index";
import LayLine from "./component/line/index";
import LayTimeline from "./component/timeline/index";
import LayTimelineItem from "./component/timelineItem/index";
import LayTextarea from "./component/textarea/index";
import LaySwitch from "./component/switch/index";
import LayCollapse from "./component/collapse/index";
import LayCollapseItem from "./component/collapseItem/index";
import LayContainer from "./component/container/index";
import LayCountUp from "./component/countUp/index";
import LayMenu from "./component/menu/index";
import LayMenuItem from "./component/menuItem/index";
import LayCheckbox from "./component/checkbox/index";
import LayCheckboxGroup from "./component/checkboxGroup/index";
import LayForm from "./component/form/index";
import LayBreadcrumb from "./component/breadcrumb/index";
import LayBreadcrumbItem from "./component/breadcrumbItem/index";
import LayField from "./component/field/index";
import LaySelect from "./component/select/index";
import LaySelectOption from "./component/selectOption/index";
import LayScroll from "./component/scroll/index";
import LayEmpty from "./component/empty/index";
import LayFormItem from "./component/formItem/index";
import LayRate from "./component/rate/index";
import LayDropdown from "./component/dropdown/index";
import LayDropdownMenu from "./component/dropdownMenu/index";
import LayDropdownMenuItem from "./component/dropdownMenuItem/index";
import LayDropdownSubMenu from "./component/dropdownSubMenu/index";
import LayTab from "./component/tab/index";
import LayTabItem from "./component/tabItem/index";
import LayTree from "./component/tree/index";
import LayTreeSelect from "./component/treeSelect/index";
import LayTable from "./component/table/index";
import LayPage from "./component/page/index";
import LayTransfer from "./component/transfer/index";
import LaySlider from "./component/slider/index";
import LayCarousel from "./component/carousel/index";
import LayCarouselItem from "./component/carouselItem/index";
import LayColorPicker from "./component/colorPicker/index";
import LayTooltip from "./component/tooltip/index";
import LayInputNumber from "./component/inputNumber/index";
import LaySkeleton from "./component/skeleton/index";
import LaySkeletonItem from "./component/skeletonItem/index";
import LayStep from "./component/step/index";
import LayStepItem from "./component/stepItem/index";
import LaySubMenu from "./component/subMenu/index";
import LaySplitPanel from "./component/splitPanel/index";
import LaySplitPanelItem from "./component/splitPanelItem/index";
import LayException from "./component/exception/index";
import LayResult from "./component/result/index";
import LayFullscreen from "./component/fullscreen/index";
import LayDatePicker from "./component/datePicker/index";
import LayTransition from "./component/transition/index";
import LayUpload from "./component/upload/index";
import LayRipple from "./component/ripple/index";
import LayNoticeBar from "./component/noticeBar/index";
import LayPageHeader from "./component/pageHeader/index";
import LayCascader from "./component/cascader/index";
import LayAffix from "./component/affix/index";
import LaySpace from "./component/space/index";
import LayTag from "./component/tag/index";
import LayTagInput from "./component/tagInput/index";
import LayConfigProvider from "./provider";
import { InstallOptions } from "./types";
declare const install: (app: App, options?: InstallOptions) => void;
export { LaySplitPanel, LaySplitPanelItem, LayRadio, LayRadioGroup, LayButton, LayIcon, LayBacktop, LayLayout, LaySide, LayHeader, LayBody, LayFooter, LayLogo, LayPanel, LayCard, LayProgress, LayButtonGroup, LayButtonContainer, LayRow, LayCol, LayInput, LayBadge, LayQuote, LayLine, LayTimeline, LayTimelineItem, LayTextarea, LaySwitch, LayCollapse, LayCollapseItem, LayContainer, LayMenu, LayMenuItem, LayCheckbox, LayForm, LayBreadcrumb, LayBreadcrumbItem, LayAvatar, LayAvatarList, LayField, LaySelect, LayScroll, LaySelectOption, LayEmpty, LayFormItem, LayRate, LayDropdown, LayDropdownMenu, LayDropdownMenuItem, LayDropdownSubMenu, LayTab, LayTabItem, LayIconPicker, LayTree, LayTable, LayPage, LayTransfer, LayCheckboxGroup, LaySlider, LayCarousel, LayCarouselItem, LayColorPicker, LayTooltip, LayInputNumber, LaySkeleton, LaySkeletonItem, LayCountUp, LayStep, LayStepItem, LaySubMenu, LayException, LayResult, LayFullscreen, LayConfigProvider, LayDatePicker, LayTransition, LayUpload, LayRipple, LayNoticeBar, LayPageHeader, LayCascader, LayAffix, LaySpace, LayTag, LayTagInput, LayTreeSelect, install, };
export { layer, useI18n };
declare const _default: {
install: (app: App<any>, options?: InstallOptions | undefined) => void;
};
export default _default;

View File

@@ -0,0 +1,52 @@
<template>
<div id="docsearch"></div>
</template>
<script setup name="LaySelect" lang="ts">
import { onMounted } from "vue";
onMounted(() => {
// @ts-ignore
docsearch({
appId: "BIYZTK0F0Q",
apiKey: "de599990b844bc1b325310f61ad19a78",
indexName: "layui-vue",
container: "#docsearch",
debug: false,
});
});
</script>
<style>
.DocSearch-Button {
outline: none;
box-shadow: none;
}
.DocSearch-Button .DocSearch-Search-Icon,
.DocSearch-Button-Placeholder {
color: whitesmoke;
}
:root {
--docsearch-logo-color: var(--global-primary-color);
--docsearch-primary-color: var(--global-primary-color);
--docsearch-searchbox-background: rgba(255, 255, 255, 0.02);
--docsearch-searchbox-focus-background: rgba(255, 255, 255, 0.02);
--docsearch-container-background: rgba(0, 0, 0, 0.1);
--docsearch-searchbox-shadow: inset 0 0 0 1px var(--docsearch-primary-color);
}
.DocSearch-Button {
width: 150px;
border-radius: 50px;
}
.DocSearch-Button,
.DocSearch-Button:hover,
.DocSearch-Button:active,
.DocSearch-Button:focus {
border: 1px solid rgb(224, 224, 230);
box-shadow: none;
}
.DocSearch-Button .DocSearch-Search-Icon,
.DocSearch-Button-Placeholder {
color: rgba(0, 0, 0, 0.6);
}
</style>