@crowbartools/firebot-types 5.67.0-alpha6 → 5.67.0-alpha8
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/package.json
CHANGED
package/types/plugins.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
1
2
|
import { EffectInstance, EffectList, EffectType } from "./effects";
|
|
2
3
|
import { Trigger } from "./triggers";
|
|
3
4
|
import { Awaitable } from "./util-types";
|
|
@@ -121,13 +122,13 @@ export interface Plugin<Params extends FirebotParams = FirebotParams> extends Sc
|
|
|
121
122
|
|
|
122
123
|
// If value within array is a function, call said function to get definition
|
|
123
124
|
// If definition is or evaluates to promise, await promise
|
|
124
|
-
effects?: DynamicArray<EffectType
|
|
125
|
+
effects?: DynamicArray<EffectType<any, any>>;
|
|
125
126
|
eventSources?: DynamicArray<EventSource>;
|
|
126
127
|
variables?: DynamicArray<ReplaceVariable>;
|
|
127
|
-
integrations?: DynamicArray<Integration
|
|
128
|
+
integrations?: DynamicArray<Integration<any>>;
|
|
128
129
|
filters?: DynamicArray<EventFilter>;
|
|
129
|
-
restrictions?: DynamicArray<RestrictionType
|
|
130
|
-
systemCommands?: DynamicArray<SystemCommand
|
|
130
|
+
restrictions?: DynamicArray<RestrictionType<any>>;
|
|
131
|
+
systemCommands?: DynamicArray<SystemCommand<any>>;
|
|
131
132
|
games?: DynamicArray<FirebotGame>;
|
|
132
133
|
uiExtensions?: DynamicArray<UIExtension>;
|
|
133
134
|
};
|
|
@@ -154,7 +155,7 @@ export type InstalledPlugin = {
|
|
|
154
155
|
type LegacyScriptParameters = Record<
|
|
155
156
|
string,
|
|
156
157
|
{
|
|
157
|
-
|
|
158
|
+
|
|
158
159
|
type: any;
|
|
159
160
|
title?: string;
|
|
160
161
|
description?: string;
|
package/types/script-api.d.ts
CHANGED
|
@@ -121,6 +121,14 @@ export interface ScriptTwitchApi {
|
|
|
121
121
|
api: typeof TwitchApi;
|
|
122
122
|
}
|
|
123
123
|
|
|
124
|
+
/**
|
|
125
|
+
* Access to this plugin's saved parameter values (the settings configured by
|
|
126
|
+
* the user)
|
|
127
|
+
*/
|
|
128
|
+
export interface ScriptParametersApi {
|
|
129
|
+
getAll<T extends Record<string, unknown> = Record<string, unknown>>(): T;
|
|
130
|
+
}
|
|
131
|
+
|
|
124
132
|
export interface ScriptFrontendCommunicatorApi {
|
|
125
133
|
/** Send a synchronous event to the frontend. */
|
|
126
134
|
send<ExpectedArg = unknown>(eventName: string, data?: ExpectedArg): void;
|
|
@@ -168,6 +176,8 @@ export interface FirebotScriptApi {
|
|
|
168
176
|
effects: ScriptEffectsApi;
|
|
169
177
|
/** Access to Firebot's Twitch API wrappers (Helix, chat, auth, etc). */
|
|
170
178
|
twitch: ScriptTwitchApi;
|
|
179
|
+
/** This plugin's saved parameter values. */
|
|
180
|
+
parameters: ScriptParametersApi;
|
|
171
181
|
/** Two-way messaging between the script and the frontend. */
|
|
172
182
|
frontendCommunicator: ScriptFrontendCommunicatorApi;
|
|
173
183
|
}
|