DesignOverviewDesign SystemMapsGraphIntroductionInstallationDeriving a themeSandboxTheme builderVisual testingAgentsCortexMemoryActiveProvenanceActiveContextActiveServicesInsightsGet in touchSource on GitHub
Loading the reference
MagneticView sourceEdit in SandboxView MarkdownCopy MarkdownOpen in ClaudeOpen in CursorDraws its content a little way toward the pointer, as if pulled.Also called Magnetic button, Pointer pull, and Attract.ExperimentalSince 0.241.0ContentImportimport'@fusion.dev/helix/magnetic'Preview
GuidelinesWhen to use
The main button on a landing page, drawn toward the mouse as it nears.MagneticThis page
Keep --magnetic-reach smaller than the content.The drift then never takes the content out from under the pointer.
API referenceRoothelix-magneticDraws its content a little way toward the pointer, as if pulled.
ReadTypeDescriptionwhenSettledPromise<void>Resolves a frame after the first update, when transitions are switched on.
SlotDescription(default)The content that drifts, such as a Button.
PartDescriptionsurfaceThe box that drifts, holding the content.
CSS PropertyDescription--magnetic-reachHow far the content drifts at most, with the pointer at an edge. Defaults to --helix-space-sm.
Custom stateDescriptionpulledA pointer is over the content, which follows it closely. It springs back once the pointer leaves.settledSet one frame after the first render. Transitions wait for it, so an element does not animate its own arrival.
Examples
NameDescriptionPreviewA button that drifts toward the mouse and springs back when it leaves.