From d199784ee6388c134bd5dbdd282094efe5d7cad6 Mon Sep 17 00:00:00 2001 From: Robin Pyon Date: Tue, 17 Oct 2023 11:56:42 +0100 Subject: [PATCH] fix: update `buildLegacyTheme` to satisfy updated color types --- packages/sanity/src/core/theme/_legacy/color.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/packages/sanity/src/core/theme/_legacy/color.ts b/packages/sanity/src/core/theme/_legacy/color.ts index bf8882e9929..7db4b1ac582 100644 --- a/packages/sanity/src/core/theme/_legacy/color.ts +++ b/packages/sanity/src/core/theme/_legacy/color.ts @@ -101,6 +101,7 @@ export function buildColor( bg, border: blend(base.bg, tints[200]), fg: blend(base.bg, buttonTones.bg), + iconColor: blend(base.bg, buttonTones.bg), muted: { fg: blend(base.bg, tints[50]), }, @@ -129,6 +130,7 @@ export function buildColor( bg, border: blend(base.bg, tints[600]), fg: blend(base.bg, buttonTones.bg), + iconColor: blend(base.bg, buttonTones.bg), muted: { fg: blend(base.bg, tints[200]), }, @@ -157,6 +159,7 @@ export function buildColor( bg, border: blend(base.bg, tints[800]), fg: blend(base.bg, buttonTones.bg), + iconColor: blend(base.bg, buttonTones.bg), muted: { fg: blend(base.bg, tints[200]), }, @@ -189,6 +192,7 @@ export function buildColor( bg, border: blend(base.bg, tints[800]), fg: blend(base.bg, buttonTones.bg), + iconColor: blend(base.bg, buttonTones.bg), muted: { fg: blend(base.bg, tints[200]), }, @@ -216,6 +220,7 @@ export function buildColor( bg, border: blend(base.bg, tints[500]), fg: blend(base.bg, buttonTones.bg), + iconColor: blend(base.bg, buttonTones.bg), muted: { fg: blend(base.bg, tints[100]), }, @@ -255,6 +260,7 @@ export function buildColor( bg, border: blend(base.bg, tints[50]), fg: blend(base.bg, tints[200]), + iconColor: blend(base.bg, tints[200]), muted: { fg: blend(bg, tints[100]), }, @@ -283,6 +289,7 @@ export function buildColor( bg, border: blend(bg, tints[100]), fg: blend(base.bg, tints[900]), + iconColor: blend(base.bg, tints[900]), muted: { fg: blend(base.bg, tints[600]), }, @@ -315,6 +322,7 @@ export function buildColor( bg, border: blend(bg, tints[100]), fg: blend(base.bg, tints[800]), + iconColor: blend(base.bg, tints[800]), muted: { fg: blend(base.bg, tints[600]), }, @@ -347,6 +355,7 @@ export function buildColor( bg, border: blend(bg, tints[100]), fg: blend(bg, tints[800]), + iconColor: blend(bg, tints[800]), muted: { fg: blend(bg, tints[600]), }, @@ -374,6 +383,7 @@ export function buildColor( bg, border: blend(bg, tints[100]), fg: blend(bg, tints[700]), + iconColor: blend(bg, tints[700]), muted: { fg: blend(bg, tints[600]), }, @@ -472,6 +482,7 @@ export function buildColor( return { bg, fg: base.fg, + iconColor: base.fg, border: base.border, muted: { fg: blend(base.bg, tints[dark ? 400 : 600]), @@ -503,6 +514,7 @@ export function buildColor( return { bg: blend(base.bg, tints[50]), + bg2: blend(base.bg, tints[50]), fg: blend(base.bg, tints[700]), border: blend(base.bg, tints[200]), placeholder: blend(base.bg, tints[400]), @@ -512,6 +524,7 @@ export function buildColor( if (state === 'hovered') { return { bg: base.bg, + bg2: base.bg, fg: base.fg, border: blend(base.bg, hues.gray[300].hex), placeholder: blend(base.bg, hues.gray[400].hex), @@ -521,6 +534,7 @@ export function buildColor( if (state === 'disabled') { return { bg: blend(base.bg, hues.gray[50].hex), + bg2: blend(base.bg, hues.gray[50].hex), fg: blend(base.bg, hues.gray[200].hex), border: blend(base.bg, hues.gray[100].hex), placeholder: blend(base.bg, hues.gray[100].hex), @@ -530,6 +544,7 @@ export function buildColor( if (state === 'readOnly') { return { bg: blend(base.bg, hues.gray[50].hex), + bg2: blend(base.bg, hues.gray[50].hex), fg: blend(base.bg, hues.gray[800].hex), border: blend(base.bg, hues.gray[200].hex), placeholder: blend(base.bg, hues.gray[400].hex), @@ -538,6 +553,7 @@ export function buildColor( return { bg: base.bg, + bg2: base.bg, fg: base.fg, border: base.border, placeholder: blend(base.bg, hues.gray[700].hex),