mirror of
https://github.com/twentyhq/twenty
synced 2026-04-21 13:37:22 +00:00
## Summary Two small visual issues with the shared `CardPicker` (used in the Enterprise plan modal and the onboarding plan picker): - Labels like \`Monthly\` / \`Yearly\` were center-aligned inside their cards while the subtitle (\`\$25 / seat / month\`) stayed left-aligned, because the underlying \`<button>\` element's default \`text-align: center\` was leaking into the children. - The hover background was painted on the same element that owned the inner padding, so the hover surface didn't visually feel like the whole card. This PR: - Moves the content padding into a new \`StyledCardInner\` so the outer \`<button>\` is just the card chrome (border + radius + background + hover). - Adds \`text-align: left\` so titles align with their subtitles. - Hoists \`cursor: pointer\` out of \`:hover\` (it should be on by default for the card). Affects: - \`EnterprisePlanModal\` (Settings → Enterprise) - \`ChooseYourPlanContent\` (onboarding trial picker)
37 lines
1.5 KiB
TypeScript
37 lines
1.5 KiB
TypeScript
import { AgentChatStreamSubscriptionEffect } from '@/ai/components/AgentChatStreamSubscriptionEffect';
|
|
import { AgentChatMessagesFetchEffect } from '@/ai/components/AgentChatMessagesFetchEffect';
|
|
import { AgentChatSessionStartTimeEffect } from '@/ai/components/AgentChatSessionStartTimeEffect';
|
|
|
|
import { AgentChatStreamingAutoScrollEffect } from '@/ai/components/AgentChatStreamingAutoScrollEffect';
|
|
import { AgentChatStreamingPartsDiffSyncEffect } from '@/ai/components/AgentChatStreamingPartsDiffSyncEffect';
|
|
import { AgentChatThreadInitializationEffect } from '@/ai/components/AgentChatThreadInitializationEffect';
|
|
import { AgentChatComponentInstanceContext } from '@/ai/states/AgentChatComponentInstanceContext';
|
|
import { Suspense } from 'react';
|
|
|
|
export const AgentChatProviderContent = ({
|
|
children,
|
|
isAiEnabled,
|
|
}: {
|
|
children: React.ReactNode;
|
|
isAiEnabled: boolean;
|
|
}) => {
|
|
return (
|
|
<Suspense fallback={null}>
|
|
<AgentChatComponentInstanceContext.Provider
|
|
value={{ instanceId: 'agentChatComponentInstance' }}
|
|
>
|
|
{isAiEnabled && (
|
|
<>
|
|
<AgentChatThreadInitializationEffect />
|
|
<AgentChatMessagesFetchEffect />
|
|
<AgentChatStreamSubscriptionEffect />
|
|
<AgentChatStreamingPartsDiffSyncEffect />
|
|
<AgentChatSessionStartTimeEffect />
|
|
<AgentChatStreamingAutoScrollEffect />
|
|
</>
|
|
)}
|
|
{children}
|
|
</AgentChatComponentInstanceContext.Provider>
|
|
</Suspense>
|
|
);
|
|
};
|