feat: desk IA
This commit is contained in:
@@ -377,14 +377,14 @@ function EcoConfig({
|
||||
onChange: (c: Record<string, any>) => void
|
||||
}) {
|
||||
const set = (k: string, v: any) => onChange({ ...config, [k]: v })
|
||||
const countries: string[] = config.countries ?? ECO_DEFAULT_COUNTRIES
|
||||
const countries: string[] = config.currencies ?? ECO_DEFAULT_COUNTRIES
|
||||
const eventTypes: string[] = config.event_types ?? ECO_DEFAULT_TYPES
|
||||
|
||||
const toggleCountry = (code: string) => {
|
||||
const next = countries.includes(code)
|
||||
? countries.filter(c => c !== code)
|
||||
: [...countries, code]
|
||||
set('countries', next)
|
||||
set('currencies', next)
|
||||
}
|
||||
|
||||
const toggleEventType = (id: string) => {
|
||||
|
||||
Reference in New Issue
Block a user