@form-observer/vue 0.8.0 → 0.9.1

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.
@@ -7,17 +7,17 @@ module.exports.default = createFormValidityObserver;
7
7
  /**
8
8
  * Creates an enhanced version of the {@link FormValidityObserver} that's more convenient for `Vue` apps
9
9
  *
10
- * @template {import("./index.d.cts").OneOrMany<import("./index.d.cts").EventType>} T
10
+ * @template {import("./index.d.cts").EventType | null} T
11
11
  * @template [M=string]
12
12
  * @template {import("./index.d.cts").ValidatableField} [E=import("./index.d.cts").ValidatableField]
13
13
  * @template {boolean} [R=false]
14
- * @param {T} types
14
+ * @param {T} type
15
15
  * @param {import("./index.d.cts").FormValidityObserverOptions<M, E, R>} [options]
16
16
  * @returns {import("./types.d.cts").VueFormValidityObserver<M, R>}
17
17
  */
18
- function createFormValidityObserver(types, options) {
18
+ function createFormValidityObserver(type, options) {
19
19
  const observer = /** @type {import("./types.d.cts").VueFormValidityObserver<M, R>} */ (
20
- /** @type {unknown} */ (new FormValidityObserver(types, options))
20
+ /** @type {unknown} */ (new FormValidityObserver(type, options))
21
21
  );
22
22
 
23
23
  /* -------------------- Bindings -------------------- */
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * Creates an enhanced version of the {@link FormValidityObserver} that's more convenient for `Vue` apps
3
3
  *
4
- * @template {import("./index.d.cts").OneOrMany<import("./index.d.cts").EventType>} T
4
+ * @template {import("./index.d.cts").EventType | null} T
5
5
  * @template [M=string]
6
6
  * @template {import("./index.d.cts").ValidatableField} [E=import("./index.d.cts").ValidatableField]
7
7
  * @template {boolean} [R=false]
8
- * @param {T} types
8
+ * @param {T} type
9
9
  * @param {import("./index.d.cts").FormValidityObserverOptions<M, E, R>} [options]
10
10
  * @returns {import("./types.d.cts").VueFormValidityObserver<M, R>}
11
11
  */
12
- export default function createFormValidityObserver<T extends import("@form-observer/core/types").OneOrMany<keyof DocumentEventMap>, M = string, E extends import("@form-observer/core/types").ValidatableField = import("@form-observer/core/types").ValidatableField, R extends boolean = false>(types: T, options?: import("@form-observer/core/FormValidityObserver").FormValidityObserverOptions<M, E, R> | undefined): import("./types.d.cts").VueFormValidityObserver<M, R>;
12
+ export default function createFormValidityObserver<T extends keyof DocumentEventMap | null, M = string, E extends import("@form-observer/core/types").ValidatableField = import("@form-observer/core/types").ValidatableField, R extends boolean = false>(type: T, options?: import("@form-observer/core/FormValidityObserver").FormValidityObserverOptions<M, E, R> | undefined): import("./types.d.cts").VueFormValidityObserver<M, R>;
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * Creates an enhanced version of the {@link FormValidityObserver} that's more convenient for `Vue` apps
3
3
  *
4
- * @template {import("./index.d.ts").OneOrMany<import("./index.d.ts").EventType>} T
4
+ * @template {import("./index.d.ts").EventType | null} T
5
5
  * @template [M=string]
6
6
  * @template {import("./index.d.ts").ValidatableField} [E=import("./index.d.ts").ValidatableField]
7
7
  * @template {boolean} [R=false]
8
- * @param {T} types
8
+ * @param {T} type
9
9
  * @param {import("./index.d.ts").FormValidityObserverOptions<M, E, R>} [options]
10
10
  * @returns {import("./types.d.ts").VueFormValidityObserver<M, R>}
11
11
  */
12
- export default function createFormValidityObserver<T extends import("@form-observer/core/types").OneOrMany<keyof DocumentEventMap>, M = string, E extends import("@form-observer/core/types").ValidatableField = import("@form-observer/core/types").ValidatableField, R extends boolean = false>(types: T, options?: import("@form-observer/core/FormValidityObserver").FormValidityObserverOptions<M, E, R> | undefined): import("./types.d.ts").VueFormValidityObserver<M, R>;
12
+ export default function createFormValidityObserver<T extends keyof DocumentEventMap | null, M = string, E extends import("@form-observer/core/types").ValidatableField = import("@form-observer/core/types").ValidatableField, R extends boolean = false>(type: T, options?: import("@form-observer/core/FormValidityObserver").FormValidityObserverOptions<M, E, R> | undefined): import("./types.d.ts").VueFormValidityObserver<M, R>;
@@ -3,17 +3,17 @@ import FormValidityObserver from "@form-observer/core/FormValidityObserver";
3
3
  /**
4
4
  * Creates an enhanced version of the {@link FormValidityObserver} that's more convenient for `Vue` apps
5
5
  *
6
- * @template {import("./index.d.ts").OneOrMany<import("./index.d.ts").EventType>} T
6
+ * @template {import("./index.d.ts").EventType | null} T
7
7
  * @template [M=string]
8
8
  * @template {import("./index.d.ts").ValidatableField} [E=import("./index.d.ts").ValidatableField]
9
9
  * @template {boolean} [R=false]
10
- * @param {T} types
10
+ * @param {T} type
11
11
  * @param {import("./index.d.ts").FormValidityObserverOptions<M, E, R>} [options]
12
12
  * @returns {import("./types.d.ts").VueFormValidityObserver<M, R>}
13
13
  */
14
- export default function createFormValidityObserver(types, options) {
14
+ export default function createFormValidityObserver(type, options) {
15
15
  const observer = /** @type {import("./types.d.ts").VueFormValidityObserver<M, R>} */ (
16
- /** @type {unknown} */ (new FormValidityObserver(types, options))
16
+ /** @type {unknown} */ (new FormValidityObserver(type, options))
17
17
  );
18
18
 
19
19
  /* -------------------- Bindings -------------------- */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@form-observer/vue",
3
3
  "type": "module",
4
- "version": "0.8.0",
4
+ "version": "0.9.1",
5
5
  "sideEffects": false,
6
6
  "description": "Convenience functions for the `@form-observer/core` package, designed for Vue apps",
7
7
  "exports": {
@@ -29,7 +29,7 @@
29
29
  }
30
30
  },
31
31
  "peerDependencies": {
32
- "@form-observer/core": "^0.8.0"
32
+ "@form-observer/core": "^0.9.1"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@testing-library/vue": "^8.0.3",