mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-18 09:20:15 +01:00
refactor(getIcon.jsx): if model is GPT-4, change background color to black.
This commit is contained in:
parent
24a82c8018
commit
871bc4c78b
1 changed files with 4 additions and 4 deletions
|
|
@ -6,7 +6,7 @@ import BingIcon from '../components/svg/BingIcon';
|
|||
|
||||
const getIcon = props => {
|
||||
// { size = 30, isCreatedByUser, model, chatGptLabel, error, ...props }
|
||||
const { size = 30, isCreatedByUser, button } = props;
|
||||
const { size = 30, isCreatedByUser, button, model } = props;
|
||||
|
||||
if (isCreatedByUser)
|
||||
return (
|
||||
|
|
@ -38,9 +38,9 @@ const getIcon = props => {
|
|||
const { chatGptLabel } = props;
|
||||
|
||||
icon = <GPTIcon size={size * 0.7} />;
|
||||
bg = chatGptLabel
|
||||
bg = model && model.toLowerCase() === 'gpt-4' ? 'black' : (chatGptLabel
|
||||
? `rgba(16, 163, 127, ${button ? 0.75 : 1})`
|
||||
: `rgba(16, 163, 127, ${button ? 0.75 : 1})`;
|
||||
: `rgba(16, 163, 127, ${button ? 0.75 : 1})`);
|
||||
name = chatGptLabel || 'ChatGPT';
|
||||
} else if (endpoint === 'bingAI') {
|
||||
const { jailbreak } = props;
|
||||
|
|
@ -50,7 +50,7 @@ const getIcon = props => {
|
|||
name = jailbreak ? 'Sydney' : 'BingAI';
|
||||
} else if (endpoint === 'chatGPTBrowser') {
|
||||
icon = <GPTIcon size={size * 0.7} />;
|
||||
bg = `rgba(0, 163, 255, ${button ? 0.75 : 1})`;
|
||||
bg = model && model.toLowerCase() === 'gpt-4' ? 'black' : `rgba(0, 163, 255, ${button ? 0.75 : 1})`;
|
||||
name = 'ChatGPT';
|
||||
} else if (endpoint === null) {
|
||||
icon = <GPTIcon size={size * 0.7} />;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue