Skip to content

Commit

Permalink
Built site for gh-pages
Browse files Browse the repository at this point in the history
  • Loading branch information
mcanouil committed Mar 10, 2024
1 parent 0288b2c commit 07dcb93
Show file tree
Hide file tree
Showing 12 changed files with 146 additions and 206 deletions.
2 changes: 1 addition & 1 deletion .nojekyll
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4d07f5a6
7bc3d7e4
84 changes: 61 additions & 23 deletions example.html
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
<script src="example_files/libs/bootstrap/bootstrap.min.js"></script>
<link href="example_files/libs/bootstrap/bootstrap-icons.css" rel="stylesheet">
<link href="example_files/libs/bootstrap/bootstrap.min.css" rel="stylesheet" id="quarto-bootstrap" data-mode="light">
<script src="example_files/libs/quarto-contrib/iconify-1.0.8/iconify-icon.min.js"></script>
<script src="example_files/libs/quarto-contrib/iconify-2.0.0/iconify-icon.min.js"></script>


</head>
Expand Down Expand Up @@ -121,35 +121,35 @@ <h1 class="title">Iconify Quarto Extension</h1>
<tbody>
<tr class="odd">
<td><code>{{&lt; iconify exploding-head &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head" aria-label="Icon exploding-head from fluent-emoji Iconify.design set." title="Icon exploding-head from fluent-emoji Iconify.design set."></iconify-icon></p></td>
</tr>
<tr class="even">
<td><code>{{&lt; iconify exploding-head size=2xl &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head" style="font-size: 2em;"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head" style="font-size: 2em;" aria-label="Icon exploding-head from fluent-emoji Iconify.design set." title="Icon exploding-head from fluent-emoji Iconify.design set."></iconify-icon></p></td>
</tr>
<tr class="odd">
<td><code>{{&lt; iconify exploding-head size=5x rotate=180deg &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head" style="font-size: 5em;" rotate="180deg"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head" style="font-size: 5em;" aria-label="Icon exploding-head from fluent-emoji Iconify.design set." title="Icon exploding-head from fluent-emoji Iconify.design set." rotate="180deg"></iconify-icon></p></td>
</tr>
<tr class="even">
<td><code>{{&lt; iconify exploding-head size=Huge &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head" style="font-size: 2.5em;"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="fluent-emoji:exploding-head" style="font-size: 2.5em;" aria-label="Icon exploding-head from fluent-emoji Iconify.design set." title="Icon exploding-head from fluent-emoji Iconify.design set."></iconify-icon></p></td>
</tr>
<tr class="odd">
<td><code>{{&lt; iconify fluent-emoji-high-contrast 1st-place-medal &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="fluent-emoji-high-contrast:1st-place-medal"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="fluent-emoji-high-contrast:1st-place-medal" aria-label="Icon 1st-place-medal from fluent-emoji-high-contrast Iconify.design set." title="Icon 1st-place-medal from fluent-emoji-high-contrast Iconify.design set."></iconify-icon></p></td>
</tr>
<tr class="even">
<td><code>{{&lt; iconify twemoji 1st-place-medal &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="twemoji:1st-place-medal"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="twemoji:1st-place-medal" aria-label="Icon 1st-place-medal from twemoji Iconify.design set." title="Icon 1st-place-medal from twemoji Iconify.design set."></iconify-icon></p></td>
</tr>
<tr class="odd">
<td><code>{{&lt; iconify line-md loading-alt-loop &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="line-md:loading-alt-loop"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="line-md:loading-alt-loop" aria-label="Icon loading-alt-loop from line-md Iconify.design set." title="Icon loading-alt-loop from line-md Iconify.design set."></iconify-icon></p></td>
</tr>
<tr class="even">
<td><code>{{&lt; iconify fa6-brands apple width=50px height=10px rotate=90deg flip=vertical &gt;}}</code></td>
<td><p><iconify-icon inline="" icon="fa6-brands:apple" width="50px" flip="vertical" rotate="90deg"></iconify-icon></p></td>
<td><p><iconify-icon inline="" icon="fa6-brands:apple" aria-label="Icon apple from fa6-brands Iconify.design set." title="Icon apple from fa6-brands Iconify.design set." width="50px" flip="vertical" rotate="90deg"></iconify-icon></p></td>
</tr>
</tbody>
</table>
Expand Down Expand Up @@ -191,18 +191,7 @@ <h1 class="title">Iconify Quarto Extension</h1>
}
return false;
}
const clipboard = new window.ClipboardJS('.code-copy-button', {
text: function(trigger) {
const codeEl = trigger.previousElementSibling.cloneNode(true);
for (const childEl of codeEl.children) {
if (isCodeAnnotation(childEl)) {
childEl.remove();
}
}
return codeEl.innerText;
}
});
clipboard.on('success', function(e) {
const onCopySuccess = function(e) {
// button target
const button = e.trigger;
// don't keep focus
Expand Down Expand Up @@ -234,7 +223,47 @@ <h1 class="title">Iconify Quarto Extension</h1>
}, 1000);
// clear code selection
e.clearSelection();
}
const getTextToCopy = function(trigger) {
const codeEl = trigger.previousElementSibling.cloneNode(true);
for (const childEl of codeEl.children) {
if (isCodeAnnotation(childEl)) {
childEl.remove();
}
}
return codeEl.innerText;
}
const clipboard = new window.ClipboardJS('.code-copy-button:not([data-in-quarto-modal])', {
text: getTextToCopy
});
clipboard.on('success', onCopySuccess);
if (window.document.getElementById('quarto-embedded-source-code-modal')) {
// For code content inside modals, clipBoardJS needs to be initialized with a container option
// TODO: Check when it could be a function (https://github.com/zenorocha/clipboard.js/issues/860)
const clipboardModal = new window.ClipboardJS('.code-copy-button[data-in-quarto-modal]', {
text: getTextToCopy,
container: window.document.getElementById('quarto-embedded-source-code-modal')
});
clipboardModal.on('success', onCopySuccess);
}
var localhostRegex = new RegExp(/^(?:http|https):\/\/localhost\:?[0-9]*\//);
var mailtoRegex = new RegExp(/^mailto:/);
var filterRegex = new RegExp('/' + window.location.host + '/');
var isInternal = (href) => {
return filterRegex.test(href) || localhostRegex.test(href) || mailtoRegex.test(href);
}
// Inspect non-navigation links and adorn them if external
var links = window.document.querySelectorAll('a[href]:not(.nav-link):not(.navbar-brand):not(.toc-action):not(.sidebar-link):not(.sidebar-item-toggle):not(.pagination-link):not(.no-external):not([aria-hidden]):not(.dropdown-item):not(.quarto-navigation-tool):not(.about-link)');
for (var i=0; i<links.length; i++) {
const link = links[i];
if (!isInternal(link.href)) {
// undo the damage that might have been done by quarto-nav.js in the case of
// links that we want to consider external
if (link.dataset.originalHref !== undefined) {
link.href = link.dataset.originalHref;
}
}
}
function tippyHover(el, contentFn, onTriggerFn, onUntriggerFn) {
const config = {
allowHTML: true,
Expand Down Expand Up @@ -269,7 +298,11 @@ <h1 class="title">Iconify Quarto Extension</h1>
try { href = new URL(href).hash; } catch {}
const id = href.replace(/^#\/?/, "");
const note = window.document.getElementById(id);
return note.innerHTML;
if (note) {
return note.innerHTML;
} else {
return "";
}
});
}
const xrefs = window.document.querySelectorAll('a.quarto-xref');
Expand Down Expand Up @@ -317,7 +350,12 @@ <h1 class="title">Iconify Quarto Extension</h1>
if (window.Quarto?.typesetMath) {
window.Quarto.typesetMath(note);
}
return note.innerHTML;
// TODO in 1.5, we should make sure this works without a callout special case
if (note.classList.contains("callout")) {
return note.outerHTML;
} else {
return note.innerHTML;
}
}
}
for (var i=0; i<xrefs.length; i++) {
Expand Down
4 changes: 2 additions & 2 deletions example_files/libs/bootstrap/bootstrap.min.css

Large diffs are not rendered by default.

This file was deleted.

This file was deleted.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

14 changes: 0 additions & 14 deletions example_files/libs/quarto-contrib/iconify-2.2.1/iconify.min.js

This file was deleted.

115 changes: 0 additions & 115 deletions example_files/libs/quarto-contrib/iconify-2.2.1/size.css

This file was deleted.

2 changes: 2 additions & 0 deletions example_files/libs/quarto-html/quarto-syntax-highlighting.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions example_files/libs/quarto-html/quarto.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const layoutMarginEls = () => {
// Find any conflicting margin elements and add margins to the
// top to prevent overlap
const marginChildren = window.document.querySelectorAll(
".column-margin.column-container > * "
".column-margin.column-container > *, .margin-caption, .aside"
);

let lastBottom = 0;
Expand All @@ -19,7 +19,9 @@ const layoutMarginEls = () => {
marginChild.style.marginTop = null;
const top = marginChild.getBoundingClientRect().top + window.scrollY;
if (top < lastBottom) {
const margin = lastBottom - top;
const marginChildStyle = window.getComputedStyle(marginChild);
const marginBottom = parseFloat(marginChildStyle["marginBottom"]);
const margin = lastBottom - top + marginBottom;
marginChild.style.marginTop = `${margin}px`;
}
const styles = window.getComputedStyle(marginChild);
Expand Down
Loading

0 comments on commit 07dcb93

Please sign in to comment.