Skip to content

Commit 7f5f6fd

Browse files
committed
fixup! ✨(frontend) improve accessibility and styling of summary table
1 parent 3991731 commit 7f5f6fd

File tree

1 file changed

+11
-5
lines changed
  • src/frontend/apps/impress/src/features/docs/doc-table-content/components

1 file changed

+11
-5
lines changed

src/frontend/apps/impress/src/features/docs/doc-table-content/components/TableContent.tsx

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ export const TableContent = () => {
106106
$maxHeight="calc(50vh - 60px)"
107107
$zIndex={1000}
108108
$align="center"
109-
$padding="xs"
109+
$padding={isHover ? 'xs' : '0'}
110110
$justify="center"
111111
$position="relative"
112112
aria-label={t('Summary')}
@@ -128,18 +128,24 @@ export const TableContent = () => {
128128
>
129129
{!isHover && (
130130
<BoxButton
131-
onClick={() => (isHover ? onClose() : onOpen())}
131+
onClick={onOpen}
132+
$width="100%"
133+
$height="100%"
132134
$justify="center"
133135
$align="center"
134136
aria-label={t('Summary')}
135137
aria-expanded={isHover}
136138
aria-controls="toc-list"
137139
$css={css`
138-
transition: none !important;
140+
&:hover {
141+
background: ${colorsTokens['primary-100']};
142+
}
139143
&:focus-visible {
140144
outline: none;
141-
box-shadow: 0 0 0 2px ${colorsTokens['primary-400']};
142-
border-radius: 4px;
145+
box-shadow: 0 0 0 4px ${colorsTokens['primary-400']};
146+
background: ${colorsTokens['primary-100']};
147+
width: 90%;
148+
height: 90%;
143149
}
144150
`}
145151
>

0 commit comments

Comments
 (0)