Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
DashboardContainer: ({ children }) => {
const translate = useTranslate();
return (
<div>
<h1>{translate('sample')}</h1>
<div>{children}</div>
</div>
);
},
DashboardTile: ({ children, rows, columns }) => <div>{children}</div>,
const LanguagePickerView: React.FC = ({ selected, available }) => {
const [open, setOpen] = React.useState(false);
const [language, setLanguage] = useDynamicLanguage(selected, loadLanguage);
const container = React.useRef();
const translate = useTranslate();
useOnClickOutside(container, () => setOpen(false));
return (
<div>
<div> setOpen(!open)}>
</div>
<ul>
{available.map(lang => (
<li> setLanguage(lang)}>
<span>{translate(lang)}</span>
</li>
))}
</ul>
</div>
);