# dioxus-hoverfx-core
Serializable configuration for worker-first cursor proximity hover effects.
```rust
use dioxus_hoverfx_core::{
HoverFxConfig, HoverFxDefinition, HoverFxFalloff, HoverFxPreset, HoverFxShape,
};
let config = HoverFxConfig::new()
.with_default_effect(HoverFxPreset::Spotlight.as_attr())
.with_radius_px(220)
.with_shape(HoverFxShape::Circle)
.with_falloff(HoverFxFalloff::Smooth)
.with_strength(1.15)
.with_effect(
HoverFxDefinition::new("brand-wash", "Brand wash")
.with_preset(HoverFxPreset::ColorWash)
.with_css_var("--dxh-color", "rgba(14,165,233,0.30)")
.with_css_var("--dxh-blend-mode", "screen"),
);
assert!(config.validate().is_valid());
let json = serde_json::to_string(&config)?;
# Ok::<(), serde_json::Error>(())
```
Built-in presets are `spotlight`, `soft-glow`, `border-trace`, `sheen`, and
`color-wash`. Defaults are tuned for worker-first rendering: 180px radius,
smooth falloff, 1.0 strength, 0.18 pointer smoothing, and up to 8 active
elements per frame.