Skip to content

Sync Primer view_components upstream through v0.51.6 - #499

Closed
myabc wants to merge 12 commits into
mainfrom
bump/primer-upstream
Closed

Sync Primer view_components upstream through v0.51.6#499
myabc wants to merge 12 commits into
mainfrom
bump/primer-upstream

Conversation

@myabc

@myabc myabc commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Merges upstream primer/view_components through 6733f3c (the commit right before "Release Tracking (Release Tracking primer/view_components#4098)"), reaching upstream package version 0.51.6
  • Only conflict was package.json: kept the fork's name/version/repository, gained upstream's new exports field (classnames subpath export)
  • Replayed the nokogiri security bump (1.19.2 → 1.19.4) in root and demo Gemfile.lock, which merge=ours would otherwise have silently dropped; left other minor patch bumps (bootsnap, css_parser, msgpack, erb, irb) to the weekly Dependabot cycle
  • view_component stays pinned at 4.9.0 in demo/Gemfile (manifest constraint, not a lockfile-only bump)
  • Ports PR-title guidance from the octicons fork's mirrored syncing-primer-fork skill (title by upstream version, not the merge SHA)

Test plan

  • CI green (lint, unit tests, static:dump)
  • Review new exports field in package.json doesn't break existing consumers

primer Bot and others added 6 commits June 16, 2026 15:55
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
…lector lists (primer#4095)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
# Conflicts:
#	package-lock.json
#	package.json
Adds a step for referencing the upstream package version (read
from package.json at TARGET) in PR titles instead of the raw
merge SHA, which tells reviewers nothing on its own. Ports the
change from the octicons fork's mirrored skill.
Copilot AI review requested due to automatic review settings July 17, 2026 13:01
@changeset-bot

changeset-bot Bot commented Jul 17, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 907b27e

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@openproject/primer-view-components Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

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

Syncs this fork with upstream primer/view_components through upstream package version 0.51.6, while carrying fork-specific conflict resolutions and adding a new published JS subpath export for CSS class name tooling.

Changes:

  • Add a new @openproject/primer-view-components/classnames subpath export backed by generated static/classnames.*.
  • Improve CSS style-recalc performance by removing universal-subject selectors and expanding merged selector lists in several component styles.
  • Replay a security bump for nokogiri in both root and demo lockfiles and extend internal sync guidance docs.

Reviewed changes

Copilot reviewed 13 out of 16 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
static/classnames.js Adds ESM default export of a generated Set of CSS class names.
static/classnames.d.ts Adds TypeScript typings for the classnames export.
static/classnames.cjs Adds CommonJS build of the generated class name Set.
static/classes.json Updates generated class-to-component mapping (new Popover caret variants, DataTable classes).
script/export-css-selectors Enhances static export generation to emit classnames.* and collect class names across folders.
package.json Adds exports field (including ./classnames) and includes new static artifacts in published files list.
Gemfile.lock Replays nokogiri security bump to 1.19.4.
demo/Gemfile.lock Replays nokogiri security bump to 1.19.4 for the demo app.
app/components/primer/beta/popover.pcss Refactors caret selectors for better style-recalc performance; adds a stylelint suppression.
app/components/primer/beta/breadcrumbs.pcss Refactors selectors to avoid merged :is(...) slow-path selector matching.
app/components/primer/alpha/text_field.pcss Adds stylelint scoping rule suppression around mixin; refactors selectors for performance.
app/components/primer/alpha/auto_complete.pcss Removes universal descendant color override for hover/selected states to reduce slow selector matching.
.devcontainer/Dockerfile Removes Yarn apt source to avoid apt GPG verification failures.
.claude/skills/syncing-primer-fork/SKILL.md Adds PR title guidance (prefer upstream version over merge SHA).
.changeset/fast-pumas-juggle.md Adds changeset entry for CSS selector performance improvements.
.changeset/classnames-export.md Adds changeset entry for the new classnames subpath export.

Comment thread script/export-css-selectors
Comment thread package.json
Comment thread .changeset/classnames-export.md
@github-actions

Copy link
Copy Markdown

⚠️ Visual or ARIA snapshot differences found

Our visual and ARIA snapshot tests found UI differences. Please review the differences by viewing the files changed tab to ensure that the changes were intentional.

Review differences

myabc and others added 3 commits July 21, 2026 15:43
Extends the include glob so nested component sources (alpha/,
beta/, open_project/) are matched, and excludes generated .d.ts
files that would otherwise conflict with their sources.

Fixes the Vite dev server in the demo app: its per-file tsconfig
resolution honours include patterns, so unmatched files were
transformed without experimentalDecorators. Catalyst @controller
decorators then reached the browser untransformed, aborting the
whole JS module graph - no custom elements were registered and
ActionMenu overlays rendered as static in-flow content.

(cherry picked from commit ba86b76)
The zizmor hardening set persist-credentials: false on the checkout,
but git-auto-commit-action pushes via the credentials checkout writes
to git config. With them off the push failed with "could not read
Username for https://github.com" and the job errored on every run.

Re-enables persistence and suppresses the artipacked rule inline; the
token is a scoped app-token (contents:write, this repo only), not the
default GITHUB_TOKEN, so the exposure zizmor guards against is limited.

(cherry picked from commit dd6de0e)
Comment thread .github/workflows/static-files.yml Dismissed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

6 participants