Skip to content

Commit

Permalink
reader mode accessibility, bug fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
hakimel committed Oct 12, 2023
1 parent 198cbc4 commit a7d0916
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 60 deletions.
54 changes: 2 additions & 52 deletions css/reveal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -1894,6 +1894,7 @@ $notesWidthPercent: 25%;
.reveal .controls,
.reveal .progress,
.reveal .playback,
.reveal .backgrounds,
.reveal .slide-number {
display: none !important;
}
Expand Down Expand Up @@ -1953,18 +1954,6 @@ $notesWidthPercent: 25%;
transform-origin: 0 0 !important;
}

.reveal section.stack {
position: relative !important;
page-break-after: avoid !important;
height: auto !important;
min-height: auto !important;
}

/* Slide backgrounds are nested inside of the page in reader mode */
.reveal .backgrounds {
display: none;
}

.reveal .slide-background {
display: block !important;
position: absolute;
Expand All @@ -1977,45 +1966,6 @@ $notesWidthPercent: 25%;
opacity: 1;
touch-action: manipulation;
}

/* Display slide speaker notes when 'showNotes' is enabled */
.reveal.show-notes {
max-width: none;
max-height: none;
}
.reveal .speaker-notes-pdf {
display: block;
width: 100%;
height: auto;
max-height: none;
top: auto;
right: auto;
bottom: auto;
left: auto;
z-index: 100;
}

/* Layout option which makes notes appear on a separate page */
.reveal .speaker-notes-pdf[data-layout="separate-page"] {
position: relative;
color: inherit;
background-color: transparent;
padding: 20px;
page-break-after: always;
border: 0;
}

/* Display slide numbers when 'slideNumber' is enabled */
.reveal .slide-number-pdf {
display: block;
position: absolute;
font-size: 14px;
}

/* This accessibility tool is not useful in PDF and breaks it visually */
.aria-status {
display: none;
}
}

.reveal-viewport.reveal-reader[data-reader-scroll-bar="true"]::-webkit-scrollbar,
Expand Down Expand Up @@ -2077,7 +2027,7 @@ $notesWidthPercent: 25%;
left: 0;
border-radius: var(--r-reader-progress-width);
background-color: rgba(var(--r-overlay-element-bg-color), 1);
z-index: 10;
z-index: 11;
transition: background-color 0.2s ease, height 0.4s ease;
}

Expand Down
4 changes: 2 additions & 2 deletions dist/reveal.css

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/reveal.esm.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/reveal.esm.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/reveal.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/reveal.js.map

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions js/reveal.js
Original file line number Diff line number Diff line change
Expand Up @@ -1577,6 +1577,10 @@ export default function( revealElement, options ) {
}
}

requestAnimationFrame( () => {
announceStatus( getStatusText( currentSlide ) );
});

dispatchSlideChanged();

}
Expand Down

0 comments on commit a7d0916

Please sign in to comment.