Fix install warning display and make it reactive

This commit is contained in:
DaneEveritt 2022-06-27 20:36:24 -04:00
parent 2dda151a49
commit bd278b2688
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
5 changed files with 39 additions and 24 deletions

View file

@ -0,0 +1,23 @@
import { ExclamationIcon } from '@heroicons/react/outline';
import React from 'react';
import classNames from 'classnames';
interface AlertProps {
type: 'warning';
className?: string;
children: React.ReactNode;
}
export default ({ className, children }: AlertProps) => {
return (
<div
className={classNames(
'flex items-center border-l-8 border-yellow-500 text-gray-50 bg-yellow-500/25 rounded-md shadow px-4 py-3',
className
)}
>
<ExclamationIcon className={'w-6 h-6 text-yellow-500 mr-2'} />
{children}
</div>
);
};

View file

@ -0,0 +1 @@
export { default as Alert } from './Alert';