mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-08-27 04:07:05 +00:00
📩 fix: Restore Primary Action Button Visibility in Light Mode (#12591)
The default <Button> variant (bg-primary / text-primary-foreground) renders invisible in light mode on the Agent Marketplace 'Start Chat' button and the Grant Access dialog 'Save Changes' button, making these primary actions undiscoverable without hovering. Switch these three affirmative-action buttons to variant='submit', which uses the hardcoded 'bg-surface-submit text-white' combination already defined in the Button component specifically to avoid the contrast issues of the default variant (see the comment above the 'submit' variant in packages/client/src/components/Button.tsx). No visual change in dark mode; in light mode the buttons now render as the green submit color with white text, matching the semantic intent of the action. Co-authored-by: Timothy Look <timothy.look@pmv.eu>
This commit is contained in:
parent
1a83f36cda
commit
46b529a86a
3 changed files with 13 additions and 2 deletions
|
|
@ -183,7 +183,12 @@ const AgentDetail: React.FC<AgentDetailProps> = ({ agent, isOpen, onClose }) =>
|
|||
>
|
||||
<Link className="h-4 w-4" aria-hidden="true" />
|
||||
</Button>
|
||||
<Button className="w-full max-w-xs" onClick={handleStartChat} disabled={!agent}>
|
||||
<Button
|
||||
variant="submit"
|
||||
className="w-full max-w-xs"
|
||||
onClick={handleStartChat}
|
||||
disabled={!agent}
|
||||
>
|
||||
{localize('com_agents_start_chat')}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -181,7 +181,12 @@ const AgentDetailContent: React.FC<AgentDetailContentProps> = ({ agent }) => {
|
|||
>
|
||||
<Link className="h-4 w-4" aria-hidden="true" />
|
||||
</Button>
|
||||
<Button className="w-full max-w-xs" onClick={handleStartChat} disabled={!agent}>
|
||||
<Button
|
||||
variant="submit"
|
||||
className="w-full max-w-xs"
|
||||
onClick={handleStartChat}
|
||||
disabled={!agent}
|
||||
>
|
||||
{localize('com_agents_start_chat')}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -401,6 +401,7 @@ export default function GenericGrantAccessDialog({
|
|||
</Button>
|
||||
</OGDialogClose>
|
||||
<Button
|
||||
variant="submit"
|
||||
onClick={handleSave}
|
||||
disabled={
|
||||
updatePermissionsMutation.isLoading ||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue