@siteimprove/alfa-list 0.97.0 → 0.98.0

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,5 +1,11 @@
1
1
  # @siteimprove/alfa-list
2
2
 
3
+ ## 0.98.0
4
+
5
+ ### Patch Changes
6
+
7
+ - **Changed:** Classes that do not implement the Singleton pattern now have `protected` constructor and can be extended. ([#1735](https://github.com/Siteimprove/alfa/pull/1735))
8
+
3
9
  ## 0.97.0
4
10
 
5
11
  ## 0.96.0
package/dist/list.d.ts CHANGED
@@ -11,6 +11,7 @@ import { Option } from "@siteimprove/alfa-option";
11
11
  import { Predicate } from "@siteimprove/alfa-predicate";
12
12
  import type { Reducer } from "@siteimprove/alfa-reducer";
13
13
  import type { Refinement } from "@siteimprove/alfa-refinement";
14
+ import { Branch, Empty, Leaf } from "./node.js";
14
15
  /**
15
16
  * @public
16
17
  */
@@ -22,7 +23,7 @@ export declare class List<T> implements Collection.Indexed<T> {
22
23
  private readonly _tail;
23
24
  private readonly _shift;
24
25
  private readonly _size;
25
- private constructor();
26
+ protected constructor(head: Empty | Leaf<T> | Branch<T>, tail: Empty | Leaf<T>, shift: number, size: number);
26
27
  get size(): number;
27
28
  isEmpty(): this is List<never>;
28
29
  forEach(callback: Callback<T, void, [index: number]>): void;
package/dist/node.d.ts CHANGED
@@ -38,7 +38,7 @@ export declare const Empty: Empty;
38
38
  export declare class Leaf<T> implements Node<T> {
39
39
  static of<T>(values: Array<T>): Leaf<T>;
40
40
  private readonly _values;
41
- private constructor();
41
+ protected constructor(values: Array<T>);
42
42
  get values(): Array<T>;
43
43
  isEmpty(): this is Empty;
44
44
  isLeaf(): this is Leaf<T>;
@@ -56,7 +56,7 @@ export declare class Branch<T> implements Node<T> {
56
56
  static of<T>(nodes: Array<Branch<T> | Leaf<T>>): Branch<T>;
57
57
  static empty<T>(): Branch<T>;
58
58
  private readonly _nodes;
59
- private constructor();
59
+ protected constructor(nodes: Array<Branch<T> | Leaf<T>>);
60
60
  get nodes(): Array<Branch<T> | Leaf<T>>;
61
61
  isEmpty(): this is Empty;
62
62
  isLeaf(): this is Leaf<T>;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "http://json.schemastore.org/package",
3
3
  "name": "@siteimprove/alfa-list",
4
4
  "homepage": "https://alfa.siteimprove.com",
5
- "version": "0.97.0",
5
+ "version": "0.98.0",
6
6
  "license": "MIT",
7
7
  "description": "An implementation of an immutable list structure, based on a bit-partitioned vector trie",
8
8
  "repository": {
@@ -22,26 +22,26 @@
22
22
  "dist/**/*.d.ts"
23
23
  ],
24
24
  "dependencies": {
25
- "@siteimprove/alfa-array": "^0.97.0",
26
- "@siteimprove/alfa-bits": "^0.97.0",
27
- "@siteimprove/alfa-callback": "^0.97.0",
28
- "@siteimprove/alfa-collection": "^0.97.0",
29
- "@siteimprove/alfa-comparable": "^0.97.0",
30
- "@siteimprove/alfa-equatable": "^0.97.0",
31
- "@siteimprove/alfa-functor": "^0.97.0",
32
- "@siteimprove/alfa-hash": "^0.97.0",
33
- "@siteimprove/alfa-iterable": "^0.97.0",
34
- "@siteimprove/alfa-json": "^0.97.0",
35
- "@siteimprove/alfa-map": "^0.97.0",
36
- "@siteimprove/alfa-mapper": "^0.97.0",
37
- "@siteimprove/alfa-option": "^0.97.0",
38
- "@siteimprove/alfa-predicate": "^0.97.0",
39
- "@siteimprove/alfa-reducer": "^0.97.0",
40
- "@siteimprove/alfa-refinement": "^0.97.0",
41
- "@siteimprove/alfa-set": "^0.97.0"
25
+ "@siteimprove/alfa-array": "^0.98.0",
26
+ "@siteimprove/alfa-bits": "^0.98.0",
27
+ "@siteimprove/alfa-callback": "^0.98.0",
28
+ "@siteimprove/alfa-collection": "^0.98.0",
29
+ "@siteimprove/alfa-comparable": "^0.98.0",
30
+ "@siteimprove/alfa-equatable": "^0.98.0",
31
+ "@siteimprove/alfa-functor": "^0.98.0",
32
+ "@siteimprove/alfa-hash": "^0.98.0",
33
+ "@siteimprove/alfa-iterable": "^0.98.0",
34
+ "@siteimprove/alfa-json": "^0.98.0",
35
+ "@siteimprove/alfa-map": "^0.98.0",
36
+ "@siteimprove/alfa-mapper": "^0.98.0",
37
+ "@siteimprove/alfa-option": "^0.98.0",
38
+ "@siteimprove/alfa-predicate": "^0.98.0",
39
+ "@siteimprove/alfa-reducer": "^0.98.0",
40
+ "@siteimprove/alfa-refinement": "^0.98.0",
41
+ "@siteimprove/alfa-set": "^0.98.0"
42
42
  },
43
43
  "devDependencies": {
44
- "@siteimprove/alfa-test": "^0.97.0"
44
+ "@siteimprove/alfa-test": "^0.98.0"
45
45
  },
46
46
  "publishConfig": {
47
47
  "access": "public",