Skip to content

Commit

Permalink
Merge pull request #835 from penicillin0/chore/fix-README-external-link
Browse files Browse the repository at this point in the history
chore: fix external link in the README
  • Loading branch information
Quramy authored Jan 19, 2024
2 parents 28b47af + 10f687c commit 7c22231
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ type Variants = {

### type `Viewport`

`Viewport` is compatible for [Puppeteer viewport interface](https://github.com/GoogleChrome/puppeteer/blob/master/docs/api.md#pagesetviewportviewport).
`Viewport` is compatible for [Puppeteer viewport interface](https://github.com/puppeteer/puppeteer/blob/main/docs/api/puppeteer.viewport.md).

```ts
type Viewport =
Expand All @@ -309,7 +309,7 @@ type Viewport =
};
```

**Note:** You should choose a valid [device name](https://github.com/puppeteer/puppeteer/blob/main/src/common/DeviceDescriptors.ts) if set string.
**Note:** You should choose a valid [device name](https://github.com/puppeteer/puppeteer/blob/main/packages/puppeteer-core/src/common/Device.ts) if set string.

`Viewport` values are available in `viewports` field such as:

Expand Down
2 changes: 1 addition & 1 deletion packages/storycap/src/node/capturing-browser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ export class CapturingBrowser extends StoryPreviewBrowser {
await this.page.setViewport(nextViewport);

// Setting isMobile or hasTouch properties will reload the page.
// See also https://github.com/puppeteer/puppeteer/blob/main/docs/api.md#pagesetviewportviewport
// See also https://github.com/puppeteer/puppeteer/blob/main/docs/api/puppeteer.viewport.md
const willBeReloaded =
nextViewport.isMobile !== this.viewport?.isMobile || nextViewport.hasTouch !== this.viewport?.hasTouch;
this.viewport = nextViewport;
Expand Down

0 comments on commit 7c22231

Please sign in to comment.