Skip to content

Commit

Permalink
Version 1.1.5
Browse files Browse the repository at this point in the history
- Fixed an error where code could not be copied if it was preceded by a space
- Empty code blocks will now *not* get a copy button
  • Loading branch information
Martinomagnifico committed Dec 1, 2023
1 parent fe43753 commit d7e6cef
Show file tree
Hide file tree
Showing 54 changed files with 2,264 additions and 1,693 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Changelog

## [1.1.5] - 2023-11-17

### Changed
- Fixed an error where code could not be copied if it was preceded by a space
- Empty code blocks will now *not* get a copy button


## [1.1.4] - 2023-11-05

### Changed
Expand Down
63 changes: 52 additions & 11 deletions demo/assets/css/demo.css
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ ol.twocol li:before, .twocol li:before {

.small, .reveal small {
font-size: calc(0.7 * var(--r-main-font-size));
margin: var(--r-block-margin) 0;
}
.small code, .reveal small code {
font-size: 0.7em;
Expand All @@ -60,10 +59,7 @@ p code {
white-space: pre-wrap;
}
.reveal code.hljs td {
line-height: 1.5;
}
.reveal code.hljs > span {
line-height: 1.5;
line-height: 1.4;
}

p.code, p code, small code, .small code, li code {
Expand Down Expand Up @@ -91,7 +87,7 @@ p.code, p code, small code, .small code, li code {
--r-main-font-size: 36px;
--r-block-margin: 1.8rem;
--code-full-bg: #142433;
--code-rgba-bg: rgba(50, 65, 80, 0.4);
--code-rgba-bg: rgba(91, 102, 112, 0.3);
}

.reveal .slides ul li, .reveal .slides ol li {
Expand All @@ -104,24 +100,69 @@ p.code, p code, small code, .small code, li code {
--r-link-color-hover: #0373bd;
}

.demoembed {
width: 768px;
height: 400px;
margin: 64px auto;
}

.reveal.embedded {
border: 4px solid transparent;
border-radius: 8px;
}
.reveal.embedded:not(.focused) {
cursor: pointer;
}
.reveal.embedded.focused {
border-color: #42affa;
box-shadow: 0 4px 16px rgba(5, 21, 37, 0.3);
}
.reveal.embedded .progress {
background: rgba(66, 175, 250, 0.3);
font-size: 10px;
height: 0.3em;
border-radius: 0.25em;
left: 0.5em;
bottom: 0.5em;
right: 0.5em;
width: calc(100% - 1em);
overflow: hidden;
}

a.github-corner {
position: fixed;
position: sticky;
border: none;
pointer-events: initial;
z-index: 2;
padding: 0;
top: 0;
left: 0;
width: clamp(50px, 8vmax, 80px);
display: flex;
flex-direction: column;
line-height: 0;
width: max-content;
height: max-content;
opacity: 0.5;
transition: opacity 0.3s;
color: var(--c-theme-color, white);
}
.rtl a.github-corner {
left: auto;
margin: 0 0 0 auto;
right: 0;
}
a.github-corner.bottom {
top: auto;
bottom: 3px;
position: sticky;
top: 100%;
margin-top: auto;
top: calc(100% - 70px);
}
.reveal.embedded a.github-corner, .reveal-viewport.reveal-scroll a.github-corner {
display: none;
}
a.github-corner svg {
line-height: 0;
width: 75px;
height: 75px;
}

a.github-corner:hover {
Expand Down
2 changes: 1 addition & 1 deletion demo/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ <h4>Credits</h4>
const pluginCheck = (plugs) => plugs.reduce((a, p) => typeof window[p] === "function" ? (a.push(window[p]), a) : (console.warn(`Plugin "${p}" does not exist.`), a), []);

let revealdeck = new Reveal(deck);
revealdeck.initialize({
revealdeck.initialize({
history: true,
overview: false,
center: true,
Expand Down
4 changes: 2 additions & 2 deletions demo/dist/reveal.css

Large diffs are not rendered by default.

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

Large diffs are not rendered by default.

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

Large diffs are not rendered by default.

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

Large diffs are not rendered by default.

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

Large diffs are not rendered by default.

16 changes: 9 additions & 7 deletions demo/dist/theme/beige.css
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,18 @@ section.has-dark-background, section.has-dark-background h1, section.has-dark-ba
--r-link-color-hover: #c0a86e;
--r-selection-background-color: rgba(79, 64, 28, 0.99);
--r-selection-color: #fff;
--r-overlay-element-bg-color: 0, 0, 0;
--r-overlay-element-fg-color: 240, 240, 240;
}

.reveal-viewport {
background: #f7f2d3;
background: -moz-radial-gradient(center, circle cover, white 0%, #f7f2d3 100%);
background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%, white), color-stop(100%, #f7f2d3));
background: -webkit-radial-gradient(center, circle cover, white 0%, #f7f2d3 100%);
background: -o-radial-gradient(center, circle cover, white 0%, #f7f2d3 100%);
background: -ms-radial-gradient(center, circle cover, white 0%, #f7f2d3 100%);
background: radial-gradient(center, circle cover, white 0%, #f7f2d3 100%);
background: rgb(247, 242, 211);
background: -moz-radial-gradient(center, circle cover, rgb(255, 255, 255) 0%, rgb(247, 242, 211) 100%);
background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%, rgb(255, 255, 255)), color-stop(100%, rgb(247, 242, 211)));
background: -webkit-radial-gradient(center, circle cover, rgb(255, 255, 255) 0%, rgb(247, 242, 211) 100%);
background: -o-radial-gradient(center, circle cover, rgb(255, 255, 255) 0%, rgb(247, 242, 211) 100%);
background: -ms-radial-gradient(center, circle cover, rgb(255, 255, 255) 0%, rgb(247, 242, 211) 100%);
background: radial-gradient(center, circle cover, rgb(255, 255, 255) 0%, rgb(247, 242, 211) 100%);
background-color: var(--r-background-color);
}

Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/black-contrast.css
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ section.has-light-background, section.has-light-background h1, section.has-light
--r-link-color-hover: #8dcffc;
--r-selection-background-color: #bee4fd;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 240, 240, 240;
--r-overlay-element-fg-color: 0, 0, 0;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/black.css
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ section.has-light-background, section.has-light-background h1, section.has-light
--r-link-color-hover: #8dcffc;
--r-selection-background-color: rgba(66, 175, 250, 0.75);
--r-selection-color: #fff;
--r-overlay-element-bg-color: 240, 240, 240;
--r-overlay-element-fg-color: 0, 0, 0;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/blood.css
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ section.has-light-background, section.has-light-background h1, section.has-light
--r-link-color-hover: #dd5566;
--r-selection-background-color: #a23;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 240, 240, 240;
--r-overlay-element-fg-color: 0, 0, 0;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/dracula.css
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ section.has-light-background, section.has-light-background h1, section.has-light
--r-link-color-hover: #8BE9FD;
--r-selection-background-color: #44475A;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 240, 240, 240;
--r-overlay-element-fg-color: 0, 0, 0;
}

.reveal-viewport {
Expand Down
16 changes: 9 additions & 7 deletions demo/dist/theme/league.css
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,18 @@ section.has-light-background, section.has-light-background h1, section.has-light
--r-link-color-hover: #71e9f4;
--r-selection-background-color: #FF5E99;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 240, 240, 240;
--r-overlay-element-fg-color: 0, 0, 0;
}

.reveal-viewport {
background: #1c1e20;
background: -moz-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%);
background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%, #555a5f), color-stop(100%, #1c1e20));
background: -webkit-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%);
background: -o-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%);
background: -ms-radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%);
background: radial-gradient(center, circle cover, #555a5f 0%, #1c1e20 100%);
background: rgb(28, 30, 32);
background: -moz-radial-gradient(center, circle cover, rgb(85, 90, 95) 0%, rgb(28, 30, 32) 100%);
background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%, rgb(85, 90, 95)), color-stop(100%, rgb(28, 30, 32)));
background: -webkit-radial-gradient(center, circle cover, rgb(85, 90, 95) 0%, rgb(28, 30, 32) 100%);
background: -o-radial-gradient(center, circle cover, rgb(85, 90, 95) 0%, rgb(28, 30, 32) 100%);
background: -ms-radial-gradient(center, circle cover, rgb(85, 90, 95) 0%, rgb(28, 30, 32) 100%);
background: radial-gradient(center, circle cover, rgb(85, 90, 95) 0%, rgb(28, 30, 32) 100%);
background-color: var(--r-background-color);
}

Expand Down
7 changes: 2 additions & 5 deletions demo/dist/theme/moon.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@
/**
* Solarized colors by Ethan Schoonover
*/
html * {
color-profile: sRGB;
rendering-intent: auto;
}

section.has-light-background, section.has-light-background h1, section.has-light-background h2, section.has-light-background h3, section.has-light-background h4, section.has-light-background h5, section.has-light-background h6 {
color: #222;
}
Expand Down Expand Up @@ -44,6 +39,8 @@ section.has-light-background, section.has-light-background h1, section.has-light
--r-link-color-hover: #78b9e6;
--r-selection-background-color: #d33682;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 240, 240, 240;
--r-overlay-element-fg-color: 0, 0, 0;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/night.css
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ section.has-light-background, section.has-light-background h1, section.has-light
--r-link-color-hover: #f3d7ac;
--r-selection-background-color: #e7ad52;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 240, 240, 240;
--r-overlay-element-fg-color: 0, 0, 0;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/serif.css
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ section.has-dark-background, section.has-dark-background h1, section.has-dark-ba
--r-link-color-hover: #8b7c69;
--r-selection-background-color: #26351C;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 0, 0, 0;
--r-overlay-element-fg-color: 240, 240, 240;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/simple.css
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ section.has-dark-background, section.has-dark-background h1, section.has-dark-ba
--r-link-color-hover: #0000f1;
--r-selection-background-color: rgba(0, 0, 0, 0.99);
--r-selection-color: #fff;
--r-overlay-element-bg-color: 0, 0, 0;
--r-overlay-element-fg-color: 240, 240, 240;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/sky.css
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ section.has-dark-background, section.has-dark-background h1, section.has-dark-ba
--r-link-color-hover: #74a7cb;
--r-selection-background-color: #134674;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 0, 0, 0;
--r-overlay-element-fg-color: 240, 240, 240;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/solarized.css
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ html * {
--r-link-color-hover: #78b9e6;
--r-selection-background-color: #d33682;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 0, 0, 0;
--r-overlay-element-fg-color: 240, 240, 240;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/white-contrast.css
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ section.has-dark-background, section.has-dark-background h1, section.has-dark-ba
--r-link-color-hover: #6ca0e8;
--r-selection-background-color: #98bdef;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 0, 0, 0;
--r-overlay-element-fg-color: 240, 240, 240;
}

.reveal-viewport {
Expand Down
2 changes: 2 additions & 0 deletions demo/dist/theme/white.css
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ section.has-dark-background, section.has-dark-background h1, section.has-dark-ba
--r-link-color-hover: #6ca0e8;
--r-selection-background-color: #98bdef;
--r-selection-color: #fff;
--r-overlay-element-bg-color: 0, 0, 0;
--r-overlay-element-fg-color: 240, 240, 240;
}

.reveal-viewport {
Expand Down
6 changes: 5 additions & 1 deletion demo/plugin/copycode/copycode.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/*****************************************************************
*
* CopyCode for Reveal.js
* Version 1.1.4
* Version 1.1.5
*
* @author: Martijn De Jongh (Martino), martijn.de.jongh@gmail.com
* https://github.com/martinomagnifico
Expand Down Expand Up @@ -42,11 +42,15 @@
.codeblock pre .code-copy-button {
display: none;
}
.codeblock code.hljs {
min-height: 1.2em;
}
.codeblock > button {
opacity: 0.5;
z-index: 1;
display: flex;
position: absolute;
max-height: 100%;
right: 0;
right: calc(var(--cc-offset, 0) * 1em);
top: 0;
Expand Down
Loading

0 comments on commit d7e6cef

Please sign in to comment.