Skip to content

Commit

Permalink
serve code snippet buttons as image file
Browse files Browse the repository at this point in the history
  • Loading branch information
whitep4nth3r committed Feb 12, 2025
1 parent 792e982 commit 646fe4d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/_components/codeBlock.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const CodeBlock = ({ code, lang, isDiff }) => {
<div class="post__codeBlock">
<div class="post__codeBlockBar">
<span class="post__codeBlockDots">
<svg xmlns="http://www.w3.org/2000/svg" width="54" height="14" viewBox="0 0 54 14"><g fill="none" fill-rule="evenodd" transform="translate(1 1)"><circle cx="6" cy="6" r="6" fill="#f0047f" stroke="#f0047f" stroke-width=".5"></circle><circle cx="26" cy="6" r="6" fill="#fc814a" stroke="#fc814a" stroke-width=".5"></circle><circle cx="46" cy="6" r="6" fill="#a6e22e" stroke="#a6e22e" stroke-width=".5"></circle></g></svg>
<img src="/img/snippet_buttons.svg" alt="" />
</span>
<button type="button" class="post__codeBlockCopyButton" data-copy="${thisCodeId}">
<svg xmlns="http://www.w3.org/2000/svg" height="24" width="24" viewBox="0 0 384 512"><path d="M192 0c-41.8 0-77.4 26.7-90.5 64L64 64C28.7 64 0 92.7 0 128L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64l-37.5 0C269.4 26.7 233.8 0 192 0zm0 64a32 32 0 1 1 0 64 32 32 0 1 1 0-64zM112 192l160 0c8.8 0 16 7.2 16 16s-7.2 16-16 16l-160 0c-8.8 0-16-7.2-16-16s7.2-16 16-16z" fill="currentColor" /></svg>
Expand Down
7 changes: 7 additions & 0 deletions src/_public/img/snippet_buttons.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 646fe4d

Please sign in to comment.