Skip to content

Commit

Permalink
fix fontawesome
Browse files Browse the repository at this point in the history
  • Loading branch information
fantkolja committed Nov 13, 2024
1 parent c7efd87 commit 8e477a3
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 25 deletions.
27 changes: 8 additions & 19 deletions src/css/clipboard.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
display: inline-block;
margin-left: 0.5rem;
margin-right: 0.5rem;
position: relative;
}

a.copy-code-button:focus,
Expand All @@ -13,35 +14,23 @@ a.copy-code-button:hover {

.copy-code-button:hover::after {
content: attr(data-title);
color: var(--pre-annotation-font-color);
line-height: 1;
position: absolute;
top: -20px;
right: 0%;
left: auto;
top: -26px;
left: 50%;
transform: translate(-50%, 0);
margin: 0;
padding: 3px;
padding: 5px;
text-align: center;
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.06);
background: var(--neutral-lighter);
color: var(--secondary-text);
border: 1px solid var(--pre-border-color);
box-sizing: border-box;
border-radius: 3px;
border-radius: 8px;
min-width: 80px;
}

.copy-code-button:hover::before {
border-left: 7px solid transparent;
border-right: 7px solid transparent;
border-bottom: 10px solid var(--pre-border-color);
position: absolute;
content: "";
box-shadow: inset 0 0 1px #bec0c1;
bottom: -27px;
right: auto;
left: auto;
}

.doc .listingblock code /*[data-lang]*/ + .source-type-box {
position: absolute;
top: -20px;
Expand All @@ -62,7 +51,7 @@ a.copy-code-button:hover {
border-right: 1px solid var(--pre-border-color);
}

.doc .listingblock:hover code /*[data-lang]*/ + .source-type-box {
.doc .listingblock code /*[data-lang]*/ + .source-type-box {
display: flex;
}

Expand Down
6 changes: 3 additions & 3 deletions src/css/doc.css
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
font-weight: 450;
hyphens: none;
line-height: 1.3;
margin: 1rem 0 0;
margin: 1.1rem 0 0;
font-size: 1.09em;
}

Expand Down Expand Up @@ -138,7 +138,7 @@ strong.beta {
font-weight: var(--heading-font-weight);
hyphens: none;
line-height: 1.3;
margin: 1rem 0 0;
margin: 1.1rem 0 0;
}

.doc > h1.page:first-child {
Expand Down Expand Up @@ -315,7 +315,7 @@ strong.beta {
.doc .verseblock,
.doc .quoteblock,
.doc .partintro {
margin: 1rem 0 0;
margin: 1.1rem 0 0;
}

.doc .ulist.tablelist {
Expand Down
2 changes: 1 addition & 1 deletion src/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@

.article-banner p {
font-size: calc(14 / var(--rem-base) * 1rem);
margin: 0 1rem 0 0;
margin: 0 1.1rem 0 0;
margin-bottom: 10px;
}

Expand Down
2 changes: 1 addition & 1 deletion src/js/08-copy-to-clipboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
var copyButton = document.createElement('a')
copyButton.className = 'copy-code-button'
copyButton.dataset.title = 'Copy'
copyButton.appendChild(document.createElement('i')).className = 'far fa-copy'
copyButton.appendChild(document.createElement('i')).className = 'fa-regular fa-copy'
var dataSource = document.createElement('span')
dataSource.className = 'data-source'
if (codeBlock.dataset.lang) {
Expand Down
2 changes: 1 addition & 1 deletion src/partials/head-scripts.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,5 @@
<!-- End Kapa snippet -->
{{/with}}

<script src="https://kit.fontawesome.com/11f046e3f7.js" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.6.0/js/all.min.js" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>

0 comments on commit 8e477a3

Please sign in to comment.