Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: atlassian-labs/compiled
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: @compiled/react@0.11.2
Choose a base ref
...
head repository: atlassian-labs/compiled
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: @compiled/react@0.11.3
Choose a head ref
Loading
Showing with 2,310 additions and 2,130 deletions.
  1. +1 −0 .eslintrc.js
  2. +3 −3 .github/workflows/build.yml
  3. +1 −1 .github/workflows/release.yml
  4. +4 −3 .github/workflows/test.yml
  5. +4 −4 .github/workflows/visual-regression-test.yml
  6. +1 −1 .nvmrc
  7. +8 −0 examples/ssr/CHANGELOG.md
  8. +6 −6 examples/ssr/package.json
  9. +8 −0 fixtures/babel-component/CHANGELOG.md
  10. +5 −5 fixtures/babel-component/package.json
  11. +30 −30 package.json
  12. +9 −0 packages/babel-plugin-strip-runtime/CHANGELOG.md
  13. +9 −9 packages/babel-plugin-strip-runtime/package.json
  14. +0 −6 packages/babel-plugin-strip-runtime/src/__tests__/strip-runtime-source-code.test.ts
  15. +0 −2 packages/babel-plugin-strip-runtime/src/__tests__/strip-runtime-transpiled-code.test.ts
  16. +11 −0 packages/babel-plugin/CHANGELOG.md
  17. +17 −17 packages/babel-plugin/package.json
  18. +0 −2 packages/babel-plugin/src/__tests__/css-builder.test.ts
  19. +5 −5 packages/babel-plugin/src/__tests__/errors.test.ts
  20. +0 −7 packages/babel-plugin/src/__tests__/index.test.ts
  21. +0 −2 packages/babel-plugin/src/__tests__/jsx-automatic.test.ts
  22. +0 −1 packages/babel-plugin/src/__tests__/module-imports.test.ts
  23. +0 −2 packages/babel-plugin/src/__tests__/rule-hoisting.test.ts
  24. +0 −10 packages/babel-plugin/src/class-names/__tests__/behaviour.test.ts
  25. +4 −4 packages/babel-plugin/src/keyframes/__tests__/behaviour.test.ts
  26. +0 −25 packages/babel-plugin/src/keyframes/__tests__/call-expression.test.ts
  27. +0 −19 packages/babel-plugin/src/keyframes/__tests__/tagged-template-expression.test.ts
  28. +0 −3 packages/babel-plugin/src/styled/__tests__/behaviour.test.ts
  29. +1 −4 packages/babel-plugin/src/utils/ast.ts
  30. +2 −2 packages/babel-plugin/src/utils/comments.ts
  31. +1 −1 packages/babel-plugin/src/utils/object-property-to-string.ts
  32. +12 −0 packages/codemods/CHANGELOG.md
  33. +2 −2 packages/codemods/package.json
  34. +5 −1 packages/codemods/src/plugins/default.ts
  35. +3 −3 packages/codemods/src/plugins/types.ts
  36. +16 −0 packages/codemods/src/transforms/emotion-to-compiled/README.md
  37. +5 −4 packages/codemods/src/transforms/emotion-to-compiled/__tests__/transformer.test.ts
  38. +0 −13 packages/codemods/src/transforms/emotion-to-compiled/index.ts
  39. +21 −2 packages/codemods/src/transforms/styled-components-to-compiled/README.md
  40. +2 −19 .../transforms/styled-components-to-compiled/__tests__/styled-components-to-compiled-imports.test.ts
  41. +0 −8 packages/codemods/src/transforms/styled-components-to-compiled/index.ts
  42. +1 −84 packages/codemods/src/utils/add-comment.ts
  43. +18 −2 packages/codemods/src/utils/convert-to-named-import.ts
  44. +1 −1 packages/codemods/src/utils/index.ts
  45. +15 −0 packages/css/CHANGELOG.md
  46. +3 −4 packages/css/package.json
  47. +3 −2 packages/css/src/__tests__/transform.test.ts
  48. +14 −0 packages/css/src/plugins/expand-shorthands/__tests__/flex.test.ts
  49. +12 −5 packages/css/src/plugins/expand-shorthands/flex.ts
  50. +12 −0 packages/eslint-plugin/CHANGELOG.md
  51. +6 −6 packages/eslint-plugin/package.json
  52. +19 −2 packages/eslint-plugin/src/rules/no-styled-tagged-template-expression/__tests__/rule.test.ts
  53. +1 −1 packages/eslint-plugin/src/test-utils.ts
  54. +4 −3 packages/eslint-plugin/src/utils/create-no-tagged-template-expression-rule/generate.ts
  55. +1 −1 packages/jest/package.json
  56. +11 −0 packages/parcel-optimizer/CHANGELOG.md
  57. +5 −6 packages/parcel-optimizer/package.json
  58. +11 −0 packages/parcel-transformer/CHANGELOG.md
  59. +9 −9 packages/parcel-transformer/package.json
  60. +6 −0 packages/react/CHANGELOG.md
  61. +3 −3 packages/react/package.json
  62. +20 −2 packages/react/src/runtime/__tests__/ax.test.ts
  63. +2 −2 packages/react/src/runtime/ax.ts
  64. +2 −4 packages/react/src/styled/index.js.flow
  65. +2 −4 packages/react/src/styled/index.ts
  66. +7 −0 packages/utils/CHANGELOG.md
  67. +3 −2 packages/utils/package.json
  68. +1 −1 packages/utils/src/array.ts
  69. +13 −0 packages/webpack-loader/CHANGELOG.md
  70. +13 −12 packages/webpack-loader/package.json
  71. +8 −0 renovate.json
  72. +1 −1 stories/module-traversal.tsx
  73. +1 −1 stories/simple-function-mixins.tsx
  74. +1,886 −1,746 yarn.lock
1 change: 1 addition & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -50,6 +50,7 @@ module.exports = {
},
],
'no-debugger': 'error',
'react/no-unknown-property': ['error', { ignore: ['css'] }],
},
},
{
6 changes: 3 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -12,22 +12,22 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Read .nvmrc
run: echo ::set-output name=NVMRC::$(cat .nvmrc)
id: nvm

- name: Setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ steps.nvm.outputs.NVMRC }}

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -23,7 +23,7 @@ jobs:
id: nvm

- name: Setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ steps.nvm.outputs.NVMRC }}

7 changes: 4 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -17,10 +17,10 @@ jobs:
node-version: [v12.15, v16]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}

@@ -31,7 +31,7 @@ jobs:
- name: Set ignore engines
run: yarn config set ignore-engines true

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
@@ -42,6 +42,7 @@ jobs:
run: yarn

- name: Validate
if: matrix.node-version == 'v16'
run: yarn lint

- name: Run tests
8 changes: 4 additions & 4 deletions .github/workflows/visual-regression-test.yml
Original file line number Diff line number Diff line change
@@ -12,22 +12,22 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Read .nvmrc
run: echo ::set-output name=NVMRC::$(cat .nvmrc)
id: nvm

- name: Setup node
uses: actions/setup-node@v2
uses: actions/setup-node@v3
with:
node-version: ${{ steps.nvm.outputs.NVMRC }}

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
@@ -48,7 +48,7 @@ jobs:

- name: Archive screenshots
if: ${{ failure() }}
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: visual-regression-screenshots
path: .loki
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
16.13.2
16.19.0
8 changes: 8 additions & 0 deletions examples/ssr/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# @compiled/ssr-app

## 1.0.14

### Patch Changes

- 4877ec38: Bump babel versions
- Updated dependencies [acd89969]
- @compiled/react@0.11.3

## 1.0.13

### Patch Changes
12 changes: 6 additions & 6 deletions examples/ssr/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@compiled/ssr-app",
"version": "1.0.13",
"version": "1.0.14",
"private": true,
"scripts": {
"build": "razzle build",
@@ -12,20 +12,20 @@
"webpack-dev-server": "^4.7.4"
},
"dependencies": {
"@babel/helper-builder-react-jsx": "^7.16.7",
"@babel/helper-builder-react-jsx": "^7.19.0",
"@babel/helper-builder-react-jsx-experimental": "^7.12.11",
"@compiled/react": "*",
"express": "4.18.1",
"express": "4.18.2",
"react": "17.0.2",
"react-dom": "17.0.2"
},
"devDependencies": {
"babel-preset-razzle": "^4.2.17",
"babel-preset-razzle": "^4.2.18",
"html-webpack-plugin": "^5.5.0",
"mini-css-extract-plugin": "^0.9.0",
"postcss": "^8.4.14",
"razzle": "^4.2.17",
"razzle-dev-utils": "^4.2.17",
"razzle": "^4.2.18",
"razzle-dev-utils": "^4.2.18",
"webpack": "^5.71.0",
"webpack-dev-server": "^4.7.4"
}
8 changes: 8 additions & 0 deletions fixtures/babel-component/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# @compiled/babel-component-fixture

## 0.0.14

### Patch Changes

- 4877ec38: Bump babel versions
- Updated dependencies [acd89969]
- @compiled/react@0.11.3

## 0.0.13

### Patch Changes
10 changes: 5 additions & 5 deletions fixtures/babel-component/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@compiled/babel-component-fixture",
"version": "0.0.13",
"version": "0.0.14",
"private": true,
"main": "./dist/index.js",
"scripts": {
@@ -10,10 +10,10 @@
"@compiled/react": "*"
},
"devDependencies": {
"@babel/cli": "^7.17.10",
"@babel/core": "^7.17.10",
"@babel/preset-env": "^7.17.10",
"@babel/preset-react": "^7.16.7",
"@babel/cli": "^7.20.7",
"@babel/core": "^7.20.12",
"@babel/preset-env": "^7.20.2",
"@babel/preset-react": "^7.18.6",
"@compiled/babel-plugin": "*"
},
"peerDependencies": {
60 changes: 30 additions & 30 deletions package.json
Original file line number Diff line number Diff line change
@@ -56,66 +56,66 @@
}
},
"resolutions": {
"@babel/core": "^7.17.10",
"@babel/core": "^7.20.12",
"css-what": "^5.1.0",
"jest": "^26.6.3",
"mini-css-extract-plugin": "^1.6.2",
"nth-check": "^2.0.1",
"nth-check": "^2.1.1",
"react": "^17.0.2",
"typescript": "^4.7.4",
"typescript": "^4.9.4",
"unset-value": "^2.0.1",
"webpack-dev-server": "^4.7.4"
},
"devDependencies": {
"@babel/preset-env": "^7.17.10",
"@babel/preset-react": "^7.16.7",
"@babel/preset-typescript": "^7.16.7",
"@changesets/cli": "^2.25.2",
"@babel/preset-env": "^7.20.2",
"@babel/preset-react": "^7.18.6",
"@babel/preset-typescript": "^7.18.6",
"@changesets/cli": "^2.26.0",
"@compiled-private/module-a": "*",
"@compiled/babel-plugin": "*",
"@compiled/jest": "*",
"@compiled/react": "*",
"@size-limit/preset-big-lib": "^7.0.8",
"@size-limit/preset-big-lib": "^8.1.2",
"@storybook/addons": "^6.4.20",
"@storybook/builder-webpack5": "^6.4.20",
"@storybook/manager-webpack5": "^6.4.20",
"@storybook/react": "^6.4.20",
"@types/jest": "^27.5.2",
"@types/node": "^17.0.45",
"@types/react": "^17.0.48",
"@types/react-dom": "^17.0.17",
"@types/node": "^18.11.18",
"@types/react": "^17.0.52",
"@types/react-dom": "^17.0.18",
"@types/svgo": "^2.6.4",
"@typescript-eslint/eslint-plugin": "^4.33.0",
"@typescript-eslint/parser": "^4.33.0",
"@typescript-eslint/eslint-plugin": "^5.48.2",
"@typescript-eslint/parser": "^5.48.2",
"babel-loader": "^8.2.4",
"eslint": "^7.32.0",
"eslint-plugin-flowtype": "^6.1.1",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-json-files": "^1.3.0",
"eslint-plugin-react": "^7.30.0",
"eslint-plugin-react-hooks": "^4.5.0",
"eslint": "^8.32.0",
"eslint-plugin-flowtype": "^8.0.3",
"eslint-plugin-import": "^2.27.5",
"eslint-plugin-json-files": "^2.1.0",
"eslint-plugin-react": "^7.32.1",
"eslint-plugin-react-hooks": "^4.6.0",
"flow-bin": "^0.183.0",
"flowgen": "^1.20.1",
"husky": "^4.3.8",
"jest": "^26.6.3",
"jest-extended": "^0.11.5",
"jest-watch-typeahead": "^0.6.5",
"loki": "^0.30.3",
"prettier": "^2.8.1",
"jest-watch-typeahead": "^2.2.1",
"loki": "^0.31.0",
"prettier": "^2.8.3",
"pretty-quick": "^3.1.3",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"size-limit": "^7.0.8",
"size-limit": "^8.1.2",
"storybook-addon-performance": "^0.16.1",
"storybook-addon-pseudo-states": "^1.15.1",
"ts-node": "^10.8.2",
"storybook-addon-pseudo-states": "^1.15.2",
"ts-node": "^10.9.1",
"ts-transform-define": "^0.1.10",
"tsconfig-paths": "^3.14.1",
"ttypescript": "^1.5.13",
"typescript": "^4.7.4"
"tsconfig-paths": "^4.1.2",
"ttypescript": "^1.5.15",
"typescript": "^4.9.4"
},
"engines": {
"node": "^v16.13.2"
"node": "^v16.19.0"
},
"loki": {
"configurations": {
@@ -139,7 +139,7 @@
},
{
"path": "./packages/react/dist/browser/runtime.js",
"limit": "166B",
"limit": "189B",
"import": "{ ax }",
"ignore": [
"react"
9 changes: 9 additions & 0 deletions packages/babel-plugin-strip-runtime/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# @compiled/babel-plugin-strip-runtime

## 0.17.3

### Patch Changes

- 4877ec38: Bump babel versions
- Updated dependencies [e887c2b5]
- Updated dependencies [4877ec38]
- @compiled/utils@0.6.17

## 0.17.2

### Patch Changes
18 changes: 9 additions & 9 deletions packages/babel-plugin-strip-runtime/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@compiled/babel-plugin-strip-runtime",
"version": "0.17.2",
"version": "0.17.3",
"description": "A familiar and performant compile time CSS-in-JS library for React.",
"homepage": "https://compiledcssinjs.com/docs/pkg-babel-plugin-strip-runtime",
"bugs": "https://github.com/atlassian-labs/compiled/issues/new?assignees=&labels=bug&template=bug_report.md",
@@ -19,16 +19,16 @@
"src"
],
"dependencies": {
"@babel/core": "^7.17.10",
"@babel/helper-plugin-utils": "^7.16.7",
"@babel/template": "^7.16.7",
"@babel/traverse": "^7.17.10",
"@babel/types": "^7.17.10",
"@compiled/utils": "^0.6.16"
"@babel/core": "^7.20.12",
"@babel/helper-plugin-utils": "^7.20.2",
"@babel/template": "^7.20.7",
"@babel/traverse": "^7.20.12",
"@babel/types": "^7.20.7",
"@compiled/utils": "^0.6.17"
},
"devDependencies": {
"@compiled/babel-plugin": "*",
"@types/babel__core": "^7.1.19",
"prettier": "^2.8.1"
"@types/babel__core": "^7.1.20",
"prettier": "^2.8.3"
}
}
Original file line number Diff line number Diff line change
@@ -83,11 +83,9 @@ describe('babel-plugin-strip-runtime using source code', () => {

expect(actual).toMatchInlineSnapshot(`
"/* app.tsx generated by @compiled/babel-plugin v0.0.0 */
import { ax, ix } from '@compiled/react/runtime';
import { jsxs as _jsxs } from 'react/jsx-runtime';
import { jsx as _jsx } from 'react/jsx-runtime';
const Component = () =>
/*#__PURE__*/ _jsx('div', {
className: ax(['_1wyb1fwx _syaz13q2']),
@@ -145,10 +143,8 @@ describe('babel-plugin-strip-runtime using source code', () => {

expect(actual).toMatchInlineSnapshot(`
"/* app.tsx generated by @compiled/babel-plugin v0.0.0 */
import * as React from 'react';
import { ax, ix } from '@compiled/react/runtime';
const Component = () =>
/*#__PURE__*/ React.createElement(
'div',
@@ -216,7 +212,6 @@ describe('babel-plugin-strip-runtime using source code', () => {
import { ax, ix } from '@compiled/react/runtime';
import { jsxs as _jsxs } from 'react/jsx-runtime';
import { jsx as _jsx } from 'react/jsx-runtime';
const Component = () =>
_jsx('div', {
className: ax(['_1wyb1fwx _syaz13q2']),
@@ -280,7 +275,6 @@ describe('babel-plugin-strip-runtime using source code', () => {
"/* app.tsx generated by @compiled/babel-plugin v0.0.0 */
import * as React from 'react';
import { ax, ix } from '@compiled/react/runtime';
const Component = () =>
/*#__PURE__*/ React.createElement(
'div',
Loading