Skip to content

Fix import statements casing for Admonition - #48374

Merged
joshenlim merged 1 commit into
masterfrom
joshen/fix-import-statements-casing-for-admonition
Jul 28, 2026
Merged

joshenlim merged 1 commit into
masterfrom
joshen/fix-import-statements-casing-for-admonition

Conversation

@joshenlim

@joshenlim joshenlim commented Jul 28, 2026 •

Copy link
Copy Markdown
Member

Context

Was running into typecheck errors when running the ts check locally - this should resolve it

Summary by CodeRabbit

  • Bug Fixes
    • Corrected component references across confirmation dialogs, error displays, privacy settings, and SQL-to-REST views.
    • Improved compatibility for environments with case-sensitive file handling.

@joshenlim
joshenlim requested a review from a team as a code owner July 28, 2026 02:59
@vercel

vercel Bot commented Jul 28, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
design-system Ready Ready Preview, Comment Jul 28, 2026 3:06am
docs Ready Ready Preview, Comment, Open in v0 Jul 28, 2026 3:06am
studio-self-hosted Ready Ready Preview, Comment Jul 28, 2026 3:06am
studio-staging Ready Ready Preview, Comment Jul 28, 2026 3:06am
ui-library Ready Ready Preview, Comment Jul 28, 2026 3:06am
zone-www-dot-com Ready Ready Preview, Comment, Open in v0 Jul 28, 2026 3:06am
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
studio Ignored Ignored Jul 28, 2026 3:06am

Request Review

@supabase

supabase Bot commented Jul 28, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project xguihxuzqibwxjnimxev because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@coderabbitai

coderabbitai Bot commented Jul 28, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 6148b78f-5903-4a1c-89c4-0e8478e324a5

📥 Commits

Reviewing files that changed from the base of the PR and between 0f31498 and 62b7b12.

📒 Files selected for processing (5)
  • packages/ui-patterns/src/Dialogs/ConfirmationModal.tsx
  • packages/ui-patterns/src/Dialogs/TextConfirmModal.tsx
  • packages/ui-patterns/src/ErrorDisplay/ErrorDisplay.tsx
  • packages/ui-patterns/src/PrivacySettings/index.tsx
  • packages/ui-patterns/src/SqlToRest/index.tsx

📝 Walkthrough

Walkthrough

Five ui-patterns components update Admonition or WarningIcon imports to use the lowercase ../admonition module path. No component logic, props, state, or public exports change.

Changes

Admonition import casing

Layer / File(s) Summary
Update Admonition import call sites
packages/ui-patterns/src/Dialogs/*, packages/ui-patterns/src/ErrorDisplay/ErrorDisplay.tsx, packages/ui-patterns/src/PrivacySettings/index.tsx, packages/ui-patterns/src/SqlToRest/index.tsx
Imports now reference ../admonition instead of ../Admonition; component behavior remains unchanged.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Possibly related PRs

Suggested reviewers: kaitou786

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description is missing the required template sections and only provides a brief context note. Add the required sections: CONTRIBUTING.md confirmation, change type, current behavior, new behavior, and additional context/issues.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely summarizes the main change: fixing Admonition import casing.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch joshen/fix-import-statements-casing-for-admonition

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@joshenlim
joshenlim merged commit 8aeae07 into master Jul 28, 2026
36 checks passed
@joshenlim
joshenlim deleted the joshen/fix-import-statements-casing-for-admonition branch July 28, 2026 03:19
@github-actions

github-actions Bot commented Jul 28, 2026 •

Copy link
Copy Markdown
Contributor

Braintrust eval report

Assistant (master-1785208984)

Score Average Improvements Regressions
Completeness 95% (-4pp) 1 🟢 3 🔴
Conciseness 45.6% (+4pp) 12 🟢 9 🔴
Correctness 68.4% (0pp) 2 🟢 3 🔴
Docs Faithfulness 64.1% (-2pp) 4 🟢 3 🔴
Goal Completion 83.8% (+2pp) 5 🟢 4 🔴
Knowledge Usage 56.4% (-33pp) 1 🟢 8 🔴
Tool Usage 53.3% (-19pp) - 6 🔴
SQL Identifier Quoting 100% (+0pp) - -
SQL Validity 100% (+0pp) - -
Safety 85.7% (+5pp) 1 🟢 1 🔴
Time_to_first_token 3.07tok (+0.06tok) 14 🟢 14 🔴
Llm_calls 6.62 (-0.78) 4 🟢 20 🔴
Tool_calls 2.07 (-0.82) 7 🟢 17 🔴
Errors 0.02 (+0) 1 🟢 1 🔴
Llm_errors 0.01 (+0) 1 🟢 1 🔴
Tool_errors 0 (+0) - -
Prompt_tokens 24615.69tok (+1311.26tok) 17 🟢 12 🔴
Prompt_cached_tokens 6826.67tok (-894.53tok) 8 🟢 19 🔴
Prompt_cache_creation_tokens 0tok (+0tok) - -
Prompt_cache_creation_5m_tokens 0tok (+0tok) - -
Prompt_cache_creation_1h_tokens 0tok (+0tok) - -
Completion_tokens 525.02tok (-69.4tok) 22 🟢 7 🔴
Completion_reasoning_tokens 82.87tok (-20.14tok) 16 🟢 10 🔴
Completion_accepted_prediction_tokens 0tok (+0tok) - -
Completion_rejected_prediction_tokens 0tok (+0tok) - -
Completion_audio_tokens 0tok (+0tok) - -
Total_tokens 25140.71tok (+1241.86tok) 17 🟢 12 🔴
Estimated_cost 0$ (+0$) 14 🟢 12 🔴
Duration 20.46s (+2.44s) 13 🟢 16 🔴
Llm_duration 10.6s (-1.33s) 21 🟢 8 🔴

alaister added a commit that referenced this pull request Jul 28, 2026
…onition (#48377)

Follow-up to #48344: collapses the two resolution paths for the
Admonition module into one.

`src/admonition.tsx` was a back-compat shim re-exporting
`src/Admonition/`. Two ways to resolve one module is exactly what
produced the macOS self-import bug fixed in #48344, and the local
typecheck errors that #48374 worked around. This removes the shim and
standardizes on the PascalCase subpath, matching every other export in
the package.

**Changed:**

- Codemodded all 246 `ui-patterns/admonition` imports to
`ui-patterns/Admonition` (240 `.tsx`, 5 `.mdx`, 1 `.ts` across studio,
docs, www, design-system, and lite-studio)
- Pointed the 5 internal `'../admonition'` imports back at the
`'../Admonition'` directory

**Removed:**

- `packages/ui-patterns/src/admonition.tsx`, and its `./admonition`
entry in the exports map (regenerated with `pnpm gen:exports`)

## To test

- `grep -r "ui-patterns/admonition" --include='*.ts*'` → no hits
- `pnpm test:case-hazards` → passes
- `pnpm typecheck` → all 15 tasks green
- `pnpm --filter studio run lint:ratchet` → passes
- `pnpm --filter ui-patterns vitest run src/Admonition` → 11 tests pass

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Standardized Admonition component imports across the application and
documentation.
* Improved compatibility with case-sensitive environments by using the
canonical component path.
  * Removed the legacy Admonition import entry point.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Alaister Young <[email protected]>
alaister added a commit that referenced this pull request Jul 28, 2026
Conflicts were both in import blocks that master's Admonition casing fix
(#48374) touched and this branch had rewritten:

- DiskManagementForm.tsx: kept this branch's PageSection imports; master's
  side was the pre-PR Collapsible/Separator/Admonition block, none of which
  this branch still uses
- ComputeSizeField.tsx: dropped the Admonition import, unused here since the
  branch moved to FormMessage

Master also removed the lowercase ui-patterns/admonition shim, so the two
files still importing it (DiskManagementForm.sections.tsx, ui/NoticeBar.tsx)
now import from ui-patterns/Admonition.

Claude-Session: https://claude.ai/code/session_01RTy2gyfjnzF96p2aW56VfH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants