initializeToggleClasses.ts 507 B

12345678910111213141516
  1. // Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. import type { ToggleClassMap } from './types.ts'
  3. // Provide your own map with the following keys, the values given here are just examples.
  4. let toggleClasses: ToggleClassMap = {
  5. track: 'field-toggle-track',
  6. trackOn: 'field-toggle-track--on',
  7. knob: 'field-toggle-knob',
  8. }
  9. export const initializeToggleClasses = (classes: ToggleClassMap) => {
  10. toggleClasses = classes
  11. }
  12. export const getToggleClasses = () => toggleClasses