@lexho111/plainblog 0.5.22 → 0.5.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/Blog.js CHANGED
@@ -456,7 +456,7 @@ export default class Blog {
456
456
  return new Promise((resolve, reject) => {
457
457
  const errorHandler = (err) => reject(err);
458
458
  this.#server.once("error", errorHandler);
459
- this.#server.listen(port, "127.0.0.1", () => {
459
+ this.#server.listen(port, "0.0.0.0", () => { // <-- for docker 0.0.0.0, localhost 127.0.0.1
460
460
  this.#server.removeListener("error", errorHandler);
461
461
  console.log(`server running at http://localhost:${port}/`);
462
462
  resolve(); // Resolve the promise when the server is listening
package/model/APIModel.js CHANGED
@@ -1,5 +1,3 @@
1
- import fetch from "node-fetch";
2
-
3
1
  // EXTERNAL DATA API
4
2
 
5
3
  /** fetch data from an URL */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lexho111/plainblog",
3
- "version": "0.5.22",
3
+ "version": "0.5.24",
4
4
  "description": "A tool for creating and serving a minimalist, single-page blog.",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -16,9 +16,7 @@
16
16
  ],
17
17
  "author": "lexho111",
18
18
  "license": "ISC",
19
- "dependencies": {
20
- "node-fetch": "^3.3.2"
21
- },
19
+ "dependencies": {},
22
20
  "devDependencies": {
23
21
  "@eslint/js": "^9.39.2",
24
22
  "@types/node": "^25.0.3",
@@ -1,2 +1 @@
1
- *{font-size:.9rem}body{background-color:#fff;color:#000}h1{font:italic small-caps 700 2.5em/2.3em Verdana,sans-serif;letter-spacing:.1em;margin:0;padding:0}#wrapper{max-width:600px;width:100%}.grid{border:2px solid #d3d3d3;display:grid;gap:.25rem;grid-template-columns:1fr}.grid article h2{color:primary;margin-bottom:2px}.grid article{border:0 solid #ccc;border-radius:4px;min-width:0;overflow-wrap:break-word;padding:.25rem}.grid article .datetime{font-style:italic;margin:0}.grid article p{margin-bottom:0;margin-top:10px}.grid article a,.grid article a:link a:visited{color:#000}h1{color:primary}nav a{color:#3c3c3c;font-size:20px;text-decoration:underline}nav a[href*=login]{display:none}nav a:visited{color:#3c3c3c;text-decoration-color:#3c3c3c}
2
- /*# sourceMappingURL=print-compiled.css.map */
1
+ *{font-size:.5rem}body{background-color:#fff;color:#000}h1{font:italic small-caps 700 2.5em/2.3em Verdana,sans-serif;letter-spacing:.1em;margin:0;padding:0}#wrapper{max-width:600px;width:100%}.grid{display:grid;grid-template-columns:1fr;grid-gap:.25rem;border:2px solid #d3d3d3;gap:.25rem}.grid article{border:0 solid #ccc;border-radius:4px;min-width:0;padding:.25rem;word-wrap:break-word}.grid article h2{color:#000;margin-bottom:2px}.grid article .datetime{font-style:italic;margin:0}.grid article p{margin-bottom:0;margin-top:10px}.grid article a,.grid article a:link a:visited,h1{color:#000}nav a{color:#3c3c3c;font-size:20px;-webkit-text-decoration:underline;text-decoration:underline}nav a[href*=login]{display:none}nav a:visited{color:#3c3c3c;text-decoration-color:#3c3c3c}
package/src/print.css ADDED
@@ -0,0 +1,71 @@
1
+ * {
2
+ font-size: 0.5rem; /* Forces every single element to this size */
3
+ }
4
+
5
+ body {
6
+ color: black;
7
+ background-color: white;
8
+ }
9
+
10
+ h1 {
11
+ font: italic small-caps bold 2.5em/2.3em Verdana, sans-serif;
12
+ margin: 0;
13
+ padding: 0;
14
+ letter-spacing: 0.1em;
15
+ }
16
+
17
+ #wrapper {
18
+ max-width: 600px;
19
+ width: 100%;
20
+ }
21
+
22
+ .grid {
23
+ display: grid;
24
+ grid-template-columns: 1fr;
25
+ gap: 0.25rem;
26
+ border: 2px solid lightgray;
27
+ }
28
+ .grid article {
29
+ padding: 0.25rem;
30
+ border: 0px solid #ccc;
31
+ border-radius: 4px;
32
+ min-width: 0; /* Allow grid items to shrink */
33
+ overflow-wrap: break-word; /* Break long words */
34
+ }
35
+ .grid article h2 {
36
+ color: black;
37
+ margin-bottom: 2px;
38
+ }
39
+ .grid article .datetime {
40
+ margin: 0;
41
+ font-style: italic;
42
+ }
43
+ .grid article p {
44
+ margin-top: 10px;
45
+ margin-bottom: 0;
46
+ }
47
+ .grid article a {
48
+ color: black;
49
+ }
50
+ .grid article a:link a:visited {
51
+ color: black;
52
+ }
53
+
54
+ h1 {
55
+ color: black;
56
+ }
57
+
58
+ nav a {
59
+ text-decoration: underline;
60
+ color: rgb(60, 60, 60);
61
+ font-size: 20px;
62
+ }
63
+ nav a[href*=login] {
64
+ display: none;
65
+ }
66
+ nav a:visited {
67
+ color: rgb(60, 60, 60);
68
+ text-decoration-color: rgb(60, 60, 60);
69
+ }
70
+
71
+ /*# sourceMappingURL=print.css.map */
@@ -0,0 +1 @@
1
+ {"version":3,"sourceRoot":"","sources":["print.scss"],"names":[],"mappings":"AAKA;EACE;;;AAIF;EACE,OAXQ;EAYR,kBATW;;;AAYb;EAAK;EACL;EAAW;EACX;;;AAGA;EACE;EAAkB;;;AAGpB;EACE;EACA;EACA;EACA;;AAEA;EAIE;EACA;EACA;EACA;EACA;;AAPA;EAAK,OA/BC;EAgCN;;AAOA;EACI;EACA;;AAEJ;EACI;EACF;;AAEF;EACI;;AAEJ;EACI;;;AAKR;EACE,OAzDQ;;;AA6DR;EACE;EACA,OA7DE;EA8DF;;AAGF;EACE;;AAGF;EACE,OAtEE;EAuEF,uBAvEE","file":"print.css"}
package/src/print.scss CHANGED
@@ -29,7 +29,7 @@ letter-spacing: 0.1em;
29
29
  border: 2px solid lightgray;
30
30
 
31
31
  article {
32
- h2 { color: primary;
32
+ h2 { color: $primary;
33
33
  margin-bottom: 2px;
34
34
  }
35
35
  padding: 0.25rem;
@@ -55,7 +55,7 @@ letter-spacing: 0.1em;
55
55
  }
56
56
 
57
57
  h1 {
58
- color: primary;
58
+ color: $primary;
59
59
  }
60
60
 
61
61
  nav {