@markuplint/selector 4.6.5 → 4.6.6

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
@@ -3,7 +3,7 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
- ## [4.6.5](https://github.com/markuplint/markuplint/compare/@markuplint/selector@4.6.4...@markuplint/selector@4.6.5) (2024-06-25)
6
+ ## [4.6.6](https://github.com/markuplint/markuplint/compare/@markuplint/selector@4.6.5...@markuplint/selector@4.6.6) (2024-09-02)
7
7
 
8
8
  **Note:** Version bump only for package @markuplint/selector
9
9
 
@@ -11,6 +11,10 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
11
11
 
12
12
 
13
13
 
14
+ ## [4.6.5](https://github.com/markuplint/markuplint/compare/@markuplint/selector@4.6.4...@markuplint/selector@4.6.5) (2024-06-25)
15
+
16
+ **Note:** Version bump only for package @markuplint/selector
17
+
14
18
  ## [4.6.4](https://github.com/markuplint/markuplint/compare/@markuplint/selector@4.6.3...@markuplint/selector@4.6.4) (2024-06-09)
15
19
 
16
20
  ### Bug Fixes
package/lib/selector.js CHANGED
@@ -103,10 +103,9 @@ class StructuredSelector {
103
103
  __classPrivateFieldSet(this, _StructuredSelector_selector, selector, "f");
104
104
  __classPrivateFieldSet(this, _StructuredSelector_edge, new SelectorTarget(extended, depth), "f");
105
105
  this.headCombinator =
106
- __classPrivateFieldGet(this, _StructuredSelector_selector, "f").nodes[0]?.type === 'combinator' ? __classPrivateFieldGet(this, _StructuredSelector_selector, "f").nodes[0].value ?? null : null;
106
+ __classPrivateFieldGet(this, _StructuredSelector_selector, "f").nodes[0]?.type === 'combinator' ? (__classPrivateFieldGet(this, _StructuredSelector_selector, "f").nodes[0].value ?? null) : null;
107
107
  const nodes = [...__classPrivateFieldGet(this, _StructuredSelector_selector, "f").nodes];
108
108
  if (0 < depth && this.headCombinator) {
109
- // eslint-disable-next-line import/no-named-as-default-member
110
109
  nodes.unshift(parser.pseudo({ value: ':scope' }));
111
110
  }
112
111
  for (const node of nodes) {
@@ -807,7 +806,7 @@ function isScope(
807
806
  el,
808
807
  // eslint-disable-next-line @typescript-eslint/prefer-readonly-parameter-types
809
808
  scope) {
810
- return el === scope ?? el.parentNode === null;
809
+ return el === scope || el.parentNode === null;
811
810
  }
812
811
  function getDescendants(
813
812
  // eslint-disable-next-line @typescript-eslint/prefer-readonly-parameter-types
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@markuplint/selector",
3
- "version": "4.6.5",
3
+ "version": "4.6.6",
4
4
  "description": "Extended W3C Selectors matcher",
5
5
  "repository": "git@github.com:markuplint/markuplint.git",
6
6
  "author": "Yusuke Hirao <yusukehirao@me.com>",
@@ -25,15 +25,15 @@
25
25
  "clean": "tsc --build --clean"
26
26
  },
27
27
  "dependencies": {
28
- "@markuplint/ml-spec": "4.6.3",
28
+ "@markuplint/ml-spec": "4.6.4",
29
29
  "@types/debug": "4.1.12",
30
- "debug": "4.3.5",
31
- "postcss-selector-parser": "6.1.0",
32
- "type-fest": "4.20.1"
30
+ "debug": "4.3.6",
31
+ "postcss-selector-parser": "6.1.2",
32
+ "type-fest": "4.26.0"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@types/jsdom": "21.1.7",
36
- "jsdom": "24.1.0"
36
+ "jsdom": "25.0.0"
37
37
  },
38
- "gitHead": "05fdca254661ec335ff0cae4c6a11db164b032b9"
38
+ "gitHead": "77cd5a25d5cf28c83253b7bfe02cd25b54e236b0"
39
39
  }