fix(ui): restore prev colors for workflow editor

Brand colors are now prefixed with "invoke".
This commit is contained in:
psychedelicious 2024-01-06 00:08:36 +11:00 committed by Kent Keirsey
parent d8d266d3be
commit 1a710a4c12
18 changed files with 41 additions and 41 deletions

View File

@ -21,7 +21,7 @@ export const InvAccordionButton = (props: InvAccordionButtonProps) => {
{children}
<Spacer />
{badges?.map((b, i) => (
<InvBadge key={`${b}.${i}`} colorScheme="blue">
<InvBadge key={`${b}.${i}`} colorScheme="invokeBlue">
{b}
</InvBadge>
))}

View File

@ -28,7 +28,7 @@ const meta: Meta<typeof InvButton> = {
export default meta;
type Story = StoryObj<typeof InvButton>;
const colorSchemes = ['base', 'invokeYellow', 'red', 'green', 'blue'] as const;
const colorSchemes = ['base', 'invokeYellow', 'invokeRed', 'invokeGreen', 'invokeBlue'] as const;
const variants = ['solid', 'outline', 'ghost', 'link'] as const;
const sizes = ['xs', 'sm', 'md', 'lg'] as const;

View File

@ -12,7 +12,7 @@ export const InvButton = memo(
<InvTooltip label={tooltip}>
<Button
ref={ref}
colorScheme={isChecked ? 'blue' : 'base'}
colorScheme={isChecked ? 'invokeBlue' : 'base'}
{...rest}
>
{children}
@ -22,7 +22,7 @@ export const InvButton = memo(
}
return (
<Button ref={ref} colorScheme={isChecked ? 'blue' : 'base'} {...rest}>
<Button ref={ref} colorScheme={isChecked ? 'invokeBlue' : 'base'} {...rest}>
{children}
</Button>
);

View File

@ -1,11 +1,11 @@
import { defineStyle, defineStyleConfig } from '@chakra-ui/react';
const blue = defineStyle(() => ({
color: 'blue.300',
const invokeBlue = defineStyle(() => ({
color: 'invokeBlue.300',
}));
export const headingTheme = defineStyleConfig({
variants: {
blue,
invokeBlue,
},
});

View File

@ -11,7 +11,7 @@ export const InvIconButton = memo(
<InvTooltip label={tooltip}>
<IconButton
ref={ref}
colorScheme={isChecked ? 'blue' : 'base'}
colorScheme={isChecked ? 'invokeBlue' : 'base'}
{...rest}
/>
</InvTooltip>
@ -21,7 +21,7 @@ export const InvIconButton = memo(
return (
<IconButton
ref={ref}
colorScheme={isChecked ? 'blue' : 'base'}
colorScheme={isChecked ? 'invokeBlue' : 'base'}
{...rest}
/>
);

View File

@ -142,7 +142,7 @@ const IAICanvasStagingAreaToolbar = () => {
aria-label={`${t('unifiedCanvas.previous')} (Left)`}
icon={<FaArrowLeft />}
onClick={handlePrevImage}
colorScheme="blue"
colorScheme="invokeBlue"
isDisabled={!shouldShowStagingImage}
/>
<InvButton
@ -156,7 +156,7 @@ const IAICanvasStagingAreaToolbar = () => {
aria-label={`${t('unifiedCanvas.next')} (Right)`}
icon={<FaArrowRight />}
onClick={handleNextImage}
colorScheme="blue"
colorScheme="invokeBlue"
isDisabled={!shouldShowStagingImage}
/>
</InvButtonGroup>
@ -166,7 +166,7 @@ const IAICanvasStagingAreaToolbar = () => {
aria-label={`${t('unifiedCanvas.accept')} (Enter)`}
icon={<FaCheck />}
onClick={handleAccept}
colorScheme="blue"
colorScheme="invokeBlue"
/>
<InvIconButton
tooltip={
@ -182,7 +182,7 @@ const IAICanvasStagingAreaToolbar = () => {
data-alert={!shouldShowStagingImage}
icon={shouldShowStagingImage ? <FaEye /> : <FaEyeSlash />}
onClick={handleToggleShouldShowStagingImage}
colorScheme="blue"
colorScheme="invokeBlue"
/>
<InvIconButton
tooltip={t('unifiedCanvas.saveToGallery')}
@ -190,7 +190,7 @@ const IAICanvasStagingAreaToolbar = () => {
isDisabled={!imageDTO || !imageDTO.is_intermediate}
icon={<FaSave />}
onClick={handleSaveToGallery}
colorScheme="blue"
colorScheme="invokeBlue"
/>
<InvIconButton
tooltip={t('unifiedCanvas.discardAll')}

View File

@ -34,7 +34,7 @@ export const EmbeddingPopover = memo((props: EmbeddingPopoverProps) => {
p={0}
insetBlockStart={-1}
shadow="dark-lg"
borderColor="blue.300"
borderColor="invokeBlue.300"
borderWidth="2px"
borderStyle="solid"
>

View File

@ -6,7 +6,7 @@ const AutoAddIcon = () => {
const { t } = useTranslation();
return (
<Flex position="absolute" insetInlineEnd={0} top={0} p={1}>
<Badge variant="solid" bg="blue.500">
<Badge variant="solid" bg="invokeBlue.500">
{t('common.auto')}
</Badge>
</Flex>

View File

@ -218,7 +218,7 @@ const GalleryBoard = ({
w="full"
maxW="full"
borderBottomRadius="base"
bg={isSelected ? 'blue.500' : 'base.600'}
bg={isSelected ? 'invokeBlue.500' : 'base.600'}
color={isSelected ? 'base.50' : 'base.100'}
lineHeight="short"
fontSize="xs"

View File

@ -124,7 +124,7 @@ const NoBoardBoard = memo(({ isSelected }: Props) => {
w="full"
maxW="full"
borderBottomRadius="base"
bg={isSelected ? 'blue.500' : 'base.600'}
bg={isSelected ? 'invokeBlue.500' : 'base.600'}
color={isSelected ? 'base.50' : 'base.100'}
lineHeight="short"
fontSize="xs"

View File

@ -143,8 +143,8 @@ const FoundModelsList = () => {
fontWeight="semibold"
p={2}
borderRadius={4}
color="blue.100"
bg="blue.600"
color="invokeBlue.100"
bg="invokeBlue.600"
>
{t('common.installed')}
</InvText>
@ -184,7 +184,7 @@ const FoundModelsList = () => {
<InvText fontWeight="semibold">
{t('modelManager.modelsFound')}: {foundModels.length}
</InvText>
<InvText fontWeight="semibold" color="blue.200">
<InvText fontWeight="semibold" color="invokeBlue.200">
{t('common.notInstalled')}: {filteredModels.length}
</InvText>
</Flex>

View File

@ -218,7 +218,7 @@ const AddNodePopover = () => {
p={0}
top={-1}
shadow="dark-lg"
borderColor="blue.400"
borderColor="invokeBlue.400"
borderWidth="2px"
borderStyle="solid"
>

View File

@ -28,7 +28,7 @@ const MinimapPanel = () => {
zoomable
nodeBorderRadius={15}
sx={minimapStyles}
nodeColor="var(--invokeai-colors-blue-600)"
nodeColor="var(--invokeai-colors-base-600)"
maskColor="var(--invokeai-colors-blackAlpha-600)"
/>
)}

View File

@ -22,7 +22,7 @@ const PruneQueueButton = ({ asIconButton }: Props) => {
tooltip={t('queue.pruneTooltip', { item_count: finishedCount })}
icon={<BsStars />}
onClick={pruneQueue}
colorScheme="blue"
colorScheme="invokeBlue"
/>
);
};

View File

@ -27,7 +27,7 @@ const ProgressBar = () => {
}
h={2}
w="full"
colorScheme="blue"
colorScheme="invokeBlue"
/>
);
};

View File

@ -40,7 +40,7 @@ const WorkflowLibraryListItem = ({ workflowDTO }: Props) => {
<Flex w="full" alignItems="center" gap={2} h={12}>
<Flex flexDir="column" flexGrow={1} h="full">
<Flex alignItems="center" w="full" h="50%">
<Heading size="sm" variant={isOpen ? 'blue' : undefined}>
<Heading size="sm" variant={isOpen ? 'invokeBlue' : undefined}>
{workflowDTO.name || t('workflows.unnamedWorkflow')}
</Heading>
<Spacer />

View File

@ -9,9 +9,9 @@ const WARNING = { H: 28, S: 42 };
const OK = { H: 113, S: 42 };
const ERROR = { H: 0, S: 42 };
const INVOKE_YELLOW = { H: 66, S: 92 };
const BLUE = { H: 200, S: 76 };
const GREEN = { H: 110, S: 69 };
const RED = { H: 16, S: 92 };
const INVOKE_BLUE = { H: 200, S: 76 };
const INVOKE_GREEN = { H: 110, S: 69 };
const INVOKE_RED = { H: 16, S: 92 };
export const getArbitraryBaseColor = (lightness: number) =>
`hsl(${BASE.H} ${BASE.S}% ${lightness}%)`;
@ -35,12 +35,12 @@ export const InvokeAIColors: InvokeAIThemeColors = {
INVOKE_YELLOW.S,
true
),
blue: generateColorPalette(BLUE.H, BLUE.S),
blueAlpha: generateColorPalette(BLUE.H, BLUE.S, true),
green: generateColorPalette(GREEN.H, GREEN.S),
greenAlpha: generateColorPalette(GREEN.H, GREEN.S, true),
red: generateColorPalette(RED.H, RED.S),
redAlpha: generateColorPalette(RED.H, RED.S, true),
invokeBlue: generateColorPalette(INVOKE_BLUE.H, INVOKE_BLUE.S),
invokeBlueAlpha: generateColorPalette(INVOKE_BLUE.H, INVOKE_BLUE.S, true),
invokeGreen: generateColorPalette(INVOKE_GREEN.H, INVOKE_GREEN.S),
invokeGreenAlpha: generateColorPalette(INVOKE_GREEN.H, INVOKE_GREEN.S, true),
invokeRed: generateColorPalette(INVOKE_RED.H, INVOKE_RED.S),
invokeRedAlpha: generateColorPalette(INVOKE_RED.H, INVOKE_RED.S, true),
};
export const layerStyleBody = {

View File

@ -13,12 +13,12 @@ export type InvokeAIThemeColors = {
errorAlpha: Partial<InvokeAIPaletteSteps>;
invokeYellow: Partial<InvokeAIPaletteSteps>;
invokeYellowAlpha: Partial<InvokeAIPaletteSteps>;
red: Partial<InvokeAIPaletteSteps>;
redAlpha: Partial<InvokeAIPaletteSteps>;
green: Partial<InvokeAIPaletteSteps>;
greenAlpha: Partial<InvokeAIPaletteSteps>;
blue: Partial<InvokeAIPaletteSteps>;
blueAlpha: Partial<InvokeAIPaletteSteps>;
invokeRed: Partial<InvokeAIPaletteSteps>;
invokeRedAlpha: Partial<InvokeAIPaletteSteps>;
invokeGreen: Partial<InvokeAIPaletteSteps>;
invokeGreenAlpha: Partial<InvokeAIPaletteSteps>;
invokeBlue: Partial<InvokeAIPaletteSteps>;
invokeBlueAlpha: Partial<InvokeAIPaletteSteps>;
};
export type InvokeAIPaletteSteps = {