DigitalConsumer.FixMyGlass/src/helpers/loading-modal-helper.js

18 lines
529 B
JavaScript

import { reactive } from "vue";
// state encapsulated and managed by the composable
const globalNonpersistedState = reactive({
showLoadingModal: true,
showTextCarousel: false,
});
export const showFmgLoadingModal = (newValue, showTextCarousel = false) => {
if (newValue !== undefined) {
globalNonpersistedState.showLoadingModal = newValue;
}
if (showTextCarousel !== undefined) {
globalNonpersistedState.showTextCarousel = showTextCarousel;
}
return { globalNonpersistedState };
};