Skip to content

Commit

Permalink
Add iosevka font
Browse files Browse the repository at this point in the history
 - integration into terminal
 - integrate into layer picker placeholder
  • Loading branch information
yanfali committed Feb 9, 2022
1 parent 43c2970 commit c9f795a
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 6 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"test:cypress:ci": "start-server-and-test dev http-get://localhost:3000 test:cypress"
},
"dependencies": {
"@fontsource/iosevka": "^4.5.2",
"@fontsource/montserrat": "^4.5.1",
"@fontsource/roboto": "^4.5.1",
"@fontsource/roboto-mono": "^4.5.0",
Expand Down
11 changes: 7 additions & 4 deletions src/components/redesign/ConsoleControl.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,18 @@ import { FitAddon } from 'xterm-addon-fit';
export default defineComponent({
name: 'console-control',
mounted() {
this.term.open(this.$refs.terminal);
this.fitAddon.fit();
this.term.write('hello world! https://config.qmk.fm');
window.setTimeout(() => {
this.term.open(this.$refs.terminal);
this.fitAddon.fit();
this.term.write('hello world! https://config.qmk.fm');
}, 500);
},
setup() {
const term = new Terminal({
rows: 25,
cols: 80,
fontFamily: 'Courier',
fontFamily: 'Iosevka',
fontWeight: 400,
theme: { background: '#ccd9f7', foreground: '#333' },
scrollback: 400
});
Expand Down
9 changes: 7 additions & 2 deletions src/components/redesign/LayerPicker.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<template>
<div class="grid grid-layout">
<div class="header mt-16px m-auto font-bold">LAYER</div>
<div class="layer-left flex flex-col-reverse">
<div class="layers-common layer-left flex flex-col-reverse">
<div v-for="layer in leftColumn" :key="layer" class="layer-button">
{{ layer }}
</div>
</div>
<div class="layer-right flex flex-col-reverse">
<div class="layer-common layer-right flex flex-col-reverse">
<div v-for="layer in rightColumn" :key="layer" class="layer-button">
{{ layer }}
</div>
Expand Down Expand Up @@ -43,6 +43,11 @@ export default defineComponent({
.header {
grid-area: head;
}
.layer-common {
font-family: Iosevka;
font-weight: normal;
font-weight: 400;
}
.layer-left {
grid-area: layerLeft;
}
Expand Down
2 changes: 2 additions & 0 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ import '@fontsource/roboto-mono/400.css';
import '@fontsource/roboto/400.css';
import '@fontsource/roboto/700.css';
import '@fontsource/montserrat/400.css';
import '@fontsource/iosevka/400.css';
import '@fontsource/iosevka/700.css';
import 'xterm/css/xterm.css';
import 'virtual:windi.css';
import 'virtual:windi-devtools';
Expand Down
28 changes: 28 additions & 0 deletions todo.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,31 @@ star
trash-2
upload-cloud
3. consider how to do GMK font positioning for Alphas
4. fonts
[buildPlans.iosevka-for-qmk]
family = "Iosevka for QMK"
spacing = "term"
serifs = "sans"
no-cv-ss = true
no-ligation = true

[buildPlans.iosevka-for-qmk.variants.design]
lower-delta = "flat-top"
lower-lambda = "straight-turn"
lower-mu = "tailless"

[buildPlans.iosevka-for-qmk.weights.regular]
shape = 400
menu = 400
css = 400

[buildPlans.iosevka-for-qmk.weights.bold]
shape = 700
menu = 700
css = 700

[buildPlans.iosevka-for-qmk.slopes.upright]
angle = 0
shape = "upright"
menu = "upright"
css = "normal"
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1294,6 +1294,11 @@
minimatch "^3.0.4"
strip-json-comments "^3.1.1"

"@fontsource/iosevka@^4.5.2":
version "4.5.2"
resolved "https://registry.yarnpkg.com/@fontsource/iosevka/-/iosevka-4.5.2.tgz#e930d4711d5501cebee8b7de1d6b071543d86d36"
integrity sha512-1llgLcHtwZf8cKYbCMZ4z+zD+iDuHrpAQGjoVKkh0HUuLtBL0fB+6+LyhCiYlehN6PTdS6pRsq4gLvvO5GkAug==

"@fontsource/montserrat@^4.5.1":
version "4.5.1"
resolved "https://registry.yarnpkg.com/@fontsource/montserrat/-/montserrat-4.5.1.tgz#64a33ffdb77bbc63484c0321710bed272cc5b16f"
Expand Down

0 comments on commit c9f795a

Please sign in to comment.