@vuesax-alpha/nightly
Version:
A Component Library for Vue 3
23 lines (20 loc) • 767 B
JavaScript
import { computed } from 'vue';
import '../../../hooks/index.mjs';
import { useGlobalConfig } from '../../../hooks/use-global-config/index.mjs';
import { defaultNamespace } from '../../../hooks/use-namespace/index.mjs';
import { useIdInjection } from '../../../hooks/use-id/index.mjs';
let cachedContainer;
const useNotificationContainerId = () => {
const namespace = useGlobalConfig("namespace", defaultNamespace);
const idInjection = useIdInjection();
const id = computed(() => {
return `${namespace.value}-notification-container-${idInjection.prefix}`;
});
const selector = computed(() => `#${id.value}`);
return {
id,
selector
};
};
export { cachedContainer, useNotificationContainerId };
//# sourceMappingURL=use-notification.mjs.map