@thi.ng/hdom-mock 2.1.99 → 2.1.101

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
@@ -1,6 +1,6 @@
1
1
  # Change Log
2
2
 
3
- - **Last updated**: 2024-04-23T07:02:18Z
3
+ - **Last updated**: 2024-05-08T18:24:31Z
4
4
  - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
5
5
 
6
6
  All notable changes to this project will be documented in this file.
package/README.md CHANGED
@@ -63,7 +63,7 @@ For Node.js REPL:
63
63
  const hm = await import("@thi.ng/hdom-mock");
64
64
  ```
65
65
 
66
- Package sizes (brotli'd, pre-treeshake): ESM: 1.08 KB
66
+ Package sizes (brotli'd, pre-treeshake): ESM: 1.07 KB
67
67
 
68
68
  ## Dependencies
69
69
 
package/index.js CHANGED
@@ -67,13 +67,11 @@ class HDOMNode {
67
67
  }
68
68
  }
69
69
  getElementById(id) {
70
- if (this.attribs.id === id)
71
- return this;
70
+ if (this.attribs.id === id) return this;
72
71
  let c;
73
72
  for (c of this.children) {
74
73
  c = c.getElementById(id);
75
- if (c)
76
- return c;
74
+ if (c) return c;
77
75
  }
78
76
  return null;
79
77
  }
@@ -145,8 +143,7 @@ class MockHDOM {
145
143
  return el;
146
144
  }
147
145
  setAttrib(el, id, val, attribs) {
148
- if (id.startsWith("__"))
149
- return;
146
+ if (id.startsWith("__")) return;
150
147
  const isListener = id.indexOf("on") === 0;
151
148
  if (!isListener && typeof val === "function") {
152
149
  val = val(attribs);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/hdom-mock",
3
- "version": "2.1.99",
3
+ "version": "2.1.101",
4
4
  "description": "Mock base implementation for @thi.ng/hdom API",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -36,15 +36,15 @@
36
36
  "tool:tangle": "../../node_modules/.bin/tangle src/**/*.ts"
37
37
  },
38
38
  "dependencies": {
39
- "@thi.ng/api": "^8.11.1",
40
- "@thi.ng/checks": "^3.6.3",
41
- "@thi.ng/hdom": "^9.4.32"
39
+ "@thi.ng/api": "^8.11.2",
40
+ "@thi.ng/checks": "^3.6.4",
41
+ "@thi.ng/hdom": "^9.4.34"
42
42
  },
43
43
  "devDependencies": {
44
- "@microsoft/api-extractor": "^7.43.0",
45
- "esbuild": "^0.20.2",
46
- "typedoc": "^0.25.12",
47
- "typescript": "^5.4.3"
44
+ "@microsoft/api-extractor": "^7.43.2",
45
+ "esbuild": "^0.21.1",
46
+ "typedoc": "^0.25.13",
47
+ "typescript": "^5.4.5"
48
48
  },
49
49
  "keywords": [
50
50
  "datastructure",
@@ -70,5 +70,5 @@
70
70
  "status": "alpha",
71
71
  "year": 2018
72
72
  },
73
- "gitHead": "5dd66c18a3862a3af69a5b2f49563f7cbdd960c2\n"
73
+ "gitHead": "df34b4a9e650cc7323575356de207d78933bdcf3\n"
74
74
  }