@streamscloud/embeddable 13.2.0 → 14.0.0-rc.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/dist/content-player/cmp.content-player.svelte.d.ts +15 -6
- package/dist/content-player/controls-and-attachments.svelte.d.ts +14 -5
- package/dist/content-player/overview-panel.svelte +3 -1
- package/dist/content-player/overview-panel.svelte.d.ts +14 -5
- package/dist/core/analytics.installation-id.d.ts +5 -0
- package/dist/core/{analytics.profile-id.js → analytics.installation-id.js} +20 -10
- package/dist/external-api/data-providers/internal-media-center-analytics-handler.d.ts +14 -14
- package/dist/external-api/data-providers/internal-media-center-analytics-handler.js +170 -19
- package/dist/external-api/data-providers/internal-post-analytics-handler.d.ts +7 -7
- package/dist/external-api/data-providers/internal-post-analytics-handler.js +72 -11
- package/dist/external-api/data-providers/internal-stream-analytics-handler.d.ts +12 -13
- package/dist/external-api/data-providers/internal-stream-analytics-handler.js +162 -18
- package/dist/external-api/data-providers/mapper.d.ts +3 -0
- package/dist/external-api/data-providers/mapper.js +18 -0
- package/dist/external-api/data-providers/post-data-loaders/mapper.js +1 -3
- package/dist/media-center/media-center/discover/community-features.svelte +2 -1
- package/dist/media-center/media-center/discover/discover-header.svelte +1 -0
- package/dist/media-center/media-center/discover/discover-view.svelte +34 -11
- package/dist/media-center/media-center/menu/menu.svelte +5 -3
- package/dist/media-center/media-center/streams-in-category/streams-in-category-panel.svelte +6 -2
- package/dist/posts/post-viewer/attachments-horizontal.svelte +1 -0
- package/dist/posts/post-viewer/media/post-media.svelte +3 -3
- package/dist/posts/posts-player/posts-player-view.svelte +2 -5
- package/dist/posts/posts-player/types.d.ts +3 -5
- package/dist/streams/streams-player/streams-player-view.svelte +0 -3
- package/dist/streams/streams-player/types.d.ts +0 -1
- package/dist/ui/button/resources/button-theme.svelte +4 -2
- package/dist/ui/icon/cmp.icon.svelte +1 -1
- package/dist/ui/player/button/cmp.player-button.svelte +3 -1
- package/dist/ui/player/button/cmp.player-buttons-group.svelte +3 -1
- package/dist/ui/player/slider/cmp.player-slider.svelte +22 -15
- package/dist/ui/player/slider/cmp.player-slider.svelte.d.ts +14 -5
- package/dist/ui/{slider → player/slider-horizontal}/cmp.slider.svelte +57 -30
- package/dist/ui/{slider → player/slider-horizontal}/cmp.slider.svelte.d.ts +13 -6
- package/dist/ui/player/slider-horizontal/index.d.ts +2 -0
- package/dist/ui/player/slider-horizontal/index.js +2 -0
- package/dist/ui/{slider → player/slider-horizontal}/slider-localization.d.ts +1 -1
- package/dist/ui/{slider → player/slider-horizontal}/slider-localization.js +1 -1
- package/dist/ui/player/utils/index.d.ts +1 -0
- package/dist/ui/player/utils/index.js +1 -0
- package/dist/ui/player/utils/touch-synchronizer.d.ts +7 -0
- package/dist/ui/player/utils/touch-synchronizer.js +21 -0
- package/dist/ui/shadow-dom/cmp.shadow-root.svelte +2 -2
- package/package.json +2 -2
- package/dist/core/analytics.profile-id.d.ts +0 -5
- package/dist/ui/slider/index.d.ts +0 -2
- package/dist/ui/slider/index.js +0 -2
- /package/dist/ui/{slider → player/slider-horizontal}/types.d.ts +0 -0
- /package/dist/ui/{slider → player/slider-horizontal}/types.js +0 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
<script lang="ts">import {
|
|
1
|
+
<script lang="ts">import { TouchSynchronizer } from '../utils';
|
|
2
|
+
import { createWheelAdapter } from './wheel-gestures-adapter';
|
|
2
3
|
import { onDestroy, onMount, untrack } from 'svelte';
|
|
3
4
|
let { buffer, on, children } = $props();
|
|
4
5
|
let slidesRef;
|
|
@@ -43,21 +44,27 @@ onMount(() => {
|
|
|
43
44
|
let touchStartY = 0;
|
|
44
45
|
let touchMoveY = 0;
|
|
45
46
|
let touchStartTime = 0;
|
|
46
|
-
let
|
|
47
|
+
let swipeState = 'not-initialized';
|
|
47
48
|
window.addEventListener(`keydown`, onKeyPress);
|
|
48
49
|
slidesRef.addEventListener('touchstart', (e) => {
|
|
50
|
+
TouchSynchronizer.touchStarted(slidesRef);
|
|
49
51
|
// The movement gets all janky if there's a transition on the elements.
|
|
50
52
|
slidesRef.classList.toggle('animate', false);
|
|
51
53
|
touchStartX = e.changedTouches[0].screenX;
|
|
52
54
|
touchStartY = e.changedTouches[0].screenY;
|
|
53
55
|
touchStartTime = Date.now();
|
|
54
|
-
|
|
56
|
+
swipeState = 'not-initialized';
|
|
55
57
|
}, { passive: true });
|
|
56
58
|
slidesRef.addEventListener('touchmove', (e) => {
|
|
57
|
-
if (
|
|
59
|
+
if (swipeState === 'vertical') {
|
|
58
60
|
// Already determined this is a vertical swipe
|
|
59
61
|
e.preventDefault();
|
|
60
62
|
e.stopPropagation();
|
|
63
|
+
TouchSynchronizer.touchMovePropagationBlocked(slidesRef);
|
|
64
|
+
}
|
|
65
|
+
else if (swipeState === 'horizontal') {
|
|
66
|
+
// Already determined this is a horizontal swipe
|
|
67
|
+
return;
|
|
61
68
|
}
|
|
62
69
|
const touchCurrentX = e.changedTouches[0].screenX;
|
|
63
70
|
const touchCurrentY = e.changedTouches[0].screenY;
|
|
@@ -67,9 +74,10 @@ onMount(() => {
|
|
|
67
74
|
if (diffX > 10 || diffY > 10) {
|
|
68
75
|
if (diffY > diffX) {
|
|
69
76
|
// Vertical swipe - handle it
|
|
70
|
-
|
|
77
|
+
swipeState = 'vertical';
|
|
71
78
|
e.preventDefault();
|
|
72
79
|
e.stopPropagation();
|
|
80
|
+
TouchSynchronizer.touchMovePropagationBlocked(slidesRef);
|
|
73
81
|
const newPosition = touchCurrentY;
|
|
74
82
|
const diff = newPosition - touchStartY;
|
|
75
83
|
if ((diff > 0 && buffer.canLoadPrevious) || (diff < 0 && buffer.canLoadNext)) {
|
|
@@ -79,28 +87,27 @@ onMount(() => {
|
|
|
79
87
|
}
|
|
80
88
|
else {
|
|
81
89
|
// Horizontal swipe - allow child to handle
|
|
82
|
-
|
|
90
|
+
swipeState = 'horizontal';
|
|
83
91
|
return;
|
|
84
92
|
}
|
|
85
93
|
}
|
|
86
94
|
}, { passive: false });
|
|
87
95
|
slidesRef.addEventListener('touchend', (e) => {
|
|
88
|
-
const
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
96
|
+
const reset = () => {
|
|
97
|
+
swipeTransition = 0;
|
|
98
|
+
touchMoveY = 0;
|
|
99
|
+
};
|
|
92
100
|
// Check if this is a vertical swipe
|
|
93
|
-
if (
|
|
101
|
+
if (swipeState !== 'vertical') {
|
|
94
102
|
// Horizontal swipe - don't handle and don't block
|
|
103
|
+
reset();
|
|
95
104
|
return;
|
|
96
105
|
}
|
|
97
106
|
// This is a vertical swipe - block propagation
|
|
98
107
|
e.stopPropagation();
|
|
108
|
+
TouchSynchronizer.touchEndPropatationBlocked(slidesRef);
|
|
109
|
+
TouchSynchronizer.touchEnded(slidesRef);
|
|
99
110
|
slidesRef.classList.toggle('animate', true);
|
|
100
|
-
const reset = () => {
|
|
101
|
-
swipeTransition = 0;
|
|
102
|
-
touchMoveY = 0;
|
|
103
|
-
};
|
|
104
111
|
const isFastSwipe = Date.now() - touchStartTime < 300;
|
|
105
112
|
if (!touchMoveY || (!isFastSwipe && Math.abs(touchMoveY) < sliderHeight / 6)) {
|
|
106
113
|
return reset();
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { PlayerSliderBuffer, PlayerSliderCallbacks } from './types';
|
|
2
2
|
import { type Snippet } from 'svelte';
|
|
3
|
-
declare
|
|
3
|
+
declare function $$render<T extends {
|
|
4
4
|
id: string;
|
|
5
|
-
}> {
|
|
6
|
-
props
|
|
5
|
+
}>(): {
|
|
6
|
+
props: {
|
|
7
7
|
buffer: PlayerSliderBuffer<T>;
|
|
8
8
|
on?: PlayerSliderCallbacks;
|
|
9
9
|
children: Snippet<[{
|
|
@@ -11,8 +11,17 @@ declare class __sveltets_Render<T extends {
|
|
|
11
11
|
active?: boolean;
|
|
12
12
|
}]>;
|
|
13
13
|
};
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
exports: {};
|
|
15
|
+
bindings: "";
|
|
16
|
+
slots: {};
|
|
17
|
+
events: {};
|
|
18
|
+
};
|
|
19
|
+
declare class __sveltets_Render<T extends {
|
|
20
|
+
id: string;
|
|
21
|
+
}> {
|
|
22
|
+
props(): ReturnType<typeof $$render<T>>['props'];
|
|
23
|
+
events(): ReturnType<typeof $$render<T>>['events'];
|
|
24
|
+
slots(): ReturnType<typeof $$render<T>>['slots'];
|
|
16
25
|
bindings(): "";
|
|
17
26
|
exports(): {};
|
|
18
27
|
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
<script lang="ts">import { runningInBrowser } from '
|
|
2
|
-
import { Utils } from '
|
|
3
|
-
import { HtmlHelper } from '
|
|
4
|
-
import { Icon } from '
|
|
1
|
+
<script lang="ts">import { runningInBrowser } from '../../../core/browser';
|
|
2
|
+
import { Utils } from '../../../core/utils';
|
|
3
|
+
import { HtmlHelper } from '../../../core/utils/html-helper';
|
|
4
|
+
import { Icon } from '../../icon';
|
|
5
|
+
import { TouchSynchronizer } from '../utils';
|
|
5
6
|
import { SliderLocalization } from './slider-localization';
|
|
6
7
|
import { SliderMode } from './types';
|
|
7
8
|
import IconChevronLeft from '@fluentui/svg-icons/icons/chevron_left_20_regular.svg?raw';
|
|
@@ -13,13 +14,14 @@ let { items, sliderMode = SliderMode.ArrowsWithCounts, dotsConfig = {
|
|
|
13
14
|
}, locale, initialIndex, autoSlideMs = 0, on, children } = $props();
|
|
14
15
|
const localization = $derived.by(() => new SliderLocalization(locale));
|
|
15
16
|
const itemIndices = $derived(items.map((_, index) => index));
|
|
16
|
-
const animationDuration =
|
|
17
|
+
const animationDuration = 300;
|
|
17
18
|
let previousItems = $state.raw(undefined);
|
|
18
19
|
let selectedIndex = $state(initialIndex);
|
|
19
20
|
let animationIndex = $state(null);
|
|
20
21
|
let interval;
|
|
21
22
|
let slidesRef;
|
|
22
23
|
let sliderWidth = $state(0);
|
|
24
|
+
let swipeTransition = $state(0);
|
|
23
25
|
let resizeObserver;
|
|
24
26
|
onMount(() => {
|
|
25
27
|
notifyIndexChanged();
|
|
@@ -28,19 +30,26 @@ onMount(() => {
|
|
|
28
30
|
});
|
|
29
31
|
let touchStartX = 0;
|
|
30
32
|
let touchStartY = 0;
|
|
33
|
+
let touchMoveX = 0;
|
|
31
34
|
let touchStartTime = 0;
|
|
32
|
-
let
|
|
35
|
+
let swipeState = 'not-initialized';
|
|
33
36
|
slidesRef.addEventListener('touchstart', (e) => {
|
|
37
|
+
TouchSynchronizer.touchStarted(slidesRef);
|
|
38
|
+
slidesRef.classList.toggle('animate', false);
|
|
34
39
|
touchStartX = e.changedTouches[0].screenX;
|
|
35
40
|
touchStartY = e.changedTouches[0].screenY;
|
|
36
41
|
touchStartTime = Date.now();
|
|
37
|
-
|
|
42
|
+
swipeState = 'not-initialized';
|
|
38
43
|
}, { passive: true });
|
|
39
44
|
slidesRef.addEventListener('touchmove', (e) => {
|
|
40
|
-
if (
|
|
45
|
+
if (swipeState === 'horizontal') {
|
|
41
46
|
// Already determined this is a horizontal swipe
|
|
42
47
|
e.preventDefault();
|
|
43
48
|
e.stopPropagation();
|
|
49
|
+
TouchSynchronizer.touchMovePropagationBlocked(slidesRef);
|
|
50
|
+
}
|
|
51
|
+
else if (swipeState === 'vertical') {
|
|
52
|
+
// Already determined this is a vertical swipe
|
|
44
53
|
return;
|
|
45
54
|
}
|
|
46
55
|
const touchCurrentX = e.changedTouches[0].screenX;
|
|
@@ -51,39 +60,49 @@ onMount(() => {
|
|
|
51
60
|
if (diffX > 10 || diffY > 10) {
|
|
52
61
|
if (diffX > diffY) {
|
|
53
62
|
// Horizontal swipe - block vertical scroll
|
|
54
|
-
|
|
63
|
+
swipeState = 'horizontal';
|
|
55
64
|
e.preventDefault();
|
|
56
65
|
e.stopPropagation();
|
|
66
|
+
TouchSynchronizer.touchMovePropagationBlocked(slidesRef);
|
|
67
|
+
touchMoveX = touchCurrentX - touchStartX;
|
|
68
|
+
const basePosition = -sliderWidth * (animationIndex === null ? selectedIndex + 1 : animationIndex);
|
|
69
|
+
swipeTransition = basePosition + touchMoveX;
|
|
57
70
|
}
|
|
58
71
|
else {
|
|
59
72
|
// Vertical swipe - allow parent to handle
|
|
60
|
-
|
|
73
|
+
swipeState = 'vertical';
|
|
61
74
|
}
|
|
62
75
|
}
|
|
63
|
-
});
|
|
76
|
+
}, { passive: false });
|
|
64
77
|
slidesRef.addEventListener('touchend', (e) => {
|
|
65
|
-
const
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
78
|
+
const reset = () => {
|
|
79
|
+
swipeTransition = 0;
|
|
80
|
+
touchMoveX = 0;
|
|
81
|
+
};
|
|
69
82
|
// Check if this is a horizontal swipe
|
|
70
|
-
if (
|
|
83
|
+
if (swipeState !== 'horizontal') {
|
|
84
|
+
reset();
|
|
71
85
|
return;
|
|
72
86
|
}
|
|
73
87
|
// This is a horizontal swipe - block propagation
|
|
74
88
|
e.stopPropagation();
|
|
75
89
|
e.preventDefault();
|
|
90
|
+
slidesRef.classList.toggle('animate', true);
|
|
91
|
+
TouchSynchronizer.touchEndPropatationBlocked(slidesRef);
|
|
92
|
+
TouchSynchronizer.touchEnded(slidesRef);
|
|
76
93
|
const isFastSwipe = Date.now() - touchStartTime < 300;
|
|
77
|
-
if (!isFastSwipe &&
|
|
94
|
+
if (!isFastSwipe && Math.abs(touchMoveX) < sliderWidth / 6) {
|
|
95
|
+
reset();
|
|
78
96
|
return;
|
|
79
97
|
}
|
|
80
|
-
if (
|
|
98
|
+
if (touchMoveX < 0) {
|
|
81
99
|
loadNext();
|
|
82
100
|
}
|
|
83
|
-
|
|
101
|
+
else {
|
|
84
102
|
loadPrevious();
|
|
85
103
|
}
|
|
86
|
-
|
|
104
|
+
reset();
|
|
105
|
+
}, { passive: false });
|
|
87
106
|
slidesRef.addEventListener('transitionend', (e) => {
|
|
88
107
|
e.stopPropagation();
|
|
89
108
|
if (animationIndex !== null && animationIndex > items.length - 1) {
|
|
@@ -166,16 +185,23 @@ const setIndex = (index) => {
|
|
|
166
185
|
};
|
|
167
186
|
const loadPrevious = Utils.throttle(() => {
|
|
168
187
|
setIndex(--selectedIndex);
|
|
169
|
-
},
|
|
188
|
+
}, animationDuration);
|
|
170
189
|
const loadNext = Utils.throttle(() => {
|
|
171
190
|
setIndex(++selectedIndex);
|
|
172
|
-
},
|
|
191
|
+
}, animationDuration);
|
|
173
192
|
$effect(() => {
|
|
174
193
|
if (previousItems && items !== previousItems) {
|
|
175
194
|
setIndex(0);
|
|
176
195
|
}
|
|
177
196
|
previousItems = items;
|
|
178
197
|
});
|
|
198
|
+
const styles = $derived.by(() => {
|
|
199
|
+
const values = [
|
|
200
|
+
`transform: translateX(${swipeTransition || (items.length > 1 ? -sliderWidth * (animationIndex === null ? selectedIndex + 1 : animationIndex) : 0)}px)`,
|
|
201
|
+
`--_slider-horizontal--animation: ${animationDuration}ms ease-out transform`
|
|
202
|
+
];
|
|
203
|
+
return values.join(';');
|
|
204
|
+
});
|
|
179
205
|
const showClassicArrowsAndDots = $derived([SliderMode.ArrowsAndDots, SliderMode.ArrowsOnly, SliderMode.DotsOnly, SliderMode.DotsOnlyBelow].includes(sliderMode));
|
|
180
206
|
</script>
|
|
181
207
|
|
|
@@ -186,12 +212,9 @@ const showClassicArrowsAndDots = $derived([SliderMode.ArrowsAndDots, SliderMode.
|
|
|
186
212
|
class:slider--dots-only={sliderMode === SliderMode.DotsOnly}
|
|
187
213
|
class:slider--dots-only-below={sliderMode === SliderMode.DotsOnlyBelow}
|
|
188
214
|
class:slider--arrows-with-counts={sliderMode === SliderMode.ArrowsWithCounts}>
|
|
189
|
-
<div
|
|
190
|
-
class="slider__slides"
|
|
191
|
-
bind:this={slidesRef}
|
|
192
|
-
style={`transform: translateX(${items.length > 1 ? -sliderWidth * (animationIndex === null ? selectedIndex + 1 : animationIndex) : 0}px)`}>
|
|
215
|
+
<div class="slider__slides" bind:this={slidesRef} style={styles}>
|
|
193
216
|
{#if items.length > 1}
|
|
194
|
-
<div class="slider__slide"
|
|
217
|
+
<div class="slider__slide">
|
|
195
218
|
{#if children}
|
|
196
219
|
{@render children(items[items.length - 1])}
|
|
197
220
|
{/if}
|
|
@@ -261,14 +284,13 @@ const showClassicArrowsAndDots = $derived([SliderMode.ArrowsAndDots, SliderMode.
|
|
|
261
284
|
width: 100%;
|
|
262
285
|
height: 100%;
|
|
263
286
|
overflow: hidden;
|
|
264
|
-
/* Set 'container-type: inline-size;' to reference container*/
|
|
265
287
|
}
|
|
266
288
|
.slider__slides {
|
|
267
289
|
display: flex;
|
|
268
290
|
height: 100%;
|
|
269
291
|
}
|
|
270
292
|
.slider__slides:global(.animate) {
|
|
271
|
-
transition:
|
|
293
|
+
transition: var(--_slider-horizontal--animation);
|
|
272
294
|
}
|
|
273
295
|
.slider__slide {
|
|
274
296
|
display: flex;
|
|
@@ -354,12 +376,14 @@ const showClassicArrowsAndDots = $derived([SliderMode.ArrowsAndDots, SliderMode.
|
|
|
354
376
|
text-align: center;
|
|
355
377
|
color: var(--sc-mc-color--text-white);
|
|
356
378
|
visibility: hidden;
|
|
357
|
-
/* Set 'container-type: inline-size;' to reference container*/
|
|
358
379
|
}
|
|
359
380
|
.slider__counts-navigation-button:disabled {
|
|
360
381
|
opacity: 0.5;
|
|
361
382
|
cursor: default;
|
|
362
383
|
}
|
|
384
|
+
.slider__counts-navigation-button {
|
|
385
|
+
/* Set 'container-type: inline-size;' to reference container*/
|
|
386
|
+
}
|
|
363
387
|
@container (width < 576px) {
|
|
364
388
|
.slider__counts-navigation-button {
|
|
365
389
|
visibility: visible;
|
|
@@ -388,6 +412,9 @@ const showClassicArrowsAndDots = $derived([SliderMode.ArrowsAndDots, SliderMode.
|
|
|
388
412
|
position: static;
|
|
389
413
|
margin-top: 1rem;
|
|
390
414
|
}
|
|
415
|
+
.slider {
|
|
416
|
+
/* Set 'container-type: inline-size;' to reference container*/
|
|
417
|
+
}
|
|
391
418
|
@container (width < 576px) {
|
|
392
419
|
.slider__navigation-button {
|
|
393
420
|
visibility: visible;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type { Locale } from '
|
|
1
|
+
import type { Locale } from '../../../core/locale';
|
|
2
2
|
import { type SliderDotsConfig, SliderMode } from './types';
|
|
3
3
|
import { type Snippet } from 'svelte';
|
|
4
|
-
declare
|
|
5
|
-
props
|
|
4
|
+
declare function $$render<T>(): {
|
|
5
|
+
props: {
|
|
6
6
|
items: T[];
|
|
7
7
|
initialIndex: number;
|
|
8
8
|
sliderMode?: SliderMode;
|
|
@@ -11,11 +11,18 @@ declare class __sveltets_Render<T> {
|
|
|
11
11
|
locale: Locale;
|
|
12
12
|
on?: {
|
|
13
13
|
indexChanged: (index: number) => void;
|
|
14
|
-
}
|
|
14
|
+
};
|
|
15
15
|
children: Snippet<[T]>;
|
|
16
16
|
};
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
exports: {};
|
|
18
|
+
bindings: "";
|
|
19
|
+
slots: {};
|
|
20
|
+
events: {};
|
|
21
|
+
};
|
|
22
|
+
declare class __sveltets_Render<T> {
|
|
23
|
+
props(): ReturnType<typeof $$render<T>>['props'];
|
|
24
|
+
events(): ReturnType<typeof $$render<T>>['events'];
|
|
25
|
+
slots(): ReturnType<typeof $$render<T>>['slots'];
|
|
19
26
|
bindings(): "";
|
|
20
27
|
exports(): {};
|
|
21
28
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TouchSynchronizer } from './touch-synchronizer';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TouchSynchronizer } from './touch-synchronizer';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare class TouchSynchronizer {
|
|
2
|
+
private static listeners;
|
|
3
|
+
static touchStarted: (ref: HTMLElement) => void;
|
|
4
|
+
static touchMovePropagationBlocked: (ref: HTMLElement) => void;
|
|
5
|
+
static touchEndPropatationBlocked: (ref: HTMLElement) => void;
|
|
6
|
+
static touchEnded: (ref: HTMLElement) => void;
|
|
7
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export class TouchSynchronizer {
|
|
2
|
+
static listeners = [];
|
|
3
|
+
static touchStarted = (ref) => {
|
|
4
|
+
TouchSynchronizer.listeners.push(ref);
|
|
5
|
+
};
|
|
6
|
+
static touchMovePropagationBlocked = (ref) => {
|
|
7
|
+
const otherListeners = TouchSynchronizer.listeners.filter((r) => r !== ref);
|
|
8
|
+
otherListeners.forEach((r) => {
|
|
9
|
+
r.dispatchEvent(new TouchEvent('touchend', { cancelable: false }));
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
static touchEndPropatationBlocked = (ref) => {
|
|
13
|
+
const otherListeners = TouchSynchronizer.listeners.filter((r) => r !== ref);
|
|
14
|
+
otherListeners.forEach((r) => {
|
|
15
|
+
r.dispatchEvent(new TouchEvent('touchend', { cancelable: false }));
|
|
16
|
+
});
|
|
17
|
+
};
|
|
18
|
+
static touchEnded = (ref) => {
|
|
19
|
+
TouchSynchronizer.listeners = TouchSynchronizer.listeners.filter((r) => r !== ref);
|
|
20
|
+
};
|
|
21
|
+
}
|
|
@@ -51,7 +51,7 @@ const styles = $derived.by(() => {
|
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
53
|
:host,
|
|
54
|
-
:global([data-theme=
|
|
54
|
+
:global([data-theme='default']) {
|
|
55
55
|
/* Backgrounds */
|
|
56
56
|
--sc-mc-color--bg-button: #ffffff;
|
|
57
57
|
--sc-mc-color--bg-card: #ffffff;
|
|
@@ -84,7 +84,7 @@ const styles = $derived.by(() => {
|
|
|
84
84
|
--sc-mc-color--text-inactive: #e5e7eb;
|
|
85
85
|
}
|
|
86
86
|
|
|
87
|
-
:global([data-theme=
|
|
87
|
+
:global([data-theme='dark']) {
|
|
88
88
|
/* Backgrounds */
|
|
89
89
|
--sc-mc-color--bg-button: #111827;
|
|
90
90
|
--sc-mc-color--bg-card: #000000;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamscloud/embeddable",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "14.0.0-rc.0",
|
|
4
4
|
"author": "StreamsCloud",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -131,7 +131,7 @@
|
|
|
131
131
|
"peerDependencies": {
|
|
132
132
|
"@fluentui/svg-icons": "^1.1.301",
|
|
133
133
|
"@popperjs/core": "^2.11.8",
|
|
134
|
-
"@streamscloud/streams-analytics-collector": "^
|
|
134
|
+
"@streamscloud/streams-analytics-collector": "^3.0.0",
|
|
135
135
|
"@urql/core": "^5.1.1",
|
|
136
136
|
"dequal": "^2.0.3",
|
|
137
137
|
"dompurify": "^3.2.6",
|
package/dist/ui/slider/index.js
DELETED
|
File without changes
|
|
File without changes
|