| | import { create } from 'zustand'; |
| |
|
| | |
| | |
| | |
| | |
| | export const useFontMapStore = create((set, get) => ({ |
| | |
| | selectedFont: null, |
| | hoveredFont: null, |
| | |
| | |
| | characterSize: 1.5, |
| | variantSizeImpact: false, |
| | useCategoryColors: false, |
| | |
| | |
| | isTransitioning: false, |
| | |
| | |
| | debugMode: false, |
| | |
| | |
| | setSelectedFont: (font) => { |
| | console.log('🎯 Store: Setting selectedFont to', font?.name || 'null'); |
| | set({ selectedFont: font }); |
| | }, |
| | |
| | setHoveredFont: (font) => { |
| | console.log('🎯 Store: Setting hoveredFont to', font?.name || 'null'); |
| | set({ hoveredFont: font }); |
| | }, |
| | |
| | |
| | setCharacterSize: (size) => { |
| | console.log('🎯 Store: Setting characterSize to', size); |
| | set({ characterSize: size }); |
| | }, |
| | |
| | setVariantSizeImpact: (impact) => { |
| | console.log('🎯 Store: Setting variantSizeImpact to', impact); |
| | set({ variantSizeImpact: impact }); |
| | }, |
| | |
| | setUseCategoryColors: (val) => set({ useCategoryColors: val }), |
| | |
| | setIsTransitioning: (val) => set({ isTransitioning: val }), |
| | |
| | |
| | setDebugMode: (debug) => { |
| | console.log('🎯 Store: Setting debugMode to', debug); |
| | set({ debugMode: debug }); |
| | }, |
| | |
| | |
| | resetState: () => { |
| | console.log('🎯 Store: Resetting state'); |
| | set({ |
| | selectedFont: null, |
| | hoveredFont: null, |
| | isTransitioning: false, |
| | characterSize: 1.5, |
| | variantSizeImpact: false, |
| | useCategoryColors: false, |
| | debugMode: false |
| | }); |
| | } |
| | })); |
| |
|