Skip to content

Commit

Permalink
Merge branch 'main' into css_modules_remove_feature_flag_text
Browse files Browse the repository at this point in the history
  • Loading branch information
jonrohan authored Oct 15, 2024
2 parents aadd4cd + 2742ee5 commit 25f2627
Show file tree
Hide file tree
Showing 122 changed files with 3,065 additions and 2,095 deletions.
5 changes: 5 additions & 0 deletions .changeset/angry-brooms-knock.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

Added className prop to the AvatarStack component
5 changes: 5 additions & 0 deletions .changeset/angry-pants-brush.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

Add `className` prop to `FormControl.Label` component
5 changes: 0 additions & 5 deletions .changeset/breezy-windows-speak.md

This file was deleted.

5 changes: 5 additions & 0 deletions .changeset/eight-avocados-lick.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/react": minor
---

Tooltip: Do not export all types publicly in the experimental bundle
5 changes: 5 additions & 0 deletions .changeset/five-seas-scream.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/react": patch
---

Move CSS modules feature flag from staff to ga for Avatar component
5 changes: 5 additions & 0 deletions .changeset/khaki-dolls-reflect.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

Promote Dialog, Tooltip, and Stack from `@primer/react/experimental` to `@primer/react`
5 changes: 5 additions & 0 deletions .changeset/large-glasses-provide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/react": patch
---

Add focus styles to Pagination component
5 changes: 5 additions & 0 deletions .changeset/lucky-lamps-invite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

Add `classname` prop support to `ActionList.Description` component
5 changes: 5 additions & 0 deletions .changeset/modern-cooks-invite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/react": patch
---

fix(Banner): rewrite PrimaryAction & SecondaryAction types
5 changes: 5 additions & 0 deletions .changeset/perfect-fishes-camp.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/react": patch
---

fix(TooltipV2): always add aria-hidden
14 changes: 14 additions & 0 deletions .changeset/pre.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,19 @@
"cool-lobsters-nail",
"curvy-goats-sell",
"dirty-pianos-wash",
"dry-pens-pay",
"dry-trainers-protect",
"dull-beans-dance",
"dull-dolphins-bake",
"dull-mirrors-dream",
"dull-turkeys-cheer",
"early-lions-vanish",
"eight-avocados-lick",
"eighty-houses-beg",
"eleven-drinks-kiss",
"fifty-foxes-drop",
"fifty-rockets-joke",
"five-seas-scream",
"flat-avocados-cheer",
"flat-weeks-battle",
"fluffy-ravens-thank",
Expand All @@ -48,13 +52,17 @@
"happy-fireants-mate",
"honest-ligers-fly",
"hot-baboons-allow",
"khaki-dolls-reflect",
"large-glasses-provide",
"large-plants-unite",
"lemon-candles-deny",
"light-chefs-bow",
"little-bats-approve",
"long-pans-travel",
"lovely-days-march",
"lucky-oranges-camp",
"mighty-parrots-carry",
"modern-cooks-invite",
"moody-rivers-impress",
"nervous-llamas-ring",
"new-shirts-beam",
Expand All @@ -63,6 +71,7 @@
"olive-donkeys-exercise",
"orange-steaks-do",
"pink-actors-cross",
"plenty-books-agree",
"purple-apricots-relax",
"quick-adults-buy",
"quick-feet-sip",
Expand All @@ -73,8 +82,10 @@
"serious-terms-sniff",
"seven-scissors-explain",
"short-boats-cover",
"silent-fireants-kneel",
"silent-planes-grab",
"silly-weeks-clap",
"silver-cheetahs-compare",
"six-owls-walk",
"sixty-olives-glow",
"slow-walls-drum",
Expand All @@ -87,6 +98,7 @@
"stale-lizards-report",
"stale-pets-tan",
"strong-tables-rest",
"stupid-monkeys-beg",
"tall-wasps-end",
"tame-boats-hide",
"ten-gifts-own",
Expand All @@ -98,11 +110,13 @@
"three-scissors-hide",
"tidy-bats-warn",
"tidy-clocks-marry",
"tidy-impalas-remain",
"tough-pans-punch",
"twelve-tables-leave",
"twenty-spoons-give",
"weak-hats-type",
"weak-ravens-greet",
"wet-apples-hide",
"wet-otters-pull",
"wicked-books-occur",
"yellow-tools-call",
Expand Down
5 changes: 5 additions & 0 deletions .changeset/real-seahorses-grab.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

Add ButtonBase to `@primer/react/experimental` to help with wildcard import interop
5 changes: 5 additions & 0 deletions .changeset/selfish-garlics-approve.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

[SelectPanel] Implement loading states
5 changes: 5 additions & 0 deletions .changeset/shiny-otters-call.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

[SegmentedControl, Autocomplete] Support passing React.ReactElements for icons.
5 changes: 5 additions & 0 deletions .changeset/silver-cheetahs-compare.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/react": patch
---

Bug fix for `IconButton` to respect the `style` prop width when the feature flag is on.
5 changes: 5 additions & 0 deletions .changeset/spicy-pants-breathe.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': patch
---

Update CSS styles for CounterLabel to allow overrides for color, background color
5 changes: 5 additions & 0 deletions .changeset/stupid-monkeys-beg.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/react": patch
---

SelectPanel: Fix items not being selected when defined within scope (track selection by item.id)
5 changes: 5 additions & 0 deletions .changeset/thin-keys-move.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': minor
---

Add 'className' prop to `Dialog` component
11 changes: 1 addition & 10 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,7 @@ updates:
directory: '/'
schedule:
interval: 'weekly'
labels:
- 'dependencies'
- 'skip changeset'

- package-ecosystem: 'npm'
directory: '/docs'
schedule:
interval: 'weekly'
allow:
- dependency-name: '@primer/gatsby-theme-doctocat'
versioning-strategy: increase
labels:
- 'dependencies'
- 'skip changeset'
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ jobs:
run: npm run build -ws --if-present

vrt-runner:
runs-on: ubuntu-latest-8-cores
runs-on: ubuntu-latest-16-cores
strategy:
fail-fast: false
matrix:
Expand All @@ -133,7 +133,7 @@ jobs:
echo "pid=$pid" >> $GITHUB_OUTPUT
sleep 5
- name: Run VRT
uses: docker://mcr.microsoft.com/playwright:v1.43.0-jammy
uses: docker://mcr.microsoft.com/playwright:v1.47.2-jammy
env:
STORYBOOK_URL: 'http://172.17.0.1:6006'
with:
Expand Down Expand Up @@ -180,7 +180,7 @@ jobs:
run: exit 1

vrt-runner-all-flags:
runs-on: ubuntu-latest-8-cores
runs-on: ubuntu-latest-16-cores
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -211,7 +211,7 @@ jobs:
echo "pid=$pid" >> $GITHUB_OUTPUT
sleep 5
- name: Run VRT
uses: docker://mcr.microsoft.com/playwright:v1.43.0-jammy
uses: docker://mcr.microsoft.com/playwright:v1.47.2-jammy
env:
STORYBOOK_URL: 'http://172.17.0.1:6006'
with:
Expand Down Expand Up @@ -253,12 +253,12 @@ jobs:
with:
name: vrt-all-flags
path: playwright-report
- name: check vrt-runner job status
if: ${{ needs.vrt-runner.result == 'failure' }}
- name: check vrt-runner-all-flags job status
if: ${{ needs.vrt-runner-all-flags.result == 'failure' }}
run: exit 1

aat-runner:
runs-on: ubuntu-latest-8-cores
runs-on: ubuntu-latest-16-cores
strategy:
fail-fast: false
matrix:
Expand All @@ -285,7 +285,7 @@ jobs:
echo "pid=$pid" >> $GITHUB_OUTPUT
sleep 5
- name: Run AAT
uses: docker://mcr.microsoft.com/playwright:v1.43.0-jammy
uses: docker://mcr.microsoft.com/playwright:v1.47.2-jammy
env:
STORYBOOK_URL: 'http://172.17.0.1:6006'
with:
Expand Down Expand Up @@ -332,7 +332,7 @@ jobs:
run: exit 1

aat-runner-all-flags:
runs-on: ubuntu-latest-8-cores
runs-on: ubuntu-latest-16-cores
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -363,7 +363,7 @@ jobs:
echo "pid=$pid" >> $GITHUB_OUTPUT
sleep 5
- name: Run AAT
uses: docker://mcr.microsoft.com/playwright:v1.43.0-jammy
uses: docker://mcr.microsoft.com/playwright:v1.47.2-jammy
env:
STORYBOOK_URL: 'http://172.17.0.1:6006'
with:
Expand Down Expand Up @@ -405,8 +405,8 @@ jobs:
with:
name: axe-all-flags
path: playwright-report
- name: Check aat-runner job status
if: ${{ needs.aat-runner.result == 'failure' }}
- name: Check aat-runner-all-flags job status
if: ${{ needs.aat-runner-all-flags.result == 'failure' }}
run: exit 1

build-components-json:
Expand Down
74 changes: 74 additions & 0 deletions .github/workflows/recommend-integration-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
name: Recommend integration tests
on:
pull_request:

jobs:
recommend:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22

- name: Get source files changes
id: source-files
run: |
DIFF=$(git diff --name-only origin/main | grep 'packages/react' | grep -Ev '.stories.tsx|.docs.json' || true)
if [ -z "$DIFF" ]; then
echo "diff=" >> $GITHUB_OUTPUT
else
echo "diff=true" >> $GITHUB_OUTPUT
fi
- name: Has diff?
run: echo ${{ steps.source-files.outputs.diff != '' }}

- name: Get or Create Comment
if: ${{ steps.source-files.outputs.diff != '' }}
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const result = await github.paginate(github.rest.issues.listComments, {
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo
});
const previousComment = result.filter(c => c.user.login == 'github-actions[bot]' && c.body.startsWith('<!-- recommend-integration-tests.yml -->'))
if (!previousComment.length) {
await github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '<!-- recommend-integration-tests.yml -->\n\n :wave: Hi, this pull request contains changes to the source code that github/github depends on. If you are GitHub staff, we recommend testing these changes with github/github using the [integration workflow](https://gh.io/testing_primer_at_dotcom). Thanks!'
})
}
- name: Add label
if: ${{ steps.source-files.outputs.diff != '' }}
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const result = await github.rest.issues.listLabelsOnIssue({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
})
const integrationLabels = result.data.filter(label => label.name.startsWith('integration-tests'))
if (!integrationLabels.length) {
await github.rest.issues.addLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
labels: ['integration-tests: recommended'],
})
}
2 changes: 1 addition & 1 deletion .github/workflows/vrt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
echo "pid=$pid" >> $GITHUB_OUTPUT
sleep 5
- name: Run VRT
uses: docker://mcr.microsoft.com/playwright:v1.43.0-jammy
uses: docker://mcr.microsoft.com/playwright:v1.47.2-jammy
env:
STORYBOOK_URL: 'http://172.17.0.1:6006'
with:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,6 @@ blob-report

# TypeScript
*.tsbuildinfo

# ESLint
.eslintcache
7 changes: 7 additions & 0 deletions .husky/install.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
// Skip Husky install in production and CI
// @see https://typicode.github.io/husky/how-to.html#ci-server-and-docker
if (process.env.NODE_ENV === 'production' || process.env.CI === 'true') {
process.exit(0)
}
const husky = (await import('husky')).default
console.log(husky())
7 changes: 1 addition & 6 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,6 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

[ -z "$HUSKY_ENABLED" ] && exit 0

npx lint-staged
lint-staged
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 25f2627

Please sign in to comment.