-
Notifications
You must be signed in to change notification settings - Fork 538
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'color-token-fixes' of https://github.com/primer/react i…
…nto color-token-fixes
- Loading branch information
Showing
84 changed files
with
5,952 additions
and
9,955 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
+1.35 KB
(110%)
...eNav.test.ts-snapshots/UnderlineNav-Overflow-Template-dark-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.33 KB
(110%)
...rlineNav.test.ts-snapshots/UnderlineNav-Overflow-Template-dark-dimmed-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.23 KB
(110%)
...v.test.ts-snapshots/UnderlineNav-Overflow-Template-dark-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.3 KB
(110%)
...eNav.test.ts-snapshots/UnderlineNav-Overflow-Template-dark-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+42 Bytes
(100%)
...Nav.test.ts-snapshots/UnderlineNav-Overflow-Template-light-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.34 KB
(110%)
....test.ts-snapshots/UnderlineNav-Overflow-Template-light-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.11 KB
(110%)
...s/UnderlineNav.test.ts-snapshots/UnderlineNav-Overflow-Template-light-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.36 KB
(110%)
...Nav.test.ts-snapshots/UnderlineNav-Overflow-Template-light-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.35 KB
(110%)
...nderlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-dark-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.33 KB
(110%)
...ts/UnderlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-dark-dimmed-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+51 Bytes
(100%)
...rlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-dark-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.13 KB
(110%)
...omponents/UnderlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-dark-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.3 KB
(110%)
...nderlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-dark-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.32 KB
(110%)
...derlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-light-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.24 KB
(110%)
...lineNav.test.ts-snapshots/UnderlineNav-Repos-Page-light-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.11 KB
(110%)
...mponents/UnderlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-light-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.36 KB
(110%)
...derlineNav.test.ts-snapshots/UnderlineNav-Repos-Page-light-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.16 KB
(110%)
...ractions-dark-Hi-43cdc-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.17 KB
(110%)
...ractions-dark-Hi-a8f67-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+968 Bytes
(110%)
...neNav-UnderlineNav-Interactions-dark-Keep-selected-item-visible-vrt-3-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.13 KB
(110%)
...nderlineNav-UnderlineNav-Interactions-dark-Overflow-interaction-vrt-1-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.37 KB
(110%)
...ractions-dark-co-09dc1-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.3 KB
(110%)
...ractions-dark-co-4ae94-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1012 Bytes
(110%)
...lineNav-Interactions-dark-colorblind-Keep-selected-item-visible-vrt-3-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+1.35 KB
(110%)
...-UnderlineNav-Interactions-dark-colorblind-Overflow-interaction-vrt-1-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-1.33 KB
(92%)
...ractions-dark-di-0885b-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
-1.39 KB
(91%)
...ractions-dark-di-b98f2-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1010 Bytes
(110%)
...nderlineNav-Interactions-dark-dimmed-Keep-selected-item-visible-vrt-3-linux.png
Oops, something went wrong.
Binary file modified
BIN
-1.33 KB
(92%)
...eNav-UnderlineNav-Interactions-dark-dimmed-Overflow-interaction-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.28 KB
(110%)
...ractions-dark-hi-277e8-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.28 KB
(110%)
...ractions-dark-hi-75912-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.28 KB
(110%)
...derlineNav-Interactions-dark-high-contrast-Overflow-interaction-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.3 KB
(110%)
...ractions-dark-tr-3b2b3-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.37 KB
(110%)
...ractions-dark-tr-488ac-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1012 Bytes
(110%)
...lineNav-Interactions-dark-tritanopia-Keep-selected-item-visible-vrt-3-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.15 KB
(110%)
...ractions-light-H-38ba9-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.15 KB
(110%)
...ractions-light-H-42961-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+919 Bytes
(110%)
...eNav-UnderlineNav-Interactions-light-Keep-selected-item-visible-vrt-3-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.36 KB
(110%)
...ractions-light-c-5b01a-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.32 KB
(110%)
...ractions-light-c-617fb-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+967 Bytes
(110%)
...ineNav-Interactions-light-colorblind-Keep-selected-item-visible-vrt-3-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.36 KB
(110%)
...UnderlineNav-Interactions-light-colorblind-Overflow-interaction-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.33 KB
(110%)
...ractions-light-h-7fa44-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.24 KB
(110%)
...ractions-light-h-9f6e1-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+920 Bytes
(110%)
...Nav-Interactions-light-high-contrast-Keep-selected-item-visible-vrt-3-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.24 KB
(110%)
...erlineNav-Interactions-light-high-contrast-Overflow-interaction-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.32 KB
(110%)
...ractions-light-t-c1290-t-enough-space-to-display-all-list-items-vrt-1-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.36 KB
(110%)
...ractions-light-t-fd45e-t-enough-space-to-display-all-list-items-vrt-2-linux.png
Oops, something went wrong.
Binary file modified
BIN
+967 Bytes
(110%)
...ineNav-Interactions-light-tritanopia-Keep-selected-item-visible-vrt-3-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.32 KB
(110%)
...UnderlineNav-Interactions-light-tritanopia-Overflow-interaction-vrt-1-linux.png
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
{ | ||
"setupTasks": [ | ||
{ | ||
"name": "Install Dependencies", | ||
"command": "npm install" | ||
} | ||
], | ||
"tasks": { | ||
"build": { | ||
"name": "build", | ||
"command": "npm run build", | ||
"runAtStart": false | ||
}, | ||
"develop": { | ||
"name": "develop", | ||
"command": "npm run dev -- --port 3000", | ||
"runAtStart": true, | ||
"preview": { | ||
"port": 3000 | ||
} | ||
}, | ||
"lint": { | ||
"name": "lint", | ||
"command": "npm run lint", | ||
"runAtStart": false | ||
}, | ||
"type-check": { | ||
"name": "type-check", | ||
"command": "npm run type-check", | ||
"runAtStart": false | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
'use strict' | ||
|
||
module.exports = { | ||
env: {browser: true, es2020: true}, | ||
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'plugin:react-hooks/recommended'], | ||
ignorePatterns: ['dist', '.eslintrc.cjs'], | ||
parser: '@typescript-eslint/parser', | ||
plugins: ['react-refresh'], | ||
rules: { | ||
'react-refresh/only-export-components': ['warn', {allowConstantExport: true}], | ||
}, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
lerna-debug.log* | ||
|
||
node_modules | ||
dist | ||
dist-ssr | ||
*.local | ||
|
||
# Editor directories and files | ||
.vscode/* | ||
!.vscode/extensions.json | ||
.idea | ||
.DS_Store | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# React + TypeScript + Vite | ||
|
||
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules. | ||
|
||
Currently, two official plugins are available: | ||
|
||
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh | ||
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh | ||
|
||
## Expanding the ESLint configuration | ||
|
||
If you are developing a production application, we recommend updating the configuration to enable type aware lint rules: | ||
|
||
- Configure the top-level `parserOptions` property like this: | ||
|
||
```js | ||
export default { | ||
// other rules... | ||
parserOptions: { | ||
ecmaVersion: 'latest', | ||
sourceType: 'module', | ||
project: ['./tsconfig.json', './tsconfig.node.json'], | ||
tsconfigRootDir: __dirname, | ||
}, | ||
} | ||
``` | ||
|
||
- Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked` | ||
- Optionally add `plugin:@typescript-eslint/stylistic-type-checked` | ||
- Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link rel="icon" type="image/svg+xml" href="/vite.svg" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Vite + React + TS</title> | ||
</head> | ||
<body> | ||
<div id="root"></div> | ||
<script type="module" src="/src/main.tsx"></script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
{ | ||
"name": "codesandbox", | ||
"private": true, | ||
"version": "0.0.0", | ||
"type": "module", | ||
"scripts": { | ||
"dev": "vite", | ||
"build": "tsc && vite build", | ||
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", | ||
"preview": "vite preview", | ||
"type-check": "tsc --noEmit" | ||
}, | ||
"dependencies": { | ||
"react": "^18.2.0", | ||
"react-dom": "^18.2.0" | ||
}, | ||
"devDependencies": { | ||
"@types/react": "^18.2.55", | ||
"@types/react-dom": "^18.2.19", | ||
"@typescript-eslint/eslint-plugin": "^6.21.0", | ||
"@typescript-eslint/parser": "^6.21.0", | ||
"@vitejs/plugin-react": "^4.2.1", | ||
"@primer/react": "36.x", | ||
"eslint": "^8.56.0", | ||
"eslint-plugin-react-hooks": "^4.6.0", | ||
"eslint-plugin-react-refresh": "^0.4.5", | ||
"styled-components": "5.x", | ||
"typescript": "^5.2.2", | ||
"vite": "^5.1.0" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import {Button} from '@primer/react' | ||
|
||
function App() { | ||
return <Button>Hello</Button> | ||
} | ||
|
||
export default App |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import {BaseStyles, ThemeProvider} from '@primer/react' | ||
import React from 'react' | ||
import ReactDOM from 'react-dom/client' | ||
import App from './App.tsx' | ||
import './index.css' | ||
|
||
ReactDOM.createRoot(document.getElementById('root')!).render( | ||
<React.StrictMode> | ||
<ThemeProvider> | ||
<BaseStyles> | ||
<App /> | ||
</BaseStyles> | ||
</ThemeProvider> | ||
</React.StrictMode>, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/// <reference types="vite/client" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"compilerOptions": { | ||
"target": "ES2020", | ||
"useDefineForClassFields": true, | ||
"lib": ["ES2020", "DOM", "DOM.Iterable"], | ||
"module": "ESNext", | ||
"skipLibCheck": true, | ||
|
||
/* Bundler mode */ | ||
"moduleResolution": "bundler", | ||
"allowImportingTsExtensions": true, | ||
"resolveJsonModule": true, | ||
"isolatedModules": true, | ||
"noEmit": true, | ||
"jsx": "react-jsx", | ||
|
||
/* Linting */ | ||
"strict": true, | ||
"noUnusedLocals": true, | ||
"noUnusedParameters": true, | ||
"noFallthroughCasesInSwitch": true | ||
}, | ||
"include": ["src"], | ||
"references": [{ "path": "./tsconfig.node.json" }] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"compilerOptions": { | ||
"composite": true, | ||
"skipLibCheck": true, | ||
"module": "ESNext", | ||
"moduleResolution": "bundler", | ||
"allowSyntheticDefaultImports": true, | ||
"strict": true | ||
}, | ||
"include": ["vite.config.ts"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import {defineConfig} from 'vite' | ||
import react from '@vitejs/plugin-react' | ||
|
||
// https://vitejs.dev/config/ | ||
export default defineConfig({ | ||
plugins: [react()], | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.