@docusaurus/utils-validation 0.0.0-4466 → 0.0.0-4484

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.
@@ -10,7 +10,7 @@ exports.JoiFrontMatter = void 0;
10
10
  const tslib_1 = require("tslib");
11
11
  const Joi_1 = (0, tslib_1.__importDefault)(require("./Joi"));
12
12
  // Enhance the default Joi.string() type so that it can convert number to strings
13
- // If user use frontmatter "tag: 2021", we shouldn't need to ask the user to write "tag: '2021'"
13
+ // If user use front matter "tag: 2021", we shouldn't need to ask the user to write "tag: '2021'"
14
14
  // Also yaml tries to convert patterns like "2019-01-01" to dates automatically
15
15
  // see https://github.com/facebook/docusaurus/issues/4642
16
16
  // see https://github.com/sideway/joi/issues/1442#issuecomment-823997884
@@ -1 +1 @@
1
- {"version":3,"file":"JoiFrontMatter.js","sourceRoot":"","sources":["../src/JoiFrontMatter.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;;AAEH,6DAAwB;AAExB,iFAAiF;AACjF,gGAAgG;AAChG,+EAA+E;AAC/E,yDAAyD;AACzD,wEAAwE;AACxE,MAAM,oBAAoB,GAAkB;IAC1C,IAAI,EAAE,QAAQ;IACd,IAAI,EAAE,aAAG,CAAC,MAAM,EAAE;IAClB,2EAA2E;IAC3E,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE;QACjB,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,YAAY,IAAI,EAAE;YACtD,OAAO,EAAC,KAAK,EAAE,KAAK,CAAC,QAAQ,EAAE,EAAC,CAAC;SAClC;QACD,OAAO,EAAC,KAAK,EAAC,CAAC;IACjB,CAAC;CACF,CAAC;AACW,QAAA,cAAc,GAAe,aAAG,CAAC,MAAM,CAAC,oBAAoB,CAAC,CAAC"}
1
+ {"version":3,"file":"JoiFrontMatter.js","sourceRoot":"","sources":["../src/JoiFrontMatter.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;;AAEH,6DAAwB;AAExB,iFAAiF;AACjF,iGAAiG;AACjG,+EAA+E;AAC/E,yDAAyD;AACzD,wEAAwE;AACxE,MAAM,oBAAoB,GAAkB;IAC1C,IAAI,EAAE,QAAQ;IACd,IAAI,EAAE,aAAG,CAAC,MAAM,EAAE;IAClB,2EAA2E;IAC3E,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE;QACjB,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,YAAY,IAAI,EAAE;YACtD,OAAO,EAAC,KAAK,EAAE,KAAK,CAAC,QAAQ,EAAE,EAAC,CAAC;SAClC;QACD,OAAO,EAAC,KAAK,EAAC,CAAC;IACjB,CAAC;CACF,CAAC;AACW,QAAA,cAAc,GAAe,aAAG,CAAC,MAAM,CAAC,oBAAoB,CAAC,CAAC"}
@@ -93,7 +93,7 @@ function validateFrontMatter(frontMatter, schema) {
93
93
  const errorDetails = error.details;
94
94
  const invalidFields = errorDetails.map(({ path }) => path).join(', ');
95
95
  (0, exports.logValidationBugReportHint)();
96
- logger_1.default.error `The following frontmatter:
96
+ logger_1.default.error `The following front matter:
97
97
  ${logger_1.default.yellow(frontMatterString)}
98
98
  contains invalid values for field(s): ${logger_1.default.yellow(invalidFields)}.
99
99
  ${errorDetails.map(({ message }) => message)}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docusaurus/utils-validation",
3
- "version": "0.0.0-4466",
3
+ "version": "0.0.0-4484",
4
4
  "description": "Node validation utility functions for Docusaurus packages.",
5
5
  "main": "./lib/index.js",
6
6
  "types": "./lib/index.d.ts",
@@ -18,8 +18,8 @@
18
18
  },
19
19
  "license": "MIT",
20
20
  "dependencies": {
21
- "@docusaurus/logger": "0.0.0-4466",
22
- "@docusaurus/utils": "0.0.0-4466",
21
+ "@docusaurus/logger": "0.0.0-4484",
22
+ "@docusaurus/utils": "0.0.0-4484",
23
23
  "joi": "^17.4.2",
24
24
  "tslib": "^2.3.1"
25
25
  },
@@ -30,5 +30,5 @@
30
30
  "engines": {
31
31
  "node": ">=14"
32
32
  },
33
- "gitHead": "e610ca3c26f1f080d90ac0cf02e73e556142dd7f"
33
+ "gitHead": "ae60bd68f83e8063d4467fc31fa2c42432a5deeb"
34
34
  }
@@ -8,7 +8,7 @@
8
8
  import Joi from './Joi';
9
9
 
10
10
  // Enhance the default Joi.string() type so that it can convert number to strings
11
- // If user use frontmatter "tag: 2021", we shouldn't need to ask the user to write "tag: '2021'"
11
+ // If user use front matter "tag: 2021", we shouldn't need to ask the user to write "tag: '2021'"
12
12
  // Also yaml tries to convert patterns like "2019-01-01" to dates automatically
13
13
  // see https://github.com/facebook/docusaurus/issues/4642
14
14
  // see https://github.com/sideway/joi/issues/1442#issuecomment-823997884
@@ -112,7 +112,7 @@ export function validateFrontMatter<T>(
112
112
 
113
113
  logValidationBugReportHint();
114
114
 
115
- logger.error`The following frontmatter:
115
+ logger.error`The following front matter:
116
116
  ${logger.yellow(frontMatterString)}
117
117
  contains invalid values for field(s): ${logger.yellow(invalidFields)}.
118
118
  ${errorDetails.map(({message}) => message)}