Skip to content

Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active

🧹 refactor: Clear Raw-Color and Unknown-Class Suppressions in Panels (#16818)

Marco Berettaa66b479ffead
diff --git a/client/src/components/Prompts/display/PromptTextCard.tsx b/client/src/components/Prompts/display/PromptTextCard.tsx
index 46fa0f3487..41bf4d23c9 100644
--- a/client/src/components/Prompts/display/PromptTextCard.tsx
+++ b/client/src/components/Prompts/display/PromptTextCard.tsx
@@ -52,8 +52,8 @@ const PromptTextCard = ({ mainText }: PromptTextCardProps) => {
}, [mainText, showToast, localize, isCopied]);
return (
- <div className="relative flex h-full flex-col rounded-xl border border-border-medium bg-transparent">
- <div className="absolute right-2 top-2 z-10">
+ <div className="border-border-medium relative flex h-full flex-col rounded-xl border bg-transparent">
+ <div className="absolute top-2 right-2 z-10">
<TooltipAnchor
description={isCopied ? localize('com_ui_copied') : localize('com_ui_copy')}
render={
@@ -67,7 +67,7 @@ const PromptTextCard = ({ mainText }: PromptTextCardProps) => {
}
aria-live="polite"
>
- <MorphIcon icon={isCopied ? Check : Copy} className="size-4 text-text-secondary" />
+ <MorphIcon icon={isCopied ? Check : Copy} className="text-text-secondary size-4" />
</Button>
}
/>
@@ -88,7 +88,7 @@ const PromptTextCard = ({ mainText }: PromptTextCardProps) => {
]}
/** @ts-ignore */
components={{ p: PromptVariableGfm, code: codeNoExecution }}
- className="markdown prose dark:prose-invert light my-1 max-w-none break-words text-text-primary"
+ className="markdown prose light text-text-primary my-1 max-w-none break-words"
>
{mainText}
</ReactMarkdown>
diff --git a/client/src/components/Prompts/editor/PromptEditor.tsx b/client/src/components/Prompts/editor/PromptEditor.tsx
index 2a52491091..b9ebc0d59b 100644
--- a/client/src/components/Prompts/editor/PromptEditor.tsx
+++ b/client/src/components/Prompts/editor/PromptEditor.tsx
@@ -131,7 +131,7 @@ const PromptEditor: React.FC<Props> = ({ name, isEditing, setIsEditing }) => {
rehypePlugins={rehypePlugins}
/** @ts-ignore */
components={{ p: PromptVariableGfm, code: codeNoExecution }}
- className="markdown prose dark:prose-invert light text-text-primary w-full break-words"
+ className="markdown prose light text-text-primary w-full break-words"
>
{field.value}
</ReactMarkdown>
diff --git a/client/src/components/Prompts/forms/VariableForm.tsx b/client/src/components/Prompts/forms/VariableForm.tsx
index 02ac40e20e..d230b0272b 100644
--- a/client/src/components/Prompts/forms/VariableForm.tsx
+++ b/client/src/components/Prompts/forms/VariableForm.tsx
@@ -145,7 +145,7 @@ export default function VariableForm({
return (
<div className="mx-auto p-1 md:container">
<form onSubmit={handleSubmit(onSubmit)} className="space-y-4">
- <div className="mb-6 max-h-screen max-w-[80vw] overflow-auto rounded-md bg-surface-tertiary p-4 text-text-secondary sm:max-w-full md:max-h-96">
+ <div className="bg-surface-tertiary text-text-secondary mb-6 max-h-screen max-w-[80vw] overflow-auto rounded-md p-4 sm:max-w-full md:max-h-96">
<ReactMarkdown
/** @ts-ignore */
remarkPlugins={[supersub, remarkGfm, [remarkMath, { singleDollarTextMath: false }]]}
@@ -157,7 +157,7 @@ export default function VariableForm({
]}
/** @ts-ignore */
components={{ code: codeNoExecution, p: PromptVariableGfm }}
- className="markdown prose dark:prose-invert light my-1 max-h-[50vh] max-w-full break-words"
+ className="markdown prose light my-1 max-h-[50vh] max-w-full break-words"
>
{generateHighlightedMarkdown()}
</ReactMarkdown>
@@ -176,7 +176,7 @@ export default function VariableForm({
placeholder={field.config.variable}
className={cn(
defaultTextProps,
- 'mb-1 rounded px-3 py-2 focus:bg-surface-tertiary',
+ 'focus:bg-surface-tertiary mb-1 rounded px-3 py-2',
)}
value={value}
onChange={onChange}
@@ -196,7 +196,7 @@ export default function VariableForm({
id={`fields.${index}.value`}
className={cn(
defaultTextProps,
- 'peer rounded px-3 py-2 focus:bg-surface-tertiary',
+ 'peer focus:bg-surface-tertiary rounded px-3 py-2',
)}
placeholder=""
maxRows={8}
@@ -204,7 +204,7 @@ export default function VariableForm({
/>
<label
htmlFor={`fields.${index}.value`}
- className="absolute left-3 top-0 text-sm text-text-secondary transition-all duration-200 peer-focus:-top-6 peer-focus:left-1 peer-focus:text-xs peer-focus:text-text-primary peer-[:not(:placeholder-shown)]:-top-6 peer-[:not(:placeholder-shown)]:left-1 peer-[:not(:placeholder-shown)]:text-xs"
+ className="text-text-secondary peer-focus:text-text-primary absolute top-0 left-3 text-sm transition-all duration-200 peer-focus:-top-6 peer-focus:left-1 peer-focus:text-xs peer-[:not(:placeholder-shown)]:-top-6 peer-[:not(:placeholder-shown)]:left-1 peer-[:not(:placeholder-shown)]:text-xs"
>
{field.config.variable}
</label>
diff --git a/client/src/components/Skills/display/SkillMarkdownRenderer.tsx b/client/src/components/Skills/display/SkillMarkdownRenderer.tsx
index 1b823f6c95..b8cdd17bd7 100644
--- a/client/src/components/Skills/display/SkillMarkdownRenderer.tsx
+++ b/client/src/components/Skills/display/SkillMarkdownRenderer.tsx
@@ -156,8 +156,7 @@ function SkillMarkdownRenderer({
components={components as unknown as Record<string, React.ElementType>}
urlTransform={skillUrlTransform}
className={
- className ??
- 'markdown prose dark:prose-invert light w-full break-words leading-[1.65rem] text-text-primary'
+ className ?? 'markdown prose light text-text-primary w-full leading-[1.65rem] break-words'
}
>
{content}
diff --git a/client/src/components/Skills/forms/SkillContentEditor.tsx b/client/src/components/Skills/forms/SkillContentEditor.tsx
index 73750a0e16..ca6b6f6642 100644
--- a/client/src/components/Skills/forms/SkillContentEditor.tsx
+++ b/client/src/components/Skills/forms/SkillContentEditor.tsx
@@ -128,7 +128,7 @@ const SkillContentEditor: React.FC<SkillContentEditorProps> = ({
/** @ts-ignore - PluggableList vs Pluggable[] shape drift */
rehypePlugins={REHYPE_PLUGINS}
components={MARKDOWN_COMPONENTS as unknown as Record<string, React.ElementType>}
- className="markdown prose dark:prose-invert light text-text-primary w-full break-words"
+ className="markdown prose light text-text-primary w-full break-words"
>
{field.value}
</ReactMarkdown>
diff --git a/client/src/style.css b/client/src/style.css
index 9ed6b773e6..3084934edd 100644
--- a/client/src/style.css
+++ b/client/src/style.css
@@ -1329,7 +1329,7 @@ html:not(.high-contrast) .markdown :is(th, td):last-child {
--tw-text-opacity: 1;
color: rgba(64, 65, 79, var(--tw-text-opacity));
}
-.dark .dark\:prose-invert {
+.dark .prose {
--tw-prose-body: var(--tw-prose-invert-body);
--tw-prose-headings: var(--tw-prose-invert-headings);
--tw-prose-lead: var(--tw-prose-invert-lead);
diff --git a/eslint-suppressions.json b/eslint-suppressions.json
index 092341eedc..9717469cff 100644
--- a/eslint-suppressions.json
+++ b/eslint-suppressions.json
@@ -1274,9 +1274,6 @@
"client/src/components/Prompts/display/PromptTextCard.tsx": {
"shadcn/no-restyle": {
"count": 2
- },
- "shadcn/no-unknown-classes": {
- "count": 1
}
},
"client/src/components/Prompts/display/PromptVariables.tsx": {
@@ -1292,9 +1289,6 @@
"client/src/components/Prompts/editor/PromptEditor.tsx": {
"shadcn/no-restyle": {
"count": 11
- },
- "shadcn/no-unknown-classes": {
- "count": 1
}
},
"client/src/components/Prompts/editor/VariablesDropdown.tsx": {
@@ -1337,9 +1331,6 @@
"shadcn/no-restyle": {
"count": 8
},
- "shadcn/no-unknown-classes": {
- "count": 1
- },
"shadcn/require-static-classes": {
"count": 2
}
@@ -1869,9 +1860,6 @@
"client/src/components/Skills/display/SkillMarkdownRenderer.tsx": {
"shadcn/no-arbitrary-values": {
"count": 1
- },
- "shadcn/no-unknown-classes": {
- "count": 1
}
},
"client/src/components/Skills/display/SkillState.tsx": {
@@ -1887,9 +1875,6 @@
"client/src/components/Skills/forms/SkillContentEditor.tsx": {
"shadcn/no-restyle": {
"count": 13
- },
- "shadcn/no-unknown-classes": {
- "count": 1
}
},
"client/src/components/Skills/forms/SkillForm.tsx": {