html-validate 8.0.1 → 8.0.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.
- package/dist/cjs/browser.js +0 -1
- package/dist/cjs/browser.js.map +1 -1
- package/dist/cjs/core.js +5 -10
- package/dist/cjs/core.js.map +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/jest.js +0 -1
- package/dist/cjs/jest.js.map +1 -1
- package/dist/es/browser.js +0 -1
- package/dist/es/browser.js.map +1 -1
- package/dist/es/core.js +5 -9
- package/dist/es/core.js.map +1 -1
- package/dist/es/index.js +1 -1
- package/dist/es/jest.js +0 -1
- package/dist/es/jest.js.map +1 -1
- package/package.json +10 -4
package/dist/cjs/index.js
CHANGED
|
@@ -7,7 +7,6 @@ var metaHelper = require('./meta-helper.js');
|
|
|
7
7
|
var rulesHelper = require('./rules-helper.js');
|
|
8
8
|
require('node:fs');
|
|
9
9
|
require('node:path');
|
|
10
|
-
require('path');
|
|
11
10
|
require('ajv');
|
|
12
11
|
require('deepmerge');
|
|
13
12
|
require('./elements.js');
|
|
@@ -17,6 +16,7 @@ require('kleur');
|
|
|
17
16
|
require('@sidvind/better-ajv-errors');
|
|
18
17
|
require('@babel/code-frame');
|
|
19
18
|
require('@html-validate/stylish');
|
|
19
|
+
require('path');
|
|
20
20
|
require('glob');
|
|
21
21
|
require('ignore');
|
|
22
22
|
require('prompts');
|
package/dist/cjs/jest.js
CHANGED
package/dist/cjs/jest.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jest.js","sources":["../../../src/jest/jest.ts"],"sourcesContent":[null],"names":["toBeValid","toBeInvalid","toHaveError","toHaveErrors","toHTMLValidate","toMatchCodeframe","toMatchInlineCodeframe"],"mappings":"
|
|
1
|
+
{"version":3,"file":"jest.js","sources":["../../../src/jest/jest.ts"],"sourcesContent":[null],"names":["toBeValid","toBeInvalid","toHaveError","toHaveErrors","toHTMLValidate","toMatchCodeframe","toMatchInlineCodeframe"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAYA,MAAM,CAAC,MAAM,CAAC;eACbA,iBAAS;iBACTC,mBAAW;iBACXC,mBAAW;kBACXC,oBAAY;oBACZC,sBAAc;sBACdC,wBAAgB;4BAChBC,8BAAsB;AACtB,CAAA,CAAC;;"}
|
package/dist/es/browser.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
export { A as Attribute, C as Config, a as ConfigError, b as ConfigLoader, f as DOMNode, d as DOMTokenList, g as DOMTree, D as DynamicValue, E as EventHandler, e as HtmlElement, H as HtmlValidate, l as MetaCopyableProperty, M as MetaTable, j as NestedError, N as NodeClosed, h as NodeType, q as Parser, o as Reporter, R as ResolvedConfig, m as Rule, i as SchemaValidationError, S as Severity, c as StaticConfigLoader, k as TextContent, T as TextNode, U as UserError, V as Validator, W as WrappedError, P as configPresets, p as definePlugin, r as ruleExists, n as sliceLocation, s as staticResolver, v as version } from './core.js';
|
|
2
2
|
export { d as defineMetadata, m as metadataHelper } from './meta-helper.js';
|
|
3
3
|
export { T as TextClassification, c as classifyNodeText, k as keywordPatternMatcher } from './rules-helper.js';
|
|
4
|
-
import 'path';
|
|
5
4
|
import 'ajv';
|
|
6
5
|
import 'deepmerge';
|
|
7
6
|
import './elements.js';
|
package/dist/es/browser.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"browser.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"browser.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;"}
|
package/dist/es/core.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import path from 'path';
|
|
2
1
|
import Ajv from 'ajv';
|
|
3
2
|
import deepmerge from 'deepmerge';
|
|
4
3
|
import { e as entities$1, h as html5, b as bundledElements } from './elements.js';
|
|
@@ -11433,8 +11432,7 @@ class HtmlValidate {
|
|
|
11433
11432
|
*/
|
|
11434
11433
|
async canValidate(filename) {
|
|
11435
11434
|
/* .html is always supported */
|
|
11436
|
-
|
|
11437
|
-
if (extension === ".html") {
|
|
11435
|
+
if (filename.toLowerCase().endsWith(".html")) {
|
|
11438
11436
|
return true;
|
|
11439
11437
|
}
|
|
11440
11438
|
/* test if there is a matching transformer */
|
|
@@ -11452,8 +11450,7 @@ class HtmlValidate {
|
|
|
11452
11450
|
*/
|
|
11453
11451
|
canValidateSync(filename) {
|
|
11454
11452
|
/* .html is always supported */
|
|
11455
|
-
|
|
11456
|
-
if (extension === ".html") {
|
|
11453
|
+
if (filename.toLowerCase().endsWith(".html")) {
|
|
11457
11454
|
return true;
|
|
11458
11455
|
}
|
|
11459
11456
|
/* test if there is a matching transformer */
|
|
@@ -11693,7 +11690,7 @@ class HtmlValidate {
|
|
|
11693
11690
|
/** @public */
|
|
11694
11691
|
const name = "html-validate";
|
|
11695
11692
|
/** @public */
|
|
11696
|
-
const version = "8.0.
|
|
11693
|
+
const version = "8.0.2";
|
|
11697
11694
|
/** @public */
|
|
11698
11695
|
const bugs = "https://gitlab.com/html-validate/html-validate/issues/new";
|
|
11699
11696
|
|
|
@@ -11830,12 +11827,11 @@ function pluralize(word, count) {
|
|
|
11830
11827
|
* @returns The formatted file path.
|
|
11831
11828
|
*/
|
|
11832
11829
|
function formatFilePath(filePath, line, column) {
|
|
11833
|
-
let relPath = path.relative(process.cwd(), filePath);
|
|
11834
11830
|
/* istanbul ignore next: safety check from original implementation */
|
|
11835
11831
|
if (line && column) {
|
|
11836
|
-
|
|
11832
|
+
filePath += `:${line}:${column}`;
|
|
11837
11833
|
}
|
|
11838
|
-
return kleur.green(
|
|
11834
|
+
return kleur.green(filePath);
|
|
11839
11835
|
}
|
|
11840
11836
|
function getStartLocation(message) {
|
|
11841
11837
|
return {
|