UNPKG

@adaptabletools/adaptable

Version:

Powerful AG Grid extension which provides advanced, cutting-edge functionality to meet all DataGrid requirements

12 lines (11 loc) 761 B
import { jsx as _jsx } from "react/jsx-runtime"; import { useAdaptable } from '../AdaptableContext'; import { getStatusItemStyle } from './Utilities/getStatusItemStyle'; import { Box } from '../../components/Flex'; export const SystemStatusStatusBarContent = () => { const adaptable = useAdaptable(); const currentSystemStatusMessageInfo = adaptable.api.systemStatusApi.getCurrentSystemStatusMessageInfo(); const { color, background } = getStatusItemStyle(currentSystemStatusMessageInfo); const message = currentSystemStatusMessageInfo?.statusMessage; return (_jsx(Box, { style: { color: message ? color : '', backgroundColor: message ? background : '' }, className: "twa:p-1 twa:rounded-standard", children: message || '0 Messages' })); };