Skip to content

Commit

Permalink
Screenreader improve hidden accessible
Browse files Browse the repository at this point in the history
  • Loading branch information
melloware committed Jan 1, 2025
1 parent d98058a commit 723e03f
Showing 1 changed file with 5 additions and 22 deletions.
27 changes: 5 additions & 22 deletions components/lib/componentbase/ComponentBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,12 @@ import { ObjectUtils, classNames, mergeProps } from '../utils/Utils';

const baseStyle = `
.p-hidden-accessible {
border: 0;
padding: 0;
margin: -1px;
position: absolute;
height: 1px;
width: 1px;
overflow: hidden;
clip: rect(0, 0, 0, 0);
clip-path: inset(50%);
pointer-events: none;
opacity: 0;
white-space: nowrap;
}
.p-hidden-accessible input,
.p-hidden-accessible select {
transform: scale(0);
}
.p-overflow-hidden {
overflow: hidden;
padding-right: var(--scrollbar-width);
Expand Down Expand Up @@ -388,16 +377,10 @@ const commonStyle = `
}
.p-sr-only {
border: 0;
clip: rect(1px, 1px, 1px, 1px);
clip-path: inset(50%);
height: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
width: 1px;
word-wrap: normal;
pointer-events: none;
opacity: 0;
white-space: nowrap;
}
/* @todo Refactor */
Expand Down

0 comments on commit 723e03f

Please sign in to comment.