@jsonresume/jsonresume-theme-professional 1.0.28 → 1.0.30

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/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # @jsonresume/jsonresume-theme-professional
2
2
 
3
+ ## 1.0.30
4
+
5
+ ### Patch Changes
6
+
7
+ - e327eb3: Load Latin Modern from https://jsonresume.org/fonts/ (served with CORS), so the theme shows in its own typeface wherever it renders, a PDF or a resume built with resume-cli, and fall back to a serif rather than Courier. Drop the Latin Modern Sans faces it declared but never used.
8
+ - Updated dependencies [a6ba9ed]
9
+ - @jsonresume/core@0.4.0
10
+
11
+ ## 1.0.29
12
+
13
+ ### Patch Changes
14
+
15
+ - 04aae6e: Improve PDF printing with repeating page margins, wrapping for long content, section pagination, and A4/Letter paper selection. Rebuild themes with the shared print fixes.
16
+ - Updated dependencies [04aae6e]
17
+ - @jsonresume/core@0.3.8
18
+
3
19
  ## 1.0.28
4
20
 
5
21
  ### Patch Changes
package/dist/index.js CHANGED
@@ -1281,6 +1281,15 @@ var vt = /^\s*<\/[a-z]/i, gt = (function() {
1281
1281
  var wt = "__sc-".concat(f, "__");
1282
1282
  "production" !== process.env.NODE_ENV && "test" !== process.env.NODE_ENV && "undefined" != typeof window && (window[wt] || (window[wt] = 0), 1 === window[wt] && console.warn("It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.\n\nSee https://s-c.sh/2BAXzed for more info."), window[wt] += 1);
1283
1283
  const CSS_RESET = "<style>*,*::before,*::after{box-sizing:border-box}html,body{margin:0;padding:0}body{-webkit-font-smoothing:antialiased}</style>";
1284
+ const PRINT_DEFAULTS = `<style data-jsonresume-core-print>
1285
+ @page{size:auto;margin:12mm}
1286
+ @media print{
1287
+ body,h1,h2,h3,h4,p,li,a{overflow-wrap:anywhere}
1288
+ :where(main,aside,section,article,header,div){min-width:0}
1289
+ h1,h2,h3,h4,h5,h6{break-inside:avoid;break-after:avoid}
1290
+ p,li{orphans:2;widows:2}
1291
+ }
1292
+ </style>`;
1284
1293
  const TOKENS_CSS_HREF = "https://unpkg.com/@jsonresume/core/dist/tokens.css";
1285
1294
  const FONTS_PRECONNECT = '<link rel="preconnect" href="https://fonts.googleapis.com"><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>';
1286
1295
  function isHref(value) {
@@ -1338,7 +1347,7 @@ function renderResumeDocument(element, options = {}) {
1338
1347
  const resetTag = reset ? CSS_RESET : "";
1339
1348
  const titleTag = title ? `<title>${title}</title>` : "";
1340
1349
  const bodyAttr = bodyClass ? ` class="${bodyClass}"` : "";
1341
- return `<!DOCTYPE html><html lang="${lang}" dir="${dir}"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">` + fontLinks + tokensLink + resetTag + head + styleTags + headAfterStyles + titleTag + `</head><body${bodyAttr}>${html}</body></html>`;
1350
+ return `<!DOCTYPE html><html lang="${lang}" dir="${dir}"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">` + fontLinks + tokensLink + resetTag + PRINT_DEFAULTS + head + styleTags + headAfterStyles + titleTag + `</head><body${bodyAttr}>${html}</body></html>`;
1342
1351
  }
1343
1352
  const Section = dt.div`
1344
1353
  max-width: 700px;
@@ -2852,47 +2861,25 @@ const render = (resume) => {
2852
2861
  font-style: normal;
2853
2862
  font-weight: normal;
2854
2863
  font-display: swap;
2855
- src: url("/fonts/lmroman10-regular.otf") format("opentype");
2864
+ src: url("https://jsonresume.org/fonts/lmroman10-regular.otf") format("opentype");
2856
2865
  }
2857
2866
 
2858
2867
  @font-face {
2859
2868
  font-family: LatinModern;
2860
2869
  font-weight: bold;
2861
2870
  font-display: swap;
2862
- src: url("/fonts/lmroman10-bold.otf") format("opentype");
2871
+ src: url("https://jsonresume.org/fonts/lmroman10-bold.otf") format("opentype");
2863
2872
  }
2864
2873
 
2865
2874
  @font-face {
2866
2875
  font-family: LatinModern;
2867
2876
  font-style: italic;
2868
2877
  font-display: swap;
2869
- src: url("/fonts/lmroman10-italic.otf") format("opentype");
2870
- }
2871
-
2872
- @font-face {
2873
- font-family: LatinModernSans;
2874
- font-style: normal;
2875
- font-weight: normal;
2876
- font-display: swap;
2877
- src: url("/fonts/lmsans10-regular.otf") format("opentype");
2878
- }
2879
-
2880
- @font-face {
2881
- font-family: LatinModernSans;
2882
- font-weight: bold;
2883
- font-display: swap;
2884
- src: url("/fonts/lmsans10-bold.otf") format("opentype");
2885
- }
2886
-
2887
- @font-face {
2888
- font-family: LatinModernSans;
2889
- font-style: italic;
2890
- font-display: swap;
2891
- src: url("/fonts/lmsans10-italic.otf") format("opentype");
2878
+ src: url("https://jsonresume.org/fonts/lmroman10-italic.otf") format("opentype");
2892
2879
  }
2893
2880
 
2894
2881
  html {
2895
- font-family:LatinModern, "Courier New", monospace;
2882
+ font-family: LatinModern, "Latin Modern Roman", Georgia, serif;
2896
2883
  background: #fff;
2897
2884
  font-size: 11px;
2898
2885
  }
package/dist/index.mjs CHANGED
@@ -1279,6 +1279,15 @@ var vt = /^\s*<\/[a-z]/i, gt = (function() {
1279
1279
  var wt = "__sc-".concat(f, "__");
1280
1280
  "production" !== process.env.NODE_ENV && "test" !== process.env.NODE_ENV && "undefined" != typeof window && (window[wt] || (window[wt] = 0), 1 === window[wt] && console.warn("It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.\n\nSee https://s-c.sh/2BAXzed for more info."), window[wt] += 1);
1281
1281
  const CSS_RESET = "<style>*,*::before,*::after{box-sizing:border-box}html,body{margin:0;padding:0}body{-webkit-font-smoothing:antialiased}</style>";
1282
+ const PRINT_DEFAULTS = `<style data-jsonresume-core-print>
1283
+ @page{size:auto;margin:12mm}
1284
+ @media print{
1285
+ body,h1,h2,h3,h4,p,li,a{overflow-wrap:anywhere}
1286
+ :where(main,aside,section,article,header,div){min-width:0}
1287
+ h1,h2,h3,h4,h5,h6{break-inside:avoid;break-after:avoid}
1288
+ p,li{orphans:2;widows:2}
1289
+ }
1290
+ </style>`;
1282
1291
  const TOKENS_CSS_HREF = "https://unpkg.com/@jsonresume/core/dist/tokens.css";
1283
1292
  const FONTS_PRECONNECT = '<link rel="preconnect" href="https://fonts.googleapis.com"><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>';
1284
1293
  function isHref(value) {
@@ -1336,7 +1345,7 @@ function renderResumeDocument(element, options = {}) {
1336
1345
  const resetTag = reset ? CSS_RESET : "";
1337
1346
  const titleTag = title ? `<title>${title}</title>` : "";
1338
1347
  const bodyAttr = bodyClass ? ` class="${bodyClass}"` : "";
1339
- return `<!DOCTYPE html><html lang="${lang}" dir="${dir}"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">` + fontLinks + tokensLink + resetTag + head + styleTags + headAfterStyles + titleTag + `</head><body${bodyAttr}>${html}</body></html>`;
1348
+ return `<!DOCTYPE html><html lang="${lang}" dir="${dir}"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">` + fontLinks + tokensLink + resetTag + PRINT_DEFAULTS + head + styleTags + headAfterStyles + titleTag + `</head><body${bodyAttr}>${html}</body></html>`;
1340
1349
  }
1341
1350
  const Section = dt.div`
1342
1351
  max-width: 700px;
@@ -2850,47 +2859,25 @@ const render = (resume) => {
2850
2859
  font-style: normal;
2851
2860
  font-weight: normal;
2852
2861
  font-display: swap;
2853
- src: url("/fonts/lmroman10-regular.otf") format("opentype");
2862
+ src: url("https://jsonresume.org/fonts/lmroman10-regular.otf") format("opentype");
2854
2863
  }
2855
2864
 
2856
2865
  @font-face {
2857
2866
  font-family: LatinModern;
2858
2867
  font-weight: bold;
2859
2868
  font-display: swap;
2860
- src: url("/fonts/lmroman10-bold.otf") format("opentype");
2869
+ src: url("https://jsonresume.org/fonts/lmroman10-bold.otf") format("opentype");
2861
2870
  }
2862
2871
 
2863
2872
  @font-face {
2864
2873
  font-family: LatinModern;
2865
2874
  font-style: italic;
2866
2875
  font-display: swap;
2867
- src: url("/fonts/lmroman10-italic.otf") format("opentype");
2868
- }
2869
-
2870
- @font-face {
2871
- font-family: LatinModernSans;
2872
- font-style: normal;
2873
- font-weight: normal;
2874
- font-display: swap;
2875
- src: url("/fonts/lmsans10-regular.otf") format("opentype");
2876
- }
2877
-
2878
- @font-face {
2879
- font-family: LatinModernSans;
2880
- font-weight: bold;
2881
- font-display: swap;
2882
- src: url("/fonts/lmsans10-bold.otf") format("opentype");
2883
- }
2884
-
2885
- @font-face {
2886
- font-family: LatinModernSans;
2887
- font-style: italic;
2888
- font-display: swap;
2889
- src: url("/fonts/lmsans10-italic.otf") format("opentype");
2876
+ src: url("https://jsonresume.org/fonts/lmroman10-italic.otf") format("opentype");
2890
2877
  }
2891
2878
 
2892
2879
  html {
2893
- font-family:LatinModern, "Courier New", monospace;
2880
+ font-family: LatinModern, "Latin Modern Roman", Georgia, serif;
2894
2881
  background: #fff;
2895
2882
  font-size: 11px;
2896
2883
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "private": false,
3
3
  "name": "@jsonresume/jsonresume-theme-professional",
4
- "version": "1.0.28",
4
+ "version": "1.0.30",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
7
7
  "license": "MIT",
@@ -19,7 +19,7 @@
19
19
  "marked": "^16.3.0",
20
20
  "prismjs": "^1.29.0",
21
21
  "react-icons": "^5.0.1",
22
- "@jsonresume/core": "0.3.7"
22
+ "@jsonresume/core": "0.4.0"
23
23
  },
24
24
  "exports": {
25
25
  ".": {
package/src/index.jsx CHANGED
@@ -13,47 +13,25 @@ export const render = (resume) => {
13
13
  font-style: normal;
14
14
  font-weight: normal;
15
15
  font-display: swap;
16
- src: url("/fonts/lmroman10-regular.otf") format("opentype");
16
+ src: url("https://jsonresume.org/fonts/lmroman10-regular.otf") format("opentype");
17
17
  }
18
18
 
19
19
  @font-face {
20
20
  font-family: LatinModern;
21
21
  font-weight: bold;
22
22
  font-display: swap;
23
- src: url("/fonts/lmroman10-bold.otf") format("opentype");
23
+ src: url("https://jsonresume.org/fonts/lmroman10-bold.otf") format("opentype");
24
24
  }
25
25
 
26
26
  @font-face {
27
27
  font-family: LatinModern;
28
28
  font-style: italic;
29
29
  font-display: swap;
30
- src: url("/fonts/lmroman10-italic.otf") format("opentype");
31
- }
32
-
33
- @font-face {
34
- font-family: LatinModernSans;
35
- font-style: normal;
36
- font-weight: normal;
37
- font-display: swap;
38
- src: url("/fonts/lmsans10-regular.otf") format("opentype");
39
- }
40
-
41
- @font-face {
42
- font-family: LatinModernSans;
43
- font-weight: bold;
44
- font-display: swap;
45
- src: url("/fonts/lmsans10-bold.otf") format("opentype");
46
- }
47
-
48
- @font-face {
49
- font-family: LatinModernSans;
50
- font-style: italic;
51
- font-display: swap;
52
- src: url("/fonts/lmsans10-italic.otf") format("opentype");
30
+ src: url("https://jsonresume.org/fonts/lmroman10-italic.otf") format("opentype");
53
31
  }
54
32
 
55
33
  html {
56
- font-family:LatinModern, "Courier New", monospace;
34
+ font-family: LatinModern, "Latin Modern Roman", Georgia, serif;
57
35
  background: #fff;
58
36
  font-size: 11px;
59
37
  }