@@ -4,7 +4,7 @@ import { onKeyStroke } from '@vueuse/core';
44import { useForwardElement } from ' ../../composables' ;
55import { getActiveElement , getTabbableCandidates , tryFocusFirst } from ' ../../shared' ;
66import { Primitive } from ' ../primitive' ;
7- import { useCollectionContext , useToastProviderContext , useToastThemeContext } from ' ./context' ;
7+ import { useCollectionContext , useToastProviderContext , useToastViewportThemeContext } from ' ./context' ;
88import ToastFocusProxy from ' ./toast-focus-proxy.vue' ;
99import { VIEWPORT_PAUSE , VIEWPORT_RESUME } from ' ./shared' ;
1010import type { TabbingDirection , ToastViewportProps } from ' ./types' ;
@@ -22,7 +22,9 @@ const props = withDefaults(defineProps<ToastViewportProps>(), {
2222
2323const attrs = useAttrs ();
2424
25- const themeContext = useToastThemeContext ();
25+ const themeContext = useToastViewportThemeContext ();
26+ const cls = computed (() => themeContext ?.value );
27+
2628const { onViewportElementChange, toastCount, isClosePausedRef } = useToastProviderContext (' ToastViewport' );
2729const { onContainerElementChange, getOrderedElements } = useCollectionContext (' ToastViewport' );
2830const [headFocusProxyElement, setHeadFocusProxyElement] = useForwardElement ();
@@ -32,8 +34,6 @@ const [viewportElement, setViewportElement] = useForwardElement(el => {
3234 onContainerElementChange (el );
3335});
3436
35- const cls = computed (() => themeContext ?.ui ?.value ?.viewport );
36-
3737const hasToasts = computed (() => toastCount .value > 0 );
3838const hotkeyMessage = computed (() => props .hotkey .join (' +' ).replace (/ Key/ g , ' ' ).replace (/ Digit/ g , ' ' ));
3939const ariaLabel = computed (() =>
0 commit comments