|
|
|
|
@ -34,6 +34,18 @@ export const Theme = ({ children }: Props) => { |
|
|
|
|
return clientBase |
|
|
|
|
}, []) |
|
|
|
|
|
|
|
|
|
// настройка цветовой гаммы зендеска https://developer.zendesk.com/api-reference/widget/settings/#color
|
|
|
|
|
useEffect(() => { |
|
|
|
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
|
|
|
(window as any).zESettings = { |
|
|
|
|
webWidget: { |
|
|
|
|
color: { |
|
|
|
|
theme: theme.colors.button, |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
} |
|
|
|
|
}, [theme]) |
|
|
|
|
|
|
|
|
|
const switchTheme = useCallback(() => { |
|
|
|
|
switch (client.name) { |
|
|
|
|
case ClientNames.Lff: |
|
|
|
|
|