Skip to content

Commit

Permalink
Merge branch 'main' into feat/zodify-config
Browse files Browse the repository at this point in the history
  • Loading branch information
chriskalmar committed Jan 14, 2024
2 parents adb076d + 2e057ab commit de7142c
Show file tree
Hide file tree
Showing 33 changed files with 724 additions and 225 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,6 @@ jobs:
- name: Build Example Storybook v6.5 with StoryStore v7
run: npm run build-example-storybook-v6.5-storystore-v7

- name: Test
run: npm run test

- name: Build
run: npm run build

- name: Build Example Pages
run: npm run build-example-next-js-pages

Expand All @@ -48,6 +42,12 @@ jobs:
- name: Build Example Vite
run: npm run build-example-vite

- name: Test
run: npm run test

- name: Build
run: npm run build

- name: Run Example Next.js Pages
run: npm run run-example-next-js-pages &

Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -110,3 +110,4 @@ dist
/.vscode/settings.json
/lostpixel.config.js
/lostpixel.config.ts
/pagesJson.json
17 changes: 11 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
| ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
| ![ezgif-5-e71eb0773d](https://user-images.githubusercontent.com/29632358/185067771-03467437-badd-466b-ad6c-60d7183d99ae.gif) | ![ezgif-5-43091ece5d](https://user-images.githubusercontent.com/29632358/185067989-3f2d818b-c01f-4304-97f6-77295b1970d9.gif) |

- **Lost Pixel Platform** - the **UI and CI helpers** that allow you to use lost-pixel's managed version. This includes specified regression UI, collaboration with team members, and an easy approval/rejection process for the snapshots. You can configure it once and enjoy hassle-free visual regression tests integrated into your GitHub actions pipeline.
- **Lost Pixel Platform** - the **UI and CI helpers** that allow you to use lost-pixel's managed version. This includes specified regression UI, collaboration with team members, and an easy approval/rejection process for the snapshots. You can configure it once and enjoy hassle-free visual regression tests integrated into your GitHub actions pipeline. `lost-pixel` repository is **core** to the SaaS offering and is being actively improved & maintained.

https://user-images.githubusercontent.com/29632358/222420960-57924da4-d0bf-4478-9322-fc68686485b6.mp4

Expand All @@ -64,6 +64,7 @@ https://user-images.githubusercontent.com/29632358/222420960-57924da4-d0bf-4478-
## Features
- 🌐 Visual regression testing in a browser of your choice (chrome, firefox, safari)
- 📱 Responsive tests running with [different breakpoints and viewports](https://docs.lost-pixel.com/user-docs/recipes/general-recipes/viewport-tests)
- 🖥️ Multiple browser execution (Chrome, Mozilla, Safari)
- 🔀 Parallel execution (limited in OSS version)
- 🎚️ Flexible sensitivity [thresholds](https://docs.lost-pixel.com/user-docs/recipes/general-recipes/thresholds)
- 🔄 Flaky test retries. [Utilities to reduce flakiness](https://docs.lost-pixel.com/user-docs/recipes/general-recipes/flakiness).
Expand Down Expand Up @@ -127,7 +128,7 @@ jobs:
run: npm run build-storybook

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
```

</details>
Expand Down Expand Up @@ -197,7 +198,7 @@ jobs:
run: npm run serve &

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
```

</details>
Expand Down Expand Up @@ -255,7 +256,7 @@ jobs:
run: npm run story:build

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
```

</details>
Expand Down Expand Up @@ -317,7 +318,7 @@ jobs:
run: npm run start &

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
```

</details>
Expand Down Expand Up @@ -397,7 +398,7 @@ jobs:
run: npx playwright install --with-deps && npm run test:e2e

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
env:
LOST_PIXEL_API_KEY: ${{ secrets.LOST_PIXEL_API_KEY }}
```
Expand Down Expand Up @@ -451,3 +452,7 @@ If you are already using Lost Pixel it would mean a lot to us if you give us a s
## Contributing 🏗️

**Lost Pixel** is open source in it's heart and welcomes any external contribution. You can refer to [CONTRIBUTING.md](https://github.com/lost-pixel/lost-pixel/blob/main/CONTRIBUTING.md) to get going with the project locally in couple of minutes.

## Lost Pixel Usage Insights 📈

[![lost-pixel npminsights](https://npminsights.vercel.app/api/package/readme-image/lost-pixel)](https://npminsights.vercel.app/package/lost-pixel)
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ inputs:
required: false
runs:
using: 'docker'
image: 'docker://lostpixel/lost-pixel:v3.8.2'
image: 'docker://lostpixel/lost-pixel:v3.11.0'
# for branch testing
# image: 'Dockerfile'
5 changes: 3 additions & 2 deletions docs/api-reference/lost-pixel.config.js-or-ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ description: >-

#### Options

* **browser**: `'chromium' | 'firefox' | 'webkit'`
* **browser**: `'chromium' | 'firefox' | 'webkit' | Array<'chromium' | 'firefox' | 'webkit'>`
* **Required**
* Defaults to `'chromium'`
* Browser to use when doing the screenshots: **chromium**, **firefox**, or **webkit**
* This option specifies which browser(s) will be used for capturing screenshots.
* Accepted values are **chromium**, **firefox**, and **webkit**, which can be used individually or as an array for multiple browsers.
* **lostPixelPlatform**: `string`
* **Required**
* Defaults to `'https://api.lost-pixel.com'` if not provided
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/getting-started/getting-started-2.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ coverY: 0
run: npm run serve &#x26;

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
</code></pre>

4. _(Optional)_ Add [automatic PR for easy baseline update](../../recipes/lost-pixel-oss/automatic-baseline-update-pr.md)
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/getting-started/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ coverY: 0
run: npm run serve &
- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
```

{% endcode %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:

- name: Lost Pixel
id: lp
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
env:
LOST_PIXEL_MODE: update
- name: Create Pull Request
Expand Down
4 changes: 2 additions & 2 deletions docs/recipes/lost-pixel-platform/monorepo.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
CI: true

- name: ${{ matrix.config.name }}
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
env:
LOST_PIXEL_API_KEY: ${{ secrets.LOST_PIXEL_API_KEY }}
LOST_PIXEL_CONFIG_DIR: ${{ matrix.config.package }}
Expand All @@ -83,7 +83,7 @@ jobs:
uses: actions/checkout@v2

- name: Lost Pixel Finalize
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
env:
LOST_PIXEL_API_KEY: ${{ secrets.LOST_PIXEL_API_KEY }}
LOST_PIXEL_CONFIG_DIR: apps/web
Expand Down
6 changes: 3 additions & 3 deletions docs/setup/integrating-with-github-actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Lost Pixel has first-class support for GitHub Actions, offering a dedicated acti

```
- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
```

As outlined in [modes](project-configuration/modes.md), Lost Pixel can run in different modes or all of them simultaneously. You would need to build the respective provider and serve it in the action to make it available for the Lost Pixel, e.g. build & serve storybook, build & serve ladle, build & serve next app
Expand Down Expand Up @@ -36,7 +36,7 @@ jobs:
run: npm run build-storybook

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
```
{% endcode %}

Expand All @@ -47,7 +47,7 @@ Using Lost Pixel in **Platform Mode,** you need to provide the `LOST_PIXEL_API_K

```
- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
env:
LOST_PIXEL_API_KEY: ${{ secrets.LOST_PIXEL_API_KEY }}
```
Expand Down
2 changes: 1 addition & 1 deletion examples/example-storybook-v6.4/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ jobs:
run: npm run build-storybook

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
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.
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,17 @@ Primary.args = {
label: 'Button',
};
Primary.parameters = {
lostpixel:{
breakpoints: [420, 1000]
}}
lostpixel: {
breakpoints: [420, 1000],
extraShots: [
{ suffix: 'with XXX label', args: { label: 'XXX' } },
{
suffix: 'with MMM label & red',
args: { label: 'MMM', backgroundColor: 'red', primary: false },
},
],
},
};

export const Secondary = Template.bind({});
Secondary.args = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ jobs:
run: npm run build-storybook

- name: Lost Pixel
uses: lost-pixel/lost-pixel@v3.8.2
uses: lost-pixel/lost-pixel@v3.11.0
2 changes: 2 additions & 0 deletions examples/example-swyxkit/lostpixel.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ import { CustomProjectConfig } from 'lost-pixel';
export const config: CustomProjectConfig = {
histoireShots:{
histoireUrl: './.histoire/dist',

},
threshold:0.04,
generateOnly: true,
failOnDifference: true,
};
69 changes: 67 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit de7142c

Please sign in to comment.