Improve dark-mode

This commit is contained in:
Justin
2022-05-04 10:50:53 -04:00
parent 1a9b0be3ab
commit a987b5f296
9 changed files with 14 additions and 15 deletions

View File

@ -37,8 +37,8 @@ const ListItem: React.FC<IListItem> = ({ label, hint, children, onClick }) => {
return (
<Comp
className={classNames({
'flex items-center justify-between px-3 py-2 first:rounded-t-lg last:rounded-b-lg bg-gradient-to-r from-gradient-purple/20 to-gradient-blue/20': true,
'cursor-pointer hover:from-gradient-purple/30 hover:to-gradient-blue/30': typeof onClick !== 'undefined',
'flex items-center justify-between px-3 py-2 first:rounded-t-lg last:rounded-b-lg bg-gradient-to-r from-gradient-purple/20 to-gradient-blue/20 dark:from-slate-900/25 dark:to-slate-900/50': true,
'cursor-pointer hover:from-gradient-purple/30 hover:to-gradient-blue/30 dark:hover:from-slate-900/40 dark:hover:to-slate-900/75': typeof onClick !== 'undefined',
})}
{...linkProps}
>

View File

@ -21,7 +21,7 @@ const useButtonStyles = ({
'border-transparent text-white bg-primary-600 hover:bg-primary-700 focus:ring-primary-500 focus:ring-2 focus:ring-offset-2',
secondary:
'border-transparent text-primary-700 bg-primary-100 hover:bg-primary-200 focus:ring-primary-500 focus:ring-2 focus:ring-offset-2',
ghost: 'shadow-none border-gray-200 text-gray-700 bg-white focus:ring-primary-500 focus:ring-2 focus:ring-offset-2',
ghost: 'shadow-none border-gray-200 text-gray-700 bg-white dark:border-slate-700 dark:bg-slate-800 dark:text-slate-200 focus:ring-primary-500 focus:ring-2 focus:ring-offset-2',
accent: 'border-transparent text-white bg-accent-500 hover:bg-accent-300 focus:ring-pink-500 focus:ring-2 focus:ring-offset-2',
danger: 'border-transparent text-danger-700 bg-danger-100 hover:bg-danger-200 focus:ring-danger-500 focus:ring-2 focus:ring-offset-2',
transparent: 'border-transparent text-gray-800 backdrop-blur-sm bg-white/75 hover:bg-white/80',

View File

@ -31,5 +31,5 @@ div:focus[data-reach-menu-list] {
}
[data-reach-menu-popover] hr {
@apply my-1 mx-2 border-t border-gray-100 dark:border-slate-600;
@apply my-1 mx-2 border-t border-gray-100 dark:border-slate-700;
}

View File

@ -7,7 +7,7 @@ const Select = React.forwardRef<HTMLSelectElement>((props, ref) => {
return (
<select
ref={ref}
className='pl-3 pr-10 py-2 text-base border-gray-300 dark:border-gray-600 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500 dark:bg-slate-800 sm:text-sm rounded-md'
className='pl-3 pr-10 py-2 text-base border-gray-300 dark:border-slate-700 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500 dark:bg-slate-800 sm:text-sm rounded-md'
{...filteredProps}
>
{children}

View File

@ -45,7 +45,7 @@ const AnimatedTabs: React.FC<IAnimatedInterface> = ({ children, ...rest }) => {
ref={ref}
>
<div
className='w-full h-[3px] bg-primary-200 dark:bg-slate-600 absolute'
className='w-full h-[3px] bg-primary-200 dark:bg-slate-700 absolute'
style={{ top }}
/>
<div

View File

@ -557,7 +557,7 @@ class Header extends ImmutablePureComponent {
<div className='-mt-12 flex items-end space-x-5'>
<div className='flex relative'>
<div
className='h-24 w-24 bg-gray-400 rounded-full ring-4 ring-white'
className='h-24 w-24 bg-gray-400 rounded-full ring-4 ring-white dark:ring-slate-800'
/>
</div>
</div>
@ -603,7 +603,7 @@ class Header extends ImmutablePureComponent {
<a href={account.get('avatar')} onClick={this.handleAvatarClick} target='_blank'>
<Avatar
account={account}
className='h-24 w-24 rounded-full ring-4 ring-white'
className='h-24 w-24 rounded-full ring-4 ring-white dark:ring-slate-800'
/>
</a>
</div>
@ -615,7 +615,7 @@ class Header extends ImmutablePureComponent {
<MenuButton
as={IconButton}
src={require('@tabler/icons/icons/dots.svg')}
className='text-primary-700 bg-primary-100 hover:bg-primary-200 p-2'
className='text-primary-700 bg-primary-100 dark:!bg-slate-700 dark:!text-white hover:bg-primary-200 p-2'
iconClassName='w-5 h-5'
/>

View File

@ -35,7 +35,7 @@ const Footer = ({ context }) => (
);
const Item = ({ context, ...rest }) => (
<div className='border-solid border-b border-gray-200 dark:border-gray-600' {...rest} />
<div className='border-solid border-b border-gray-200 dark:border-slate-700' {...rest} />
);
const getNotifications = createSelector([

View File

@ -20,7 +20,6 @@ interface IEnableOtpForm {
}
const EnableOtpForm: React.FC<IEnableOtpForm> = ({ displayOtpForm, handleSetupProceedClick }) => {
const dispatch = useAppDispatch();
const intl = useIntl();
const history = useHistory();
@ -43,7 +42,7 @@ const EnableOtpForm: React.FC<IEnableOtpForm> = ({ displayOtpForm, handleSetupPr
<FormattedMessage id='mfa.setup_warning' defaultMessage="Write these codes down or save them somewhere secure - otherwise you won't see them again. If you lose access to your 2FA app and recovery codes you'll be locked out of your account." />
</Text>
<div className='bg-gray-100 dark:bg-slate-700 rounded-lg p-4'>
<div className='bg-gray-100 dark:bg-slate-900/50 rounded-lg p-4'>
<Stack space={3}>
<Text weight='medium' align='center'>
<FormattedMessage id='mfa.setup_recoverycodes' defaultMessage='Recovery codes' />
@ -85,4 +84,4 @@ const EnableOtpForm: React.FC<IEnableOtpForm> = ({ displayOtpForm, handleSetupPr
);
};
export default EnableOtpForm;
export default EnableOtpForm;

View File

@ -65,7 +65,7 @@ const OtpConfirmForm: React.FC = () => {
return (
<Stack space={4}>
<hr className='mt-4' />
<hr className='mt-4 dark:border-slate-700' />
<Form onSubmit={handleSubmit}>
<Stack>
@ -137,4 +137,4 @@ const OtpConfirmForm: React.FC = () => {
);
};
export default OtpConfirmForm;
export default OtpConfirmForm;