Browse Source

prefer local fonts

- stop force-loading plex mono
- use forkawesome.min
- update font stack preference
master
Ben Harris 1 year ago
parent
commit
8cea7034a3
Signed by untrusted user: ben GPG Key ID: 4E0AF802FFF7960C
  1. 9
      css/Makefile
  2. 2
      css/dracula.css
  3. 12
      css/fork-awesome.min.css
  4. 2
      css/hacker.css
  5. 0
      css/less/_theme.less
  6. 6
      css/less/dracula.less
  7. 6
      css/less/dracula_variables.less
  8. 6
      css/less/hacker.less
  9. 6
      css/less/hacker_variables.less
  10. 156
      css/package-lock.json
  11. 2
      css/package.json
  12. 2
      header.php

9
css/Makefile

@ -3,15 +3,14 @@ lightserver := node_modules/.bin/light-server
NPM != command -v npm 2> /dev/null
.PHONY: build dev clean
.PHONY: dev clean
# First target is default
build: hacker.css dracula.css
dev: build
$(lightserver) -s . -p 9000 -w "index.html, **/*.less \# make" -o
%.css: node_modules less/%/*.less less/plex.css
%.css: node_modules less/*.less
$(info building $@)
$(lessc) less/$*.less $*.css --clean-css="--s1 --advanced --compatibility=ie8"
@ -19,10 +18,10 @@ node_modules: package.json package-lock.json Makefile
ifndef NPM
$(error Missing dependency 'npm'. Please install and try again.)
endif
npm install
$(NPM) install
touch node_modules # fixes watch bug if you manually ran npm install
clean:
rm -rf node_modules
rm dracula.css
rm dracula.css
rm hacker.css

2
css/dracula.css

File diff suppressed because one or more lines are too long

12
css/fork-awesome.min.css

File diff suppressed because one or more lines are too long

2
css/hacker.css

File diff suppressed because one or more lines are too long

0
css/less/hacker/_theme.less → css/less/_theme.less

6
css/less/dracula.less

@ -1,9 +1,9 @@
// import bootstrap base
@import "../node_modules/bootstrap/less/bootstrap.less";
@import (inline) "plex.css";
// @import (inline) "plex.css";
// import custom variables
@import "dracula/_variables.less";
@import "dracula_variables.less";
// import custom theme changes
@import "hacker/_theme.less";
@import "_theme.less";

6
css/less/dracula/_variables.less → css/less/dracula_variables.less

@ -56,9 +56,9 @@ Palette URL: http://paletton.com/#uid=12U0u0knnfti5bkladVnSlVo6tw
// Typography
@font-family-sans-serif: "IBM Plex Mono", monospace;
@font-family-serif: "IBM Plex Mono", monospace;
@font-family-monospace: "IBM Plex Mono", monospace;
@font-family-monospace: "IBM Plex Mono", "JetBrains Mono", "Fira Mono", Consolas, Inconsolata, monospace;
@font-family-sans-serif: @font-family-monospace;
@font-family-serif: @font-family-monospace;
@font-family-base: @font-family-monospace;
@font-size-base: 16px;
@font-size-large: ceil(@font-size-base * 1.25);

6
css/less/hacker.less

@ -1,9 +1,9 @@
// import bootstrap base
@import "../node_modules/bootstrap/less/bootstrap.less";
@import (inline) "plex.css";
// @import (inline) "plex.css";
// import custom variables
@import "hacker/_variables.less";
@import "hacker_variables.less";
// import custom theme changes
@import "hacker/_theme.less";
@import "_theme.less";

6
css/less/hacker/_variables.less → css/less/hacker_variables.less

@ -54,9 +54,9 @@ Palette URL: http://paletton.com/#uid=12U0u0knnfti5bkladVnSlVo6tw
// Typography
@font-family-sans-serif: "IBM Plex Mono", monospace;
@font-family-serif: "IBM Plex Mono", monospace;
@font-family-monospace: "IBM Plex Mono", monospace;
@font-family-monospace: "IBM Plex Mono", "JetBrains Mono", "Fira Mono", Consolas, Inconsolata, monospace;
@font-family-sans-serif: @font-family-monospace;
@font-family-serif: @font-family-monospace;
@font-family-base: @font-family-monospace;
@font-size-base: 16px;
@font-size-large: ceil(@font-size-base * 1.25);

156
css/package-lock.json

@ -14,16 +14,16 @@
},
"dependencies": {
"mime-db": {
"version": "1.43.0",
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.43.0.tgz",
"integrity": "sha512-+5dsGEEovYbT8UY9yD7eE4XTc4UwJ1jBYlgaQQF38ENsKR3wj/8q8RFZrF9WIZpB2V1ArTVFUva8sAul1NzRzQ=="
"version": "1.45.0",
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.45.0.tgz",
"integrity": "sha512-CkqLUxUk15hofLoLyljJSrukZi8mAtgd+yE5uO4tqRZsdsAJKv0O+rFMhVDRJgozy+yG6md5KwuXhD4ocIoP+w=="
},
"mime-types": {
"version": "2.1.26",
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.26.tgz",
"integrity": "sha512-01paPWYgLrkqAyrlDorC1uDwl2p3qZT7yl806vW7DvDoxwXi46jsjFbg+WdwotBIk6/MbEhO/dh5aZ5sNj/dWQ==",
"version": "2.1.28",
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.28.tgz",
"integrity": "sha512-0TO2yJ5YHYr7M2zzT7gDU1tbwHxEUWBCLt0lscSNpcdAfFyJOVEpRYNS7EXVcTLNj/25QO8gulHC5JtTzSE2UQ==",
"requires": {
"mime-db": "1.43.0"
"mime-db": "1.45.0"
}
}
}
@ -233,9 +233,9 @@
"optional": true
},
"depd": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz",
"integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz",
"integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw=="
},
"destroy": {
"version": "1.0.4",
@ -287,9 +287,9 @@
"integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc="
},
"eventemitter3": {
"version": "4.0.4",
"resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.4.tgz",
"integrity": "sha512-rlaVLnVxtxvoyLsQQFBx53YmXHDxRIzzTLbdfxqi4yocpSjAxXwkU0cScM5JgSKMqEhrZpnvQ2D9gjylR0AimQ=="
"version": "4.0.7",
"resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.7.tgz",
"integrity": "sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw=="
},
"extend": {
"version": "3.0.2",
@ -330,27 +330,9 @@
}
},
"follow-redirects": {
"version": "1.11.0",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.11.0.tgz",
"integrity": "sha512-KZm0V+ll8PfBrKwMzdo5D13b1bur9Iq9Zd/RMmAoQQcl2PxxFml8cxXPaaPYVbV0RjNjq1CU7zIzAOqtUPudmA==",
"requires": {
"debug": "^3.0.0"
},
"dependencies": {
"debug": {
"version": "3.2.6",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz",
"integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==",
"requires": {
"ms": "^2.1.1"
}
},
"ms": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
}
}
"version": "1.13.1",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.13.1.tgz",
"integrity": "sha512-SSG5xmZh1mkPGyKzjZP8zLjltIfpW32Y5QpdNJyjcfGxK3qo3NDDkZOZSFiGn1A6SclQxY9GzEwAHQ3dmYRWpg=="
},
"forever-agent": {
"version": "0.6.1",
@ -410,12 +392,12 @@
}
},
"globule": {
"version": "1.3.1",
"resolved": "https://registry.npmjs.org/globule/-/globule-1.3.1.tgz",
"integrity": "sha512-OVyWOHgw29yosRHCHo7NncwR1hW5ew0W/UrvtwvjefVJeQ26q4/8r8FmPsSF1hJ93IgWkyv16pCTz6WblMzm/g==",
"version": "1.3.2",
"resolved": "https://registry.npmjs.org/globule/-/globule-1.3.2.tgz",
"integrity": "sha512-7IDTQTIu2xzXkT+6mlluidnWo+BypnbSoEVVQCGfzqnl5Ik8d3e1d4wycb8Rj9tWW+Z39uPWsdlquqiqPCd/pA==",
"requires": {
"glob": "~7.1.1",
"lodash": "~4.17.12",
"lodash": "~4.17.10",
"minimatch": "~3.0.2"
}
},
@ -431,9 +413,9 @@
"integrity": "sha1-TK+tdrxi8C+gObL5Tpo906ORpyU="
},
"handle-thing": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/handle-thing/-/handle-thing-2.0.0.tgz",
"integrity": "sha512-d4sze1JNC454Wdo2fkuyzCr6aHcbL6PGGuFAz0Li/NcOm1tCHGnWDRmJP85dh9IhQErTc2svWFEX5xHIOo//kQ=="
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/handle-thing/-/handle-thing-2.0.1.tgz",
"integrity": "sha512-9Qn4yBxelxoh2Ow62nP+Ka/kMnOXRi8BXnRaUwezLNhqelnN49xKz4F/dPP8OYLxLxq6JDtZb2i9XznUQbNPTg=="
},
"har-schema": {
"version": "2.0.0",
@ -494,6 +476,11 @@
"statuses": ">= 1.4.0 < 2"
},
"dependencies": {
"depd": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz",
"integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
},
"inherits": {
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz",
@ -621,37 +608,37 @@
}
},
"light-server": {
"version": "2.6.4",
"resolved": "https://registry.npmjs.org/light-server/-/light-server-2.6.4.tgz",
"integrity": "sha512-rrJn+RrM98chJM1+Ebwk0wqc+ygtUhU5DYQvWlxkAEnnvYh8a//k9YGwVUnHDHI23QQnEMCodava99GzmX5wjw==",
"version": "2.9.1",
"resolved": "https://registry.npmjs.org/light-server/-/light-server-2.9.1.tgz",
"integrity": "sha512-8uerqP4ffFbTJZ2QGR1225TqZUWEFkl/kGnJ+vRGiaqnLr6pFj8XLFGyO1XgO8ib9NQKxd7gsq3pEYN3AB+Q2g==",
"requires": {
"commander": "^2.20.0",
"commander": "^6.0.0",
"connect": "^3.7.0",
"connect-history-api-fallback": "^1.6.0",
"connect-injector": "^0.4.4",
"gaze": "^1.1.3",
"http-proxy": "^1.17.0",
"morgan": "~1.9.1",
"http-proxy": "^1.18.1",
"morgan": "~1.10.0",
"opener": "^1.5.1",
"parseurl": "^1.3.3",
"serve-index": "^1.9.1",
"serve-static": "~1.14.1",
"spdy": "^4.0.0",
"strip-json-comments": "^3.0.1",
"ws": "^7.1.0"
"spdy": "^4.0.2",
"strip-json-comments": "^3.1.1",
"ws": "^7.3.1"
},
"dependencies": {
"commander": {
"version": "2.20.3",
"resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz",
"integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ=="
"version": "6.2.1",
"resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz",
"integrity": "sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA=="
}
}
},
"lodash": {
"version": "4.17.19",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz",
"integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ=="
"version": "4.17.20",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz",
"integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA=="
},
"mime": {
"version": "1.6.0",
@ -700,15 +687,15 @@
}
},
"morgan": {
"version": "1.9.1",
"resolved": "https://registry.npmjs.org/morgan/-/morgan-1.9.1.tgz",
"integrity": "sha512-HQStPIV4y3afTiCYVxirakhlCfGkI161c76kKFca7Fk1JusM//Qeo1ej2XaMniiNeaZklMVrh3vTtIzpzwbpmA==",
"version": "1.10.0",
"resolved": "https://registry.npmjs.org/morgan/-/morgan-1.10.0.tgz",
"integrity": "sha512-AbegBVI4sh6El+1gNwvD5YIck7nSA36weD7xvIxG4in80j/UoK8AEGaWnnz8v1GxonMCltmlNs5ZKbGvl9b1XQ==",
"requires": {
"basic-auth": "~2.0.0",
"basic-auth": "~2.0.1",
"debug": "2.6.9",
"depd": "~1.1.2",
"depd": "~2.0.0",
"on-finished": "~2.3.0",
"on-headers": "~1.0.1"
"on-headers": "~1.0.2"
}
},
"ms": {
@ -754,9 +741,9 @@
}
},
"opener": {
"version": "1.5.1",
"resolved": "https://registry.npmjs.org/opener/-/opener-1.5.1.tgz",
"integrity": "sha512-goYSy5c2UXE4Ra1xixabeVh1guIX/ZV/YokJksb6q2lubWu6UbvPQ20p542/sFIll1nl8JnCyK9oBaOcCWXwvA=="
"version": "1.5.2",
"resolved": "https://registry.npmjs.org/opener/-/opener-1.5.2.tgz",
"integrity": "sha512-ur5UIdyw5Y7yEj9wLzhqXiy6GZ3Mwx0yGI+5sMn2r0N0v3cKJvUmFH5yPP+WXh9e0xfyzyJX95D8l088DNFj7A=="
},
"parseurl": {
"version": "1.3.3",
@ -918,6 +905,11 @@
"statuses": "~1.5.0"
},
"dependencies": {
"depd": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz",
"integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak="
},
"http-errors": {
"version": "1.7.3",
"resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.3.tgz",
@ -979,9 +971,9 @@
"optional": true
},
"spdy": {
"version": "4.0.1",
"resolved": "https://registry.npmjs.org/spdy/-/spdy-4.0.1.tgz",
"integrity": "sha512-HeZS3PBdMA+sZSu0qwpCxl3DeALD5ASx8pAX0jZdKXSpPWbQ6SYGnlg3BBmYLx5LtiZrmkAZfErCm2oECBcioA==",
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/spdy/-/spdy-4.0.2.tgz",
"integrity": "sha512-r46gZQZQV+Kl9oItvl1JZZqJKGr+oEkB08A6BzkiR7593/7IbtuncXHd2YoYeTsG4157ZssMu9KYvUHLcjcDoA==",
"requires": {
"debug": "^4.1.0",
"handle-thing": "^2.0.0",
@ -991,11 +983,11 @@
},
"dependencies": {
"debug": {
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz",
"integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==",
"version": "4.3.1",
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.1.tgz",
"integrity": "sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ==",
"requires": {
"ms": "^2.1.1"
"ms": "2.1.2"
}
},
"ms": {
@ -1019,11 +1011,11 @@
},
"dependencies": {
"debug": {
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz",
"integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==",
"version": "4.3.1",
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.1.tgz",
"integrity": "sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ==",
"requires": {
"ms": "^2.1.1"
"ms": "2.1.2"
}
},
"ms": {
@ -1069,9 +1061,9 @@
}
},
"strip-json-comments": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.0.1.tgz",
"integrity": "sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw=="
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz",
"integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig=="
},
"toidentifier": {
"version": "1.0.0",
@ -1168,9 +1160,9 @@
"integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8="
},
"ws": {
"version": "7.2.1",
"resolved": "https://registry.npmjs.org/ws/-/ws-7.2.1.tgz",
"integrity": "sha512-sucePNSafamSKoOqoNfBd8V0StlkzJKL2ZAhGQinCfNQ+oacw+Pk7lcdAElecBF2VkLNZRiIb5Oi1Q5lVUVt2A=="
"version": "7.4.2",
"resolved": "https://registry.npmjs.org/ws/-/ws-7.4.2.tgz",
"integrity": "sha512-T4tewALS3+qsrpGI/8dqNMLIVdq/g/85U98HPMa6F0m6xTbvhXU6RCQLqPH3+SlomNV/LdY6RXEbBpMH6EOJnA=="
}
}
}

2
css/package.json

@ -14,7 +14,7 @@
"bootstrap": "3.4.1",
"less": "3.11.1",
"less-plugin-clean-css": "1.5.1",
"light-server": "^2.6.4"
"light-server": "^2.9.1"
},
"preferGlobal": true,
"license": "MIT"

2
header.php

@ -16,7 +16,7 @@
<link rel="icon" type="image/png" sizes="96x96" href="/favicon-96x96.png">
<link rel="stylesheet" href="/css/hacker.css">
<link rel="stylesheet" href="/css/fork-awesome.css">
<link rel="stylesheet" href="/css/fork-awesome.min.css">
<?=$additional_head ?? ""?>
<?php unset($title); unset($additional_head); ?>

Loading…
Cancel
Save