Skip to content

Allow formatting compiled code files, and configure whether code ligatures are used - #152

Merged
EskiMojo14 merged 11 commits into
mainfrom
code-improvements
Jul 16, 2026
Merged

Allow formatting compiled code files, and configure whether code ligatures are used#152
EskiMojo14 merged 11 commits into
mainfrom
code-improvements

Conversation

@EskiMojo14

Copy link
Copy Markdown
Member

No description provided.

@netlify

netlify Bot commented Jul 16, 2026

Copy link
Copy Markdown

Deploy Preview for schemabenchmarks ready!

Name Link
🔨 Latest commit c990c2a
🔍 Latest deploy log https://app.netlify.com/projects/schemabenchmarks/deploys/6a596104abe1b1000850c652
😎 Deploy Preview https://deploy-preview-152--schemabenchmarks.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds two user-facing capabilities to the website: (1) an option to view formatted versions of compiled repository artifacts and (2) a user preference to enable/disable code ligatures (persisted via cookie + analytics).

Changes:

  • Introduces server-side code formatting via oxfmt and exposes it through the repo raw-file viewer (with a UI toggle for compiled artifacts).
  • Adds a new “Code ligatures” preference (cookie-backed) and wires it into the app root + preferences dialog.
  • Updates code block UI to support an actions area and adjusts formatting/import-sorting configuration.

Reviewed changes

Copilot reviewed 16 out of 17 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
website/vite.config.ts Adds oxfmt to client import-protection list.
website/src/shared/styles/index.css Updates font-feature settings and adds ligature toggle CSS + icon styling.
website/src/shared/lib/prefs/index.ts Adds server fns + middleware to get/set ligature preference cookie (+ analytics).
website/src/shared/lib/prefs/constants.ts Adds ligatureSchema and Ligature type.
website/src/shared/lib/highlight.ts Adds getFormattedCodeFn server fn + react-query options wrapper using oxfmt.
website/src/shared/lib/analytics.ts Extends analytics event typings for change_ligature.
website/src/shared/components/prefs/provider.tsx Adds LigatureProvider wiring.
website/src/shared/components/prefs/context.tsx Adds LigatureContext / useLigature.
website/src/shared/components/dialog/pref.tsx Adds “Code ligatures” preference UI option.
website/src/shared/components/code/index.tsx Adds actions slot and renames copy to showCopy.
website/src/routes/repo/raw.$.tsx Adds formatted-view search param + formatting toggle and query usage.
website/src/routes/__root.tsx Loads ligature preference and applies it to the document + provider tree.
website/package.json Adds oxfmt dependency for the website package.
pnpm-workspace.yaml Adds oxfmt to the workspace catalog.
pnpm-lock.yaml Updates lockfile entries for oxfmt catalog usage.
package.json Switches root oxfmt version to catalog:.
.oxfmtrc.jsonc Updates import-sorting config key (experimentalSortImportssortImports).
Files not reviewed (1)
  • pnpm-lock.yaml: Generated file

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread website/src/shared/styles/index.css
Comment thread website/src/shared/styles/index.css
Comment thread website/src/shared/styles/index.css
Comment thread website/src/shared/components/dialog/pref.tsx
Comment thread website/src/routes/repo/raw.$.tsx Outdated
Comment thread website/src/routes/repo/raw.$.tsx Outdated
@EskiMojo14
EskiMojo14 force-pushed the code-improvements branch 4 times, most recently from 597436a to 9dbf1b7 Compare July 16, 2026 17:46
@EskiMojo14
EskiMojo14 requested a review from Copilot July 16, 2026 17:47

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 18 out of 19 changed files in this pull request and generated 4 comments.

Files not reviewed (1)
  • pnpm-lock.yaml: Generated file
Comments suppressed due to low confidence (1)

website/src/shared/styles/index.css:159

  • The styles that used to apply to .code-block__copy inside .code-block__title were moved to .code-block__actions, but MDX pre blocks still render the copy button as a direct child (.code-block__title > .code-block__copy). That copy button will lose the margin/RTL alignment styling. Consider keeping a direct-child fallback selector so both structures are styled.
    .code-block__actions {
      margin: -0.5rem;
      margin-left: auto;
      &:dir(rtl) {
        margin-left: -0.5rem;

Comment thread website/src/shared/lib/highlight.ts
Comment thread website/src/shared/lib/highlight.ts
Comment thread website/package.json
Comment thread website/src/routes/repo/raw.$.tsx Outdated
@EskiMojo14
EskiMojo14 merged commit f877967 into main Jul 16, 2026
8 of 9 checks passed
@EskiMojo14
EskiMojo14 deleted the code-improvements branch July 16, 2026 22:58
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