Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CB-4685 disable default theme setting (temporary) #2399

Merged
merged 2 commits into from
Feb 21, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* you may not use this file except in compliance with the License.
*/
import { Dependency, injectable } from '@cloudbeaver/core-di';
import { ESettingsValueType, INTERFACE_SETTINGS_GROUP, SettingsManagerService } from '@cloudbeaver/core-plugin';
import { SettingsManagerService } from '@cloudbeaver/core-plugin';

import { ThemeService } from './ThemeService';
import { ThemeSettingsService } from './ThemeSettingsService';
Expand All @@ -16,14 +16,14 @@ export class ThemeSettingsManagementService extends Dependency {
constructor(themeSettingsService: ThemeSettingsService, themeService: ThemeService, settingsManagerService: SettingsManagerService) {
super();
settingsManagerService.registerSettings(themeSettingsService.settings, () => [
{
key: 'defaultTheme',
type: ESettingsValueType.Select,
name: 'core_theming_settings_default_theme_name',
description: 'core_theming_settings_default_theme_description',
options: themeService.themes.map(theme => ({ id: theme.id, name: theme.name })),
group: INTERFACE_SETTINGS_GROUP,
},
// {
Copy link
Contributor Author

@sergeyteleshev sergeyteleshev Feb 20, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see no reason to comment other parts here
webapp/packages/core-theming/src/ThemeSettingsService.ts
or here
webapp/packages/core-theming/src/ThemeService.ts

Cause it just sets the theme to the light as default and doesn't (won't) affect anything

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exactly, we want to hide this setting from preferences only

// key: 'defaultTheme',
// type: ESettingsValueType.Select,
// name: 'core_theming_settings_default_theme_name',
// description: 'core_theming_settings_default_theme_description',
// options: themeService.themes.map(theme => ({ id: theme.id, name: theme.name })),
// group: INTERFACE_SETTINGS_GROUP,
// },
]);
}
}
Loading