@lumiastream/lumia-types 3.5.5 → 3.5.7

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.
@@ -1275,6 +1275,64 @@ export declare enum SystemVariables {
1275
1275
  MONTH_TOP_DONATOR_LIST = "month_top_donator_list",
1276
1276
  /** Amounts for MONTH_TOP_DONATOR_LIST. Use as {{month_top_donator_list_amount}}. */
1277
1277
  MONTH_TOP_DONATOR_LIST_AMOUNT = "month_top_donator_list_amount",
1278
+ /** Followers this session across all platforms. Use as {{session_follower_count}}. */
1279
+ SESSION_FOLLOWER_COUNT = "session_follower_count",
1280
+ /** Followers this week across all platforms. Use as {{week_follower_count}}. */
1281
+ WEEK_FOLLOWER_COUNT = "week_follower_count",
1282
+ /** Followers this month across all platforms. Use as {{month_follower_count}}. */
1283
+ MONTH_FOLLOWER_COUNT = "month_follower_count",
1284
+ /** Lifetime followers across all platforms. Use as {{total_follower_count}}. */
1285
+ TOTAL_FOLLOWER_COUNT = "total_follower_count",
1286
+ /** Most recent follower (any platform). Use as {{last_follower}}. */
1287
+ LAST_FOLLOWER = "last_follower",
1288
+ /** Subscribers this session across all platforms (new + resub + gifted). Use as {{session_subscriber_count}}. */
1289
+ SESSION_SUBSCRIBER_COUNT = "session_subscriber_count",
1290
+ /** New (first-time) subscribers this session. Use as {{session_new_subscribers_count}}. */
1291
+ SESSION_NEW_SUBSCRIBERS_COUNT = "session_new_subscribers_count",
1292
+ /** Resubscribers this session. Use as {{session_resub_subscribers_count}}. */
1293
+ SESSION_RESUB_SUBSCRIBERS_COUNT = "session_resub_subscribers_count",
1294
+ /** Gifted subs this session. Use as {{session_gifted_subscribers_count}}. */
1295
+ SESSION_GIFTED_SUBSCRIBERS_COUNT = "session_gifted_subscribers_count",
1296
+ /** Subscribers this week across all platforms. Use as {{week_subscriber_count}}. */
1297
+ WEEK_SUBSCRIBER_COUNT = "week_subscriber_count",
1298
+ /** Subscribers this month across all platforms. Use as {{month_subscriber_count}}. */
1299
+ MONTH_SUBSCRIBER_COUNT = "month_subscriber_count",
1300
+ /** Lifetime subscribers across all platforms. Use as {{total_subscriber_count}}. */
1301
+ TOTAL_SUBSCRIBER_COUNT = "total_subscriber_count",
1302
+ /** Most recent subscriber (any platform). Use as {{last_subscriber}}. */
1303
+ LAST_SUBSCRIBER = "last_subscriber",
1304
+ /** All-time top gifter (any platform). Use as {{alltime_top_gifter}}. */
1305
+ ALLTIME_TOP_GIFTER = "alltime_top_gifter",
1306
+ /** Bits/cheers count this session. Use as {{session_bits_count}}. */
1307
+ SESSION_BITS_COUNT = "session_bits_count",
1308
+ /** Bits/cheers count this week. Use as {{week_bits_count}}. */
1309
+ WEEK_BITS_COUNT = "week_bits_count",
1310
+ /** Bits/cheers count this month. Use as {{month_bits_count}}. */
1311
+ MONTH_BITS_COUNT = "month_bits_count",
1312
+ /** Top cheerer (by total bits) this session. Use as {{session_top_cheerer}}. */
1313
+ SESSION_TOP_CHEERER = "session_top_cheerer",
1314
+ /** Amount for SESSION_TOP_CHEERER. Use as {{session_top_cheerer_amount}}. */
1315
+ SESSION_TOP_CHEERER_AMOUNT = "session_top_cheerer_amount",
1316
+ /** Top cheerer this week. Use as {{week_top_cheerer}}. */
1317
+ WEEK_TOP_CHEERER = "week_top_cheerer",
1318
+ /** Amount for WEEK_TOP_CHEERER. Use as {{week_top_cheerer_amount}}. */
1319
+ WEEK_TOP_CHEERER_AMOUNT = "week_top_cheerer_amount",
1320
+ /** Top cheerer this month. Use as {{month_top_cheerer}}. */
1321
+ MONTH_TOP_CHEERER = "month_top_cheerer",
1322
+ /** Amount for MONTH_TOP_CHEERER. Use as {{month_top_cheerer_amount}}. */
1323
+ MONTH_TOP_CHEERER_AMOUNT = "month_top_cheerer_amount",
1324
+ /** All-time top cheerer. Use as {{alltime_top_cheerer}}. */
1325
+ ALLTIME_TOP_CHEERER = "alltime_top_cheerer",
1326
+ /** Amount for ALLTIME_TOP_CHEERER. Use as {{alltime_top_cheerer_amount}}. */
1327
+ ALLTIME_TOP_CHEERER_AMOUNT = "alltime_top_cheerer_amount",
1328
+ /** Largest single cheer this session. Use as {{session_top_cheer}}. */
1329
+ SESSION_TOP_CHEER = "session_top_cheer",
1330
+ /** Amount for SESSION_TOP_CHEER. Use as {{session_top_cheer_amount}}. */
1331
+ SESSION_TOP_CHEER_AMOUNT = "session_top_cheer_amount",
1332
+ /** Most recent raider/host (any platform). Use as {{last_raider}}. */
1333
+ LAST_RAIDER = "last_raider",
1334
+ /** Viewer count for LAST_RAIDER. Use as {{last_raid_amount}}. */
1335
+ LAST_RAID_AMOUNT = "last_raid_amount",
1278
1336
  /** Raffle title. Use as {{raffle_title}}. */
1279
1337
  RAFFLE_TITLE = "raffle_title",
1280
1338
  /** Raffle description. Use as {{raffle_description}}. */
@@ -1275,6 +1275,64 @@ export declare enum SystemVariables {
1275
1275
  MONTH_TOP_DONATOR_LIST = "month_top_donator_list",
1276
1276
  /** Amounts for MONTH_TOP_DONATOR_LIST. Use as {{month_top_donator_list_amount}}. */
1277
1277
  MONTH_TOP_DONATOR_LIST_AMOUNT = "month_top_donator_list_amount",
1278
+ /** Followers this session across all platforms. Use as {{session_follower_count}}. */
1279
+ SESSION_FOLLOWER_COUNT = "session_follower_count",
1280
+ /** Followers this week across all platforms. Use as {{week_follower_count}}. */
1281
+ WEEK_FOLLOWER_COUNT = "week_follower_count",
1282
+ /** Followers this month across all platforms. Use as {{month_follower_count}}. */
1283
+ MONTH_FOLLOWER_COUNT = "month_follower_count",
1284
+ /** Lifetime followers across all platforms. Use as {{total_follower_count}}. */
1285
+ TOTAL_FOLLOWER_COUNT = "total_follower_count",
1286
+ /** Most recent follower (any platform). Use as {{last_follower}}. */
1287
+ LAST_FOLLOWER = "last_follower",
1288
+ /** Subscribers this session across all platforms (new + resub + gifted). Use as {{session_subscriber_count}}. */
1289
+ SESSION_SUBSCRIBER_COUNT = "session_subscriber_count",
1290
+ /** New (first-time) subscribers this session. Use as {{session_new_subscribers_count}}. */
1291
+ SESSION_NEW_SUBSCRIBERS_COUNT = "session_new_subscribers_count",
1292
+ /** Resubscribers this session. Use as {{session_resub_subscribers_count}}. */
1293
+ SESSION_RESUB_SUBSCRIBERS_COUNT = "session_resub_subscribers_count",
1294
+ /** Gifted subs this session. Use as {{session_gifted_subscribers_count}}. */
1295
+ SESSION_GIFTED_SUBSCRIBERS_COUNT = "session_gifted_subscribers_count",
1296
+ /** Subscribers this week across all platforms. Use as {{week_subscriber_count}}. */
1297
+ WEEK_SUBSCRIBER_COUNT = "week_subscriber_count",
1298
+ /** Subscribers this month across all platforms. Use as {{month_subscriber_count}}. */
1299
+ MONTH_SUBSCRIBER_COUNT = "month_subscriber_count",
1300
+ /** Lifetime subscribers across all platforms. Use as {{total_subscriber_count}}. */
1301
+ TOTAL_SUBSCRIBER_COUNT = "total_subscriber_count",
1302
+ /** Most recent subscriber (any platform). Use as {{last_subscriber}}. */
1303
+ LAST_SUBSCRIBER = "last_subscriber",
1304
+ /** All-time top gifter (any platform). Use as {{alltime_top_gifter}}. */
1305
+ ALLTIME_TOP_GIFTER = "alltime_top_gifter",
1306
+ /** Bits/cheers count this session. Use as {{session_bits_count}}. */
1307
+ SESSION_BITS_COUNT = "session_bits_count",
1308
+ /** Bits/cheers count this week. Use as {{week_bits_count}}. */
1309
+ WEEK_BITS_COUNT = "week_bits_count",
1310
+ /** Bits/cheers count this month. Use as {{month_bits_count}}. */
1311
+ MONTH_BITS_COUNT = "month_bits_count",
1312
+ /** Top cheerer (by total bits) this session. Use as {{session_top_cheerer}}. */
1313
+ SESSION_TOP_CHEERER = "session_top_cheerer",
1314
+ /** Amount for SESSION_TOP_CHEERER. Use as {{session_top_cheerer_amount}}. */
1315
+ SESSION_TOP_CHEERER_AMOUNT = "session_top_cheerer_amount",
1316
+ /** Top cheerer this week. Use as {{week_top_cheerer}}. */
1317
+ WEEK_TOP_CHEERER = "week_top_cheerer",
1318
+ /** Amount for WEEK_TOP_CHEERER. Use as {{week_top_cheerer_amount}}. */
1319
+ WEEK_TOP_CHEERER_AMOUNT = "week_top_cheerer_amount",
1320
+ /** Top cheerer this month. Use as {{month_top_cheerer}}. */
1321
+ MONTH_TOP_CHEERER = "month_top_cheerer",
1322
+ /** Amount for MONTH_TOP_CHEERER. Use as {{month_top_cheerer_amount}}. */
1323
+ MONTH_TOP_CHEERER_AMOUNT = "month_top_cheerer_amount",
1324
+ /** All-time top cheerer. Use as {{alltime_top_cheerer}}. */
1325
+ ALLTIME_TOP_CHEERER = "alltime_top_cheerer",
1326
+ /** Amount for ALLTIME_TOP_CHEERER. Use as {{alltime_top_cheerer_amount}}. */
1327
+ ALLTIME_TOP_CHEERER_AMOUNT = "alltime_top_cheerer_amount",
1328
+ /** Largest single cheer this session. Use as {{session_top_cheer}}. */
1329
+ SESSION_TOP_CHEER = "session_top_cheer",
1330
+ /** Amount for SESSION_TOP_CHEER. Use as {{session_top_cheer_amount}}. */
1331
+ SESSION_TOP_CHEER_AMOUNT = "session_top_cheer_amount",
1332
+ /** Most recent raider/host (any platform). Use as {{last_raider}}. */
1333
+ LAST_RAIDER = "last_raider",
1334
+ /** Viewer count for LAST_RAIDER. Use as {{last_raid_amount}}. */
1335
+ LAST_RAID_AMOUNT = "last_raid_amount",
1278
1336
  /** Raffle title. Use as {{raffle_title}}. */
1279
1337
  RAFFLE_TITLE = "raffle_title",
1280
1338
  /** Raffle description. Use as {{raffle_description}}. */
@@ -6,3 +6,4 @@ export interface InputFieldLike {
6
6
  }
7
7
  export declare function isRedundantInputField(inputField: InputFieldLike, allInputFields: ReadonlyArray<InputFieldLike> | undefined): boolean;
8
8
  export declare function syncLinkedVariableFields(values: Record<string, any>): void;
9
+ export declare function coerceNumericAlertFields(values: Record<string, any>): void;
@@ -5,6 +5,7 @@ exports.getExampleAlertVariableValue = getExampleAlertVariableValue;
5
5
  exports.buildExampleAlertVariables = buildExampleAlertVariables;
6
6
  exports.isRedundantInputField = isRedundantInputField;
7
7
  exports.syncLinkedVariableFields = syncLinkedVariableFields;
8
+ exports.coerceNumericAlertFields = coerceNumericAlertFields;
8
9
  exports.EMULATE_EXAMPLE_AVATAR_URL = 'https://static-cdn.jtvnw.net/jtv_user_pictures/2b1fa336-f9b2-42cf-bd2c-98675da74982-profile_image-300x300.png';
9
10
  function getExampleAlertVariableValue(variableName) {
10
11
  const lowered = variableName.toLowerCase();
@@ -122,3 +123,56 @@ function syncLinkedVariableFields(values) {
122
123
  }
123
124
  }
124
125
  }
126
+ // Canonical wire-type-aligned numeric field set. Each name corresponds to a
127
+ // dynamic/extraSettings field that real platform managers (twitch, kick,
128
+ // streamlabs, …) emit as a Number — see wire.types.ts. Emulation form inputs
129
+ // hand back numeric strings ("1"), which silently break downstream consumers
130
+ // that do arithmetic (SE compat shim's resolvedAmount, goal/cheer widgets,
131
+ // plugin SDK reducers). Run this before dispatch to match the live shape.
132
+ //
133
+ // `value` is intentionally NOT in this set — wire.types.ts uses `value: string`
134
+ // for most alerts (templated display string) and `value: number` only for a
135
+ // handful (bits, raid, kicks, hypetrain, ads). Coerce `value` at the form
136
+ // binding using inputField.type === 'number' instead, so the per-alert
137
+ // contract isn't violated.
138
+ const NUMERIC_ALERT_FIELDS = new Set([
139
+ 'amount',
140
+ 'giftAmount',
141
+ 'totalGifts',
142
+ 'subMonths',
143
+ 'streakMonths',
144
+ 'cumulativeMonths',
145
+ 'streak',
146
+ 'months',
147
+ 'bits',
148
+ 'kicks',
149
+ 'viewers',
150
+ 'total',
151
+ 'previousTotal',
152
+ 'current_amount',
153
+ 'target_amount',
154
+ 'length',
155
+ 'streak_count',
156
+ 'channel_points_awarded',
157
+ 'reward_cost',
158
+ 'view_count',
159
+ 'clip_duration',
160
+ 'timeout_duration',
161
+ 'expiration_ms',
162
+ 'poll_duration',
163
+ 'level',
164
+ 'progress',
165
+ 'goal',
166
+ ]);
167
+ function coerceNumericAlertFields(values) {
168
+ if (!values)
169
+ return;
170
+ for (const key of Object.keys(values)) {
171
+ if (!NUMERIC_ALERT_FIELDS.has(key))
172
+ continue;
173
+ const v = values[key];
174
+ if (typeof v === 'string' && v !== '' && !isNaN(Number(v))) {
175
+ values[key] = Number(v);
176
+ }
177
+ }
178
+ }
@@ -115,3 +115,56 @@ export function syncLinkedVariableFields(values) {
115
115
  }
116
116
  }
117
117
  }
118
+ // Canonical wire-type-aligned numeric field set. Each name corresponds to a
119
+ // dynamic/extraSettings field that real platform managers (twitch, kick,
120
+ // streamlabs, …) emit as a Number — see wire.types.ts. Emulation form inputs
121
+ // hand back numeric strings ("1"), which silently break downstream consumers
122
+ // that do arithmetic (SE compat shim's resolvedAmount, goal/cheer widgets,
123
+ // plugin SDK reducers). Run this before dispatch to match the live shape.
124
+ //
125
+ // `value` is intentionally NOT in this set — wire.types.ts uses `value: string`
126
+ // for most alerts (templated display string) and `value: number` only for a
127
+ // handful (bits, raid, kicks, hypetrain, ads). Coerce `value` at the form
128
+ // binding using inputField.type === 'number' instead, so the per-alert
129
+ // contract isn't violated.
130
+ const NUMERIC_ALERT_FIELDS = new Set([
131
+ 'amount',
132
+ 'giftAmount',
133
+ 'totalGifts',
134
+ 'subMonths',
135
+ 'streakMonths',
136
+ 'cumulativeMonths',
137
+ 'streak',
138
+ 'months',
139
+ 'bits',
140
+ 'kicks',
141
+ 'viewers',
142
+ 'total',
143
+ 'previousTotal',
144
+ 'current_amount',
145
+ 'target_amount',
146
+ 'length',
147
+ 'streak_count',
148
+ 'channel_points_awarded',
149
+ 'reward_cost',
150
+ 'view_count',
151
+ 'clip_duration',
152
+ 'timeout_duration',
153
+ 'expiration_ms',
154
+ 'poll_duration',
155
+ 'level',
156
+ 'progress',
157
+ 'goal',
158
+ ]);
159
+ export function coerceNumericAlertFields(values) {
160
+ if (!values)
161
+ return;
162
+ for (const key of Object.keys(values)) {
163
+ if (!NUMERIC_ALERT_FIELDS.has(key))
164
+ continue;
165
+ const v = values[key];
166
+ if (typeof v === 'string' && v !== '' && !isNaN(Number(v))) {
167
+ values[key] = Number(v);
168
+ }
169
+ }
170
+ }
package/dist/esm/index.js CHANGED
@@ -4,7 +4,7 @@ export { LumiaIntegrations, LumiaEventTypes, } from './event.types.js';
4
4
  export { LumiaEventListTypes, LumiaMapAlertTypeToEventListType, AlertsToFilter, PlatformsToFilter, LumiaEventListTypeColors, getEventListCategoryColor } from './eventlist.types.js';
5
5
  export { SystemVariables, ReservedVariables, AllVariables, getAcceptedVariableName, getAcceptedVariableNames, } from './variables.types.js';
6
6
  export { formatCondition } from './helpers.js';
7
- export { EMULATE_EXAMPLE_AVATAR_URL, getExampleAlertVariableValue, buildExampleAlertVariables, isRedundantInputField, syncLinkedVariableFields, } from './emulate.helpers.js';
7
+ export { EMULATE_EXAMPLE_AVATAR_URL, getExampleAlertVariableValue, buildExampleAlertVariables, coerceNumericAlertFields, isRedundantInputField, syncLinkedVariableFields, } from './emulate.helpers.js';
8
8
  export { KickKicksData } from './kick_kicks.js';
9
9
  export { BLANK_OVERLAY_TEMPLATE_ID } from './overlay_template.types.js';
10
10
  export { TiktokGiftsData } from './tiktok_gifts.js';
@@ -200,6 +200,69 @@ export var SystemVariables;
200
200
  SystemVariables["MONTH_TOP_DONATOR_LIST"] = "month_top_donator_list";
201
201
  /** Amounts for MONTH_TOP_DONATOR_LIST. Use as {{month_top_donator_list_amount}}. */
202
202
  SystemVariables["MONTH_TOP_DONATOR_LIST_AMOUNT"] = "month_top_donator_list_amount";
203
+ // ─── Cross-platform follower / subscriber / cheer / raid (SE-shaped names) ───
204
+ // Mirror StreamElements' session keys without a platform prefix so SE → Lumia
205
+ // is a 1:1 map and labels can reference one counter that aggregates across
206
+ // Twitch, YouTube, Kick, etc. Platform-specific variants (TWITCH_*, KICK_*,
207
+ // YOUTUBE_*) remain available for labels that need a single-platform view.
208
+ /** Followers this session across all platforms. Use as {{session_follower_count}}. */
209
+ SystemVariables["SESSION_FOLLOWER_COUNT"] = "session_follower_count";
210
+ /** Followers this week across all platforms. Use as {{week_follower_count}}. */
211
+ SystemVariables["WEEK_FOLLOWER_COUNT"] = "week_follower_count";
212
+ /** Followers this month across all platforms. Use as {{month_follower_count}}. */
213
+ SystemVariables["MONTH_FOLLOWER_COUNT"] = "month_follower_count";
214
+ /** Lifetime followers across all platforms. Use as {{total_follower_count}}. */
215
+ SystemVariables["TOTAL_FOLLOWER_COUNT"] = "total_follower_count";
216
+ /** Most recent follower (any platform). Use as {{last_follower}}. */
217
+ SystemVariables["LAST_FOLLOWER"] = "last_follower";
218
+ /** Subscribers this session across all platforms (new + resub + gifted). Use as {{session_subscriber_count}}. */
219
+ SystemVariables["SESSION_SUBSCRIBER_COUNT"] = "session_subscriber_count";
220
+ /** New (first-time) subscribers this session. Use as {{session_new_subscribers_count}}. */
221
+ SystemVariables["SESSION_NEW_SUBSCRIBERS_COUNT"] = "session_new_subscribers_count";
222
+ /** Resubscribers this session. Use as {{session_resub_subscribers_count}}. */
223
+ SystemVariables["SESSION_RESUB_SUBSCRIBERS_COUNT"] = "session_resub_subscribers_count";
224
+ /** Gifted subs this session. Use as {{session_gifted_subscribers_count}}. */
225
+ SystemVariables["SESSION_GIFTED_SUBSCRIBERS_COUNT"] = "session_gifted_subscribers_count";
226
+ /** Subscribers this week across all platforms. Use as {{week_subscriber_count}}. */
227
+ SystemVariables["WEEK_SUBSCRIBER_COUNT"] = "week_subscriber_count";
228
+ /** Subscribers this month across all platforms. Use as {{month_subscriber_count}}. */
229
+ SystemVariables["MONTH_SUBSCRIBER_COUNT"] = "month_subscriber_count";
230
+ /** Lifetime subscribers across all platforms. Use as {{total_subscriber_count}}. */
231
+ SystemVariables["TOTAL_SUBSCRIBER_COUNT"] = "total_subscriber_count";
232
+ /** Most recent subscriber (any platform). Use as {{last_subscriber}}. */
233
+ SystemVariables["LAST_SUBSCRIBER"] = "last_subscriber";
234
+ /** All-time top gifter (any platform). Use as {{alltime_top_gifter}}. */
235
+ SystemVariables["ALLTIME_TOP_GIFTER"] = "alltime_top_gifter";
236
+ /** Bits/cheers count this session. Use as {{session_bits_count}}. */
237
+ SystemVariables["SESSION_BITS_COUNT"] = "session_bits_count";
238
+ /** Bits/cheers count this week. Use as {{week_bits_count}}. */
239
+ SystemVariables["WEEK_BITS_COUNT"] = "week_bits_count";
240
+ /** Bits/cheers count this month. Use as {{month_bits_count}}. */
241
+ SystemVariables["MONTH_BITS_COUNT"] = "month_bits_count";
242
+ /** Top cheerer (by total bits) this session. Use as {{session_top_cheerer}}. */
243
+ SystemVariables["SESSION_TOP_CHEERER"] = "session_top_cheerer";
244
+ /** Amount for SESSION_TOP_CHEERER. Use as {{session_top_cheerer_amount}}. */
245
+ SystemVariables["SESSION_TOP_CHEERER_AMOUNT"] = "session_top_cheerer_amount";
246
+ /** Top cheerer this week. Use as {{week_top_cheerer}}. */
247
+ SystemVariables["WEEK_TOP_CHEERER"] = "week_top_cheerer";
248
+ /** Amount for WEEK_TOP_CHEERER. Use as {{week_top_cheerer_amount}}. */
249
+ SystemVariables["WEEK_TOP_CHEERER_AMOUNT"] = "week_top_cheerer_amount";
250
+ /** Top cheerer this month. Use as {{month_top_cheerer}}. */
251
+ SystemVariables["MONTH_TOP_CHEERER"] = "month_top_cheerer";
252
+ /** Amount for MONTH_TOP_CHEERER. Use as {{month_top_cheerer_amount}}. */
253
+ SystemVariables["MONTH_TOP_CHEERER_AMOUNT"] = "month_top_cheerer_amount";
254
+ /** All-time top cheerer. Use as {{alltime_top_cheerer}}. */
255
+ SystemVariables["ALLTIME_TOP_CHEERER"] = "alltime_top_cheerer";
256
+ /** Amount for ALLTIME_TOP_CHEERER. Use as {{alltime_top_cheerer_amount}}. */
257
+ SystemVariables["ALLTIME_TOP_CHEERER_AMOUNT"] = "alltime_top_cheerer_amount";
258
+ /** Largest single cheer this session. Use as {{session_top_cheer}}. */
259
+ SystemVariables["SESSION_TOP_CHEER"] = "session_top_cheer";
260
+ /** Amount for SESSION_TOP_CHEER. Use as {{session_top_cheer_amount}}. */
261
+ SystemVariables["SESSION_TOP_CHEER_AMOUNT"] = "session_top_cheer_amount";
262
+ /** Most recent raider/host (any platform). Use as {{last_raider}}. */
263
+ SystemVariables["LAST_RAIDER"] = "last_raider";
264
+ /** Viewer count for LAST_RAIDER. Use as {{last_raid_amount}}. */
265
+ SystemVariables["LAST_RAID_AMOUNT"] = "last_raid_amount";
203
266
  // ─────────────────────────────────── Games ────────────────────────────────────
204
267
  /** Raffle title. Use as {{raffle_title}}. */
205
268
  SystemVariables["RAFFLE_TITLE"] = "raffle_title";
package/dist/index.d.ts CHANGED
@@ -4,7 +4,7 @@ export { ILumiaSendPack, ILumiaEvent, ILumiaEventChatCommandBody, ILumiaEventCha
4
4
  export { LumiaEventListTypes, LumiaMapAlertTypeToEventListType, AlertsToFilter, PlatformsToFilter, LumiaEventListTypeColors, getEventListCategoryColor } from './eventlist.types';
5
5
  export { SystemVariables, ReservedVariables, AllVariables, getAcceptedVariableName, getAcceptedVariableNames, type LumiaAcceptedVariable, type LumiaAcceptedVariableDefinition, } from './variables.types';
6
6
  export { formatCondition } from './helpers';
7
- export { EMULATE_EXAMPLE_AVATAR_URL, getExampleAlertVariableValue, buildExampleAlertVariables, isRedundantInputField, syncLinkedVariableFields, type InputFieldLike, } from './emulate.helpers';
7
+ export { EMULATE_EXAMPLE_AVATAR_URL, getExampleAlertVariableValue, buildExampleAlertVariables, coerceNumericAlertFields, isRedundantInputField, syncLinkedVariableFields, type InputFieldLike, } from './emulate.helpers';
8
8
  export { KickKicksData } from './kick_kicks';
9
9
  export { BLANK_OVERLAY_TEMPLATE_ID, type OverlayTemplate, type OverlayTemplateLayerDescriptor, type OverlayTemplateAnchor, type OverlayTemplateLayerOverrides } from './overlay_template.types';
10
10
  export { TiktokGiftsData } from './tiktok_gifts';
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SongRequestPlaybackTarget = exports.SongRequestProvider = exports.SongRequestSource = exports.SongRequestStatus = exports.VIEWER_PROFILE_ACHIEVEMENTS = exports.YoutubeSuperstickersData = exports.TiktokGiftsData = exports.BLANK_OVERLAY_TEMPLATE_ID = exports.KickKicksData = exports.syncLinkedVariableFields = exports.isRedundantInputField = exports.buildExampleAlertVariables = exports.getExampleAlertVariableValue = exports.EMULATE_EXAMPLE_AVATAR_URL = exports.formatCondition = exports.getAcceptedVariableNames = exports.getAcceptedVariableName = exports.AllVariables = exports.ReservedVariables = exports.SystemVariables = exports.getEventListCategoryColor = exports.LumiaEventListTypeColors = exports.PlatformsToFilter = exports.AlertsToFilter = exports.LumiaMapAlertTypeToEventListType = exports.LumiaEventListTypes = exports.LumiaEventTypes = exports.LumiaIntegrations = exports.LumiaAlertConfigs = exports.LumiaRedemptionCurrencySymbol = exports.LumiaRedemptionCurrency = exports.VariationCurrencySymbol = exports.LumiaVariationCurrency = exports.LumiaVariationConditions = exports.LumiaActivityTestType = exports.LumiaActivityNoValueTypes = exports.LumiaActivityApiValueType = exports.LumiaActivityOriginTypes = exports.LumiaAlertFriendlyValues = exports.LumiaAlertValues = exports.LumiaExternalActivityCommandTypes = exports.LumiaActivityCommandTypes = exports.LumiaStreamingSites = void 0;
3
+ exports.SongRequestPlaybackTarget = exports.SongRequestProvider = exports.SongRequestSource = exports.SongRequestStatus = exports.VIEWER_PROFILE_ACHIEVEMENTS = exports.YoutubeSuperstickersData = exports.TiktokGiftsData = exports.BLANK_OVERLAY_TEMPLATE_ID = exports.KickKicksData = exports.syncLinkedVariableFields = exports.isRedundantInputField = exports.coerceNumericAlertFields = exports.buildExampleAlertVariables = exports.getExampleAlertVariableValue = exports.EMULATE_EXAMPLE_AVATAR_URL = exports.formatCondition = exports.getAcceptedVariableNames = exports.getAcceptedVariableName = exports.AllVariables = exports.ReservedVariables = exports.SystemVariables = exports.getEventListCategoryColor = exports.LumiaEventListTypeColors = exports.PlatformsToFilter = exports.AlertsToFilter = exports.LumiaMapAlertTypeToEventListType = exports.LumiaEventListTypes = exports.LumiaEventTypes = exports.LumiaIntegrations = exports.LumiaAlertConfigs = exports.LumiaRedemptionCurrencySymbol = exports.LumiaRedemptionCurrency = exports.VariationCurrencySymbol = exports.LumiaVariationCurrency = exports.LumiaVariationConditions = exports.LumiaActivityTestType = exports.LumiaActivityNoValueTypes = exports.LumiaActivityApiValueType = exports.LumiaActivityOriginTypes = exports.LumiaAlertFriendlyValues = exports.LumiaAlertValues = exports.LumiaExternalActivityCommandTypes = exports.LumiaActivityCommandTypes = exports.LumiaStreamingSites = void 0;
4
4
  var activity_types_1 = require("./activity.types");
5
5
  Object.defineProperty(exports, "LumiaStreamingSites", { enumerable: true, get: function () { return activity_types_1.LumiaStreamingSites; } });
6
6
  Object.defineProperty(exports, "LumiaActivityCommandTypes", { enumerable: true, get: function () { return activity_types_1.LumiaActivityCommandTypes; } });
@@ -40,6 +40,7 @@ var emulate_helpers_1 = require("./emulate.helpers");
40
40
  Object.defineProperty(exports, "EMULATE_EXAMPLE_AVATAR_URL", { enumerable: true, get: function () { return emulate_helpers_1.EMULATE_EXAMPLE_AVATAR_URL; } });
41
41
  Object.defineProperty(exports, "getExampleAlertVariableValue", { enumerable: true, get: function () { return emulate_helpers_1.getExampleAlertVariableValue; } });
42
42
  Object.defineProperty(exports, "buildExampleAlertVariables", { enumerable: true, get: function () { return emulate_helpers_1.buildExampleAlertVariables; } });
43
+ Object.defineProperty(exports, "coerceNumericAlertFields", { enumerable: true, get: function () { return emulate_helpers_1.coerceNumericAlertFields; } });
43
44
  Object.defineProperty(exports, "isRedundantInputField", { enumerable: true, get: function () { return emulate_helpers_1.isRedundantInputField; } });
44
45
  Object.defineProperty(exports, "syncLinkedVariableFields", { enumerable: true, get: function () { return emulate_helpers_1.syncLinkedVariableFields; } });
45
46
  var kick_kicks_1 = require("./kick_kicks");
@@ -199,6 +199,64 @@ export declare enum SystemVariables {
199
199
  MONTH_TOP_DONATOR_LIST = "month_top_donator_list",
200
200
  /** Amounts for MONTH_TOP_DONATOR_LIST. Use as {{month_top_donator_list_amount}}. */
201
201
  MONTH_TOP_DONATOR_LIST_AMOUNT = "month_top_donator_list_amount",
202
+ /** Followers this session across all platforms. Use as {{session_follower_count}}. */
203
+ SESSION_FOLLOWER_COUNT = "session_follower_count",
204
+ /** Followers this week across all platforms. Use as {{week_follower_count}}. */
205
+ WEEK_FOLLOWER_COUNT = "week_follower_count",
206
+ /** Followers this month across all platforms. Use as {{month_follower_count}}. */
207
+ MONTH_FOLLOWER_COUNT = "month_follower_count",
208
+ /** Lifetime followers across all platforms. Use as {{total_follower_count}}. */
209
+ TOTAL_FOLLOWER_COUNT = "total_follower_count",
210
+ /** Most recent follower (any platform). Use as {{last_follower}}. */
211
+ LAST_FOLLOWER = "last_follower",
212
+ /** Subscribers this session across all platforms (new + resub + gifted). Use as {{session_subscriber_count}}. */
213
+ SESSION_SUBSCRIBER_COUNT = "session_subscriber_count",
214
+ /** New (first-time) subscribers this session. Use as {{session_new_subscribers_count}}. */
215
+ SESSION_NEW_SUBSCRIBERS_COUNT = "session_new_subscribers_count",
216
+ /** Resubscribers this session. Use as {{session_resub_subscribers_count}}. */
217
+ SESSION_RESUB_SUBSCRIBERS_COUNT = "session_resub_subscribers_count",
218
+ /** Gifted subs this session. Use as {{session_gifted_subscribers_count}}. */
219
+ SESSION_GIFTED_SUBSCRIBERS_COUNT = "session_gifted_subscribers_count",
220
+ /** Subscribers this week across all platforms. Use as {{week_subscriber_count}}. */
221
+ WEEK_SUBSCRIBER_COUNT = "week_subscriber_count",
222
+ /** Subscribers this month across all platforms. Use as {{month_subscriber_count}}. */
223
+ MONTH_SUBSCRIBER_COUNT = "month_subscriber_count",
224
+ /** Lifetime subscribers across all platforms. Use as {{total_subscriber_count}}. */
225
+ TOTAL_SUBSCRIBER_COUNT = "total_subscriber_count",
226
+ /** Most recent subscriber (any platform). Use as {{last_subscriber}}. */
227
+ LAST_SUBSCRIBER = "last_subscriber",
228
+ /** All-time top gifter (any platform). Use as {{alltime_top_gifter}}. */
229
+ ALLTIME_TOP_GIFTER = "alltime_top_gifter",
230
+ /** Bits/cheers count this session. Use as {{session_bits_count}}. */
231
+ SESSION_BITS_COUNT = "session_bits_count",
232
+ /** Bits/cheers count this week. Use as {{week_bits_count}}. */
233
+ WEEK_BITS_COUNT = "week_bits_count",
234
+ /** Bits/cheers count this month. Use as {{month_bits_count}}. */
235
+ MONTH_BITS_COUNT = "month_bits_count",
236
+ /** Top cheerer (by total bits) this session. Use as {{session_top_cheerer}}. */
237
+ SESSION_TOP_CHEERER = "session_top_cheerer",
238
+ /** Amount for SESSION_TOP_CHEERER. Use as {{session_top_cheerer_amount}}. */
239
+ SESSION_TOP_CHEERER_AMOUNT = "session_top_cheerer_amount",
240
+ /** Top cheerer this week. Use as {{week_top_cheerer}}. */
241
+ WEEK_TOP_CHEERER = "week_top_cheerer",
242
+ /** Amount for WEEK_TOP_CHEERER. Use as {{week_top_cheerer_amount}}. */
243
+ WEEK_TOP_CHEERER_AMOUNT = "week_top_cheerer_amount",
244
+ /** Top cheerer this month. Use as {{month_top_cheerer}}. */
245
+ MONTH_TOP_CHEERER = "month_top_cheerer",
246
+ /** Amount for MONTH_TOP_CHEERER. Use as {{month_top_cheerer_amount}}. */
247
+ MONTH_TOP_CHEERER_AMOUNT = "month_top_cheerer_amount",
248
+ /** All-time top cheerer. Use as {{alltime_top_cheerer}}. */
249
+ ALLTIME_TOP_CHEERER = "alltime_top_cheerer",
250
+ /** Amount for ALLTIME_TOP_CHEERER. Use as {{alltime_top_cheerer_amount}}. */
251
+ ALLTIME_TOP_CHEERER_AMOUNT = "alltime_top_cheerer_amount",
252
+ /** Largest single cheer this session. Use as {{session_top_cheer}}. */
253
+ SESSION_TOP_CHEER = "session_top_cheer",
254
+ /** Amount for SESSION_TOP_CHEER. Use as {{session_top_cheer_amount}}. */
255
+ SESSION_TOP_CHEER_AMOUNT = "session_top_cheer_amount",
256
+ /** Most recent raider/host (any platform). Use as {{last_raider}}. */
257
+ LAST_RAIDER = "last_raider",
258
+ /** Viewer count for LAST_RAIDER. Use as {{last_raid_amount}}. */
259
+ LAST_RAID_AMOUNT = "last_raid_amount",
202
260
  /** Raffle title. Use as {{raffle_title}}. */
203
261
  RAFFLE_TITLE = "raffle_title",
204
262
  /** Raffle description. Use as {{raffle_description}}. */
@@ -205,6 +205,69 @@ var SystemVariables;
205
205
  SystemVariables["MONTH_TOP_DONATOR_LIST"] = "month_top_donator_list";
206
206
  /** Amounts for MONTH_TOP_DONATOR_LIST. Use as {{month_top_donator_list_amount}}. */
207
207
  SystemVariables["MONTH_TOP_DONATOR_LIST_AMOUNT"] = "month_top_donator_list_amount";
208
+ // ─── Cross-platform follower / subscriber / cheer / raid (SE-shaped names) ───
209
+ // Mirror StreamElements' session keys without a platform prefix so SE → Lumia
210
+ // is a 1:1 map and labels can reference one counter that aggregates across
211
+ // Twitch, YouTube, Kick, etc. Platform-specific variants (TWITCH_*, KICK_*,
212
+ // YOUTUBE_*) remain available for labels that need a single-platform view.
213
+ /** Followers this session across all platforms. Use as {{session_follower_count}}. */
214
+ SystemVariables["SESSION_FOLLOWER_COUNT"] = "session_follower_count";
215
+ /** Followers this week across all platforms. Use as {{week_follower_count}}. */
216
+ SystemVariables["WEEK_FOLLOWER_COUNT"] = "week_follower_count";
217
+ /** Followers this month across all platforms. Use as {{month_follower_count}}. */
218
+ SystemVariables["MONTH_FOLLOWER_COUNT"] = "month_follower_count";
219
+ /** Lifetime followers across all platforms. Use as {{total_follower_count}}. */
220
+ SystemVariables["TOTAL_FOLLOWER_COUNT"] = "total_follower_count";
221
+ /** Most recent follower (any platform). Use as {{last_follower}}. */
222
+ SystemVariables["LAST_FOLLOWER"] = "last_follower";
223
+ /** Subscribers this session across all platforms (new + resub + gifted). Use as {{session_subscriber_count}}. */
224
+ SystemVariables["SESSION_SUBSCRIBER_COUNT"] = "session_subscriber_count";
225
+ /** New (first-time) subscribers this session. Use as {{session_new_subscribers_count}}. */
226
+ SystemVariables["SESSION_NEW_SUBSCRIBERS_COUNT"] = "session_new_subscribers_count";
227
+ /** Resubscribers this session. Use as {{session_resub_subscribers_count}}. */
228
+ SystemVariables["SESSION_RESUB_SUBSCRIBERS_COUNT"] = "session_resub_subscribers_count";
229
+ /** Gifted subs this session. Use as {{session_gifted_subscribers_count}}. */
230
+ SystemVariables["SESSION_GIFTED_SUBSCRIBERS_COUNT"] = "session_gifted_subscribers_count";
231
+ /** Subscribers this week across all platforms. Use as {{week_subscriber_count}}. */
232
+ SystemVariables["WEEK_SUBSCRIBER_COUNT"] = "week_subscriber_count";
233
+ /** Subscribers this month across all platforms. Use as {{month_subscriber_count}}. */
234
+ SystemVariables["MONTH_SUBSCRIBER_COUNT"] = "month_subscriber_count";
235
+ /** Lifetime subscribers across all platforms. Use as {{total_subscriber_count}}. */
236
+ SystemVariables["TOTAL_SUBSCRIBER_COUNT"] = "total_subscriber_count";
237
+ /** Most recent subscriber (any platform). Use as {{last_subscriber}}. */
238
+ SystemVariables["LAST_SUBSCRIBER"] = "last_subscriber";
239
+ /** All-time top gifter (any platform). Use as {{alltime_top_gifter}}. */
240
+ SystemVariables["ALLTIME_TOP_GIFTER"] = "alltime_top_gifter";
241
+ /** Bits/cheers count this session. Use as {{session_bits_count}}. */
242
+ SystemVariables["SESSION_BITS_COUNT"] = "session_bits_count";
243
+ /** Bits/cheers count this week. Use as {{week_bits_count}}. */
244
+ SystemVariables["WEEK_BITS_COUNT"] = "week_bits_count";
245
+ /** Bits/cheers count this month. Use as {{month_bits_count}}. */
246
+ SystemVariables["MONTH_BITS_COUNT"] = "month_bits_count";
247
+ /** Top cheerer (by total bits) this session. Use as {{session_top_cheerer}}. */
248
+ SystemVariables["SESSION_TOP_CHEERER"] = "session_top_cheerer";
249
+ /** Amount for SESSION_TOP_CHEERER. Use as {{session_top_cheerer_amount}}. */
250
+ SystemVariables["SESSION_TOP_CHEERER_AMOUNT"] = "session_top_cheerer_amount";
251
+ /** Top cheerer this week. Use as {{week_top_cheerer}}. */
252
+ SystemVariables["WEEK_TOP_CHEERER"] = "week_top_cheerer";
253
+ /** Amount for WEEK_TOP_CHEERER. Use as {{week_top_cheerer_amount}}. */
254
+ SystemVariables["WEEK_TOP_CHEERER_AMOUNT"] = "week_top_cheerer_amount";
255
+ /** Top cheerer this month. Use as {{month_top_cheerer}}. */
256
+ SystemVariables["MONTH_TOP_CHEERER"] = "month_top_cheerer";
257
+ /** Amount for MONTH_TOP_CHEERER. Use as {{month_top_cheerer_amount}}. */
258
+ SystemVariables["MONTH_TOP_CHEERER_AMOUNT"] = "month_top_cheerer_amount";
259
+ /** All-time top cheerer. Use as {{alltime_top_cheerer}}. */
260
+ SystemVariables["ALLTIME_TOP_CHEERER"] = "alltime_top_cheerer";
261
+ /** Amount for ALLTIME_TOP_CHEERER. Use as {{alltime_top_cheerer_amount}}. */
262
+ SystemVariables["ALLTIME_TOP_CHEERER_AMOUNT"] = "alltime_top_cheerer_amount";
263
+ /** Largest single cheer this session. Use as {{session_top_cheer}}. */
264
+ SystemVariables["SESSION_TOP_CHEER"] = "session_top_cheer";
265
+ /** Amount for SESSION_TOP_CHEER. Use as {{session_top_cheer_amount}}. */
266
+ SystemVariables["SESSION_TOP_CHEER_AMOUNT"] = "session_top_cheer_amount";
267
+ /** Most recent raider/host (any platform). Use as {{last_raider}}. */
268
+ SystemVariables["LAST_RAIDER"] = "last_raider";
269
+ /** Viewer count for LAST_RAIDER. Use as {{last_raid_amount}}. */
270
+ SystemVariables["LAST_RAID_AMOUNT"] = "last_raid_amount";
208
271
  // ─────────────────────────────────── Games ────────────────────────────────────
209
272
  /** Raffle title. Use as {{raffle_title}}. */
210
273
  SystemVariables["RAFFLE_TITLE"] = "raffle_title";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lumiastream/lumia-types",
3
- "version": "3.5.5",
3
+ "version": "3.5.7",
4
4
  "description": "",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/esm/index.js",