Skip to content

Commit

Permalink
Merge branch 'main' into remove-old-colors
Browse files Browse the repository at this point in the history
  • Loading branch information
jonrohan committed Jun 11, 2024
2 parents 0aa6eca + 035ffef commit ce0ab59
Show file tree
Hide file tree
Showing 57 changed files with 1,714 additions and 1,743 deletions.
5 changes: 0 additions & 5 deletions .changeset/angry-toys-live.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/fair-cups-lay.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/three-apples-beg.md

This file was deleted.

5 changes: 5 additions & 0 deletions .changeset/young-foxes-battle.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/css": patch
---

Upgrade to @primer/primtives@8.2.0 and @primer/stylelint-config@13.0.0-rc
4 changes: 3 additions & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
* @primer/css-reviewers
* @primer/design-reviewers
package.json @primer/design-reviewers @primer/engineer-reviewers
package-lock.json @primer/design-reviewers @primer/engineer-reviewers
12 changes: 10 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,18 @@ updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "monthly"
interval: "daily"
groups:
all:
patterns:
- "*"

# Maintain dependencies for npm
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "monthly"
interval: "daily"
groups:
all:
patterns:
- "*"
4 changes: 1 addition & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@ jobs:
- run: npm ci
- run: npm run dist
- name: Lint source files
run: npx stylelint --fix
- name: Look for unused stylelint:disable lines
run: npm run stylelint -- --report-needless-disables
run: npm run stylelint:fix
- name: Push up any fixes
if: ${{ github.event_name == 'pull_request' }}
uses: stefanzweifel/git-auto-commit-action@v5
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/deploy_preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ permissions:
jobs:
deploy:
if: ${{ github.repository == 'primer/css' }}
uses: primer/.github/.github/workflows/deploy_preview.yml@main
uses: primer/.github/.github/workflows/deploy_preview.yml@v2.1.0
name: Deploy preview
secrets:
gh_token: ${{ secrets.GITHUB_TOKEN }}
with:
node_version: 18
install: npm ci && cd docs && npm ci && cd ..
node_version: 20
install: npm i && cd docs && npm i && cd ..
build: npm run build:docs:preview
output_dir: docs/public

Expand All @@ -32,7 +32,7 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: chrnorm/[email protected].5
- uses: chrnorm/[email protected].7
name: Create GitHub deployment for storybook
id: storybook
with:
Expand All @@ -42,7 +42,7 @@ jobs:

- name: Update storybook deployment status (success)
if: success()
uses: chrnorm/[email protected].1
uses: chrnorm/[email protected].3
with:
token: ${{ secrets.GITHUB_TOKEN }}
environment-url: '${{ needs.deploy.outputs.deployment_url }}/storybook'
Expand All @@ -51,7 +51,7 @@ jobs:

- name: Update storybook deployment status (failure)
if: failure()
uses: chrnorm/[email protected].1
uses: chrnorm/[email protected].3
with:
token: ${{ secrets.GITHUB_TOKEN }}
state: 'failure'
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/deploy_production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ jobs:
if: ${{ github.repository == 'primer/css' }}
name: Production
needs: [guard]
uses: primer/.github/.github/workflows/deploy.yml@main
uses: primer/.github/.github/workflows/deploy.yml@v2.1.0
secrets:
gh_token: ${{ secrets.GITHUB_TOKEN }}
with:
node_version: 18
install: npm ci && cd docs && npm ci && cd ..
node_version: 20
install: npm i && cd docs && npm i && cd ..
build: npm run build:docs
output_dir: docs/public
2 changes: 1 addition & 1 deletion .github/workflows/release_canary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ on:
jobs:
release-canary:
name: Canary
uses: primer/.github/.github/workflows/release_canary.yml@main
uses: primer/.github/.github/workflows/release_canary.yml@v2.1.0
with:
install: npm ci
secrets:
Expand Down
19 changes: 19 additions & 0 deletions .github/workflows/release_tracking.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Release Event Tracking
# Measure a datadog event every time a release occurs

on:
pull_request:
types:
- closed
- opened
- reopened

release:
types: [published]

jobs:
release-tracking:
name: Release Tracking
uses: primer/.github/.github/workflows/[email protected]
secrets:
datadog_api_key: ${{ secrets.DATADOG_API_KEY }}
20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
# @primer/css

## 21.3.1

### Patch Changes

- [#2613](https://github.com/primer/css/pull/2613) [`2eabfde`](https://github.com/primer/css/commit/2eabfdea85667c041e86e13376f1d2823b64fcb1) Thanks [@stamat](https://github.com/stamat)! - removing !important from letter-spacing marketing typography

- [#2611](https://github.com/primer/css/pull/2611) [`e867934`](https://github.com/primer/css/commit/e8679348ca29c85b470a6b04a821d7143d4acf16) Thanks [@keithamus](https://github.com/keithamus)! - drop !important from details styling

## 21.3.0

### Minor Changes

- [#2598](https://github.com/primer/css/pull/2598) [`434fcac`](https://github.com/primer/css/commit/434fcac6c296ddd3155945420f785a6b48eb693c) Thanks [@langermank](https://github.com/langermank)! - Remove marketing icon variables

- [#2596](https://github.com/primer/css/pull/2596) [`9896c79`](https://github.com/primer/css/commit/9896c79a846cbaa633d21573be252b8e4812e79d) Thanks [@jonrohan](https://github.com/jonrohan)! - Move native color styles from the color-modes bundle to the base bundle

### Patch Changes

- [#2606](https://github.com/primer/css/pull/2606) [`a03827b`](https://github.com/primer/css/commit/a03827b0a0c76c6df8d15d04ea2ec7976799cc92) Thanks [@langermank](https://github.com/langermank)! - Cleanup old Primitive imports

## 21.2.2

### Patch Changes
Expand Down
15 changes: 6 additions & 9 deletions docs/.storybook/preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,12 @@ export const decorators = [
const {parameters} = context
const defaultStoryType = 'banner'
const storyType = parameters.storyType || defaultStoryType
document.body.setAttribute('data-color-mode', context.globals.theme.startsWith('light') ? 'light' : 'dark')
document.body.setAttribute(
'data-light-theme',
context.globals.theme.startsWith('light') ? context.globals.theme : undefined,
)
document.body.setAttribute(
'data-dark-theme',
context.globals.theme.startsWith('dark') ? context.globals.theme : undefined,
)
const colorMode = context.globals.theme === '' ? 'light' : (context.globals.theme.startsWith('light') ? 'light' : 'dark')
const lightTheme = context.globals.theme === '' ? 'light' : (colorMode === 'light' ? context.globals.theme : undefined)
const darkTheme = context.globals.theme === '' ? 'dark' : (colorMode === 'dark' ? context.globals.theme : undefined)
document.body.setAttribute('data-color-mode', colorMode)
document.body.setAttribute('data-light-theme', lightTheme)
document.body.setAttribute('data-dark-theme', darkTheme)
return (
<>
{context.globals.theme === 'all' ? (
Expand Down
Loading

0 comments on commit ce0ab59

Please sign in to comment.