fix(admin-ui): Lint all UI files (#3459)
This commit is contained in:
committed by
GitHub
parent
55febef7f1
commit
ad7d7fcd51
@@ -26,7 +26,7 @@ type BasicFocusModalProps = {
|
||||
const FocusModal: IFocusModal = ({ className, children }) => (
|
||||
<div
|
||||
className={clsx(
|
||||
"absolute inset-0 bg-grey-0 z-50 flex flex-col items-center",
|
||||
"bg-grey-0 absolute inset-0 z-50 flex flex-col items-center",
|
||||
className
|
||||
)}
|
||||
>
|
||||
@@ -37,7 +37,7 @@ const FocusModal: IFocusModal = ({ className, children }) => (
|
||||
FocusModal.Header = ({ children, className }) => (
|
||||
<div
|
||||
className={clsx(
|
||||
"w-full border-b py-4 border-b-grey-20 flex justify-center",
|
||||
"border-b-grey-20 flex w-full justify-center border-b py-4",
|
||||
className
|
||||
)}
|
||||
>
|
||||
@@ -46,7 +46,7 @@ FocusModal.Header = ({ children, className }) => (
|
||||
)
|
||||
|
||||
FocusModal.Main = ({ children, className }) => (
|
||||
<div className={clsx("w-full px-8 overflow-y-auto h-full", className)}>
|
||||
<div className={clsx("h-full w-full overflow-y-auto px-8", className)}>
|
||||
{children}
|
||||
</div>
|
||||
)
|
||||
@@ -79,12 +79,12 @@ const BasicFocusModalHeader: React.FC<BasicFocusModalProps> = ({
|
||||
}) => {
|
||||
return (
|
||||
<FocusModal.Header>
|
||||
<div className="medium:w-8/12 w-full px-8 flex justify-between">
|
||||
<div className="medium:w-8/12 flex w-full justify-between px-8">
|
||||
<Button
|
||||
size="small"
|
||||
variant="ghost"
|
||||
onClick={handleClose}
|
||||
className="border rounded-rounded w-8 h-8"
|
||||
className="rounded-rounded h-8 w-8 border"
|
||||
>
|
||||
<CrossIcon size={20} />
|
||||
</Button>
|
||||
@@ -93,7 +93,7 @@ const BasicFocusModalHeader: React.FC<BasicFocusModalProps> = ({
|
||||
onClick={handleClose}
|
||||
size="small"
|
||||
variant="ghost"
|
||||
className="border rounded-rounded"
|
||||
className="rounded-rounded border"
|
||||
>
|
||||
{cancelText || "Cancel"}
|
||||
</Button>
|
||||
|
||||
@@ -43,7 +43,7 @@ type ModalType = React.FC<ModalProps> & {
|
||||
|
||||
const Overlay: React.FC<React.PropsWithChildren> = ({ children }) => {
|
||||
return (
|
||||
<Dialog.Overlay className="fixed top-0 bottom-0 left-0 right-0 z-50 grid overflow-y-auto bg-grey-90/40 place-items-center">
|
||||
<Dialog.Overlay className="bg-grey-90/40 fixed top-0 bottom-0 left-0 right-0 z-50 grid place-items-center overflow-y-auto">
|
||||
{children}
|
||||
</Dialog.Overlay>
|
||||
)
|
||||
@@ -57,7 +57,7 @@ const Content: React.FC<React.PropsWithChildren> = ({ children }) => {
|
||||
return (
|
||||
<Dialog.Content
|
||||
style={style}
|
||||
className="overflow-x-hidden min-w-modal rounded-rounded bg-grey-0"
|
||||
className="min-w-modal rounded-rounded bg-grey-0 overflow-x-hidden"
|
||||
>
|
||||
{children}
|
||||
</Dialog.Content>
|
||||
@@ -125,7 +125,7 @@ Modal.Content = ({ children, className }) => {
|
||||
Modal.Header = ({ handleClose = undefined, children }) => {
|
||||
return (
|
||||
<div
|
||||
className="flex items-center w-full px-8 py-6 border-b"
|
||||
className="flex w-full items-center border-b px-8 py-6"
|
||||
onClick={(e) => e.stopPropagation()}
|
||||
>
|
||||
<div className="flex flex-grow">{children}</div>
|
||||
|
||||
@@ -112,13 +112,13 @@ const LayeredModal: React.FC<LayeredModalProps> = ({
|
||||
<Button
|
||||
variant="ghost"
|
||||
size="small"
|
||||
className="w-8 h-8 border text-grey-50"
|
||||
className="text-grey-50 h-8 w-8 border"
|
||||
onClick={screen.onBack}
|
||||
>
|
||||
<UTurnIcon size={20} />
|
||||
</Button>
|
||||
<div className="flex items-center gap-x-2xsmall">
|
||||
<h2 className="ml-4 inter-xlarge-semibold">{screen.title}</h2>
|
||||
<div className="gap-x-2xsmall flex items-center">
|
||||
<h2 className="inter-xlarge-semibold ml-4">{screen.title}</h2>
|
||||
{screen.subtitle && (
|
||||
<span className="inter-xlarge-regular text-grey-50">
|
||||
({screen.subtitle})
|
||||
|
||||
@@ -139,7 +139,7 @@ const SteppedModal: React.FC<SteppedProps> = ({
|
||||
>
|
||||
<Modal.Body
|
||||
className={clsx(
|
||||
"transition-transform flex flex-col justify-between duration-100 max-h-full"
|
||||
"flex max-h-full flex-col justify-between transition-transform duration-100"
|
||||
)}
|
||||
>
|
||||
<Modal.Header handleClose={resetAndClose}>
|
||||
@@ -149,20 +149,20 @@ const SteppedModal: React.FC<SteppedProps> = ({
|
||||
(lastScreenIsSummary &&
|
||||
context.currentStep !== steps.length - 1 && (
|
||||
<div className="flex items-center">
|
||||
<span className="text-grey-50 inter-small-regular w-[70px] mr-4">{`Step ${
|
||||
<span className="text-grey-50 inter-small-regular mr-4 w-[70px]">{`Step ${
|
||||
context.currentStep + 1
|
||||
} of ${steps.length}`}</span>
|
||||
{steps.map((_, i) => (
|
||||
<span
|
||||
key={i}
|
||||
className={clsx(
|
||||
"w-2 h-2 rounded-full mr-3",
|
||||
"mr-3 h-2 w-2 rounded-full",
|
||||
{
|
||||
"bg-grey-20": i > context.currentStep,
|
||||
"bg-violet-60": context.currentStep >= i,
|
||||
},
|
||||
{
|
||||
"outline-4 outline outline-violet-20":
|
||||
"outline-violet-20 outline outline-4":
|
||||
context.currentStep === i,
|
||||
}
|
||||
)}
|
||||
@@ -175,7 +175,7 @@ const SteppedModal: React.FC<SteppedProps> = ({
|
||||
<Modal.Content>{steps[context.currentStep]}</Modal.Content>
|
||||
</Modal.Body>
|
||||
<Modal.Footer>
|
||||
<div className="flex justify-end w-full gap-x-xsmall">
|
||||
<div className="gap-x-xsmall flex w-full justify-end">
|
||||
<Button
|
||||
variant="ghost"
|
||||
size="small"
|
||||
|
||||
Reference in New Issue
Block a user