Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update link colours for audio articles #12608

Merged
merged 13 commits into from
Oct 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,16 @@ export const QuotedDeadBlogDesignAllThemes = {
},
} satisfies Story;

export const QuotedCommentDesignAudioAllThemes = {
args: QuotedStandardDesignAllThemes.args,
parameters: {
formats: getAllThemes({
design: ArticleDesign.Audio,
display: ArticleDisplay.Standard,
}),
},
} satisfies Story;

export const QuotedAllDesignsNewsTheme = {
args: QuotedStandardDesignAllThemes.args,
parameters: {
Expand Down
17 changes: 15 additions & 2 deletions dotcom-rendering/src/palette.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3131,6 +3131,9 @@ const articleSectionTitleDark: PaletteFunction = () =>
sourcePalette.neutral[86];

const articleLinkTextLight: PaletteFunction = ({ design, theme }) => {
if (design === ArticleDesign.Audio) {
return sourcePalette.neutral[86];
}
if (design === ArticleDesign.Analysis) return sourcePalette.news[300];
switch (theme) {
case Pillar.Lifestyle:
Expand Down Expand Up @@ -3170,8 +3173,10 @@ const articleLinkTextDark: PaletteFunction = ({ display, theme }) => {
};

const articleLinkBorderLight: PaletteFunction = ({ design, theme }) => {
if (design === ArticleDesign.Audio) {
return sourcePalette.neutral[46];
}
if (theme === ArticleSpecial.Labs) return sourcePalette.neutral[60];

if (theme === ArticleSpecial.SpecialReport) {
return sourcePalette.specialReport[300];
}
Expand Down Expand Up @@ -3205,6 +3210,9 @@ const articleMetaLinesDark: PaletteFunction = ({ design }) => {
};

const articleLinkHoverLight: PaletteFunction = ({ design, theme }) => {
if (design === ArticleDesign.Audio) {
return sourcePalette.neutral[86];
}
switch (design) {
case ArticleDesign.DeadBlog:
switch (theme) {
Expand Down Expand Up @@ -3274,7 +3282,12 @@ const articleLinkHoverLight: PaletteFunction = ({ design, theme }) => {
const articleLinkHoverDark: PaletteFunction = (f) => articleLinkTextDark(f);

const articleLinkBorderHoverLight: PaletteFunction = ({ design, theme }) => {
if (theme === ArticleSpecial.Labs) return sourcePalette.neutral[7];
if (design === ArticleDesign.Audio) {
return sourcePalette.neutral[86];
}
if (theme === ArticleSpecial.Labs) {
return sourcePalette.neutral[7];
}
if (theme === ArticleSpecial.SpecialReport) {
return sourcePalette.specialReport[100];
}
Expand Down
Loading