Compare commits

...

6 Commits

Author SHA1 Message Date
JimmFly
609766d898 refactor(core): replace history to ViewService.history (#6972)
upstream: #6966
2024-05-22 04:01:33 +00:00
renovate
3b8345ea5a chore: bump up all non-major dependencies (#6968)
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@nx/vite](https://nx.dev) ([source](https://togithub.com/nrwl/nx/tree/HEAD/packages/vite)) | [`19.0.4` -> `19.0.5`](https://renovatebot.com/diffs/npm/@nx%2fvite/19.0.4/19.0.5) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nx%2fvite/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nx%2fvite/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nx%2fvite/19.0.4/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nx%2fvite/19.0.4/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@vanilla-extract/css](https://togithub.com/vanilla-extract-css/vanilla-extract) ([source](https://togithub.com/vanilla-extract-css/vanilla-extract/tree/HEAD/packages/css)) | [`1.15.1` -> `1.15.2`](https://renovatebot.com/diffs/npm/@vanilla-extract%2fcss/1.15.1/1.15.2) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@vanilla-extract%2fcss/1.15.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@vanilla-extract%2fcss/1.15.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@vanilla-extract%2fcss/1.15.1/1.15.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@vanilla-extract%2fcss/1.15.1/1.15.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@vanilla-extract/dynamic](https://togithub.com/vanilla-extract-css/vanilla-extract) ([source](https://togithub.com/vanilla-extract-css/vanilla-extract/tree/HEAD/packages/dynamic)) | [`2.1.0` -> `2.1.1`](https://renovatebot.com/diffs/npm/@vanilla-extract%2fdynamic/2.1.0/2.1.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@vanilla-extract%2fdynamic/2.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@vanilla-extract%2fdynamic/2.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@vanilla-extract%2fdynamic/2.1.0/2.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@vanilla-extract%2fdynamic/2.1.0/2.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@vanilla-extract/vite-plugin](https://togithub.com/vanilla-extract-css/vanilla-extract) ([source](https://togithub.com/vanilla-extract-css/vanilla-extract/tree/HEAD/packages/vite-plugin)) | [`4.0.9` -> `4.0.10`](https://renovatebot.com/diffs/npm/@vanilla-extract%2fvite-plugin/4.0.9/4.0.10) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@vanilla-extract%2fvite-plugin/4.0.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@vanilla-extract%2fvite-plugin/4.0.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@vanilla-extract%2fvite-plugin/4.0.9/4.0.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@vanilla-extract%2fvite-plugin/4.0.9/4.0.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@vanilla-extract/webpack-plugin](https://togithub.com/vanilla-extract-css/vanilla-extract) ([source](https://togithub.com/vanilla-extract-css/vanilla-extract/tree/HEAD/packages/webpack-plugin)) | [`2.3.8` -> `2.3.9`](https://renovatebot.com/diffs/npm/@vanilla-extract%2fwebpack-plugin/2.3.8/2.3.9) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@vanilla-extract%2fwebpack-plugin/2.3.9?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@vanilla-extract%2fwebpack-plugin/2.3.9?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@vanilla-extract%2fwebpack-plugin/2.3.8/2.3.9?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@vanilla-extract%2fwebpack-plugin/2.3.8/2.3.9?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [glob](https://togithub.com/isaacs/node-glob) | [`10.3.15` -> `10.3.16`](https://renovatebot.com/diffs/npm/glob/10.3.15/10.3.16) | [![age](https://developer.mend.io/api/mc/badges/age/npm/glob/10.3.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/glob/10.3.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/glob/10.3.15/10.3.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/glob/10.3.15/10.3.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [jotai](https://togithub.com/pmndrs/jotai) | [`2.8.0` -> `2.8.1`](https://renovatebot.com/diffs/npm/jotai/2.8.0/2.8.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/jotai/2.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/jotai/2.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/jotai/2.8.0/2.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/jotai/2.8.0/2.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [lint-staged](https://togithub.com/okonet/lint-staged) | [`15.2.2` -> `15.2.4`](https://renovatebot.com/diffs/npm/lint-staged/15.2.2/15.2.4) | [![age](https://developer.mend.io/api/mc/badges/age/npm/lint-staged/15.2.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/lint-staged/15.2.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/lint-staged/15.2.2/15.2.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/lint-staged/15.2.2/15.2.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [nx](https://nx.dev) ([source](https://togithub.com/nrwl/nx/tree/HEAD/packages/nx)) | [`19.0.4` -> `19.0.5`](https://renovatebot.com/diffs/npm/nx/19.0.4/19.0.5) | [![age](https://developer.mend.io/api/mc/badges/age/npm/nx/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/nx/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/nx/19.0.4/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/nx/19.0.4/19.0.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [wrangler](https://togithub.com/cloudflare/workers-sdk) ([source](https://togithub.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler)) | [`3.57.0` -> `3.57.1`](https://renovatebot.com/diffs/npm/wrangler/3.57.0/3.57.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/wrangler/3.57.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/wrangler/3.57.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/wrangler/3.57.0/3.57.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/wrangler/3.57.0/3.57.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>nrwl/nx (@&#8203;nx/vite)</summary>

### [`v19.0.5`](https://togithub.com/nrwl/nx/releases/tag/19.0.5)

[Compare Source](https://togithub.com/nrwl/nx/compare/19.0.4...19.0.5)

#### 19.0.5 (2024-05-21)

##### 🚀 Features

-   **bundling:** added support for declarations (\*.d.ts) ([#&#8203;21084](https://togithub.com/nrwl/nx/pull/21084))
-   **core:** resolve nx migrate target version against registry ([#&#8203;23450](https://togithub.com/nrwl/nx/pull/23450))
-   **core:** allow executor definition to point to another executor ([#&#8203;23576](https://togithub.com/nrwl/nx/pull/23576))
-   **graph:** change gradle and nextjs svg ([#&#8203;23201](https://togithub.com/nrwl/nx/pull/23201))

##### 🩹 Fixes

-   **angular:** libraries should not contain tslib by default [#&#8203;21023](https://togithub.com/nrwl/nx/issues/21023) ([#&#8203;23423](https://togithub.com/nrwl/nx/pull/23423), [#&#8203;21023](https://togithub.com/nrwl/nx/issues/21023))
-   **angular:** [@&#8203;angular/core](https://togithub.com/angular/core) should always be provided as a shared package [#&#8203;19121](https://togithub.com/nrwl/nx/issues/19121) ([#&#8203;23464](https://togithub.com/nrwl/nx/pull/23464), [#&#8203;19121](https://togithub.com/nrwl/nx/issues/19121))
-   **core:** do not add an ending new line when serializing a json ([#&#8203;23440](https://togithub.com/nrwl/nx/pull/23440))
-   **core:** migrate should warn if package does not exist ([#&#8203;23317](https://togithub.com/nrwl/nx/pull/23317))
-   **core:** azure ci workflow ([#&#8203;23453](https://togithub.com/nrwl/nx/pull/23453))
-   **core:** only check for `err` in `handleWorkspaceChanges` ([#&#8203;23500](https://togithub.com/nrwl/nx/pull/23500))
-   **core:** remove duplicate `js-yaml` packages ([2eaf79b65](https://togithub.com/nrwl/nx/commit/2eaf79b65))
-   **core:** fix alias package parsing and pruning for npm ([#&#8203;23474](https://togithub.com/nrwl/nx/pull/23474))
-   **core:** install packages per migration when creating commits ([#&#8203;23820](https://togithub.com/nrwl/nx/pull/23820))
-   **devkit:** combineAsyncIterable should not be blocking when error occurs [#&#8203;21393](https://togithub.com/nrwl/nx/issues/21393) ([#&#8203;23400](https://togithub.com/nrwl/nx/pull/23400), [#&#8203;21393](https://togithub.com/nrwl/nx/issues/21393))
-   **graph:** reload graph app only when hash changes in watch mode ([#&#8203;23434](https://togithub.com/nrwl/nx/pull/23434))
-   **js:** Respect loose option provided from config ([#&#8203;23406](https://togithub.com/nrwl/nx/pull/23406))
-   **js:** fix update package.json ([#&#8203;21415](https://togithub.com/nrwl/nx/pull/21415))
-   **nextjs:** additional experimental HTTPS options ([#&#8203;23334](https://togithub.com/nrwl/nx/pull/23334))
-   **node:** Docker generator should work ([#&#8203;23452](https://togithub.com/nrwl/nx/pull/23452))
-   **react:** respect unitTestRunner passed to the generator ([#&#8203;23383](https://togithub.com/nrwl/nx/pull/23383))
-   **react:** remote generator should update host's app routes ([#&#8203;23499](https://togithub.com/nrwl/nx/pull/23499))
-   **react:** applications not using plugin usage should set target defaults ([#&#8203;23582](https://togithub.com/nrwl/nx/pull/23582))
-   **react-native:** fix test-setup for react native/expo jest ([#&#8203;23314](https://togithub.com/nrwl/nx/pull/23314))
-   **release:** invalid tag for fixed groups without changes ([#&#8203;22800](https://togithub.com/nrwl/nx/pull/22800))
-   **repo:** hash proper projects when nx ([#&#8203;23506](https://togithub.com/nrwl/nx/pull/23506))
-   **testing:** handle existing jest preset file correctly ([#&#8203;23437](https://togithub.com/nrwl/nx/pull/23437))
-   **vite:** add  prop to config to ensure output dir is emptied [#&#8203;23382](https://togithub.com/nrwl/nx/issues/23382) ([#&#8203;23466](https://togithub.com/nrwl/nx/pull/23466), [#&#8203;23382](https://togithub.com/nrwl/nx/issues/23382))
-   **vue:** ootb unit testing should work with --routing [#&#8203;19921](https://togithub.com/nrwl/nx/issues/19921) ([#&#8203;23441](https://togithub.com/nrwl/nx/pull/23441), [#&#8203;19921](https://togithub.com/nrwl/nx/issues/19921))
-   **web:** Add strict mode ([#&#8203;23457](https://togithub.com/nrwl/nx/pull/23457))
-   **web:** Add strict mode" ([#&#8203;23472](https://togithub.com/nrwl/nx/pull/23472))
-   **web:** Add strict mode for [@&#8203;nx/web](https://togithub.com/nx/web) ([#&#8203;23497](https://togithub.com/nrwl/nx/pull/23497))
-   **webpack:** only add entrypoints if they are intentionally injected [#&#8203;20049](https://togithub.com/nrwl/nx/issues/20049) ([#&#8203;23444](https://togithub.com/nrwl/nx/pull/23444), [#&#8203;20049](https://togithub.com/nrwl/nx/issues/20049))

##### ❤️  Thank You

-   castleadmin [@&#8203;castleadmin](https://togithub.com/castleadmin)
-   Colum Ferry [@&#8203;Coly010](https://togithub.com/Coly010)
-   Craigory Coppola [@&#8203;AgentEnder](https://togithub.com/AgentEnder)
-   Emily Xiong [@&#8203;xiongemi](https://togithub.com/xiongemi)
-   Isaac Mann [@&#8203;isaacplmann](https://togithub.com/isaacplmann)
-   Jack Hsu [@&#8203;jaysoo](https://togithub.com/jaysoo)
-   James Henry [@&#8203;JamesHenry](https://togithub.com/JamesHenry)
-   Jason Jean [@&#8203;FrozenPandaz](https://togithub.com/FrozenPandaz)
-   Jonathan Cammisuli
-   Katerina Skroumpelou [@&#8203;mandarini](https://togithub.com/mandarini)
-   Leosvel Pérez Espinosa [@&#8203;leosvelperez](https://togithub.com/leosvelperez)
-   MaxKless [@&#8203;MaxKless](https://togithub.com/MaxKless)
-   Miroslav Jonaš [@&#8203;meeroslav](https://togithub.com/meeroslav)
-   Nicholas Cunningham [@&#8203;ndcunningham](https://togithub.com/ndcunningham)
-   Phillip Barta [@&#8203;Phillip9587](https://togithub.com/Phillip9587)
-   Younes Jaaidi

</details>

<details>
<summary>vanilla-extract-css/vanilla-extract (@&#8203;vanilla-extract/css)</summary>

### [`v1.15.2`](https://togithub.com/vanilla-extract-css/vanilla-extract/blob/HEAD/packages/css/CHANGELOG.md#1152)

[Compare Source](https://togithub.com/vanilla-extract-css/vanilla-extract/compare/@vanilla-extract/css@1.15.1...@vanilla-extract/css@1.15.2)

##### Patch Changes

-   [#&#8203;1335](https://togithub.com/vanilla-extract-css/vanilla-extract/pull/1335) [`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980) Thanks [@&#8203;askoufis](https://togithub.com/askoufis)! - Add `types` field to `package.json`

-   Updated dependencies \[[`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980)]:
    -   [@&#8203;vanilla-extract/private](https://togithub.com/vanilla-extract/private)[@&#8203;1](https://togithub.com/1).0.5

</details>

<details>
<summary>vanilla-extract-css/vanilla-extract (@&#8203;vanilla-extract/dynamic)</summary>

### [`v2.1.1`](https://togithub.com/vanilla-extract-css/vanilla-extract/blob/HEAD/packages/dynamic/CHANGELOG.md#211)

[Compare Source](https://togithub.com/vanilla-extract-css/vanilla-extract/compare/@vanilla-extract/dynamic@2.1.0...@vanilla-extract/dynamic@2.1.1)

##### Patch Changes

-   [#&#8203;1335](https://togithub.com/vanilla-extract-css/vanilla-extract/pull/1335) [`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980) Thanks [@&#8203;askoufis](https://togithub.com/askoufis)! - Add `types` field to `package.json`

-   Updated dependencies \[[`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980)]:
    -   [@&#8203;vanilla-extract/private](https://togithub.com/vanilla-extract/private)[@&#8203;1](https://togithub.com/1).0.5

</details>

<details>
<summary>vanilla-extract-css/vanilla-extract (@&#8203;vanilla-extract/vite-plugin)</summary>

### [`v4.0.10`](https://togithub.com/vanilla-extract-css/vanilla-extract/blob/HEAD/packages/vite-plugin/CHANGELOG.md#4010)

[Compare Source](https://togithub.com/vanilla-extract-css/vanilla-extract/compare/@vanilla-extract/vite-plugin@4.0.9...@vanilla-extract/vite-plugin@4.0.10)

##### Patch Changes

-   [#&#8203;1335](https://togithub.com/vanilla-extract-css/vanilla-extract/pull/1335) [`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980) Thanks [@&#8203;askoufis](https://togithub.com/askoufis)! - Add `types` field to `package.json`

-   Updated dependencies \[[`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980)]:
    -   [@&#8203;vanilla-extract/integration](https://togithub.com/vanilla-extract/integration)[@&#8203;7](https://togithub.com/7).1.5

</details>

<details>
<summary>vanilla-extract-css/vanilla-extract (@&#8203;vanilla-extract/webpack-plugin)</summary>

### [`v2.3.9`](https://togithub.com/vanilla-extract-css/vanilla-extract/blob/HEAD/packages/webpack-plugin/CHANGELOG.md#239)

[Compare Source](https://togithub.com/vanilla-extract-css/vanilla-extract/compare/@vanilla-extract/webpack-plugin@2.3.8...@vanilla-extract/webpack-plugin@2.3.9)

##### Patch Changes

-   [#&#8203;1335](https://togithub.com/vanilla-extract-css/vanilla-extract/pull/1335) [`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980) Thanks [@&#8203;askoufis](https://togithub.com/askoufis)! - Add `types` field to `package.json`

-   Updated dependencies \[[`b8a99e4980710a34692034d5da43e584edbc3d17`](b8a99e4980)]:
    -   [@&#8203;vanilla-extract/integration](https://togithub.com/vanilla-extract/integration)[@&#8203;7](https://togithub.com/7).1.5

</details>

<details>
<summary>isaacs/node-glob (glob)</summary>

### [`v10.3.16`](https://togithub.com/isaacs/node-glob/compare/v10.3.15...b27429849a6e8bc11a042811a939d02cbf5b100d)

[Compare Source](https://togithub.com/isaacs/node-glob/compare/v10.3.15...v10.3.16)

</details>

<details>
<summary>pmndrs/jotai (jotai)</summary>

### [`v2.8.1`](https://togithub.com/pmndrs/jotai/compare/v2.8.0...a4dc98502c6541a86dc3961d614f1f9767ae0c7a)

[Compare Source](https://togithub.com/pmndrs/jotai/compare/v2.8.0...v2.8.1)

</details>

<details>
<summary>okonet/lint-staged (lint-staged)</summary>

### [`v15.2.4`](https://togithub.com/okonet/lint-staged/blob/HEAD/CHANGELOG.md#1524)

[Compare Source](https://togithub.com/okonet/lint-staged/compare/v15.2.2...v15.2.4)

##### Patch Changes

-   [`4f4537a`](4f4537a75e) Thanks [@&#8203;iiroj](https://togithub.com/iiroj)! - Fix release issue with previous version; update dependencies

</details>

<details>
<summary>cloudflare/workers-sdk (wrangler)</summary>

### [`v3.57.1`](https://togithub.com/cloudflare/workers-sdk/blob/HEAD/packages/wrangler/CHANGELOG.md#3571)

[Compare Source](https://togithub.com/cloudflare/workers-sdk/compare/wrangler@3.57.0...wrangler@3.57.1)

##### Patch Changes

-   [#&#8203;5859](https://togithub.com/cloudflare/workers-sdk/pull/5859) [`f2ceb3a`](f2ceb3a5b9) Thanks [@&#8203;w-kuhn](https://togithub.com/w-kuhn)! - fix: queue consumer max_batch_timeout should accept a 0 value

-   [#&#8203;5862](https://togithub.com/cloudflare/workers-sdk/pull/5862) [`441a05f`](441a05f4df) Thanks [@&#8203;CarmenPopoviciu](https://togithub.com/CarmenPopoviciu)! - fix: `wrangler pages deploy` should fail if deployment was unsuccessful

    If a Pages project fails to deploy, `wrangler pages deploy` will log
    an error message, but exit successfully. It should instead throw a
    `FatalError`.

-   [#&#8203;5812](https://togithub.com/cloudflare/workers-sdk/pull/5812) [`d5e00e4`](d5e00e4a61) Thanks [@&#8203;thomasgauvin](https://togithub.com/thomasgauvin)! - fix: remove Hyperdrive warning for local development.

    Hyperdrive bindings are now supported when developing locally with Hyperdrive. We should update our logs to reflect this.

-   [#&#8203;5626](https://togithub.com/cloudflare/workers-sdk/pull/5626) [`a12b031`](a12b031e41) Thanks [@&#8203;RamIdeas](https://togithub.com/RamIdeas)! - chore: ignore workerd output (error: CODE_MOVED) not intended for end-user devs

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zNjMuNSIsInVwZGF0ZWRJblZlciI6IjM3LjM2OC4xMCIsInRhcmdldEJyYW5jaCI6ImNhbmFyeSIsImxhYmVscyI6WyJkZXBlbmRlbmNpZXMiXX0=-->
2024-05-22 03:44:45 +00:00
forehalo
29e7fa1371 chore(server): cleanup expired sessions (#7018) 2024-05-22 03:31:41 +00:00
Brooooooklyn
278336168f fix(web): add Promise.withResolvers polyfill (#7003)
- Fix https://github.com/toeverything/blocksuite/issues/7098
2024-05-22 01:08:18 +00:00
pengx17
96cdb041c6 fix(electron): incorrect db rows docId when doing trim (#7008) 2024-05-21 13:53:16 +00:00
renovate
f05b51ab49 chore: Lock file maintenance (#6987)
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Update | Change |
|---|---|
| lockFileMaintenance | All locks refreshed |

🔧 This Pull Request updates lock files to use the latest dependency versions.

---

### Configuration

📅 **Schedule**: Branch creation - "before 4am on Monday" (UTC), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zNjMuNSIsInVwZGF0ZWRJblZlciI6IjM3LjM2My41IiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2024-05-21 05:08:34 +00:00
12 changed files with 755 additions and 519 deletions

78
Cargo.lock generated
View File

@@ -106,9 +106,9 @@ dependencies = [
[[package]]
name = "anyhow"
version = "1.0.83"
version = "1.0.86"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "25bdb32cbbdce2b519a9cd7df3a678443100e265d5e25ca763b7572a5104f5f3"
checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da"
[[package]]
name = "arbitrary"
@@ -243,9 +243,9 @@ checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9"
[[package]]
name = "cc"
version = "1.0.97"
version = "1.0.98"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "099a5357d84c4c61eb35fc8eafa9a79a902c2f76911e5747ced4e032edd8d9b4"
checksum = "41c270e7540d725e65ac7f1b212ac8ce349719624d7bcff99f8e2e488e8cf03f"
[[package]]
name = "cfg-if"
@@ -314,9 +314,9 @@ checksum = "19d374276b40fb8bbdee95aef7c7fa6b5316ec764510eb64b8dd0e2ed0d7e7f5"
[[package]]
name = "crossbeam-channel"
version = "0.5.12"
version = "0.5.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ab3db02a9c5b5121e1e42fbdb1aeb65f5e02624cc58c43f2884c6ccac0b82f95"
checksum = "33480d6946193aa8033910124896ca395333cae7e2d1113d1fef6c3272217df2"
dependencies = [
"crossbeam-utils",
]
@@ -332,9 +332,9 @@ dependencies = [
[[package]]
name = "crossbeam-utils"
version = "0.8.19"
version = "0.8.20"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345"
checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80"
[[package]]
name = "crypto-common"
@@ -353,7 +353,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "edb49164822f3ee45b17acd4a208cfc1251410cf0cad9a833234c9890774dd9f"
dependencies = [
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -388,7 +388,7 @@ checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -417,9 +417,9 @@ checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b"
[[package]]
name = "either"
version = "1.11.0"
version = "1.12.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a47c1c47d2f5964e29c61246e81db715514cd532db6b5116a25ea3c03d6780a2"
checksum = "3dca9240753cf90908d7e4aac30f630662b02aebaa1b58a3cadabdb23385b58b"
dependencies = [
"serde",
]
@@ -858,9 +858,9 @@ dependencies = [
[[package]]
name = "libc"
version = "0.2.154"
version = "0.2.155"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ae743338b92ff9146ce83992f766a31066a91a8c84a45e0e9f21e7cf6de6d346"
checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c"
[[package]]
name = "libloading"
@@ -880,9 +880,9 @@ checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058"
[[package]]
name = "libmimalloc-sys"
version = "0.1.37"
version = "0.1.38"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "81eb4061c0582dedea1cbc7aff2240300dd6982e0239d1c99e65c1dbf4a30ba7"
checksum = "0e7bb23d733dfcc8af652a78b7bf232f0e967710d044732185e561e47c0336b6"
dependencies = [
"cc",
"libc",
@@ -901,9 +901,9 @@ dependencies = [
[[package]]
name = "linux-raw-sys"
version = "0.4.13"
version = "0.4.14"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c"
checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89"
[[package]]
name = "lock_api"
@@ -963,9 +963,9 @@ checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d"
[[package]]
name = "mimalloc"
version = "0.1.41"
version = "0.1.42"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9f41a2280ded0da56c8cf898babb86e8f10651a34adcfff190ae9a1159c6908d"
checksum = "e9186d86b79b52f4a77af65604b51225e8db1d6ee7e3f41aec1e40829c71a176"
dependencies = [
"libmimalloc-sys",
]
@@ -978,9 +978,9 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a"
[[package]]
name = "miniz_oxide"
version = "0.7.2"
version = "0.7.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7"
checksum = "87dfd01fe195c66b572b37921ad8803d010623c0aca821bea2302239d155cdae"
dependencies = [
"adler",
]
@@ -1039,7 +1039,7 @@ dependencies = [
"napi-derive-backend",
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -1054,7 +1054,7 @@ dependencies = [
"quote",
"regex",
"semver",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -1285,9 +1285,9 @@ checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de"
[[package]]
name = "proc-macro2"
version = "1.0.82"
version = "1.0.83"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b"
checksum = "0b33eb56c327dec362a9e55b3ad14f9d2f0904fb5a5b03b513ab5465399e9f43"
dependencies = [
"unicode-ident",
]
@@ -1565,7 +1565,7 @@ checksum = "6048858004bcff69094cd972ed40a32500f153bd3be9f716b2eed2e8217c4838"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -1940,9 +1940,9 @@ dependencies = [
[[package]]
name = "syn"
version = "2.0.63"
version = "2.0.65"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "bf5be731623ca1a1fb7d8be6f261a3be6d3e2337b8a1f97be944d020c8fcb704"
checksum = "d2863d96a84c6439701d7a38f9de935ec562c8832cc55d1dde0f513b52fad106"
dependencies = [
"proc-macro2",
"quote",
@@ -1969,22 +1969,22 @@ dependencies = [
[[package]]
name = "thiserror"
version = "1.0.60"
version = "1.0.61"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "579e9083ca58dd9dcf91a9923bb9054071b9ebbd800b342194c9feb0ee89fc18"
checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709"
dependencies = [
"thiserror-impl",
]
[[package]]
name = "thiserror-impl"
version = "1.0.60"
version = "1.0.61"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e2470041c06ec3ac1ab38d0356a6119054dedaea53e12fbefc0de730a1c08524"
checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -2054,7 +2054,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -2088,7 +2088,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]
@@ -2264,7 +2264,7 @@ dependencies = [
"once_cell",
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
"wasm-bindgen-shared",
]
@@ -2286,7 +2286,7 @@ checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
"wasm-bindgen-backend",
"wasm-bindgen-shared",
]
@@ -2571,7 +2571,7 @@ checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b"
dependencies = [
"proc-macro2",
"quote",
"syn 2.0.63",
"syn 2.0.65",
]
[[package]]

View File

@@ -4,6 +4,7 @@ import {
NotAcceptableException,
OnApplicationBootstrap,
} from '@nestjs/common';
import { Cron, CronExpression } from '@nestjs/schedule';
import type { User } from '@prisma/client';
import { PrismaClient } from '@prisma/client';
import type { CookieOptions, Request, Response } from 'express';
@@ -455,4 +456,23 @@ export class AuthService implements OnApplicationBootstrap {
to: email,
});
}
@Cron(CronExpression.EVERY_DAY_AT_MIDNIGHT)
async cleanExpiredSessions() {
await this.db.session.deleteMany({
where: {
expiresAt: {
lte: new Date(),
},
},
});
await this.db.userSession.deleteMany({
where: {
expiresAt: {
lte: new Date(),
},
},
});
}
}

View File

@@ -87,8 +87,8 @@ export class TokenService {
}
@Cron(CronExpression.EVERY_DAY_AT_MIDNIGHT)
cleanExpiredTokens() {
return this.db.verificationToken.deleteMany({
async cleanExpiredTokens() {
await this.db.verificationToken.deleteMany({
where: {
expiresAt: {
lte: new Date(),

View File

@@ -1,4 +1,5 @@
import type { BlockElement } from '@blocksuite/block-std';
import { ViewService } from '@affine/core/modules/workbench/services/view';
import type { BaseSelection, BlockElement } from '@blocksuite/block-std';
import type { Disposable } from '@blocksuite/global/utils';
import type {
AffineEditorContainer,
@@ -7,7 +8,7 @@ import type {
} from '@blocksuite/presets';
import type { Doc } from '@blocksuite/store';
import { Slot } from '@blocksuite/store';
import type { DocMode } from '@toeverything/infra';
import { type DocMode, useServiceOptional } from '@toeverything/infra';
import clsx from 'clsx';
import type React from 'react';
import type { RefObject } from 'react';
@@ -102,10 +103,11 @@ export const BlocksuiteEditorContainer = forwardRef<
{ page, mode, className, style, defaultSelectedBlockId, referenceRenderer },
ref
) {
const [scrolled, setScrolled] = useState(false);
const scrolledRef = useRef(false);
const rootRef = useRef<HTMLDivElement>(null);
const docRef = useRef<PageEditor>(null);
const edgelessRef = useRef<EdgelessEditor>(null);
const renderStartRef = useRef<number>(Date.now());
const slots: BlocksuiteEditorContainerRef['slots'] = useMemo(() => {
return {
@@ -208,39 +210,18 @@ export const BlocksuiteEditorContainer = forwardRef<
}, [affineEditorContainerProxy, ref]);
const blockElement = useBlockElementById(rootRef, defaultSelectedBlockId);
const currentView = useServiceOptional(ViewService)?.view;
useEffect(() => {
let disposable: Disposable | undefined = undefined;
// update the hash when the block is selected
const handleUpdateComplete = () => {
const selectManager = affineEditorContainerProxy?.host?.selection;
if (!selectManager) return;
disposable = selectManager.slots.changed.on(() => {
const selectedBlock = selectManager.find('block');
const selectedId = selectedBlock?.blockId;
const newHash = selectedId ? `#${selectedId}` : '';
//TODO: use activeView.history which is in workbench instead of history.replaceState
history.replaceState(null, '', `${window.location.pathname}${newHash}`);
// Dispatch a custom event to notify the hash change
const hashChangeEvent = new CustomEvent('hashchange-custom', {
detail: { hash: newHash },
});
window.dispatchEvent(hashChangeEvent);
});
};
// scroll to the block element when the block id is provided and the page is first loaded
let canceled = false;
const handleScrollToBlock = (blockElement: BlockElement) => {
if (mode === 'page') {
blockElement.scrollIntoView({
behavior: 'smooth',
block: 'center',
});
if (!mode || !blockElement) {
return;
}
blockElement.scrollIntoView({
behavior: 'smooth',
block: 'center',
});
const selectManager = affineEditorContainerProxy.host?.selection;
if (!blockElement.path.length || !selectManager) {
return;
@@ -249,22 +230,65 @@ export const BlocksuiteEditorContainer = forwardRef<
blockId: blockElement.blockId,
});
selectManager.set([newSelection]);
setScrolled(true);
};
affineEditorContainerProxy.updateComplete
.then(() => {
if (blockElement && !scrolled) {
if (blockElement && !scrolledRef.current && !canceled) {
handleScrollToBlock(blockElement);
scrolledRef.current = true;
}
handleUpdateComplete();
})
.catch(console.error);
return () => {
canceled = true;
};
}, [blockElement, affineEditorContainerProxy, mode]);
useEffect(() => {
let disposable: Disposable | null = null;
let canceled = false;
// Function to handle block selection change
const handleSelectionChange = (selection: BaseSelection[]) => {
const viewLocation = currentView?.location$.value;
const currentPath = viewLocation?.pathname;
const locationHash = viewLocation?.hash;
if (
!currentView ||
!currentPath ||
// do not update the hash during the initial render
renderStartRef.current > Date.now() - 1000
) {
return;
}
if (selection[0]?.type !== 'block') {
return currentView.history.replace(currentPath);
}
const selectedId = selection[0]?.blockId;
if (!selectedId) {
return;
}
const newHash = `#${selectedId}`;
// Only update the hash if it has changed
if (locationHash !== newHash) {
currentView.history.replace(currentPath + newHash);
}
};
affineEditorContainerProxy.updateComplete
.then(() => {
const selectManager = affineEditorContainerProxy.host?.selection;
if (!selectManager || canceled) return;
// Set up the new disposable listener
disposable = selectManager.slots.changed.on(handleSelectionChange);
})
.catch(console.error);
return () => {
canceled = true;
disposable?.dispose();
};
}, [blockElement, affineEditorContainerProxy, mode, scrolled]);
}, [affineEditorContainerProxy, currentView]);
return (
<div

View File

@@ -3,6 +3,7 @@ import {
useLitPortalFactory,
} from '@affine/component';
import { useJournalInfoHelper } from '@affine/core/hooks/use-journal';
import { WorkbenchService } from '@affine/core/modules/workbench';
import {
BiDirectionalLinkPanel,
DocMetaTags,
@@ -11,6 +12,7 @@ import {
PageEditor,
} from '@blocksuite/presets';
import type { Doc } from '@blocksuite/store';
import { useLiveData, useService } from '@toeverything/infra';
import React, {
forwardRef,
Fragment,
@@ -70,6 +72,10 @@ export const BlocksuiteDocEditor = forwardRef<
useState<HTMLElementTagNameMap['affine-page-root']>();
const { isJournal } = useJournalInfoHelper(page.collection, page.id);
const workbench = useService(WorkbenchService).workbench;
const activeView = useLiveData(workbench.activeView$);
const hash = useLiveData(activeView.location$).hash;
const onDocRef = useCallback(
(el: PageEditor) => {
docRef.current = el;
@@ -98,13 +104,14 @@ export const BlocksuiteDocEditor = forwardRef<
if (docPage) {
setDocPage(docPage);
}
if (titleRef.current) {
if (titleRef.current && !hash) {
const richText = titleRef.current.querySelector('rich-text');
richText?.inlineEditor?.focusEnd();
} else {
docPage?.focusFirstParagraph();
}
});
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);
return (

View File

@@ -1,8 +1,10 @@
import { toast } from '@affine/component';
import { notify } from '@affine/component';
import { getAffineCloudBaseUrl } from '@affine/core/modules/cloud/services/fetch';
import { WorkbenchService } from '@affine/core/modules/workbench';
import { mixpanel } from '@affine/core/utils';
import { useAFFiNEI18N } from '@affine/i18n/hooks';
import { useCallback, useEffect, useMemo, useState } from 'react';
import { useLiveData, useService } from '@toeverything/infra';
import { useCallback, useMemo } from 'react';
type UrlType = 'share' | 'workspace';
@@ -19,28 +21,18 @@ const useGenerateUrl = ({ workspaceId, pageId, urlType }: UseSharingUrl) => {
// to generate a public url like https://app.affine.app/share/123/456
// or https://app.affine.app/share/123/456?mode=edgeless
const [hash, setHash] = useState(window.location.hash);
useEffect(() => {
const handleLocationChange = () => {
setHash(window.location.hash);
};
window.addEventListener('hashchange-custom', handleLocationChange);
return () => {
window.removeEventListener('hashchange-custom', handleLocationChange);
};
}, [setHash]);
const workbench = useService(WorkbenchService).workbench;
const activeView = useLiveData(workbench.activeView$);
const hash = useLiveData(activeView.location$).hash;
const baseUrl = getAffineCloudBaseUrl();
const url = useMemo(() => {
// baseUrl is null when running in electron and without network
if (!baseUrl) return null;
try {
return new URL(
`${baseUrl}/${urlType}/${workspaceId}/${pageId}${urlType === 'workspace' ? `${hash}` : ''}`
`${baseUrl}/${urlType}/${workspaceId}/${pageId}${urlType === 'workspace' && hash ? `${hash}` : ''}`
).toString();
} catch (e) {
return null;
@@ -63,7 +55,9 @@ export const useSharingUrl = ({
navigator.clipboard
.writeText(sharingUrl)
.then(() => {
toast(t['Copied link to clipboard']());
notify.success({
title: t['Copied link to clipboard'](),
});
})
.catch(err => {
console.error(err);
@@ -73,7 +67,9 @@ export const useSharingUrl = ({
type: 'link',
});
} else {
toast('Network not available');
notify.error({
title: 'Network not available',
});
}
}, [sharingUrl, t, urlType]);

View File

@@ -107,7 +107,7 @@ export class WorkspaceSQLiteDB {
logger.debug(`trim ${this.workspaceId}:${dbID} ${count}`);
const updates = await this.adapter.getUpdates(dbID);
const update = mergeUpdate(updates.map(row => row.data));
const insertRows = [{ data: update, dbID }];
const insertRows = [{ data: update, docId: dbID }];
await this.adapter?.replaceUpdates(dbID, insertRows);
logger.debug(`trim ${this.workspaceId}:${dbID} successfully`);
return update;

View File

@@ -66,7 +66,7 @@ export const LOCALES = [
originalName: '简体中文',
flagEmoji: '🇨🇳',
base: false,
completeRate: 1,
completeRate: 0.99,
res: zh_Hans,
},
{

View File

@@ -1,5 +1,6 @@
import './polyfill/dispose';
import './polyfill/intl-segmenter';
import './polyfill/promise-with-resolvers';
import './polyfill/request-idle-callback';
import '@affine/core/bootstrap/preload';

View File

@@ -0,0 +1 @@
import 'core-js/features/promise/with-resolvers';

View File

@@ -8,6 +8,7 @@
"electron",
"server",
"core",
"web",
"docs",
"storybook",
"component",

1026
yarn.lock

File diff suppressed because it is too large Load Diff