Share via


Get-SPOTheme

Description

This cmdlet returns the settings for a named existing theme, or for all uploaded themes if no name is provided.

Note

To support consistent branding and simplify governance, theme management is transitioning to a centralized model.

  • The primary geo will act as the central location for organization-wide theme creation and management. Themes created here will be visible and applicable across satellite geos.
  • The satellite Geo Administrators will be able to view and apply themes from the primary geo to their own sites by using Get-SPOTheme and Set-SPOWebTheme cmdlet. Themes previously created within satellite geos will remain available for use. However, creating new themes in satellite geos will no longer be supported going forward.

Examples

Example 1

This example shows how to use the Get-SPOTheme cmdlet to return the settings for the "Custom Cyan" theme created in the example for the Add-SPOTheme cmdlet. Note that this example uses the PowerShell ConvertTo-Json filter to display the theme in JSON format.

Get-SPOTheme -Name "Custom Cyan" | ConvertTo-Json -Depth 4
{
    "Name":  "Custom Cyan",
    "Palette": null,
    "ColorPairs": {
        "light": [
            {"accentColor": "#0078D4", "backgroundColor": "#FFFFFF"},
            {"accentColor": "#FFFFFF", "backgroundColor": "#0078D4"}
        ]
    },
    "IsInverted":  false,
    "Editable": true
}

If the theme is in legacy format, the output will be:

{
    "Name":  "Custom Cyan",
    "Palette":  {
        "themeLight":  "#affefe",
        "themeTertiary":  "#76ffff",
        "black":  "#000000",
        "neutralSecondary":  "#666666",
        "neutralTertiaryAlt":  "#c8c8c8",
        "themeSecondary":  "#39ffff",
        "themeDarker":  "#005252",
        "primaryBackground":  "#fff",
        "neutralQuaternary":  "#d0d0d0",
        "neutralPrimaryAlt":  "#3c3c3c",
        "neutralPrimary":  "#333",
        "themeDark":  "#009090",
        "themeLighter":  "#daffff",
        "neutralTertiary":  "#a6a6a6",
        "neutralQuaternaryAlt":  "#dadada",
        "themeLighterAlt":  "#f3fcfc",
        "white":  "#fff",
        "neutralSecondaryAlt":  "#767676",
        "neutralLighter":  "#f4f4f4",
        "neutralLight":  "#eaeaea",
        "neutralDark":  "#212121",
        "themeDarkAlt":  "#00c4c4",
        "neutralLighterAlt":  "#f8f8f8",
        "primaryText":  "#333",
        "themePrimary":  "#00ffff"
    },
    "IsInverted":  false,
    "Editable": true
}

Example 2

To return all uploaded themes, use the Get-SPOTheme command with no arguments.

Get-SPOTheme

Parameters

-Name

Applicable: SharePoint Online

The name of the theme.

Parameter properties

Type:System.String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:0
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Inputs

System.String

Outputs

System.Object