# WorkspaceThemeProperty

Contains theme configuration for a workspace, supporting both light and dark modes.

- Source: Generated at build time
- Type last changed: v2.233.0 · 18 Dec 2025

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_connect as connect } from 'aws-cdk-lib';
const workspaceThemeProperty: connect.CfnWorkspace.WorkspaceThemeProperty = {
  dark: {
    palette: {
      canvas: {
        activeBackground: 'activeBackground',
        containerBackground: 'containerBackground',
        pageBackground: 'pageBackground',
      },
      header: {
        background: 'background',
        invertActionsColors: false,
        text: 'text',
        textHover: 'textHover',
      },
      navigation: {
        background: 'background',
        invertActionsColors: false,
        text: 'text',
        textActive: 'textActive',
        textBackgroundActive: 'textBackgroundActive',
        textBackgroundHover: 'textBackgroundHover',
        textHover: 'textHover',
      },
      primary: {
        active: 'active',
        contrastText: 'contrastText',
        default: 'default',
      },
    },
    typography: {
      fontFamily: {
        default: 'default',
      },
    },
  },
  light: {
    palette: {
      canvas: {
        activeBackground: 'activeBackground',
        containerBackground: 'containerBackground',
        pageBackground: 'pageBackground',
      },
      header: {
        background: 'background',
        invertActionsColors: false,
        text: 'text',
        textHover: 'textHover',
      },
      navigation: {
        background: 'background',
        invertActionsColors: false,
        text: 'text',
        textActive: 'textActive',
        textBackgroundActive: 'textBackgroundActive',
        textBackgroundHover: 'textBackgroundHover',
        textHover: 'textHover',
      },
      primary: {
        active: 'active',
        contrastText: 'contrastText',
        default: 'default',
      },
    },
    typography: {
      fontFamily: {
        default: 'default',
      },
    },
  },
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_connect as connect

workspace_theme_property = connect.CfnWorkspace.WorkspaceThemeProperty(
    dark=connect.CfnWorkspace.WorkspaceThemeConfigProperty(
        palette=connect.CfnWorkspace.WorkspaceThemePaletteProperty(
            canvas=connect.CfnWorkspace.PaletteCanvasProperty(
                active_background="activeBackground",
                container_background="containerBackground",
                page_background="pageBackground"
            ),
            header=connect.CfnWorkspace.PaletteHeaderProperty(
                background="background",
                invert_actions_colors=False,
                text="text",
                text_hover="textHover"
            ),
            navigation=connect.CfnWorkspace.PaletteNavigationProperty(
                background="background",
                invert_actions_colors=False,
                text="text",
                text_active="textActive",
                text_background_active="textBackgroundActive",
                text_background_hover="textBackgroundHover",
                text_hover="textHover"
            ),
            primary=connect.CfnWorkspace.PalettePrimaryProperty(
                active="active",
                contrast_text="contrastText",
                default="default"
            )
        ),
        typography=connect.CfnWorkspace.WorkspaceThemeTypographyProperty(
            font_family=connect.CfnWorkspace.FontFamilyProperty(
                default="default"
            )
        )
    ),
    light=connect.CfnWorkspace.WorkspaceThemeConfigProperty(
        palette=connect.CfnWorkspace.WorkspaceThemePaletteProperty(
            canvas=connect.CfnWorkspace.PaletteCanvasProperty(
                active_background="activeBackground",
                container_background="containerBackground",
                page_background="pageBackground"
            ),
            header=connect.CfnWorkspace.PaletteHeaderProperty(
                background="background",
                invert_actions_colors=False,
                text="text",
                text_hover="textHover"
            ),
            navigation=connect.CfnWorkspace.PaletteNavigationProperty(
                background="background",
                invert_actions_colors=False,
                text="text",
                text_active="textActive",
                text_background_active="textBackgroundActive",
                text_background_hover="textBackgroundHover",
                text_hover="textHover"
            ),
            primary=connect.CfnWorkspace.PalettePrimaryProperty(
                active="active",
                contrast_text="contrastText",
                default="default"
            )
        ),
        typography=connect.CfnWorkspace.WorkspaceThemeTypographyProperty(
            font_family=connect.CfnWorkspace.FontFamilyProperty(
                default="default"
            )
        )
    )
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.connect.*;

WorkspaceThemeProperty workspaceThemeProperty = WorkspaceThemeProperty.builder()
        .dark(WorkspaceThemeConfigProperty.builder()
                .palette(WorkspaceThemePaletteProperty.builder()
                        .canvas(PaletteCanvasProperty.builder()
                                .activeBackground("activeBackground")
                                .containerBackground("containerBackground")
                                .pageBackground("pageBackground")
                                .build())
                        .header(PaletteHeaderProperty.builder()
                                .background("background")
                                .invertActionsColors(false)
                                .text("text")
                                .textHover("textHover")
                                .build())
                        .navigation(PaletteNavigationProperty.builder()
                                .background("background")
                                .invertActionsColors(false)
                                .text("text")
                                .textActive("textActive")
                                .textBackgroundActive("textBackgroundActive")
                                .textBackgroundHover("textBackgroundHover")
                                .textHover("textHover")
                                .build())
                        .primary(PalettePrimaryProperty.builder()
                                .active("active")
                                .contrastText("contrastText")
                                .default("default")
                                .build())
                        .build())
                .typography(WorkspaceThemeTypographyProperty.builder()
                        .fontFamily(FontFamilyProperty.builder()
                                .default("default")
                                .build())
                        .build())
                .build())
        .light(WorkspaceThemeConfigProperty.builder()
                .palette(WorkspaceThemePaletteProperty.builder()
                        .canvas(PaletteCanvasProperty.builder()
                                .activeBackground("activeBackground")
                                .containerBackground("containerBackground")
                                .pageBackground("pageBackground")
                                .build())
                        .header(PaletteHeaderProperty.builder()
                                .background("background")
                                .invertActionsColors(false)
                                .text("text")
                                .textHover("textHover")
                                .build())
                        .navigation(PaletteNavigationProperty.builder()
                                .background("background")
                                .invertActionsColors(false)
                                .text("text")
                                .textActive("textActive")
                                .textBackgroundActive("textBackgroundActive")
                                .textBackgroundHover("textBackgroundHover")
                                .textHover("textHover")
                                .build())
                        .primary(PalettePrimaryProperty.builder()
                                .active("active")
                                .contrastText("contrastText")
                                .default("default")
                                .build())
                        .build())
                .typography(WorkspaceThemeTypographyProperty.builder()
                        .fontFamily(FontFamilyProperty.builder()
                                .default("default")
                                .build())
                        .build())
                .build())
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Connect;

var workspaceThemeProperty = new WorkspaceThemeProperty {
    Dark = new WorkspaceThemeConfigProperty {
        Palette = new WorkspaceThemePaletteProperty {
            Canvas = new PaletteCanvasProperty {
                ActiveBackground = "activeBackground",
                ContainerBackground = "containerBackground",
                PageBackground = "pageBackground"
            },
            Header = new PaletteHeaderProperty {
                Background = "background",
                InvertActionsColors = false,
                Text = "text",
                TextHover = "textHover"
            },
            Navigation = new PaletteNavigationProperty {
                Background = "background",
                InvertActionsColors = false,
                Text = "text",
                TextActive = "textActive",
                TextBackgroundActive = "textBackgroundActive",
                TextBackgroundHover = "textBackgroundHover",
                TextHover = "textHover"
            },
            Primary = new PalettePrimaryProperty {
                Active = "active",
                ContrastText = "contrastText",
                Default = "default"
            }
        },
        Typography = new WorkspaceThemeTypographyProperty {
            FontFamily = new FontFamilyProperty {
                Default = "default"
            }
        }
    },
    Light = new WorkspaceThemeConfigProperty {
        Palette = new WorkspaceThemePaletteProperty {
            Canvas = new PaletteCanvasProperty {
                ActiveBackground = "activeBackground",
                ContainerBackground = "containerBackground",
                PageBackground = "pageBackground"
            },
            Header = new PaletteHeaderProperty {
                Background = "background",
                InvertActionsColors = false,
                Text = "text",
                TextHover = "textHover"
            },
            Navigation = new PaletteNavigationProperty {
                Background = "background",
                InvertActionsColors = false,
                Text = "text",
                TextActive = "textActive",
                TextBackgroundActive = "textBackgroundActive",
                TextBackgroundHover = "textBackgroundHover",
                TextHover = "textHover"
            },
            Primary = new PalettePrimaryProperty {
                Active = "active",
                ContrastText = "contrastText",
                Default = "default"
            }
        },
        Typography = new WorkspaceThemeTypographyProperty {
            FontFamily = new FontFamilyProperty {
                Default = "default"
            }
        }
    }
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

workspaceThemeProperty := &WorkspaceThemeProperty{
	Dark: &WorkspaceThemeConfigProperty{
		Palette: &WorkspaceThemePaletteProperty{
			Canvas: &PaletteCanvasProperty{
				ActiveBackground: jsii.String("activeBackground"),
				ContainerBackground: jsii.String("containerBackground"),
				PageBackground: jsii.String("pageBackground"),
			},
			Header: &PaletteHeaderProperty{
				Background: jsii.String("background"),
				InvertActionsColors: jsii.Boolean(false),
				Text: jsii.String("text"),
				TextHover: jsii.String("textHover"),
			},
			Navigation: &PaletteNavigationProperty{
				Background: jsii.String("background"),
				InvertActionsColors: jsii.Boolean(false),
				Text: jsii.String("text"),
				TextActive: jsii.String("textActive"),
				TextBackgroundActive: jsii.String("textBackgroundActive"),
				TextBackgroundHover: jsii.String("textBackgroundHover"),
				TextHover: jsii.String("textHover"),
			},
			Primary: &PalettePrimaryProperty{
				Active: jsii.String("active"),
				ContrastText: jsii.String("contrastText"),
				Default: jsii.String("default"),
			},
		},
		Typography: &WorkspaceThemeTypographyProperty{
			FontFamily: &FontFamilyProperty{
				Default: jsii.String("default"),
			},
		},
	},
	Light: &WorkspaceThemeConfigProperty{
		Palette: &WorkspaceThemePaletteProperty{
			Canvas: &PaletteCanvasProperty{
				ActiveBackground: jsii.String("activeBackground"),
				ContainerBackground: jsii.String("containerBackground"),
				PageBackground: jsii.String("pageBackground"),
			},
			Header: &PaletteHeaderProperty{
				Background: jsii.String("background"),
				InvertActionsColors: jsii.Boolean(false),
				Text: jsii.String("text"),
				TextHover: jsii.String("textHover"),
			},
			Navigation: &PaletteNavigationProperty{
				Background: jsii.String("background"),
				InvertActionsColors: jsii.Boolean(false),
				Text: jsii.String("text"),
				TextActive: jsii.String("textActive"),
				TextBackgroundActive: jsii.String("textBackgroundActive"),
				TextBackgroundHover: jsii.String("textBackgroundHover"),
				TextHover: jsii.String("textHover"),
			},
			Primary: &PalettePrimaryProperty{
				Active: jsii.String("active"),
				ContrastText: jsii.String("contrastText"),
				Default: jsii.String("default"),
			},
		},
		Typography: &WorkspaceThemeTypographyProperty{
			FontFamily: &FontFamilyProperty{
				Default: jsii.String("default"),
			},
		},
	},
}
```

## Properties

- `dark`: [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnWorkspace.WorkspaceThemeConfigProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_connect.CfnWorkspace.WorkspaceThemeConfigProperty.html) — The theme configuration for dark mode.

- `light`: [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnWorkspace.WorkspaceThemeConfigProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_connect.CfnWorkspace.WorkspaceThemeConfigProperty.html) — The theme configuration for light mode.
