remove empty-tips replace for center-tips
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
import view from "./index.vue";
|
||||
import WebToolkit from "../../utils/WebToolkit";
|
||||
import type { App } from "vue";
|
||||
|
||||
export const CenterTips = WebToolkit.withInstall(view);
|
||||
CenterTips.install = (app: App) => {
|
||||
app.component("CenterTips", CenterTips);
|
||||
app.component("EmptyTips", CenterTips);
|
||||
};
|
||||
|
||||
/** 兼容旧组件名。 */
|
||||
export const EmptyTips = CenterTips;
|
||||
export default CenterTips;
|
||||
@@ -1,11 +1,15 @@
|
||||
<template>
|
||||
<div class="tui-empty-tips gray" v-text="content"></div>
|
||||
<div class="tui-center-tips gray">
|
||||
<slot>
|
||||
<span v-text="content" />
|
||||
</slot>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
|
||||
defineOptions({
|
||||
name: "EmptyTips"
|
||||
name: "CenterTips"
|
||||
});
|
||||
|
||||
withDefaults(defineProps<{
|
||||
@@ -16,10 +20,10 @@ withDefaults(defineProps<{
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.tui-empty-tips {
|
||||
.tui-center-tips {
|
||||
width: 100%;
|
||||
padding: 1rem 0;
|
||||
font-size: 14px;
|
||||
padding: .5rem 0;
|
||||
font-size: .875rem;
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
||||
@@ -1,5 +0,0 @@
|
||||
import view from "./index.vue";
|
||||
import WebToolkit from "../../utils/WebToolkit";
|
||||
|
||||
export const EmptyTips = WebToolkit.withInstall(view);
|
||||
export default EmptyTips;
|
||||
@@ -5,7 +5,7 @@ import HoverPopup, { VPopupComponent } from "./v-popup";
|
||||
import Captcha from "./captcha";
|
||||
import Loading from "./loading";
|
||||
import Copyright from "./copyright";
|
||||
import EmptyTips from "./empty-tips";
|
||||
import CenterTips, { EmptyTips } from "./center-tips";
|
||||
import MarkdownView from "./markdown-view";
|
||||
import BEFlowerFall from "./background-effect/flower-fall";
|
||||
import MarkdownEditor from "./markdown-editor";
|
||||
@@ -21,7 +21,7 @@ export default [
|
||||
Captcha,
|
||||
Loading,
|
||||
Copyright,
|
||||
EmptyTips,
|
||||
CenterTips,
|
||||
MarkdownView,
|
||||
BEFlowerFall,
|
||||
MarkdownEditor,
|
||||
@@ -39,6 +39,7 @@ export {
|
||||
Captcha,
|
||||
Loading,
|
||||
Copyright,
|
||||
CenterTips,
|
||||
EmptyTips,
|
||||
MarkdownView,
|
||||
BEFlowerFall,
|
||||
|
||||
Reference in New Issue
Block a user