feat: add sr-only h1 title per-page

This commit is contained in:
Nicola Zambello 2023-02-18 23:45:47 +01:00
parent 50fb9af24f
commit eccd7b5d96
Signed by: nzambello
GPG key ID: 56E4A92C2C1E50BA
4 changed files with 61 additions and 2 deletions

View file

@ -198,6 +198,21 @@ export default function ImportExportPage() {
return (
<div>
<h1
style={{
position: 'absolute',
width: '1px',
height: '1px',
padding: 0,
margin: '-1px',
overflow: 'hidden',
clip: 'rect(0,0,0,0)',
whiteSpace: 'nowrap',
border: 0
}}
>
Import/Export
</h1>
<Tabs
radius="sm"
defaultValue="import"

View file

@ -92,6 +92,21 @@ export default function LoginPage() {
return (
<Box sx={{ maxWidth: 300 }} mx="auto">
<h1
style={{
position: 'absolute',
width: '1px',
height: '1px',
padding: 0,
margin: '-1px',
overflow: 'hidden',
clip: 'rect(0,0,0,0)',
whiteSpace: 'nowrap',
border: 0
}}
>
Login
</h1>
<Form method="post" noValidate>
<TextInput
mb={12}

View file

@ -71,6 +71,21 @@ export default function Projects() {
return (
<div>
<h1
style={{
position: 'absolute',
width: '1px',
height: '1px',
padding: 0,
margin: '-1px',
overflow: 'hidden',
clip: 'rect(0,0,0,0)',
whiteSpace: 'nowrap',
border: 0
}}
>
Projects
</h1>
<Paper
component="fieldset"
aria-controls="projects"

View file

@ -1,4 +1,4 @@
import { Box, Paper } from '@mantine/core';
import { Box, Paper, Title } from '@mantine/core';
import { MetaFunction, LoaderArgs, redirect, json } from '@remix-run/node';
import { useLoaderData } from '@remix-run/react';
import { getTimeEntries } from '~/models/timeEntry.server';
@ -28,7 +28,21 @@ export default function ReportPage() {
return (
<>
<h1>Report</h1>
<h1
style={{
position: 'absolute',
width: '1px',
height: '1px',
padding: 0,
margin: '-1px',
overflow: 'hidden',
clip: 'rect(0,0,0,0)',
whiteSpace: 'nowrap',
border: 0
}}
>
Report
</h1>
<Paper p="lg" radius="md">
Coming soon
</Paper>