Skip to content

Commit a1f1756

Browse files
committed
yarn prettier-all
1 parent 1a8d2e9 commit a1f1756

File tree

1,043 files changed

+9890
-10017
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,043 files changed

+9890
-10017
lines changed

compiler/apps/playground/__tests__/e2e/page.spec.ts

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
* LICENSE file in the root directory of this source tree.
66
*/
77

8-
import { expect, test } from "@playwright/test";
9-
import { encodeStore, type Store } from "../../lib/stores";
8+
import {expect, test} from '@playwright/test';
9+
import {encodeStore, type Store} from '../../lib/stores';
1010

1111
const STORE: Store = {
1212
source: `export default function TestComponent({ x }) {
@@ -17,33 +17,33 @@ const STORE: Store = {
1717
const HASH = encodeStore(STORE);
1818

1919
function concat(data: Array<string>): string {
20-
return data.join("");
20+
return data.join('');
2121
}
2222

23-
test("editor should compile successfully", async ({ page }) => {
24-
await page.goto(`/#${HASH}`, { waitUntil: "networkidle" });
23+
test('editor should compile successfully', async ({page}) => {
24+
await page.goto(`/#${HASH}`, {waitUntil: 'networkidle'});
2525
await page.screenshot({
2626
fullPage: true,
27-
path: "test-results/00-on-networkidle.png",
27+
path: 'test-results/00-on-networkidle.png',
2828
});
2929

3030
// User input from hash compiles
3131
await page.screenshot({
3232
fullPage: true,
33-
path: "test-results/01-show-js-before.png",
33+
path: 'test-results/01-show-js-before.png',
3434
});
3535
const userInput =
36-
(await page.locator(".monaco-editor").nth(2).allInnerTexts()) ?? [];
37-
expect(concat(userInput)).toMatchSnapshot("user-input.txt");
36+
(await page.locator('.monaco-editor').nth(2).allInnerTexts()) ?? [];
37+
expect(concat(userInput)).toMatchSnapshot('user-input.txt');
3838

3939
// Reset button works
40-
page.on("dialog", (dialog) => dialog.accept());
41-
await page.getByRole("button", { name: "Reset" }).click();
40+
page.on('dialog', dialog => dialog.accept());
41+
await page.getByRole('button', {name: 'Reset'}).click();
4242
await page.screenshot({
4343
fullPage: true,
44-
path: "test-results/02-show-js-after.png",
44+
path: 'test-results/02-show-js-after.png',
4545
});
4646
const defaultInput =
47-
(await page.locator(".monaco-editor").nth(2).allInnerTexts()) ?? [];
48-
expect(concat(defaultInput)).toMatchSnapshot("default-input.txt");
47+
(await page.locator('.monaco-editor').nth(2).allInnerTexts()) ?? [];
48+
expect(concat(defaultInput)).toMatchSnapshot('default-input.txt');
4949
});

compiler/apps/playground/app/index.tsx

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,25 +5,24 @@
55
* LICENSE file in the root directory of this source tree.
66
*/
77

8-
import type { NextPage } from "next";
9-
import Head from "next/head";
10-
import { SnackbarProvider } from "notistack";
11-
import { Editor, Header, StoreProvider } from "../components";
12-
import MessageSnackbar from "../components/Message";
8+
import type {NextPage} from 'next';
9+
import Head from 'next/head';
10+
import {SnackbarProvider} from 'notistack';
11+
import {Editor, Header, StoreProvider} from '../components';
12+
import MessageSnackbar from '../components/Message';
1313

1414
const Home: NextPage = () => {
1515
return (
1616
<div className="flex flex-col w-screen h-screen font-light">
1717
<Head>
1818
<title>
19-
{process.env.NODE_ENV === "development"
20-
? "[DEV] React Compiler Playground"
21-
: "React Compiler Playground"}
19+
{process.env.NODE_ENV === 'development'
20+
? '[DEV] React Compiler Playground'
21+
: 'React Compiler Playground'}
2222
</title>
2323
<meta
2424
name="viewport"
25-
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"
26-
></meta>
25+
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"></meta>
2726
<link rel="icon" href="/favicon.ico" />
2827
<link rel="manifest" href="/site.webmanifest" />
2928
<link
@@ -45,8 +44,7 @@ const Home: NextPage = () => {
4544
<SnackbarProvider
4645
preventDuplicate
4746
maxSnack={10}
48-
Components={{ message: MessageSnackbar }}
49-
>
47+
Components={{message: MessageSnackbar}}>
5048
<Header />
5149
<Editor />
5250
</SnackbarProvider>

compiler/apps/playground/app/layout.tsx

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,26 +5,21 @@
55
* LICENSE file in the root directory of this source tree.
66
*/
77

8-
import "../styles/globals.css";
8+
import '../styles/globals.css';
99

10-
export default function RootLayout({
11-
children,
12-
}: {
13-
children: React.ReactNode;
14-
}) {
15-
"use no memo";
10+
export default function RootLayout({children}: {children: React.ReactNode}) {
11+
'use no memo';
1612
return (
1713
<html lang="en">
1814
<head>
1915
<title>
20-
{process.env.NODE_ENV === "development"
21-
? "[DEV] React Compiler Playground"
22-
: "React Compiler Playground"}
16+
{process.env.NODE_ENV === 'development'
17+
? '[DEV] React Compiler Playground'
18+
: 'React Compiler Playground'}
2319
</title>
2420
<meta
2521
name="viewport"
26-
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"
27-
></meta>
22+
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"></meta>
2823
<link rel="icon" href="/favicon.ico" />
2924
<link rel="manifest" href="/site.webmanifest" />
3025
<link

compiler/apps/playground/app/page.tsx

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,19 @@
55
* LICENSE file in the root directory of this source tree.
66
*/
77

8-
"use client";
8+
'use client';
99

10-
import { SnackbarProvider } from "notistack";
11-
import { Editor, Header, StoreProvider } from "../components";
12-
import MessageSnackbar from "../components/Message";
10+
import {SnackbarProvider} from 'notistack';
11+
import {Editor, Header, StoreProvider} from '../components';
12+
import MessageSnackbar from '../components/Message';
1313

1414
export default function Hoot() {
1515
return (
1616
<StoreProvider>
1717
<SnackbarProvider
1818
preventDuplicate
1919
maxSnack={10}
20-
Components={{ message: MessageSnackbar }}
21-
>
20+
Components={{message: MessageSnackbar}}>
2221
<Header />
2322
<Editor />
2423
</SnackbarProvider>

compiler/apps/playground/babel.config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@
88
module.exports = function (api) {
99
api.cache(true);
1010
return {
11-
presets: ["next/babel"],
11+
presets: ['next/babel'],
1212
plugins: [
1313
[
14-
"babel-plugin-react-compiler",
14+
'babel-plugin-react-compiler',
1515
{
16-
runtimeModule: "react-compiler-runtime",
16+
runtimeModule: 'react-compiler-runtime',
1717
},
1818
],
1919
],

compiler/apps/playground/colors.js

Lines changed: 66 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -11,86 +11,86 @@
1111

1212
module.exports = {
1313
// Text colors
14-
primary: "#23272F", // gray-90
15-
"primary-dark": "#F6F7F9", // gray-5
16-
secondary: "#404756", // gray-70
17-
"secondary-dark": "#EBECF0", // gray-10
18-
link: "#087EA4", // blue-50
19-
"link-dark": "#149ECA", // blue-40
20-
syntax: "#EBECF0", // gray-10
21-
wash: "#FFFFFF",
22-
"wash-dark": "#23272F", // gray-90
23-
card: "#F6F7F9", // gray-05
24-
"card-dark": "#343A46", // gray-80
25-
highlight: "#E6F7FF", // blue-10
26-
"highlight-dark": "rgba(88,175,223,.1)",
27-
border: "#EBECF0", // gray-10
28-
"border-dark": "#343A46", // gray-80
29-
"secondary-button": "#EBECF0", // gray-10
30-
"secondary-button-dark": "#404756", // gray-70
14+
primary: '#23272F', // gray-90
15+
'primary-dark': '#F6F7F9', // gray-5
16+
secondary: '#404756', // gray-70
17+
'secondary-dark': '#EBECF0', // gray-10
18+
link: '#087EA4', // blue-50
19+
'link-dark': '#149ECA', // blue-40
20+
syntax: '#EBECF0', // gray-10
21+
wash: '#FFFFFF',
22+
'wash-dark': '#23272F', // gray-90
23+
card: '#F6F7F9', // gray-05
24+
'card-dark': '#343A46', // gray-80
25+
highlight: '#E6F7FF', // blue-10
26+
'highlight-dark': 'rgba(88,175,223,.1)',
27+
border: '#EBECF0', // gray-10
28+
'border-dark': '#343A46', // gray-80
29+
'secondary-button': '#EBECF0', // gray-10
30+
'secondary-button-dark': '#404756', // gray-70
3131

3232
// Gray
33-
"gray-95": "#16181D",
34-
"gray-90": "#23272F",
35-
"gray-80": "#343A46",
36-
"gray-70": "#404756",
37-
"gray-60": "#4E5769",
38-
"gray-50": "#5E687E", // unused
39-
"gray-40": "#78839B",
40-
"gray-30": "#99A1B3",
41-
"gray-20": "#BCC1CD",
42-
"gray-10": "#EBECF0",
43-
"gray-5": "#F6F7F9",
33+
'gray-95': '#16181D',
34+
'gray-90': '#23272F',
35+
'gray-80': '#343A46',
36+
'gray-70': '#404756',
37+
'gray-60': '#4E5769',
38+
'gray-50': '#5E687E', // unused
39+
'gray-40': '#78839B',
40+
'gray-30': '#99A1B3',
41+
'gray-20': '#BCC1CD',
42+
'gray-10': '#EBECF0',
43+
'gray-5': '#F6F7F9',
4444

4545
// Blue
46-
"blue-60": "#045975",
47-
"blue-50": "#087EA4",
48-
"blue-40": "#149ECA", // Brand Blue
49-
"blue-30": "#58C4DC", // unused
50-
"blue-20": "#ABE2ED",
51-
"blue-10": "#E6F7FF", // todo: doesn't match illustrations
52-
"blue-5": "#E6F6FA",
46+
'blue-60': '#045975',
47+
'blue-50': '#087EA4',
48+
'blue-40': '#149ECA', // Brand Blue
49+
'blue-30': '#58C4DC', // unused
50+
'blue-20': '#ABE2ED',
51+
'blue-10': '#E6F7FF', // todo: doesn't match illustrations
52+
'blue-5': '#E6F6FA',
5353

5454
// Yellow
55-
"yellow-60": "#B65700",
56-
"yellow-50": "#C76A15",
57-
"yellow-40": "#DB7D27", // unused
58-
"yellow-30": "#FABD62", // unused
59-
"yellow-20": "#FCDEB0", // unused
60-
"yellow-10": "#FDE7C7",
61-
"yellow-5": "#FEF5E7",
55+
'yellow-60': '#B65700',
56+
'yellow-50': '#C76A15',
57+
'yellow-40': '#DB7D27', // unused
58+
'yellow-30': '#FABD62', // unused
59+
'yellow-20': '#FCDEB0', // unused
60+
'yellow-10': '#FDE7C7',
61+
'yellow-5': '#FEF5E7',
6262

6363
// Purple
64-
"purple-60": "#2B3491", // unused
65-
"purple-50": "#575FB7",
66-
"purple-40": "#6B75DB",
67-
"purple-30": "#8891EC",
68-
"purple-20": "#C3C8F5", // unused
69-
"purple-10": "#E7E9FB",
70-
"purple-5": "#F3F4FD",
64+
'purple-60': '#2B3491', // unused
65+
'purple-50': '#575FB7',
66+
'purple-40': '#6B75DB',
67+
'purple-30': '#8891EC',
68+
'purple-20': '#C3C8F5', // unused
69+
'purple-10': '#E7E9FB',
70+
'purple-5': '#F3F4FD',
7171

7272
// Green
73-
"green-60": "#2B6E62",
74-
"green-50": "#388F7F",
75-
"green-40": "#44AC99",
76-
"green-30": "#7FCCBF",
77-
"green-20": "#ABDED5",
78-
"green-10": "#E5F5F2",
79-
"green-5": "#F4FBF9",
73+
'green-60': '#2B6E62',
74+
'green-50': '#388F7F',
75+
'green-40': '#44AC99',
76+
'green-30': '#7FCCBF',
77+
'green-20': '#ABDED5',
78+
'green-10': '#E5F5F2',
79+
'green-5': '#F4FBF9',
8080

8181
// RED
82-
"red-60": "#712D28",
83-
"red-50": "#A6423A", // unused
84-
"red-40": "#C1554D",
85-
"red-30": "#D07D77",
86-
"red-20": "#E5B7B3", // unused
87-
"red-10": "#F2DBD9", // unused
88-
"red-5": "#FAF1F0",
82+
'red-60': '#712D28',
83+
'red-50': '#A6423A', // unused
84+
'red-40': '#C1554D',
85+
'red-30': '#D07D77',
86+
'red-20': '#E5B7B3', // unused
87+
'red-10': '#F2DBD9', // unused
88+
'red-5': '#FAF1F0',
8989

9090
// MISC
91-
"code-block": "#99a1b30f", // gray-30 @ 6%
92-
"gradient-blue": "#58C4DC", // Only used for the landing gradient for now.
91+
'code-block': '#99a1b30f', // gray-30 @ 6%
92+
'gradient-blue': '#58C4DC', // Only used for the landing gradient for now.
9393
github: {
94-
highlight: "#fffbdd",
94+
highlight: '#fffbdd',
9595
},
9696
};

0 commit comments

Comments
 (0)