@streamscloud/embeddable 16.0.1 → 16.0.2
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/dist/external-api/media-page/index.d.ts +3 -3
- package/dist/external-api/media-page/index.js +1 -1
- package/dist/external-api/short-videos-player/index.d.ts +3 -3
- package/dist/external-api/short-videos-player/index.js +1 -1
- package/dist/external-api/streams-player/index.d.ts +4 -4
- package/dist/external-api/streams-player/index.js +2 -2
- package/dist/media-center/media-center/discover/community-features-localization.js +5 -5
- package/dist/media-center/media-center/discover/discover-view-localization.js +3 -3
- package/dist/media-center/media-center/handlers/media-center-settings-handler.svelte.d.ts +3 -3
- package/dist/media-center/media-center/header/media-center-header-localization.js +8 -8
- package/dist/media-center/media-center/media-center-context.svelte.d.ts +1 -1
- package/dist/media-center/media-center/media-center-settings.svelte.d.ts +2 -2
- package/dist/media-center/media-center/menu/menu-localization.js +6 -6
- package/dist/media-center/media-center/types.d.ts +2 -2
- package/dist/media-page/index.d.ts +4 -4
- package/dist/media-page/index.js +2 -2
- package/dist/posts/post-viewer/post-viewer-localization.js +3 -3
- package/dist/posts/posts-player/cmp.posts-player.svelte.d.ts +2 -2
- package/dist/posts/posts-player/index.d.ts +2 -2
- package/dist/posts/posts-player/posts-player-proxy.svelte.d.ts +2 -2
- package/dist/posts/posts-player/types.d.ts +2 -2
- package/dist/products/product-card/product-card-localization.js +2 -2
- package/dist/short-videos/short-video-card/localization.js +2 -2
- package/dist/streams/layout/element-views/price-stream-element-localization.js +3 -3
- package/dist/streams/layout/element-views/stock-stream-element-localization.js +2 -2
- package/dist/streams/streams-player/cmp.streams-player.svelte.d.ts +2 -2
- package/dist/streams/streams-player/index.d.ts +4 -4
- package/dist/streams/streams-player/index.js +2 -2
- package/dist/streams/streams-player/stream-player-localization.js +2 -2
- package/dist/streams/streams-player/streams-player-proxy.svelte.d.ts +2 -2
- package/dist/streams/streams-player/types.d.ts +2 -2
- package/dist/ui/player/player/player-settings.svelte.d.ts +3 -3
- package/dist/ui/shadow-dom/cmp.shadow-root.svelte +2 -2
- package/dist/ui/shadow-dom/cmp.shadow-root.svelte.d.ts +2 -2
- package/package.json +3 -3
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type IMediaCenterDataProvider } from '../../media-center/config/types';
|
|
2
|
-
import type {
|
|
2
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
3
3
|
export type { IMediaCenterDataProvider };
|
|
4
4
|
/**
|
|
5
5
|
* Opens the media page modal using an internal media-center configuration.
|
|
@@ -30,7 +30,7 @@ export type { IMediaCenterDataProvider };
|
|
|
30
30
|
* If true, hides the player's background image.
|
|
31
31
|
* - {boolean} [hideCloseButton]
|
|
32
32
|
* If true, hides the close button.
|
|
33
|
-
* - {
|
|
33
|
+
* - {AppLocaleValue} [locale='en']
|
|
34
34
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
35
35
|
* If omitted, the default locale 'en' is used.
|
|
36
36
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -72,7 +72,7 @@ export declare function openMediaPageModal(init: {
|
|
|
72
72
|
graphqlOrigin?: string;
|
|
73
73
|
viewerSettings?: {
|
|
74
74
|
disableBackground?: boolean;
|
|
75
|
-
locale?:
|
|
75
|
+
locale?: AppLocaleValue;
|
|
76
76
|
showStreamsCloudWatermark?: boolean;
|
|
77
77
|
hideCloseButton?: boolean;
|
|
78
78
|
theme?: 'light' | 'dark';
|
|
@@ -30,7 +30,7 @@ import { openMediaPageModal as openMediaPageModalInternal } from '../../media-pa
|
|
|
30
30
|
* If true, hides the player's background image.
|
|
31
31
|
* - {boolean} [hideCloseButton]
|
|
32
32
|
* If true, hides the close button.
|
|
33
|
-
* - {
|
|
33
|
+
* - {AppLocaleValue} [locale='en']
|
|
34
34
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
35
35
|
* If omitted, the default locale 'en' is used.
|
|
36
36
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type IMediaCenterDataProvider } from '../../media-center/config/types';
|
|
2
|
-
import type {
|
|
2
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
3
3
|
export type { IMediaCenterDataProvider };
|
|
4
4
|
/**
|
|
5
5
|
* Opens the short videos player modal.
|
|
@@ -33,7 +33,7 @@ export type { IMediaCenterDataProvider };
|
|
|
33
33
|
* If true, hides the player's background image.
|
|
34
34
|
* - {boolean} [hideCloseButton]
|
|
35
35
|
* If true, hides the close button.
|
|
36
|
-
* - {
|
|
36
|
+
* - {AppLocaleValue} [locale='en']
|
|
37
37
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
38
38
|
* If omitted, the default locale 'en' is used.
|
|
39
39
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -83,7 +83,7 @@ export declare function openShortVideosPlayer(init: {
|
|
|
83
83
|
mediaPageId?: string;
|
|
84
84
|
playerSettings?: {
|
|
85
85
|
disableBackground?: boolean;
|
|
86
|
-
locale?:
|
|
86
|
+
locale?: AppLocaleValue;
|
|
87
87
|
showStreamsCloudWatermark?: boolean;
|
|
88
88
|
hideCloseButton?: boolean;
|
|
89
89
|
theme?: 'light' | 'dark';
|
|
@@ -34,7 +34,7 @@ import { openPostsPlayer } from '../../posts/posts-player';
|
|
|
34
34
|
* If true, hides the player's background image.
|
|
35
35
|
* - {boolean} [hideCloseButton]
|
|
36
36
|
* If true, hides the close button.
|
|
37
|
-
* - {
|
|
37
|
+
* - {AppLocaleValue} [locale='en']
|
|
38
38
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
39
39
|
* If omitted, the default locale 'en' is used.
|
|
40
40
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type IMediaCenterDataProvider } from '../../media-center/config/types';
|
|
2
2
|
import type { StreamPageViewerModel } from '../../streams/stream-page-viewer/types';
|
|
3
3
|
import type { IStreamAnalyticsHandler, IStreamsPlayerDataProvider, StreamAmplificationParameters, StreamPlayerModel } from '../../streams/streams-player/types';
|
|
4
|
-
import type {
|
|
4
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
5
5
|
export { type StreamPlayerModel, type StreamPageViewerModel };
|
|
6
6
|
export type { IStreamsPlayerDataProvider, IStreamAnalyticsHandler, IMediaCenterDataProvider };
|
|
7
7
|
/**
|
|
@@ -36,7 +36,7 @@ export type { IStreamsPlayerDataProvider, IStreamAnalyticsHandler, IMediaCenterD
|
|
|
36
36
|
* If true, hides the player's background image.
|
|
37
37
|
* - {boolean} [hideCloseButton]
|
|
38
38
|
* If true, hides the close button.
|
|
39
|
-
* - {
|
|
39
|
+
* - {AppLocaleValue} [locale='en']
|
|
40
40
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
41
41
|
* If omitted, the default locale 'en' is used.
|
|
42
42
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -67,7 +67,7 @@ export type { IStreamsPlayerDataProvider, IStreamAnalyticsHandler, IMediaCenterD
|
|
|
67
67
|
* // ...your amplification parameters
|
|
68
68
|
* },
|
|
69
69
|
* playerSettings: {
|
|
70
|
-
* //
|
|
70
|
+
* // AppLocaleValue defaults to 'en'; set 'no' to switch to Norwegian:
|
|
71
71
|
* locale: 'no',
|
|
72
72
|
* disableBackground: false,
|
|
73
73
|
* hideCloseButton: false,
|
|
@@ -90,7 +90,7 @@ export declare function openStreamsPlayer(init: {
|
|
|
90
90
|
amplificationParameters?: StreamAmplificationParameters;
|
|
91
91
|
playerSettings?: {
|
|
92
92
|
disableBackground?: boolean;
|
|
93
|
-
locale?:
|
|
93
|
+
locale?: AppLocaleValue;
|
|
94
94
|
showStreamsCloudWatermark?: boolean;
|
|
95
95
|
hideCloseButton?: boolean;
|
|
96
96
|
theme?: 'light' | 'dark';
|
|
@@ -35,7 +35,7 @@ export {};
|
|
|
35
35
|
* If true, hides the player's background image.
|
|
36
36
|
* - {boolean} [hideCloseButton]
|
|
37
37
|
* If true, hides the close button.
|
|
38
|
-
* - {
|
|
38
|
+
* - {AppLocaleValue} [locale='en']
|
|
39
39
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
40
40
|
* If omitted, the default locale 'en' is used.
|
|
41
41
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -66,7 +66,7 @@ export {};
|
|
|
66
66
|
* // ...your amplification parameters
|
|
67
67
|
* },
|
|
68
68
|
* playerSettings: {
|
|
69
|
-
* //
|
|
69
|
+
* // AppLocaleValue defaults to 'en'; set 'no' to switch to Norwegian:
|
|
70
70
|
* locale: 'no',
|
|
71
71
|
* disableBackground: false,
|
|
72
72
|
* hideCloseButton: false,
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class CommunityFeaturesLocalization {
|
|
3
3
|
get membersLabel() {
|
|
4
|
-
return loc.membersLabel[
|
|
4
|
+
return loc.membersLabel[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
get memberButtonLabel() {
|
|
7
|
-
return loc.memberButtonLabel[
|
|
7
|
+
return loc.memberButtonLabel[AppLocale.current];
|
|
8
8
|
}
|
|
9
9
|
get joinButtonLabel() {
|
|
10
|
-
return loc.joinButtonLabel[
|
|
10
|
+
return loc.joinButtonLabel[AppLocale.current];
|
|
11
11
|
}
|
|
12
12
|
get leaveButtonLabel() {
|
|
13
|
-
return loc.leaveButtonLabel[
|
|
13
|
+
return loc.leaveButtonLabel[AppLocale.current];
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
16
|
const loc = {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class DiscoverViewLocalization {
|
|
3
3
|
get latestStreamsSectionTitle() {
|
|
4
|
-
return loc.streamsSectionTitle[
|
|
4
|
+
return loc.streamsSectionTitle[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
get latestShortVideosSectionTitle() {
|
|
7
|
-
return loc.shortVideosSectionTitle[
|
|
7
|
+
return loc.shortVideosSectionTitle[AppLocale.current];
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
10
|
const loc = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { IMediaCenterDataProvider } from '../../config/types';
|
|
2
2
|
import type { MediaCenterSettings } from '../media-center-settings.svelte';
|
|
3
|
-
import type {
|
|
3
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
4
4
|
export declare class MediaCenterSettingsHandler {
|
|
5
5
|
private _backgroundImageUrl;
|
|
6
6
|
private _mediaCenterSettings;
|
|
@@ -10,7 +10,7 @@ export declare class MediaCenterSettingsHandler {
|
|
|
10
10
|
settings: MediaCenterSettings;
|
|
11
11
|
});
|
|
12
12
|
get playerSettings(): ContentPlayerSettingsLocal;
|
|
13
|
-
get locale():
|
|
13
|
+
get locale(): AppLocaleValue;
|
|
14
14
|
get backgroundWrapperProps(): {
|
|
15
15
|
backgroundDisabled: boolean;
|
|
16
16
|
backgroundImageUrl: string | null;
|
|
@@ -21,7 +21,7 @@ export declare class MediaCenterSettingsHandler {
|
|
|
21
21
|
}
|
|
22
22
|
declare class ContentPlayerSettingsLocal {
|
|
23
23
|
private settings;
|
|
24
|
-
locale?:
|
|
24
|
+
locale?: AppLocaleValue;
|
|
25
25
|
showStreamsCloudWatermark?: boolean;
|
|
26
26
|
overlayMinOffsetTop?: number;
|
|
27
27
|
constructor(settings: MediaCenterSettings);
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class MediaCenterHeaderLocalization {
|
|
3
3
|
get discoverLabel() {
|
|
4
|
-
return loc.discoverLabel[
|
|
4
|
+
return loc.discoverLabel[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
get buttons() {
|
|
7
7
|
return {
|
|
8
|
-
cart: loc.cartButton[
|
|
9
|
-
discover: loc.discoverButton[
|
|
10
|
-
feed: loc.feedButton[
|
|
11
|
-
login: loc.loginButton[
|
|
12
|
-
moments: loc.momentsButton[
|
|
13
|
-
webpage: loc.webpageButton[
|
|
8
|
+
cart: loc.cartButton[AppLocale.current],
|
|
9
|
+
discover: loc.discoverButton[AppLocale.current],
|
|
10
|
+
feed: loc.feedButton[AppLocale.current],
|
|
11
|
+
login: loc.loginButton[AppLocale.current],
|
|
12
|
+
moments: loc.momentsButton[AppLocale.current],
|
|
13
|
+
webpage: loc.webpageButton[AppLocale.current]
|
|
14
14
|
};
|
|
15
15
|
}
|
|
16
16
|
}
|
|
@@ -42,7 +42,7 @@ export declare class MediaCenterContext {
|
|
|
42
42
|
};
|
|
43
43
|
get membershipHandler(): import("..").IMediaCenterMembershipHandler | null;
|
|
44
44
|
get categoriesFollowingHandler(): import("..").IContentCategoryFollowingHandler | null;
|
|
45
|
-
get locale():
|
|
45
|
+
get locale(): AppLocaleValue;
|
|
46
46
|
toggleMenu: () => void;
|
|
47
47
|
showMenu: () => void;
|
|
48
48
|
hideMenu: () => void;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { ThemeValue } from '../../core/theme';
|
|
2
2
|
import type { MediaCenterState } from '..';
|
|
3
3
|
import type { IMediaCenterSettings } from './types';
|
|
4
|
-
import type {
|
|
4
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
5
5
|
export declare class MediaCenterSettings {
|
|
6
|
-
locale:
|
|
6
|
+
locale: AppLocaleValue;
|
|
7
7
|
showStreamsCloudWatermark: boolean;
|
|
8
8
|
disableBackground: boolean;
|
|
9
9
|
theme: ThemeValue;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class MenuLocalization {
|
|
3
3
|
get interestsSectionTitle() {
|
|
4
|
-
return loc.interestsSectionTitle[
|
|
4
|
+
return loc.interestsSectionTitle[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
get popularStreamsSectionTitle() {
|
|
7
|
-
return loc.popularStreamsSectionTitle[
|
|
7
|
+
return loc.popularStreamsSectionTitle[AppLocale.current];
|
|
8
8
|
}
|
|
9
9
|
get discoverLabel() {
|
|
10
|
-
return loc.discoverLabel[
|
|
10
|
+
return loc.discoverLabel[AppLocale.current];
|
|
11
11
|
}
|
|
12
12
|
get feedLabel() {
|
|
13
|
-
return loc.feedLabel[
|
|
13
|
+
return loc.feedLabel[AppLocale.current];
|
|
14
14
|
}
|
|
15
15
|
get membersLabel() {
|
|
16
|
-
return loc.membersLabel[
|
|
16
|
+
return loc.membersLabel[AppLocale.current];
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
19
|
const loc = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { MediaCenterState } from '../navigation';
|
|
2
2
|
import type { PostPlayerModel, PostsPlayerProps } from '../../posts/posts-player/types';
|
|
3
3
|
import type { IStreamsPlayerDataProvider, StreamAmplificationParameters, StreamsPlayerProps } from '../../streams/streams-player/types';
|
|
4
|
-
import type {
|
|
4
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
5
5
|
import type { IPlayerDataProvider } from '@streamscloud/kit/ui/player/providers';
|
|
6
6
|
export type MediaCenterMode = 'discover' | 'posts-feed' | 'streams-feed' | 'moments';
|
|
7
7
|
export type MediaCenterCategoryData = {
|
|
@@ -37,7 +37,7 @@ export type PlayerProps = {
|
|
|
37
37
|
props: StreamsPlayerProps;
|
|
38
38
|
};
|
|
39
39
|
export type IMediaCenterSettings = {
|
|
40
|
-
locale?:
|
|
40
|
+
locale?: AppLocaleValue;
|
|
41
41
|
showStreamsCloudWatermark?: boolean;
|
|
42
42
|
disableBackground?: boolean;
|
|
43
43
|
theme?: 'light' | 'dark';
|
|
@@ -3,7 +3,7 @@ import type { MediaCenterState } from '../media-center/navigation';
|
|
|
3
3
|
import type { PostPlayerModel } from '../posts/posts-player';
|
|
4
4
|
import type { IStreamsPlayerDataProvider } from '../streams/streams-player';
|
|
5
5
|
import type { StreamAmplificationParameters } from '../streams/streams-player/types';
|
|
6
|
-
import type {
|
|
6
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
7
7
|
import type { IPlayerDataProvider } from '@streamscloud/kit/ui/player/providers';
|
|
8
8
|
export { default as MediaPage } from './cmp.media-page.svelte';
|
|
9
9
|
export type { IMediaCenterDataProvider };
|
|
@@ -23,7 +23,7 @@ export type { IMediaCenterDataProvider };
|
|
|
23
23
|
* Fields of `viewerSettings`:
|
|
24
24
|
* - {boolean} [viewerSettings.disableBackground]
|
|
25
25
|
* If true, hides the viewer background image.
|
|
26
|
-
* - {
|
|
26
|
+
* - {AppLocaleValue} [viewerSettings.locale]
|
|
27
27
|
* Localization for the viewer UI. Supported values: 'en' | 'no'.
|
|
28
28
|
* If omitted, the default locale 'en' is used.
|
|
29
29
|
* - {boolean} [viewerSettings.showStreamsCloudWatermark]
|
|
@@ -55,7 +55,7 @@ export type { IMediaCenterDataProvider };
|
|
|
55
55
|
* openMediaPageModal({
|
|
56
56
|
* dataProvider,
|
|
57
57
|
* viewerSettings: {
|
|
58
|
-
* // Example: switch to Norwegian (if supported by your
|
|
58
|
+
* // Example: switch to Norwegian (if supported by your AppLocaleValue type)
|
|
59
59
|
* locale: 'no',
|
|
60
60
|
* disableBackground: false,
|
|
61
61
|
* hideCloseButton: false,
|
|
@@ -101,7 +101,7 @@ export declare function openMediaPageModalWithInitialStreamsProvider(init: {
|
|
|
101
101
|
}): void;
|
|
102
102
|
export type MediaPageViewerSettings = {
|
|
103
103
|
disableBackground?: boolean;
|
|
104
|
-
locale?:
|
|
104
|
+
locale?: AppLocaleValue;
|
|
105
105
|
showStreamsCloudWatermark?: boolean;
|
|
106
106
|
hideCloseButton?: boolean;
|
|
107
107
|
theme?: 'light' | 'dark';
|
package/dist/media-page/index.js
CHANGED
|
@@ -20,7 +20,7 @@ export { default as MediaPage } from './cmp.media-page.svelte';
|
|
|
20
20
|
* Fields of `viewerSettings`:
|
|
21
21
|
* - {boolean} [viewerSettings.disableBackground]
|
|
22
22
|
* If true, hides the viewer background image.
|
|
23
|
-
* - {
|
|
23
|
+
* - {AppLocaleValue} [viewerSettings.locale]
|
|
24
24
|
* Localization for the viewer UI. Supported values: 'en' | 'no'.
|
|
25
25
|
* If omitted, the default locale 'en' is used.
|
|
26
26
|
* - {boolean} [viewerSettings.showStreamsCloudWatermark]
|
|
@@ -52,7 +52,7 @@ export { default as MediaPage } from './cmp.media-page.svelte';
|
|
|
52
52
|
* openMediaPageModal({
|
|
53
53
|
* dataProvider,
|
|
54
54
|
* viewerSettings: {
|
|
55
|
-
* // Example: switch to Norwegian (if supported by your
|
|
55
|
+
* // Example: switch to Norwegian (if supported by your AppLocaleValue type)
|
|
56
56
|
* locale: 'no',
|
|
57
57
|
* disableBackground: false,
|
|
58
58
|
* hideCloseButton: false,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class PostViewerLocalization {
|
|
3
3
|
get viewsCount() {
|
|
4
|
-
return loc.viewsCount[
|
|
4
|
+
return loc.viewsCount[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
get readMore() {
|
|
7
|
-
return loc.readMore[
|
|
7
|
+
return loc.readMore[AppLocale.current];
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
10
|
const loc = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { IPostSocialInteractionsHandler } from '..';
|
|
2
2
|
import type { IPostSharingHandler } from '../sharing';
|
|
3
3
|
import type { IPostAnalyticsHandler, PostPlayerModel } from './types';
|
|
4
|
-
import type {
|
|
4
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
5
5
|
import type { IPlayerDataProvider } from '@streamscloud/kit/ui/player/providers';
|
|
6
6
|
type Props = {
|
|
7
7
|
dataProvider: IPlayerDataProvider<PostPlayerModel>;
|
|
@@ -9,7 +9,7 @@ type Props = {
|
|
|
9
9
|
sharingHandler?: IPostSharingHandler;
|
|
10
10
|
analyticsHandler?: IPostAnalyticsHandler;
|
|
11
11
|
playerSettings?: {
|
|
12
|
-
locale?:
|
|
12
|
+
locale?: AppLocaleValue;
|
|
13
13
|
showStreamsCloudWatermark?: boolean;
|
|
14
14
|
disableBackground?: boolean;
|
|
15
15
|
theme?: 'light' | 'dark';
|
|
@@ -3,7 +3,7 @@ import type { IPostSharingHandler } from '../sharing';
|
|
|
3
3
|
import type { IPostSocialInteractionsHandler } from '../social-interactions';
|
|
4
4
|
import { default as PostsPlayer } from './cmp.posts-player.svelte';
|
|
5
5
|
import type { IPostAnalyticsHandler, PostPlayerModel } from './types';
|
|
6
|
-
import type {
|
|
6
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
7
7
|
export { PostsPlayer, type PostPlayerModel };
|
|
8
8
|
export type { IMediaCenterDataProvider, IPostAnalyticsHandler };
|
|
9
9
|
/**
|
|
@@ -89,7 +89,7 @@ export declare function openPostsPlayer(init: {
|
|
|
89
89
|
sharingHandler?: IPostSharingHandler;
|
|
90
90
|
playerSettings?: {
|
|
91
91
|
disableBackground?: boolean;
|
|
92
|
-
locale?:
|
|
92
|
+
locale?: AppLocaleValue;
|
|
93
93
|
showStreamsCloudWatermark?: boolean;
|
|
94
94
|
hideCloseButton?: boolean;
|
|
95
95
|
theme?: 'light' | 'dark';
|
|
@@ -2,7 +2,7 @@ import type { IPostSharingHandler } from '../sharing';
|
|
|
2
2
|
import type { IPostSocialInteractionsHandler } from '../social-interactions';
|
|
3
3
|
import { type ICloseOrchestrator } from '../../ui/player/close-orchestrator';
|
|
4
4
|
import type { IPostAnalyticsHandler, PostPlayerModel } from './types';
|
|
5
|
-
import type {
|
|
5
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
6
6
|
import type { IPlayerDataProvider } from '@streamscloud/kit/ui/player/providers';
|
|
7
7
|
type Props = {
|
|
8
8
|
dataProvider: IPlayerDataProvider<PostPlayerModel>;
|
|
@@ -11,7 +11,7 @@ type Props = {
|
|
|
11
11
|
analyticsHandler?: IPostAnalyticsHandler;
|
|
12
12
|
closeOrchestrator: ICloseOrchestrator;
|
|
13
13
|
playerSettings?: {
|
|
14
|
-
locale?:
|
|
14
|
+
locale?: AppLocaleValue;
|
|
15
15
|
showStreamsCloudWatermark?: boolean;
|
|
16
16
|
disableBackground?: boolean;
|
|
17
17
|
theme?: 'light' | 'dark';
|
|
@@ -3,7 +3,7 @@ import type { IPostModel } from '..';
|
|
|
3
3
|
import type { IPostSharingHandler } from '../sharing';
|
|
4
4
|
import type { IPostSocialInteractionsHandler } from '../social-interactions';
|
|
5
5
|
import type { ICloseOrchestrator } from '../../ui/player/close-orchestrator';
|
|
6
|
-
import type {
|
|
6
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
7
7
|
import type { IPlayerBuffer, IPlayerDataProvider } from '@streamscloud/kit/ui/player/providers';
|
|
8
8
|
export interface IPostAnalyticsHandler {
|
|
9
9
|
trackPostOpened: (postType: PostType, postId: string) => void;
|
|
@@ -34,7 +34,7 @@ export type PostsPlayerProps = {
|
|
|
34
34
|
};
|
|
35
35
|
};
|
|
36
36
|
export type PostPlayerSettings = {
|
|
37
|
-
locale?:
|
|
37
|
+
locale?: AppLocaleValue;
|
|
38
38
|
showStreamsCloudWatermark?: boolean;
|
|
39
39
|
};
|
|
40
40
|
export type PostManagementActions = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class ProductCardLocalization {
|
|
3
3
|
get beforeNowPrefix() {
|
|
4
|
-
return loc.beforeNowPrefix[
|
|
4
|
+
return loc.beforeNowPrefix[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
}
|
|
7
7
|
const loc = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class ShortVideoCardLocalization {
|
|
3
3
|
get viewsLabel() {
|
|
4
|
-
return loc.viewsLabel[
|
|
4
|
+
return loc.viewsLabel[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
}
|
|
7
7
|
const loc = {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class PriceStreamElementLocalization {
|
|
3
3
|
get saveValue() {
|
|
4
|
-
return loc.saveValue[
|
|
4
|
+
return loc.saveValue[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
get beforeValue() {
|
|
7
|
-
return loc.beforeValue[
|
|
7
|
+
return loc.beforeValue[AppLocale.current];
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
10
|
const loc = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class StockStreamElementLocalization {
|
|
3
3
|
get quantity() {
|
|
4
|
-
return loc.quantity[
|
|
4
|
+
return loc.quantity[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
}
|
|
7
7
|
const loc = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { IPostSocialInteractionsHandler } from '../../posts';
|
|
2
2
|
import type { IStreamSharingHandler } from '../sharing';
|
|
3
3
|
import type { IStreamAnalyticsHandler, IStreamsPlayerDataProvider, StreamAmplificationParameters } from './types';
|
|
4
|
-
import type {
|
|
4
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
5
5
|
type Props = {
|
|
6
6
|
dataProvider: IStreamsPlayerDataProvider;
|
|
7
7
|
postSocialInteractionsHandler?: IPostSocialInteractionsHandler;
|
|
@@ -9,7 +9,7 @@ type Props = {
|
|
|
9
9
|
analyticsHandler?: IStreamAnalyticsHandler;
|
|
10
10
|
amplificationParameters?: StreamAmplificationParameters;
|
|
11
11
|
playerSettings?: {
|
|
12
|
-
locale?:
|
|
12
|
+
locale?: AppLocaleValue;
|
|
13
13
|
showStreamsCloudWatermark?: boolean;
|
|
14
14
|
disableBackground?: boolean;
|
|
15
15
|
theme?: 'light' | 'dark';
|
|
@@ -3,7 +3,7 @@ import type { IPostSocialInteractionsHandler } from '../../posts/social-interact
|
|
|
3
3
|
import type { IStreamSharingHandler } from '../sharing';
|
|
4
4
|
import type { StreamPageViewerModel } from '../stream-page-viewer/types';
|
|
5
5
|
import type { IStreamAnalyticsHandler, IStreamsPlayerDataProvider, StreamAmplificationParameters, StreamPlayerModel } from './types';
|
|
6
|
-
import type {
|
|
6
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
7
7
|
export { type StreamPlayerModel, type StreamPageViewerModel };
|
|
8
8
|
export type { IStreamsPlayerDataProvider, IStreamAnalyticsHandler, IMediaCenterDataProvider };
|
|
9
9
|
/**
|
|
@@ -30,7 +30,7 @@ export type { IStreamsPlayerDataProvider, IStreamAnalyticsHandler, IMediaCenterD
|
|
|
30
30
|
* If true, hides the player's background image.
|
|
31
31
|
* - {boolean} [hideCloseButton]
|
|
32
32
|
* If true, hides the close button.
|
|
33
|
-
* - {
|
|
33
|
+
* - {AppLocaleValue} [locale='en']
|
|
34
34
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
35
35
|
* If omitted, the default locale 'en' is used.
|
|
36
36
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -59,7 +59,7 @@ export type { IStreamsPlayerDataProvider, IStreamAnalyticsHandler, IMediaCenterD
|
|
|
59
59
|
* // ...your amplification parameters
|
|
60
60
|
* },
|
|
61
61
|
* playerSettings: {
|
|
62
|
-
* //
|
|
62
|
+
* // AppLocaleValue defaults to 'en'; set 'no' to switch to Norwegian:
|
|
63
63
|
* locale: 'no',
|
|
64
64
|
* disableBackground: false,
|
|
65
65
|
* hideCloseButton: false,
|
|
@@ -90,7 +90,7 @@ export declare function openStreamsPlayer(init: {
|
|
|
90
90
|
}): void;
|
|
91
91
|
export type StreamsPlayerSettings = {
|
|
92
92
|
disableBackground?: boolean;
|
|
93
|
-
locale?:
|
|
93
|
+
locale?: AppLocaleValue;
|
|
94
94
|
showStreamsCloudWatermark?: boolean;
|
|
95
95
|
hideCloseButton?: boolean;
|
|
96
96
|
theme?: 'light' | 'dark';
|
|
@@ -28,7 +28,7 @@ export {};
|
|
|
28
28
|
* If true, hides the player's background image.
|
|
29
29
|
* - {boolean} [hideCloseButton]
|
|
30
30
|
* If true, hides the close button.
|
|
31
|
-
* - {
|
|
31
|
+
* - {AppLocaleValue} [locale='en']
|
|
32
32
|
* Localization for the player UI. Supported values: 'en' | 'no'.
|
|
33
33
|
* If omitted, the default locale 'en' is used.
|
|
34
34
|
* - {boolean} [showStreamsCloudWatermark]
|
|
@@ -57,7 +57,7 @@ export {};
|
|
|
57
57
|
* // ...your amplification parameters
|
|
58
58
|
* },
|
|
59
59
|
* playerSettings: {
|
|
60
|
-
* //
|
|
60
|
+
* // AppLocaleValue defaults to 'en'; set 'no' to switch to Norwegian:
|
|
61
61
|
* locale: 'no',
|
|
62
62
|
* disableBackground: false,
|
|
63
63
|
* hideCloseButton: false,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export class StreamPlayerLocalization {
|
|
3
3
|
get streamNotFound() {
|
|
4
|
-
return loc.streamNotFound[
|
|
4
|
+
return loc.streamNotFound[AppLocale.current];
|
|
5
5
|
}
|
|
6
6
|
}
|
|
7
7
|
const loc = {
|
|
@@ -2,7 +2,7 @@ import type { IPostSocialInteractionsHandler } from '../../posts/social-interact
|
|
|
2
2
|
import type { IStreamSharingHandler } from '../sharing';
|
|
3
3
|
import { type ICloseOrchestrator } from '../../ui/player/close-orchestrator';
|
|
4
4
|
import type { IStreamsPlayerDataProvider, IStreamAnalyticsHandler, StreamAmplificationParameters } from './types';
|
|
5
|
-
import type {
|
|
5
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
6
6
|
type Props = {
|
|
7
7
|
dataProvider: IStreamsPlayerDataProvider;
|
|
8
8
|
postSocialInteractionsHandler?: IPostSocialInteractionsHandler;
|
|
@@ -11,7 +11,7 @@ type Props = {
|
|
|
11
11
|
amplificationParameters?: StreamAmplificationParameters;
|
|
12
12
|
closeOrchestrator: ICloseOrchestrator;
|
|
13
13
|
playerSettings?: {
|
|
14
|
-
locale?:
|
|
14
|
+
locale?: AppLocaleValue;
|
|
15
15
|
showStreamsCloudWatermark?: boolean;
|
|
16
16
|
disableBackground?: boolean;
|
|
17
17
|
theme?: 'light' | 'dark';
|
|
@@ -3,7 +3,7 @@ import type { IStreamSharingHandler } from '../sharing';
|
|
|
3
3
|
import type { StreamPageViewerModel } from '../stream-page-viewer';
|
|
4
4
|
import type { ICloseOrchestrator } from '../../ui/player/close-orchestrator';
|
|
5
5
|
import type { StreamsPlayerBuffer } from './streams-player-buffer.svelte';
|
|
6
|
-
import type {
|
|
6
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
7
7
|
export type StreamPlayerModel = {
|
|
8
8
|
id: string;
|
|
9
9
|
title: string;
|
|
@@ -43,7 +43,7 @@ export type StreamsPlayerProps = {
|
|
|
43
43
|
};
|
|
44
44
|
};
|
|
45
45
|
export type StreamsPlayerSettings = {
|
|
46
|
-
locale?:
|
|
46
|
+
locale?: AppLocaleValue;
|
|
47
47
|
showStreamsCloudWatermark?: boolean;
|
|
48
48
|
overlayMinOffsetTop?: number;
|
|
49
49
|
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
2
2
|
export declare class PlayerSettings {
|
|
3
|
-
locale:
|
|
3
|
+
locale: AppLocaleValue;
|
|
4
4
|
showStreamsCloudWatermark: boolean;
|
|
5
5
|
constructor(init?: IContentPlayerSettings);
|
|
6
6
|
patch: (settings?: IContentPlayerSettings) => void;
|
|
7
7
|
}
|
|
8
8
|
export type IContentPlayerSettings = {
|
|
9
|
-
locale?:
|
|
9
|
+
locale?: AppLocaleValue;
|
|
10
10
|
showStreamsCloudWatermark?: boolean;
|
|
11
11
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
<script lang="ts">import { brandColors } from '../../core/theme';
|
|
2
|
-
import {
|
|
2
|
+
import { AppLocale } from '@streamscloud/kit/core/locale';
|
|
3
3
|
let { locale, theme = 'dark', backgroundDisabled, backgroundImageUrl, children } = $props();
|
|
4
4
|
$effect(() => {
|
|
5
5
|
if (locale) {
|
|
6
|
-
|
|
6
|
+
AppLocale.change(locale);
|
|
7
7
|
}
|
|
8
8
|
});
|
|
9
9
|
const appendBrandPair = (values, name, pair) => {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type ThemeValue } from '../../core/theme';
|
|
2
|
-
import { type
|
|
2
|
+
import { type AppLocaleValue } from '@streamscloud/kit/core/locale';
|
|
3
3
|
import type { Snippet } from 'svelte';
|
|
4
4
|
type Props = {
|
|
5
|
-
locale?:
|
|
5
|
+
locale?: AppLocaleValue;
|
|
6
6
|
theme?: ThemeValue;
|
|
7
7
|
backgroundDisabled: boolean;
|
|
8
8
|
backgroundImageUrl: string | null | 'not-applicable';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamscloud/embeddable",
|
|
3
|
-
"version": "16.0.
|
|
3
|
+
"version": "16.0.2",
|
|
4
4
|
"author": "StreamsCloud",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -133,7 +133,7 @@
|
|
|
133
133
|
}
|
|
134
134
|
},
|
|
135
135
|
"peerDependencies": {
|
|
136
|
-
"@streamscloud/kit": "^0.1.
|
|
136
|
+
"@streamscloud/kit": "^0.1.4",
|
|
137
137
|
"@streamscloud/streams-analytics-collector": "^4.0.1",
|
|
138
138
|
"svelte": "^5.51.0"
|
|
139
139
|
},
|
|
@@ -149,7 +149,7 @@
|
|
|
149
149
|
"@graphql-codegen/typescript": "^5.0.7",
|
|
150
150
|
"@graphql-codegen/typescript-operations": "^5.0.7",
|
|
151
151
|
"@graphql-typed-document-node/core": "^3.2.0",
|
|
152
|
-
"@streamscloud/kit": "^0.1.
|
|
152
|
+
"@streamscloud/kit": "^0.1.4",
|
|
153
153
|
"@streamscloud/streams-analytics-collector": "^4.0.1",
|
|
154
154
|
"@sveltejs/package": "^2.5.7",
|
|
155
155
|
"@sveltejs/vite-plugin-svelte": "^6.2.4",
|