Visual Referencing
Creating brand consistency or collaborations in your applications with visual referencing and generative AI
Summary
Example: Creating brand themed elements through visual referencing
Prompt:
Create a McDonald's themed button component in Next.js and Chakra UI. Generate a color palette from a single color based on a happy mood.Response:
import React from 'react';
import { Button } from '@chakra-ui/react';
const McDonaldsThemedButton = ({ children, ...props }) => {
const brandColors = {
primary: '#FFC72C',
secondary: '#E51837',
};
const generatedHappyPalette = {
100: '#FFD580',
200: '#FFCA61',
300: '#FFBF42',
400: '#FFB523',
500: '#FFAB04',
};
return (
<Button
bg={brandColors.primary}
color={brandColors.secondary}
_hover={{ bg: generatedHappyPalette[300] }}
{...props}
>
{children}
</Button>
);
};
export default McDonaldsThemedButton;Discussion
Last updated