@markuplint/ml-core 3.0.0-dev.24 → 3.0.0-dev.290

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 (95) hide show
  1. package/lib/configs.browser.js +1 -5
  2. package/lib/configs.js +33 -31
  3. package/lib/convert-ruleset.d.ts +1 -1
  4. package/lib/convert-ruleset.js +3 -8
  5. package/lib/debug.js +9 -14
  6. package/lib/index.d.ts +13 -12
  7. package/lib/index.js +13 -29
  8. package/lib/ml-core.d.ts +7 -7
  9. package/lib/ml-core.js +60 -66
  10. package/lib/ml-dom/helper/accname.d.ts +1 -1
  11. package/lib/ml-dom/helper/accname.js +23 -19
  12. package/lib/ml-dom/helper/create-node.d.ts +4 -4
  13. package/lib/ml-dom/helper/create-node.js +13 -15
  14. package/lib/ml-dom/helper/debug.d.ts +1 -1
  15. package/lib/ml-dom/helper/debug.js +8 -8
  16. package/lib/ml-dom/helper/getIndent.d.ts +2 -2
  17. package/lib/ml-dom/helper/getIndent.js +30 -28
  18. package/lib/ml-dom/helper/walkers.d.ts +6 -6
  19. package/lib/ml-dom/helper/walkers.js +23 -22
  20. package/lib/ml-dom/index.d.ts +9 -9
  21. package/lib/ml-dom/index.js +1 -5
  22. package/lib/ml-dom/manipulations/child-node-methods.d.ts +9 -9
  23. package/lib/ml-dom/manipulations/child-node-methods.js +31 -25
  24. package/lib/ml-dom/manipulations/get-children.d.ts +4 -4
  25. package/lib/ml-dom/manipulations/get-children.js +5 -7
  26. package/lib/ml-dom/node/attr.d.ts +7 -7
  27. package/lib/ml-dom/node/attr.js +33 -34
  28. package/lib/ml-dom/node/block.d.ts +6 -6
  29. package/lib/ml-dom/node/block.js +21 -15
  30. package/lib/ml-dom/node/character-data.d.ts +4 -4
  31. package/lib/ml-dom/node/character-data.js +20 -19
  32. package/lib/ml-dom/node/child-node.d.ts +9 -9
  33. package/lib/ml-dom/node/child-node.js +3 -5
  34. package/lib/ml-dom/node/comment.d.ts +4 -4
  35. package/lib/ml-dom/node/comment.js +2 -6
  36. package/lib/ml-dom/node/document-fragment.d.ts +4 -4
  37. package/lib/ml-dom/node/document-fragment.js +4 -9
  38. package/lib/ml-dom/node/document-type.d.ts +6 -6
  39. package/lib/ml-dom/node/document-type.js +21 -15
  40. package/lib/ml-dom/node/document.d.ts +32 -29
  41. package/lib/ml-dom/node/document.js +329 -246
  42. package/lib/ml-dom/node/dom-token-list.d.ts +3 -3
  43. package/lib/ml-dom/node/dom-token-list.js +29 -33
  44. package/lib/ml-dom/node/element.d.ts +65 -16
  45. package/lib/ml-dom/node/element.js +396 -306
  46. package/lib/ml-dom/node/named-node-map.d.ts +4 -4
  47. package/lib/ml-dom/node/named-node-map.js +18 -18
  48. package/lib/ml-dom/node/node-list.d.ts +6 -6
  49. package/lib/ml-dom/node/node-list.js +25 -13
  50. package/lib/ml-dom/node/node-store.d.ts +5 -5
  51. package/lib/ml-dom/node/node-store.js +25 -10
  52. package/lib/ml-dom/node/node.d.ts +12 -12
  53. package/lib/ml-dom/node/node.js +101 -76
  54. package/lib/ml-dom/node/parent-node.d.ts +6 -6
  55. package/lib/ml-dom/node/parent-node.js +31 -29
  56. package/lib/ml-dom/node/rule-mapper.d.ts +5 -5
  57. package/lib/ml-dom/node/rule-mapper.js +20 -17
  58. package/lib/ml-dom/node/text.d.ts +4 -4
  59. package/lib/ml-dom/node/text.js +6 -11
  60. package/lib/ml-dom/node/types.d.ts +30 -16
  61. package/lib/ml-dom/node/types.js +1 -2
  62. package/lib/ml-dom/node/unexpected-call-error.js +1 -4
  63. package/lib/ml-dom/token/token.js +19 -23
  64. package/lib/ml-rule/create-rule.d.ts +3 -3
  65. package/lib/ml-rule/create-rule.js +1 -5
  66. package/lib/ml-rule/create-test-rule.d.ts +5 -5
  67. package/lib/ml-rule/create-test-rule.js +3 -7
  68. package/lib/ml-rule/index.d.ts +3 -3
  69. package/lib/ml-rule/index.js +3 -6
  70. package/lib/ml-rule/ml-rule-context.d.ts +4 -4
  71. package/lib/ml-rule/ml-rule-context.js +11 -13
  72. package/lib/ml-rule/ml-rule.d.ts +9 -9
  73. package/lib/ml-rule/ml-rule.js +48 -45
  74. package/lib/ml-rule/types.d.ts +12 -12
  75. package/lib/ml-rule/types.js +1 -2
  76. package/lib/plugin/index.d.ts +2 -2
  77. package/lib/plugin/index.js +2 -5
  78. package/lib/plugin/plugin.d.ts +2 -2
  79. package/lib/plugin/plugin.js +1 -5
  80. package/lib/plugin/types.d.ts +6 -6
  81. package/lib/plugin/types.js +1 -2
  82. package/lib/ruleset/index.d.ts +3 -3
  83. package/lib/ruleset/index.js +4 -8
  84. package/lib/test/index.d.ts +9 -9
  85. package/lib/test/index.js +14 -24
  86. package/lib/types.d.ts +11 -10
  87. package/lib/types.js +1 -2
  88. package/lib/utils/get-location-from-chars.d.ts +1 -1
  89. package/lib/utils/get-location-from-chars.js +1 -5
  90. package/lib/utils/index.d.ts +1 -1
  91. package/lib/utils/index.js +1 -5
  92. package/lib/utils/string-splice.js +1 -5
  93. package/package.json +25 -16
  94. package/tsconfig.test.json +0 -3
  95. package/tsconfig.tsbuildinfo +0 -1
@@ -1,4 +1,4 @@
1
- import type { MLAttr } from './attr';
1
+ import type { MLAttr } from './attr.js';
2
2
  import type { RuleInfo } from '@markuplint/ml-config';
3
3
  type Scope = {
4
4
  raw: string;
@@ -11,7 +11,7 @@ export declare class MLDomTokenList extends Array<string> implements DOMTokenLis
11
11
  #private;
12
12
  constructor(tokens: string, ownerAttrs: MLAttr<any, any>[]);
13
13
  get value(): string;
14
- add(...tokens: string[]): void;
14
+ add(...tokens: readonly string[]): void;
15
15
  /**
16
16
  * @implements `@markuplint/ml-core` API: `MLDomTokenList`
17
17
  */
@@ -23,7 +23,7 @@ export declare class MLDomTokenList extends Array<string> implements DOMTokenLis
23
23
  * @implements `@markuplint/ml-core` API: `MLDomTokenList`
24
24
  */
25
25
  pick(token: string): Scope | null;
26
- remove(...tokens: string[]): void;
26
+ remove(...tokens: readonly string[]): void;
27
27
  replace(token: string, newToken: string): boolean;
28
28
  supports(token: string): boolean;
29
29
  toString(): string;
@@ -1,12 +1,11 @@
1
- "use strict";
2
1
  var _MLDomTokenList_origin, _MLDomTokenList_ownerAttrs, _MLDomTokenList_set;
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.MLDomTokenList = void 0;
5
- const tslib_1 = require("tslib");
6
- const parser_utils_1 = require("@markuplint/parser-utils");
7
- const unexpected_call_error_1 = tslib_1.__importDefault(require("./unexpected-call-error"));
8
- class MLDomTokenList extends Array {
9
- constructor(tokens, ownerAttrs) {
2
+ import { __classPrivateFieldGet, __classPrivateFieldSet } from "tslib";
3
+ import { getCol, getLine } from '@markuplint/parser-utils';
4
+ import UnexpectedCallError from './unexpected-call-error.js';
5
+ export class MLDomTokenList extends Array {
6
+ constructor(tokens,
7
+ // eslint-disable-next-line @typescript-eslint/prefer-readonly-parameter-types
8
+ ownerAttrs) {
10
9
  const list = tokens
11
10
  .split(/\s+/)
12
11
  .map(t => t.trim())
@@ -19,22 +18,22 @@ class MLDomTokenList extends Array {
19
18
  */
20
19
  _MLDomTokenList_ownerAttrs.set(this, void 0);
21
20
  _MLDomTokenList_set.set(this, void 0);
22
- tslib_1.__classPrivateFieldSet(this, _MLDomTokenList_origin, tokens, "f");
23
- tslib_1.__classPrivateFieldSet(this, _MLDomTokenList_ownerAttrs, ownerAttrs, "f");
24
- tslib_1.__classPrivateFieldSet(this, _MLDomTokenList_set, new Set(list), "f");
21
+ __classPrivateFieldSet(this, _MLDomTokenList_origin, tokens, "f");
22
+ __classPrivateFieldSet(this, _MLDomTokenList_ownerAttrs, ownerAttrs, "f");
23
+ __classPrivateFieldSet(this, _MLDomTokenList_set, new Set(list), "f");
25
24
  }
26
25
  get value() {
27
26
  return this.join(' ');
28
27
  }
29
28
  add(...tokens) {
30
29
  for (const token of tokens) {
31
- if (tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_set, "f").has(token)) {
30
+ if (__classPrivateFieldGet(this, _MLDomTokenList_set, "f").has(token)) {
32
31
  continue;
33
32
  }
34
- tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_set, "f").add(token);
33
+ __classPrivateFieldGet(this, _MLDomTokenList_set, "f").add(token);
35
34
  this.push(token);
36
35
  }
37
- tslib_1.__classPrivateFieldSet(this, _MLDomTokenList_origin, tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_origin, "f") + tokens.join(' '), "f");
36
+ __classPrivateFieldSet(this, _MLDomTokenList_origin, __classPrivateFieldGet(this, _MLDomTokenList_origin, "f") + tokens.join(' '), "f");
38
37
  }
39
38
  /**
40
39
  * @implements `@markuplint/ml-core` API: `MLDomTokenList`
@@ -43,7 +42,7 @@ class MLDomTokenList extends Array {
43
42
  let offset = 0;
44
43
  const tokens = Array.from(this);
45
44
  const locs = [];
46
- while (tokens.length) {
45
+ while (tokens.length > 0) {
47
46
  const token = tokens.shift();
48
47
  if (!token) {
49
48
  break;
@@ -65,14 +64,13 @@ class MLDomTokenList extends Array {
65
64
  return locs;
66
65
  }
67
66
  contains(token) {
68
- return tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_set, "f").has(token);
67
+ return __classPrivateFieldGet(this, _MLDomTokenList_set, "f").has(token);
69
68
  }
70
69
  forEach(callbackfn, thisArg) {
71
- this.forEach.bind(this)((v, i) => callbackfn(v, i, thisArg !== null && thisArg !== void 0 ? thisArg : this));
70
+ this.forEach.bind(this)((v, i) => callbackfn(v, i, thisArg ?? this));
72
71
  }
73
72
  item(index) {
74
- var _a;
75
- return (_a = this[index]) !== null && _a !== void 0 ? _a : null;
73
+ return this[index] ?? null;
76
74
  }
77
75
  /**
78
76
  * @implements `@markuplint/ml-core` API: `MLDomTokenList`
@@ -91,41 +89,40 @@ class MLDomTokenList extends Array {
91
89
  };
92
90
  }
93
91
  remove(...tokens) {
94
- throw new unexpected_call_error_1.default('Not supported "remove" method');
92
+ throw new UnexpectedCallError('Not supported "remove" method');
95
93
  }
96
94
  replace(token, newToken) {
97
- throw new unexpected_call_error_1.default('Not supported "replace" method');
95
+ throw new UnexpectedCallError('Not supported "replace" method');
98
96
  }
99
97
  supports(token) {
100
- throw new unexpected_call_error_1.default('Not supported "supports" method');
98
+ throw new UnexpectedCallError('Not supported "supports" method');
101
99
  }
102
100
  toString() {
103
101
  return this.value;
104
102
  }
105
103
  toggle(token, force) {
106
- throw new unexpected_call_error_1.default('Not supported "toggle" method');
104
+ throw new UnexpectedCallError('Not supported "toggle" method');
107
105
  }
108
106
  _pick(token, _offset = 0) {
109
- var _a, _b, _c, _d, _e, _f;
110
- token = token.trim().split(/\s+/g)[0];
107
+ token = token.trim().split(/\s+/g)[0] ?? '';
111
108
  if (!token) {
112
109
  return null;
113
110
  }
114
- for (const ownerAttr of tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_ownerAttrs, "f")) {
111
+ for (const ownerAttr of __classPrivateFieldGet(this, _MLDomTokenList_ownerAttrs, "f")) {
115
112
  if (ownerAttr.isDynamicValue) {
116
113
  continue;
117
114
  }
118
- const startOffset = tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_origin, "f").indexOf(token, _offset);
115
+ const startOffset = __classPrivateFieldGet(this, _MLDomTokenList_origin, "f").indexOf(token, _offset);
119
116
  if (startOffset === -1) {
120
117
  continue;
121
118
  }
122
- const startLine = (0, parser_utils_1.getLine)(tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_origin, "f"), startOffset);
123
- const startCol = (0, parser_utils_1.getCol)(tslib_1.__classPrivateFieldGet(this, _MLDomTokenList_origin, "f"), startOffset);
119
+ const startLine = getLine(__classPrivateFieldGet(this, _MLDomTokenList_origin, "f"), startOffset);
120
+ const startCol = getCol(__classPrivateFieldGet(this, _MLDomTokenList_origin, "f"), startOffset);
124
121
  return {
125
122
  raw: token,
126
- startOffset: ((_b = (_a = ownerAttr.valueNode) === null || _a === void 0 ? void 0 : _a.startOffset) !== null && _b !== void 0 ? _b : 0) + startOffset,
127
- startLine: ((_d = (_c = ownerAttr.valueNode) === null || _c === void 0 ? void 0 : _c.startLine) !== null && _d !== void 0 ? _d : 0) + (startLine - 1),
128
- startCol: ((_f = (_e = ownerAttr.valueNode) === null || _e === void 0 ? void 0 : _e.startCol) !== null && _f !== void 0 ? _f : 0) + (startCol - 1),
123
+ startOffset: (ownerAttr.valueNode?.startOffset ?? 0) + startOffset,
124
+ startLine: (ownerAttr.valueNode?.startLine ?? 0) + (startLine - 1),
125
+ startCol: (ownerAttr.valueNode?.startCol ?? 0) + (startCol - 1),
129
126
  rule: ownerAttr.rule,
130
127
  _searchedIndex: startOffset,
131
128
  };
@@ -133,5 +130,4 @@ class MLDomTokenList extends Array {
133
130
  return null;
134
131
  }
135
132
  }
136
- exports.MLDomTokenList = MLDomTokenList;
137
133
  _MLDomTokenList_origin = new WeakMap(), _MLDomTokenList_ownerAttrs = new WeakMap(), _MLDomTokenList_set = new WeakMap();
@@ -1,15 +1,15 @@
1
- import type { MLDocument } from './document';
2
- import type { MLNamedNodeMap } from './named-node-map';
3
- import type { MLText } from './text';
4
- import type { ElementNodeType, PretenderContext } from './types';
1
+ import type { MLDocument } from './document.js';
2
+ import type { MLNamedNodeMap } from './named-node-map.js';
3
+ import type { MLText } from './text.js';
4
+ import type { ElementNodeType, PretenderContext } from './types.js';
5
5
  import type { ElementType, MLASTElement, NamespaceURI } from '@markuplint/ml-ast';
6
- import type { Pretender, RuleConfigValue, RuleInfo } from '@markuplint/ml-config';
6
+ import type { PlainData, Pretender, RuleConfigValue, RuleInfo } from '@markuplint/ml-config';
7
7
  import type { ARIAVersion } from '@markuplint/ml-spec';
8
- import { MLToken } from '../token/token';
9
- import { MLAttr } from './attr';
10
- import { MLDomTokenList } from './dom-token-list';
11
- import { MLParentNode } from './parent-node';
12
- export declare class MLElement<T extends RuleConfigValue, O = null> extends MLParentNode<T, O, MLASTElement> implements Element, HTMLOrSVGElement, HTMLElement {
8
+ import { MLToken } from '../token/token.js';
9
+ import { MLAttr } from './attr.js';
10
+ import { MLDomTokenList } from './dom-token-list.js';
11
+ import { MLParentNode } from './parent-node.js';
12
+ export declare class MLElement<T extends RuleConfigValue, O extends PlainData = undefined> extends MLParentNode<T, O, MLASTElement> implements Element, HTMLOrSVGElement, HTMLElement {
13
13
  #private;
14
14
  readonly closeTag: MLToken | null;
15
15
  readonly elementType: ElementType;
@@ -361,6 +361,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
361
361
  * @see https://dom.spec.whatwg.org/#dom-slotable-assignedslot
362
362
  */
363
363
  get assignedSlot(): HTMLSlotElement | null;
364
+ get attributeStyleMap(): StylePropertyMap;
364
365
  /**
365
366
  * @implements DOM API: `Element`
366
367
  * @see https://dom.spec.whatwg.org/#dom-element-attributes
@@ -739,7 +740,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
739
740
  * @unsupported
740
741
  * @implements DOM API: `Element`
741
742
  */
742
- get oncopy(): ((this: DocumentAndElementEventHandlers, ev: ClipboardEvent) => any) | null;
743
+ get oncopy(): ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
743
744
  /**
744
745
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
745
746
  *
@@ -755,7 +756,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
755
756
  * @unsupported
756
757
  * @implements DOM API: `Element`
757
758
  */
758
- get oncut(): ((this: DocumentAndElementEventHandlers, ev: ClipboardEvent) => any) | null;
759
+ get oncut(): ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
759
760
  /**
760
761
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
761
762
  *
@@ -1035,7 +1036,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1035
1036
  * @unsupported
1036
1037
  * @implements DOM API: `Element`
1037
1038
  */
1038
- get onpaste(): ((this: DocumentAndElementEventHandlers, ev: ClipboardEvent) => any) | null;
1039
+ get onpaste(): ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
1039
1040
  /**
1040
1041
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1041
1042
  *
@@ -1164,6 +1165,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1164
1165
  * @implements DOM API: `Element`
1165
1166
  */
1166
1167
  get onscroll(): ((this: GlobalEventHandlers, ev: Event) => any) | null;
1168
+ get onscrollend(): ((this: GlobalEventHandlers, ev: Event) => any) | null;
1167
1169
  /**
1168
1170
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1169
1171
  *
@@ -1372,6 +1374,14 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1372
1374
  * @see https://www.w3.org/TR/css-shadow-parts-1/#idl
1373
1375
  */
1374
1376
  get part(): DOMTokenList;
1377
+ /**
1378
+ * **IT THROWS AN ERROR WHEN CALLING THIS.**
1379
+ *
1380
+ * @unsupported
1381
+ * @implements DOM API: `Element`
1382
+ * @see https://html.spec.whatwg.org/multipage/popover.html#dom-popover
1383
+ */
1384
+ get popover(): string | null;
1375
1385
  /**
1376
1386
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1377
1387
  *
@@ -1548,6 +1558,14 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1548
1558
  * @implements DOM API: `Element`
1549
1559
  */
1550
1560
  blur(): void;
1561
+ /**
1562
+ * **IT THROWS AN ERROR WHEN CALLING THIS.**
1563
+ *
1564
+ * @deprecated
1565
+ * @unsupported
1566
+ * @implements DOM API: `Element`
1567
+ */
1568
+ checkVisibility(options?: CheckVisibilityOptions): boolean;
1551
1569
  /**
1552
1570
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1553
1571
  *
@@ -1561,6 +1579,13 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1561
1579
  * @see https://dom.spec.whatwg.org/#ref-for-dom-element-closest%E2%91%A0
1562
1580
  */
1563
1581
  closest(selectors: string): MLElement<T, O> | null;
1582
+ /**
1583
+ * **IT THROWS AN ERROR WHEN CALLING THIS.**
1584
+ *
1585
+ * @unsupported
1586
+ * @implements DOM API: `Element`
1587
+ */
1588
+ computedStyleMap(): StylePropertyMapReadOnly;
1564
1589
  fixNodeName(name: string): void;
1565
1590
  /**
1566
1591
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
@@ -1651,7 +1676,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1651
1676
  * @implements DOM API: `Element`
1652
1677
  * @see https://dom.spec.whatwg.org/#ref-for-dom-element-getelementsbyclassname
1653
1678
  */
1654
- getElementsByTagName(qualifiedName: string): ReturnType<typeof Element['prototype']['getElementsByTagName']>;
1679
+ getElementsByTagName(qualifiedName: string): ReturnType<(typeof Element)['prototype']['getElementsByTagName']>;
1655
1680
  /**
1656
1681
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1657
1682
  *
@@ -1704,6 +1729,14 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1704
1729
  * @see https://www.w3.org/TR/pointerevents2/#dom-element-haspointercapture
1705
1730
  */
1706
1731
  hasPointerCapture(pointerId: number): boolean;
1732
+ /**
1733
+ * **IT THROWS AN ERROR WHEN CALLING THIS.**
1734
+ *
1735
+ * @unsupported
1736
+ * @implements DOM API: `Element`
1737
+ * @see https://html.spec.whatwg.org/multipage/popover.html#dom-hidepopover
1738
+ */
1739
+ hidePopover(): void;
1707
1740
  /**
1708
1741
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1709
1742
  *
@@ -1731,7 +1764,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1731
1764
  /**
1732
1765
  * @implements `@markuplint/ml-core` API: `MLElement`
1733
1766
  */
1734
- isDescendantByUUIDList(uuidList: string[]): boolean;
1767
+ isDescendantByUUIDList(uuidList: readonly string[]): boolean;
1735
1768
  /**
1736
1769
  * @implements `@markuplint/ml-core` API: `MLElement`
1737
1770
  */
@@ -1744,7 +1777,7 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1744
1777
  /**
1745
1778
  * Pretenders Initialization
1746
1779
  */
1747
- pretending(pretenders: Pretender[]): void;
1780
+ pretending(pretenders: readonly Pretender[]): void;
1748
1781
  /**
1749
1782
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1750
1783
  *
@@ -1873,6 +1906,14 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1873
1906
  * @see https://www.w3.org/TR/pointerevents2/#idl-def-element-setpointercapture-pointerid
1874
1907
  */
1875
1908
  setPointerCapture(pointerId: number): void;
1909
+ /**
1910
+ * **IT THROWS AN ERROR WHEN CALLING THIS.**
1911
+ *
1912
+ * @unsupported
1913
+ * @implements DOM API: `Element`
1914
+ * @see https://html.spec.whatwg.org/multipage/popover.html#dom-showpopover
1915
+ */
1916
+ showPopover(): void;
1876
1917
  /**
1877
1918
  * @implements `@markuplint/ml-core` API: `MLElement`
1878
1919
  */
@@ -1889,6 +1930,14 @@ export declare class MLElement<T extends RuleConfigValue, O = null> extends MLPa
1889
1930
  * @see https://dom.spec.whatwg.org/#ref-for-dom-element-toggleattribute%E2%91%A0
1890
1931
  */
1891
1932
  toggleAttribute(qualifiedName: string, force?: boolean): boolean;
1933
+ /**
1934
+ * **IT THROWS AN ERROR WHEN CALLING THIS.**
1935
+ *
1936
+ * @unsupported
1937
+ * @implements DOM API: `Element`
1938
+ * @see https://html.spec.whatwg.org/multipage/popover.html#dom-togglepopover
1939
+ */
1940
+ togglePopover(force?: boolean): void;
1892
1941
  /**
1893
1942
  * **IT THROWS AN ERROR WHEN CALLING THIS.**
1894
1943
  *