state.ts

src/state.ts
import { proxy, useSnapshot, subscribe } from 'valtio'
import { DEFAULT_PANEL_COLOR } from '@/utils/panel-colors'
const state = proxy({
playVideo: false,
offsetTop: 0,
windowHeight: 0,
lastOffsetTop: 0,
isScrolling: false,
dialogOpen: false,
scrollingDirection: 'down',
lastScrollingDirection: 'down',
lockScrollDirection: false,
/** Currently selected panel finish (hex), driven by the color chart picker. */
panelColor: DEFAULT_PANEL_COLOR,
/** When flipped true, opens the floating AI chat panel from anywhere. */
aiSearchOpen: false,
})
export { state, useSnapshot, subscribe, proxy }

Support

Talk to the developers of this project to learn more

We have been building professional websites for big clients for over 15 years. Gallop templates and blocks is our best foundation for SEO websites and web apps.

© 2026 Web Plant Media, LLC