@morphika/andami 0.5.0 → 0.5.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/README.md +151 -36
- package/app/admin/assets/page.tsx +6 -6
- package/app/admin/database/page.tsx +302 -302
- package/app/admin/error.tsx +53 -53
- package/app/admin/layout.tsx +320 -327
- package/app/admin/navigation/page.tsx +255 -255
- package/app/admin/pages/[slug]/page.tsx +6 -6
- package/app/admin/pages/page.tsx +11 -11
- package/app/admin/projects/page.tsx +14 -14
- package/app/admin/setup/page.tsx +1 -1
- package/app/admin/styles/page.tsx +1 -1
- package/components/admin/MetadataEditor.tsx +6 -6
- package/components/admin/nav-builder/NavBuilder.tsx +1 -1
- package/components/admin/nav-builder/NavBuilderGrid.tsx +3 -3
- package/components/admin/nav-builder/NavGridCell.tsx +48 -48
- package/components/admin/nav-builder/NavGridItem.tsx +4 -4
- package/components/admin/nav-builder/NavItemSettings.tsx +331 -331
- package/components/admin/nav-builder/NavItemTypePicker.tsx +102 -102
- package/components/admin/nav-builder/NavLivePreview.tsx +1 -1
- package/components/admin/nav-builder/NavMobileLivePreview.tsx +226 -226
- package/components/admin/nav-builder/NavMobileSettings.tsx +242 -242
- package/components/admin/nav-builder/NavSettingsFields.tsx +514 -514
- package/components/admin/setup-wizard/BrandingStep.tsx +3 -3
- package/components/admin/setup-wizard/DatabaseStep.tsx +2 -2
- package/components/admin/setup-wizard/DoneStep.tsx +1 -1
- package/components/admin/setup-wizard/SetupWizard.tsx +4 -4
- package/components/admin/setup-wizard/StorageStep.tsx +2 -2
- package/components/admin/setup-wizard/WelcomeStep.tsx +2 -2
- package/components/admin/styles/ColorsEditor.tsx +2 -2
- package/components/admin/styles/FontsEditor.tsx +6 -6
- package/components/admin/styles/GridLayoutEditor.tsx +9 -9
- package/components/admin/styles/LinksButtonsEditor.tsx +5 -5
- package/components/admin/styles/TypographyEditor.tsx +6 -6
- package/components/admin/styles/shared.tsx +68 -68
- package/components/blocks/AudioBlockRenderer.tsx +286 -0
- package/components/blocks/BeforeAfterBlockRenderer.tsx +274 -0
- package/components/blocks/MarqueeBlockRenderer.tsx +316 -0
- package/components/blocks/ProjectCarouselBlockRenderer.tsx +1 -1
- package/components/builder/BlockCardIcons.tsx +316 -227
- package/components/builder/BlockTypePicker.tsx +3 -1
- package/components/builder/BubbleIcons.tsx +90 -0
- package/components/builder/BuilderCanvas.tsx +2 -0
- package/components/builder/CanvasMinimap.tsx +2 -2
- package/components/builder/CoverSectionCanvas.tsx +363 -275
- package/components/builder/DeviceFrame.tsx +1 -1
- package/components/builder/DndWrapper.tsx +3 -3
- package/components/builder/InsertionLines.tsx +1 -1
- package/components/builder/SectionCardIcons.tsx +421 -320
- package/components/builder/SectionEditorBar.tsx +1 -1
- package/components/builder/SectionTypePicker.tsx +4 -4
- package/components/builder/SectionV2Canvas.tsx +20 -4
- package/components/builder/SectionV2Column.tsx +74 -68
- package/components/builder/SortableBlock.tsx +93 -73
- package/components/builder/SortableRow.tsx +27 -26
- package/components/builder/VirtualAssetGrid.tsx +2 -2
- package/components/builder/asset-browser/R2BrowserContent.tsx +34 -17
- package/components/builder/asset-browser/helpers.ts +4 -0
- package/components/builder/asset-browser/types.ts +2 -1
- package/components/builder/blockStyles.tsx +192 -173
- package/components/builder/color-picker/AlphaSlider.tsx +141 -141
- package/components/builder/color-picker/ColorInputs.tsx +105 -105
- package/components/builder/color-picker/EyedropperButton.tsx +74 -74
- package/components/builder/color-picker/HueSlider.tsx +124 -124
- package/components/builder/color-picker/SaturationCanvas.tsx +142 -142
- package/components/builder/color-picker/SwatchBar.tsx +93 -93
- package/components/builder/editors/AudioBlockEditor.tsx +242 -0
- package/components/builder/editors/BeforeAfterBlockEditor.tsx +360 -0
- package/components/builder/editors/ButtonBlockEditor.tsx +4 -4
- package/components/builder/editors/EnterAnimationPicker.tsx +2 -2
- package/components/builder/editors/HoverEffectPicker.tsx +2 -2
- package/components/builder/editors/ImageBlockEditor.tsx +2 -2
- package/components/builder/editors/ImageGridBlockEditor.tsx +4 -4
- package/components/builder/editors/MarqueeBlockEditor.tsx +621 -0
- package/components/builder/editors/ProjectCarouselBlockEditor.tsx +443 -443
- package/components/builder/editors/ProjectGridEditor.tsx +9 -9
- package/components/builder/editors/SpacerBlockEditor.tsx +5 -5
- package/components/builder/editors/StaggerSettings.tsx +109 -109
- package/components/builder/editors/TextBlockEditor.tsx +3 -3
- package/components/builder/editors/TextStylePicker.tsx +1 -1
- package/components/builder/editors/VideoBlockEditor.tsx +2 -2
- package/components/builder/editors/index.ts +11 -10
- package/components/builder/editors/shared.tsx +7 -7
- package/components/builder/live-preview/LiveAudioPreview.tsx +120 -0
- package/components/builder/live-preview/LiveBeforeAfterPreview.tsx +176 -0
- package/components/builder/live-preview/LiveImageGridPreview.tsx +10 -2
- package/components/builder/live-preview/LiveImagePreview.tsx +1 -1
- package/components/builder/live-preview/LiveMarqueePreview.tsx +39 -0
- package/components/builder/live-preview/LiveProjectCarouselPreview.tsx +1 -1
- package/components/builder/live-preview/LiveVideoPreview.tsx +1 -1
- package/components/builder/live-preview/ProjectCardWrapper.tsx +291 -291
- package/components/builder/settings-panel/AnimationTab.tsx +138 -138
- package/components/builder/settings-panel/BlockLayoutTab.tsx +7 -7
- package/components/builder/settings-panel/CardEntranceSection.tsx +114 -114
- package/components/builder/settings-panel/ColumnV2Settings.tsx +5 -5
- package/components/builder/settings-panel/CoverSectionLayoutTab.tsx +71 -71
- package/components/builder/settings-panel/CoverSectionSettings.tsx +335 -335
- package/components/builder/settings-panel/PageSettings.tsx +3 -3
- package/components/builder/settings-panel/ParallaxSlideSettings.tsx +2 -2
- package/components/builder/settings-panel/SectionV2AnimationTab.tsx +4 -4
- package/components/builder/settings-panel/SectionV2LayoutTab.tsx +356 -356
- package/components/builder/settings-panel/SectionV2Settings.tsx +14 -14
- package/components/builder/settings-panel/TRBLInputs.tsx +1 -1
- package/lib/animation/enter-types.ts +3 -0
- package/lib/animation/hover-effect-presets.ts +210 -210
- package/lib/animation/hover-effect-types.ts +3 -0
- package/lib/builder/block-registrations.ts +468 -335
- package/lib/builder/constants.ts +111 -111
- package/lib/builder/store-sections.ts +2 -2
- package/lib/builder/types-slices.ts +414 -414
- package/lib/builder/types.ts +6 -1
- package/lib/config/index.ts +27 -27
- package/lib/sanity/types.ts +156 -1
- package/lib/version.ts +1 -1
- package/package.json +1 -1
- package/sanity/schemas/blocks/audioBlock.ts +69 -0
- package/sanity/schemas/blocks/beforeAfterBlock.ts +121 -0
- package/sanity/schemas/blocks/index.ts +12 -9
- package/sanity/schemas/blocks/marqueeBlock.ts +292 -0
- package/sanity/schemas/index.ts +120 -111
- package/styles/admin.css +85 -85
- package/styles/animations.css +237 -237
- package/styles/base.css +114 -114
|
@@ -0,0 +1,316 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { useEffect, useId, useRef, useState } from "react";
|
|
4
|
+
import type {
|
|
5
|
+
MarqueeBlock,
|
|
6
|
+
MarqueeItem,
|
|
7
|
+
MarqueeFontSize,
|
|
8
|
+
MarqueeImageItem,
|
|
9
|
+
} from "../../lib/sanity/types";
|
|
10
|
+
import { useAssetUrl } from "../../lib/contexts/AssetContext";
|
|
11
|
+
import { handleImageRetry } from "../../lib/asset-retry";
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Marquee Block — horizontal infinite-scroll ticker.
|
|
15
|
+
*
|
|
16
|
+
* Rendering strategy:
|
|
17
|
+
* 1. Render the items array twice back-to-back (copy A + copy B).
|
|
18
|
+
* 2. Animate container via CSS @keyframes from translateX(0) to
|
|
19
|
+
* translateX(-<copy-width>px). When copy A scrolls fully out of
|
|
20
|
+
* view, copy B is exactly where copy A started — seamless loop.
|
|
21
|
+
* 3. Measure copy-width after mount with a ResizeObserver so the
|
|
22
|
+
* loop distance stays accurate when fonts load or items change.
|
|
23
|
+
* 4. Duration = copyWidth / speed — gives a constant *pixel-per-second*
|
|
24
|
+
* rate independent of how many items the user adds.
|
|
25
|
+
* 5. IntersectionObserver pauses animation when off-screen → zero CPU
|
|
26
|
+
* off-screen. Matches Andami's Hobby-tier CPU budget philosophy.
|
|
27
|
+
* 6. `prefers-reduced-motion`: renders a single static copy, no
|
|
28
|
+
* animation, no duplicate.
|
|
29
|
+
*
|
|
30
|
+
* Hover effects and enter animations are handled by wrappers one level up
|
|
31
|
+
* (ScrollAnimationWrapper / HoverAnimationWrapper) — this component only
|
|
32
|
+
* deals with the marquee itself.
|
|
33
|
+
*/
|
|
34
|
+
|
|
35
|
+
// ── Font-size scale → rem ─────────────────────────────────────────
|
|
36
|
+
const FONT_SIZE_REM: Record<MarqueeFontSize, number> = {
|
|
37
|
+
s: 0.875,
|
|
38
|
+
base: 1,
|
|
39
|
+
l: 1.25,
|
|
40
|
+
xl: 1.5,
|
|
41
|
+
"2xl": 2,
|
|
42
|
+
"3xl": 3,
|
|
43
|
+
"4xl": 4.5,
|
|
44
|
+
"5xl": 6,
|
|
45
|
+
"6xl": 8,
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
// ── Props ─────────────────────────────────────────────────────────
|
|
49
|
+
|
|
50
|
+
export interface MarqueeBlockRendererProps {
|
|
51
|
+
block: MarqueeBlock;
|
|
52
|
+
/**
|
|
53
|
+
* Multiplier applied to the configured speed. The public site uses 1
|
|
54
|
+
* (the default); the builder's live preview passes 0.3 to show slow
|
|
55
|
+
* movement without distracting while editing.
|
|
56
|
+
*/
|
|
57
|
+
speedMultiplier?: number;
|
|
58
|
+
/**
|
|
59
|
+
* When true, disables the IntersectionObserver pause — useful in the
|
|
60
|
+
* builder where the block is always visible inside its own scrollable
|
|
61
|
+
* canvas and the observer would otherwise report false positives.
|
|
62
|
+
*/
|
|
63
|
+
alwaysPlay?: boolean;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
// ── Helpers ───────────────────────────────────────────────────────
|
|
67
|
+
|
|
68
|
+
function useReducedMotion(): boolean {
|
|
69
|
+
const [reduced, setReduced] = useState(false);
|
|
70
|
+
useEffect(() => {
|
|
71
|
+
if (typeof window === "undefined" || !window.matchMedia) return;
|
|
72
|
+
const mq = window.matchMedia("(prefers-reduced-motion: reduce)");
|
|
73
|
+
const update = () => setReduced(mq.matches);
|
|
74
|
+
update();
|
|
75
|
+
mq.addEventListener?.("change", update);
|
|
76
|
+
return () => mq.removeEventListener?.("change", update);
|
|
77
|
+
}, []);
|
|
78
|
+
return reduced;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
// ── Main component ───────────────────────────────────────────────
|
|
82
|
+
|
|
83
|
+
export default function MarqueeBlockRenderer({
|
|
84
|
+
block,
|
|
85
|
+
speedMultiplier = 1,
|
|
86
|
+
alwaysPlay = false,
|
|
87
|
+
}: MarqueeBlockRendererProps) {
|
|
88
|
+
const resolveAsset = useAssetUrl();
|
|
89
|
+
const reduced = useReducedMotion();
|
|
90
|
+
const reactId = useId();
|
|
91
|
+
const animationName = `marquee-${reactId.replace(/[^a-zA-Z0-9]/g, "")}`;
|
|
92
|
+
|
|
93
|
+
const rootRef = useRef<HTMLDivElement | null>(null);
|
|
94
|
+
const trackRef = useRef<HTMLDivElement | null>(null);
|
|
95
|
+
const copyRef = useRef<HTMLDivElement | null>(null);
|
|
96
|
+
const [copyWidth, setCopyWidth] = useState<number>(0);
|
|
97
|
+
const [inView, setInView] = useState<boolean>(true);
|
|
98
|
+
|
|
99
|
+
const items = block.items ?? [];
|
|
100
|
+
const direction = block.direction ?? "left";
|
|
101
|
+
const rawSpeed = block.speed ?? 60;
|
|
102
|
+
const speed = Math.max(1, rawSpeed * speedMultiplier);
|
|
103
|
+
const pauseOnHover = block.pause_on_hover !== false;
|
|
104
|
+
|
|
105
|
+
// Typography
|
|
106
|
+
const fontSize = FONT_SIZE_REM[block.font_size ?? "3xl"] ?? FONT_SIZE_REM["3xl"];
|
|
107
|
+
const fontWeight = block.font_weight ?? "700";
|
|
108
|
+
const color = block.color ?? "#111111";
|
|
109
|
+
const textStyle = block.text_style ?? "solid";
|
|
110
|
+
const letterSpacing = block.letter_spacing ?? 0;
|
|
111
|
+
const textTransform = block.text_transform ?? "uppercase";
|
|
112
|
+
|
|
113
|
+
// Layout
|
|
114
|
+
const gap = block.gap ?? 48;
|
|
115
|
+
const rowHeight = block.row_height ?? 120;
|
|
116
|
+
const paddingY = block.padding_y ?? 16;
|
|
117
|
+
const backgroundColor = block.background_color || undefined;
|
|
118
|
+
|
|
119
|
+
// Measure copy width on mount, resize, and when items change.
|
|
120
|
+
useEffect(() => {
|
|
121
|
+
if (reduced || !copyRef.current) return;
|
|
122
|
+
const el = copyRef.current;
|
|
123
|
+
const measure = () => setCopyWidth(el.getBoundingClientRect().width);
|
|
124
|
+
measure();
|
|
125
|
+
const ro = new ResizeObserver(measure);
|
|
126
|
+
ro.observe(el);
|
|
127
|
+
return () => ro.disconnect();
|
|
128
|
+
}, [reduced, items.length, gap, rowHeight, fontSize, textStyle]);
|
|
129
|
+
|
|
130
|
+
// Pause animation when off-screen.
|
|
131
|
+
useEffect(() => {
|
|
132
|
+
if (alwaysPlay || reduced || !rootRef.current) return;
|
|
133
|
+
const el = rootRef.current;
|
|
134
|
+
const io = new IntersectionObserver(
|
|
135
|
+
(entries) => {
|
|
136
|
+
for (const entry of entries) setInView(entry.isIntersecting);
|
|
137
|
+
},
|
|
138
|
+
{ rootMargin: "100px" }
|
|
139
|
+
);
|
|
140
|
+
io.observe(el);
|
|
141
|
+
return () => io.disconnect();
|
|
142
|
+
}, [alwaysPlay, reduced]);
|
|
143
|
+
|
|
144
|
+
// Duration derived from measured width and configured speed.
|
|
145
|
+
const durationSec = copyWidth > 0 ? copyWidth / speed : 0;
|
|
146
|
+
|
|
147
|
+
// Typography style shared between text + separator items.
|
|
148
|
+
const textItemStyle: React.CSSProperties = {
|
|
149
|
+
fontSize: `${fontSize}rem`,
|
|
150
|
+
fontWeight,
|
|
151
|
+
color: textStyle === "solid" ? color : "transparent",
|
|
152
|
+
letterSpacing: `${letterSpacing}em`,
|
|
153
|
+
textTransform,
|
|
154
|
+
lineHeight: 1,
|
|
155
|
+
whiteSpace: "nowrap",
|
|
156
|
+
fontStyle: textStyle === "italic-outline" ? "italic" : "normal",
|
|
157
|
+
// Outline via -webkit-text-stroke. Supported in all modern browsers.
|
|
158
|
+
...(textStyle !== "solid"
|
|
159
|
+
? {
|
|
160
|
+
WebkitTextStroke: `1px ${color}`,
|
|
161
|
+
}
|
|
162
|
+
: {}),
|
|
163
|
+
};
|
|
164
|
+
|
|
165
|
+
const renderItem = (item: MarqueeItem, keyPrefix: string) => {
|
|
166
|
+
if (item._type === "marqueeText") {
|
|
167
|
+
return (
|
|
168
|
+
<span key={`${keyPrefix}-${item._key}`} style={textItemStyle}>
|
|
169
|
+
{item.text}
|
|
170
|
+
</span>
|
|
171
|
+
);
|
|
172
|
+
}
|
|
173
|
+
if (item._type === "marqueeSeparator") {
|
|
174
|
+
return (
|
|
175
|
+
<span
|
|
176
|
+
key={`${keyPrefix}-${item._key}`}
|
|
177
|
+
style={textItemStyle}
|
|
178
|
+
aria-hidden="true"
|
|
179
|
+
>
|
|
180
|
+
{item.character || "•"}
|
|
181
|
+
</span>
|
|
182
|
+
);
|
|
183
|
+
}
|
|
184
|
+
// marqueeImage
|
|
185
|
+
const img = item as MarqueeImageItem;
|
|
186
|
+
const height = rowHeight;
|
|
187
|
+
const widthStyle: React.CSSProperties = img.width
|
|
188
|
+
? { width: `${img.width}px` }
|
|
189
|
+
: { width: "auto" };
|
|
190
|
+
const radius = img.border_radius ? `${img.border_radius}px` : undefined;
|
|
191
|
+
return (
|
|
192
|
+
/* eslint-disable-next-line @next/next/no-img-element */
|
|
193
|
+
<img
|
|
194
|
+
key={`${keyPrefix}-${item._key}`}
|
|
195
|
+
src={resolveAsset(img.asset_path)}
|
|
196
|
+
alt={img.alt || ""}
|
|
197
|
+
onError={handleImageRetry}
|
|
198
|
+
loading="lazy"
|
|
199
|
+
decoding="async"
|
|
200
|
+
style={{
|
|
201
|
+
height: `${height}px`,
|
|
202
|
+
...widthStyle,
|
|
203
|
+
objectFit: "contain",
|
|
204
|
+
borderRadius: radius,
|
|
205
|
+
display: "block",
|
|
206
|
+
flexShrink: 0,
|
|
207
|
+
}}
|
|
208
|
+
/>
|
|
209
|
+
);
|
|
210
|
+
};
|
|
211
|
+
|
|
212
|
+
const renderCopy = (keyPrefix: string, hidden: boolean) => (
|
|
213
|
+
<div
|
|
214
|
+
ref={keyPrefix === "a" ? copyRef : undefined}
|
|
215
|
+
aria-hidden={hidden || undefined}
|
|
216
|
+
style={{
|
|
217
|
+
display: "flex",
|
|
218
|
+
alignItems: "center",
|
|
219
|
+
gap: `${gap}px`,
|
|
220
|
+
paddingRight: `${gap}px`, // trailing gap so last→first wrap doesn't collide
|
|
221
|
+
flexShrink: 0,
|
|
222
|
+
}}
|
|
223
|
+
>
|
|
224
|
+
{items.map((item) => renderItem(item, keyPrefix))}
|
|
225
|
+
</div>
|
|
226
|
+
);
|
|
227
|
+
|
|
228
|
+
// Graceful empty state — nothing to render.
|
|
229
|
+
if (items.length === 0) {
|
|
230
|
+
return (
|
|
231
|
+
<div
|
|
232
|
+
style={{
|
|
233
|
+
height: `${rowHeight + paddingY * 2}px`,
|
|
234
|
+
backgroundColor,
|
|
235
|
+
display: "flex",
|
|
236
|
+
alignItems: "center",
|
|
237
|
+
justifyContent: "center",
|
|
238
|
+
color: "#9ca3af",
|
|
239
|
+
fontSize: "14px",
|
|
240
|
+
fontFamily: "Inter, system-ui, sans-serif",
|
|
241
|
+
}}
|
|
242
|
+
>
|
|
243
|
+
Empty marquee — add items to get started.
|
|
244
|
+
</div>
|
|
245
|
+
);
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
// Reduced motion: render a single static copy, no animation.
|
|
249
|
+
if (reduced) {
|
|
250
|
+
return (
|
|
251
|
+
<div
|
|
252
|
+
ref={rootRef}
|
|
253
|
+
role="group"
|
|
254
|
+
aria-label="Marquee (animation disabled due to reduced-motion preference)"
|
|
255
|
+
style={{
|
|
256
|
+
width: "100%",
|
|
257
|
+
overflow: "hidden",
|
|
258
|
+
backgroundColor,
|
|
259
|
+
paddingTop: `${paddingY}px`,
|
|
260
|
+
paddingBottom: `${paddingY}px`,
|
|
261
|
+
}}
|
|
262
|
+
>
|
|
263
|
+
{renderCopy("a", false)}
|
|
264
|
+
</div>
|
|
265
|
+
);
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
const animationPlayState = inView ? "running" : "paused";
|
|
269
|
+
const animationDirection = direction === "right" ? "reverse" : "normal";
|
|
270
|
+
|
|
271
|
+
return (
|
|
272
|
+
<div
|
|
273
|
+
ref={rootRef}
|
|
274
|
+
role="group"
|
|
275
|
+
aria-label="Marquee"
|
|
276
|
+
className={pauseOnHover ? "marquee-hoverable" : undefined}
|
|
277
|
+
style={{
|
|
278
|
+
width: "100%",
|
|
279
|
+
overflow: "hidden",
|
|
280
|
+
backgroundColor,
|
|
281
|
+
paddingTop: `${paddingY}px`,
|
|
282
|
+
paddingBottom: `${paddingY}px`,
|
|
283
|
+
}}
|
|
284
|
+
>
|
|
285
|
+
{/* Inline keyframes + hover rule scoped per-instance via unique name. */}
|
|
286
|
+
<style>{`
|
|
287
|
+
@keyframes ${animationName} {
|
|
288
|
+
from { transform: translateX(0); }
|
|
289
|
+
to { transform: translateX(-${copyWidth}px); }
|
|
290
|
+
}
|
|
291
|
+
.marquee-hoverable:hover [data-marquee-track="${animationName}"] {
|
|
292
|
+
animation-play-state: paused;
|
|
293
|
+
}
|
|
294
|
+
`}</style>
|
|
295
|
+
|
|
296
|
+
<div
|
|
297
|
+
ref={trackRef}
|
|
298
|
+
data-marquee-track={animationName}
|
|
299
|
+
style={{
|
|
300
|
+
display: "flex",
|
|
301
|
+
width: "max-content",
|
|
302
|
+
willChange: "transform",
|
|
303
|
+
animationName: durationSec > 0 ? animationName : undefined,
|
|
304
|
+
animationDuration: durationSec > 0 ? `${durationSec}s` : undefined,
|
|
305
|
+
animationTimingFunction: "linear",
|
|
306
|
+
animationIterationCount: "infinite",
|
|
307
|
+
animationPlayState,
|
|
308
|
+
animationDirection,
|
|
309
|
+
}}
|
|
310
|
+
>
|
|
311
|
+
{renderCopy("a", false)}
|
|
312
|
+
{renderCopy("b", true)}
|
|
313
|
+
</div>
|
|
314
|
+
</div>
|
|
315
|
+
);
|
|
316
|
+
}
|
|
@@ -391,7 +391,7 @@ export default function ProjectCarouselBlockRenderer({
|
|
|
391
391
|
<div
|
|
392
392
|
ref={trackRef}
|
|
393
393
|
onScroll={handleScroll}
|
|
394
|
-
className="flex overflow-x-auto no-scrollbar"
|
|
394
|
+
className="flex overflow-x-auto no-scrollbar py-3"
|
|
395
395
|
style={{
|
|
396
396
|
gap: `${gap}px`,
|
|
397
397
|
scrollSnapType: snapScroll ? "x mandatory" : undefined,
|