2023-04-19 18:45:34 +03:00
|
|
|
import Component from '@glimmer/component';
|
|
|
|
import {action} from '@ember/object';
|
|
|
|
import {inject as service} from '@ember/service';
|
|
|
|
|
|
|
|
export default class AnnouncementSettingsBackgroundComponent extends Component {
|
|
|
|
@service settings;
|
|
|
|
|
|
|
|
get background() {
|
|
|
|
return this.settings.announcementBackground;
|
|
|
|
}
|
|
|
|
|
|
|
|
get options() {
|
|
|
|
return [
|
2023-04-21 11:49:29 +03:00
|
|
|
{value: 'dark', label: 'Dark', className: 'kg-headerstyle-btn-dark'},
|
|
|
|
{value: 'light', label: 'Light', className: 'kg-headerstyle-btn-light'},
|
|
|
|
{value: 'accent', label: 'Accent', className: 'kg-headerstyle-btn-accent'}
|
2023-04-19 18:45:34 +03:00
|
|
|
];
|
|
|
|
}
|
|
|
|
|
|
|
|
@action
|
2023-04-21 11:49:29 +03:00
|
|
|
setBackground(value) {
|
|
|
|
this.settings.announcementBackground = value;
|
2023-04-19 18:45:34 +03:00
|
|
|
this.args.onChange?.();
|
|
|
|
}
|
|
|
|
}
|