hdoc-tools 0.9.1 → 0.9.2

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.
Files changed (2) hide show
  1. package/hdoc-validate.js +5 -1
  2. package/package.json +1 -1
package/hdoc-validate.js CHANGED
@@ -58,7 +58,7 @@
58
58
  for (let i = 0; i < translate_output[key].length; i++) {
59
59
  for (const spelling in translate_output[key][i]) {
60
60
  if (translate_output[key][i].hasOwnProperty(spelling)) {
61
- errors[htmlFile.relativePath].push(`${error_message} ${spelling}`);
61
+ errors[htmlFile.relativePath].push(`${error_message} ${spelling} should be ${translate_output[key][i][spelling].details}`);
62
62
  }
63
63
  }
64
64
  }
@@ -74,6 +74,10 @@
74
74
  const valid_url = hdoc.valid_url(links[i]);
75
75
  if (!valid_url) {
76
76
  // Could be a relative path, check
77
+ if (links[i].startsWith('/')) {
78
+ const link_root = links[i].split('/')[0];
79
+ if (link_root !== hdocbook_config.docId) continue;
80
+ }
77
81
  isRelativePath(source_path, htmlFile, links[i]);
78
82
  } else {
79
83
  messages[htmlFile.relativePath].push(`Link is a properly formatted external URL: ${links[i]}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hdoc-tools",
3
- "version": "0.9.1",
3
+ "version": "0.9.2",
4
4
  "description": "Hornbill HDocBook Development Support Tool",
5
5
  "main": "hdoc.js",
6
6
  "bin": {