This commit is contained in:
kandrusyak
2022-12-06 14:34:09 +03:00
parent ff1a47a20b
commit a7b9c81e06
3 changed files with 44 additions and 2 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 98 KiB

View File

@@ -0,0 +1,28 @@
<template lang="pug">
img(:src="img", :height="height", :width="width")
</template>
<script>
import LoaderGif from "@/assets/images/loader.gif";
export default {
name: "BaseLoader",
props: {
width: {
type: Number,
default: 64,
},
height: {
type: Number,
default: 64,
},
},
data() {
return {
img: LoaderGif,
};
},
};
</script>
<style scoped></style>

View File

@@ -4,6 +4,7 @@
BaseButton(@click="showModal = true") Открыть модалку
base-modal(v-model="showModal", title="Тестовый заголовок окна" )
base-button(@click="addNotification") Добавить уведомление
base-loader
</template>
<script>
@@ -12,9 +13,16 @@ import BaseModal from "@/components/base/BaseModal";
import BaseButton from "@/components/base/BaseButton";
import TheNotificationProvider from "@/components/Notifications/TheNotificationProvider";
import { addNotification } from "@/components/Notifications/notificationContext";
import BaseLoader from "@/components/Loader/BaseLoader";
export default {
name: "TheSettings",
components: { TheNotificationProvider, BaseButton, BaseModal, VSelect },
components: {
BaseLoader,
TheNotificationProvider,
BaseButton,
BaseModal,
VSelect,
},
data() {
return {
items: [
@@ -37,7 +45,13 @@ export default {
},
methods: {
addNotification() {
addNotification(new Date().getTime(), "test", "test-text", "warning", 0);
addNotification(
new Date().getTime(),
"test",
"test-text",
"warning",
3000
);
},
},
};