Skip to content

improve globe transition#9

Merged
Nabal22 merged 8 commits into
mainfrom
transition/b-quick-patch
May 18, 2026
Merged

improve globe transition#9
Nabal22 merged 8 commits into
mainfrom
transition/b-quick-patch

Conversation

@Nabal22

@Nabal22 Nabal22 commented May 18, 2026

Copy link
Copy Markdown
Owner

No description provided.

Quick-patch variant: keep current container layout animation but
- bump duration 200ms → 280ms with cubic-bezier(0.32, 0.72, 0, 1)
- add will-change for compositor hint
- drop the spurious 'transform 200ms ease' (no transform applied)
- replace the 220ms mount-toggle for the atmosphere halo with a tween
  that drives a shader uOpacity uniform, fading in sync with the shrink
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented May 18, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
omind-map 0462463 Commit Preview URL

Branch Preview URL
May 18 2026, 11:18 AM

Nabal22 added 7 commits May 18, 2026 12:36
Pass an `interactive` flag from SceneContent (= isExplorePage) down to
Globe so country clicks, hover highlights, and haptic feedback only
fire when the globe is in fullscreen mode. In mini/navbar mode the
container's onclick (go home) is the only interaction.
- Bump container/Tween duration from 280ms to 380ms so the
  shrink/expand reads as deliberate instead of snappy.
- Replace oncreate ref + $effect with Threlte's nested dash-syntax
  binding (uniforms-uOpacity-value), which reactively pushes the
  tween value onto material.uniforms.uOpacity.value every change.
  The prior ref capture wasn't propagating, leaving uOpacity at 0
  so the atmosphere stayed invisible.
Fire a light haptic pulse before navigating home from the navbar
mini-globe, matching the rest of the navbar/menu buttons.
Threlte's nested dash-syntax (uniforms-uOpacity-value) didn't push the
tween value onto the live ShaderMaterial here, so the halo rendered at
its initial uOpacity (effectively 0) and was invisible in the navbar.
Capture the material via bind:ref and mutate uniforms.uOpacity.value
from an $effect. Mesh stays mounted with visible={opacity > 0} instead
of conditional remount, so the material ref survives the first tween
tick.
Threlte's reactive uniforms / bind:ref pattern did not reliably push the
tween value through to the live ShaderMaterial — the halo rendered at
its initial uOpacity (0) and stayed invisible in the navbar.

Build the THREE.ShaderMaterial in JS (with uOpacity declared in
uniforms) and attach it to the halo mesh via <T is={...} attach="material">.
A single $effect mutates uniforms.uOpacity.value whenever the
atmosphereOpacity prop changes, so the fade follows the layout tween
deterministically. visible={atmosphereOpacity > 0} avoids drawing an
invisible mesh on the explore view.
…n on /

Bump CAMERA_DISTANCE 2.5 → 3.2 so the explore view frames the globe
with a bit more breathing room.
@Nabal22
Nabal22 merged commit cd7ab49 into main May 18, 2026
2 of 3 checks passed
@Nabal22
Nabal22 deleted the transition/b-quick-patch branch May 18, 2026 11:17
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.

1 participant