chore: better Prettier config for easier reviews

This commit is contained in:
2023-10-23 23:33:39 +02:00
parent a8781724d4
commit 71ea41695f
209 changed files with 4093 additions and 4114 deletions

View File

@ -1,8 +1,8 @@
import classNames from 'clsx'
import classNames from "clsx"
import type { ApplicationProps } from '..'
import type { ApplicationProps } from ".."
export type DirectionSidebar = 'left' | 'right'
export type DirectionSidebar = "left" | "right"
export interface SidebarProps {
direction: DirectionSidebar
@ -12,24 +12,24 @@ export interface SidebarProps {
}
export const Sidebar: React.FC<React.PropsWithChildren<SidebarProps>> = (
props
props,
) => {
const { direction, visible, children, path, isMobile } = props
return (
<nav
className={classNames(
'h-full-without-header visible z-50 flex bg-gray-200 drop-shadow-2xl transition-all dark:bg-gray-800',
"h-full-without-header visible z-50 flex bg-gray-200 drop-shadow-2xl transition-all dark:bg-gray-800",
{
'scrollbar-firefox-support right-0 top-0 flex-col space-y-1 overflow-y-auto':
direction === 'right',
'w-72': direction === 'right' && visible,
'invisible w-0 opacity-0': !visible,
'w-80': direction === 'left' && visible,
'max-w-max': typeof path !== 'string' && direction === 'left',
'right-0 top-0': direction === 'right' && isMobile,
absolute: isMobile
}
"scrollbar-firefox-support right-0 top-0 flex-col space-y-1 overflow-y-auto":
direction === "right",
"w-72": direction === "right" && visible,
"invisible w-0 opacity-0": !visible,
"w-80": direction === "left" && visible,
"max-w-max": typeof path !== "string" && direction === "left",
"right-0 top-0": direction === "right" && isMobile,
absolute: isMobile,
},
)}
>
{children}

View File

@ -1 +1 @@
export * from './Sidebar'
export * from "./Sidebar"