mirror of
https://github.com/ryanoasis/nerd-fonts.git
synced 2025-01-25 03:32:02 +02:00
Reworks cheat sheet layout with flexbox and clean-up console.logs
This commit is contained in:
parent
f9ccf1c4a0
commit
fb920fc0fd
@ -46,6 +46,11 @@ a.nerd-font-button:before {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#icon-cheat-sheet .container {
|
||||||
|
max-width: none;
|
||||||
|
width: auto;
|
||||||
|
}
|
||||||
|
|
||||||
#main .nerd-font-buttons {
|
#main .nerd-font-buttons {
|
||||||
line-height: 4em;
|
line-height: 4em;
|
||||||
}
|
}
|
||||||
@ -62,6 +67,10 @@ a.nerd-font-button:before {
|
|||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
padding-top: 20px;
|
padding-top: 20px;
|
||||||
|
max-width: none;
|
||||||
|
justify-content: center;
|
||||||
|
display: flex;
|
||||||
|
flex-flow: row wrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
#glyphCheatSheet .column {
|
#glyphCheatSheet .column {
|
||||||
|
@ -12,7 +12,7 @@ style: container
|
|||||||
|
|
||||||
<input type="text" id="glyphSearch" placeholder="Search for glyphs/icons..." title="Type in a glyph name or hex codepoint" class="nerd-font-cheat-sheet-search" />
|
<input type="text" id="glyphSearch" placeholder="Search for glyphs/icons..." title="Type in a glyph name or hex codepoint" class="nerd-font-cheat-sheet-search" />
|
||||||
|
|
||||||
<div id="glyphCheatSheet" class="nerd-font-cheat-sheet container">
|
<div id="glyphCheatSheet" class="nerd-font-cheat-sheet">
|
||||||
<div class="column">
|
<div class="column">
|
||||||
<div class="nf nf-custom-c center"></div>
|
<div class="nf nf-custom-c center"></div>
|
||||||
<div class="class-name">nf-custom-c</div><div class="codepoint">e61e</div>
|
<div class="class-name">nf-custom-c</div><div class="codepoint">e61e</div>
|
||||||
|
2
site.js
2
site.js
@ -232,7 +232,6 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||||||
'mouseenter',
|
'mouseenter',
|
||||||
function (e) {
|
function (e) {
|
||||||
if (e.target.classList.contains('column')) {
|
if (e.target.classList.contains('column')) {
|
||||||
console.log('entered column');
|
|
||||||
// add Node
|
// add Node
|
||||||
const newNode = document.createElement('span');
|
const newNode = document.createElement('span');
|
||||||
const copyTextNode = document.createElement('span');
|
const copyTextNode = document.createElement('span');
|
||||||
@ -264,7 +263,6 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||||||
'mouseleave',
|
'mouseleave',
|
||||||
function (e) {
|
function (e) {
|
||||||
if (e.target.classList.contains('column')) {
|
if (e.target.classList.contains('column')) {
|
||||||
console.log('left column');
|
|
||||||
e.target.querySelector('.glyph-popout-copy-clipboard').remove();
|
e.target.querySelector('.glyph-popout-copy-clipboard').remove();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user