style: restrict type import (#1589)

This commit is contained in:
Himself65
2023-03-15 11:58:43 -05:00
committed by GitHub
parent 6ab2f83e13
commit efcf1fcaa0
154 changed files with 332 additions and 307 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
import { Children, cloneElement, forwardRef } from 'react';
import { ButtonProps } from './interface';
import type { ButtonProps } from './interface';
import { Loading } from './Loading';
import { StyledButton } from './styles';
import { getSize } from './utils';
@@ -1,11 +1,5 @@
import {
Children,
cloneElement,
CSSProperties,
forwardRef,
HTMLAttributes,
ReactElement,
} from 'react';
import type { CSSProperties, HTMLAttributes, ReactElement } from 'react';
import { Children, cloneElement, forwardRef } from 'react';
import { StyledIconButton } from './styles';
const SIZE_SMALL = 'small' as const;
+1 -1
View File
@@ -1,5 +1,5 @@
import { styled } from '../../styles';
import { ButtonProps } from './interface';
import type { ButtonProps } from './interface';
import { getButtonColors } from './utils';
export const LoadingContainer = styled('div')<Pick<ButtonProps, 'type'>>(
({ theme, type = 'default' }) => {
@@ -1,6 +1,6 @@
import { Children, cloneElement, forwardRef } from 'react';
import { ButtonProps } from './interface';
import type { ButtonProps } from './interface';
import { StyledTextButton } from './styles';
import { getSize } from './utils';
export const TextButton = forwardRef<HTMLButtonElement, ButtonProps>(
@@ -1,4 +1,4 @@
import {
import type {
CSSProperties,
HTMLAttributes,
PropsWithChildren,
+2 -2
View File
@@ -1,7 +1,7 @@
import { CSSProperties } from 'react';
import type { CSSProperties } from 'react';
import { absoluteCenter, displayInlineFlex, styled } from '../../styles';
import { ButtonProps } from './interface';
import type { ButtonProps } from './interface';
import { getButtonColors, getSize } from './utils';
export const StyledIconButton = styled('button', {
+3 -7
View File
@@ -1,11 +1,7 @@
import { Theme } from '@mui/material';
import type { Theme } from '@mui/material';
import {
ButtonProps,
SIZE_DEFAULT,
SIZE_MIDDLE,
SIZE_SMALL,
} from './interface';
import type { ButtonProps } from './interface';
import { SIZE_DEFAULT, SIZE_MIDDLE, SIZE_SMALL } from './interface';
// TODO: Designer is not sure about the size, Now, is just use default size
export const SIZE_CONFIG = {