
import { isString, isBoolean } from '../../../../base/common/types.js';

const THEME_SCOPE_OPEN_PAREN = '[';
const THEME_SCOPE_CLOSE_PAREN = ']';
const THEME_SCOPE_WILDCARD = '*';
const themeScopeRegex = /\[(.+?)\]/g;
var ThemeSettings;
(function (ThemeSettings) {
    ThemeSettings["COLOR_THEME"] = "workbench.colorTheme";
    ThemeSettings["FILE_ICON_THEME"] = "workbench.iconTheme";
    ThemeSettings["PRODUCT_ICON_THEME"] = "workbench.productIconTheme";
    ThemeSettings["COLOR_CUSTOMIZATIONS"] = "workbench.colorCustomizations";
    ThemeSettings["TOKEN_COLOR_CUSTOMIZATIONS"] = "editor.tokenColorCustomizations";
    ThemeSettings["SEMANTIC_TOKEN_COLOR_CUSTOMIZATIONS"] = "editor.semanticTokenColorCustomizations";
    ThemeSettings["PREFERRED_DARK_THEME"] = "workbench.preferredDarkColorTheme";
    ThemeSettings["PREFERRED_LIGHT_THEME"] = "workbench.preferredLightColorTheme";
    ThemeSettings["PREFERRED_HC_DARK_THEME"] = "workbench.preferredHighContrastColorTheme";
    ThemeSettings["PREFERRED_HC_LIGHT_THEME"] = "workbench.preferredHighContrastLightColorTheme";
    ThemeSettings["DETECT_COLOR_SCHEME"] = "window.autoDetectColorScheme";
    ThemeSettings["DETECT_HC"] = "window.autoDetectHighContrast";
    ThemeSettings["SYSTEM_COLOR_THEME"] = "window.systemColorTheme";
})(ThemeSettings || (ThemeSettings = {}));
var ThemeSettingDefaults;
(function (ThemeSettingDefaults) {
    ThemeSettingDefaults.COLOR_THEME_DARK = 'VS Code Dark';
    ThemeSettingDefaults.COLOR_THEME_LIGHT = 'VS Code Light';
    ThemeSettingDefaults.COLOR_THEME_HC_DARK = 'Default High Contrast';
    ThemeSettingDefaults.COLOR_THEME_HC_LIGHT = 'Default High Contrast Light';
    ThemeSettingDefaults.FILE_ICON_THEME = 'vs-seti';
    ThemeSettingDefaults.PRODUCT_ICON_THEME = 'Default';
})(ThemeSettingDefaults || (ThemeSettingDefaults = {}));
function migrateThemeSettingsId(settingsId) {
    switch (settingsId) {
        case 'Default Dark Modern': return 'Dark Modern';
        case 'Default Light Modern': return 'Light Modern';
        case 'Default Dark+': return 'Dark+';
        case 'Default Light+': return 'Light+';
        case 'Experimental Dark': return 'VS Code Dark';
        case 'Experimental Light': return 'VS Code Light';
    }
    return settingsId;
}
const COLOR_THEME_DARK_INITIAL_COLORS = {
    'actionBar.toggledBackground': '#383a49',
    'activityBar.activeBorder': '#0078D4',
    'activityBar.background': '#181818',
    'activityBar.border': '#2B2B2B',
    'activityBar.foreground': '#D7D7D7',
    'activityBar.inactiveForeground': '#868686',
    'activityBarBadge.background': '#0078D4',
    'activityBarBadge.foreground': '#FFFFFF',
    'badge.background': '#616161',
    'badge.foreground': '#F8F8F8',
    'button.background': '#0078D4',
    'button.border': '#FFFFFF12',
    'button.foreground': '#FFFFFF',
    'button.hoverBackground': '#026EC1',
    'button.secondaryBackground': '#313131',
    'button.secondaryForeground': '#CCCCCC',
    'button.secondaryHoverBackground': '#3C3C3C',
    'chat.slashCommandBackground': '#26477866',
    'chat.slashCommandForeground': '#85B6FF',
    'chat.editedFileForeground': '#E2C08D',
    'checkbox.background': '#313131',
    'checkbox.border': '#3C3C3C',
    'debugToolBar.background': '#181818',
    'descriptionForeground': '#9D9D9D',
    'dropdown.background': '#313131',
    'dropdown.border': '#3C3C3C',
    'dropdown.foreground': '#CCCCCC',
    'dropdown.listBackground': '#1F1F1F',
    'editor.background': '#1F1F1F',
    'editor.findMatchBackground': '#9E6A03',
    'editor.foreground': '#CCCCCC',
    'editor.inactiveSelectionBackground': '#3A3D41',
    'editor.selectionHighlightBackground': '#ADD6FF26',
    'editorGroup.border': '#FFFFFF17',
    'editorGroupHeader.tabsBackground': '#181818',
    'editorGroupHeader.tabsBorder': '#2B2B2B',
    'editorGutter.addedBackground': '#2EA043',
    'editorGutter.deletedBackground': '#F85149',
    'editorGutter.modifiedBackground': '#0078D4',
    'editorIndentGuide.activeBackground1': '#707070',
    'editorIndentGuide.background1': '#404040',
    'editorLineNumber.activeForeground': '#CCCCCC',
    'editorLineNumber.foreground': '#6E7681',
    'editorOverviewRuler.border': '#010409',
    'editorWidget.background': '#202020',
    'errorForeground': '#F85149',
    'focusBorder': '#0078D4',
    'foreground': '#CCCCCC',
    'icon.foreground': '#CCCCCC',
    'input.background': '#313131',
    'input.border': '#3C3C3C',
    'input.foreground': '#CCCCCC',
    'input.placeholderForeground': '#989898',
    'inputOption.activeBackground': '#2489DB82',
    'inputOption.activeBorder': '#2488DB',
    'keybindingLabel.foreground': '#CCCCCC',
    'list.activeSelectionIconForeground': '#FFF',
    'list.dropBackground': '#383B3D',
    'menu.background': '#1F1F1F',
    'menu.border': '#454545',
    'menu.foreground': '#CCCCCC',
    'menu.selectionBackground': '#0078d4',
    'menu.separatorBackground': '#454545',
    'notificationCenterHeader.background': '#1F1F1F',
    'notificationCenterHeader.foreground': '#CCCCCC',
    'notifications.background': '#1F1F1F',
    'notifications.border': '#2B2B2B',
    'notifications.foreground': '#CCCCCC',
    'panel.background': '#181818',
    'panel.border': '#2B2B2B',
    'panelInput.border': '#2B2B2B',
    'panelTitle.activeBorder': '#0078D4',
    'panelTitle.activeForeground': '#CCCCCC',
    'panelTitle.inactiveForeground': '#9D9D9D',
    'peekViewEditor.background': '#1F1F1F',
    'peekViewEditor.matchHighlightBackground': '#BB800966',
    'peekViewResult.background': '#1F1F1F',
    'peekViewResult.matchHighlightBackground': '#BB800966',
    'pickerGroup.border': '#3C3C3C',
    'ports.iconRunningProcessForeground': '#369432',
    'progressBar.background': '#0078D4',
    'quickInput.background': '#222222',
    'quickInput.foreground': '#CCCCCC',
    'settings.dropdownBackground': '#313131',
    'settings.dropdownBorder': '#3C3C3C',
    'settings.headerForeground': '#FFFFFF',
    'settings.modifiedItemIndicator': '#BB800966',
    'sideBar.background': '#181818',
    'sideBar.border': '#2B2B2B',
    'sideBar.foreground': '#CCCCCC',
    'sideBarSectionHeader.background': '#181818',
    'sideBarSectionHeader.border': '#2B2B2B',
    'sideBarSectionHeader.foreground': '#CCCCCC',
    'sideBarTitle.foreground': '#CCCCCC',
    'statusBar.background': '#181818',
    'statusBar.border': '#2B2B2B',
    'statusBar.debuggingBackground': '#0078D4',
    'statusBar.debuggingForeground': '#FFFFFF',
    'statusBar.focusBorder': '#0078D4',
    'statusBar.foreground': '#CCCCCC',
    'statusBar.noFolderBackground': '#1F1F1F',
    'statusBarItem.focusBorder': '#0078D4',
    'statusBarItem.prominentBackground': '#6E768166',
    'statusBarItem.remoteBackground': '#0078D4',
    'statusBarItem.remoteForeground': '#FFFFFF',
    'tab.activeBackground': '#1F1F1F',
    'tab.activeBorder': '#1F1F1F',
    'tab.activeBorderTop': '#0078D4',
    'tab.activeForeground': '#FFFFFF',
    'tab.border': '#2B2B2B',
    'tab.hoverBackground': '#1F1F1F',
    'tab.inactiveBackground': '#181818',
    'tab.inactiveForeground': '#9D9D9D',
    'tab.lastPinnedBorder': '#ccc3',
    'tab.selectedBackground': '#222222',
    'tab.selectedBorderTop': '#6caddf',
    'tab.selectedForeground': '#ffffffa0',
    'tab.unfocusedActiveBorder': '#1F1F1F',
    'tab.unfocusedActiveBorderTop': '#2B2B2B',
    'tab.unfocusedHoverBackground': '#1F1F1F',
    'terminal.foreground': '#CCCCCC',
    'terminal.inactiveSelectionBackground': '#3A3D41',
    'terminal.tab.activeBorder': '#0078D4',
    'textBlockQuote.background': '#2B2B2B',
    'textBlockQuote.border': '#616161',
    'textCodeBlock.background': '#2B2B2B',
    'textLink.activeForeground': '#4daafc',
    'textLink.foreground': '#4daafc',
    'textPreformat.background': '#3C3C3C',
    'textPreformat.foreground': '#D0D0D0',
    'textSeparator.foreground': '#21262D',
    'titleBar.activeBackground': '#181818',
    'titleBar.activeForeground': '#CCCCCC',
    'titleBar.border': '#2B2B2B',
    'titleBar.inactiveBackground': '#1F1F1F',
    'titleBar.inactiveForeground': '#9D9D9D',
    'welcomePage.progress.foreground': '#0078D4',
    'welcomePage.tileBackground': '#2B2B2B',
    'widget.border': '#313131'
};
const COLOR_THEME_LIGHT_INITIAL_COLORS = {
    'actionBar.toggledBackground': '#dddddd',
    'activityBar.activeBorder': '#005FB8',
    'activityBar.background': '#F8F8F8',
    'activityBar.border': '#E5E5E5',
    'activityBar.foreground': '#1F1F1F',
    'activityBar.inactiveForeground': '#616161',
    'activityBarBadge.background': '#005FB8',
    'activityBarBadge.foreground': '#FFFFFF',
    'badge.background': '#CCCCCC',
    'badge.foreground': '#3B3B3B',
    'button.background': '#005FB8',
    'button.border': '#0000001a',
    'button.foreground': '#FFFFFF',
    'button.hoverBackground': '#0258A8',
    'button.secondaryBackground': '#E5E5E5',
    'button.secondaryForeground': '#3B3B3B',
    'button.secondaryHoverBackground': '#CCCCCC',
    'chat.slashCommandBackground': '#ADCEFF7A',
    'chat.slashCommandForeground': '#26569E',
    'chat.editedFileForeground': '#895503',
    'checkbox.background': '#F8F8F8',
    'checkbox.border': '#CECECE',
    'descriptionForeground': '#3B3B3B',
    'diffEditor.unchangedRegionBackground': '#f8f8f8',
    'dropdown.background': '#FFFFFF',
    'dropdown.border': '#CECECE',
    'dropdown.foreground': '#3B3B3B',
    'dropdown.listBackground': '#FFFFFF',
    'editor.background': '#FFFFFF',
    'editor.foreground': '#3B3B3B',
    'editor.inactiveSelectionBackground': '#E5EBF1',
    'editor.selectionHighlightBackground': '#ADD6FF80',
    'editorGroup.border': '#E5E5E5',
    'editorGroupHeader.tabsBackground': '#F8F8F8',
    'editorGroupHeader.tabsBorder': '#E5E5E5',
    'editorGutter.addedBackground': '#2EA043',
    'editorGutter.deletedBackground': '#F85149',
    'editorGutter.modifiedBackground': '#005FB8',
    'editorIndentGuide.activeBackground1': '#939393',
    'editorIndentGuide.background1': '#D3D3D3',
    'editorLineNumber.activeForeground': '#171184',
    'editorLineNumber.foreground': '#6E7681',
    'editorOverviewRuler.border': '#E5E5E5',
    'editorSuggestWidget.background': '#F8F8F8',
    'editorWidget.background': '#F8F8F8',
    'errorForeground': '#F85149',
    'focusBorder': '#005FB8',
    'foreground': '#3B3B3B',
    'icon.foreground': '#3B3B3B',
    'input.background': '#FFFFFF',
    'input.border': '#CECECE',
    'input.foreground': '#3B3B3B',
    'input.placeholderForeground': '#767676',
    'inputOption.activeBackground': '#BED6ED',
    'inputOption.activeBorder': '#005FB8',
    'inputOption.activeForeground': '#000000',
    'keybindingLabel.foreground': '#3B3B3B',
    'list.activeSelectionBackground': '#E8E8E8',
    'list.activeSelectionForeground': '#000000',
    'list.activeSelectionIconForeground': '#000000',
    'list.focusAndSelectionOutline': '#005FB8',
    'list.hoverBackground': '#F2F2F2',
    'menu.border': '#CECECE',
    'menu.selectionBackground': '#005FB8',
    'menu.selectionForeground': '#ffffff',
    'notebook.cellBorderColor': '#E5E5E5',
    'notebook.selectedCellBackground': '#C8DDF150',
    'notificationCenterHeader.background': '#FFFFFF',
    'notificationCenterHeader.foreground': '#3B3B3B',
    'notifications.background': '#FFFFFF',
    'notifications.border': '#E5E5E5',
    'notifications.foreground': '#3B3B3B',
    'panel.background': '#F8F8F8',
    'panel.border': '#E5E5E5',
    'panelInput.border': '#E5E5E5',
    'panelTitle.activeBorder': '#005FB8',
    'panelTitle.activeForeground': '#3B3B3B',
    'panelTitle.inactiveForeground': '#3B3B3B',
    'peekViewEditor.matchHighlightBackground': '#BB800966',
    'peekViewResult.background': '#FFFFFF',
    'peekViewResult.matchHighlightBackground': '#BB800966',
    'pickerGroup.border': '#E5E5E5',
    'pickerGroup.foreground': '#8B949E',
    'ports.iconRunningProcessForeground': '#369432',
    'progressBar.background': '#005FB8',
    'quickInput.background': '#F8F8F8',
    'quickInput.foreground': '#3B3B3B',
    'searchEditor.textInputBorder': '#CECECE',
    'settings.dropdownBackground': '#FFFFFF',
    'settings.dropdownBorder': '#CECECE',
    'settings.headerForeground': '#1F1F1F',
    'settings.modifiedItemIndicator': '#BB800966',
    'settings.numberInputBorder': '#CECECE',
    'settings.textInputBorder': '#CECECE',
    'sideBar.background': '#F8F8F8',
    'sideBar.border': '#E5E5E5',
    'sideBar.foreground': '#3B3B3B',
    'sideBarSectionHeader.background': '#F8F8F8',
    'sideBarSectionHeader.border': '#E5E5E5',
    'sideBarSectionHeader.foreground': '#3B3B3B',
    'sideBarTitle.foreground': '#3B3B3B',
    'statusBar.background': '#F8F8F8',
    'statusBar.border': '#E5E5E5',
    'statusBar.debuggingBackground': '#FD716C',
    'statusBar.debuggingForeground': '#000000',
    'statusBar.focusBorder': '#005FB8',
    'statusBar.foreground': '#3B3B3B',
    'statusBar.noFolderBackground': '#F8F8F8',
    'statusBarItem.compactHoverBackground': '#CCCCCC',
    'statusBarItem.errorBackground': '#C72E0F',
    'statusBarItem.focusBorder': '#005FB8',
    'statusBarItem.hoverBackground': '#B8B8B850',
    'statusBarItem.prominentBackground': '#6E768166',
    'statusBarItem.remoteBackground': '#005FB8',
    'statusBarItem.remoteForeground': '#FFFFFF',
    'tab.activeBackground': '#FFFFFF',
    'tab.activeBorder': '#F8F8F8',
    'tab.activeBorderTop': '#005FB8',
    'tab.activeForeground': '#3B3B3B',
    'tab.border': '#E5E5E5',
    'tab.hoverBackground': '#FFFFFF',
    'tab.inactiveBackground': '#F8F8F8',
    'tab.inactiveForeground': '#868686',
    'tab.lastPinnedBorder': '#D4D4D4',
    'tab.selectedBackground': '#ffffffa5',
    'tab.selectedBorderTop': '#68a3da',
    'tab.selectedForeground': '#333333b3',
    'tab.unfocusedActiveBorder': '#F8F8F8',
    'tab.unfocusedActiveBorderTop': '#E5E5E5',
    'tab.unfocusedHoverBackground': '#F8F8F8',
    'terminal.foreground': '#3B3B3B',
    'terminal.inactiveSelectionBackground': '#E5EBF1',
    'terminal.tab.activeBorder': '#005FB8',
    'terminalCursor.foreground': '#005FB8',
    'textBlockQuote.background': '#F8F8F8',
    'textBlockQuote.border': '#E5E5E5',
    'textCodeBlock.background': '#F8F8F8',
    'textLink.activeForeground': '#005FB8',
    'textLink.foreground': '#005FB8',
    'textPreformat.background': '#0000001F',
    'textPreformat.foreground': '#3B3B3B',
    'textSeparator.foreground': '#21262D',
    'titleBar.activeBackground': '#F8F8F8',
    'titleBar.activeForeground': '#1E1E1E',
    'titleBar.border': '#E5E5E5',
    'titleBar.inactiveBackground': '#F8F8F8',
    'titleBar.inactiveForeground': '#8B949E',
    'welcomePage.tileBackground': '#F3F3F3',
    'widget.border': '#E5E5E5'
};
var ExtensionData;
(function (ExtensionData) {
    function toJSONObject(d) {
        return d && { _extensionId: d.extensionId, _extensionIsBuiltin: d.extensionIsBuiltin, _extensionName: d.extensionName, _extensionPublisher: d.extensionPublisher };
    }
    ExtensionData.toJSONObject = toJSONObject;
    function fromJSONObject(o) {
        if (o && isString(o._extensionId) && isBoolean(o._extensionIsBuiltin) && isString(o._extensionName) && isString(o._extensionPublisher)) {
            return { extensionId: o._extensionId, extensionIsBuiltin: o._extensionIsBuiltin, extensionName: o._extensionName, extensionPublisher: o._extensionPublisher };
        }
        return undefined;
    }
    ExtensionData.fromJSONObject = fromJSONObject;
    function fromName(publisher, name, isBuiltin = false) {
        return { extensionPublisher: publisher, extensionId: `${publisher}.${name}`, extensionName: name, extensionIsBuiltin: isBuiltin };
    }
    ExtensionData.fromName = fromName;
})(ExtensionData || (ExtensionData = {}));

export { COLOR_THEME_DARK_INITIAL_COLORS, COLOR_THEME_LIGHT_INITIAL_COLORS, ExtensionData, THEME_SCOPE_CLOSE_PAREN, THEME_SCOPE_OPEN_PAREN, THEME_SCOPE_WILDCARD, ThemeSettingDefaults, ThemeSettings, migrateThemeSettingsId, themeScopeRegex };
