Skip to content

Commit a6f760a

Browse files
authored
Replace use of deprecated themes in palette (#14814)
1 parent 6314f8f commit a6f760a

File tree

1 file changed

+9
-11
lines changed

1 file changed

+9
-11
lines changed

dotcom-rendering/src/paletteDeclarations.ts

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,8 @@
55
*/
66
import { palette as sourcePalette } from '@guardian/source/foundations';
77
import {
8-
buttonThemeBrand,
9-
buttonThemeDefault,
108
themeButton,
9+
themeButtonBrand,
1110
} from '@guardian/source/react-components';
1211
import {
1312
expandingWrapperDarkTheme,
@@ -887,20 +886,19 @@ const bylineUnderline: PaletteFunction = ({ theme }) => {
887886
const calloutPromptLight: PaletteFunction = () => sourcePalette.brand[500];
888887
const calloutPromptDark: PaletteFunction = () => sourcePalette.brand[800];
889888

890-
const calloutSubmitTextLight: PaletteFunction = () =>
891-
buttonThemeDefault.button.textPrimary;
889+
const calloutSubmitTextLight: PaletteFunction = () => themeButton.textPrimary;
892890
const calloutSubmitTextDark: PaletteFunction = () =>
893-
buttonThemeBrand.button.textPrimary;
891+
themeButtonBrand.textPrimary;
894892

895893
const calloutSubmitBackgroundLight: PaletteFunction = () =>
896-
buttonThemeDefault.button.backgroundPrimary;
894+
themeButton.backgroundPrimary;
897895
const calloutSubmitBackgroundDark: PaletteFunction = () =>
898-
buttonThemeBrand.button.backgroundPrimary;
896+
themeButtonBrand.backgroundPrimary;
899897

900898
const calloutSubmitBackgroundHoverLight: PaletteFunction = () =>
901-
buttonThemeDefault.button.backgroundPrimaryHover;
899+
themeButton.backgroundPrimaryHover;
902900
const calloutSubmitBackgroundHoverDark: PaletteFunction = () =>
903-
buttonThemeBrand.button.backgroundPrimaryHover;
901+
themeButtonBrand.backgroundPrimaryHover;
904902

905903
export const expandingWrapper = {
906904
'--expandingWrapper--background': {
@@ -1977,11 +1975,11 @@ const clickToViewBorderDark: PaletteFunction = () => sourcePalette.neutral[46];
19771975
const clickToViewButtonLight: PaletteFunction = () => sourcePalette.brand[400];
19781976
const clickToViewButtonDark: PaletteFunction = () => sourcePalette.neutral[97];
19791977
const clickToViewButtonTextLight: PaletteFunction = () =>
1980-
buttonThemeDefault.button.textPrimary;
1978+
themeButton.textPrimary;
19811979
const clickToViewButtonTextDark: PaletteFunction = () =>
19821980
sourcePalette.neutral[7];
19831981
const clickToViewButtonHoverLight: PaletteFunction = () =>
1984-
buttonThemeDefault.button.backgroundPrimaryHover;
1982+
themeButton.backgroundPrimaryHover;
19851983
const clickToViewButtonHoverDark: PaletteFunction = () =>
19861984
sourcePalette.neutral[86];
19871985

0 commit comments

Comments
 (0)