mirror of
https://github.com/unraid/api.git
synced 2026-01-01 14:10:10 -06:00
fix(web): replace incorrect custom types with codegen from gql & update values to match expected shapes
This commit is contained in:
@@ -136,6 +136,7 @@ export const serverState: Server = {
|
||||
apiKey: "unupc_fab6ff6ffe51040595c6d9ffb63a353ba16cc2ad7d93f813a2e80a5810",
|
||||
avatar: "https://source.unsplash.com/300x300/?portrait",
|
||||
config: {
|
||||
id: 'config-id',
|
||||
error: null,
|
||||
valid: false,
|
||||
},
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
import { defineStore, createPinia, setActivePinia } from 'pinia';
|
||||
import type { NotificationItemProps } from "~/types/ui/notification";
|
||||
import type { NotificationFragmentFragment } from '~/composables/gql/graphql';
|
||||
|
||||
setActivePinia(createPinia());
|
||||
|
||||
export const useNotificationsStore = defineStore('notifications', () => {
|
||||
const notifications = ref<NotificationItemProps[]>([]);
|
||||
const notifications = ref<NotificationFragmentFragment[]>([]);
|
||||
const isOpen = ref<boolean>(false);
|
||||
|
||||
const title = computed<string>(() => isOpen.value ? 'Notifications Are Open' : 'Notifications Are Closed');
|
||||
|
||||
const toggle = () => isOpen.value = !isOpen.value;
|
||||
|
||||
const setNotifications = (newNotifications: NotificationItemProps[]) => {
|
||||
const setNotifications = (newNotifications: NotificationFragmentFragment[]) => {
|
||||
notifications.value = newNotifications;
|
||||
};
|
||||
|
||||
|
||||
@@ -714,6 +714,7 @@ export const useServerStore = defineStore('server', () => {
|
||||
// ref: 'configError',
|
||||
// type: 'server',
|
||||
// };
|
||||
//@ts-expect-error - causing a build-breaking type error, but seems plausible, so i kept it around - pujitm
|
||||
case 'INELIGIBLE':
|
||||
return {
|
||||
heading: 'Ineligible for OS Version',
|
||||
|
||||
Reference in New Issue
Block a user