@streamlayer/react 0.41.10 → 1.1.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/lib/app/advertisement.d.ts +1 -0
- package/lib/app/app.d.ts +5 -3
- package/lib/app/auth.d.ts +0 -1
- package/lib/app/masters.d.ts +2 -1
- package/lib/app/provider.d.ts +5 -4
- package/lib/app/useStreamLayerApp.d.ts +8 -7
- package/lib/cjs/app.js +1 -1
- package/lib/cjs/gamification-feature.js +1 -1
- package/lib/cjs/gamification-feature2.js +1 -0
- package/lib/cjs/index.js +1 -1
- package/lib/cjs/index2.js +182 -14
- package/lib/cjs/masters.js +1 -1
- package/lib/cjs/masters2.js +9 -164
- package/lib/cjs/points.js +1 -1
- package/lib/cjs/useStreamLayerApp.js +1 -1
- package/lib/cjs/useStreamLayerApp2.js +17 -0
- package/lib/dist/cjs/gamification-feature2.js +1 -0
- package/lib/dist/cjs/index.js +1 -1
- package/lib/dist/cjs/masters.js +92 -80
- package/lib/dist/es/gamification-feature2.js +115 -0
- package/lib/dist/es/index.js +7 -5
- package/lib/dist/es/masters.js +31532 -34905
- package/lib/dist/index.d.ts +234 -145
- package/lib/dist/style.css +1 -1
- package/lib/es/app.js +940 -11
- package/lib/es/gamification-feature.js +1 -1
- package/lib/es/gamification-feature2.js +4 -0
- package/lib/es/index.js +6 -14
- package/lib/es/index2.js +23159 -112
- package/lib/es/masters.js +1 -1
- package/lib/es/masters2.js +679 -23045
- package/lib/es/points.js +30 -33
- package/lib/es/useStreamLayerApp.js +3 -36
- package/lib/es/useStreamLayerApp2.js +17388 -0
- package/lib/index.d.ts +1 -1
- package/lib/masters.d.ts +2 -1
- package/lib/style.css +1 -1
- package/package.json +45 -40
- package/lib/cjs/index3.js +0 -1
- package/lib/es/index3.js +0 -246
package/lib/dist/index.d.ts
CHANGED
|
@@ -1,15 +1,14 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
declare module "../../sdk-web-types/src/sl-types" {
|
|
3
2
|
import { PlainMessage } from '@bufbuild/protobuf';
|
|
4
3
|
import type { StreamSettings as SLStreamSettings, SdkOverlay, Advertising, OrganizationSettings as SLOrganizationSettings } from '@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb';
|
|
5
4
|
import type { GameSettings as IGameSettings } from '@streamlayer/sl-eslib/sdkSettings/game/common/game_common_pb';
|
|
6
5
|
import type { ClientSettings } from '@streamlayer/sl-eslib/sdkSettings/client/client_pb';
|
|
7
|
-
import type {
|
|
8
|
-
export { QuestionType, QuestionStatus, QuestionImages, ImagePosition, SilenceSetting, QuestionOptions, } from '@streamlayer/sl-eslib/interactive/interactive.common_pb';
|
|
9
|
-
import type { PickHistory as IPickHistory, InsightHistory as IInsightHistory, TweetHistory as ITweetHistory, FeedItem as IFeedItem, FeedItemAttributes as IFeedItemAttributes, InstantView as IInstantView } from '@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb';
|
|
6
|
+
import type { User as ProtoUser } from '@streamlayer/sl-eslib/users/users_common_pb';
|
|
7
|
+
export { QuestionType, QuestionStatus, QuestionImages, ImagePosition, SilenceSetting, QuestionOptions, PromotionType, PromotionWallet, PromotionLogoMode, CtaIconMode, } from '@streamlayer/sl-eslib/interactive/interactive.common_pb';
|
|
8
|
+
import type { PickHistory as IPickHistory, InsightHistory as IInsightHistory, TweetHistory as ITweetHistory, FeedItem as IFeedItem, FeedItemAttributes as IFeedItemAttributes, InstantView as IInstantView, PromotionHistory as IPromotionHistory } from '@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb';
|
|
10
9
|
export { PickHistoryStatus } from '@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb';
|
|
11
10
|
import type { LeaderboardItem as ILeaderboardItem } from '@streamlayer/sl-eslib/interactive/leaderboard/interactive.leaderboard_pb';
|
|
12
|
-
import type { ExtendedQuestionAnswer as IExtendedQuestionAnswer, Question as IQuestion, ExtendedQuestion as IExtendedQuestion } from '@streamlayer/sl-eslib/interactive/interactive.common_pb';
|
|
11
|
+
import type { ExtendedQuestionAnswer as IExtendedQuestionAnswer, Question as IQuestion, ExtendedQuestion as IExtendedQuestion, QuestionOptions_PromotionOptions } from '@streamlayer/sl-eslib/interactive/interactive.common_pb';
|
|
13
12
|
export type PickHistory = PlainMessage<IPickHistory>;
|
|
14
13
|
export type ExtendedQuestionAnswer = PlainMessage<IExtendedQuestionAnswer>;
|
|
15
14
|
export type InsightHistory = PlainMessage<IInsightHistory>;
|
|
@@ -18,7 +17,9 @@ declare module "../../sdk-web-types/src/sl-types" {
|
|
|
18
17
|
export type OrganizationAdvertising = Advertising;
|
|
19
18
|
export type FeatureConfig = SdkOverlay;
|
|
20
19
|
export type StreamSettings = SLStreamSettings;
|
|
21
|
-
export type User =
|
|
20
|
+
export type User = {
|
|
21
|
+
data: ProtoUser | undefined;
|
|
22
|
+
};
|
|
22
23
|
export type UserSettings = ClientSettings;
|
|
23
24
|
export type LeaderboardItem = ILeaderboardItem;
|
|
24
25
|
export type FeedItem = PlainMessage<IFeedItem>;
|
|
@@ -27,6 +28,8 @@ declare module "../../sdk-web-types/src/sl-types" {
|
|
|
27
28
|
export type GameSettings = PlainMessage<IGameSettings>;
|
|
28
29
|
export type Question = PlainMessage<IQuestion>;
|
|
29
30
|
export type ExtendedQuestion = PlainMessage<IExtendedQuestion>;
|
|
31
|
+
export type PromotionHistory = PlainMessage<IPromotionHistory>;
|
|
32
|
+
export type PromotionOptions = PlainMessage<QuestionOptions_PromotionOptions>;
|
|
30
33
|
export { SdkOverlayType as FeatureType, SdkOverlaySettings, GamesOverlaySettings, } from '@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb';
|
|
31
34
|
export { InvitationFrom } from '@streamlayer/sl-eslib/analytics/v1/invitations/invitations_pb';
|
|
32
35
|
}
|
|
@@ -39,7 +42,7 @@ declare module "../../sdk-web-logger/src/index" {
|
|
|
39
42
|
export type Logger = ReturnType<typeof createLogger>;
|
|
40
43
|
}
|
|
41
44
|
declare module "../../sdk-web-interfaces/src/event-bus/index" {
|
|
42
|
-
import { InvitationFrom, QuestionType } from '
|
|
45
|
+
import { InvitationFrom, QuestionType } from '@streamlayer/sdk-web-types';
|
|
43
46
|
const EventBusActions: {
|
|
44
47
|
notification: {
|
|
45
48
|
received: string;
|
|
@@ -94,7 +97,7 @@ declare module "../../sdk-web-interfaces/src/event-bus/index" {
|
|
|
94
97
|
private name;
|
|
95
98
|
private listeners;
|
|
96
99
|
constructor(name?: string);
|
|
97
|
-
emit: <K extends
|
|
100
|
+
emit: <K extends EventBusActionsKeys = "notification" | "invitation" | "interactions" | "poll">(type: K, payload: Omit<EventBusData<K>, "type">) => void;
|
|
98
101
|
listen<T extends EventBusActionsKeys>(listener: (event: EventBusEvent<T>) => void): () => void;
|
|
99
102
|
off<T extends EventBusActionsKeys>(listener: (event: EventBusEvent<T>) => void): void;
|
|
100
103
|
destroy: () => void;
|
|
@@ -177,7 +180,7 @@ declare module "../../sdk-web-interfaces/src/store/map" {
|
|
|
177
180
|
};
|
|
178
181
|
}
|
|
179
182
|
declare module "../../sdk-web-interfaces/src/feature" {
|
|
180
|
-
import { FeatureConfig as SdkOverlay, SdkOverlaySettings } from '
|
|
183
|
+
import { FeatureConfig as SdkOverlay, SdkOverlaySettings } from '@streamlayer/sdk-web-types';
|
|
181
184
|
import { PlainMessage } from '@bufbuild/protobuf';
|
|
182
185
|
import { WritableAtom } from 'nanostores';
|
|
183
186
|
import { MapStore } from "../../sdk-web-interfaces/src/store/map";
|
|
@@ -228,10 +231,10 @@ declare module "../../sdk-web-interfaces/src/store/single" {
|
|
|
228
231
|
* Wrapper for nanostores WritableAtom
|
|
229
232
|
*/
|
|
230
233
|
export class SingleStore<StoreValue, StoreInstance extends WritableAtom<StoreValue | undefined> = WritableAtom<StoreValue | undefined>> extends AbstractStore<StoreInstance> {
|
|
231
|
-
getValue: () => StoreInstance[
|
|
234
|
+
getValue: () => StoreInstance["value"];
|
|
232
235
|
getValues(): unknown;
|
|
233
236
|
setValue: (value?: StoreValue) => void;
|
|
234
|
-
subscribe: (listener: Parameters<StoreInstance[
|
|
237
|
+
subscribe: (listener: Parameters<StoreInstance["subscribe"]>[0]) => () => void;
|
|
235
238
|
unsubscribe: () => void;
|
|
236
239
|
listen(listener: Parameters<StoreInstance['subscribe']>[0]): () => void;
|
|
237
240
|
get(): StoreValue | undefined;
|
|
@@ -240,7 +243,7 @@ declare module "../../sdk-web-interfaces/src/store/single" {
|
|
|
240
243
|
* create atom store from nanostores
|
|
241
244
|
*/
|
|
242
245
|
export const createSingleStore: <T>(initialData: T) => WritableAtom<T>;
|
|
243
|
-
export const createComputedStore: <Value, T extends WritableAtom
|
|
246
|
+
export const createComputedStore: <Value, T extends WritableAtom = WritableAtom<any>>(store: T, mutator: (value: StoreValue<T>) => Value) => import("nanostores").ReadableAtom<Value>;
|
|
244
247
|
}
|
|
245
248
|
declare module "../../sdk-web-interfaces/src/store/api" {
|
|
246
249
|
import type { FetcherStore, FetcherValue } from '@nanostores/query';
|
|
@@ -255,18 +258,18 @@ declare module "../../sdk-web-interfaces/src/store/api" {
|
|
|
255
258
|
getAtomStore: () => WritableAtom<string | undefined>;
|
|
256
259
|
getValue: () => Promise<StoreValue | undefined>;
|
|
257
260
|
getValues: () => FetcherValue<StoreValue, any>;
|
|
258
|
-
setValue: (value?: StoreInstance[
|
|
261
|
+
setValue: (value?: StoreInstance["value"]) => void;
|
|
259
262
|
subscribe: StoreInstance['subscribe'];
|
|
260
263
|
unsubscribe: () => never;
|
|
261
264
|
invalidate: () => void;
|
|
262
|
-
listen: (cb: Parameters<StoreInstance[
|
|
265
|
+
listen: (cb: Parameters<StoreInstance["listen"]>[0]) => () => void;
|
|
263
266
|
get(): void;
|
|
264
267
|
key: () => string | undefined;
|
|
265
268
|
off: () => void;
|
|
266
269
|
}
|
|
267
270
|
}
|
|
268
271
|
declare module "../../sdk-web-interfaces/src/index" {
|
|
269
|
-
import { FeatureType } from '
|
|
272
|
+
import { FeatureType } from '@streamlayer/sdk-web-types';
|
|
270
273
|
import { EventBus, EventBusEvent, EventBusData, EventBusActionPayload } from "../../sdk-web-interfaces/src/event-bus/index";
|
|
271
274
|
export { AbstractAuthenticationProvider } from "../../sdk-web-interfaces/src/auth";
|
|
272
275
|
export { AbstractFeature, FeatureSource, type FeatureProps, FeatureStatus } from "../../sdk-web-interfaces/src/feature";
|
|
@@ -367,7 +370,7 @@ declare module "../../sdk-web-api/src/grpc/retry" {
|
|
|
367
370
|
export const retry: Interceptor;
|
|
368
371
|
}
|
|
369
372
|
declare module "../../sdk-web-api/src/grpc/transport" {
|
|
370
|
-
import { MapStore } from '
|
|
373
|
+
import { MapStore } from '@streamlayer/sdk-web-interfaces';
|
|
371
374
|
import { createRouterTransport, ConnectRouter, Interceptor, PromiseClient, UnaryRequest, StreamRequest } from '@connectrpc/connect';
|
|
372
375
|
import type { ServiceType, Message, PlainMessage } from '@bufbuild/protobuf';
|
|
373
376
|
import { createGrpcWebTransport } from '@connectrpc/connect-web';
|
|
@@ -425,7 +428,7 @@ declare module "../../sdk-web-api/src/grpc/transport" {
|
|
|
425
428
|
refetchInterval?: number;
|
|
426
429
|
retryable?: boolean;
|
|
427
430
|
});
|
|
428
|
-
addSubscription: <T extends ServiceType, Req extends Message<Req>, Res extends Message<Res>>(method: ServerStreamSubscription<T, Req, Res>[
|
|
431
|
+
addSubscription: <T extends ServiceType, Req extends Message<Req>, Res extends Message<Res>>(method: ServerStreamSubscription<T, Req, Res>["method"], params: Atom<PlainMessage<Req>> | PlainMessage<Req>, options: ServerStreamSubscriptionOptions) => ServerStreamSubscription<ServiceType, Message<import("@bufbuild/protobuf").AnyMessage>, Message<import("@bufbuild/protobuf").AnyMessage>, never, never> | ServerStreamSubscription<T, Req, Res, keyof { [P in keyof PromiseClient<T> as T["methods"][P] extends import("@bufbuild/protobuf").MethodInfoServerStreaming<any, any> ? P : never]: T["methods"][P] extends import("@bufbuild/protobuf").MethodInfoServerStreaming<any, any> ? PromiseClient<T>[P] : never; }, { [P in keyof PromiseClient<T> as T["methods"][P] extends import("@bufbuild/protobuf").MethodInfoServerStreaming<any, any> ? P : never]: T["methods"][P] extends import("@bufbuild/protobuf").MethodInfoServerStreaming<any, any> ? PromiseClient<T>[P] : never; }[keyof { [P in keyof PromiseClient<T> as T["methods"][P] extends import("@bufbuild/protobuf").MethodInfoServerStreaming<any, any> ? P : never]: T["methods"][P] extends import("@bufbuild/protobuf").MethodInfoServerStreaming<any, any> ? PromiseClient<T>[P] : never; }]>;
|
|
429
432
|
removeSubscription: (subscription: ServerStreamSubscription<ServiceType, Message, Message>) => void;
|
|
430
433
|
disconnect: () => void;
|
|
431
434
|
registerInterceptor: (interceptor: Interceptor) => void;
|
|
@@ -433,8 +436,8 @@ declare module "../../sdk-web-api/src/grpc/transport" {
|
|
|
433
436
|
getClient: <T extends ServiceType>(service: T) => PromiseClient<T>;
|
|
434
437
|
getStreamClient: <T extends ServiceType>(service: T) => PromiseClient<T>;
|
|
435
438
|
createPromiseClient: <T extends ServiceType>(service: T, { params, method }: {
|
|
436
|
-
params?: KeyInput
|
|
437
|
-
method: keyof T[
|
|
439
|
+
params?: KeyInput;
|
|
440
|
+
method: keyof T["methods"];
|
|
438
441
|
}) => {
|
|
439
442
|
client: PromiseClient<T>;
|
|
440
443
|
createRequestOptions: (options: RequestOptions) => import("@connectrpc/connect").ContextValues;
|
|
@@ -446,7 +449,7 @@ declare module "../../sdk-web-api/src/grpc/transport" {
|
|
|
446
449
|
};
|
|
447
450
|
setSdkKey: (sdkKey: string) => void;
|
|
448
451
|
setAuth: (token: string, userId: string) => void;
|
|
449
|
-
setHeader: <T extends
|
|
452
|
+
setHeader: <T extends keyof KnownHeaders = string>(name: ExcludeReservedHeaders<T>, value: string) => void;
|
|
450
453
|
getHeader: (name: keyof KnownHeaders) => string;
|
|
451
454
|
getHeaders: () => KnownHeaders;
|
|
452
455
|
initInterceptors: () => void;
|
|
@@ -531,7 +534,9 @@ declare module "../../sdk-web-api/src/grpc/queries/user" {
|
|
|
531
534
|
import type { BypassAuthRequest } from '@streamlayer/sl-eslib/users/users_pb';
|
|
532
535
|
import { PlainMessage } from '@bufbuild/protobuf';
|
|
533
536
|
import { Transport } from "../../sdk-web-api/src/grpc/transport";
|
|
534
|
-
export const $user: ($userToken: ReadableAtom<string | undefined>, transport: Transport) => import("@nanostores/query").FetcherStore<
|
|
537
|
+
export const $user: ($userToken: ReadableAtom<string | undefined>, transport: Transport) => import("@nanostores/query").FetcherStore<{
|
|
538
|
+
data: import("@streamlayer/sl-eslib/users/users_common_pb").User | undefined;
|
|
539
|
+
}, any>;
|
|
535
540
|
export const bypassLogin: (transport: Transport) => ({ userKey, schema, init, inviterKey }: PlainMessage<BypassAuthRequest>) => Promise<import("@streamlayer/sl-eslib/users/users_pb").BypassAuthResponse>;
|
|
536
541
|
export const bypassAuth: (transport: Transport, params: {
|
|
537
542
|
userKey?: string;
|
|
@@ -545,7 +550,7 @@ declare module "../../sdk-web-api/src/grpc/queries/organization" {
|
|
|
545
550
|
import { ReadableAtom } from 'nanostores';
|
|
546
551
|
import { Transport } from "../../sdk-web-api/src/grpc/transport";
|
|
547
552
|
export { $user } from "../../sdk-web-api/src/grpc/queries/user";
|
|
548
|
-
export const $organizationSettings: ($enabled: ReadableAtom<
|
|
553
|
+
export const $organizationSettings: ($enabled: ReadableAtom<"on" | undefined>, transport: Transport) => import("@nanostores/query").FetcherStore<{
|
|
549
554
|
id: string;
|
|
550
555
|
overlays?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").SdkOverlay[] | undefined;
|
|
551
556
|
buttonIcon?: string | undefined;
|
|
@@ -558,9 +563,9 @@ declare module "../../sdk-web-api/src/grpc/queries/organization" {
|
|
|
558
563
|
moderationPrimaryColor?: string | undefined;
|
|
559
564
|
linkShareIcon?: string | undefined;
|
|
560
565
|
linkShareText?: string | undefined;
|
|
561
|
-
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults
|
|
562
|
-
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK
|
|
563
|
-
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient
|
|
566
|
+
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults;
|
|
567
|
+
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK;
|
|
568
|
+
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient;
|
|
564
569
|
publicName?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").PublicName | undefined;
|
|
565
570
|
analyticsVersion?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").AnalyticsVersion | undefined;
|
|
566
571
|
} | undefined, any>;
|
|
@@ -572,7 +577,7 @@ declare module "../../sdk-web-api/src/grpc/queries/index" {
|
|
|
572
577
|
export * from "../../sdk-web-api/src/grpc/queries/user";
|
|
573
578
|
}
|
|
574
579
|
declare module "../../sdk-web-api/src/index" {
|
|
575
|
-
import { StreamLayerContext } from '
|
|
580
|
+
import { StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
576
581
|
import { FetcherStore } from '@nanostores/query';
|
|
577
582
|
export type { ServerStreamSubscriptionOptions } from "../../sdk-web-api/src/grpc/subscription";
|
|
578
583
|
export { Transport } from "../../sdk-web-api/src/grpc/transport";
|
|
@@ -597,7 +602,7 @@ declare module "../../sdk-web-api/src/index" {
|
|
|
597
602
|
}, done: () => void) => void;
|
|
598
603
|
}
|
|
599
604
|
declare module "../../sdk-web-core/src/storage" {
|
|
600
|
-
import { Storage } from '
|
|
605
|
+
import { Storage } from '@streamlayer/sdk-web-storage';
|
|
601
606
|
export class UserStorage extends Storage {
|
|
602
607
|
constructor();
|
|
603
608
|
setSchema: (value: string) => void;
|
|
@@ -610,9 +615,9 @@ declare module "../../sdk-web-core/src/storage" {
|
|
|
610
615
|
}
|
|
611
616
|
}
|
|
612
617
|
declare module "../../sdk-web-core/src/store/init" {
|
|
613
|
-
import { SingleStore, ApiStore } from '
|
|
614
|
-
import { Transport } from '
|
|
615
|
-
import
|
|
618
|
+
import { SingleStore, ApiStore } from '@streamlayer/sdk-web-interfaces';
|
|
619
|
+
import { Transport } from '@streamlayer/sdk-web-api';
|
|
620
|
+
import { User } from '@streamlayer/sdk-web-types';
|
|
616
621
|
export enum CoreStatus {
|
|
617
622
|
DISABLED = "disabled",
|
|
618
623
|
INITIALIZATION = "initialization",
|
|
@@ -626,7 +631,7 @@ declare module "../../sdk-web-core/src/store/init" {
|
|
|
626
631
|
readonly providerStreamId: SingleStore<unknown, import("nanostores").WritableAtom<string | undefined>>;
|
|
627
632
|
readonly slStreamId: ApiStore<string | undefined, import("@nanostores/query").FetcherStore<string | undefined, any>>;
|
|
628
633
|
readonly streamSettings: ApiStore<import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").StreamSettings | undefined, import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").StreamSettings | undefined, any>>;
|
|
629
|
-
readonly user: ApiStore<
|
|
634
|
+
readonly user: ApiStore<User, import("@nanostores/query").FetcherStore<User, any>>;
|
|
630
635
|
readonly userKey: SingleStore<unknown, import("nanostores").WritableAtom<string | undefined>>;
|
|
631
636
|
readonly userToken: SingleStore<unknown, import("nanostores").WritableAtom<string | undefined>>;
|
|
632
637
|
readonly userSettings: ApiStore<import("@streamlayer/sl-eslib/sdkSettings/client/client_pb").ClientSettings | undefined, import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/sdkSettings/client/client_pb").ClientSettings | undefined, any>>;
|
|
@@ -643,9 +648,9 @@ declare module "../../sdk-web-core/src/store/init" {
|
|
|
643
648
|
moderationPrimaryColor?: string | undefined;
|
|
644
649
|
linkShareIcon?: string | undefined;
|
|
645
650
|
linkShareText?: string | undefined;
|
|
646
|
-
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults
|
|
647
|
-
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK
|
|
648
|
-
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient
|
|
651
|
+
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults;
|
|
652
|
+
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK;
|
|
653
|
+
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient;
|
|
649
654
|
publicName?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").PublicName | undefined;
|
|
650
655
|
analyticsVersion?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").AnalyticsVersion | undefined;
|
|
651
656
|
} | undefined, import("@nanostores/query").FetcherStore<{
|
|
@@ -661,9 +666,9 @@ declare module "../../sdk-web-core/src/store/init" {
|
|
|
661
666
|
moderationPrimaryColor?: string | undefined;
|
|
662
667
|
linkShareIcon?: string | undefined;
|
|
663
668
|
linkShareText?: string | undefined;
|
|
664
|
-
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults
|
|
665
|
-
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK
|
|
666
|
-
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient
|
|
669
|
+
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults;
|
|
670
|
+
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK;
|
|
671
|
+
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient;
|
|
667
672
|
publicName?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").PublicName | undefined;
|
|
668
673
|
analyticsVersion?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").AnalyticsVersion | undefined;
|
|
669
674
|
} | undefined, any>>;
|
|
@@ -671,9 +676,9 @@ declare module "../../sdk-web-core/src/store/init" {
|
|
|
671
676
|
};
|
|
672
677
|
}
|
|
673
678
|
declare module "../../sdk-web-core/src/store/store" {
|
|
674
|
-
import type { OrganizationAdvertising, StreamSettings, OrganizationSettings, User, UserSettings } from '
|
|
675
|
-
import { AbstractStore } from '
|
|
676
|
-
import { Transport } from '
|
|
679
|
+
import type { OrganizationAdvertising, StreamSettings, OrganizationSettings, User, UserSettings } from '@streamlayer/sdk-web-types';
|
|
680
|
+
import { AbstractStore } from '@streamlayer/sdk-web-interfaces';
|
|
681
|
+
import { Transport } from '@streamlayer/sdk-web-api';
|
|
677
682
|
import { ReadableAtom } from 'nanostores';
|
|
678
683
|
import { FetcherValue } from '@nanostores/query';
|
|
679
684
|
import { initializeStore, CoreStatus } from "../../sdk-web-core/src/store/init";
|
|
@@ -721,16 +726,16 @@ declare module "../../sdk-web-core/src/store/store" {
|
|
|
721
726
|
constructor(transport: Transport);
|
|
722
727
|
getValue(): unknown;
|
|
723
728
|
getValues(): {
|
|
724
|
-
readonly enabled: import(
|
|
725
|
-
readonly status: import(
|
|
726
|
-
readonly providerStreamId: import(
|
|
727
|
-
readonly slStreamId: import(
|
|
728
|
-
readonly streamSettings: import(
|
|
729
|
-
readonly user: import(
|
|
730
|
-
readonly userKey: import(
|
|
731
|
-
readonly userToken: import(
|
|
732
|
-
readonly userSettings: import(
|
|
733
|
-
readonly organizationSettings: import(
|
|
729
|
+
readonly enabled: import("@streamlayer/sdk-web-interfaces").SingleStore<unknown, import("nanostores").WritableAtom<"on" | undefined>>;
|
|
730
|
+
readonly status: import("@streamlayer/sdk-web-interfaces").SingleStore<unknown, import("nanostores").WritableAtom<CoreStatus>>;
|
|
731
|
+
readonly providerStreamId: import("@streamlayer/sdk-web-interfaces").SingleStore<unknown, import("nanostores").WritableAtom<string | undefined>>;
|
|
732
|
+
readonly slStreamId: import("@streamlayer/sdk-web-interfaces").ApiStore<string | undefined, import("@nanostores/query").FetcherStore<string | undefined, any>>;
|
|
733
|
+
readonly streamSettings: import("@streamlayer/sdk-web-interfaces").ApiStore<import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").StreamSettings | undefined, import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").StreamSettings | undefined, any>>;
|
|
734
|
+
readonly user: import("@streamlayer/sdk-web-interfaces").ApiStore<User, import("@nanostores/query").FetcherStore<User, any>>;
|
|
735
|
+
readonly userKey: import("@streamlayer/sdk-web-interfaces").SingleStore<unknown, import("nanostores").WritableAtom<string | undefined>>;
|
|
736
|
+
readonly userToken: import("@streamlayer/sdk-web-interfaces").SingleStore<unknown, import("nanostores").WritableAtom<string | undefined>>;
|
|
737
|
+
readonly userSettings: import("@streamlayer/sdk-web-interfaces").ApiStore<import("@streamlayer/sl-eslib/sdkSettings/client/client_pb").ClientSettings | undefined, import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/sdkSettings/client/client_pb").ClientSettings | undefined, any>>;
|
|
738
|
+
readonly organizationSettings: import("@streamlayer/sdk-web-interfaces").ApiStore<{
|
|
734
739
|
id: string;
|
|
735
740
|
overlays?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").SdkOverlay[] | undefined;
|
|
736
741
|
buttonIcon?: string | undefined;
|
|
@@ -743,9 +748,9 @@ declare module "../../sdk-web-core/src/store/store" {
|
|
|
743
748
|
moderationPrimaryColor?: string | undefined;
|
|
744
749
|
linkShareIcon?: string | undefined;
|
|
745
750
|
linkShareText?: string | undefined;
|
|
746
|
-
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults
|
|
747
|
-
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK
|
|
748
|
-
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient
|
|
751
|
+
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults;
|
|
752
|
+
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK;
|
|
753
|
+
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient;
|
|
749
754
|
publicName?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").PublicName | undefined;
|
|
750
755
|
analyticsVersion?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").AnalyticsVersion | undefined;
|
|
751
756
|
} | undefined, import("@nanostores/query").FetcherStore<{
|
|
@@ -761,13 +766,13 @@ declare module "../../sdk-web-core/src/store/store" {
|
|
|
761
766
|
moderationPrimaryColor?: string | undefined;
|
|
762
767
|
linkShareIcon?: string | undefined;
|
|
763
768
|
linkShareText?: string | undefined;
|
|
764
|
-
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults
|
|
765
|
-
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK
|
|
766
|
-
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient
|
|
769
|
+
brandDefaults?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").BrandDefaults;
|
|
770
|
+
pub?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").JWK;
|
|
771
|
+
getstream?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").GetStreamSettingsClient;
|
|
767
772
|
publicName?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").PublicName | undefined;
|
|
768
773
|
analyticsVersion?: import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").AnalyticsVersion | undefined;
|
|
769
774
|
} | undefined, any>>;
|
|
770
|
-
readonly organizationAdvertising: import(
|
|
775
|
+
readonly organizationAdvertising: import("@streamlayer/sdk-web-interfaces").ApiStore<import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").Advertising | undefined, import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/sdkSettings/sdkSettings.common_pb").Advertising | undefined, any>>;
|
|
771
776
|
};
|
|
772
777
|
setValue(): void;
|
|
773
778
|
subscribe: (subscribes: Partial<StoreListeners>) => void;
|
|
@@ -778,7 +783,7 @@ declare module "../../sdk-web-core/src/store/store" {
|
|
|
778
783
|
};
|
|
779
784
|
}
|
|
780
785
|
declare module "../../sdk-web-core/src/deepLink/index" {
|
|
781
|
-
import { MapStore, StreamLayerContext } from '
|
|
786
|
+
import { MapStore, StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
782
787
|
type DeepLinkContextData = {
|
|
783
788
|
handled?: boolean;
|
|
784
789
|
parsed?: boolean;
|
|
@@ -822,8 +827,8 @@ declare module "../../sdk-web-core/src/deepLink/index" {
|
|
|
822
827
|
}, done: () => void) => void;
|
|
823
828
|
}
|
|
824
829
|
declare module "../../sdk-web-core/src/auth/bypass/index" {
|
|
825
|
-
import { AbstractAuthenticationProvider } from '
|
|
826
|
-
import { Transport } from '
|
|
830
|
+
import { AbstractAuthenticationProvider } from '@streamlayer/sdk-web-interfaces';
|
|
831
|
+
import { Transport } from '@streamlayer/sdk-web-api';
|
|
827
832
|
import { CoreStore } from "../../sdk-web-core/src/store/store";
|
|
828
833
|
import { DeepLinkContext } from "../../sdk-web-core/src/deepLink/index";
|
|
829
834
|
/**
|
|
@@ -875,7 +880,7 @@ declare module "../../sdk-web-core/src/auth/bypass/index" {
|
|
|
875
880
|
}
|
|
876
881
|
}
|
|
877
882
|
declare module "../../sdk-web-core/src/auth/index" {
|
|
878
|
-
import { StreamLayerContext } from '
|
|
883
|
+
import { StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
879
884
|
import { CoreStores, StoreObj } from "../../sdk-web-core/src/store/store";
|
|
880
885
|
import { UserStorage } from "../../sdk-web-core/src/storage";
|
|
881
886
|
import { BypassAuth } from "../../sdk-web-core/src/auth/bypass/index";
|
|
@@ -899,7 +904,7 @@ declare module "../../sdk-web-core/src/auth/index" {
|
|
|
899
904
|
export const bypass: (instance: StreamLayerContext, opts: unknown, done: () => void) => void;
|
|
900
905
|
}
|
|
901
906
|
declare module "../../sdk-web-core/src/store/index" {
|
|
902
|
-
import { StreamLayerContext } from '
|
|
907
|
+
import { StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
903
908
|
import { CoreStore, CoreStores, StoreObj } from "../../sdk-web-core/src/store/store";
|
|
904
909
|
module '@streamlayer/sdk-web-interfaces' {
|
|
905
910
|
interface StreamLayerSDK {
|
|
@@ -929,7 +934,7 @@ declare module "../../sdk-web-core/src/store/index" {
|
|
|
929
934
|
export const store: (instance: StreamLayerContext, opts: unknown, done: () => void) => void;
|
|
930
935
|
}
|
|
931
936
|
declare module "../../sdk-web-core/src/videoPlayer/index" {
|
|
932
|
-
import { StreamLayerContext } from '
|
|
937
|
+
import { StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
933
938
|
export type VideoPlayerData = {
|
|
934
939
|
muted: boolean;
|
|
935
940
|
};
|
|
@@ -952,7 +957,7 @@ declare module "../../sdk-web-core/src/videoPlayer/index" {
|
|
|
952
957
|
}, done: () => void) => void;
|
|
953
958
|
}
|
|
954
959
|
declare module "../../sdk-web-core/src/index" {
|
|
955
|
-
import { StreamLayerContext } from '
|
|
960
|
+
import { StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
956
961
|
export { bypass, storage } from "../../sdk-web-core/src/auth/index";
|
|
957
962
|
export { store } from "../../sdk-web-core/src/store/index";
|
|
958
963
|
export { deepLink, type DeepLinkUrlParams, type DeepLinkCallback, type DeepLinkContext, DEEP_LINK_PREFIX, DEEP_LINK_USER_ID, DEEP_LINK_EVENT_ID, DEEP_LINK_EXTERNAL_EVENT_ID, } from "../../sdk-web-core/src/deepLink/index";
|
|
@@ -985,13 +990,11 @@ declare module "../../sdk-web-core/src/index" {
|
|
|
985
990
|
export const core: (instance: StreamLayerContext, opts: unknown, done: () => void) => void;
|
|
986
991
|
}
|
|
987
992
|
declare module "../../react-ui/src/index" {
|
|
988
|
-
export
|
|
989
|
-
sdk: unknown;
|
|
990
|
-
}>;
|
|
993
|
+
export { App } from 'app/app';
|
|
991
994
|
export { StreamLayerThemeProvider } from 'ui/theme';
|
|
992
995
|
}
|
|
993
996
|
declare module "../../sdk-web-notifications/src/queue/index" {
|
|
994
|
-
import { SingleStore, createComputedStore } from '
|
|
997
|
+
import { SingleStore, createComputedStore } from '@streamlayer/sdk-web-interfaces';
|
|
995
998
|
import { Notification } from "../../sdk-web-notifications/src/index";
|
|
996
999
|
export type NotificationsQueueOptions = {
|
|
997
1000
|
concurrency: number;
|
|
@@ -1017,7 +1020,7 @@ declare module "../../sdk-web-notifications/src/queue/index" {
|
|
|
1017
1020
|
}
|
|
1018
1021
|
}
|
|
1019
1022
|
declare module "../../sdk-web-notifications/src/storage" {
|
|
1020
|
-
import { Storage } from '
|
|
1023
|
+
import { Storage } from '@streamlayer/sdk-web-storage';
|
|
1021
1024
|
export class NotificationStorage extends Storage {
|
|
1022
1025
|
constructor();
|
|
1023
1026
|
setOpened: (notificationId: string) => void;
|
|
@@ -1026,7 +1029,7 @@ declare module "../../sdk-web-notifications/src/storage" {
|
|
|
1026
1029
|
}
|
|
1027
1030
|
}
|
|
1028
1031
|
declare module "../../sdk-web-notifications/src/notifications" {
|
|
1029
|
-
import { InstantView, QuestionType, GameSettings, TweetHistory } from '
|
|
1032
|
+
import { InstantView, QuestionType, GameSettings, TweetHistory } from '@streamlayer/sdk-web-types';
|
|
1030
1033
|
import { NotificationsQueue, NotificationsQueueOptions } from "../../sdk-web-notifications/src/queue/index";
|
|
1031
1034
|
export type NotificationData = {
|
|
1032
1035
|
questionId: string;
|
|
@@ -1093,7 +1096,7 @@ declare module "../../sdk-web-notifications/src/notifications" {
|
|
|
1093
1096
|
}
|
|
1094
1097
|
}
|
|
1095
1098
|
declare module "../../sdk-web-notifications/src/index" {
|
|
1096
|
-
import { StreamLayerContext } from '
|
|
1099
|
+
import { StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
1097
1100
|
import { Notifications } from "../../sdk-web-notifications/src/notifications";
|
|
1098
1101
|
export { type Notification, type NotificationData, NotificationType, Notifications } from "../../sdk-web-notifications/src/notifications";
|
|
1099
1102
|
export { type NotificationsList } from "../../sdk-web-notifications/src/queue/index";
|
|
@@ -1114,7 +1117,7 @@ declare module "../../sdk-web-notifications/src/index" {
|
|
|
1114
1117
|
export const notifications: (instance: StreamLayerContext, opts: unknown, done: () => void) => void;
|
|
1115
1118
|
}
|
|
1116
1119
|
declare module "../../feature-gamification/src/queries/leaderboard" {
|
|
1117
|
-
import type { Transport } from '
|
|
1120
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1118
1121
|
import { ReadableAtom } from 'nanostores';
|
|
1119
1122
|
import { ListRequest, SummaryRequest } from '@streamlayer/sl-eslib/interactive/leaderboard/interactive.leaderboard_pb';
|
|
1120
1123
|
import { PartialMessage } from '@bufbuild/protobuf';
|
|
@@ -1125,17 +1128,17 @@ declare module "../../feature-gamification/src/queries/leaderboard" {
|
|
|
1125
1128
|
export const createUserSummaryFetch: (transport: Transport) => (params: PartialMessage<SummaryRequest>) => Promise<import("@streamlayer/sl-eslib/interactive/leaderboard/interactive.leaderboard_pb").SummaryResponse>;
|
|
1126
1129
|
}
|
|
1127
1130
|
declare module "../../feature-gamification/src/queries/friends" {
|
|
1128
|
-
import type { Transport } from '
|
|
1131
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1129
1132
|
import { ReadableAtom } from 'nanostores';
|
|
1130
1133
|
export const $friends: ($userId: ReadableAtom<string | undefined>, transport: Transport) => import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/users/users_pb").GetFriendsResponse_FriendData[], any>;
|
|
1131
1134
|
}
|
|
1132
1135
|
declare module "../../feature-gamification/src/queries/moderation" {
|
|
1133
|
-
import type { Transport } from '
|
|
1136
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1134
1137
|
import { ReadableAtom } from 'nanostores';
|
|
1135
1138
|
export const $moderation: (slStreamId: ReadableAtom<string | undefined>, transport: Transport) => import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").InteractiveFeed | undefined, any>;
|
|
1136
1139
|
}
|
|
1137
1140
|
declare module "../../feature-gamification/src/queries/index" {
|
|
1138
|
-
import type { Transport } from '
|
|
1141
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1139
1142
|
import { ReadableAtom } from 'nanostores';
|
|
1140
1143
|
import type { SubscriptionRequest, SubscriptionResponse, VotingSubscriptionRequest, VotingSubscriptionResponse, QuestionSubscriptionRequest, QuestionSubscriptionResponse } from '@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb';
|
|
1141
1144
|
import { InteractiveAllowed } from "../../feature-gamification/src/background";
|
|
@@ -1246,7 +1249,7 @@ declare module "../../feature-gamification/src/queries/index" {
|
|
|
1246
1249
|
readonly kind: import("@bufbuild/protobuf").MethodKind.ServerStreaming;
|
|
1247
1250
|
};
|
|
1248
1251
|
};
|
|
1249
|
-
}, SubscriptionRequest, SubscriptionResponse, "subscription" | "votingSubscription" | "questionSubscription" | "feedSubscription", ((request: import("@bufbuild/protobuf").PartialMessage<SubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions
|
|
1252
|
+
}, SubscriptionRequest, SubscriptionResponse, "subscription" | "votingSubscription" | "questionSubscription" | "feedSubscription", ((request: import("@bufbuild/protobuf").PartialMessage<SubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<SubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<VotingSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<VotingSubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<QuestionSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<QuestionSubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedSubscriptionResponse>)>;
|
|
1250
1253
|
export const votingSubscription: (params: {
|
|
1251
1254
|
questionId: string;
|
|
1252
1255
|
feedId: string;
|
|
@@ -1356,7 +1359,7 @@ declare module "../../feature-gamification/src/queries/index" {
|
|
|
1356
1359
|
readonly kind: import("@bufbuild/protobuf").MethodKind.ServerStreaming;
|
|
1357
1360
|
};
|
|
1358
1361
|
};
|
|
1359
|
-
}, VotingSubscriptionRequest, VotingSubscriptionResponse, "subscription" | "votingSubscription" | "questionSubscription" | "feedSubscription", ((request: import("@bufbuild/protobuf").PartialMessage<SubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions
|
|
1362
|
+
}, VotingSubscriptionRequest, VotingSubscriptionResponse, "subscription" | "votingSubscription" | "questionSubscription" | "feedSubscription", ((request: import("@bufbuild/protobuf").PartialMessage<SubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<SubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<VotingSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<VotingSubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<QuestionSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<QuestionSubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedSubscriptionResponse>)>;
|
|
1360
1363
|
export const questionSubscription: (questionId: string, transport: Transport) => import("../../../sdk-web-api/src/grpc/subscription").ServerStreamSubscription<import("@bufbuild/protobuf").ServiceType, import("@bufbuild/protobuf").Message<import("@bufbuild/protobuf").AnyMessage>, import("@bufbuild/protobuf").Message<import("@bufbuild/protobuf").AnyMessage>, never, never> | import("../../../sdk-web-api/src/grpc/subscription").ServerStreamSubscription<{
|
|
1361
1364
|
readonly typeName: "streamlayer.interactive.feed.Feed";
|
|
1362
1365
|
readonly methods: {
|
|
@@ -1463,10 +1466,11 @@ declare module "../../feature-gamification/src/queries/index" {
|
|
|
1463
1466
|
readonly kind: import("@bufbuild/protobuf").MethodKind.ServerStreaming;
|
|
1464
1467
|
};
|
|
1465
1468
|
};
|
|
1466
|
-
}, QuestionSubscriptionRequest, QuestionSubscriptionResponse, "subscription" | "votingSubscription" | "questionSubscription" | "feedSubscription", ((request: import("@bufbuild/protobuf").PartialMessage<SubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions
|
|
1469
|
+
}, QuestionSubscriptionRequest, QuestionSubscriptionResponse, "subscription" | "votingSubscription" | "questionSubscription" | "feedSubscription", ((request: import("@bufbuild/protobuf").PartialMessage<SubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<SubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<VotingSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<VotingSubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<QuestionSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<QuestionSubscriptionResponse>) | ((request: import("@bufbuild/protobuf").PartialMessage<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedSubscriptionRequest>, options?: import("@connectrpc/connect").CallOptions) => AsyncIterable<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedSubscriptionResponse>)>;
|
|
1467
1470
|
export const getQuestionByUser: (questionId: string, transport: Transport) => Promise<import("@streamlayer/sl-eslib/interactive/interactive.common_pb").ExtendedQuestion | undefined>;
|
|
1468
1471
|
export const getQuestionDetail: (questionId: string, transport: Transport) => Promise<import("@streamlayer/sl-eslib/interactive/interactive.common_pb").Question | undefined>;
|
|
1469
1472
|
export const $questionByUser: ($questionId: ReadableAtom<string | undefined> | string, transport: Transport) => import("@nanostores/query").FetcherStore<import("@bufbuild/protobuf").PlainMessage<import("@streamlayer/sl-eslib/interactive/interactive.common_pb").ExtendedQuestion>, any>;
|
|
1473
|
+
export const getPromotionDetail: (promoId: string, transport: Transport) => Promise<import("@streamlayer/sl-eslib/interactive/interactive.common_pb").QuestionOptions_PromotionOptions | undefined>;
|
|
1470
1474
|
export const $pickHistory: (slStreamId: ReadableAtom<string | undefined>, transport: Transport) => import("@nanostores/query").FetcherStore<(import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").PickHistory | undefined)[], any>;
|
|
1471
1475
|
export const $feedList: ($slStreamId: ReadableAtom<string | undefined>, $interactiveAllowed: ReadableAtom<InteractiveAllowed>, transport: Transport) => import("@nanostores/query").FetcherStore<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedItem[], any>;
|
|
1472
1476
|
export { $userSummary, $leaderboardList } from "../../feature-gamification/src/queries/leaderboard";
|
|
@@ -1474,31 +1478,105 @@ declare module "../../feature-gamification/src/queries/index" {
|
|
|
1474
1478
|
export { $moderation } from "../../feature-gamification/src/queries/moderation";
|
|
1475
1479
|
}
|
|
1476
1480
|
declare module "../../feature-gamification/src/detail" {
|
|
1477
|
-
import type { Transport } from '
|
|
1478
|
-
import { FeedItem, ExtendedQuestion } from '
|
|
1481
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1482
|
+
import { FeedItem, ExtendedQuestion } from '@streamlayer/sdk-web-types';
|
|
1479
1483
|
import { ReadableAtom } from 'nanostores';
|
|
1480
1484
|
import { type GamificationBackground } from "../../feature-gamification/src/background";
|
|
1481
1485
|
export const detail: (transport: Transport, $openedQuestionId: ReadableAtom<{
|
|
1482
1486
|
questionId: string;
|
|
1483
1487
|
question?: FeedItem & {
|
|
1484
|
-
openedFrom?:
|
|
1488
|
+
openedFrom?: "list" | "notification";
|
|
1485
1489
|
};
|
|
1486
|
-
} | undefined>, $feedList: ReturnType<GamificationBackground[
|
|
1490
|
+
} | undefined>, $feedList: ReturnType<GamificationBackground["feedList"]["getStore"]>) => {
|
|
1487
1491
|
$store: ReadableAtom<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedItem | (import("@bufbuild/protobuf").PlainMessage<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").FeedItem> & {
|
|
1488
|
-
openedFrom?: "list" | "notification"
|
|
1492
|
+
openedFrom?: "list" | "notification";
|
|
1489
1493
|
}) | undefined>;
|
|
1490
1494
|
$extendedStore: import("@nanostores/query").FetcherStore<import("@bufbuild/protobuf").PlainMessage<import("@streamlayer/sl-eslib/interactive/interactive.common_pb").ExtendedQuestion>, any>;
|
|
1491
1495
|
updateExtendedQuestion: (question: ExtendedQuestion | undefined) => void;
|
|
1492
1496
|
};
|
|
1493
1497
|
}
|
|
1498
|
+
declare module "../../feature-gamification/src/advertisement/storage" {
|
|
1499
|
+
import { Storage } from '@streamlayer/sdk-web-storage';
|
|
1500
|
+
export class AdvertisementStorage extends Storage {
|
|
1501
|
+
constructor();
|
|
1502
|
+
setShowed: (advertId: string) => void;
|
|
1503
|
+
isShowed: (advertId: string) => string | undefined;
|
|
1504
|
+
}
|
|
1505
|
+
}
|
|
1506
|
+
declare module "../../feature-gamification/src/advertisement/queue" {
|
|
1507
|
+
import { SingleStore, createComputedStore } from '@streamlayer/sdk-web-interfaces';
|
|
1508
|
+
import { Advertisement } from "../../feature-gamification/src/advertisement/index";
|
|
1509
|
+
export type AdvertisementsQueueOptions = {
|
|
1510
|
+
concurrency: number;
|
|
1511
|
+
animationDelay: number;
|
|
1512
|
+
};
|
|
1513
|
+
export type AdvertisementsList = ReturnType<typeof createComputedStore<Advertisement[]>>;
|
|
1514
|
+
export class AdvertisementsQueue {
|
|
1515
|
+
advertisementList: ReturnType<SingleStore<Map<Advertisement['id'], Advertisement>>['getStore']>;
|
|
1516
|
+
private store;
|
|
1517
|
+
private timeouts;
|
|
1518
|
+
private waitingQueue;
|
|
1519
|
+
private activeQueue;
|
|
1520
|
+
private options;
|
|
1521
|
+
private logger;
|
|
1522
|
+
constructor(options: AdvertisementsQueueOptions);
|
|
1523
|
+
addToQueue: (advertisement: Advertisement) => void;
|
|
1524
|
+
tickWaitingQueue: () => void;
|
|
1525
|
+
tickActiveQueue: (advertisementId: string) => void;
|
|
1526
|
+
closeAdvertisement: (advertisementId: string, { animateHiding }?: {
|
|
1527
|
+
animateHiding?: boolean | undefined;
|
|
1528
|
+
}) => Advertisement | undefined;
|
|
1529
|
+
drain: () => void;
|
|
1530
|
+
}
|
|
1531
|
+
}
|
|
1532
|
+
declare module "../../feature-gamification/src/advertisement/index" {
|
|
1533
|
+
import { createMapStore } from '@streamlayer/sdk-web-interfaces';
|
|
1534
|
+
import { PromotionOptions } from '@streamlayer/sdk-web-types';
|
|
1535
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1536
|
+
import { type GamificationBackground } from "../../feature-gamification/src/background";
|
|
1537
|
+
type AdvertisementData = {
|
|
1538
|
+
loading?: boolean;
|
|
1539
|
+
error?: unknown;
|
|
1540
|
+
data?: PromotionOptions;
|
|
1541
|
+
};
|
|
1542
|
+
export type Advertisement = {
|
|
1543
|
+
autoHideDuration: number;
|
|
1544
|
+
delay?: number;
|
|
1545
|
+
hiding?: boolean;
|
|
1546
|
+
action?: (...args: unknown[]) => void;
|
|
1547
|
+
close?: (...args: unknown[]) => void;
|
|
1548
|
+
data: ReturnType<typeof createMapStore<AdvertisementData>>;
|
|
1549
|
+
promise: () => Promise<void>;
|
|
1550
|
+
id: string;
|
|
1551
|
+
};
|
|
1552
|
+
/**
|
|
1553
|
+
* @name Advertisement
|
|
1554
|
+
* @description advertisement functionality, show, hide
|
|
1555
|
+
* - show: show advertisement by id, if it was not showed before
|
|
1556
|
+
* - hide: hide advertisement by id
|
|
1557
|
+
* - markAsViewed: mark advertisement as viewed, called when UI is requested to show advertisement
|
|
1558
|
+
* - getActiveAdvertisement: request active advertisement from queue by UI
|
|
1559
|
+
*
|
|
1560
|
+
* On mount:
|
|
1561
|
+
* - we subscribe to $feedList, and show last advertisement from list
|
|
1562
|
+
* - we subscribe to $feedSubscription, and show advertisement on activate
|
|
1563
|
+
*/
|
|
1564
|
+
export const advertisement: ($feedList: GamificationBackground["feedList"], $feedSubscription: GamificationBackground["feedSubscription"], transport: Transport) => {
|
|
1565
|
+
hide: (notificationId: string) => void;
|
|
1566
|
+
show: (advertisementId: string) => void;
|
|
1567
|
+
$list: import("nanostores").WritableAtom<Map<string, Advertisement> | undefined>;
|
|
1568
|
+
getActiveAdvertisement: () => Advertisement | null;
|
|
1569
|
+
};
|
|
1570
|
+
}
|
|
1494
1571
|
declare module "../../feature-gamification/src/background" {
|
|
1495
|
-
import { ApiStore, type StreamLayerContext } from '
|
|
1496
|
-
import type { GetApiResponseType } from '
|
|
1497
|
-
import { FeedItem } from '
|
|
1572
|
+
import { ApiStore, type StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
1573
|
+
import type { GetApiResponseType } from '@streamlayer/sdk-web-api';
|
|
1574
|
+
import { FeedItem } from '@streamlayer/sdk-web-types';
|
|
1498
1575
|
import '@streamlayer/sdk-web-core/store';
|
|
1499
1576
|
import { ReadableAtom, WritableAtom } from 'nanostores';
|
|
1500
1577
|
import * as queries from "../../feature-gamification/src/queries/index";
|
|
1501
1578
|
import { detail } from "../../feature-gamification/src/detail";
|
|
1579
|
+
import { advertisement } from "../../feature-gamification/src/advertisement/index";
|
|
1502
1580
|
export enum InteractiveAllowed {
|
|
1503
1581
|
ALLOWED = "allowed",
|
|
1504
1582
|
DISALLOWED = "disallowed"
|
|
@@ -1538,6 +1616,7 @@ declare module "../../feature-gamification/src/background" {
|
|
|
1538
1616
|
feedSubscription: ReturnType<typeof queries.feedSubscription>;
|
|
1539
1617
|
/** subscription to opened question (vote percentage) */
|
|
1540
1618
|
questionSubscription?: ReturnType<typeof queries.questionSubscription>;
|
|
1619
|
+
advertisement: ReturnType<typeof advertisement>;
|
|
1541
1620
|
private notifications;
|
|
1542
1621
|
private log;
|
|
1543
1622
|
private transport;
|
|
@@ -1563,7 +1642,7 @@ declare module "../../feature-gamification/src/background" {
|
|
|
1563
1642
|
* Open question and mark notification for this question as viewed
|
|
1564
1643
|
*/
|
|
1565
1644
|
openQuestion: (questionId: string, question?: FeedItem & {
|
|
1566
|
-
openedFrom?:
|
|
1645
|
+
openedFrom?: "list" | "notification";
|
|
1567
1646
|
}) => void;
|
|
1568
1647
|
/**
|
|
1569
1648
|
* Close question and mark notification for this question as viewed
|
|
@@ -1578,7 +1657,7 @@ declare module "../../feature-gamification/src/constants" {
|
|
|
1578
1657
|
}
|
|
1579
1658
|
}
|
|
1580
1659
|
declare module "../../feature-gamification/src/queries/actions" {
|
|
1581
|
-
import type { Transport } from '
|
|
1660
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1582
1661
|
export const submitAnswer: (transport: Transport, data: {
|
|
1583
1662
|
questionId: string;
|
|
1584
1663
|
answerId: string;
|
|
@@ -1587,8 +1666,8 @@ declare module "../../feature-gamification/src/queries/actions" {
|
|
|
1587
1666
|
export const skipQuestion: (transport: Transport, questionId: string) => Promise<import("@streamlayer/sl-eslib/interactive/feed/interactive.feed_pb").SkipQuestionResponse>;
|
|
1588
1667
|
}
|
|
1589
1668
|
declare module "../../feature-gamification/src/onboarding" {
|
|
1590
|
-
import { Transport } from '
|
|
1591
|
-
import { type Notifications } from '
|
|
1669
|
+
import { Transport } from '@streamlayer/sdk-web-api';
|
|
1670
|
+
import { type Notifications } from '@streamlayer/sdk-web-notifications';
|
|
1592
1671
|
import { GamificationBackground } from "../../feature-gamification/src/background";
|
|
1593
1672
|
import { Gamification } from "../../feature-gamification/src/index";
|
|
1594
1673
|
/**
|
|
@@ -1612,7 +1691,7 @@ declare module "../../feature-gamification/src/onboarding" {
|
|
|
1612
1691
|
};
|
|
1613
1692
|
}
|
|
1614
1693
|
declare module "../../feature-gamification/src/storage" {
|
|
1615
|
-
import { Storage } from '
|
|
1694
|
+
import { Storage } from '@streamlayer/sdk-web-storage';
|
|
1616
1695
|
import { OnboardingStatus } from "../../feature-gamification/src/onboarding";
|
|
1617
1696
|
type UserProps = {
|
|
1618
1697
|
userId: string;
|
|
@@ -1629,7 +1708,7 @@ declare module "../../feature-gamification/src/storage" {
|
|
|
1629
1708
|
}
|
|
1630
1709
|
}
|
|
1631
1710
|
declare module "../../feature-gamification/src/leaderboard" {
|
|
1632
|
-
import type { Transport } from '
|
|
1711
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1633
1712
|
import { ReadableAtom } from 'nanostores';
|
|
1634
1713
|
import { type LeaderboardItem } from "../../feature-gamification/src/queries/leaderboard";
|
|
1635
1714
|
import { Gamification } from "../../feature-gamification/src/index";
|
|
@@ -1645,14 +1724,14 @@ declare module "../../feature-gamification/src/leaderboard" {
|
|
|
1645
1724
|
hasMore: boolean;
|
|
1646
1725
|
error?: string;
|
|
1647
1726
|
};
|
|
1648
|
-
export const leaderboard: (transport: Transport, $eventId: ReadableAtom<string | undefined>, $userId: ReadableAtom<string | undefined>, $friends: Gamification[
|
|
1727
|
+
export const leaderboard: (transport: Transport, $eventId: ReadableAtom<string | undefined>, $userId: ReadableAtom<string | undefined>, $friends: Gamification["friends"], options?: LeaderboardOptions) => {
|
|
1649
1728
|
$store: import("nanostores").MapStore<LeaderboardStore>;
|
|
1650
1729
|
fetchMore: (page?: number) => void;
|
|
1651
1730
|
invalidate: () => void;
|
|
1652
1731
|
};
|
|
1653
1732
|
}
|
|
1654
1733
|
declare module "../../feature-gamification/src/queries/deepLink" {
|
|
1655
|
-
import type { Transport } from '
|
|
1734
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1656
1735
|
import { ReadableAtom } from 'nanostores';
|
|
1657
1736
|
import { DeepLink } from '@streamlayer/sl-eslib/sdkSettings/client/client_pb';
|
|
1658
1737
|
type EventId = ReadableAtom<string | undefined>;
|
|
@@ -1664,7 +1743,7 @@ declare module "../../feature-gamification/src/queries/deepLink" {
|
|
|
1664
1743
|
}) => Promise<import("@streamlayer/sl-eslib/shortLinks/linksClient_pb").GenerateResponse>;
|
|
1665
1744
|
}
|
|
1666
1745
|
declare module "../../feature-gamification/src/deepLink" {
|
|
1667
|
-
import type { Transport } from '
|
|
1746
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1668
1747
|
import { ReadableAtom } from 'nanostores';
|
|
1669
1748
|
type DeepLinkData = {
|
|
1670
1749
|
data?: string;
|
|
@@ -1677,26 +1756,26 @@ declare module "../../feature-gamification/src/deepLink" {
|
|
|
1677
1756
|
};
|
|
1678
1757
|
}
|
|
1679
1758
|
declare module "../../feature-gamification/src/userSummary" {
|
|
1680
|
-
import type { Transport } from '
|
|
1759
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1681
1760
|
import { ReadableAtom } from 'nanostores';
|
|
1682
1761
|
import { LeaderboardSummaryItem } from '@streamlayer/sl-eslib/interactive/leaderboard/interactive.leaderboard_pb';
|
|
1683
1762
|
import { Gamification } from "../../feature-gamification/src/index";
|
|
1684
|
-
export const summary: ($eventId: ReadableAtom<string | undefined>, $userId: ReadableAtom<string | undefined>, $friends: Gamification[
|
|
1763
|
+
export const summary: ($eventId: ReadableAtom<string | undefined>, $userId: ReadableAtom<string | undefined>, $friends: Gamification["friends"], transport: Transport) => {
|
|
1685
1764
|
$store: import("nanostores").MapStore<LeaderboardSummaryItem | undefined>;
|
|
1686
1765
|
invalidate: () => void;
|
|
1687
1766
|
};
|
|
1688
1767
|
}
|
|
1689
1768
|
declare module "../../feature-gamification/src/friendSummary" {
|
|
1690
|
-
import type { Transport } from '
|
|
1769
|
+
import type { Transport } from '@streamlayer/sdk-web-api';
|
|
1691
1770
|
import { ReadableAtom } from 'nanostores';
|
|
1692
1771
|
import { LeaderboardItem } from '@streamlayer/sl-eslib/interactive/leaderboard/interactive.leaderboard_pb';
|
|
1693
1772
|
import { Gamification } from "../../feature-gamification/src/index";
|
|
1694
|
-
export const friendSummary: ($eventId: ReadableAtom<string | undefined>, $userId: ReadableAtom<string | undefined>, $friends: Gamification[
|
|
1773
|
+
export const friendSummary: ($eventId: ReadableAtom<string | undefined>, $userId: ReadableAtom<string | undefined>, $friends: Gamification["friends"], friendId: string, transport: Transport) => Promise<LeaderboardItem | undefined>;
|
|
1695
1774
|
}
|
|
1696
1775
|
declare module "../../feature-gamification/src/gamification" {
|
|
1697
|
-
import { AbstractFeature, ApiStore, FeatureSource, type FeatureProps, type StreamLayerContext } from '
|
|
1698
|
-
import { type GamesOverlaySettings, FeedItem } from '
|
|
1699
|
-
import type { GetApiResponseType } from '
|
|
1776
|
+
import { AbstractFeature, ApiStore, FeatureSource, type FeatureProps, type StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
1777
|
+
import { type GamesOverlaySettings, FeedItem } from '@streamlayer/sdk-web-types';
|
|
1778
|
+
import type { GetApiResponseType } from '@streamlayer/sdk-web-api';
|
|
1700
1779
|
import '@streamlayer/sdk-web-core/store';
|
|
1701
1780
|
import type { PlainMessage } from '@bufbuild/protobuf';
|
|
1702
1781
|
import { WritableAtom } from 'nanostores';
|
|
@@ -1744,6 +1823,7 @@ declare module "../../feature-gamification/src/gamification" {
|
|
|
1744
1823
|
feedSubscription: GamificationBackground['feedSubscription'];
|
|
1745
1824
|
activeQuestionId: GamificationBackground['activeQuestionId'];
|
|
1746
1825
|
openedQuestionId: GamificationBackground['openedQuestionId'];
|
|
1826
|
+
advertisement: GamificationBackground['advertisement'];
|
|
1747
1827
|
private notifications;
|
|
1748
1828
|
private transport;
|
|
1749
1829
|
/** gamification background class, handle subscriptions and notifications for closed overlay */
|
|
@@ -1759,7 +1839,7 @@ declare module "../../feature-gamification/src/gamification" {
|
|
|
1759
1839
|
disconnect: () => void;
|
|
1760
1840
|
submitAnswer: (questionId: string, answerId: string) => Promise<void>;
|
|
1761
1841
|
openQuestion: (questionId?: string, question?: FeedItem & {
|
|
1762
|
-
openedFrom?:
|
|
1842
|
+
openedFrom?: "list" | "notification";
|
|
1763
1843
|
}) => void | (() => void);
|
|
1764
1844
|
closeQuestion: (questionId?: string) => void;
|
|
1765
1845
|
openUser: (friendId: string) => Promise<void>;
|
|
@@ -1776,6 +1856,7 @@ declare module "../../feature-gamification/src/gamification" {
|
|
|
1776
1856
|
declare module "../../feature-gamification/src/index" {
|
|
1777
1857
|
export { GamificationBackground } from "../../feature-gamification/src/background";
|
|
1778
1858
|
export { Gamification } from "../../feature-gamification/src/gamification";
|
|
1859
|
+
export { Advertisement } from "../../feature-gamification/src/advertisement/index";
|
|
1779
1860
|
module '@streamlayer/sdk-web-interfaces' {
|
|
1780
1861
|
interface StreamLayerContext {
|
|
1781
1862
|
gamification: import("../../feature-gamification/src/background").GamificationBackground;
|
|
@@ -1783,9 +1864,9 @@ declare module "../../feature-gamification/src/index" {
|
|
|
1783
1864
|
}
|
|
1784
1865
|
}
|
|
1785
1866
|
declare module "../../sdk-web-features/src/index" {
|
|
1786
|
-
import { FeatureType } from '
|
|
1787
|
-
import { AbstractFeature, FeatureSource, FeatureProps, StreamLayerContext, SingleStore } from '
|
|
1788
|
-
import { Gamification } from '
|
|
1867
|
+
import { FeatureType } from '@streamlayer/sdk-web-types';
|
|
1868
|
+
import { AbstractFeature, FeatureSource, FeatureProps, StreamLayerContext, SingleStore } from '@streamlayer/sdk-web-interfaces';
|
|
1869
|
+
import { Gamification } from '@streamlayer/feature-gamification';
|
|
1789
1870
|
export type Features = Feature | Gamification;
|
|
1790
1871
|
export const AvailableFeatures: {
|
|
1791
1872
|
12: boolean;
|
|
@@ -1794,7 +1875,7 @@ declare module "../../sdk-web-features/src/index" {
|
|
|
1794
1875
|
constructor(overlay: FeatureProps, source: FeatureSource);
|
|
1795
1876
|
}
|
|
1796
1877
|
export const initFeature: (overlay: FeatureProps, source: FeatureSource, instance: StreamLayerContext) => Gamification | Feature;
|
|
1797
|
-
export { FeatureSource } from '
|
|
1878
|
+
export { FeatureSource } from '@streamlayer/sdk-web-interfaces';
|
|
1798
1879
|
module '@streamlayer/sdk-web-interfaces' {
|
|
1799
1880
|
interface StreamLayerContext {
|
|
1800
1881
|
features: Map<FeatureType, Features>;
|
|
@@ -1822,7 +1903,7 @@ declare module "../../sdk-web-analytics/src/invitation" {
|
|
|
1822
1903
|
constructor(analytics: Analytics);
|
|
1823
1904
|
accepted: () => void;
|
|
1824
1905
|
sent: ({ from }: {
|
|
1825
|
-
from?: InvitationFrom
|
|
1906
|
+
from?: InvitationFrom;
|
|
1826
1907
|
}) => void;
|
|
1827
1908
|
}
|
|
1828
1909
|
}
|
|
@@ -1892,7 +1973,7 @@ declare module "../../sdk-web-analytics/src/notifications" {
|
|
|
1892
1973
|
}
|
|
1893
1974
|
}
|
|
1894
1975
|
declare module "../../sdk-web-analytics/src/polls" {
|
|
1895
|
-
import { QuestionType } from '
|
|
1976
|
+
import { QuestionType } from '@streamlayer/sdk-web-types';
|
|
1896
1977
|
import { Analytics } from "../../sdk-web-analytics/src/analytics";
|
|
1897
1978
|
/**
|
|
1898
1979
|
* PollsAnalytics is a class that is used to send analytics events related to polls.
|
|
@@ -1902,24 +1983,24 @@ declare module "../../sdk-web-analytics/src/polls" {
|
|
|
1902
1983
|
private analytics;
|
|
1903
1984
|
constructor(analytics: Analytics);
|
|
1904
1985
|
received: ({ questionId, questionType }: {
|
|
1905
|
-
questionId?: string
|
|
1906
|
-
questionType?: QuestionType
|
|
1986
|
+
questionId?: string;
|
|
1987
|
+
questionType?: QuestionType;
|
|
1907
1988
|
}) => void;
|
|
1908
1989
|
opened: ({ questionId, questionType, questionOpenedFrom, }: {
|
|
1909
|
-
questionId?: string
|
|
1910
|
-
questionType?: QuestionType
|
|
1911
|
-
questionOpenedFrom?: "list" | "notification"
|
|
1990
|
+
questionId?: string;
|
|
1991
|
+
questionType?: QuestionType;
|
|
1992
|
+
questionOpenedFrom?: "list" | "notification";
|
|
1912
1993
|
}) => void;
|
|
1913
1994
|
voted: ({ questionId, questionType }: {
|
|
1914
|
-
questionId?: string
|
|
1915
|
-
questionType?: QuestionType
|
|
1995
|
+
questionId?: string;
|
|
1996
|
+
questionType?: QuestionType;
|
|
1916
1997
|
}) => void;
|
|
1917
1998
|
onboardingPassed: () => void;
|
|
1918
1999
|
navigated: () => void;
|
|
1919
2000
|
}
|
|
1920
2001
|
}
|
|
1921
2002
|
declare module "../../sdk-web-analytics/src/heartbeat" {
|
|
1922
|
-
import { Transport } from '
|
|
2003
|
+
import { Transport } from '@streamlayer/sdk-web-api';
|
|
1923
2004
|
import { Analytics } from "../../sdk-web-analytics/src/analytics";
|
|
1924
2005
|
type IHeartbeat = {
|
|
1925
2006
|
transport: Transport;
|
|
@@ -1933,14 +2014,15 @@ declare module "../../sdk-web-analytics/src/heartbeat" {
|
|
|
1933
2014
|
};
|
|
1934
2015
|
}
|
|
1935
2016
|
declare module "../../sdk-web-analytics/src/analytics" {
|
|
1936
|
-
import { MapStore, StreamLayerContext, OnMountCb } from '
|
|
1937
|
-
import { Logger } from '
|
|
2017
|
+
import { MapStore, StreamLayerContext, OnMountCb } from '@streamlayer/sdk-web-interfaces';
|
|
2018
|
+
import { Logger } from '@streamlayer/sdk-web-logger';
|
|
1938
2019
|
import { GamesMessage, NotificationMessage, SendInvitationsMessage, EventOpenedMessage, SendInteractionsMessage, CommonData } from '@streamlayer/sl-eslib/analytics/v2/streaming/streaming_pb';
|
|
1939
2020
|
import { PlainMessage } from '@bufbuild/protobuf';
|
|
1940
2021
|
import { InvitationAnalytics } from "../../sdk-web-analytics/src/invitation";
|
|
1941
2022
|
import { InteractionsAnalytics } from "../../sdk-web-analytics/src/interactions";
|
|
1942
2023
|
import { NotificationsAnalytics } from "../../sdk-web-analytics/src/notifications";
|
|
1943
2024
|
import { PollsAnalytics } from "../../sdk-web-analytics/src/polls";
|
|
2025
|
+
import { AllowedCases } from "../../sdk-web-analytics/src/constants";
|
|
1944
2026
|
import '@streamlayer/sdk-web-features';
|
|
1945
2027
|
type AnalyticsMessages = {
|
|
1946
2028
|
games?: PlainMessage<GamesMessage>;
|
|
@@ -1975,16 +2057,16 @@ declare module "../../sdk-web-analytics/src/analytics" {
|
|
|
1975
2057
|
constructor(instance: StreamLayerContext);
|
|
1976
2058
|
connect: () => void;
|
|
1977
2059
|
disconnect: () => void;
|
|
1978
|
-
write: <T extends
|
|
1979
|
-
writeCommon: <T extends
|
|
2060
|
+
write: <T extends keyof typeof AllowedCases = "notification" | "invitation" | "interactions" | "games" | "eventOpened">(key: T, value: AnalyticsMessages[T]) => void;
|
|
2061
|
+
writeCommon: <T extends keyof PlainMessage<CommonData> = "eventId" | "category" | "kind" | "screenOrientation" | "sessionId" | "overlaySessionId" | "topicId" | "topicType" | "parentTopicId" | "parentTopicType" | "participantsCount" | "routeMap" | "trackTimestamp" | "topicSubType" | "country">(key: T, value: PlainMessage<CommonData>[T]) => void;
|
|
1980
2062
|
onConnect: (cb: OnMountCb) => void;
|
|
1981
2063
|
private connectToSDK;
|
|
1982
2064
|
}
|
|
1983
2065
|
}
|
|
1984
2066
|
declare module "../../sdk-web-analytics/src/index" {
|
|
1985
|
-
import { type StreamLayerContext } from '
|
|
1986
|
-
import type { DeepLinkContext } from '
|
|
1987
|
-
import { Transport } from '
|
|
2067
|
+
import { type StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
2068
|
+
import type { DeepLinkContext } from '@streamlayer/sdk-web-core';
|
|
2069
|
+
import { Transport } from '@streamlayer/sdk-web-api';
|
|
1988
2070
|
import { Analytics } from "../../sdk-web-analytics/src/analytics";
|
|
1989
2071
|
module '@streamlayer/sdk-web-interfaces' {
|
|
1990
2072
|
interface StreamLayerContext {
|
|
@@ -1996,8 +2078,8 @@ declare module "../../sdk-web-analytics/src/index" {
|
|
|
1996
2078
|
export const analytics: (instance: StreamLayerContext, opts: unknown, done: Function) => void;
|
|
1997
2079
|
}
|
|
1998
2080
|
declare module "../../sdk-web/src/index" {
|
|
1999
|
-
import { StreamLayerContext } from '
|
|
2000
|
-
import { type DeepLinkCallback, type VideoPlayerCallback } from '
|
|
2081
|
+
import { StreamLayerContext } from '@streamlayer/sdk-web-interfaces';
|
|
2082
|
+
import { type DeepLinkCallback, type VideoPlayerCallback } from '@streamlayer/sdk-web-core';
|
|
2001
2083
|
import avvio from 'avvio';
|
|
2002
2084
|
import './polyfills/raf';
|
|
2003
2085
|
export type StreamLayerInstance = avvio.mixedInstance<StreamLayerContext>;
|
|
@@ -2010,8 +2092,8 @@ declare module "../../sdk-web/src/index" {
|
|
|
2010
2092
|
}): avvio.Avvio<StreamLayerContext>;
|
|
2011
2093
|
}
|
|
2012
2094
|
declare module "app/useStreamLayerApp" {
|
|
2013
|
-
import type { StreamLayerSDK, StreamLayerPlugin } from '
|
|
2014
|
-
import type { DeepLinkCallback, VideoPlayerCallback } from '
|
|
2095
|
+
import type { StreamLayerSDK, StreamLayerPlugin } from '@streamlayer/sdk-web-interfaces';
|
|
2096
|
+
import type { DeepLinkCallback, VideoPlayerCallback } from '@streamlayer/sdk-web-core';
|
|
2015
2097
|
global {
|
|
2016
2098
|
interface Window {
|
|
2017
2099
|
sl: unknown;
|
|
@@ -2019,16 +2101,17 @@ declare module "app/useStreamLayerApp" {
|
|
|
2019
2101
|
}
|
|
2020
2102
|
export const useStreamLayerApp: ({ sdkKey, plugins, production, autoEnable, onDeepLinkHandled, videoPlayerController, }: {
|
|
2021
2103
|
sdkKey: string;
|
|
2022
|
-
plugins?: Set<StreamLayerPlugin
|
|
2023
|
-
production?: boolean
|
|
2024
|
-
autoEnable?: boolean
|
|
2025
|
-
onDeepLinkHandled?: DeepLinkCallback
|
|
2026
|
-
videoPlayerController?: VideoPlayerCallback
|
|
2104
|
+
plugins?: Set<StreamLayerPlugin>;
|
|
2105
|
+
production?: boolean;
|
|
2106
|
+
autoEnable?: boolean;
|
|
2107
|
+
onDeepLinkHandled?: DeepLinkCallback;
|
|
2108
|
+
videoPlayerController?: VideoPlayerCallback;
|
|
2027
2109
|
}) => StreamLayerSDK | null;
|
|
2028
2110
|
}
|
|
2029
2111
|
declare module "app/provider" {
|
|
2030
|
-
import type { StreamLayerSDK, StreamLayerPlugin } from '
|
|
2031
|
-
import type { DeepLinkCallback, VideoPlayerCallback } from '
|
|
2112
|
+
import type { StreamLayerSDK, StreamLayerPlugin } from '@streamlayer/sdk-web-interfaces';
|
|
2113
|
+
import type { DeepLinkCallback, VideoPlayerCallback } from '@streamlayer/sdk-web-core';
|
|
2114
|
+
export type { DeepLinkCallback, VideoPlayerCallback } from '@streamlayer/sdk-web-core';
|
|
2032
2115
|
export enum StreamLayerStatus {
|
|
2033
2116
|
UNSET = 0,
|
|
2034
2117
|
CONNECTED = 1,
|
|
@@ -2050,6 +2133,13 @@ declare module "app/provider" {
|
|
|
2050
2133
|
children: React.ReactNode;
|
|
2051
2134
|
}>;
|
|
2052
2135
|
}
|
|
2136
|
+
declare module "app/app" {
|
|
2137
|
+
import type { StreamLayerSDK } from '@streamlayer/sdk-web-interfaces';
|
|
2138
|
+
export const useStreamLayer: () => StreamLayerSDK | null;
|
|
2139
|
+
export const StreamLayerSDKReact: React.FC<{
|
|
2140
|
+
event: string;
|
|
2141
|
+
}>;
|
|
2142
|
+
}
|
|
2053
2143
|
declare module "app/masters" {
|
|
2054
2144
|
import { Component } from 'react';
|
|
2055
2145
|
import { StreamLayerProps } from "app/provider";
|
|
@@ -2079,25 +2169,18 @@ declare module "app/masters" {
|
|
|
2079
2169
|
render(): string | number | boolean | Iterable<import("react").ReactNode> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
2080
2170
|
}
|
|
2081
2171
|
}
|
|
2082
|
-
declare module "app/app" {
|
|
2083
|
-
import type { StreamLayerSDK } from '../../sdk-web-interfaces/src/index.ts';
|
|
2084
|
-
export const useStreamLayer: () => StreamLayerSDK | null;
|
|
2085
|
-
export const StreamLayerSDKReact: React.FC;
|
|
2086
|
-
}
|
|
2087
2172
|
declare module "app/auth" {
|
|
2088
2173
|
export const StreamLayerLogin: React.FC<{
|
|
2089
2174
|
token: string;
|
|
2090
2175
|
schema: string;
|
|
2091
2176
|
}>;
|
|
2092
2177
|
}
|
|
2093
|
-
declare module "app/points" {
|
|
2094
|
-
export const StreamLayerSDKPoints: () => import("react/jsx-runtime").JSX.Element | null;
|
|
2095
|
-
}
|
|
2096
2178
|
/// <amd-module name="@streamlayer/react/masters" />
|
|
2097
2179
|
declare module "@streamlayer/react/masters" {
|
|
2098
2180
|
export * from "app/masters";
|
|
2099
2181
|
export * from "app/auth";
|
|
2100
|
-
export
|
|
2182
|
+
export { type DeepLinkCallback, type VideoPlayerCallback } from "app/provider";
|
|
2183
|
+
export const StreamLayerSDKPoints: () => import("react/jsx-runtime").JSX.Element | null;
|
|
2101
2184
|
}
|
|
2102
2185
|
declare module "index" {
|
|
2103
2186
|
import '@streamlayer/sdk-web-api';
|
|
@@ -2109,6 +2192,12 @@ declare module "index" {
|
|
|
2109
2192
|
import '@streamlayer/sdk-web-interfaces';
|
|
2110
2193
|
import '@streamlayer/sdk-web-notifications';
|
|
2111
2194
|
import '@streamlayer/feature-gamification';
|
|
2112
|
-
export { StreamLayerProvider } from "app/provider";
|
|
2195
|
+
export { StreamLayerProvider, type DeepLinkCallback, type VideoPlayerCallback } from "app/provider";
|
|
2113
2196
|
export { StreamLayerSDKReact, useStreamLayer } from "app/app";
|
|
2114
2197
|
}
|
|
2198
|
+
declare module "app/advertisement" {
|
|
2199
|
+
export const StreamLayerSDKAdvertisement: React.FC;
|
|
2200
|
+
}
|
|
2201
|
+
declare module "app/points" {
|
|
2202
|
+
export const StreamLayerSDKPoints: () => import("react/jsx-runtime").JSX.Element | null;
|
|
2203
|
+
}
|