cvdl-ts 1.0.21 → 1.0.23

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.
@@ -35,4 +35,4 @@ export declare class FontDict {
35
35
  load_fonts(storage: Storage): Promise<this>;
36
36
  get_font(name: string): fontkit.Font;
37
37
  }
38
- export declare function render({ resume, layout_schemas, data_schemas, resume_layout, bindings, fontDict, }: RenderProps): Promise<Layout.RenderedLayout[]>;
38
+ export declare function render({ resume, layout_schemas, data_schemas, resume_layout, bindings, fontDict, }: RenderProps): Layout.RenderedLayout[];
package/dist/AnyLayout.js CHANGED
@@ -37,7 +37,6 @@ class FontDict {
37
37
  const variants = cartesian(["Exo", "OpenSans", "SourceCodePro"], ["Medium", "Bold"], ["", "Italic"]);
38
38
  await Promise.all(variants.map(async ([name, weight, style]) => {
39
39
  const fontName = `${name}-${weight}${style}`;
40
- console.error(`Loading font ${fontName}`);
41
40
  if (this.fonts.has(fontName)) {
42
41
  console.log(`Font ${fontName} is already loaded`);
43
42
  return;
@@ -57,7 +56,7 @@ class FontDict {
57
56
  }
58
57
  }
59
58
  exports.FontDict = FontDict;
60
- async function render({ resume, layout_schemas, data_schemas, resume_layout, bindings, fontDict, }) {
59
+ function render({ resume, layout_schemas, data_schemas, resume_layout, bindings, fontDict, }) {
61
60
  // Compute the total usable width by subtracting the margins from the document width
62
61
  const width = resume_layout.width -
63
62
  (resume_layout.margin.left + resume_layout.margin.right);
@@ -66,7 +65,7 @@ async function render({ resume, layout_schemas, data_schemas, resume_layout, bin
66
65
  ? width
67
66
  : width - (0, ResumeLayout_1.vertical_margin)(resume_layout.column_type) / 2.0;
68
67
  const layouts = [];
69
- console.error("Rendering sections...");
68
+ console.info("Rendering sections...");
70
69
  for (const section of resume.sections) {
71
70
  // Render Section Header
72
71
  // 1. Find the layout schema for the section
package/dist/Defaults.js CHANGED
@@ -828,7 +828,7 @@ exports.DefaultSections = [
828
828
  fields: {
829
829
  "name": { tag: "Url", value: { text: "Greatest Software Development Course", url: "www.google.com" } },
830
830
  "date": { tag: "String", value: "01-01-1970" },
831
- "issues": { tag: "String", value: "An course that teaches only to the best of the best" },
831
+ "issuer": { tag: "String", value: "An course that teaches only to the best of the best" },
832
832
  }
833
833
  },
834
834
  {
@@ -836,7 +836,7 @@ exports.DefaultSections = [
836
836
  fields: {
837
837
  "name": { tag: "Url", value: { text: "Greatest Software Development Course", url: "www.google.com" } },
838
838
  "date": { tag: "String", value: "01-01-1970" },
839
- "issues": { tag: "String", value: "An course that teaches only to the best of the best" },
839
+ "issuer": { tag: "String", value: "An course that teaches only to the best of the best" },
840
840
  }
841
841
  },
842
842
  ]),
@@ -849,7 +849,7 @@ exports.DefaultSections = [
849
849
  fields: {
850
850
  "name": { tag: "Url", value: { text: "How to develop good software", url: "www.google.com" } },
851
851
  "publisher": { tag: "String", value: "SoftwareAwards.inc" },
852
- "date": { tag: "String", value: "01-01-1970" },
852
+ "releaseDate": { tag: "String", value: "01-01-1970" },
853
853
  "summary": { tag: "String", value: "A publication worthy of the best of the best" },
854
854
  }
855
855
  },
@@ -857,8 +857,8 @@ exports.DefaultSections = [
857
857
  id: Utils.randomString(),
858
858
  fields: {
859
859
  "name": { tag: "Url", value: { text: "How to develop good software", url: "www.google.com" } },
860
- "awarder": { tag: "String", value: "SoftwareAwards.inc" },
861
- "date": { tag: "String", value: "01-01-1970" },
860
+ "publisher": { tag: "String", value: "SoftwareAwards.inc" },
861
+ "releaseDate": { tag: "String", value: "01-01-1970" },
862
862
  "summary": { tag: "String", value: "A publication worthy of the best of the best" },
863
863
  }
864
864
  },
@@ -40,6 +40,10 @@ class LocalStorage {
40
40
  return Promise.resolve();
41
41
  }
42
42
  async initiate_storage() {
43
+ if (localStorage.getItem("version") !== "0.1.2") {
44
+ localStorage.clear();
45
+ localStorage.setItem("version", "0.1.2");
46
+ }
43
47
  if (!localStorage.getItem("resumes")) {
44
48
  localStorage.setItem("resumes", JSON.stringify([Defaults.DefaultResume]));
45
49
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cvdl-ts",
3
- "version": "1.0.21",
3
+ "version": "1.0.23",
4
4
  "description": "Typescript Implementation of CVDL Compiler",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",