import { Event } from '@gedit/utils'; import { Color } from './color'; export declare namespace MonacoColorRegistry { type IJSONSchema = any; export type ThemeType = 'light' | 'dark' | 'hc'; export interface IColorTheme { readonly type: ThemeType; getColor(color: ColorIdentifier, useDefault?: boolean): Color | undefined; } export type ColorIdentifier = string; export interface ColorContribution { readonly id: ColorIdentifier; readonly description: string; readonly defaults: ColorDefaults | null; readonly needsTransparency: boolean; readonly deprecationMessage: string | undefined; } export interface ColorFunction { (theme: IColorTheme): Color | undefined; } export interface ColorDefaults { light?: ColorValue | null; dark?: ColorValue | null; hc?: ColorValue | null; } /** * A Color Value is either a color literal, a refence to other color or a derived color */ export type ColorValue = Color | string | ColorIdentifier | ColorFunction; export interface IColorRegistry { readonly onDidChangeSchema: Event; /** * Register a color to the registry. * @param id The color id as used in theme description files * @param defaults The default values * @description the description */ registerColor(id: string, defaults: ColorDefaults, description: string): ColorIdentifier; getColorContribution(key: string): ColorContribution | undefined; /** * Register a color to the registry. */ deregisterColor(id: string): void; /** * Get all color contributions */ getColors(): ColorContribution[]; /** * Gets the default color of the given id */ resolveDefaultColor(id: ColorIdentifier, theme: IColorTheme): Color | undefined; /** * JSON schema for an object to assign color values to one of the color contributions. */ getColorSchema(): IJSONSchema; /** * JSON schema to for a reference to a color contribution. */ getColorReferenceSchema(): IJSONSchema; } export function registerColor(id: string, defaults: ColorDefaults | null, description: string, needsTransparency?: boolean, deprecationMessage?: string): ColorIdentifier; export function getColorRegistry(): IColorRegistry; export const foreground: string; export const errorForeground: string; export const descriptionForeground: string; export const iconForeground: string; export const focusBorder: string; export const contrastBorder: string; export const activeContrastBorder: string; export const selectionBackground: string; export const textSeparatorForeground: string; export const textLinkForeground: string; export const textLinkActiveForeground: string; export const textPreformatForeground: string; export const textBlockQuoteBackground: string; export const textBlockQuoteBorder: string; export const textCodeBlockBackground: string; export const widgetShadow: string; export const inputBackground: string; export const inputForeground: string; export const inputBorder: string; export const inputActiveOptionBorder: string; export const inputActiveOptionBackground: string; export const inputActiveOptionForeground: string; export const inputPlaceholderForeground: string; export const inputValidationInfoBackground: string; export const inputValidationInfoForeground: string; export const inputValidationInfoBorder: string; export const inputValidationWarningBackground: string; export const inputValidationWarningForeground: string; export const inputValidationWarningBorder: string; export const inputValidationErrorBackground: string; export const inputValidationErrorForeground: string; export const inputValidationErrorBorder: string; export const selectBackground: string; export const selectListBackground: string; export const selectForeground: string; export const selectBorder: string; export const simpleCheckboxBackground: string; export const simpleCheckboxForeground: string; export const simpleCheckboxBorder: string; export const buttonForeground: string; export const buttonBackground: string; export const buttonHoverBackground: string; export const buttonSecondaryForeground: string; export const buttonSecondaryBackground: string; export const buttonSecondaryHoverBackground: string; export const badgeBackground: string; export const badgeForeground: string; export const scrollbarShadow: string; export const scrollbarSliderBackground: string; export const scrollbarSliderHoverBackground: string; export const scrollbarSliderActiveBackground: string; export const progressBarBackground: string; export const editorErrorForeground: string; export const editorErrorBorder: string; export const editorWarningForeground: string; export const editorWarningBorder: string; export const editorInfoForeground: string; export const editorInfoBorder: string; export const editorHintForeground: string; export const editorHintBorder: string; /** * Editor background color. * Because of bug https://monacotools.visualstudio.com/DefaultCollection/Monaco/_workitems/edit/13254 * we are *not* using the color white (or #ffffff, rgba(255,255,255)) but something very close to white. */ export const editorBackground: string; /** * Editor foreground color. */ export const editorForeground: string; /** * Editor widgets */ export const editorWidgetBackground: string; export const editorWidgetForeground: string; export const editorWidgetBorder: string; export const editorWidgetResizeBorder: string; /** * Quick pick widget */ export const quickInputBackground: string; export const quickInputForeground: string; export const quickInputTitleBackground: string; export const pickerGroupForeground: string; export const pickerGroupBorder: string; /** * Editor selection colors. */ export const editorSelectionBackground: string; export const editorSelectionForeground: string; export const editorInactiveSelection: string; export const editorSelectionHighlight: string; export const editorSelectionHighlightBorder: string; /** * Editor find match colors. */ export const editorFindMatch: string; export const editorFindMatchHighlight: string; export const editorFindRangeHighlight: string; export const editorFindMatchBorder: string; export const editorFindMatchHighlightBorder: string; export const editorFindRangeHighlightBorder: string; /** * Search Editor query match colors. * * Distinct from normal editor find match to allow for better differentiation */ export const searchEditorFindMatch: string; export const searchEditorFindMatchBorder: string; /** * Editor hover */ export const editorHoverHighlight: string; export const editorHoverBackground: string; export const editorHoverForeground: string; export const editorHoverBorder: string; export const editorHoverStatusBarBackground: string; /** * Editor link colors */ export const editorActiveLinkForeground: string; /** * Editor lighbulb icon colors */ export const editorLightBulbForeground: string; export const editorLightBulbAutoFixForeground: string; /** * Diff Editor Colors */ export const defaultInsertColor: Color; export const defaultRemoveColor: Color; export const diffInserted: string; export const diffRemoved: string; export const diffInsertedOutline: string; export const diffRemovedOutline: string; export const diffBorder: string; export const diffDiagonalFill: string; /** * List and tree colors */ export const listFocusBackground: string; export const listFocusForeground: string; export const listActiveSelectionBackground: string; export const listActiveSelectionForeground: string; export const listInactiveSelectionBackground: string; export const listInactiveSelectionForeground: string; export const listInactiveFocusBackground: string; export const listHoverBackground: string; export const listHoverForeground: string; export const listDropBackground: string; export const listHighlightForeground: string; export const listInvalidItemForeground: string; export const listErrorForeground: string; export const listWarningForeground: string; export const listFilterWidgetBackground: string; export const listFilterWidgetOutline: string; export const listFilterWidgetNoMatchesOutline: string; export const listFilterMatchHighlight: string; export const listFilterMatchHighlightBorder: string; export const treeIndentGuidesStroke: string; export const listDeemphasizedForeground: string; /** * Menu colors */ export const menuBorder: string; export const menuForeground: string; export const menuBackground: string; export const menuSelectionForeground: string; export const menuSelectionBackground: string; export const menuSelectionBorder: string; export const menuSeparatorBackground: string; /** * Snippet placeholder colors */ export const snippetTabstopHighlightBackground: string; export const snippetTabstopHighlightBorder: string; export const snippetFinalTabstopHighlightBackground: string; export const snippetFinalTabstopHighlightBorder: string; /** * Breadcrumb colors */ export const breadcrumbsForeground: string; export const breadcrumbsBackground: string; export const breadcrumbsFocusForeground: string; export const breadcrumbsActiveSelectionForeground: string; export const breadcrumbsPickerBackground: string; export const mergeCurrentHeaderBackground: string; export const mergeCurrentContentBackground: string; export const mergeIncomingHeaderBackground: string; export const mergeIncomingContentBackground: string; export const mergeCommonHeaderBackground: string; export const mergeCommonContentBackground: string; export const mergeBorder: string; export const overviewRulerCurrentContentForeground: string; export const overviewRulerIncomingContentForeground: string; export const overviewRulerCommonContentForeground: string; export const overviewRulerFindMatchForeground: string; export const overviewRulerSelectionHighlightForeground: string; export const minimapFindMatch: string; export const minimapSelection: string; export const minimapError: string; export const minimapWarning: string; export const minimapBackground: string; export const minimapSliderBackground: string; export const minimapSliderHoverBackground: string; export const minimapSliderActiveBackground: string; export const problemsErrorIconForeground: string; export const problemsWarningIconForeground: string; export const problemsInfoIconForeground: string; export function darken(colorValue: ColorValue, factor: number): ColorFunction; export function lighten(colorValue: ColorValue, factor: number): ColorFunction; export function transparent(colorValue: ColorValue, factor: number): ColorFunction; export function oneOf(...colorValues: ColorValue[]): ColorFunction; /** * @param colorValue Resolve a color value in the context of a theme */ export function resolveColorValue(colorValue: ColorValue | null, theme: IColorTheme): Color | undefined; export {}; } //# sourceMappingURL=monaco-color-registry.d.ts.map