Skip to content

feat: entrance motion on layout and headline bloks - #417

Draft
dmnktoe wants to merge 1 commit into
mainfrom
cursor/entrance-motion-8178
Draft

dmnktoe wants to merge 1 commit into
mainfrom
cursor/entrance-motion-8178

Conversation

@dmnktoe

@dmnktoe dmnktoe commented Sep 3, 2026

Copy link
Copy Markdown
Owner

⇝pull request

*ੈ✩‧₊˚༺☆༻*ੈ✩‧₊˚

what & why

Section, container, grid, grid item, and headline get a Motion tab. Default is none, so existing pages stay still. Reduced motion stays off.

Closes #2

scope

@httpjpg/storyblok-sync · @httpjpg/storyblok-ui

change type

  • feat — new feature · Added · minor
  • fix — bug fix · Fixed · patch
  • refactor / style / revert · Changed · patch
  • perf — faster or leaner · Performance · patch
  • build / ci / docs / test · Tooling · patch
  • deps — dependency bump · Dependencies · patch
  • chore — hidden from the changelog · patch
  • carries a BREAKING CHANGE: footer · ⚠ BREAKING · major

checklist — every pull request
  • Follows the conventions in CLAUDE.md — I read a neighbouring file before inventing a pattern
  • Scoped: no drive-by refactors bundled with the feature
  • Server Components by default; any new "use client" boundary is as small as possible
  • Tests added or updated next to the source (*.test.ts(x))
  • Did not hand-edit the root package.json version, .release-please-manifest.json or CHANGELOG.md
storyblok / cms — only if a blok or schema moved
  • Schema added or updated in packages/storyblok-sync/scripts/blocks/*
  • sync:components (and sync:datasources for new CMS_OPTIONS) run against Storyblok
  • Motion via withMotion() / BlokMotion
  • editableAttrs(blok) still spread on the root

notes for reviewers

Split out of #413.

  • withMotion() appends the tab. Runtime BlokMotion is a no-op unless an animation is set.
  • Slideshow already had a motion field; it now shares ENTRANCE_ANIMATION_OPTIONS.

CMS is not pushed from this PR. After merge:

pnpm --filter @httpjpg/storyblok-sync sync:components

Shares layout.ts, SbGrid, and SbGridItem with the signed-margins PR. Rebase after that one merges.

Open in Web Open in Cursor 

Motion tab defaults to none. Runtime wrapper is a no-op unless an
animation is set, so existing pages stay still.

Closes #2
@codecov

codecov Bot commented Sep 3, 2026

Copy link
Copy Markdown

Bundle Report

Changes will increase total bundle size by 14.69kB (0.08%) ⬆️. This is within the configured threshold ✅

Detailed changes
Bundle name Size Change
portfolio-server-cjs 11.05MB 2.27kB (0.02%) ⬆️
portfolio-client-array-push 3.42MB 12.41kB (0.36%) ⬆️

Affected Assets, Files, and Routes:

view changes for bundle: portfolio-client-array-push

Assets Changed:

Asset Name Size Change Total Size Change (%)
server/app/_global-*.js 791 bytes 97.34kB 0.82%
server/app/_not-*.js 791 bytes 97.34kB 0.82%
server/app/(portfolio)/[...slug]/page_client-*.js 791 bytes 97.28kB 0.82%
server/app/page_client-*.js 791 bytes 97.25kB 0.82%
server/app/(portfolio)/cookie-*.js 791 bytes 88.79kB 0.9%
server/app/api/psn-*.js 783 bytes 63.91kB 1.24%
server/app/api/cloudflare/route_client-*.js 781 bytes 63.75kB 1.24%
server/app/api/letterboxd/route_client-*.js 781 bytes 63.75kB 1.24%
server/app/work/feed.xml/route_client-*.js 780 bytes 63.67kB 1.24%
server/app/api/discogs/route_client-*.js 778 bytes 63.5kB 1.24%
server/app/api/discord/route_client-*.js 778 bytes 63.5kB 1.24%
server/app/api/weather/route_client-*.js 778 bytes 63.5kB 1.24%
server/app/api/status/route_client-*.js 776 bytes 63.34kB 1.24%
server/app/api/x/route_client-*.js 772 bytes 63.01kB 1.24%
static/chunks/app/layout-*.js 558 bytes 47.78kB 1.18%
static/chunks/4680-*.js -1 bytes 28.11kB -0.0%
static/chunks/7259-*.js (New) 18.7kB 18.7kB 100.0% 🚀
static/chunks/app/(portfolio)/[...slug]/page-*.js 40 bytes 11.42kB 0.35%
static/chunks/app/api/cloudflare/route-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/api/discogs/route-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/api/discord/route-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/api/letterboxd/route-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/api/psn-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/api/status/route-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/api/weather/route-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/api/x/route-*.js 40 bytes 3.48kB 1.16%
static/chunks/app/work/feed.xml/route-*.js 40 bytes 3.48kB 1.16%
static/jvgzGCzXGygiZW0jFksZt/_buildManifest.js (New) 1.5kB 1.5kB 100.0% 🚀
react-*.json -1 bytes 901 bytes -0.11%
server/middleware-*.js -1 bytes 841 bytes -0.12%
static/chunks/5402.*.js (New) 681 bytes 681 bytes 100.0% 🚀
static/chunks/8173.*.js (New) 680 bytes 680 bytes 100.0% 🚀
static/jvgzGCzXGygiZW0jFksZt/_ssgManifest.js (New) 77 bytes 77 bytes 100.0% 🚀
static/chunks/6996-*.js (Deleted) -18.21kB 0 bytes -100.0% 🗑️
static/sFSdLuN4TFQ8DKJwNDPqs/_buildManifest.js (Deleted) -1.5kB 0 bytes -100.0% 🗑️
static/chunks/3218.*.js (Deleted) -681 bytes 0 bytes -100.0% 🗑️
static/chunks/8586.*.js (Deleted) -681 bytes 0 bytes -100.0% 🗑️
static/sFSdLuN4TFQ8DKJwNDPqs/_ssgManifest.js (Deleted) -77 bytes 0 bytes -100.0% 🗑️

App Routes Affected:

App Route Size Change Total Size Change (%)
/ 557 bytes 78.69kB 0.71%
view changes for bundle: portfolio-server-cjs

Assets Changed:

Asset Name Size Change Total Size Change (%)
7321.js (New) 429.17kB 429.17kB 100.0% 🚀
../app/(portfolio)/[...slug]/page.js 81 bytes 160.41kB 0.05%
2869.js (New) 74.84kB 74.84kB 100.0% 🚀
6629.js (New) 68.11kB 68.11kB 100.0% 🚀
2728.js 2 bytes 52.37kB 0.0%
../app/_global-error/page.js 1 bytes 22.61kB 0.0%
../app/(portfolio)/cookie-policy/page.js 1 bytes 21.95kB 0.0%
../app/api/og/[...slug]/route.js 1 bytes 17.89kB 0.01%
../app/work/feed.xml/route.js 1 bytes 12.46kB 0.01%
../app/api/cloudflare/route.js 1 bytes 11.61kB 0.01%
../app/api/discord/route.js 1 bytes 11.03kB 0.01%
../app/api/weather/route.js 1 bytes 10.54kB 0.01%
../app/api/psn-trophies/route.js 1 bytes 9.75kB 0.01%
../app/api/x/route.js 1 bytes 9.55kB 0.01%
../app/api/letterboxd/route.js 1 bytes 9.54kB 0.01%
../app/api/discogs/route.js 1 bytes 9.51kB 0.01%
../app/api/status/route.js 1 bytes 9.24kB 0.01%
../app/page.js 1 bytes 7.33kB 0.01%
8784.js (New) 6.64kB 6.64kB 100.0% 🚀
../app/_not-found/page.js 1 bytes 4.07kB 0.02%
../app/(portfolio)/[...slug]/page.js.nft.json 3 bytes 1.26kB 0.24%
../app/api/cloudflare/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/api/discogs/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/api/discord/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/api/letterboxd/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/api/psn-trophies/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/api/status/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/api/weather/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/api/x/route.js.nft.json 3 bytes 1.24kB 0.24%
../app/work/feed.xml/route.js.nft.json 3 bytes 1.16kB 0.26%
../app/api/og/[...slug]/route.js.nft.json 1 bytes 977 bytes 0.1%
../app/page.js.nft.json 3 bytes 854 bytes 0.35%
../app/(portfolio)/cookie-policy/page.js.nft.json 3 bytes 776 bytes 0.39%
3826.js (New) 616 bytes 616 bytes 100.0% 🚀
7817.js (New) 616 bytes 616 bytes 100.0% 🚀
../app/_not-found/page.js.nft.json 3 bytes 546 bytes 0.55%
../app/_global-error/page.js.nft.json 1 bytes 201 bytes 0.5%
463.js (Deleted) -429.17kB 0 bytes -100.0% 🗑️
4493.js (Deleted) -74.24kB 0 bytes -100.0% 🗑️
6040.js (Deleted) -66.65kB 0 bytes -100.0% 🗑️
5696.js (Deleted) -6.56kB 0 bytes -100.0% 🗑️
718.js (Deleted) -614 bytes 0 bytes -100.0% 🗑️
853.js (Deleted) -614 bytes 0 bytes -100.0% 🗑️

App Routes Affected:

App Route Size Change Total Size Change (%)
/work/feed.xml 5 bytes 264.19kB 0.0%
/api/x 5 bytes 261.28kB 0.0%
/(portfolio)/[...slug] 85 bytes 412.15kB 0.02%
/api/letterboxd 5 bytes 261.27kB 0.0%
/api/weather 5 bytes 262.27kB 0.0%
/api/cloudflare 5 bytes 263.34kB 0.0%
/api/discord 5 bytes 262.76kB 0.0%
/api/status 5 bytes 260.97kB 0.0%
/api/psn-trophies 5 bytes 261.48kB 0.0%
/(portfolio)/cookie-policy 5 bytes 273.68kB 0.0%
/api/og/[...slug] 1 bytes 17.89kB 0.01%
/(portfolio) 86 bytes 434.1kB 0.02%
/ 604 bytes 356.51kB 0.17%
/api/discogs 5 bytes 261.24kB 0.0%

@codecov

codecov Bot commented Sep 3, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 82.35294% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 97.23%. Comparing base (5fad6f3) to head (5fe0fe0).
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
packages/storyblok-ui/src/lib/blok-motion.tsx 62.50% 6 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #417      +/-   ##
==========================================
- Coverage   97.29%   97.23%   -0.06%     
==========================================
  Files         356      358       +2     
  Lines        9109     9129      +20     
  Branches     3091     3096       +5     
==========================================
+ Hits         8863     8877      +14     
- Misses        238      244       +6     
  Partials        8        8              
Components Coverage Δ
ui 97.44% <ø> (ø)
storyblok 96.34% <82.35%> (-0.47%) ⬇️
integrations 93.73% <ø> (ø)
foundations 92.10% <ø> (ø)
portfolio 98.15% <ø> (ø)
Files with missing lines Coverage Δ
packages/storyblok-sync/scripts/blocks/content.ts 100.00% <ø> (ø)
packages/storyblok-sync/scripts/blocks/layout.ts 100.00% <ø> (ø)
packages/storyblok-sync/scripts/blocks/media.ts 100.00% <ø> (ø)
packages/storyblok-sync/scripts/lib/motion.ts 100.00% <100.00%> (ø)
...ryblok-ui/src/components/container/SbContainer.tsx 100.00% <100.00%> (ø)
...oryblok-ui/src/components/grid-item/SbGridItem.tsx 100.00% <100.00%> (ø)
...ckages/storyblok-ui/src/components/grid/SbGrid.tsx 96.42% <100.00%> (ø)
...toryblok-ui/src/components/headline/SbHeadline.tsx 100.00% <100.00%> (ø)
.../storyblok-ui/src/components/section/SbSection.tsx 100.00% <100.00%> (ø)
...ryblok-ui/src/components/slideshow/SbSlideshow.tsx 100.00% <100.00%> (ø)
... and 1 more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

add consistent animate-in-view value to every storyblok component

2 participants