@spatial-elements/sveltekit 1.0.0-beta.5 → 1.0.0-beta.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/catalog/catalogTransition.css +12 -0
- package/dist/spatial-element/BrandStageShell.svelte +10 -1
- package/dist/spatial-element/BrandStageShell.svelte.d.ts +2 -0
- package/dist/spatial-element/CarouselSection.svelte +341 -322
- package/dist/spatial-element/CarouselSection.svelte.d.ts +2 -7
- package/dist/spatial-element/CarouselSpatialElement.svelte +140 -126
- package/dist/spatial-element/CarouselSpatialElement.svelte.d.ts +5 -1
- package/dist/spatial-element/ListSection.svelte +7 -1
- package/dist/spatial-element/PointerHint.svelte +78 -0
- package/dist/spatial-element/PointerHint.svelte.d.ts +3 -0
- package/dist/spatial-element/SpatialElementCard.svelte +66 -1
- package/dist/spatial-element/SpatialElementMediaRail.svelte +20 -2
- package/dist/spatial-element/SpatialElementPage.svelte +0 -3
- package/dist/spatial-element/SpatialElementSummaryContent.svelte +182 -0
- package/dist/spatial-element/SpatialElementSummaryContent.svelte.d.ts +18 -0
- package/dist/spatial-element/SpatialElementSummaryPanel.svelte +5 -370
- package/dist/spatial-element/carouselTextHit.d.ts +2 -0
- package/dist/spatial-element/carouselTextHit.js +17 -0
- package/dist/spatial-element/truncatedTitle.d.ts +5 -0
- package/dist/spatial-element/truncatedTitle.js +28 -0
- package/dist/stage/Stage.svelte +42 -2
- package/dist/stage/Stage.svelte.d.ts +1 -0
- package/dist/stage/StageViewport.svelte +7 -1
- package/package.json +2 -2
|
@@ -57,3 +57,15 @@
|
|
|
57
57
|
.stage[data-catalog-transition] [data-catalog-transition-group] * {
|
|
58
58
|
pointer-events: none !important;
|
|
59
59
|
}
|
|
60
|
+
|
|
61
|
+
/* The persistent shell is already present at both restored scroll positions. */
|
|
62
|
+
.stage[data-catalog-transition] [data-catalog-shell-continuous] {
|
|
63
|
+
--catalog-content-opacity: 1;
|
|
64
|
+
--stage-transition-opacity: 1;
|
|
65
|
+
opacity: 1 !important;
|
|
66
|
+
visibility: visible !important;
|
|
67
|
+
}
|
|
68
|
+
.stage[data-catalog-transition] [data-catalog-shell-continuous] [data-catalog-transition-group='enter'] {
|
|
69
|
+
--stage-transition-opacity: 1;
|
|
70
|
+
visibility: visible !important;
|
|
71
|
+
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import type { Snippet } from 'svelte';
|
|
3
|
+
import { retainDeviceOrientationPermission } from '@spatial-elements/core/catalog/listDeviceOrientation';
|
|
3
4
|
import Stage from '../stage/Stage.svelte';
|
|
5
|
+
import PointerHint from './PointerHint.svelte';
|
|
4
6
|
import type { StageRenderSettings } from '@spatial-elements/core';
|
|
5
7
|
import { getSpatialThemeStyle } from './spatialThemeStyle.js';
|
|
6
8
|
import { provideSpatialTheme } from './brandContext.js';
|
|
@@ -9,6 +11,8 @@
|
|
|
9
11
|
import type { SpatialTheme } from '@spatial-elements/core/spatial-element/types';
|
|
10
12
|
|
|
11
13
|
interface Props {
|
|
14
|
+
/** Enable automatic sensor access / permission on internal navigation for opted-in lists. */
|
|
15
|
+
deviceOrientation?: boolean;
|
|
12
16
|
/** Shared appearance and namespace. Use createSpatialTheme for defaults. */
|
|
13
17
|
theme: SpatialTheme;
|
|
14
18
|
/** Resolved by the host. System preference and persistence belong to the shell. */
|
|
@@ -23,7 +27,10 @@
|
|
|
23
27
|
children?: Snippet;
|
|
24
28
|
}
|
|
25
29
|
|
|
26
|
-
let { theme, colorScheme, messages, renderSettings, dracoDecoderPath, children }: Props = $props();
|
|
30
|
+
let { theme, colorScheme, messages, renderSettings, dracoDecoderPath, children, deviceOrientation = false }: Props = $props();
|
|
31
|
+
$effect(() => {
|
|
32
|
+
if (deviceOrientation) return retainDeviceOrientationPermission();
|
|
33
|
+
});
|
|
27
34
|
|
|
28
35
|
provideSpatialTheme(() => theme);
|
|
29
36
|
provideSpatialMessages(() => messages);
|
|
@@ -33,6 +40,7 @@
|
|
|
33
40
|
|
|
34
41
|
<div class="brand-stage-shell" style={brandStyle} style:color-scheme={colorScheme} data-color-scheme={colorScheme}>
|
|
35
42
|
<Stage
|
|
43
|
+
{deviceOrientation}
|
|
36
44
|
brandId={theme.id}
|
|
37
45
|
{renderSettings}
|
|
38
46
|
{dracoDecoderPath}
|
|
@@ -43,6 +51,7 @@
|
|
|
43
51
|
>
|
|
44
52
|
{@render children?.()}
|
|
45
53
|
</Stage>
|
|
54
|
+
<PointerHint />
|
|
46
55
|
</div>
|
|
47
56
|
|
|
48
57
|
<style>
|
|
@@ -3,6 +3,8 @@ import type { StageRenderSettings } from '@spatial-elements/core';
|
|
|
3
3
|
import type { SpatialMessagesInput } from '@spatial-elements/core/spatial-element/messages';
|
|
4
4
|
import type { SpatialTheme } from '@spatial-elements/core/spatial-element/types';
|
|
5
5
|
interface Props {
|
|
6
|
+
/** Enable automatic sensor access / permission on internal navigation for opted-in lists. */
|
|
7
|
+
deviceOrientation?: boolean;
|
|
6
8
|
/** Shared appearance and namespace. Use createSpatialTheme for defaults. */
|
|
7
9
|
theme: SpatialTheme;
|
|
8
10
|
/** Resolved by the host. System preference and persistence belong to the shell. */
|