@companion-surface/base 0.5.0 → 0.6.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,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.6.0](https://github.com/bitfocus/companion-surface-api/compare/companion-surface-base-v0.5.0...companion-surface-base-v0.6.0) (2025-11-23)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* add allowMultipleInstances field to manifest ([94bba80](https://github.com/bitfocus/companion-surface-api/commit/94bba800143308a1b8fd6ed1d56249b8fc8a432b))
|
|
9
|
+
|
|
3
10
|
## [0.5.0](https://github.com/bitfocus/companion-surface-api/compare/companion-surface-base-v0.4.2...companion-surface-base-v0.5.0) (2025-11-16)
|
|
4
11
|
|
|
5
12
|
|
|
@@ -130,6 +130,10 @@
|
|
|
130
130
|
"required": ["vendorId", "productIds"],
|
|
131
131
|
"additionalProperties": false
|
|
132
132
|
}
|
|
133
|
+
},
|
|
134
|
+
"allowMultipleInstances": {
|
|
135
|
+
"type": "boolean",
|
|
136
|
+
"description": "Whether multiple instances of this module can be run simultaneously"
|
|
133
137
|
}
|
|
134
138
|
},
|
|
135
139
|
"required": [
|
package/generated/manifest.d.ts
CHANGED
|
@@ -58,6 +58,10 @@ export interface SurfaceModuleManifest {
|
|
|
58
58
|
* List of USB vendor and product IDs that the module supports. Your module will only be notified of devices matching these IDs.
|
|
59
59
|
*/
|
|
60
60
|
usbIds: SurfaceModuleManifestUsbIds[];
|
|
61
|
+
/**
|
|
62
|
+
* Whether multiple instances of this module can be run simultaneously
|
|
63
|
+
*/
|
|
64
|
+
allowMultipleInstances?: boolean;
|
|
61
65
|
}
|
|
62
66
|
export interface SurfaceModuleManifestMaintainer {
|
|
63
67
|
name: string;
|
|
@@ -52,7 +52,7 @@ var require_equal = __commonJS({
|
|
|
52
52
|
// generated/validate_manifest.js
|
|
53
53
|
var validate = validate20;
|
|
54
54
|
var validate_manifest_default = validate20;
|
|
55
|
-
var schema31 = { "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "title": "SurfaceModuleManifest", "properties": { "$schema": { "type": "string" }, "type": { "type": "string", "enum": ["surface"], "description": "Type of module. Must be: surface" }, "id": { "type": "string", "description": "Unique identifier for the module" }, "name": { "type": "string", "description": "Name of the module" }, "shortname": { "type": "string" }, "description": { "type": "string", "description": "Description of the module " }, "version": { "type": "string", "description": "Current version of the module" }, "isPrerelease": { "type": "boolean", "description": "Is this a pre-release version" }, "license": { "type": "string", "description": "SPDX identifier for license of the module" }, "repository": { "type": "string", "description": "URL to the source repository" }, "bugs": { "type": "string", "description": "URL to bug tracker" }, "maintainers": { "type": "array", "description": "List of active maintiners", "uniqueItems": true, "items": { "type": "object", "title": "SurfaceModuleManifestMaintainer", "properties": { "name": { "type": "string" }, "email": { "type": "string" }, "github": { "type": "string" }, "url": { "type": "string" } }, "required": ["name"], "additionalProperties": false } }, "runtime": { "type": "object", "title": "SurfaceModuleManifestRuntime", "description": "Information on how to execute the module", "properties": { "type": { "type": "string", "description": "Type of the module. Must be: node18 or node22", "enum": ["node22"] }, "apiVersion": { "type": "string", "description": "The version of the host-api used" }, "entrypoint": { "type": "string", "description": "Entrypoint to pass to the runtime. eg index.js" } }, "required": ["type", "apiVersion", "entrypoint"] }, "products": { "type": "array", "uniqueItems": true, "items": { "type": "string" }, "minItems": 1 }, "keywords": { "type": "array", "uniqueItems": true, "items": { "type": "string" } }, "usbIds": { "type": "array", "description": "List of USB vendor and product IDs that the module supports. Your module will only be notified of devices matching these IDs.", "uniqueItems": true, "items": { "type": "object", "title": "SurfaceModuleManifestUsbIds", "properties": { "vendorId": { "type": "integer" }, "productIds": { "type": "array", "uniqueItems": true, "items": { "type": "integer" }, "minItems": 1 } }, "required": ["vendorId", "productIds"], "additionalProperties": false } } }, "required": ["type", "id", "name", "shortname", "description", "version", "license", "repository", "bugs", "maintainers", "runtime", "products", "keywords", "usbIds"] };
|
|
55
|
+
var schema31 = { "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "title": "SurfaceModuleManifest", "properties": { "$schema": { "type": "string" }, "type": { "type": "string", "enum": ["surface"], "description": "Type of module. Must be: surface" }, "id": { "type": "string", "description": "Unique identifier for the module" }, "name": { "type": "string", "description": "Name of the module" }, "shortname": { "type": "string" }, "description": { "type": "string", "description": "Description of the module " }, "version": { "type": "string", "description": "Current version of the module" }, "isPrerelease": { "type": "boolean", "description": "Is this a pre-release version" }, "license": { "type": "string", "description": "SPDX identifier for license of the module" }, "repository": { "type": "string", "description": "URL to the source repository" }, "bugs": { "type": "string", "description": "URL to bug tracker" }, "maintainers": { "type": "array", "description": "List of active maintiners", "uniqueItems": true, "items": { "type": "object", "title": "SurfaceModuleManifestMaintainer", "properties": { "name": { "type": "string" }, "email": { "type": "string" }, "github": { "type": "string" }, "url": { "type": "string" } }, "required": ["name"], "additionalProperties": false } }, "runtime": { "type": "object", "title": "SurfaceModuleManifestRuntime", "description": "Information on how to execute the module", "properties": { "type": { "type": "string", "description": "Type of the module. Must be: node18 or node22", "enum": ["node22"] }, "apiVersion": { "type": "string", "description": "The version of the host-api used" }, "entrypoint": { "type": "string", "description": "Entrypoint to pass to the runtime. eg index.js" } }, "required": ["type", "apiVersion", "entrypoint"] }, "products": { "type": "array", "uniqueItems": true, "items": { "type": "string" }, "minItems": 1 }, "keywords": { "type": "array", "uniqueItems": true, "items": { "type": "string" } }, "usbIds": { "type": "array", "description": "List of USB vendor and product IDs that the module supports. Your module will only be notified of devices matching these IDs.", "uniqueItems": true, "items": { "type": "object", "title": "SurfaceModuleManifestUsbIds", "properties": { "vendorId": { "type": "integer" }, "productIds": { "type": "array", "uniqueItems": true, "items": { "type": "integer" }, "minItems": 1 } }, "required": ["vendorId", "productIds"], "additionalProperties": false } }, "allowMultipleInstances": { "type": "boolean", "description": "Whether multiple instances of this module can be run simultaneously" } }, "required": ["type", "id", "name", "shortname", "description", "version", "license", "repository", "bugs", "maintainers", "runtime", "products", "keywords", "usbIds"] };
|
|
56
56
|
var func0 = require_equal().default;
|
|
57
57
|
function validate20(data, { instancePath = "", parentData, parentDataProperty, rootData = data, dynamicAnchors = {} } = {}) {
|
|
58
58
|
let vErrors = null;
|
|
@@ -595,6 +595,18 @@ function validate20(data, { instancePath = "", parentData, parentDataProperty, r
|
|
|
595
595
|
} else {
|
|
596
596
|
var valid0 = true;
|
|
597
597
|
}
|
|
598
|
+
if (valid0) {
|
|
599
|
+
if (data.allowMultipleInstances !== void 0) {
|
|
600
|
+
const _errs63 = errors;
|
|
601
|
+
if (typeof data.allowMultipleInstances !== "boolean") {
|
|
602
|
+
validate20.errors = [{ instancePath: instancePath + "/allowMultipleInstances", schemaPath: "#/properties/allowMultipleInstances/type", keyword: "type", params: { type: "boolean" }, message: "must be boolean" }];
|
|
603
|
+
return false;
|
|
604
|
+
}
|
|
605
|
+
var valid0 = _errs63 === errors;
|
|
606
|
+
} else {
|
|
607
|
+
var valid0 = true;
|
|
608
|
+
}
|
|
609
|
+
}
|
|
598
610
|
}
|
|
599
611
|
}
|
|
600
612
|
}
|
|
@@ -619,7 +631,7 @@ function validate20(data, { instancePath = "", parentData, parentDataProperty, r
|
|
|
619
631
|
validate20.errors = vErrors;
|
|
620
632
|
return errors === 0;
|
|
621
633
|
}
|
|
622
|
-
validate20.evaluated = { "props": { "$schema": true, "type": true, "id": true, "name": true, "shortname": true, "description": true, "version": true, "isPrerelease": true, "license": true, "repository": true, "bugs": true, "maintainers": true, "runtime": true, "products": true, "keywords": true, "usbIds": true }, "dynamicProps": false, "dynamicItems": false };
|
|
634
|
+
validate20.evaluated = { "props": { "$schema": true, "type": true, "id": true, "name": true, "shortname": true, "description": true, "version": true, "isPrerelease": true, "license": true, "repository": true, "bugs": true, "maintainers": true, "runtime": true, "products": true, "keywords": true, "usbIds": true, "allowMultipleInstances": true }, "dynamicProps": false, "dynamicItems": false };
|
|
623
635
|
export {
|
|
624
636
|
validate_manifest_default as default,
|
|
625
637
|
validate
|