mirror of
https://github.com/eigilnikolajsen/commit-mono.git
synced 2024-09-11 18:37:12 +03:00
fix windows naming issue, bump to version 142
This commit is contained in:
parent
83be8d5052
commit
9da322eb1e
4
404.html
4
404.html
@ -1,4 +1,4 @@
|
|||||||
<!doctype html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
@ -19,7 +19,7 @@
|
|||||||
<style>
|
<style>
|
||||||
@font-face {
|
@font-face {
|
||||||
font-family: "CommitMono";
|
font-family: "CommitMono";
|
||||||
src: url("/src/fonts/fontlab/CommitMonoV141-VF.woff2");
|
src: url("/src/fonts/fontlab/CommitMonoV142-VF.woff2");
|
||||||
font-style: normal;
|
font-style: normal;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-display: swap;
|
font-display: swap;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
<!doctype html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
@ -1190,7 +1190,7 @@
|
|||||||
<div tabindex="0" id="block_tab_end"></div>
|
<div tabindex="0" id="block_tab_end"></div>
|
||||||
</div>
|
</div>
|
||||||
<script>
|
<script>
|
||||||
const versionOfCommitMono = "V141"
|
const versionOfCommitMono = "V142"
|
||||||
let fontsLoaded = false
|
let fontsLoaded = false
|
||||||
const commitMono = new FontFace(
|
const commitMono = new FontFace(
|
||||||
"CommitMono",
|
"CommitMono",
|
||||||
@ -1198,7 +1198,7 @@
|
|||||||
{
|
{
|
||||||
style: "normal",
|
style: "normal",
|
||||||
weight: "400",
|
weight: "400",
|
||||||
},
|
}
|
||||||
)
|
)
|
||||||
// Add to the document.fonts (FontFaceSet)
|
// Add to the document.fonts (FontFaceSet)
|
||||||
document.fonts.add(commitMono)
|
document.fonts.add(commitMono)
|
||||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-200Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-200Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-200Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-200Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-225Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-225Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-225Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-225Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-250Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-250Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-250Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-250Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-275Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-275Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-275Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-275Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-300Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-300Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-300Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-300Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-325Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-325Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-325Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-325Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-350Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-350Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-350Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-350Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-375Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-375Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-375Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-375Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-400Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-400Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-400Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-400Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-425Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-425Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-425Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-425Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-450Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-450Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-450Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-450Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-475Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-475Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-475Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-475Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-500Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-500Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-500Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-500Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-525Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-525Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-525Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-525Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-550Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-550Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-550Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-550Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-575Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-575Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-575Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-575Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-600Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-600Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-600Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-600Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-625Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-625Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-625Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-625Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-650Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-650Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-650Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-650Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-675Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-675Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-675Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-675Regular.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-700Italic.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-700Italic.otf
Normal file
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-700Regular.otf
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-700Regular.otf
Normal file
Binary file not shown.
Binary file not shown.
BIN
src/fonts/fontlab/CommitMonoV142-VF.woff2
Normal file
BIN
src/fonts/fontlab/CommitMonoV142-VF.woff2
Normal file
Binary file not shown.
@ -45,7 +45,7 @@ async function updateCodeFont() {
|
|||||||
.load(
|
.load(
|
||||||
`/src/fonts/fontlab/CommitMono${versionOfCommitMono}-${websiteData.weight}${
|
`/src/fonts/fontlab/CommitMono${versionOfCommitMono}-${websiteData.weight}${
|
||||||
websiteData.italic ? "Italic" : "Regular"
|
websiteData.italic ? "Italic" : "Regular"
|
||||||
}.otf`,
|
}.otf`
|
||||||
)
|
)
|
||||||
.then((font) => {
|
.then((font) => {
|
||||||
// // console.log(font)
|
// // console.log(font)
|
||||||
@ -54,7 +54,7 @@ async function updateCodeFont() {
|
|||||||
})
|
})
|
||||||
.catch((err) => console.log(err))
|
.catch((err) => console.log(err))
|
||||||
// opentype
|
// opentype
|
||||||
// .load("src/fonts/fontlab/CommitMonoV141-500Regular.otf")
|
// .load("src/fonts/fontlab/CommitMonoV142-500Regular.otf")
|
||||||
// .then((font) => {
|
// .then((font) => {
|
||||||
// console.log(font)
|
// console.log(font)
|
||||||
// console.log(font.toTables())
|
// console.log(font.toTables())
|
||||||
@ -81,7 +81,7 @@ function updateCode(event, form) {
|
|||||||
displayName = character.name
|
displayName = character.name
|
||||||
const ps = document.querySelectorAll(".code_char")
|
const ps = document.querySelectorAll(".code_char")
|
||||||
ps.forEach((p) =>
|
ps.forEach((p) =>
|
||||||
p.dataset.char == character.name ? (p.style.display = "block") : (p.style.display = "none"),
|
p.dataset.char == character.name ? (p.style.display = "block") : (p.style.display = "none")
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
@ -100,8 +100,7 @@ function initializeDownload(button, blob) {
|
|||||||
downloadStarted = false
|
downloadStarted = false
|
||||||
button.classList.remove("loading")
|
button.classList.remove("loading")
|
||||||
button.classList.add("loaded")
|
button.classList.add("loaded")
|
||||||
// downloadFile(blob)
|
saveFile(blob, `${websiteData.fontName}${versionOfCommitMono}.zip`)
|
||||||
saveFile(blob, `${websiteData.fontName}.zip`)
|
|
||||||
}
|
}
|
||||||
function catchError(button, error) {
|
function catchError(button, error) {
|
||||||
downloadStarted = false
|
downloadStarted = false
|
||||||
@ -110,7 +109,7 @@ function catchError(button, error) {
|
|||||||
console.log(error)
|
console.log(error)
|
||||||
}
|
}
|
||||||
|
|
||||||
function makeCustomFont(settings) {
|
async function makeCustomFont(settings) {
|
||||||
const fontBaseURL = "/src/fonts/fontlab/"
|
const fontBaseURL = "/src/fonts/fontlab/"
|
||||||
const fontName = "CommitMono" + versionOfCommitMono
|
const fontName = "CommitMono" + versionOfCommitMono
|
||||||
const fontWeight = settings.weight
|
const fontWeight = settings.weight
|
||||||
@ -302,7 +301,6 @@ function makeCustomFont(settings) {
|
|||||||
font.names.windows.uniqueID.en = `${font.names.windows.version.en};;${websiteData.fontName}-${settings.style
|
font.names.windows.uniqueID.en = `${font.names.windows.version.en};;${websiteData.fontName}-${settings.style
|
||||||
.split(" ")
|
.split(" ")
|
||||||
.join("")};2023;FL820`
|
.join("")};2023;FL820`
|
||||||
delete font.names.windows.preferredFamily
|
|
||||||
|
|
||||||
font.tables.cff.topDict.familyName = fontFamily
|
font.tables.cff.topDict.familyName = fontFamily
|
||||||
font.tables.cff.topDict.fullName = fullName
|
font.tables.cff.topDict.fullName = fullName
|
||||||
@ -360,12 +358,6 @@ async function getZipFileBlob(kindOfDownload, fonts) {
|
|||||||
return zipFileBlob
|
return zipFileBlob
|
||||||
}
|
}
|
||||||
|
|
||||||
function downloadFile(blob) {
|
|
||||||
const a = document.createElement("a")
|
|
||||||
a.download = `${websiteData.fontName}.zip`
|
|
||||||
a.href = URL.createObjectURL(blob)
|
|
||||||
a.click()
|
|
||||||
}
|
|
||||||
function saveFile(blob, filename) {
|
function saveFile(blob, filename) {
|
||||||
if (window.navigator.msSaveOrOpenBlob) {
|
if (window.navigator.msSaveOrOpenBlob) {
|
||||||
window.navigator.msSaveOrOpenBlob(blob, filename)
|
window.navigator.msSaveOrOpenBlob(blob, filename)
|
||||||
|
@ -235,7 +235,7 @@ function simulateTab(e) {
|
|||||||
.forEach((el) => el.classList.remove("shake", "shake_left", "shake_right", "shake_up", "shake_down"))
|
.forEach((el) => el.classList.remove("shake", "shake_left", "shake_right", "shake_up", "shake_down"))
|
||||||
|
|
||||||
const allTabbable = document.querySelectorAll(
|
const allTabbable = document.querySelectorAll(
|
||||||
"#nav_form input:checked, section.visible input:checked, section.visible [tabindex='0']",
|
"#nav_form input:checked, section.visible input:checked, section.visible [tabindex='0']"
|
||||||
)
|
)
|
||||||
let addShake = false
|
let addShake = false
|
||||||
let indexOfActive = 0
|
let indexOfActive = 0
|
||||||
@ -402,7 +402,7 @@ function onFocusIn(e) {
|
|||||||
const paddingOffsetBottom = 200
|
const paddingOffsetBottom = 200
|
||||||
if (bounds.top > window.innerHeight - paddingOffsetBottom) {
|
if (bounds.top > window.innerHeight - paddingOffsetBottom) {
|
||||||
const numberOfMoves = Math.floor(
|
const numberOfMoves = Math.floor(
|
||||||
(bounds.top - (window.innerHeight - paddingOffsetBottom)) / websiteData.pushPage.distance,
|
(bounds.top - (window.innerHeight - paddingOffsetBottom)) / websiteData.pushPage.distance
|
||||||
)
|
)
|
||||||
for (let i = 0; i < numberOfMoves; i++) {
|
for (let i = 0; i < numberOfMoves; i++) {
|
||||||
pushPage("KeyS")
|
pushPage("KeyS")
|
||||||
@ -412,7 +412,7 @@ function onFocusIn(e) {
|
|||||||
if (!document.activeElement.className.includes("nav")) {
|
if (!document.activeElement.className.includes("nav")) {
|
||||||
if (bounds.top < paddingOffsetTop) {
|
if (bounds.top < paddingOffsetTop) {
|
||||||
const numberOfMoves = Math.ceil(
|
const numberOfMoves = Math.ceil(
|
||||||
Math.abs(bounds.top - paddingOffsetTop - 32) / websiteData.pushPage.distance,
|
Math.abs(bounds.top - paddingOffsetTop - 32) / websiteData.pushPage.distance
|
||||||
)
|
)
|
||||||
// console.log("num of moves:", numberOfMoves, "bounds.top:", bounds.top)
|
// console.log("num of moves:", numberOfMoves, "bounds.top:", bounds.top)
|
||||||
for (let i = 0; i < numberOfMoves; i++) {
|
for (let i = 0; i < numberOfMoves; i++) {
|
||||||
@ -476,8 +476,8 @@ function checkTutorialKeys(e) {
|
|||||||
tutorialFinished = true
|
tutorialFinished = true
|
||||||
const tutorialContainer = document.querySelector("#tutorial_complete")
|
const tutorialContainer = document.querySelector("#tutorial_complete")
|
||||||
tutorialContainer.innerHTML = `<p>Tutorial complete! Your present is the variable version of Commit Mono:</p>
|
tutorialContainer.innerHTML = `<p>Tutorial complete! Your present is the variable version of Commit Mono:</p>
|
||||||
<p><a href="/src/fonts/fontlab/CommitMonoV141-VF.ttf" tabindex="0">Download CommitMono-VF.ttf</a></p>
|
<p><a href="/src/fonts/fontlab/CommitMonoV142-VF.ttf" tabindex="0">Download CommitMono-VF.ttf</a></p>
|
||||||
<p><a href="/src/fonts/fontlab/CommitMonoV141-VF.woff2" tabindex="0">Download CommitMono-VF.woff2</a></p>
|
<p><a href="/src/fonts/fontlab/CommitMonoV142-VF.woff2" tabindex="0">Download CommitMono-VF.woff2</a></p>
|
||||||
<br />`
|
<br />`
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,9 +3,9 @@
|
|||||||
# step 3: run this from the root directory
|
# step 3: run this from the root directory
|
||||||
|
|
||||||
rm src/fonts/*.zip
|
rm src/fonts/*.zip
|
||||||
mkdir src/fonts/CommitMono-1.141
|
mkdir src/fonts/CommitMono-1.142
|
||||||
mv src/fonts/website-export/CommitMono.zip src/fonts/CommitMono-1.141/CommitMono.zip
|
mv src/fonts/website-export/CommitMono.zip src/fonts/CommitMono-1.142/CommitMono.zip
|
||||||
cd src/fonts/CommitMono-1.141
|
cd src/fonts/CommitMono-1.142
|
||||||
unzip CommitMono.zip
|
unzip CommitMono.zip
|
||||||
rm CommitMono.zip
|
rm CommitMono.zip
|
||||||
mkdir ttfautohint
|
mkdir ttfautohint
|
||||||
@ -22,8 +22,8 @@ rm CommitMono-400-Italic-unhinted.ttf
|
|||||||
rm CommitMono-700-Regular-unhinted.ttf
|
rm CommitMono-700-Regular-unhinted.ttf
|
||||||
rm CommitMono-700-Italic-unhinted.ttf
|
rm CommitMono-700-Italic-unhinted.ttf
|
||||||
cd ..
|
cd ..
|
||||||
zip -vr CommitMono-1.141.zip CommitMono-1.141/ -x "*.DS_Store"
|
zip -vr CommitMono-1.142.zip CommitMono-1.142/ -x "*.DS_Store"
|
||||||
rm -R CommitMono-1.141
|
rm -R CommitMono-1.142
|
||||||
cd ..
|
cd ..
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#1 Rename variable font to "CommitMonoV141-VF.ttf"
|
#1 Rename variable font to "CommitMonoV142-VF.ttf"
|
||||||
#2 Navigate to /Developer/woff2
|
#2 Navigate to /Developer/woff2
|
||||||
#3
|
#3
|
||||||
~/Developer/woff2/woff2_compress ~/Library/CloudStorage/Dropbox/Privat/Eigils\ ting/projects/typography/Font\ Projects/code-mono-font/commit-mono/export/CommitMonoV141/CommitMonoV141-VF.ttf
|
~/Developer/woff2/woff2_compress ~/Library/CloudStorage/Dropbox/Privat/Eigils\ ting/projects/typography/Font\ Projects/code-mono-font/commit-mono/export/CommitMonoV142/CommitMonoV142-VF.ttf
|
Loading…
Reference in New Issue
Block a user