mirror of
https://github.com/supabase/supabase.git
synced 2026-10-05 17:35:10 +03:00
## What kind of change does this PR introduce? UI clarification. ## What is the current behavior? Our messaging around the compatibility of: - Dedicated pooler - Shared pooler ...in conjunction with the following connection types: - IPv4 - IPv6 - Direct connection ...is hard to parse. ## What is the new behavior? Copywriting clarifications to all of the above. Plus: - Broader copywriting clarifications to `IPV4SidePanel` - Replace deprecated `Radio` component with `RadioGroupItem_Shadcn_` as the former has little-to-no visual difference between unselected and selected states - Fixed `SidePanel` header gap and button labelling ## Additional context | Before | After | | --- | --- | | <img width="1024" height="563" alt="AWS Healthy Toolshed Supabase-4587771A-83A2-40E8-845B-256CE7E1A7DB" src="https://github.com/user-attachments/assets/09591fa1-48b8-4f3c-aaef-733af8dbdc9a" /> | <img width="1024" height="563" alt="AWS Healthy Toolshed Supabase-D56A2209-7421-43C2-A7C1-6C6965B3F008" src="https://github.com/user-attachments/assets/13a05e51-02a5-486a-9549-4c5fe049c65a" /> | | <img width="1024" height="563" alt="Add ons Supabase-10CC55BC-C3D8-4E40-9F73-31FFE8D7F42A" src="https://github.com/user-attachments/assets/73e206dc-58a3-4356-8e31-cf2ad74383f8" /> | <img width="1024" height="563" alt="Add ons Supabase-6311B7FE-4291-4982-968E-5EDBA76DE519" src="https://github.com/user-attachments/assets/503667ef-9b36-4d62-9872-53ac6b32f56f" /> | --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
35 lines
983 B
TypeScript
35 lines
983 B
TypeScript
import { PropsWithChildren } from 'react'
|
|
import { Tooltip, TooltipContent, TooltipTrigger } from 'ui'
|
|
|
|
export interface ProjectUpdateDisabledTooltipProps {
|
|
projectUpdateDisabled: boolean
|
|
projectNotActive?: boolean
|
|
tooltip?: string
|
|
}
|
|
|
|
export const ProjectUpdateDisabledTooltip = ({
|
|
projectUpdateDisabled,
|
|
projectNotActive = false,
|
|
children,
|
|
tooltip,
|
|
}: PropsWithChildren<ProjectUpdateDisabledTooltipProps>) => {
|
|
const tooltipMessage =
|
|
tooltip ||
|
|
(projectUpdateDisabled
|
|
? 'Subscription changes are currently disabled. Our engineers are working on a fix.'
|
|
: projectNotActive
|
|
? 'Unable to update subscription as project is currently not active'
|
|
: undefined)
|
|
|
|
return (
|
|
<Tooltip>
|
|
<TooltipTrigger asChild>{children}</TooltipTrigger>
|
|
{tooltipMessage !== undefined && (
|
|
<TooltipContent side="bottom" className="w-64 text-center">
|
|
{tooltipMessage}
|
|
</TooltipContent>
|
|
)}
|
|
</Tooltip>
|
|
)
|
|
}
|