chore: replace prettier with oxfmt (#8676)
This commit is contained in:
parent
9ee73d57ef
commit
41abaffc6e
1008 changed files with 4046 additions and 4027 deletions
|
|
@ -28,7 +28,7 @@ const Checkbox = React.forwardRef(function Checkbox(props: CheckboxProps, ref: R
|
|||
} = props;
|
||||
|
||||
return (
|
||||
<div className={cn("relative flex-shrink-0 flex gap-2", containerClassName)}>
|
||||
<div className={cn("relative flex flex-shrink-0 gap-2", containerClassName)}>
|
||||
<input
|
||||
id={id}
|
||||
ref={ref}
|
||||
|
|
@ -36,10 +36,10 @@ const Checkbox = React.forwardRef(function Checkbox(props: CheckboxProps, ref: R
|
|||
name={name}
|
||||
checked={checked}
|
||||
className={cn(
|
||||
"appearance-none shrink-0 size-4 border rounded-[3px] focus:outline-1 focus:outline-offset-4 focus:outline-accent-strong cursor-pointer",
|
||||
"size-4 shrink-0 cursor-pointer appearance-none rounded-[3px] border focus:outline-1 focus:outline-offset-4 focus:outline-accent-strong",
|
||||
{
|
||||
"border-subtle bg-layer-1 cursor-not-allowed": disabled,
|
||||
"border-strong hover:border-strong-1 bg-transparent": !disabled,
|
||||
"cursor-not-allowed border-subtle bg-layer-1": disabled,
|
||||
"border-strong bg-transparent hover:border-strong-1": !disabled,
|
||||
"border-accent-strong-40 hover:border-accent-strong-40 bg-accent-primary hover:bg-accent-primary/80":
|
||||
!disabled && (checked || indeterminate),
|
||||
|
||||
|
|
@ -52,7 +52,7 @@ const Checkbox = React.forwardRef(function Checkbox(props: CheckboxProps, ref: R
|
|||
/>
|
||||
<svg
|
||||
className={cn(
|
||||
"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 size-4 p-0.5 pointer-events-none outline-none hidden text-on-color",
|
||||
"pointer-events-none absolute top-1/2 left-1/2 hidden size-4 -translate-x-1/2 -translate-y-1/2 p-0.5 text-on-color outline-none",
|
||||
{
|
||||
block: checked,
|
||||
"text-placeholder opacity-40": disabled,
|
||||
|
|
@ -71,7 +71,7 @@ const Checkbox = React.forwardRef(function Checkbox(props: CheckboxProps, ref: R
|
|||
</svg>
|
||||
<svg
|
||||
className={cn(
|
||||
"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 size-4 p-0.5 pointer-events-none outline-none stroke-white hidden",
|
||||
"pointer-events-none absolute top-1/2 left-1/2 hidden size-4 -translate-x-1/2 -translate-y-1/2 stroke-white p-0.5 outline-none",
|
||||
{
|
||||
"stroke-placeholder opacity-40": disabled,
|
||||
block: indeterminate && !checked,
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ export function InputColorPicker(props: InputColorPickerProps) {
|
|||
style={style}
|
||||
/>
|
||||
|
||||
<Popover as="div" className="absolute right-1 top-1/2 z-10 -translate-y-1/2">
|
||||
<Popover as="div" className="absolute top-1/2 right-1 z-10 -translate-y-1/2">
|
||||
{() => (
|
||||
<>
|
||||
<Popover.Button as={React.Fragment}>
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ const Input = React.forwardRef(function Input(props: InputProps, ref: React.Forw
|
|||
type={type}
|
||||
name={name}
|
||||
className={cn(
|
||||
"block rounded-md bg-layer-2 text-13 placeholder-tertiary border-subtle-1 focus:outline-none",
|
||||
"placeholder-tertiary block rounded-md border-subtle-1 bg-layer-2 text-13 focus:outline-none",
|
||||
{
|
||||
"rounded-md border-[0.5px]": mode === "primary",
|
||||
"rounded-sm border-none bg-transparent ring-0 transition-all focus:ring-1 focus:ring-accent-strong":
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ export function PasswordStrengthIndicator({
|
|||
<div className={cn("space-y-3")}>
|
||||
{/* Strength Indicator */}
|
||||
<div className="space-y-2">
|
||||
<div className="flex gap-1 w-full transition-all duration-300 ease-linear">
|
||||
<div className="flex w-full gap-1 transition-all duration-300 ease-linear">
|
||||
{[0, 1, 2].map((fragmentIndex) => (
|
||||
<div
|
||||
key={fragmentIndex}
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ export function PasswordInput({
|
|||
value={value}
|
||||
onChange={(e) => onChange(e.target.value)}
|
||||
className={cn(
|
||||
"w-full px-3 py-2 pr-10 text-secondary border rounded-md bg-surface-1 focus:outline-none focus:ring-2 focus:ring-accent-strong placeholder:text-placeholder focus:border-transparent transition-all duration-200",
|
||||
"w-full rounded-md border bg-surface-1 px-3 py-2 pr-10 text-secondary transition-all duration-200 placeholder:text-placeholder focus:border-transparent focus:ring-2 focus:ring-accent-strong focus:outline-none",
|
||||
{
|
||||
"border-strong": !error,
|
||||
"border-danger-strong": error,
|
||||
|
|
@ -54,19 +54,19 @@ export function PasswordInput({
|
|||
<button
|
||||
type="button"
|
||||
onClick={() => setShowPassword(!showPassword)}
|
||||
className="absolute inset-y-0 right-0 pr-3 flex items-center text-secondary hover:text-primary transition-colors duration-200"
|
||||
className="absolute inset-y-0 right-0 flex items-center pr-3 text-secondary transition-colors duration-200 hover:text-primary"
|
||||
>
|
||||
<div className="relative w-4 h-4">
|
||||
<div className="relative h-4 w-4">
|
||||
<Eye
|
||||
className={cn(
|
||||
"absolute inset-0 h-4 w-4 transition-all duration-300 ease-in-out",
|
||||
showPassword ? "opacity-0 scale-75 rotate-12" : "opacity-100 scale-100 rotate-0"
|
||||
showPassword ? "scale-75 rotate-12 opacity-0" : "scale-100 rotate-0 opacity-100"
|
||||
)}
|
||||
/>
|
||||
<EyeClosed
|
||||
className={cn(
|
||||
"absolute inset-0 h-4 w-4 transition-all duration-300 ease-in-out",
|
||||
showPassword ? "opacity-100 scale-100 rotate-0" : "opacity-0 scale-75 -rotate-12"
|
||||
showPassword ? "scale-100 rotate-0 opacity-100" : "scale-75 -rotate-12 opacity-0"
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ export function FormField({ label, htmlFor, children, className, optional = fals
|
|||
<div className={cn("flex flex-col gap-1.5", className)}>
|
||||
<Label htmlFor={htmlFor}>
|
||||
{label}
|
||||
{optional && <span className="text-placeholder text-13"> (optional)</span>}
|
||||
{optional && <span className="text-13 text-placeholder"> (optional)</span>}
|
||||
</Label>
|
||||
{children}
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue