Skip to content

Commit ee47089

Browse files
merchakoclaude
andcommitted
fix: restore JSX indentation in design-principles.mdx
The shadcn/ui upgrade (ac37eda) stripped 2-space indentation from JSX blocks inside preview={} props, leaving them flush-left. This restores the original indentation style. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent d4a411b commit ee47089

1 file changed

Lines changed: 31 additions & 31 deletions

File tree

lib/platform-bible-react/src/stories/guidelines/design-principles.mdx

Lines changed: 31 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,9 @@ Tooltips are required for every icon button and any control without a visible la
114114
variant="dont"
115115
previewClassName="tw:pb-8"
116116
preview={
117-
<Button variant="outline" size="icon" aria-label="Save" >
118-
<Save />
119-
</Button>
117+
<Button variant="outline" size="icon" aria-label="Save">
118+
<Save />
119+
</Button>
120120
}
121121
>
122122
This icon button lacks a tooltip, so users can't learn what it means.
@@ -127,14 +127,14 @@ Tooltips are required for every icon button and any control without a visible la
127127
variant="dont"
128128
previewClassName="tw:pb-8"
129129
preview={
130-
<TooltipProvider>
131-
<Tooltip open>
132-
<TooltipTrigger asChild>
133-
<Button>Save</Button>
134-
</TooltipTrigger>
135-
<TooltipContent side="bottom">Save</TooltipContent>
136-
</Tooltip>
137-
</TooltipProvider>
130+
<TooltipProvider>
131+
<Tooltip open>
132+
<TooltipTrigger asChild>
133+
<Button>Save</Button>
134+
</TooltipTrigger>
135+
<TooltipContent side="bottom">Save</TooltipContent>
136+
</Tooltip>
137+
</TooltipProvider>
138138
}
139139
>
140140
The tooltip only repeats the visible label — omit it.
@@ -148,16 +148,16 @@ Keep tooltip text short enough to scan at a glance. A tooltip is a hint, not an
148148
variant="dont"
149149
previewClassName="tw:pb-16"
150150
preview={
151-
<TooltipProvider>
152-
<Tooltip open>
153-
<TooltipTrigger asChild>
154-
<Button variant="outline" size="icon" aria-label="Save">
155-
<Save />
156-
</Button>
157-
</TooltipTrigger>
158-
<TooltipContent side="bottom" className="tw:max-w-[200px]">Click this button to apply your changes and save the current document</TooltipContent>
159-
</Tooltip>
160-
</TooltipProvider>
151+
<TooltipProvider>
152+
<Tooltip open>
153+
<TooltipTrigger asChild>
154+
<Button variant="outline" size="icon" aria-label="Save">
155+
<Save />
156+
</Button>
157+
</TooltipTrigger>
158+
<TooltipContent side="bottom" className="tw:max-w-[200px]">Click this button to apply your changes and save the current document</TooltipContent>
159+
</Tooltip>
160+
</TooltipProvider>
161161
}
162162
>
163163
Too long to scan — a tooltip is a hint, not a sentence.
@@ -167,16 +167,16 @@ Keep tooltip text short enough to scan at a glance. A tooltip is a hint, not an
167167
variant="do"
168168
previewClassName="tw:pb-16"
169169
preview={
170-
<TooltipProvider>
171-
<Tooltip open>
172-
<TooltipTrigger asChild>
173-
<Button variant="outline" size="icon" aria-label="Save">
174-
<Save />
175-
</Button>
176-
</TooltipTrigger>
177-
<TooltipContent side="bottom">Save changes</TooltipContent>
178-
</Tooltip>
179-
</TooltipProvider>
170+
<TooltipProvider>
171+
<Tooltip open>
172+
<TooltipTrigger asChild>
173+
<Button variant="outline" size="icon" aria-label="Save">
174+
<Save />
175+
</Button>
176+
</TooltipTrigger>
177+
<TooltipContent side="bottom">Save changes</TooltipContent>
178+
</Tooltip>
179+
</TooltipProvider>
180180
}
181181
>
182182
The tooltip adds meaning an icon alone cannot convey, and it's short enough to read at a glance.

0 commit comments

Comments
 (0)