diff --git a/apps/demo/src/App.tsx b/apps/demo/src/App.tsx index 4a42bb1..b901cf2 100644 --- a/apps/demo/src/App.tsx +++ b/apps/demo/src/App.tsx @@ -45,11 +45,12 @@ const preferredScheme = window.matchMedia("(prefers-color-scheme: dark)") export const App = () => { const [locale] = useState("en-US"); const [theme, setTheme] = useState( - (sessionStorage.getItem("c-theme") as Theme | null) ?? preferredScheme.theme + (sessionStorage.getItem("c-theme") as Theme | null) ?? + preferredScheme.theme, ); const [variant, setVariant] = useState( (sessionStorage.getItem("c-variant") as Variant | null) ?? - preferredScheme.variant + preferredScheme.variant, ); const activeTheme = useMemo(() => THEMES[theme][variant], [theme, variant]); const modal = useModal(); @@ -97,7 +98,7 @@ export const App = () => { setTheme(e.target.value as Theme); if (THEMES[e.target.value as Theme][variant] === undefined) { setVariant( - variant === Variant.LIGHT ? Variant.DARK : Variant.LIGHT + variant === Variant.LIGHT ? Variant.DARK : Variant.LIGHT, ); } }} @@ -112,7 +113,7 @@ export const App = () => { } onClick={() => { setVariant( - variant === Variant.LIGHT ? Variant.DARK : Variant.LIGHT + variant === Variant.LIGHT ? Variant.DARK : Variant.LIGHT, ); }} disabled={ diff --git a/apps/demo/src/Create.tsx b/apps/demo/src/Create.tsx index 6b63a8a..5648b16 100644 --- a/apps/demo/src/Create.tsx +++ b/apps/demo/src/Create.tsx @@ -55,7 +55,9 @@ export const Create = (props: PageProps) => { >
-

General Information

+

+ General Information +

You are about to add a new character to the collection @@ -91,7 +93,9 @@ export const Create = (props: PageProps) => {
-

Bio

+

+ Bio +

Please be exhaustive, every detail counts! @@ -127,7 +131,9 @@ export const Create = (props: PageProps) => {
-

Add pictures

+

+ Add pictures +

{ // Set the pagination length. pagination.setPagesCount( - Math.ceil(sortedDatabase.length / pagination.pageSize) + Math.ceil(sortedDatabase.length / pagination.pageSize), ); // Select the rows to display on the current page. setRows( sortedDatabase.slice( (pagination.page - 1) * pagination.pageSize, - pagination.page * pagination.pageSize - ) + pagination.page * pagination.pageSize, + ), ); setIsLoading(false); }, [pagination.page, sortModel, modal.isOpen, refresh]); @@ -138,13 +137,13 @@ export const Home = ({ modal }: { modal: PageProps }) => { return; } const index = database.findIndex( - (character) => character.id === params.row.id + (character) => character.id === params.row.id, ); database.splice(index, 1); setRefresh(refresh + 1); toast( "Character deleted successfully", - VariantType.WARNING + VariantType.WARNING, ); }} icon={delete}