GhostInteractiveSurface reference
Package: @ghostvue/themes. Status: experimental (stability policy).
Themed wrapper around headless GhostInteractiveSurface. Same as/effects props; importing it loads the default stylesheet and scopes recipes to this instance. Spotlight tokens come from defineTheme interactivity. Hand-written because the wrapper is a .ts defineComponent.
Generated from the component manifest. Edit the manifest or Vue source, then rebuild the docs.
Props
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
as | 'div' | 'article' | 'section' | 'aside' | "div" | No | Rendered root element, forwarded to the unstyled GhostInteractiveSurface. |
effects | InteractiveEffect[] | "['spotlight']" | No | Recipes advertised on data-interactive. v1 supports spotlight only. |
Emits
None declared.
Models
None declared.
Slots
| Name | Description |
|---|---|
default | Surface content. The glow layer is rendered by the unstyled primitive. |
Slot props: default
None declared.
Exposed members
| Name | Type | Description |
|---|---|---|
element | HTMLElement | null | The root element after mount; null before mount and after unmount. Delegates to the unstyled GhostInteractiveSurface. |
Parts and data attributes
| Attribute | Value | Description |
|---|---|---|
data-part | root | The element selected by as, inside the display:contents themed scope. |
data-part | glow | Decorative spotlight overlay painted from interactive.spotlight tokens. |
data-state | off | Reduced motion, coarse pointer, or empty effects. Glow is not shown. |
data-state | idle | Capable of tracking. Glow opacity is 0. |
data-state | tracking | Pointer is over the host. Glow follows --ghost-pointer-x/y. |
CSS variables
| Name | Description |
|---|---|
--ghost-interactive-spotlight-size | Glow diameter. Subtle default 10rem; none is 0px; expressive is 20rem. |
--ghost-interactive-spotlight-opacity | Peak glow opacity before --ghost-motion-intensity. |
--ghost-interactive-spotlight-color | Glow color. Aliases action.primary.bg so mono stays a hairline. |
--ghost-interactive-leave-spring | Leave-settle easing. Alias of motion.spring.snappy. |
--ghost-interactive-leave-spring-duration | Leave-settle duration. Instant tracking, spring on leave. |
--ghost-pointer-x | Pointer x in CSS pixels. |
--ghost-pointer-y | Pointer y in CSS pixels. |
Accessibility
Role: generic. APG pattern: https://www.w3.org/WAI/ARIA/apg/practices/hiding-semantics/.
Required ARIA attributes: none.
Keyboard
None declared.
Verification
Each category is reviewed separately. Automated keyboard and axe results do not attest manual or assistive-technology review.
| Category | Status | Evidence |
|---|---|---|
| Automated keyboard | Not reviewed | No declared key is mapped to a browser test yet. |
| Manual interaction | Not reviewed | No review recorded. |
| Assistive technology | Not reviewed | No review recorded. |
Examples
interactive-surface/feature-tiles
Responsive grid of themed spotlight tiles, each with a focusable link as its action.
interactive-surface/basic
Pointer spotlight on a content surface.
interactive-surface/button
Themed GhostButton stays inert until interactive is set.