bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/screenreader-alert/service.ts

21 lines
318 B
TypeScript
Raw Normal View History

import { uniqueId } from '/imports/utils/string-utils';
import Queue from './queue';
export const addAlert = (text: string) => {
const alert = {
id: uniqueId('alert-'),
text,
};
Queue.push(alert);
};
export const shiftAlert = () => {
Queue.shift();
};
export default {
addAlert,
shiftAlert,
};