UNPKG

@plteam/chat-ui

Version:

CUI Kit is a free and open-source library for creating AI assistant chat interfaces, built with React, Material UI, and TypeScript

19 lines (18 loc) 442 B
import { ObservableReactValue } from "../utils/observers"; class SnackbarModel { open = new ObservableReactValue(false); title = ''; show = (text) => { this.title = text; this.open.value = true; }; close = () => { this.open.value = false; }; constructor(callback) { if (callback) { this.show = callback; } } } export default SnackbarModel;