import { useUserSelectionStore } from '@launch/state/user-selections.js'; import { __ } from '@wordpress/i18n'; import classNames from 'classnames'; export const TONES = [ { label: __('Professional', 'extendify-local'), value: 'professional', }, { label: __('Friendly', 'extendify-local'), value: 'friendly', }, { label: __('Inspirational', 'extendify-local'), value: 'inspirational', }, { label: __('Informative', 'extendify-local'), value: 'informative', }, { label: __('Persuasive', 'extendify-local'), value: 'persuasive', }, ]; export const SiteTones = () => { const { businessInformation, setBusinessInformation } = useUserSelectionStore(); const handleTonesToggle = (tone) => { const { tones } = businessInformation; const isSelected = !!tones?.find(({ value }) => value === tone.value); const newTones = isSelected ? tones?.filter(({ value }) => value !== tone.value) : [...tones, tone]; setBusinessInformation('tones', newTones); }; return (
{__("Select your site's tone", 'extendify-local')}