Compare commits

...

148 Commits

Author SHA1 Message Date
pengx17
bb606ac3e5 fix(core): audio job submittion timeout too short (#11918)
fix AF-2556
2025-04-24 17:07:49 +08:00
pengx17
851111e1e4 feat(core): add actions to transcription block (#11896) 2025-04-24 17:05:55 +08:00
pengx17
9982e0ea45 fix(core): sidebar audio player seek position issue (#11844)
fix AF-2541
2025-04-24 17:05:44 +08:00
pengx17
58f7a6166c fix(electron): use askForMeetingPermission for asking microphone permission (#11792) 2025-04-24 17:05:33 +08:00
pengx17
07d7a62071 fix(electron): sometimes pops up failed to save dialog (#11925)
fix AF-2557
2025-04-24 17:05:08 +08:00
Peng Xiao
ab3f056927 fix(core): remove image proxy in onboarding snapshots (#11954) 2025-04-24 17:04:32 +08:00
pengx17
61e3364717 fix(core): should not limit the number of docs of at menu (#11889)
fix AF-2544
2025-04-24 17:03:52 +08:00
yoyoyohamapi
e32d6b9347 fix(core): action items in the ai response are not optimized for dark mode (#11839)
### TL;DR

* Fix action items in the AI response are not optimized for dark mode.
* Fix answer content in the AI response are not optimized for edgeless theme.

![截屏2025-04-21 14.26.41.png](https://graphite-user-uploaded-assets-prod.s3.amazonaws.com/MyktQ6Qwc7H6TiRCFoYN/9c991df4-36b1-4969-ac0d-3c582edb1120.png)

[uploading 截屏2025-04-21 14.30.00.png...]

> CLOSE BS-3249
2025-04-24 16:48:09 +08:00
EYHN
075a2e9f99 fix(nbstore): fix indexer cache not working (#11922) 2025-04-24 16:43:04 +08:00
EYHN
8b486b4833 fix(core): subscribe search not unsubscribe (#11929) 2025-04-24 16:42:53 +08:00
darkskygit
21b7f02b0f fix(server): empty mimetype attachments fallback (#11869) 2025-04-23 15:57:12 +08:00
JimmFly
9f59d5e941 fix(core): confirm the tag name before creating a new tag (#11724)
close AF-1569

- Show rename modal below the "Add Tag" button instead of at the new tag node
- Tag is created only after the user confirms the name in the modal
- Improves sidebar tag creation flow and user experience
![CleanShot 2025-04-16 at 11 18 28@2x](https://github.com/user-attachments/assets/8b6ccd52-deef-45d7-b523-5f7b1c2cab96)
2025-04-18 07:53:32 +00:00
L-Sun
3264e65980 chore(editor): add feature flag to embed doc with alias (#11797) 2025-04-18 07:39:16 +00:00
fundon
9c02512d7c fix(editor): chevron down icon on toolbar (#11803)
Uniform size: 16x16
2025-04-18 07:10:01 +00:00
darkskygit
a33b82e8b1 fix(server): relax global embedding condition (#11791) 2025-04-18 06:56:35 +00:00
pengx17
3772a4700e fix(electron): browserwindow creationis sometimes too early (#11787)
fix https://toeverything.sentry.io/issues/6548826257/events/31d3c96a20c24c908188b3004b3ecab7?project=4506307500179456
2025-04-18 05:42:48 +00:00
CatsJuice
1c6eea21df fix(mobile): new doc in explorer folder (#11682) 2025-04-18 05:29:23 +00:00
JimmFly
a5061cee93 chore: adjust tag editor style (#11757)
close AF-2006
![CleanShot 2025-04-17 at 12 43 26@2x](https://github.com/user-attachments/assets/e7498ace-7294-410d-a2d3-83b92dbde036)
![CleanShot 2025-04-17 at 12 43 17@2x](https://github.com/user-attachments/assets/8617cea0-3200-4020-ad5b-b76a70680844)
2025-04-18 05:15:00 +00:00
JimmFly
37e07e91a3 fix(core): add tooltip to cloud server selector (#11755)
close AF-2438
2025-04-18 04:47:24 +00:00
JimmFly
178954a18c fix(core): handle incorrect style of the confirm delete button (#11725)
close AF-2401
2025-04-18 04:34:24 +00:00
EYHN
5694e3a56c feat(nbstore): add internal timeout to autoreconnection (#11785) 2025-04-18 04:20:52 +00:00
JimmFly
3355277e28 chore: remove cmd+s toast (#11754)
close AF-2345
2025-04-18 04:08:08 +00:00
fundon
1ae36d4b3e fix(editor): remove redundant subtraction (#11781) 2025-04-18 03:53:51 +00:00
JimmFly
445d7b47b8 chore: adjust rename input font size (#11758)
close AF-1974

![CleanShot 2025-04-17 at 12 56 03@2x](https://github.com/user-attachments/assets/88066cc7-0c1a-4d0c-90e9-8d20ba7880b3)
2025-04-18 03:40:22 +00:00
akumatus
203e931e30 fix(core): filter embedding results to return only user-selected tags and documents (#11770)
Close [AI-73](https://linear.app/affine-design/issue/AI-73)
2025-04-18 03:25:30 +00:00
darkskygit
d71cbd5fd3 feat(server): improve pdf support (#10929) 2025-04-18 03:11:09 +00:00
donteatfriedrice
a555df0200 fix(editor): footnote popup style and position issues (#11771)
Close [BS-3049](https://linear.app/affine-design/issue/BS-3049/chat引用的样式坏了) [BS-3024](https://linear.app/affine-design/issue/BS-3024/footnote-在容器边缘时,hover-抽搐)
2025-04-18 02:44:21 +00:00
EYHN
dd51180acb feat(core): replace onboarding template (#11768) 2025-04-18 02:31:13 +00:00
renovate
0b33fb6dbf chore: bump up @blocksuite/icons version to v2.2.12 (#11752)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@blocksuite/icons](https://redirect.github.com/toeverything/icons) | [`2.2.11` -> `2.2.12`](https://renovatebot.com/diffs/npm/@blocksuite%2ficons/2.2.11/2.2.12) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@blocksuite%2ficons/2.2.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@blocksuite%2ficons/2.2.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@blocksuite%2ficons/2.2.11/2.2.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@blocksuite%2ficons/2.2.11/2.2.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>toeverything/icons (@&#8203;blocksuite/icons)</summary>

### [`v2.2.12`](be28c231ea...00a749af2e)

[Compare Source](be28c231ea...00a749af2e)

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-18 02:18:08 +00:00
pengx17
04c0fa3de1 fix(native): invalid call to set mute behavior (#11764)
the error is only visible when turning build debug mode on
2025-04-18 02:03:06 +00:00
renovate
ec58850aca chore: bump up @nestjs/schedule version to v6 (#11780)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@nestjs/schedule](https://redirect.github.com/nestjs/schedule) | [`^5.0.1` -> `^6.0.0`](https://renovatebot.com/diffs/npm/@nestjs%2fschedule/5.0.1/6.0.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fschedule/6.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fschedule/6.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fschedule/5.0.1/6.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fschedule/5.0.1/6.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>nestjs/schedule (@&#8203;nestjs/schedule)</summary>

### [`v6.0.0`](https://redirect.github.com/nestjs/schedule/releases/tag/6.0.0)

[Compare Source](https://redirect.github.com/nestjs/schedule/compare/5.0.1...6.0.0)

#### What's Changed

-   fix(deps): update dependency cron to v4 by [@&#8203;renovate](https://redirect.github.com/renovate) in [https://github.com/nestjs/schedule/pull/1899](https://redirect.github.com/nestjs/schedule/pull/1899)

**Full Changelog**: https://github.com/nestjs/schedule/compare/5.0.1...6.0.0

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-18 01:50:23 +00:00
forehalo
8a013af12f build: update default container name to avoid conflict (#11782) 2025-04-18 01:37:42 +00:00
forehalo
5e0d1fae98 chore(server): allow preflight workspace blob url (#11783) 2025-04-18 01:23:14 +00:00
EYHN
a9e4690d2d fix(core): fix ai with multiple server (#11570) 2025-04-17 13:31:53 +00:00
EYHN
5e9ad634b7 feat(nbstore): optimize search performance (#11778)
now we can debug indexeddb performance by devtool

![image.png](https://graphite-user-uploaded-assets-prod.s3.amazonaws.com/g3jz87HxbjOJpXV3FPT7/75cf686f-9bc4-4db3-86ac-12bba83e8d83.png)
2025-04-17 13:16:18 +00:00
pengx17
75df27a145 fix(core): transcription block styls (#11772)
1. collapsed transcript block by default
2. summary block should be able to have list paragraphs
2025-04-17 12:41:52 +00:00
fundon
a46bb446e2 fix(editor): should keep color on custom color button (#11773)
Closes: [BS-3167](https://linear.app/affine-design/issue/BS-3167/自定义按钮显示错误)
2025-04-17 12:21:39 +00:00
EYHN
8dc21e53ca chore(i18n): update i18n-completenesses.json (#11779) 2025-04-17 11:57:44 +00:00
Vladimir Romashchenko
8575fc2ad5 feat(client): switch to 512x512 icons for linux, add metainfo (#11759) 2025-04-17 19:17:51 +08:00
JimmFly
c2c106f508 feat(core): add new loading doc component (#11737) 2025-04-17 18:54:38 +08:00
liuyi
bfecd1856b chore(core): wrong worker url prefix (#11769) 2025-04-17 18:52:55 +08:00
darkskygit
570dc79e3d feat(server): stop embedding in doc embedding disabled workspace (#11761)
fix AI-33
2025-04-17 09:57:33 +00:00
akumatus
e577bb7aa9 fix(core): ask ai loses user selected context (#11767)
Close [AI-72](https://linear.app/affine-design/issue/AI-72)
2025-04-17 09:05:44 +00:00
donteatfriedrice
d6287fd7b0 fix(editor): clicking footnote node should not open doc when readonly (#11749) 2025-04-17 08:52:17 +00:00
L-Sun
fa28554b66 chore(editor): improve highlight of toc card (#11766)
Close [BS-3166](https://linear.app/affine-design/issue/BS-3166/toc-hover有时会出现两个阴影)

https://github.com/user-attachments/assets/842a69bc-e299-4b84-8780-ff2b54c30bab
2025-04-17 08:10:50 +00:00
darkskygit
38e8806787 feat(server): add doc embedding switch for workspace (#11760)
fix AI-33
2025-04-17 07:13:22 +00:00
pengx17
ebf1d5476d feat(core): add summary to transcription block (#11753)
fix AF-2523
2025-04-17 06:33:04 +00:00
L-Sun
98899b4eea feat(editor): affine to blocksuite doc dnd with prefered card view (#11748)
Close [BS-3070](https://linear.app/affine-design/issue/BS-3070/文档拖动进入edgeless,形成引用时,默认形成embeded的引用,但是记录上次选择)
2025-04-17 04:06:50 +00:00
akumatus
50b3f5f7df fix(core): ai history of new users is always loading, enable online search by default (#11741)
Close [AI-69](https://linear.app/affine-design/issue/AI-69).
2025-04-17 02:53:41 +00:00
EYHN
b8d9c5417d fix(android): fix user db engine (#11684) 2025-04-17 02:26:56 +00:00
pengx17
e8d2b0114b fix(core): avatar cannot load google user content url image (#11733) 2025-04-17 02:13:54 +00:00
renovate
4a7f57ae3b chore: bump up @blocksuite/icons version to v2.2.11 (#11743)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@blocksuite/icons](https://redirect.github.com/toeverything/icons) | [`2.2.10` -> `2.2.11`](https://renovatebot.com/diffs/npm/@blocksuite%2ficons/2.2.10/2.2.11) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@blocksuite%2ficons/2.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@blocksuite%2ficons/2.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@blocksuite%2ficons/2.2.10/2.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@blocksuite%2ficons/2.2.10/2.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>toeverything/icons (@&#8203;blocksuite/icons)</summary>

### [`v2.2.11`](12ccbd9591...be28c231ea)

[Compare Source](12ccbd9591...be28c231ea)

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-17 01:59:04 +00:00
pengx17
72aa92546d feat(core): dragging audio waveform to change seek time (#11730)
fix AF-2519
2025-04-17 01:43:11 +00:00
forehalo
18fae0f1aa fix: host app with subpath (#11739)
closes #11719
2025-04-17 01:29:48 +00:00
pengx17
268c34e8b5 fix(core): appcontainer fallback display issue (#11669) 2025-04-16 10:44:03 +00:00
JimmFly
1c1c5ce64b feat(core): show expiration time in link invitation dialog (#11610)
close BS-3095
2025-04-16 10:30:35 +00:00
donteatfriedrice
022e5f2c93 fix(editor): update embed iframe block event tracker (#11736)
Close [BS-3151](https://linear.app/affine-design/issue/BS-3151/埋一下-reload-link-成功失败)
2025-04-16 09:53:38 +00:00
Yifeng Wang
16f7be7f0b perf(editor): avoid redundant dom query when editing single block (#11732) 2025-04-16 17:52:22 +08:00
renovate
71114e8935 chore: bump up nestjs to v11.0.20 (#11728)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@nestjs/common](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/common)) | [`11.0.19` -> `11.0.20`](https://renovatebot.com/diffs/npm/@nestjs%2fcommon/11.0.19/11.0.20) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcommon/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcommon/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcommon/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcommon/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/core](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/core)) | [`11.0.19` -> `11.0.20`](https://renovatebot.com/diffs/npm/@nestjs%2fcore/11.0.19/11.0.20) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcore/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcore/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcore/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcore/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-express](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-express)) | [`11.0.19` -> `11.0.20`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-express/11.0.19/11.0.20) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-express/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-express/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-express/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-express/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-socket.io](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-socket.io)) | [`11.0.19` -> `11.0.20`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-socket.io/11.0.19/11.0.20) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-socket.io/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-socket.io/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-socket.io/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-socket.io/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/websockets](https://redirect.github.com/nestjs/nest) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/websockets)) | [`11.0.19` -> `11.0.20`](https://renovatebot.com/diffs/npm/@nestjs%2fwebsockets/11.0.19/11.0.20) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fwebsockets/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fwebsockets/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fwebsockets/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fwebsockets/11.0.19/11.0.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>nestjs/nest (@&#8203;nestjs/common)</summary>

### [`v11.0.20`](https://redirect.github.com/nestjs/nest/compare/v11.0.19...d5bca8871cfb16e18bb9c9814fc7d7df7b3896c3)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.19...v11.0.20)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/core)</summary>

### [`v11.0.20`](https://redirect.github.com/nestjs/nest/compare/v11.0.19...d5bca8871cfb16e18bb9c9814fc7d7df7b3896c3)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.19...v11.0.20)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-express)</summary>

### [`v11.0.20`](https://redirect.github.com/nestjs/nest/releases/tag/v11.0.20)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.19...v11.0.20)

#### What's Changed

-   refactor(common): Prevent JavaScript being wrapped in `eval` by [@&#8203;Borewit](https://redirect.github.com/Borewit) in [https://github.com/nestjs/nest/pull/14974](https://redirect.github.com/nestjs/nest/pull/14974)

#### New Contributors

-   [@&#8203;Borewit](https://redirect.github.com/Borewit) made their first contribution in [https://github.com/nestjs/nest/pull/14974](https://redirect.github.com/nestjs/nest/pull/14974)

**Full Changelog**: https://github.com/nestjs/nest/compare/v11.0.19...v11.0.20

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-socket.io)</summary>

### [`v11.0.20`](https://redirect.github.com/nestjs/nest/compare/v11.0.19...d5bca8871cfb16e18bb9c9814fc7d7df7b3896c3)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.19...v11.0.20)

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about these updates again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-16 09:32:40 +00:00
pengx17
ef7a82d6e6 fix(core): adjust recording user-select none style (#11735) 2025-04-16 09:19:14 +00:00
doodlewind
b21864cf63 perf(editor): dispose input event handler for removed blocks (#11734) 2025-04-16 09:05:47 +00:00
donteatfriedrice
212c13f843 fix(editor): add code block clipboard extension (#11731)
Close [BS-3109](https://linear.app/affine-design/issue/BS-3109/code-block-不支援-markdown-語法)
2025-04-16 08:32:00 +00:00
forehalo
bfb94acc42 fix(server): subscription delete race condition (#11729) 2025-04-16 08:18:29 +00:00
L-Sun
84bf7d2a41 chore(debug): no need sourceMapPathOverrides anymore (#11726) 2025-04-16 08:04:15 +00:00
pengx17
51316217af feat(core): audio playback rate (#11702)
fix AF-2470
2025-04-16 07:49:12 +00:00
renovate
30184817da chore: Lock file maintenance (#11483)
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 - "* 0-3 * * 1" (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://redirect.github.com/renovatebot/renovate/discussions) if that's undesired.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMjcuMyIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-16 07:32:48 +00:00
renovate
4b62d109d3 chore: bump up nestjs to v11.0.19 (#11718)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@nestjs/common](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/common)) | [`11.0.17` -> `11.0.19`](https://renovatebot.com/diffs/npm/@nestjs%2fcommon/11.0.17/11.0.19) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcommon/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcommon/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcommon/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcommon/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/core](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/core)) | [`11.0.17` -> `11.0.19`](https://renovatebot.com/diffs/npm/@nestjs%2fcore/11.0.17/11.0.19) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcore/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcore/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcore/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcore/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-express](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-express)) | [`11.0.17` -> `11.0.19`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-express/11.0.17/11.0.19) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-express/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-express/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-express/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-express/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-socket.io](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-socket.io)) | [`11.0.17` -> `11.0.19`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-socket.io/11.0.17/11.0.19) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-socket.io/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-socket.io/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-socket.io/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-socket.io/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/websockets](https://redirect.github.com/nestjs/nest) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/websockets)) | [`11.0.17` -> `11.0.19`](https://renovatebot.com/diffs/npm/@nestjs%2fwebsockets/11.0.17/11.0.19) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fwebsockets/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fwebsockets/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fwebsockets/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fwebsockets/11.0.17/11.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>nestjs/nest (@&#8203;nestjs/common)</summary>

### [`v11.0.19`](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

### [`v11.0.18`](https://redirect.github.com/nestjs/nest/releases/tag/v11.0.18)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.17...v11.0.18)

#### What's Changed

-   chore(common): temporarily move file-type to regular deps d9a69a32a4

**Full Changelog**: https://github.com/nestjs/nest/compare/v11.0.17...v11.0.18

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/core)</summary>

### [`v11.0.19`](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

### [`v11.0.18`](https://redirect.github.com/nestjs/nest/releases/tag/v11.0.18)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.17...v11.0.18)

##### What's Changed

-   chore(common): temporarily move file-type to regular deps d9a69a32a4

**Full Changelog**: https://github.com/nestjs/nest/compare/v11.0.17...v11.0.18

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-express)</summary>

### [`v11.0.19`](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

### [`v11.0.18`](https://redirect.github.com/nestjs/nest/releases/tag/v11.0.18)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.17...v11.0.18)

##### What's Changed

-   chore(common): temporarily move file-type to regular deps d9a69a32a4

**Full Changelog**: https://github.com/nestjs/nest/compare/v11.0.17...v11.0.18

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-socket.io)</summary>

### [`v11.0.19`](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

### [`v11.0.18`](https://redirect.github.com/nestjs/nest/releases/tag/v11.0.18)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.17...v11.0.18)

#### What's Changed

-   chore(common): temporarily move file-type to regular deps d9a69a32a4

**Full Changelog**: https://github.com/nestjs/nest/compare/v11.0.17...v11.0.18

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/websockets)</summary>

### [`v11.0.19`](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.18...v11.0.19)

### [`v11.0.18`](https://redirect.github.com/nestjs/nest/releases/tag/v11.0.18)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.17...v11.0.18)

##### What's Changed

-   chore(common): temporarily move file-type to regular deps d9a69a32a4

**Full Changelog**: https://github.com/nestjs/nest/compare/v11.0.17...v11.0.18

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about these updates again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-16 06:49:26 +00:00
Cats Juice
d045651a03 fix(mobile): tab is not at bottom in tag detail page when empty (#11723) 2025-04-16 14:48:48 +08:00
pengx17
79c9425df6 fix(editor): link popover title overflow (#11704)
fix AF-2506
2025-04-16 04:40:59 +00:00
donteatfriedrice
bfec5dd594 fix(editor): markdown html and image import (#11712)
Close
[BS-3145](https://linear.app/affine-design/issue/BS-3145/markdown-adapter-html-标签导入成-code-block)
[BS-3154](https://linear.app/affine-design/issue/BS-3154/[bug]-使用-markdown-with-files-导入到-affine-图片丢失)
2025-04-16 04:27:39 +00:00
Saul-Mirone
828215f45a refactor(editor): remove unused modal widget (#11713) 2025-04-16 04:13:58 +00:00
Aki Chang
26ddccccd2 fix(android): add proguard rules for release build crash (#11710) 2025-04-16 10:11:29 +08:00
Brooooooklyn
fe86722845 perf(native): use simd to speedup audio buffer mix (#11717)
Run `cargo bench -p affine_media_capture`

```
test result: ok. 0 passed; 0 failed; 6 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running benches/mix_audio_samples.rs (target/release/deps/mix_audio_samples-ffbc55dcf90d3468)
audio mix/simd          time:   [98.380 ns 99.339 ns 100.57 ns]
                        change: [−19.199% −16.928% −14.569%] (p = 0.00 < 0.05)
                        Performance has improved.
Found 12 outliers among 100 measurements (12.00%)
  6 (6.00%) high mild
  6 (6.00%) high severe
audio mix/scalar        time:   [123.99 ns 126.11 ns 128.71 ns]
                        change: [+0.2703% +1.2739% +2.5727%] (p = 0.02 < 0.05)
                        Change within noise threshold.
Found 11 outliers among 100 measurements (11.00%)
  4 (4.00%) high mild
  7 (7.00%) high severe
```
2025-04-16 00:42:30 +00:00
darkskygit
e0970daa5a feat(server): upgrade models to gpt4.1 (#11696) 2025-04-15 14:23:40 +00:00
pengx17
220087c172 fix(mobile): cannot change tag color (#11708)
fix AF-2402
2025-04-15 13:36:22 +00:00
pengx17
db2a8fd509 fix(core): database backlink row visibility (#11706)
fix AF-2507

do not show the db backlink row if
- the row does not have any properties (excluding `title` column)
- the target doc is a template page
2025-04-15 13:21:49 +00:00
Saul-Mirone
b2694003c9 fix(editor): missing copy as png implementation (#11716) 2025-04-15 13:08:47 +00:00
forehalo
681c61a300 chore(admin): allow config avatar public path (#11689)
close #11677
2025-04-15 12:54:55 +00:00
Saul-Mirone
3ebac1d39d refactor(editor): remove dead code (#11709) 2025-04-15 12:40:36 +00:00
donteatfriedrice
96e58316f7 feat(editor): add footnote node click handler (#11699)
Close [BS-3114](https://linear.app/affine-design/issue/BS-3114/点击-footnote-node-行为更新)
2025-04-15 12:22:43 +00:00
Saul-Mirone
b5c9741f18 feat(editor): extract keyboard toolbar widget (#11707) 2025-04-15 12:06:50 +00:00
renovate
ecdaea9176 chore: bump up i18next version to v25 (#11705)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [i18next](https://www.i18next.com) ([source](https://redirect.github.com/i18next/i18next)) | [`^24.1.0` -> `^25.0.0`](https://renovatebot.com/diffs/npm/i18next/24.2.3/25.0.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/i18next/25.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/i18next/25.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/i18next/24.2.3/25.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/i18next/24.2.3/25.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>i18next/i18next (i18next)</summary>

### [`v25.0.0`](https://redirect.github.com/i18next/i18next/blob/HEAD/CHANGELOG.md#2500)

[Compare Source](https://redirect.github.com/i18next/i18next/compare/v24.2.3...v25.0.0)

**This is a potentially breaking release:**

-   fix multiple changeLanguage call that may have result in wrong order in previous versions [1605](https://redirect.github.com/i18next/i18next/issues/1605) [2298](https://redirect.github.com/i18next/i18next/pull/2298)
-   adapt `changeLanguage` to always (string or array) use `getBestMatchFromCodes` [2299](https://redirect.github.com/i18next/i18next/issues/2299)
-   `getBestMatchFromCodes` now tries to fallback to language code with same script [2299](https://redirect.github.com/i18next/i18next/issues/2299)

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-15 11:52:42 +00:00
forehalo
7257f1b55b chore(server): remove enable flag in mail config (#11680)
close #11625
2025-04-15 09:18:10 +00:00
renovate
b249939093 chore: bump up prisma monorepo to v6 (major) (#8964)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@prisma/client](https://www.prisma.io) ([source](https://redirect.github.com/prisma/prisma/tree/HEAD/packages/client)) | [`^5.22.0` -> `^6.0.0`](https://renovatebot.com/diffs/npm/@prisma%2fclient/5.22.0/6.0.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@prisma%2fclient/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@prisma%2fclient/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@prisma%2fclient/5.22.0/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@prisma%2fclient/5.22.0/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@prisma/instrumentation](https://www.prisma.io) ([source](https://redirect.github.com/prisma/prisma/tree/HEAD/packages/instrumentation)) | [`^5.22.0` -> `^6.0.0`](https://renovatebot.com/diffs/npm/@prisma%2finstrumentation/5.22.0/6.0.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@prisma%2finstrumentation/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@prisma%2finstrumentation/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@prisma%2finstrumentation/5.22.0/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@prisma%2finstrumentation/5.22.0/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [prisma](https://www.prisma.io) ([source](https://redirect.github.com/prisma/prisma/tree/HEAD/packages/cli)) | [`^5.22.0` -> `^6.0.0`](https://renovatebot.com/diffs/npm/prisma/5.22.0/6.0.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/prisma/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/prisma/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/prisma/5.22.0/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/prisma/5.22.0/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>prisma/prisma (@&#8203;prisma/client)</summary>

### [`v6.0.1`](https://redirect.github.com/prisma/prisma/compare/6.0.0...6.0.1)

[Compare Source](https://redirect.github.com/prisma/prisma/compare/6.0.0...6.0.1)

### [`v6.0.0`](https://redirect.github.com/prisma/prisma/releases/tag/6.0.0)

[Compare Source](https://redirect.github.com/prisma/prisma/compare/5.22.0...6.0.0)

We’re excited to share the Prisma ORM v6 release today 🎉

As this is a major release, it includes a few breaking changes that may affect your application. Before upgrading, we recommend that you check out our [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6) to understand the impact on your application.

If you want to have an overview of what we accomplished since v5, check out our announcement blog post: [Prisma 6: Better Performance, More Flexibility & Type-Safe SQL](https://www.prisma.io/blog/prisma-6-better-performance-more-flexibility-and-type-safe-sql).

🌟 **Help us spread the word about Prisma by starring the repo ☝️ or [posting on X](https://twitter.com/intent/tweet?text=Check%20out%20the%20latest%20@&#8203;prisma%20release%20v6.0.0%20%F0%9F%9A%80%0D%0A%0D%0Ahttps://github.com/prisma/prisma/releases/tag/6.0.0) about the release.**

##### Breaking changes

⚠️ This section contains a list of breaking changes. If you upgrade your application to Prisma ORM v6 without addressing these, your application is going to break! **For detailed upgrade instructions, check out the [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6).** ⚠️ 

##### Minimum supported Node.js versions

The new minimum supported Node.js versions for Prisma ORM v6 are:

-   for Node.js 18 the minimum supported version is **18.18.0**
-   for Node.js 20 the minimum supported version is **20.9.0**
-   for Node.js 22 the minimum supported version is **22.11.0**

There is no official support for Node.js <18.18.0, 19, 21, 23.

##### Minimum supported TypeScript version

The new minimum supported TypeScript version for Prisma ORM v6 is: **5.1.0**.

##### Schema change for implicit m-n relations on PostgreSQL

If you're using PostgreSQL and are defining [implicit many-to-many relations](https://www.prisma.io/docs/orm/prisma-schema/data-model/relations/many-to-many-relations#implicit-many-to-many-relations) in your Prisma schema, Prisma ORM maintains the [relation table](https://www.prisma.io/docs/orm/prisma-schema/data-model/relations/many-to-many-relations#relation-tables) for you under the hood. This relation table has `A` and `B` columns to represent the tables of the models that are part of this relation.

Previous versions of Prisma ORM used to create a *unique index* on these two columns. In Prisma v6, this unique index is changing to a *primary key* in order to [simplify for the default replica identity behaviour](https://redirect.github.com/prisma/prisma/issues/25196).

If you're defining implicit m-n relations in your Prisma schema, the next migration you'll create will contain `ALTER TABLE` statements for *all* the relation tables that belong to these relations.

##### Full-text search on PostgreSQL

The `fullTextSearch` Preview feature is promoted to General Availability only for MySQL. This means that if you're using PostgreSQL and currently make use of this Preview feature, you now need to use the new `fullTextSearchPostgres` Preview feature.

##### Usage of `Buffer`

Prisma v6 replaces the usage of [`Buffer`](https://nodejs.org/api/buffer.html) with [`Uint8Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array) to represent fields of type `Bytes`. Make sure to replace all your occurrences of the `Buffer` type with the new `Uint8Array`.

##### Removed `NotFoundError`

In Prisma v6, we removed the `NotFoundError` in favor of `PrismaClientKnownRequestError` with error code [`P2025`](https://www.prisma.io/docs/orm/reference/error-reference#p2025) in [`findUniqueOrThrow()`](https://www.prisma.io/docs/orm/reference/prisma-client-reference#finduniqueorthrow) and [`findFirstOrThrow()`](https://www.prisma.io/docs/orm/reference/prisma-client-reference#findfirstorthrow). If you've relied on catching `NotFoundError` instances in your code, you need to adjust the code accordingly.

##### New keywords that can't be used as model names: `async`, `await`, `using`

With this release, you can't use `async`, `await` and `using` as model names any more.

***

⚠️ **For detailed upgrade instructions, check out the [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6).**  ⚠️ 

##### Preview features promoted to General Availability

In this release, we are promoting a number of [Preview](https://www.prisma.io/docs/orm/more/releases#preview) features to [General Availability](https://www.prisma.io/docs/orm/more/releases#generally-available-ga).

##### `fullTextIndex`

If you use the [full-text index](https://www.prisma.io/docs/orm/prisma-schema/data-model/indexes#full-text-indexes-mysql-and-mongodb) feature in your app, you can now remove `fullTextIndex` from the `previewFeatures` in your Prisma schema:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextIndex"]
}

```

##### `fullTextSearch`

If you use the [full-text search](https://www.prisma.io/docs/orm/prisma-client/queries/full-text-search) feature with **MySQL** in your app, you can now remove `fullTextSearch` from the `previewFeatures` in your Prisma schema:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextSearch"]
}

```

If you are using it with **PostgreSQL**, you need to update the name of the feature flag to `fullTextSearchPostgres`:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextSearch"]
+ previewFeatures = ["fullTextSearchPostgres"]
}
```

##### New features

We are also releasing new features with this release:

-   [cuid2() support](https://redirect.github.com/prisma/prisma-engines/pull/5047)
-   [Include unused enum definitions in `prisma generate`'s output](https://redirect.github.com/prisma/prisma/pull/25740)
-   [Improved compatibility with Deno 2](https://redirect.github.com/prisma/prisma/pull/25734)

##### Company news

##### 🚀 Prisma Postgres is free during Early Access

In case you missed it: We recently launched [Prisma Postgres](https://www.prisma.io/blog/announcing-prisma-postgres-early-access), a serverless database with zero cold starts, a generous free tier, connection pooling, real-time events, and a lot more! It’s entirely free during the Early Access phase, try it now!

#####  Let us know what you think of Prisma ORM

We're always trying to improve! If you've recently used Prisma ORM, we'd appreciate hearing your thoughts about your experience via this [2min survey](https://pris.ly/orm/survey/release-5-22).

</details>

<details>
<summary>prisma/prisma (@&#8203;prisma/instrumentation)</summary>

### [`v6.0.1`](https://redirect.github.com/prisma/prisma/releases/tag/6.0.1)

[Compare Source](https://redirect.github.com/prisma/prisma/compare/6.0.0...6.0.1)

Today we are releasing the `6.0.1` patch release to address an issue with using Prisma Client generated in a custom output path with Next.js.

##### Changes

-   [Revert `"type": "commonjs"` addition in generated `package.json`](https://redirect.github.com/prisma/prisma/pull/25767)

### [`v6.0.0`](https://redirect.github.com/prisma/prisma/releases/tag/6.0.0)

[Compare Source](https://redirect.github.com/prisma/prisma/compare/5.22.0...6.0.0)

We’re excited to share the Prisma ORM v6 release today 🎉

As this is a major release, it includes a few breaking changes that may affect your application. Before upgrading, we recommend that you check out our [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6) to understand the impact on your application.

If you want to have an overview of what we accomplished since v5, check out our announcement blog post: [Prisma 6: Better Performance, More Flexibility & Type-Safe SQL](https://www.prisma.io/blog/prisma-6-better-performance-more-flexibility-and-type-safe-sql).

🌟 **Help us spread the word about Prisma by starring the repo ☝️ or [posting on X](https://twitter.com/intent/tweet?text=Check%20out%20the%20latest%20@&#8203;prisma%20release%20v6.0.0%20%F0%9F%9A%80%0D%0A%0D%0Ahttps://github.com/prisma/prisma/releases/tag/6.0.0) about the release.**

#### Breaking changes

⚠️ This section contains a list of breaking changes. If you upgrade your application to Prisma ORM v6 without addressing these, your application is going to break! **For detailed upgrade instructions, check out the [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6).** ⚠️ 

##### Minimum supported Node.js versions

The new minimum supported Node.js versions for Prisma ORM v6 are:

-   for Node.js 18 the minimum supported version is **18.18.0**
-   for Node.js 20 the minimum supported version is **20.9.0**
-   for Node.js 22 the minimum supported version is **22.11.0**

There is no official support for Node.js <18.18.0, 19, 21, 23.

##### Minimum supported TypeScript version

The new minimum supported TypeScript version for Prisma ORM v6 is: **5.1.0**.

##### Schema change for implicit m-n relations on PostgreSQL

If you're using PostgreSQL and are defining [implicit many-to-many relations](https://www.prisma.io/docs/orm/prisma-schema/data-model/relations/many-to-many-relations#implicit-many-to-many-relations) in your Prisma schema, Prisma ORM maintains the [relation table](https://www.prisma.io/docs/orm/prisma-schema/data-model/relations/many-to-many-relations#relation-tables) for you under the hood. This relation table has `A` and `B` columns to represent the tables of the models that are part of this relation.

Previous versions of Prisma ORM used to create a *unique index* on these two columns. In Prisma v6, this unique index is changing to a *primary key* in order to [simplify for the default replica identity behaviour](https://redirect.github.com/prisma/prisma/issues/25196).

If you're defining implicit m-n relations in your Prisma schema, the next migration you'll create will contain `ALTER TABLE` statements for *all* the relation tables that belong to these relations.

##### Full-text search on PostgreSQL

The `fullTextSearch` Preview feature is promoted to General Availability only for MySQL. This means that if you're using PostgreSQL and currently make use of this Preview feature, you now need to use the new `fullTextSearchPostgres` Preview feature.

##### Usage of `Buffer`

Prisma v6 replaces the usage of [`Buffer`](https://nodejs.org/api/buffer.html) with [`Uint8Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array) to represent fields of type `Bytes`. Make sure to replace all your occurrences of the `Buffer` type with the new `Uint8Array`.

##### Removed `NotFoundError`

In Prisma v6, we removed the `NotFoundError` in favor of `PrismaClientKnownRequestError` with error code [`P2025`](https://www.prisma.io/docs/orm/reference/error-reference#p2025) in [`findUniqueOrThrow()`](https://www.prisma.io/docs/orm/reference/prisma-client-reference#finduniqueorthrow) and [`findFirstOrThrow()`](https://www.prisma.io/docs/orm/reference/prisma-client-reference#findfirstorthrow). If you've relied on catching `NotFoundError` instances in your code, you need to adjust the code accordingly.

##### New keywords that can't be used as model names: `async`, `await`, `using`

With this release, you can't use `async`, `await` and `using` as model names any more.

***

⚠️ **For detailed upgrade instructions, check out the [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6).**  ⚠️ 

#### Preview features promoted to General Availability

In this release, we are promoting a number of [Preview](https://www.prisma.io/docs/orm/more/releases#preview) features to [General Availability](https://www.prisma.io/docs/orm/more/releases#generally-available-ga).

##### `fullTextIndex`

If you use the [full-text index](https://www.prisma.io/docs/orm/prisma-schema/data-model/indexes#full-text-indexes-mysql-and-mongodb) feature in your app, you can now remove `fullTextIndex` from the `previewFeatures` in your Prisma schema:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextIndex"]
}

```

##### `fullTextSearch`

If you use the [full-text search](https://www.prisma.io/docs/orm/prisma-client/queries/full-text-search) feature with **MySQL** in your app, you can now remove `fullTextSearch` from the `previewFeatures` in your Prisma schema:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextSearch"]
}

```

If you are using it with **PostgreSQL**, you need to update the name of the feature flag to `fullTextSearchPostgres`:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextSearch"]
+ previewFeatures = ["fullTextSearchPostgres"]
}
```

#### New features

We are also releasing new features with this release:

-   [cuid2() support](https://redirect.github.com/prisma/prisma-engines/pull/5047)
-   [Include unused enum definitions in `prisma generate`'s output](https://redirect.github.com/prisma/prisma/pull/25740)
-   [Improved compatibility with Deno 2](https://redirect.github.com/prisma/prisma/pull/25734)

#### Company news

##### 🚀 Prisma Postgres is free during Early Access

In case you missed it: We recently launched [Prisma Postgres](https://www.prisma.io/blog/announcing-prisma-postgres-early-access), a serverless database with zero cold starts, a generous free tier, connection pooling, real-time events, and a lot more! It’s entirely free during the Early Access phase, try it now!

#####  Let us know what you think of Prisma ORM

We're always trying to improve! If you've recently used Prisma ORM, we'd appreciate hearing your thoughts about your experience via this [2min survey](https://pris.ly/orm/survey/release-5-22).

</details>

<details>
<summary>prisma/prisma (prisma)</summary>

### [`v6.0.1`](https://redirect.github.com/prisma/prisma/compare/6.0.0...6.0.1)

[Compare Source](https://redirect.github.com/prisma/prisma/compare/6.0.0...6.0.1)

### [`v6.0.0`](https://redirect.github.com/prisma/prisma/releases/tag/6.0.0)

[Compare Source](https://redirect.github.com/prisma/prisma/compare/5.22.0...6.0.0)

We’re excited to share the Prisma ORM v6 release today 🎉

As this is a major release, it includes a few breaking changes that may affect your application. Before upgrading, we recommend that you check out our [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6) to understand the impact on your application.

If you want to have an overview of what we accomplished since v5, check out our announcement blog post: [Prisma 6: Better Performance, More Flexibility & Type-Safe SQL](https://www.prisma.io/blog/prisma-6-better-performance-more-flexibility-and-type-safe-sql).

🌟 **Help us spread the word about Prisma by starring the repo ☝️ or [posting on X](https://twitter.com/intent/tweet?text=Check%20out%20the%20latest%20@&#8203;prisma%20release%20v6.0.0%20%F0%9F%9A%80%0D%0A%0D%0Ahttps://github.com/prisma/prisma/releases/tag/6.0.0) about the release.**

##### Breaking changes

⚠️ This section contains a list of breaking changes. If you upgrade your application to Prisma ORM v6 without addressing these, your application is going to break! **For detailed upgrade instructions, check out the [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6).** ⚠️ 

##### Minimum supported Node.js versions

The new minimum supported Node.js versions for Prisma ORM v6 are:

-   for Node.js 18 the minimum supported version is **18.18.0**
-   for Node.js 20 the minimum supported version is **20.9.0**
-   for Node.js 22 the minimum supported version is **22.11.0**

There is no official support for Node.js <18.18.0, 19, 21, 23.

##### Minimum supported TypeScript version

The new minimum supported TypeScript version for Prisma ORM v6 is: **5.1.0**.

##### Schema change for implicit m-n relations on PostgreSQL

If you're using PostgreSQL and are defining [implicit many-to-many relations](https://www.prisma.io/docs/orm/prisma-schema/data-model/relations/many-to-many-relations#implicit-many-to-many-relations) in your Prisma schema, Prisma ORM maintains the [relation table](https://www.prisma.io/docs/orm/prisma-schema/data-model/relations/many-to-many-relations#relation-tables) for you under the hood. This relation table has `A` and `B` columns to represent the tables of the models that are part of this relation.

Previous versions of Prisma ORM used to create a *unique index* on these two columns. In Prisma v6, this unique index is changing to a *primary key* in order to [simplify for the default replica identity behaviour](https://redirect.github.com/prisma/prisma/issues/25196).

If you're defining implicit m-n relations in your Prisma schema, the next migration you'll create will contain `ALTER TABLE` statements for *all* the relation tables that belong to these relations.

##### Full-text search on PostgreSQL

The `fullTextSearch` Preview feature is promoted to General Availability only for MySQL. This means that if you're using PostgreSQL and currently make use of this Preview feature, you now need to use the new `fullTextSearchPostgres` Preview feature.

##### Usage of `Buffer`

Prisma v6 replaces the usage of [`Buffer`](https://nodejs.org/api/buffer.html) with [`Uint8Array`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array) to represent fields of type `Bytes`. Make sure to replace all your occurrences of the `Buffer` type with the new `Uint8Array`.

##### Removed `NotFoundError`

In Prisma v6, we removed the `NotFoundError` in favor of `PrismaClientKnownRequestError` with error code [`P2025`](https://www.prisma.io/docs/orm/reference/error-reference#p2025) in [`findUniqueOrThrow()`](https://www.prisma.io/docs/orm/reference/prisma-client-reference#finduniqueorthrow) and [`findFirstOrThrow()`](https://www.prisma.io/docs/orm/reference/prisma-client-reference#findfirstorthrow). If you've relied on catching `NotFoundError` instances in your code, you need to adjust the code accordingly.

##### New keywords that can't be used as model names: `async`, `await`, `using`

With this release, you can't use `async`, `await` and `using` as model names any more.

***

⚠️ **For detailed upgrade instructions, check out the [upgrade guide](https://www.prisma.io/docs/orm/more/upgrade-guides/upgrading-versions/upgrading-to-prisma-6).**  ⚠️ 

##### Preview features promoted to General Availability

In this release, we are promoting a number of [Preview](https://www.prisma.io/docs/orm/more/releases#preview) features to [General Availability](https://www.prisma.io/docs/orm/more/releases#generally-available-ga).

##### `fullTextIndex`

If you use the [full-text index](https://www.prisma.io/docs/orm/prisma-schema/data-model/indexes#full-text-indexes-mysql-and-mongodb) feature in your app, you can now remove `fullTextIndex` from the `previewFeatures` in your Prisma schema:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextIndex"]
}

```

##### `fullTextSearch`

If you use the [full-text search](https://www.prisma.io/docs/orm/prisma-client/queries/full-text-search) feature with **MySQL** in your app, you can now remove `fullTextSearch` from the `previewFeatures` in your Prisma schema:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextSearch"]
}

```

If you are using it with **PostgreSQL**, you need to update the name of the feature flag to `fullTextSearchPostgres`:

```diff
generator client {
  provider        = "prisma-client-js"
- previewFeatures = ["fullTextSearch"]
+ previewFeatures = ["fullTextSearchPostgres"]
}
```

##### New features

We are also releasing new features with this release:

-   [cuid2() support](https://redirect.github.com/prisma/prisma-engines/pull/5047)
-   [Include unused enum definitions in `prisma generate`'s output](https://redirect.github.com/prisma/prisma/pull/25740)
-   [Improved compatibility with Deno 2](https://redirect.github.com/prisma/prisma/pull/25734)

##### Company news

##### 🚀 Prisma Postgres is free during Early Access

In case you missed it: We recently launched [Prisma Postgres](https://www.prisma.io/blog/announcing-prisma-postgres-early-access), a serverless database with zero cold starts, a generous free tier, connection pooling, real-time events, and a lot more! It’s entirely free during the Early Access phase, try it now!

#####  Let us know what you think of Prisma ORM

We're always trying to improve! If you've recently used Prisma ORM, we'd appreciate hearing your thoughts about your experience via this [2min survey](https://pris.ly/orm/survey/release-5-22).

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about these updates again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4xOS4wIiwidXBkYXRlZEluVmVyIjoiMzkuNTguMSIsInRhcmdldEJyYW5jaCI6ImNhbmFyeSIsImxhYmVscyI6WyJkZXBlbmRlbmNpZXMiXX0=-->
2025-04-15 09:05:00 +00:00
fundon
8ca675b2ec fix(editor): improve pdf embed viewer UX (#11641)
Closes: [BS-3101](https://linear.app/affine-design/issue/BS-3101/pdf-embed-模式的选中框选-和点开看详情有比较大的问题)

### What's Changed!

* Fixed disable pointer event in native pdf viewer by dragging
* Disable opening peek view with pdf viewer in readonly and sharing modes
2025-04-15 08:51:02 +00:00
yoyoyohamapi
0df584bd5e refactor(core): add keyPress event to fix IME space detection (#11700)
### TL;DR
Refactor space-triggered AI Widget activation logic from `keydown` to `keypress` event listeners

### Background

The `keydown` event triggered by a space may originate from:
1. Normal space insertion
2. Space triggered by input method confirming candidate words

In scenarios like (2), some browsers (see [ISSUE](https://github.com/toeverything/AFFiNE/issues/11541)) and input method callbacks produce events identical to scenario (1),making it impossible to distinguish between the two.

To fix this, the space-activated AI listener uses the `keypress` event:
In scenario 2, `event.which !== 32` (may be `30430` or other values) can be used to differentiate from scenario 1.

> CLOSE BS-3081
2025-04-15 08:37:27 +00:00
Flrande
fd6c34cfa3 fix(editor): v-element may get undefined inline editor (#11697) 2025-04-15 08:22:39 +00:00
pengx17
46f3dfc64c fix(core): audio player ux (#11685) 2025-04-15 16:06:59 +08:00
Aki Chang
793d084077 chore(android): only status draft may be created on draft app (#11701) 2025-04-15 15:51:12 +08:00
pengx17
7b2ae7f573 feat(core): adjust history modal styles (#11675)
- add avatar/name info to each history snapshot item
- add avatar to audio transcription job owner

fix AF-2483

![image.png](https://graphite-user-uploaded-assets-prod.s3.amazonaws.com/T2klNLEk0wxLh4NRDzhk/4a2b88c2-311a-470e-a8a9-113931cdf17e.png)
2025-04-15 07:16:53 +00:00
donteatfriedrice
e02b159bf4 feat(core): remove preview footnote hover effect config (#11695)
Close [BS-3115](https://linear.app/affine-design/issue/BS-3115/侧边栏-footnote-ui-和用户行为与编辑器内统一)
2025-04-15 07:02:51 +00:00
aki-chang-dev
a8cb48da5d chore(android): fix google play action (#11686) 2025-04-15 06:35:24 +00:00
pengx17
575aa3c1c1 fix(editor): rework disable middle click settings for linux (#11556)
fix BS-3028
Unfortunately, I don't find out a way to disable this behavior on ff linux
2025-04-15 04:44:26 +00:00
CatsJuice
4011214451 fix(ios): avoid keyboard covering dialog (#11681)
close PD-2540
2025-04-15 04:30:19 +00:00
L-Sun
6f35021f22 chore(editor): update github block ui (#11690)
Close [BS-2651](https://linear.app/affine-design/issue/BS-2651/github-embed-block的样式修复)
2025-04-15 04:15:00 +00:00
darkskygit
84ff54f9d7 feat(server): make slide audio transcript parallel (#11692) 2025-04-15 03:59:23 +00:00
darkskygit
ad712da07f fix(server): slide audio override (#11688) 2025-04-15 03:59:23 +00:00
darkskygit
f2f1a10715 fix(server): initial user plan (#11687) 2025-04-15 03:59:22 +00:00
LongYinan
5bb67e66c2 docs: format releases.md 2025-04-15 11:37:39 +08:00
glitched-w0rld
2b9ccf8fcf docs: improve grammar of contributing releases.md (#10032) 2025-04-15 10:26:34 +08:00
renovate
aaa81e7d12 chore: bump up all non-major dependencies (#11670)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@ai-sdk/google](https://sdk.vercel.ai/docs) ([source](https://redirect.github.com/vercel/ai)) | [`1.2.10` -> `1.2.11`](https://renovatebot.com/diffs/npm/@ai-sdk%2fgoogle/1.2.10/1.2.11) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@ai-sdk%2fgoogle/1.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@ai-sdk%2fgoogle/1.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@ai-sdk%2fgoogle/1.2.10/1.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@ai-sdk%2fgoogle/1.2.10/1.2.11?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@ai-sdk/openai](https://sdk.vercel.ai/docs) ([source](https://redirect.github.com/vercel/ai)) | [`1.3.10` -> `1.3.12`](https://renovatebot.com/diffs/npm/@ai-sdk%2fopenai/1.3.10/1.3.12) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@ai-sdk%2fopenai/1.3.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@ai-sdk%2fopenai/1.3.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@ai-sdk%2fopenai/1.3.10/1.3.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@ai-sdk%2fopenai/1.3.10/1.3.12?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@ai-sdk/perplexity](https://sdk.vercel.ai/docs) ([source](https://redirect.github.com/vercel/ai)) | [`1.1.6` -> `1.1.7`](https://renovatebot.com/diffs/npm/@ai-sdk%2fperplexity/1.1.6/1.1.7) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@ai-sdk%2fperplexity/1.1.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@ai-sdk%2fperplexity/1.1.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@ai-sdk%2fperplexity/1.1.6/1.1.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@ai-sdk%2fperplexity/1.1.6/1.1.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@swc/core](https://swc.rs) ([source](https://redirect.github.com/swc-project/swc)) | [`1.11.20` -> `1.11.21`](https://renovatebot.com/diffs/npm/@swc%2fcore/1.11.20/1.11.21) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@swc%2fcore/1.11.21?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@swc%2fcore/1.11.21?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@swc%2fcore/1.11.20/1.11.21?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@swc%2fcore/1.11.20/1.11.21?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@tailwindcss/postcss](https://tailwindcss.com) ([source](https://redirect.github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/@tailwindcss-postcss)) | [`4.1.3` -> `4.1.4`](https://renovatebot.com/diffs/npm/@tailwindcss%2fpostcss/4.1.3/4.1.4) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@tailwindcss%2fpostcss/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@tailwindcss%2fpostcss/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@tailwindcss%2fpostcss/4.1.3/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@tailwindcss%2fpostcss/4.1.3/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@tailwindcss/vite](https://tailwindcss.com) ([source](https://redirect.github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/@tailwindcss-vite)) | [`4.1.3` -> `4.1.4`](https://renovatebot.com/diffs/npm/@tailwindcss%2fvite/4.1.3/4.1.4) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@tailwindcss%2fvite/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@tailwindcss%2fvite/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@tailwindcss%2fvite/4.1.3/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@tailwindcss%2fvite/4.1.3/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@tanstack/react-table](https://tanstack.com/table) ([source](https://redirect.github.com/TanStack/table/tree/HEAD/packages/react-table)) | [`8.21.2` -> `8.21.3`](https://renovatebot.com/diffs/npm/@tanstack%2freact-table/8.21.2/8.21.3) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@tanstack%2freact-table/8.21.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@tanstack%2freact-table/8.21.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@tanstack%2freact-table/8.21.2/8.21.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@tanstack%2freact-table/8.21.2/8.21.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@types/react](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react) ([source](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react)) | [`19.1.1` -> `19.1.2`](https://renovatebot.com/diffs/npm/@types%2freact/19.1.1/19.1.2) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@types%2freact/19.1.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@types%2freact/19.1.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@types%2freact/19.1.1/19.1.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@types%2freact/19.1.1/19.1.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [ai](https://sdk.vercel.ai/docs) ([source](https://redirect.github.com/vercel/ai)) | [`4.3.5` -> `4.3.6`](https://renovatebot.com/diffs/npm/ai/4.3.5/4.3.6) | [![age](https://developer.mend.io/api/mc/badges/age/npm/ai/4.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/ai/4.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/ai/4.3.5/4.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/ai/4.3.5/4.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [react-day-picker](https://daypicker.dev) ([source](https://redirect.github.com/gpbl/react-day-picker)) | [`9.6.6` -> `9.6.7`](https://renovatebot.com/diffs/npm/react-day-picker/9.6.6/9.6.7) | [![age](https://developer.mend.io/api/mc/badges/age/npm/react-day-picker/9.6.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/react-day-picker/9.6.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/react-day-picker/9.6.6/9.6.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/react-day-picker/9.6.6/9.6.7?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [tailwindcss](https://tailwindcss.com) ([source](https://redirect.github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss)) | [`4.1.3` -> `4.1.4`](https://renovatebot.com/diffs/npm/tailwindcss/4.1.3/4.1.4) | [![age](https://developer.mend.io/api/mc/badges/age/npm/tailwindcss/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/tailwindcss/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/tailwindcss/4.1.3/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/tailwindcss/4.1.3/4.1.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [typescript-eslint](https://typescript-eslint.io/packages/typescript-eslint) ([source](https://redirect.github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/typescript-eslint)) | [`8.29.1` -> `8.30.1`](https://renovatebot.com/diffs/npm/typescript-eslint/8.29.1/8.30.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/typescript-eslint/8.30.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/typescript-eslint/8.30.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/typescript-eslint/8.29.1/8.30.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/typescript-eslint/8.29.1/8.30.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [yarn](https://redirect.github.com/yarnpkg/berry) ([source](https://redirect.github.com/yarnpkg/berry/tree/HEAD/packages/yarnpkg-cli)) | [`4.9.0` -> `4.9.1`](https://renovatebot.com/diffs/npm/yarn/4.9.0/4.9.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@yarnpkg%2fcli/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@yarnpkg%2fcli/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@yarnpkg%2fcli/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@yarnpkg%2fcli/4.9.0/4.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>vercel/ai (@&#8203;ai-sdk/google)</summary>

### [`v1.2.11`](https://redirect.github.com/vercel/ai/releases/tag/%40ai-sdk/google%401.2.11)

[Compare Source](https://redirect.github.com/vercel/ai/compare/@ai-sdk/google@1.2.10...@ai-sdk/google@1.2.11)

##### Patch Changes

-   Updated dependencies \[[`beef951`](https://redirect.github.com/vercel/ai/commit/beef951)]
    -   [@&#8203;ai-sdk/provider](https://redirect.github.com/ai-sdk/provider)[@&#8203;1](https://redirect.github.com/1).1.3
    -   [@&#8203;ai-sdk/provider-utils](https://redirect.github.com/ai-sdk/provider-utils)[@&#8203;2](https://redirect.github.com/2).2.7

</details>

<details>
<summary>swc-project/swc (@&#8203;swc/core)</summary>

### [`v1.11.21`](https://redirect.github.com/swc-project/swc/blob/HEAD/CHANGELOG.md#11121---2025-04-14)

[Compare Source](https://redirect.github.com/swc-project/swc/compare/v1.11.20...v1.11.21)

##### Bug Fixes

-   **(es/helpers)** Sync tslib `_ts_generator` implementation ([#&#8203;10366](https://redirect.github.com/swc-project/swc/issues/10366)) ([d3fb992](d3fb992a2f))

-   **(es/proposal)** Fix scope of declarations for `explicit-resource-management` ([#&#8203;10362](https://redirect.github.com/swc-project/swc/issues/10362)) ([eb7f7e9](eb7f7e9ff9))

-   **(ts/fast-strip)** Increase Wasm stack size ([#&#8203;10359](https://redirect.github.com/swc-project/swc/issues/10359)) ([6d444a5](6d444a5592))

##### Miscellaneous Tasks

-   **(es/parser)** Remove useless check ([#&#8203;10363](https://redirect.github.com/swc-project/swc/issues/10363)) ([0f6a8c3](0f6a8c3f3d))

##### Performance

-   **(es/parser)** Reduce string comparison ([#&#8203;10355](https://redirect.github.com/swc-project/swc/issues/10355)) ([21789c4](21789c4077))

-   **(es/parser)** Add initial capacitity for some vectors ([#&#8203;10361](https://redirect.github.com/swc-project/swc/issues/10361)) ([7b7b50e](7b7b50e6cd))

-   **(es/parser)** Reduce clone of token contexts ([#&#8203;10364](https://redirect.github.com/swc-project/swc/issues/10364)) ([3ab47b2](3ab47b291f))

-   **(es/parser)** Use `bitflags` to reduce parser context size ([#&#8203;10367](https://redirect.github.com/swc-project/swc/issues/10367)) ([a2d3596](a2d35960ad))

-   **(es/parser)** Replace byte arguments with generics ([#&#8203;10370](https://redirect.github.com/swc-project/swc/issues/10370)) ([68f7667](68f76679b4))

-   **(es/parser)** Use `arrayvec` and unsafe `push` to optimize escaped string parsing ([#&#8203;10369](https://redirect.github.com/swc-project/swc/issues/10369)) ([e12ae1c](e12ae1c994))

</details>

<details>
<summary>tailwindlabs/tailwindcss (@&#8203;tailwindcss/postcss)</summary>

### [`v4.1.4`](https://redirect.github.com/tailwindlabs/tailwindcss/blob/HEAD/CHANGELOG.md#414---2025-04-14)

[Compare Source](https://redirect.github.com/tailwindlabs/tailwindcss/compare/v4.1.3...v4.1.4)

##### Added

-   Add experimental `@tailwindcss/oxide-wasm32-wasi` target for running Tailwind in browser environments like StackBlitz ([#&#8203;17558](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17558))

##### Fixed

-   Ensure `color-mix(…)` polyfills do not cause used CSS variables to be removed ([#&#8203;17555](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17555))
-   Ensure `color-mix(…)` polyfills create fallbacks for theme variables that reference other theme variables ([#&#8203;17562](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17562))
-   Fix brace expansion in declining ranges like `{10..0..5}` and `{0..10..-5}` ([#&#8203;17591](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17591))
-   Work around a Chrome rendering bug when using the `skew-*` utilities ([#&#8203;17627](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17627))
-   Ensure container query variant names can contain hyphens ([#&#8203;17628](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17628))
-   Ensure `shadow-inherit`, `inset-shadow-inherit`, `drop-shadow-inherit`, and `text-shadow-inherit` inherit the shadow color ([#&#8203;17647](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17647))
-   Ensure compatibility with array tuples used in `fontSize` JS theme keys ([#&#8203;17630](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17630))
-   Ensure folders with binary file extensions in their names are scanned for utilities ([#&#8203;17595](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17595))
-   Upgrade: Convert `fontSize` array tuple syntax to CSS theme variables ([#&#8203;17630](https://redirect.github.com/tailwindlabs/tailwindcss/pull/17630))

</details>

<details>
<summary>TanStack/table (@&#8203;tanstack/react-table)</summary>

### [`v8.21.3`](https://redirect.github.com/TanStack/table/releases/tag/v8.21.3)

[Compare Source](https://redirect.github.com/TanStack/table/compare/v8.21.2...v8.21.3)

Version 8.21.3 - 4/14/25, 8:19 PM

#### Changes

##### Fix

-   table-core: use right Document instance on getResizeHandler (column-sizing feature) ([#&#8203;5989](https://redirect.github.com/TanStack/table/issues/5989)) ([`54ce673`](https://redirect.github.com/TanStack/table/commit/54ce673)) by [@&#8203;riccardoperra](https://redirect.github.com/riccardoperra)

##### Docs

-   fix all 158 broken links ([#&#8203;5972](https://redirect.github.com/TanStack/table/issues/5972)) ([`f7bf6f1`](https://redirect.github.com/TanStack/table/commit/f7bf6f1)) by [@&#8203;kisaragi-hiu](https://redirect.github.com/kisaragi-hiu)
-   add vue example for grouping ([#&#8203;5941](https://redirect.github.com/TanStack/table/issues/5941)) ([`3efa59c`](https://redirect.github.com/TanStack/table/commit/3efa59c)) by Harshil Patel

#### Packages

-   [@&#8203;tanstack/table-core](https://redirect.github.com/tanstack/table-core)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/angular-table](https://redirect.github.com/tanstack/angular-table)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/lit-table](https://redirect.github.com/tanstack/lit-table)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/qwik-table](https://redirect.github.com/tanstack/qwik-table)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/react-table](https://redirect.github.com/tanstack/react-table)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/solid-table](https://redirect.github.com/tanstack/solid-table)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/svelte-table](https://redirect.github.com/tanstack/svelte-table)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/vue-table](https://redirect.github.com/tanstack/vue-table)[@&#8203;8](https://redirect.github.com/8).21.3
-   [@&#8203;tanstack/react-table-devtools](https://redirect.github.com/tanstack/react-table-devtools)[@&#8203;8](https://redirect.github.com/8).21.3

</details>

<details>
<summary>gpbl/react-day-picker (react-day-picker)</summary>

### [`v9.6.7`](https://redirect.github.com/gpbl/react-day-picker/releases/tag/v9.6.7)

[Compare Source](https://redirect.github.com/gpbl/react-day-picker/compare/v9.6.6...v9.6.7)

Improved handling of timezones, fixed alignment with the Left/Right navigation icons.

#### What's Changed

-   fix: improve left/right icon alignment by [@&#8203;AlecRust](https://redirect.github.com/AlecRust) in [https://github.com/gpbl/react-day-picker/pull/2734](https://redirect.github.com/gpbl/react-day-picker/pull/2734)
-   fix: prevent timezone override when `initialMonth` is `Date` type by [@&#8203;lovebuizel](https://redirect.github.com/lovebuizel) in [https://github.com/gpbl/react-day-picker/pull/2737](https://redirect.github.com/gpbl/react-day-picker/pull/2737)

#### New Contributors

-   [@&#8203;lovebuizel](https://redirect.github.com/lovebuizel) made their first contribution in [https://github.com/gpbl/react-day-picker/pull/2737](https://redirect.github.com/gpbl/react-day-picker/pull/2737)

**Full Changelog**: https://github.com/gpbl/react-day-picker/compare/v9.6.6...v9.6.7

</details>

<details>
<summary>typescript-eslint/typescript-eslint (typescript-eslint)</summary>

### [`v8.30.1`](https://redirect.github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/typescript-eslint/CHANGELOG.md#8301-2025-04-14)

[Compare Source](https://redirect.github.com/typescript-eslint/typescript-eslint/compare/v8.30.0...v8.30.1)

This was a version bump only for typescript-eslint to align it with other projects, there were no code changes.

You can read about our [versioning strategy](https://main--typescript-eslint.netlify.app/users/versioning) and [releases](https://main--typescript-eslint.netlify.app/users/releases) on our website.

### [`v8.30.0`](https://redirect.github.com/typescript-eslint/typescript-eslint/blob/HEAD/packages/typescript-eslint/CHANGELOG.md#8300-2025-04-14)

[Compare Source](https://redirect.github.com/typescript-eslint/typescript-eslint/compare/v8.29.1...v8.30.0)

This was a version bump only for typescript-eslint to align it with other projects, there were no code changes.

You can read about our [versioning strategy](https://main--typescript-eslint.netlify.app/users/versioning) and [releases](https://main--typescript-eslint.netlify.app/users/releases) on our website.

</details>

<details>
<summary>yarnpkg/berry (yarn)</summary>

### [`v4.9.1`](2b26e3dff6...1908ee79fd)

[Compare Source](2b26e3dff6...1908ee79fd)

</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://redirect.github.com/renovatebot/renovate/discussions) if that's undesired.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-15 02:08:17 +00:00
renovate
b70a0dfbc7 chore: bump up nestjs to v11.0.17 (#11676)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@nestjs/common](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/common)) | [`11.0.16` -> `11.0.17`](https://renovatebot.com/diffs/npm/@nestjs%2fcommon/11.0.16/11.0.17) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcommon/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcommon/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcommon/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcommon/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/core](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/core)) | [`11.0.16` -> `11.0.17`](https://renovatebot.com/diffs/npm/@nestjs%2fcore/11.0.16/11.0.17) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcore/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcore/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcore/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcore/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-express](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-express)) | [`11.0.16` -> `11.0.17`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-express/11.0.16/11.0.17) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-express/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-express/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-express/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-express/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-socket.io](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-socket.io)) | [`11.0.16` -> `11.0.17`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-socket.io/11.0.16/11.0.17) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-socket.io/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-socket.io/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-socket.io/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-socket.io/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/websockets](https://redirect.github.com/nestjs/nest) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/websockets)) | [`11.0.16` -> `11.0.17`](https://renovatebot.com/diffs/npm/@nestjs%2fwebsockets/11.0.16/11.0.17) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fwebsockets/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fwebsockets/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fwebsockets/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fwebsockets/11.0.16/11.0.17?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>nestjs/nest (@&#8203;nestjs/common)</summary>

### [`v11.0.17`](https://redirect.github.com/nestjs/nest/compare/v11.0.16...f8a171c4cb3f663a7e949fdc8fe1e4c9b49640e6)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.16...v11.0.17)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/core)</summary>

### [`v11.0.17`](https://redirect.github.com/nestjs/nest/compare/v11.0.16...f8a171c4cb3f663a7e949fdc8fe1e4c9b49640e6)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.16...v11.0.17)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-express)</summary>

### [`v11.0.17`](https://redirect.github.com/nestjs/nest/compare/v11.0.16...f8a171c4cb3f663a7e949fdc8fe1e4c9b49640e6)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.16...v11.0.17)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-socket.io)</summary>

### [`v11.0.17`](https://redirect.github.com/nestjs/nest/compare/v11.0.16...v11.0.17)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.16...v11.0.17)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/websockets)</summary>

### [`v11.0.17`](https://redirect.github.com/nestjs/nest/compare/v11.0.16...v11.0.17)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.16...v11.0.17)

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about these updates again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-15 01:54:22 +00:00
Yifeng Wang
594e896f74 Merge pull request #11661 from toeverything/0414/vtr_test_layout
test(editor): add tests for turbo renderer layout cache
2025-04-15 09:46:14 +08:00
Yifeng Wang
760a689c07 Merge branch 'canary' into 0414/vtr_test_layout 2025-04-15 09:20:25 +08:00
doodlewind
b8967a8a7b test(editor): add tests for turbo renderer state machine (#11659) 2025-04-14 15:54:02 +00:00
Aki Chang
1a2d6f25be fix(android): nbstore laod error (#11674) 2025-04-14 17:19:14 +08:00
Yifeng Wang
e9d04de399 test(editor): add tests for turbo renderer layout cache 2025-04-14 17:06:13 +08:00
Yifeng Wang
e68947c792 fix(editor): integration vitest config warning 2025-04-14 17:04:57 +08:00
Yifeng Wang
2cd0e75810 fix: flaky 2025-04-14 17:04:22 +08:00
doodlewind
6457c979f5 test(editor): add tests for turbo renderer state machine (#11659) 2025-04-14 17:01:27 +08:00
donteatfriedrice
7aa87de5f7 fix(editor): markdown code preprocessor should handle link correctly (#11671)
Close [BS-3117](https://linear.app/affine-design/issue/BS-3117/代码粘贴后出现多余的-和-符号)
2025-04-14 08:28:43 +00:00
Saul-Mirone
efecce9bf2 test(editor): enable basic test for cross platform (#11667) 2025-04-14 07:36:56 +00:00
pengx17
ee15b364d1 fix(electron): use CG* instead of NS* (#11668)
I encounter the following error when developing locally. Not sure if the current PR is the correct fix.

```
thread '<unnamed>' panicked at packages/frontend/native/media_capture/src/macos/screen_capture_kit.rs:253:11:
invalid message send to -[NSImage initWithSize:]: expected argument at index 0 to have type code '{CGSize=dd}', but found '{NSSize=dd}'
```
2025-04-14 07:21:49 +00:00
renovate
2db7dea46f chore: bump up all non-major dependencies (#11618)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence | Type | Update |
|---|---|---|---|---|---|---|---|
| [@ai-sdk/openai](https://sdk.vercel.ai/docs) ([source](https://redirect.github.com/vercel/ai)) | [`1.3.9` -> `1.3.10`](https://renovatebot.com/diffs/npm/@ai-sdk%2fopenai/1.3.9/1.3.10) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@ai-sdk%2fopenai/1.3.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@ai-sdk%2fopenai/1.3.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@ai-sdk%2fopenai/1.3.9/1.3.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@ai-sdk%2fopenai/1.3.9/1.3.10?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [@aws-sdk/client-s3](https://redirect.github.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3) ([source](https://redirect.github.com/aws/aws-sdk-js-v3/tree/HEAD/clients/client-s3)) | [`3.782.0` -> `3.787.0`](https://renovatebot.com/diffs/npm/@aws-sdk%2fclient-s3/3.782.0/3.787.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@aws-sdk%2fclient-s3/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@aws-sdk%2fclient-s3/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@aws-sdk%2fclient-s3/3.782.0/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@aws-sdk%2fclient-s3/3.782.0/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [@aws-sdk/s3-request-presigner](https://redirect.github.com/aws/aws-sdk-js-v3/tree/main/packages/s3-request-presigner) ([source](https://redirect.github.com/aws/aws-sdk-js-v3/tree/HEAD/packages/s3-request-presigner)) | [`3.782.0` -> `3.787.0`](https://renovatebot.com/diffs/npm/@aws-sdk%2fs3-request-presigner/3.782.0/3.787.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@aws-sdk%2fs3-request-presigner/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@aws-sdk%2fs3-request-presigner/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@aws-sdk%2fs3-request-presigner/3.782.0/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@aws-sdk%2fs3-request-presigner/3.782.0/3.787.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [@faker-js/faker](https://fakerjs.dev) ([source](https://redirect.github.com/faker-js/faker)) | [`9.6.0` -> `9.7.0`](https://renovatebot.com/diffs/npm/@faker-js%2ffaker/9.6.0/9.7.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@faker-js%2ffaker/9.7.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@faker-js%2ffaker/9.7.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@faker-js%2ffaker/9.6.0/9.7.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@faker-js%2ffaker/9.6.0/9.7.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | minor |
| [@lit/context](https://lit.dev/) ([source](https://redirect.github.com/lit/lit/tree/HEAD/packages/context)) | [`1.1.4` -> `1.1.5`](https://renovatebot.com/diffs/npm/@lit%2fcontext/1.1.4/1.1.5) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@lit%2fcontext/1.1.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@lit%2fcontext/1.1.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@lit%2fcontext/1.1.4/1.1.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@lit%2fcontext/1.1.4/1.1.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [@smarttools/eslint-plugin-rxjs](https://redirect.github.com/DaveMBush/eslint-plugin-rxjs) | [`1.0.18` -> `1.0.19`](https://renovatebot.com/diffs/npm/@smarttools%2feslint-plugin-rxjs/1.0.18/1.0.19) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@smarttools%2feslint-plugin-rxjs/1.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@smarttools%2feslint-plugin-rxjs/1.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@smarttools%2feslint-plugin-rxjs/1.0.18/1.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@smarttools%2feslint-plugin-rxjs/1.0.18/1.0.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | patch |
| [@swc/core](https://swc.rs) ([source](https://redirect.github.com/swc-project/swc)) | [`1.11.18` -> `1.11.20`](https://renovatebot.com/diffs/npm/@swc%2fcore/1.11.18/1.11.20) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@swc%2fcore/1.11.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@swc%2fcore/1.11.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@swc%2fcore/1.11.18/1.11.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@swc%2fcore/1.11.18/1.11.20?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | patch |
| [@types/node](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node) ([source](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)) | [`22.14.0` -> `22.14.1`](https://renovatebot.com/diffs/npm/@types%2fnode/22.14.0/22.14.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@types%2fnode/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@types%2fnode/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@types%2fnode/22.14.0/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@types%2fnode/22.14.0/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [@types/node](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node) ([source](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)) | [`22.14.0` -> `22.14.1`](https://renovatebot.com/diffs/npm/@types%2fnode/22.14.0/22.14.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@types%2fnode/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@types%2fnode/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@types%2fnode/22.14.0/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@types%2fnode/22.14.0/22.14.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | patch |
| [@types/react](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react) ([source](https://redirect.github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react)) | [`19.1.0` -> `19.1.1`](https://renovatebot.com/diffs/npm/@types%2freact/19.1.0/19.1.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@types%2freact/19.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@types%2freact/19.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@types%2freact/19.1.0/19.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@types%2freact/19.1.0/19.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | patch |
| [ai](https://sdk.vercel.ai/docs) ([source](https://redirect.github.com/vercel/ai)) | [`4.3.4` -> `4.3.5`](https://renovatebot.com/diffs/npm/ai/4.3.4/4.3.5) | [![age](https://developer.mend.io/api/mc/badges/age/npm/ai/4.3.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/ai/4.3.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/ai/4.3.4/4.3.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/ai/4.3.4/4.3.5?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [animejs](https://animejs.com) ([source](https://redirect.github.com/juliangarnier/anime)) | [`4.0.0` -> `4.0.1`](https://renovatebot.com/diffs/npm/animejs/4.0.0/4.0.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/animejs/4.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/animejs/4.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/animejs/4.0.0/4.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/animejs/4.0.0/4.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [anyhow](https://redirect.github.com/dtolnay/anyhow) | `1.0.97` -> `1.0.98` | [![age](https://developer.mend.io/api/mc/badges/age/crate/anyhow/1.0.98?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/crate/anyhow/1.0.98?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/crate/anyhow/1.0.97/1.0.98?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/crate/anyhow/1.0.97/1.0.98?slim=true)](https://docs.renovatebot.com/merge-confidence/) | workspace.dependencies | patch |
| [cc](https://redirect.github.com/rust-lang/cc-rs) | `1.2.18` -> `1.2.19` | [![age](https://developer.mend.io/api/mc/badges/age/crate/cc/1.2.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/crate/cc/1.2.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/crate/cc/1.2.18/1.2.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/crate/cc/1.2.18/1.2.19?slim=true)](https://docs.renovatebot.com/merge-confidence/) | build-dependencies | patch |
| [dotenv](https://redirect.github.com/motdotla/dotenv) | [`16.4.7` -> `16.5.0`](https://renovatebot.com/diffs/npm/dotenv/16.4.7/16.5.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/dotenv/16.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/dotenv/16.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/dotenv/16.4.7/16.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/dotenv/16.4.7/16.5.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [html-validate](https://html-validate.org) ([source](https://gitlab.com/html-validate/html-validate)) | [`9.5.2` -> `9.5.3`](https://renovatebot.com/diffs/npm/html-validate/9.5.2/9.5.3) | [![age](https://developer.mend.io/api/mc/badges/age/npm/html-validate/9.5.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/html-validate/9.5.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/html-validate/9.5.2/9.5.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/html-validate/9.5.2/9.5.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [ioredis](https://redirect.github.com/luin/ioredis) | [`5.6.0` -> `5.6.1`](https://renovatebot.com/diffs/npm/ioredis/5.6.0/5.6.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/ioredis/5.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/ioredis/5.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/ioredis/5.6.0/5.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/ioredis/5.6.0/5.6.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [jotai](https://redirect.github.com/pmndrs/jotai) | [`2.12.2` -> `2.12.3`](https://renovatebot.com/diffs/npm/jotai/2.12.2/2.12.3) | [![age](https://developer.mend.io/api/mc/badges/age/npm/jotai/2.12.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/jotai/2.12.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/jotai/2.12.2/2.12.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/jotai/2.12.2/2.12.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [lib0](https://redirect.github.com/dmonad/lib0) | [`0.2.102` -> `0.2.104`](https://renovatebot.com/diffs/npm/lib0/0.2.102/0.2.104) | [![age](https://developer.mend.io/api/mc/badges/age/npm/lib0/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/lib0/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/lib0/0.2.102/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/lib0/0.2.102/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [lib0](https://redirect.github.com/dmonad/lib0) | [`0.2.102` -> `0.2.104`](https://renovatebot.com/diffs/npm/lib0/0.2.102/0.2.104) | [![age](https://developer.mend.io/api/mc/badges/age/npm/lib0/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/lib0/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/lib0/0.2.102/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/lib0/0.2.102/0.2.104?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | patch |
| [lint-staged](https://redirect.github.com/lint-staged/lint-staged) | [`15.5.0` -> `15.5.1`](https://renovatebot.com/diffs/npm/lint-staged/15.5.0/15.5.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/lint-staged/15.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/lint-staged/15.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/lint-staged/15.5.0/15.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/lint-staged/15.5.0/15.5.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | patch |
| [lit](https://lit.dev/) ([source](https://redirect.github.com/lit/lit/tree/HEAD/packages/lit)) | [`3.2.1` -> `3.3.0`](https://renovatebot.com/diffs/npm/lit/3.2.1/3.3.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/lit/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/lit/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/lit/3.2.1/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/lit/3.2.1/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [lit-html](https://lit.dev/) ([source](https://redirect.github.com/lit/lit/tree/HEAD/packages/lit-html)) | [`3.2.1` -> `3.3.0`](https://renovatebot.com/diffs/npm/lit-html/3.2.1/3.3.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/lit-html/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/lit-html/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/lit-html/3.2.1/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/lit-html/3.2.1/3.3.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [lucide-react](https://lucide.dev) ([source](https://redirect.github.com/lucide-icons/lucide/tree/HEAD/packages/lucide-react)) | [`^0.487.0` -> `^0.488.0`](https://renovatebot.com/diffs/npm/lucide-react/0.487.0/0.488.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/lucide-react/0.488.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/lucide-react/0.488.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/lucide-react/0.487.0/0.488.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/lucide-react/0.487.0/0.488.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [msw](https://mswjs.io) ([source](https://redirect.github.com/mswjs/msw)) | [`2.7.3` -> `2.7.4`](https://renovatebot.com/diffs/npm/msw/2.7.3/2.7.4) | [![age](https://developer.mend.io/api/mc/badges/age/npm/msw/2.7.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/msw/2.7.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/msw/2.7.3/2.7.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/msw/2.7.3/2.7.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | devDependencies | patch |
| [nodemailer](https://nodemailer.com/) ([source](https://redirect.github.com/nodemailer/nodemailer)) | [`6.10.0` -> `6.10.1`](https://renovatebot.com/diffs/npm/nodemailer/6.10.0/6.10.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/nodemailer/6.10.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/nodemailer/6.10.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/nodemailer/6.10.0/6.10.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/nodemailer/6.10.0/6.10.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [react-day-picker](https://daypicker.dev) ([source](https://redirect.github.com/gpbl/react-day-picker)) | [`9.6.5` -> `9.6.6`](https://renovatebot.com/diffs/npm/react-day-picker/9.6.5/9.6.6) | [![age](https://developer.mend.io/api/mc/badges/age/npm/react-day-picker/9.6.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/react-day-picker/9.6.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/react-day-picker/9.6.5/9.6.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/react-day-picker/9.6.5/9.6.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [sqlx](https://redirect.github.com/launchbadge/sqlx) | `0.8.3` -> `0.8.4` | [![age](https://developer.mend.io/api/mc/badges/age/crate/sqlx/0.8.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/crate/sqlx/0.8.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/crate/sqlx/0.8.3/0.8.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/crate/sqlx/0.8.3/0.8.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | workspace.dependencies | patch |
| [com.google.devtools.ksp](https://goo.gle/ksp) ([source](https://redirect.github.com/google/ksp)) | `2.1.20-1.0.32` -> `2.1.20-2.0.0` | [![age](https://developer.mend.io/api/mc/badges/age/maven/com.google.devtools.ksp:com.google.devtools.ksp.gradle.plugin/2.1.20-2.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/com.google.devtools.ksp:com.google.devtools.ksp.gradle.plugin/2.1.20-2.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/com.google.devtools.ksp:com.google.devtools.ksp.gradle.plugin/2.1.20-1.0.32/2.1.20-2.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/com.google.devtools.ksp:com.google.devtools.ksp.gradle.plugin/2.1.20-1.0.32/2.1.20-2.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | plugin | patch |
| [org.jetbrains.kotlinx:kotlinx-serialization-json](https://redirect.github.com/Kotlin/kotlinx.serialization) | `1.8.0` -> `1.8.1` | [![age](https://developer.mend.io/api/mc/badges/age/maven/org.jetbrains.kotlinx:kotlinx-serialization-json/1.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/org.jetbrains.kotlinx:kotlinx-serialization-json/1.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/org.jetbrains.kotlinx:kotlinx-serialization-json/1.8.0/1.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/org.jetbrains.kotlinx:kotlinx-serialization-json/1.8.0/1.8.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [org.jetbrains.kotlinx:kotlinx-coroutines-android](https://redirect.github.com/Kotlin/kotlinx.coroutines) | `1.10.1` -> `1.10.2` | [![age](https://developer.mend.io/api/mc/badges/age/maven/org.jetbrains.kotlinx:kotlinx-coroutines-android/1.10.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/org.jetbrains.kotlinx:kotlinx-coroutines-android/1.10.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/org.jetbrains.kotlinx:kotlinx-coroutines-android/1.10.1/1.10.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/org.jetbrains.kotlinx:kotlinx-coroutines-android/1.10.1/1.10.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | patch |
| [com.android.tools.build:gradle](https://developer.android.com/studio/build) ([source](https://android.googlesource.com/platform/tools/base)) | `8.7.2` -> `8.9.1` | [![age](https://developer.mend.io/api/mc/badges/age/maven/com.android.tools.build:gradle/8.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/com.android.tools.build:gradle/8.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/com.android.tools.build:gradle/8.7.2/8.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/com.android.tools.build:gradle/8.7.2/8.9.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [androidx.core:core-ktx](https://developer.android.com/jetpack/androidx/releases/core#1.16.0) ([source](https://cs.android.com/androidx/platform/frameworks/support)) | `1.15.0` -> `1.16.0` | [![age](https://developer.mend.io/api/mc/badges/age/maven/androidx.core:core-ktx/1.16.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/androidx.core:core-ktx/1.16.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/androidx.core:core-ktx/1.15.0/1.16.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/androidx.core:core-ktx/1.15.0/1.16.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |
| [androidx.compose:compose-bom](https://developer.android.com/jetpack) | `2025.03.01` -> `2025.04.00` | [![age](https://developer.mend.io/api/mc/badges/age/maven/androidx.compose:compose-bom/2025.04.00?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/androidx.compose:compose-bom/2025.04.00?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/androidx.compose:compose-bom/2025.03.01/2025.04.00?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/androidx.compose:compose-bom/2025.03.01/2025.04.00?slim=true)](https://docs.renovatebot.com/merge-confidence/) | dependencies | minor |

---

### Release Notes

<details>
<summary>vercel/ai (@&#8203;ai-sdk/openai)</summary>

### [`v1.3.10`](https://redirect.github.com/vercel/ai/releases/tag/%40ai-sdk/openai%401.3.10)

[Compare Source](https://redirect.github.com/vercel/ai/compare/@ai-sdk/openai@1.3.9...@ai-sdk/openai@1.3.10)

##### Patch Changes

-   [`dbe53e7`](https://redirect.github.com/vercel/ai/commit/dbe53e7): adding support for gpt-4o-search-preview and handling unsupported parameters
-   [`84ffaba`](https://redirect.github.com/vercel/ai/commit/84ffaba): fix: propagate openai transcription fixes

</details>

<details>
<summary>aws/aws-sdk-js-v3 (@&#8203;aws-sdk/client-s3)</summary>

### [`v3.787.0`](https://redirect.github.com/aws/aws-sdk-js-v3/blob/HEAD/clients/client-s3/CHANGELOG.md#37870-2025-04-10)

[Compare Source](https://redirect.github.com/aws/aws-sdk-js-v3/compare/v3.782.0...v3.787.0)

**Note:** Version bump only for package [@&#8203;aws-sdk/client-s3](https://redirect.github.com/aws-sdk/client-s3)

</details>

<details>
<summary>aws/aws-sdk-js-v3 (@&#8203;aws-sdk/s3-request-presigner)</summary>

### [`v3.787.0`](https://redirect.github.com/aws/aws-sdk-js-v3/blob/HEAD/packages/s3-request-presigner/CHANGELOG.md#37870-2025-04-10)

[Compare Source](https://redirect.github.com/aws/aws-sdk-js-v3/compare/v3.782.0...v3.787.0)

**Note:** Version bump only for package [@&#8203;aws-sdk/s3-request-presigner](https://redirect.github.com/aws-sdk/s3-request-presigner)

</details>

<details>
<summary>faker-js/faker (@&#8203;faker-js/faker)</summary>

### [`v9.7.0`](https://redirect.github.com/faker-js/faker/blob/HEAD/CHANGELOG.md#970-2025-04-13)

[Compare Source](https://redirect.github.com/faker-js/faker/compare/v9.6.0...v9.7.0)

##### New Locales

-   **locale:** Add bn_BD locale ([#&#8203;3439](https://redirect.github.com/faker-js/faker/issues/3439)) ([fef0ad7](fef0ad7859))
-   **locale:** add cy locale, start with date ([#&#8203;3462](https://redirect.github.com/faker-js/faker/issues/3462)) ([f70a6f7](f70a6f7a65))
-   **locale:** add finance support for ja locale ([#&#8203;3449](https://redirect.github.com/faker-js/faker/issues/3449)) ([b2c5298](b2c5298c94))
-   **locale:** add localize sex support for zh_CN & zh_TW ([#&#8203;3450](https://redirect.github.com/faker-js/faker/issues/3450)) ([048c325](048c32581b))
-   **locale:** add Tamil language support ([#&#8203;3468](https://redirect.github.com/faker-js/faker/issues/3468)) ([cdf6dc4](cdf6dc4a97))

##### Bug Fixes

-   **airline:** Air France and KLM Royal Dutch Airlines ([#&#8203;3440](https://redirect.github.com/faker-js/faker/issues/3440)) ([8a2d168](8a2d168f62))
-   **iban:** more strict pattern for IE and PS ([#&#8203;3464](https://redirect.github.com/faker-js/faker/issues/3464)) ([7b12056](7b12056713))
-   **locale:** rename ja and zh_CN company affix files ([#&#8203;3448](https://redirect.github.com/faker-js/faker/issues/3448)) ([1e551c5](1e551c5f47))
-   **number:** don't ignore multipleOf in float when min=max ([#&#8203;3417](https://redirect.github.com/faker-js/faker/issues/3417)) ([e4cc4e5](e4cc4e50d1))

</details>

<details>
<summary>lit/lit (@&#8203;lit/context)</summary>

### [`v1.1.5`](https://redirect.github.com/lit/lit/blob/HEAD/packages/context/CHANGELOG.md#115)

[Compare Source](7db8eadb28...@lit/context@1.1.5)

##### Patch Changes

-   [#&#8203;4917](https://redirect.github.com/lit/lit/pull/4917) [`aced5a93`](aced5a93b7) Thanks [@&#8203;djrenren](https://redirect.github.com/djrenren)! - Fixed a bug where initial values were not handled by the [@&#8203;provide](https://redirect.github.com/provide)() decorator
    when using standard decorators ([#&#8203;4675](https://redirect.github.com/lit/lit/issues/4675))
-   Updated dependencies \[[`c9160405`](c9160405de), [`3e2f87f6`](3e2f87f688), [`4824c4ce`](4824c4ce09)]:
    -   [@&#8203;lit/reactive-element](https://redirect.github.com/lit/reactive-element)[@&#8203;2](https://redirect.github.com/2).1.0

</details>

<details>
<summary>DaveMBush/eslint-plugin-rxjs (@&#8203;smarttools/eslint-plugin-rxjs)</summary>

### [`v1.0.19`](https://redirect.github.com/DaveMBush/eslint-plugin-rxjs/releases/tag/v1.0.19): (2025-04-11)

[Compare Source](https://redirect.github.com/DaveMBush/eslint-plugin-rxjs/compare/v1.0.18...v1.0.19)

Fix issue 131

</details>

<details>
<summary>swc-project/swc (@&#8203;swc/core)</summary>

### [`v1.11.20`](https://redirect.github.com/swc-project/swc/blob/HEAD/CHANGELOG.md#11120---2025-04-11)

[Compare Source](https://redirect.github.com/swc-project/swc/compare/v1.11.18...v1.11.20)

##### Bug Fixes

-   **(error_reporters)** Removing unused code to fix clippy check ([#&#8203;10338](https://redirect.github.com/swc-project/swc/issues/10338)) ([5970f93](5970f937f7))

-   **(es/minifier)** Preserve block with block scoped declaration ([#&#8203;10335](https://redirect.github.com/swc-project/swc/issues/10335)) ([a4ac3b7](a4ac3b7188))

-   **(es/parser)** Allow abstract method named `accessor` ([#&#8203;10327](https://redirect.github.com/swc-project/swc/issues/10327)) ([3f71776](3f7177665c))

-   **(es/preset-env)** Consider `browserslist` config if `env.target` is not configured ([#&#8203;8921](https://redirect.github.com/swc-project/swc/issues/8921)) ([a2dc372](a2dc372f9c))

-   **(es/resolver)** Handle using declarations ([#&#8203;10354](https://redirect.github.com/swc-project/swc/issues/10354)) ([dad815c](dad815cee6))

-   fix(es/compat): Remove one promise tick in yield\* ([tc39/ecma262#2819](https://redirect.github.com/tc39/ecma262/issues/2819)) ([#&#8203;10317](https://redirect.github.com/swc-project/swc/issues/10317))

**Related issue:**

-   [babel/babel#14877](https://redirect.github.com/babel/babel/issues/14877)
-   [tc39/ecma262#2819](https://redirect.github.com/tc39/ecma262/issues/2819) ([3fb1950](3fb19505b5))

##### Features

-   **(errors)** Integrate `miette` for enhanced diagnostic reporting ([#&#8203;10241](https://redirect.github.com/swc-project/swc/issues/10241)) ([156c3b1](156c3b1cdc))

-   **(es/codegen)** Support `sourceMap.url` option of `terser` ([#&#8203;10346](https://redirect.github.com/swc-project/swc/issues/10346)) ([566bc7c](566bc7c06e))

-   **(plugin/runner)** Support `pluginEnvVars` ([#&#8203;10318](https://redirect.github.com/swc-project/swc/issues/10318)) ([795fedc](795fedc6ae))

##### Miscellaneous Tasks

-   **(es/helpers)** Update peer dependency version for `@swc/helpers` to `>=0.5.17` ([#&#8203;10321](https://redirect.github.com/swc-project/swc/issues/10321)) ([ddbf3e1](ddbf3e1d8c))

-   **(ide)** Disable RA diagnostics ([#&#8203;10324](https://redirect.github.com/swc-project/swc/issues/10324)) ([fcf280f](fcf280fc62))

##### Performance

-   **(es/ast)** Reduce redundant string comparison for `Atom`s ([#&#8203;10323](https://redirect.github.com/swc-project/swc/issues/10323)) ([3ce9d81](3ce9d8119e))

-   **(es/jsx)** Cache FileName for JSX pass ([#&#8203;9951](https://redirect.github.com/swc-project/swc/issues/9951)) ([#&#8203;10322](https://redirect.github.com/swc-project/swc/issues/10322)) ([9852940](98529404bc))

-   **(es/parser)** Remove redundant `is_ascii` calls ([#&#8203;10334](https://redirect.github.com/swc-project/swc/issues/10334)) ([e66b4d6](e66b4d660c))

-   **(es/parser)** Remove ascii check for no-ascii ([#&#8203;10350](https://redirect.github.com/swc-project/swc/issues/10350)) ([4279b96](4279b96d12))

##### Testing

-   **(es)** Unignore tests and update node to `20` in exec tests ([#&#8203;10348](https://redirect.github.com/swc-project/swc/issues/10348)) ([eee73ce](eee73cec76))

</details>

<details>
<summary>juliangarnier/anime (animejs)</summary>

### [`v4.0.1`](https://redirect.github.com/juliangarnier/anime/releases/tag/v4.0.1)

[Compare Source](https://redirect.github.com/juliangarnier/anime/compare/4.0.0...v4.0.1)

#### fixes

-   Fix `createScope` root param type for `ReactRef` ([#&#8203;971](https://redirect.github.com/juliangarnier/anime/issues/971)) thanks [@&#8203;Jimmydalecleveland](https://redirect.github.com/Jimmydalecleveland)

</details>

<details>
<summary>dtolnay/anyhow (anyhow)</summary>

### [`v1.0.98`](https://redirect.github.com/dtolnay/anyhow/releases/tag/1.0.98)

[Compare Source](https://redirect.github.com/dtolnay/anyhow/compare/1.0.97...1.0.98)

-   Add [`self.into_boxed_dyn_error()`](https://docs.rs/anyhow/1/anyhow/struct.Error.html#method.into_boxed_dyn_error) and [`self.reallocate_into_boxed_dyn_error_without_backtrace()`](https://docs.rs/anyhow/1/anyhow/struct.Error.html#method.reallocate_into_boxed_dyn_error_without_backtrace) methods for anyhow::Error ([#&#8203;415](https://redirect.github.com/dtolnay/anyhow/issues/415))

</details>

<details>
<summary>rust-lang/cc-rs (cc)</summary>

### [`v1.2.19`](https://redirect.github.com/rust-lang/cc-rs/blob/HEAD/CHANGELOG.md#1219---2025-04-11)

[Compare Source](https://redirect.github.com/rust-lang/cc-rs/compare/cc-v1.2.18...cc-v1.2.19)

##### Other

-   Fix musl compilation: Add musl as a prefix fallback ([#&#8203;1455](https://redirect.github.com/rust-lang/cc-rs/pull/1455))

</details>

<details>
<summary>motdotla/dotenv (dotenv)</summary>

### [`v16.5.0`](https://redirect.github.com/motdotla/dotenv/blob/HEAD/CHANGELOG.md#1650-2025-04-07)

[Compare Source](https://redirect.github.com/motdotla/dotenv/compare/v16.4.7...v16.5.0)

##### Added

-   🎉 Added new sponsor [Graphite](https://graphite.dev/?utm_source=github\&utm_medium=repo\&utm_campaign=dotenv) - *the AI developer productivity platform helping teams on GitHub ship higher quality software, faster*.

> \[!TIP]
> **[Become a sponsor](https://redirect.github.com/sponsors/motdotla)**
>
> The dotenvx README is viewed thousands of times DAILY on GitHub and NPM.
> Sponsoring dotenv is a great way to get in front of developers and give back to the developer community at the same time.

##### Changed

-   Remove `_log` method. Use `_debug` [#&#8203;862](https://redirect.github.com/motdotla/dotenv/pull/862)

</details>

<details>
<summary>html-validate/html-validate (html-validate)</summary>

### [`v9.5.3`](https://gitlab.com/html-validate/html-validate/blob/HEAD/CHANGELOG.md#953-2025-04-13)

[Compare Source](https://gitlab.com/html-validate/html-validate/compare/v9.5.2...v9.5.3)

##### Bug Fixes

-   fix crash when aria attribute references id with comma ([fb91b7c](fb91b7c7e7)), closes [#&#8203;299](https://gitlab.com/html-validate/html-validate/issues/299)
-   fix crash when attribute selector `[..]` contains escaped characters ([0c19b82](0c19b8267d))

</details>

<details>
<summary>luin/ioredis (ioredis)</summary>

### [`v5.6.1`](https://redirect.github.com/luin/ioredis/blob/HEAD/CHANGELOG.md#561-2025-04-11)

[Compare Source](https://redirect.github.com/luin/ioredis/compare/v5.6.0...v5.6.1)

##### Bug Fixes

-   adding debug log on cluster.slots initial connection error ([bedcfb5](bedcfb5d4b))

</details>

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

### [`v2.12.3`](https://redirect.github.com/pmndrs/jotai/releases/tag/v2.12.3)

[Compare Source](https://redirect.github.com/pmndrs/jotai/compare/v2.12.2...v2.12.3)

This introduces an internal capability for jotai-devtools.

#### What's Changed

-   fix: expose an internal function for devtools by [@&#8203;dai-shi](https://redirect.github.com/dai-shi) in [https://github.com/pmndrs/jotai/pull/3045](https://redirect.github.com/pmndrs/jotai/pull/3045)
-   fix(react): experimental option to make attaching promise status controllable by [@&#8203;dai-shi](https://redirect.github.com/dai-shi) in [https://github.com/pmndrs/jotai/pull/3026](https://redirect.github.com/pmndrs/jotai/pull/3026)

#### New Contributors

-   [@&#8203;siyou](https://redirect.github.com/siyou) made their first contribution in [https://github.com/pmndrs/jotai/pull/3029](https://redirect.github.com/pmndrs/jotai/pull/3029)

**Full Changelog**: https://github.com/pmndrs/jotai/compare/v2.12.2...v2.12.3

</details>

<details>
<summary>dmonad/lib0 (lib0)</summary>

### [`v0.2.104`](https://redirect.github.com/dmonad/lib0/releases/tag/v0.2.104)

[Compare Source](https://redirect.github.com/dmonad/lib0/compare/v0.2.103...v0.2.104)

-   \[array/bubblesortItem] fix edge case  [`cffe349`](https://redirect.github.com/dmonad/lib0/commit/cffe349)

***

### [`v0.2.103`](https://redirect.github.com/dmonad/lib0/releases/tag/v0.2.103)

[Compare Source](https://redirect.github.com/dmonad/lib0/compare/v0.2.102...v0.2.103)

-   \[array] add bubblesortItem  [`98544a4`](https://redirect.github.com/dmonad/lib0/commit/98544a4)

***

</details>

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

### [`v15.5.1`](https://redirect.github.com/lint-staged/lint-staged/blob/HEAD/CHANGELOG.md#1551)

[Compare Source](https://redirect.github.com/lint-staged/lint-staged/compare/v15.5.0...v15.5.1)

##### Patch Changes

-   [#&#8203;1533](https://redirect.github.com/lint-staged/lint-staged/pull/1533) [`5d53534`](5d53534995) Thanks [@&#8203;iiroj](https://redirect.github.com/iiroj)! - Improve listing of staged files so that *lint-staged* doesn't crash when encountering an uninitialized submodule. This should result in less errors like:

        ✖ Failed to get staged files!

</details>

<details>
<summary>lit/lit (lit)</summary>

### [`v3.3.0`](https://redirect.github.com/lit/lit/blob/HEAD/packages/lit/CHANGELOG.md#330)

[Compare Source](https://redirect.github.com/lit/lit/compare/lit@3.2.1...lit@3.3.0)

##### Minor Changes

-   [#&#8203;4901](https://redirect.github.com/lit/lit/pull/4901) [`c9160405`](c9160405de) Thanks [@&#8203;maxpatiiuk](https://redirect.github.com/maxpatiiuk)! - Dev mode warnings are now emitted on the next microtask after package import, allowing for a wider opportunity to suppress the warnings by consumers.

-   [#&#8203;4934](https://redirect.github.com/lit/lit/pull/4934) [`4824c4ce`](4824c4ce09) - Adds property option for `useDefault`. When set, the initial default value is not considered a change and does *not* reflect when `reflect` is set. In addition, when the attribute is removed, the default value is restored.

##### Patch Changes

-   [#&#8203;4949](https://redirect.github.com/lit/lit/pull/4949) [`3e2f87f6`](3e2f87f688) - fixes inconsistent initial changed properties values

-   [#&#8203;4956](https://redirect.github.com/lit/lit/pull/4956) [`0a9bc720`](0a9bc72016) Thanks [@&#8203;louis-bompart](https://redirect.github.com/louis-bompart)! - Import barrels explicitly for compatibility with modern Node resolution w/ ESM

-   Updated dependencies \[[`c9160405`](c9160405de), [`3e2f87f6`](3e2f87f688), [`4824c4ce`](4824c4ce09), [`0a9bc720`](0a9bc72016)]:
    -   [@&#8203;lit/reactive-element](https://redirect.github.com/lit/reactive-element)[@&#8203;2](https://redirect.github.com/2).1.0
    -   lit-element@4.2.0
    -   lit-html@3.3.0

</details>

<details>
<summary>lit/lit (lit-html)</summary>

### [`v3.3.0`](https://redirect.github.com/lit/lit/blob/HEAD/packages/lit-html/CHANGELOG.md#330)

[Compare Source](https://redirect.github.com/lit/lit/compare/lit-html@3.2.1...lit-html@3.3.0)

##### Minor Changes

-   [#&#8203;4901](https://redirect.github.com/lit/lit/pull/4901) [`c9160405`](c9160405de) Thanks [@&#8203;maxpatiiuk](https://redirect.github.com/maxpatiiuk)! - Dev mode warnings are now emitted on the next microtask after package import, allowing for a wider opportunity to suppress the warnings by consumers.

##### Patch Changes

-   [#&#8203;4956](https://redirect.github.com/lit/lit/pull/4956) [`0a9bc720`](0a9bc72016) Thanks [@&#8203;louis-bompart](https://redirect.github.com/louis-bompart)! - Import barrels explicitly for compatibility with modern Node resolution w/ ESM

</details>

<details>
<summary>lucide-icons/lucide (lucide-react)</summary>

### [`v0.488.0`](https://redirect.github.com/lucide-icons/lucide/releases/tag/0.488.0): Version 0.488.0

[Compare Source](https://redirect.github.com/lucide-icons/lucide/compare/0.487.0...0.488.0)

##### What's Changed

-   docs(readme): fix packages table by [@&#8203;realguse](https://redirect.github.com/realguse) in [https://github.com/lucide-icons/lucide/pull/2976](https://redirect.github.com/lucide-icons/lucide/pull/2976)
-   fix(dev): point urls on packages page to correct page by [@&#8203;briz123](https://redirect.github.com/briz123) in [https://github.com/lucide-icons/lucide/pull/2983](https://redirect.github.com/lucide-icons/lucide/pull/2983)
-   build(deps-dev): bump vite from 5.4.14 to 5.4.15 by [@&#8203;dependabot](https://redirect.github.com/dependabot) in [https://github.com/lucide-icons/lucide/pull/2946](https://redirect.github.com/lucide-icons/lucide/pull/2946)
-   Typo fix for [@&#8203;lucide/astro](https://redirect.github.com/lucide/astro) badge by [@&#8203;dotspencer](https://redirect.github.com/dotspencer) in [https://github.com/lucide-icons/lucide/pull/3004](https://redirect.github.com/lucide-icons/lucide/pull/3004)
-   removed flutter package link by [@&#8203;shamaamahh](https://redirect.github.com/shamaamahh) in [https://github.com/lucide-icons/lucide/pull/2999](https://redirect.github.com/lucide-icons/lucide/pull/2999)
-   feat(ci): added npm package provenance attestation by [@&#8203;jguddas](https://redirect.github.com/jguddas) in [https://github.com/lucide-icons/lucide/pull/3016](https://redirect.github.com/lucide-icons/lucide/pull/3016)
-   fix(icons): changed `text` icon by [@&#8203;jguddas](https://redirect.github.com/jguddas) in [https://github.com/lucide-icons/lucide/pull/3029](https://redirect.github.com/lucide-icons/lucide/pull/3029)
-   fix(icons): changed `letter-text` icon by [@&#8203;jguddas](https://redirect.github.com/jguddas) in [https://github.com/lucide-icons/lucide/pull/3030](https://redirect.github.com/lucide-icons/lucide/pull/3030)
-   fix(icons): changed `text-select` icon by [@&#8203;jguddas](https://redirect.github.com/jguddas) in [https://github.com/lucide-icons/lucide/pull/3028](https://redirect.github.com/lucide-icons/lucide/pull/3028)

##### New Contributors

-   [@&#8203;dotspencer](https://redirect.github.com/dotspencer) made their first contribution in [https://github.com/lucide-icons/lucide/pull/3004](https://redirect.github.com/lucide-icons/lucide/pull/3004)
-   [@&#8203;shamaamahh](https://redirect.github.com/shamaamahh) made their first contribution in [https://github.com/lucide-icons/lucide/pull/2999](https://redirect.github.com/lucide-icons/lucide/pull/2999)

**Full Changelog**: https://github.com/lucide-icons/lucide/compare/0.487.0...0.488.0

</details>

<details>
<summary>mswjs/msw (msw)</summary>

### [`v2.7.4`](https://redirect.github.com/mswjs/msw/releases/tag/v2.7.4)

[Compare Source](https://redirect.github.com/mswjs/msw/compare/v2.7.3...v2.7.4)

#### v2.7.4 (2025-04-12)

##### Bug Fixes

-   resolve relative URLs against `location.href` ([#&#8203;2471](https://redirect.github.com/mswjs/msw/issues/2471)) ([`fa9b07f`](fa9b07f7b9)) [@&#8203;kettanaito](https://redirect.github.com/kettanaito)
-   **graphql:** add `extensions` property to the `GraphQLResponseBody` type ([#&#8203;2468](https://redirect.github.com/mswjs/msw/issues/2468)) ([`827a5dc`](827a5dc055)) [@&#8203;ytoshiki](https://redirect.github.com/ytoshiki)

</details>

<details>
<summary>nodemailer/nodemailer (nodemailer)</summary>

### [`v6.10.1`](https://redirect.github.com/nodemailer/nodemailer/blob/HEAD/CHANGELOG.md#6101-2025-02-06)

[Compare Source](https://redirect.github.com/nodemailer/nodemailer/compare/v6.10.0...v6.10.1)

##### Bug Fixes

-   close correct socket ([a18062c](a18062c04d))

</details>

<details>
<summary>gpbl/react-day-picker (react-day-picker)</summary>

### [`v9.6.6`](https://redirect.github.com/gpbl/react-day-picker/releases/tag/v9.6.6)

[Compare Source](https://redirect.github.com/gpbl/react-day-picker/compare/v9.6.5...v9.6.6)

Includes a fix for `autoFocus` prop not correctly autofocusing the selected day.

#### What's Changed

-   fix: calculateFocusTarget logic by [@&#8203;rodgobbi](https://redirect.github.com/rodgobbi) in [https://github.com/gpbl/react-day-picker/pull/2727](https://redirect.github.com/gpbl/react-day-picker/pull/2727)

**Full Changelog**: https://github.com/gpbl/react-day-picker/compare/v9.6.5...v9.6.6

</details>

<details>
<summary>launchbadge/sqlx (sqlx)</summary>

### [`v0.8.4`](https://redirect.github.com/launchbadge/sqlx/blob/HEAD/CHANGELOG.md#084---2025-04-13)

50 pull requests were merged this release cycle.

As of this release, development of `0.9.0` has begun on `main`.
Barring urgent hotfixes, this is expected to be the last release of `0.8.x`.

##### Added

-   \[[#&#8203;3603]]: Added missing special casing for encoding embedded arrays of custom types \[\[[@&#8203;nico-incubiq](https://redirect.github.com/nico-incubiq)]]
-   \[[#&#8203;3625]]: feat(sqlite): add preupdate hook \[\[[@&#8203;aschey](https://redirect.github.com/aschey)]]
-   \[[#&#8203;3655]]: docs: add example for postgres enums with type TEXT \[\[[@&#8203;tisonkun](https://redirect.github.com/tisonkun)]]
-   \[[#&#8203;3677]]: Add json(nullable) macro attribute \[\[[@&#8203;seanaye](https://redirect.github.com/seanaye)]]
-   \[[#&#8203;3687]]: Derive clone and debug for postgresql arguments \[\[[@&#8203;remysaissy](https://redirect.github.com/remysaissy)]]
-   \[[#&#8203;3690]]: feat: add postres geometry line segment \[\[[@&#8203;jayy-lmao](https://redirect.github.com/jayy-lmao)]]
-   \[[#&#8203;3707]]: feat(Sqlite): add LockedSqliteHandle::last_error \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3710]]: feat: add ipnet support \[\[[@&#8203;BeauGieskens](https://redirect.github.com/BeauGieskens)]]
-   \[[#&#8203;3711]]: feat(postgres): add geometry box \[\[[@&#8203;jayy-lmao](https://redirect.github.com/jayy-lmao)]]
-   \[[#&#8203;3714]]: chore: expose bstr feature \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3716]]: feat(postgres): add geometry path \[\[[@&#8203;jayy-lmao](https://redirect.github.com/jayy-lmao)]]
-   \[[#&#8203;3724]]: feat(sqlx-cli): Add flag to disable automatic loading of .env files \[\[[@&#8203;benwilber](https://redirect.github.com/benwilber)]]
-   \[[#&#8203;3734]]: QueryBuilder: add debug_assert when `push_values` is passed an empty set of tuples \[\[[@&#8203;chanmaoganda](https://redirect.github.com/chanmaoganda)]]
-   \[[#&#8203;3745]]: feat: sqlx sqlite expose de/serialize \[\[[@&#8203;mattrighetti](https://redirect.github.com/mattrighetti)]]
-   \[[#&#8203;3765]]: Merge of [#&#8203;3427](https://redirect.github.com/launchbadge/sqlx/issues/3427) (by [@&#8203;mpyw](https://redirect.github.com/mpyw)) and [#&#8203;3614](https://redirect.github.com/launchbadge/sqlx/issues/3614) (by [@&#8203;bonsairobo](https://redirect.github.com/bonsairobo)) \[\[[@&#8203;abonander](https://redirect.github.com/abonander)]]
    -   \[[#&#8203;3427]] Expose `transaction_depth` through `get_transaction_depth()` method \[\[[@&#8203;mpyw](https://redirect.github.com/mpyw)]]
        -   Changed to `Connection::is_in_transaction` in \[[#&#8203;3765]]
    -   \[[#&#8203;3614]] Add `begin_with` methods to support database-specific transaction options \[\[[@&#8203;bonsairobo](https://redirect.github.com/bonsairobo)]]
-   \[[#&#8203;3769]]: feat(postgres): add geometry polygon \[\[[@&#8203;jayy-lmao](https://redirect.github.com/jayy-lmao)]]
-   \[[#&#8203;3773]]: feat(postgres): add geometry circle \[\[[@&#8203;jayy-lmao](https://redirect.github.com/jayy-lmao)]]

##### Changed

-   \[[#&#8203;3665]]: build(deps): bump semver compatible dependencies \[\[[@&#8203;paolobarbolini](https://redirect.github.com/paolobarbolini)]]
-   \[[#&#8203;3669]]: refactor(cli): replace promptly with dialoguer \[\[[@&#8203;paolobarbolini](https://redirect.github.com/paolobarbolini)]]
-   \[[#&#8203;3672]]: add `#[track_caller]` to `Row::get()` \[\[[@&#8203;karambarakat](https://redirect.github.com/karambarakat)]]
-   \[[#&#8203;3708]]: chore(MySql): Remove unnecessary box \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3715]]: chore: add pg_copy regression tests \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3721]]: Replace some `futures-core` / `futures-util` APIs with `std` variants \[\[[@&#8203;paolobarbolini](https://redirect.github.com/paolobarbolini)]]
-   \[[#&#8203;3725]]: chore: replace rustls-pemfile with rustls-pki-types \[\[[@&#8203;tottoto](https://redirect.github.com/tottoto)]]
-   \[[#&#8203;3754]]: chore(cli): remove unused async-trait crate from dependencies \[\[[@&#8203;tottoto](https://redirect.github.com/tottoto)]]
-   \[[#&#8203;3762]]: docs(pool): recommend actix-web ThinData over Data to avoid two Arcs \[\[[@&#8203;jonasmalacofilho](https://redirect.github.com/jonasmalacofilho)]]

##### Fixed

-   \[[#&#8203;3289]]: Always set `SQLITE_OPEN_URI` on in-memory sqlite \[\[[@&#8203;LecrisUT](https://redirect.github.com/LecrisUT)]]
-   \[[#&#8203;3334]]: Fix: nextest cleanup race condition \[\[[@&#8203;bonega](https://redirect.github.com/bonega)]]
-   \[[#&#8203;3666]]: fix(cli): running tests on 32bit platforms \[\[[@&#8203;paolobarbolini](https://redirect.github.com/paolobarbolini)]]
-   \[[#&#8203;3686]]: fix: handle nullable values by printing NULL instead of panicking \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3700]]: fix(Sqlite): stop sending rows after first error \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3701]]: fix(postgres) use signed int for length prefix in `PgCopyIn` \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3703]]: fix(Postgres) chunk pg_copy data \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3712]]: FromRow: Fix documentation order \[\[[@&#8203;Turbo87](https://redirect.github.com/Turbo87)]]
-   \[[#&#8203;3720]]: Fix readme: uuid feature is gating for all repos \[\[[@&#8203;jthacker](https://redirect.github.com/jthacker)]]
-   \[[#&#8203;3728]]: postgres: Fix tracing span when dropping PgListener \[\[[@&#8203;chitoku-k](https://redirect.github.com/chitoku-k)]]
-   \[[#&#8203;3741]]: Fix example calculation in docs \[\[[@&#8203;dns2utf8](https://redirect.github.com/dns2utf8)]]
-   \[[#&#8203;3749]]: docs: add some missing backticks \[\[[@&#8203;soulwa](https://redirect.github.com/soulwa)]]
-   \[[#&#8203;3753]]: Avoid privilege requirements by using an advisory lock in test setup (postgres). \[\[[@&#8203;kildrens](https://redirect.github.com/kildrens)]]
-   \[[#&#8203;3755]]: Fix FromRow docs for tuples \[\[[@&#8203;xvapx](https://redirect.github.com/xvapx)]]
-   \[[#&#8203;3768]]: chore(Sqlite): remove ci.db from repo \[\[[@&#8203;joeydewaal](https://redirect.github.com/joeydewaal)]]
-   \[[#&#8203;3771]]: fix(ci): breakage from Rustup 1.28 \[\[[@&#8203;abonander](https://redirect.github.com/abonander)]]
-   \[[#&#8203;3786]]: Fix a copy-paste error on get_username docs \[\[[@&#8203;sulami](https://redirect.github.com/sulami)]]
-   \[[#&#8203;3801]]: Fix: Enable Json type when db feature isn't enabled \[\[[@&#8203;thriller08](https://redirect.github.com/thriller08)]]
-   \[[#&#8203;3809]]: fix: PgConnectOptions docs \[\[[@&#820

</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://redirect.github.com/renovatebot/renovate/discussions) if that's undesired.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-14 07:07:39 +00:00
renovate
2fd2c149a5 chore: bump up tldts version to v7 (#11662)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [tldts](https://redirect.github.com/remusao/tldts) | [`^6.1.68` -> `^7.0.0`](https://renovatebot.com/diffs/npm/tldts/6.1.85/7.0.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/tldts/7.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/tldts/7.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/tldts/6.1.85/7.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/tldts/6.1.85/7.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>remusao/tldts (tldts)</summary>

### [`v7.0.0`](https://redirect.github.com/remusao/tldts/blob/HEAD/CHANGELOG.md#v700-Sat-Apr-12-2025)

[Compare Source](https://redirect.github.com/remusao/tldts/compare/v6.1.86...v7.0.0)

##### 💥 Breaking Change

-   `tldts-core`, `tldts-tests`
    -   Fix inconsistent hostname validation in `getHostname` and `parse(url).hostname` when `validateHostname` is enabled [#&#8203;2262](https://redirect.github.com/remusao/tldts/pull/2262) ([@&#8203;remusao](https://redirect.github.com/remusao))

##### Authors: 1

-   Rémi ([@&#8203;remusao](https://redirect.github.com/remusao))

***

### [`v6.1.86`](https://redirect.github.com/remusao/tldts/blob/HEAD/CHANGELOG.md#v6186-Sat-Apr-12-2025)

[Compare Source](https://redirect.github.com/remusao/tldts/compare/v6.1.85...v6.1.86)

##### 📜 Update Public Suffix List

-   `tldts-experimental`, `tldts-icann`, `tldts`
    -   Update upstream public suffix list [#&#8203;2311](https://redirect.github.com/remusao/tldts/pull/2311) ([@&#8203;remusao](https://redirect.github.com/remusao))

##### 🔩 Dependencies

-   Bump axios from 1.7.7 to 1.8.4 [#&#8203;2318](https://redirect.github.com/remusao/tldts/pull/2318) ([@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot]))
-   Bump [@&#8203;rollup/plugin-node-resolve](https://redirect.github.com/rollup/plugin-node-resolve) from 16.0.0 to 16.0.1 [#&#8203;2303](https://redirect.github.com/remusao/tldts/pull/2303) ([@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot]))
-   Bump [@&#8203;babel/helpers](https://redirect.github.com/babel/helpers) from 7.24.7 to 7.26.10 [#&#8203;2306](https://redirect.github.com/remusao/tldts/pull/2306) ([@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot]))
-   Bump rollup from 4.34.8 to 4.39.0 [#&#8203;2314](https://redirect.github.com/remusao/tldts/pull/2314) ([@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot]))
-   Bump [@&#8203;types/node](https://redirect.github.com/types/node) from 22.13.5 to 22.14.0 [#&#8203;2315](https://redirect.github.com/remusao/tldts/pull/2315) ([@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot]))
-   Bump typescript from 5.7.3 to 5.8.3 [#&#8203;2316](https://redirect.github.com/remusao/tldts/pull/2316) ([@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot]))
-   Bump lerna from 8.2.0 to 8.2.2 [#&#8203;2317](https://redirect.github.com/remusao/tldts/pull/2317) ([@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot]))

##### Authors: 2

-   [@&#8203;dependabot\[bot\]](https://redirect.github.com/dependabot\[bot])
-   Rémi ([@&#8203;remusao](https://redirect.github.com/remusao))

***

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-14 06:29:31 +00:00
renovate
be759dc118 chore: bump up oxlint version to v0.16.6 (#11664)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [oxlint](https://oxc.rs) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/npm/oxlint)) | [`0.16.5` -> `0.16.6`](https://renovatebot.com/diffs/npm/oxlint/0.16.5/0.16.6) | [![age](https://developer.mend.io/api/mc/badges/age/npm/oxlint/0.16.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/oxlint/0.16.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/oxlint/0.16.5/0.16.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/oxlint/0.16.5/0.16.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>oxc-project/oxc (oxlint)</summary>

### [`v0.16.6`](https://redirect.github.com/oxc-project/oxc/releases/tag/oxlint_v0.16.6): oxlint v0.16.6

[Compare Source](https://redirect.github.com/oxc-project/oxc/compare/oxlint_v0.16.5...oxlint_v0.16.6)

#### \[0.16.6] - 2025-04-14

##### Features

-   [`0370363`](https://redirect.github.com/oxc-project/oxc/commit/0370363) language_server: Switch `tower-lsp` to `tower-lsp-server` ([#&#8203;10298](https://redirect.github.com/oxc-project/oxc/issues/10298)) (Boshen)
-   [`d48e886`](https://redirect.github.com/oxc-project/oxc/commit/d48e886) linter: Add `import/group-exports` rule ([#&#8203;10330](https://redirect.github.com/oxc-project/oxc/issues/10330)) (yefan)

##### Bug Fixes

-   [`664342b`](https://redirect.github.com/oxc-project/oxc/commit/664342b) language_server: Diable nested configuration when config path is provided ([#&#8203;10385](https://redirect.github.com/oxc-project/oxc/issues/10385)) (Sysix)
-   [`04e2fd4`](https://redirect.github.com/oxc-project/oxc/commit/04e2fd4) linter: Fix false positives for `no-control-regex` ([#&#8203;10345](https://redirect.github.com/oxc-project/oxc/issues/10345)) (Cam McHenry)
-   [`e000f60`](https://redirect.github.com/oxc-project/oxc/commit/e000f60) linter: Make extended configs properly inherit plugins ([#&#8203;10174](https://redirect.github.com/oxc-project/oxc/issues/10174)) (Sub)
-   [`81867c4`](https://redirect.github.com/oxc-project/oxc/commit/81867c4) linter: Fix stack overflow in react/exhaustive deps ([#&#8203;10322](https://redirect.github.com/oxc-project/oxc/issues/10322)) (camc314)
-   [`9aaba69`](https://redirect.github.com/oxc-project/oxc/commit/9aaba69) linter: Nested configuration directory resolution ([#&#8203;10157](https://redirect.github.com/oxc-project/oxc/issues/10157)) (Sub)

##### Performance

-   [`e0057c3`](https://redirect.github.com/oxc-project/oxc/commit/e0057c3) language_server: Only restart internal linter once when multiple config changes detected ([#&#8203;10256](https://redirect.github.com/oxc-project/oxc/issues/10256)) (Sysix)
-   [`1bb61c6`](https://redirect.github.com/oxc-project/oxc/commit/1bb61c6) linter: Replace `phf_set` with `array` in `unicorn/prefer-native-coercion-functions` ([#&#8203;10384](https://redirect.github.com/oxc-project/oxc/issues/10384)) (shulaoda)
-   [`e1e7a19`](https://redirect.github.com/oxc-project/oxc/commit/e1e7a19) linter: Replace `phf_set` with `array` in `unicorn/no-array-for-each` ([#&#8203;10377](https://redirect.github.com/oxc-project/oxc/issues/10377)) (dalaoshu)
-   [`5f0e66c`](https://redirect.github.com/oxc-project/oxc/commit/5f0e66c) linter: Replace `phf_set` with `array` in `unicorn/prefer-spread` ([#&#8203;10376](https://redirect.github.com/oxc-project/oxc/issues/10376)) (dalaoshu)
-   [`8d9559d`](https://redirect.github.com/oxc-project/oxc/commit/8d9559d) linter: Replace `phf_set` with `array` in `react/jsx-key` ([#&#8203;10375](https://redirect.github.com/oxc-project/oxc/issues/10375)) (dalaoshu)
-   [`fbd4f92`](https://redirect.github.com/oxc-project/oxc/commit/fbd4f92) linter: Replace `phf_set` with `array` in `utils::jest` ([#&#8203;10369](https://redirect.github.com/oxc-project/oxc/issues/10369)) (shulaoda)
-   [`8d0eb33`](https://redirect.github.com/oxc-project/oxc/commit/8d0eb33) linter: Replace `phf_set` with `array` in `utils::express` ([#&#8203;10370](https://redirect.github.com/oxc-project/oxc/issues/10370)) (shulaoda)
-   [`ba538ff`](https://redirect.github.com/oxc-project/oxc/commit/ba538ff) linter: Use `binary_search` for arrays with more than `7` elements ([#&#8203;10357](https://redirect.github.com/oxc-project/oxc/issues/10357)) (shulaoda)
-   [`283e4c7`](https://redirect.github.com/oxc-project/oxc/commit/283e4c7) linter: Replace `phf_set` with `array` in `react/exhaustive-deps` ([#&#8203;10337](https://redirect.github.com/oxc-project/oxc/issues/10337)) (shulaoda)
-   [`8b8d708`](https://redirect.github.com/oxc-project/oxc/commit/8b8d708) linter: Replace `phf_set` with `array` in `nextjs/no-typos` ([#&#8203;10336](https://redirect.github.com/oxc-project/oxc/issues/10336)) (shulaoda)
-   [`0fd93d6`](https://redirect.github.com/oxc-project/oxc/commit/0fd93d6) linter: Replace `phf_set` with `array` in `utils::promise` ([#&#8203;10335](https://redirect.github.com/oxc-project/oxc/issues/10335)) (shulaoda)
-   [`485ba19`](https://redirect.github.com/oxc-project/oxc/commit/485ba19) linter: Replace `phf_set` with `array` in `jest/prefer-jest-mocked` ([#&#8203;10302](https://redirect.github.com/oxc-project/oxc/issues/10302)) (shulaoda)
-   [`83931ec`](https://redirect.github.com/oxc-project/oxc/commit/83931ec) linter: Replace `phf_set` with `array` in `jsdoc/check-access` ([#&#8203;10303](https://redirect.github.com/oxc-project/oxc/issues/10303)) (shulaoda)
-   [`651b56f`](https://redirect.github.com/oxc-project/oxc/commit/651b56f) linter: Replace `phf_set` with `array` in `jsdoc/empty-tags` ([#&#8203;10304](https://redirect.github.com/oxc-project/oxc/issues/10304)) (shulaoda)
-   [`7ffb7aa`](https://redirect.github.com/oxc-project/oxc/commit/7ffb7aa) linter: Replace `phf_set` with `array` in `jsdoc/require-returns` ([#&#8203;10305](https://redirect.github.com/oxc-project/oxc/issues/10305)) (shulaoda)
-   [`d7399c4`](https://redirect.github.com/oxc-project/oxc/commit/d7399c4) linter: Replace `phf_set` with `array` in `jsx-a11y/no-noninteractive-tabindex` ([#&#8203;10306](https://redirect.github.com/oxc-project/oxc/issues/10306)) (shulaoda)
-   [`afe663b`](https://redirect.github.com/oxc-project/oxc/commit/afe663b) linter: Replace `phf_set` with `array` in `jest/no-restricted-matchers` ([#&#8203;10297](https://redirect.github.com/oxc-project/oxc/issues/10297)) (shulaoda)
-   [`bd27959`](https://redirect.github.com/oxc-project/oxc/commit/bd27959) linter: Replace `phf_set` with `array` in `eslint/array-callback-return` ([#&#8203;10296](https://redirect.github.com/oxc-project/oxc/issues/10296)) (shulaoda)
-   [`1aa0d71`](https://redirect.github.com/oxc-project/oxc/commit/1aa0d71) linter: Replace `phf_set` with `array` in `react/no-array-index-key` ([#&#8203;10294](https://redirect.github.com/oxc-project/oxc/issues/10294)) (shulaoda)
-   [`d9c4891`](https://redirect.github.com/oxc-project/oxc/commit/d9c4891) linter: Replace `phf_set` with `array` in `eslint/valid-typeof` ([#&#8203;10293](https://redirect.github.com/oxc-project/oxc/issues/10293)) (shulaoda)

##### Refactor

-   [`a95ba40`](https://redirect.github.com/oxc-project/oxc/commit/a95ba40) language_server: Make server more error resistance by falling back to default config ([#&#8203;10257](https://redirect.github.com/oxc-project/oxc/issues/10257)) (Sysix)
-   [`2e1ef4c`](https://redirect.github.com/oxc-project/oxc/commit/2e1ef4c) linter: Extract common logic from `jsdoc/require-yields` and `jsdoc/require-returns` ([#&#8203;10383](https://redirect.github.com/oxc-project/oxc/issues/10383)) (shulaoda)
-   [`9533d09`](https://redirect.github.com/oxc-project/oxc/commit/9533d09) linter: Remove duplicate ARIA property lists ([#&#8203;10326](https://redirect.github.com/oxc-project/oxc/issues/10326)) (camchenry)
-   [`67bd7aa`](https://redirect.github.com/oxc-project/oxc/commit/67bd7aa) linter: Add `AriaProperty` enum ([#&#8203;10325](https://redirect.github.com/oxc-project/oxc/issues/10325)) (camchenry)
-   [`52ea978`](https://redirect.github.com/oxc-project/oxc/commit/52ea978) linter: Update comments, improve tests, add variant All to LintFilterKind ([#&#8203;10259](https://redirect.github.com/oxc-project/oxc/issues/10259)) (Ulrich Stark)

##### Testing

-   [`62f7d76`](https://redirect.github.com/oxc-project/oxc/commit/62f7d76) editor: Refactor tests to use fixtures ([#&#8203;10381](https://redirect.github.com/oxc-project/oxc/issues/10381)) (Sysix)
-   [`4a6bb21`](https://redirect.github.com/oxc-project/oxc/commit/4a6bb21) language_server: Add test for `import` plugin integration ([#&#8203;10364](https://redirect.github.com/oxc-project/oxc/issues/10364)) (Sysix)
-   [`aa6ccd2`](https://redirect.github.com/oxc-project/oxc/commit/aa6ccd2) oxlint: Add test for nested and extended configuration with import plugin ([#&#8203;10372](https://redirect.github.com/oxc-project/oxc/issues/10372)) (Sysix)

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-14 06:13:38 +00:00
Aki Chang
00bd05897e feat(android): ai chat scaffold (#11124)
Co-authored-by: graphite-app[bot] <96075541+graphite-app[bot]@users.noreply.github.com>
Co-authored-by: eyhn <cneyhn@gmail.com>
2025-04-14 06:05:47 +00:00
renovate
08dbaae19b chore: bump up jotai-effect version to v2 (#10262)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [jotai-effect](https://jotai.org/docs/extensions/effect) ([source](https://redirect.github.com/jotaijs/jotai-effect)) | [`^1.0.5` -> `^2.0.0`](https://renovatebot.com/diffs/npm/jotai-effect/1.1.6/2.0.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/jotai-effect/2.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/jotai-effect/2.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/jotai-effect/1.1.6/2.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/jotai-effect/1.1.6/2.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>jotaijs/jotai-effect (jotai-effect)</summary>

### [`v2.0.1`](https://redirect.github.com/jotaijs/jotai-effect/compare/v2.0.0...v2.0.1)

[Compare Source](https://redirect.github.com/jotaijs/jotai-effect/compare/v2.0.0...v2.0.1)

### [`v2.0.0`](https://redirect.github.com/jotaijs/jotai-effect/releases/tag/v2.0.0)

[Compare Source](https://redirect.github.com/jotaijs/jotai-effect/compare/v1.1.6...v2.0.0)

We’re excited to announce the release of **jotai-effect v2**, which brings a single but significant change to the core API: **`atomEffect` now runs synchronously** whenever it mounts or its dependencies change. This update improves consistency, helps avoid race conditions, and keeps related state changes in sync.

***

#### What’s New?

##### Synchronous `atomEffect`

-   In v1, `atomEffect` would run **asynchronously** in the next microtask.
-   In v2, `atomEffect` runs **synchronously** on mount and whenever the dependencies it uses have changed.
-   **Batching is still supported** when you update multiple dependencies in a single writable atom. The effect runs only after that writable atom has finished all its updates, preventing partial updates or intermediate states.

**Example:**

```ts
const syncEffect = atomEffect((get, set) => {
  get(someAtom)
  set(anotherAtom)
})

const store = createStore()
store.set(someAtom, (v) => v + 1)
// The effect above runs immediately, so anotherAtom is updated in the same microtask
console.log(store.get(anotherAtom)) // Updated by atomEffect synchronously
```

When `someAtom` is updated, the effect runs **immediately**, updating `anotherAtom` in the same turn. If you update multiple atoms in the same writable atom, these changes are batched together, and `atomEffect` runs after those updates complete.

***

#### Migration Guide

For most users, **no change is required**. If you depended on the old microtask delay or cross-atom batching, read on.

##### 1. Adding back the microtask delay

If your logic explicitly relied on `atomEffect` running in a separate microtask, you can reintroduce the delay yourself:

**Before (v1)**

```ts
const effect = atomEffect((get, set) => {
  console.log('effect')
  return () => {
    console.log('cleanup')
  }
})
```

**After (v2)**

```ts
const effect = atomEffect((get, set) => {
  queueMicrotask(() => {
    console.log('effect')
  })
  return () => {
    queueMicrotask(() => {
      console.log('cleanup')
    })
  }
})
```

##### 2. Batching updates

In v1, updates to separate atoms were implicitly batched in the next microtask. In v2, **batching only occurs within a single writable atom update**:

**Before (v1)**

```ts
store.set(atomA, (v) => v + 1)
store.set(atomB, (v) => v + 1)
// atomEffect would 'see' both changes together in the next microtask
```

**After (v2)**

```ts
const actionAtom = atom(null, (get, set) => {
  set(atomA, (v) => v + 1)
  set(atomB, (v) => v + 1)
})

store.set(actionAtom)
// atomEffect now runs after both updates, in one batch
```

***

##### A Special Thanks to Daishi Kato

I’d like to extend my deepest gratitude to **Daishi Kato**, author of Jotai. Daishi dedicated months of tireless work to rework and rewrite significant parts of the Jotai core—primarily to empower community library authors such as myself to implement features such as **synchronous effects** in jotai-effect. His willingness to refine Jotai’s internals and his thoughtfulness in API design made this effort possible. Thank you.

##### Final Thoughts

-   **Most code will just work** without any changes.
-   If you have specialized scenarios relying on microtask delays or separate updates to multiple atoms, you’ll need to wrap them in a single writable atom or manually queue the microtask.

We hope these improvements make your state management more predictable and easier to reason about. If you have any issues, please feel free to open a GitHub [Discussion](https://redirect.github.com/jotaijs/jotai-effect/discussions). Happy coding!

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4xNjcuMSIsInVwZGF0ZWRJblZlciI6IjM5LjE2Ny4xIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-14 05:34:38 +00:00
renovate
1ab9f1376d chore: bump up nestjs (#11658)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@nestjs/apollo](https://redirect.github.com/nestjs/graphql) | [`13.0.4` -> `13.1.0`](https://renovatebot.com/diffs/npm/@nestjs%2fapollo/13.0.4/13.1.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fapollo/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fapollo/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fapollo/13.0.4/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fapollo/13.0.4/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/core](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/core)) | [`11.0.15` -> `11.0.16`](https://renovatebot.com/diffs/npm/@nestjs%2fcore/11.0.15/11.0.16) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcore/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcore/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcore/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcore/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/graphql](https://redirect.github.com/nestjs/graphql) | [`13.0.4` -> `13.1.0`](https://renovatebot.com/diffs/npm/@nestjs%2fgraphql/13.0.4/13.1.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fgraphql/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fgraphql/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fgraphql/13.0.4/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fgraphql/13.0.4/13.1.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-express](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-express)) | [`11.0.15` -> `11.0.16`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-express/11.0.15/11.0.16) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-express/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-express/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-express/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-express/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/platform-socket.io](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/platform-socket.io)) | [`11.0.15` -> `11.0.16`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-socket.io/11.0.15/11.0.16) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-socket.io/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fplatform-socket.io/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fplatform-socket.io/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-socket.io/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@nestjs/websockets](https://redirect.github.com/nestjs/nest) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/websockets)) | [`11.0.15` -> `11.0.16`](https://renovatebot.com/diffs/npm/@nestjs%2fwebsockets/11.0.15/11.0.16) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fwebsockets/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fwebsockets/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fwebsockets/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fwebsockets/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>nestjs/graphql (@&#8203;nestjs/apollo)</summary>

### [`v13.1.0`](https://redirect.github.com/nestjs/graphql/releases/tag/v13.1.0)

[Compare Source](https://redirect.github.com/nestjs/graphql/compare/v13.0.4...v13.1.0)

##### 13.1.0 (2025-04-11)

##### Enhancements

-   `apollo`
    -   [#&#8203;3544](https://redirect.github.com/nestjs/graphql/pull/3544) feat(apollo): add graphiql playground support ([@&#8203;kamilmysliwiec](https://redirect.github.com/kamilmysliwiec))

##### Committers: 1

-   Kamil Mysliwiec ([@&#8203;kamilmysliwiec](https://redirect.github.com/kamilmysliwiec))

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/core)</summary>

### [`v11.0.16`](https://redirect.github.com/nestjs/nest/compare/v11.0.15...v11.0.16)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.15...v11.0.16)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-express)</summary>

### [`v11.0.16`](https://redirect.github.com/nestjs/nest/compare/v11.0.15...v11.0.16)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.15...v11.0.16)

</details>

<details>
<summary>nestjs/nest (@&#8203;nestjs/platform-socket.io)</summary>

### [`v11.0.16`](https://redirect.github.com/nestjs/nest/releases/tag/v11.0.16)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.15...v11.0.16)

#### v11.0.16 (2025-04-11)

-   fix(common): use `file-type` to validate file mimetypes by [@&#8203;Chathula](https://redirect.github.com/Chathula) in [https://github.com/nestjs/nest/pull/14881](https://redirect.github.com/nestjs/nest/pull/14881)

</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://redirect.github.com/renovatebot/renovate/discussions) if that's undesired.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-14 02:57:54 +00:00
yoyoyohamapi
d494394c8d test(core): common setup for ai tests (#11644)
### TL:DR

By sharing initialization logic, accelerate test case execution.

### What Changed

* Global setup for copilot e2e
  * Login
  * Create Workspace
* Enable fully parallel for ci

### Optimization Comparison​

Comparing with PR [fix(core): ask AI input box in the whiteboard is blocked by the menu …](https://github.com/toeverything/AFFiNE/pull/11634):

|           |    Shard 1   |2|3|4|5|6|7|8|
| ------|----|----|----|----|----|---|---|--|
|Before|15min|14min|14min|14min|14min|13min|15min|10min|
|After|8min|11min|8min|8min|8min|8min|8min|7min|

### Trade-Off

Since all copilot use cases currently share a single user and workspace, some test cases need to focus on **isolation** and **independence**.
For example, when testing Embedding-related workflows:
* Different document contents should be used to avoid interference.
* After each test case execution, **cleanup** operations are also required.
* Some tests should be configured to **serial** mode.

```ts
test.describe.configure({ mode: 'serial' });

test.describe('AIChatWith/Collections', () => {
  test.beforeEach(async ({ loggedInPage: page, utils }) => {
    await utils.testUtils.setupTestEnvironment(page);
    await utils.chatPanel.openChatPanel(page);
    await utils.editor.clearAllCollections(page);

    await utils.testUtils.createNewPage(page);
  });

  test.afterEach(async ({ loggedInPage: page, utils }) => {
    // clear all collections
    await utils.editor.clearAllCollections(page);
  });

  test('should support chat with collection', async ({
    loggedInPage: page,
    utils,
  }) => {
    // Create two collections
    await utils.editor.createCollectionAndDoc(
      page,
      'Collection 1',
      'CollectionAAaa is a cute dog'
    );

    await utils.chatPanel.chatWithCollections(page, ['Collection 1']);
    await utils.chatPanel.makeChat(page, 'What is CollectionAAaa(Use English)');
    // ...
  });

  test('should support chat with multiple collections', async ({
    loggedInPage: page,
    utils,
  }) => {
    // Create two collections
    await utils.editor.createCollectionAndDoc(
      page,
      'Collection 2',
      'CollectionEEee is a cute cat'
    );

    await utils.editor.createCollectionAndDoc(
      page,
      'Collection 3',
      'CollectionFFff is a cute dog'
    );

    await utils.chatPanel.chatWithCollections(page, [
      'Collection 2',
      'Collection 3',
    ]);
    await utils.chatPanel.makeChat(
      page,
      'What is CollectionEEee? What is CollectionFFff?(Use English)'
    );
    // ...
  });
});

```

> CLOSE AI-51
2025-04-14 02:42:06 +00:00
renovate
11d1b2fae5 chore: bump up @nestjs/common version to v11.0.16 [SECURITY] (#11645)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@nestjs/common](https://nestjs.com) ([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/common)) | [`11.0.15` -> `11.0.16`](https://renovatebot.com/diffs/npm/@nestjs%2fcommon/11.0.15/11.0.16) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcommon/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@nestjs%2fcommon/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@nestjs%2fcommon/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcommon/11.0.15/11.0.16?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

### GitHub Vulnerability Alerts

#### [CVE-2024-29409](https://nvd.nist.gov/vuln/detail/CVE-2024-29409)

File Upload vulnerability in nestjs nest prior to v.11.0.16 allows a remote attacker to execute arbitrary code via the Content-Type header.

---

### Release Notes

<details>
<summary>nestjs/nest (@&#8203;nestjs/common)</summary>

### [`v11.0.16`](https://redirect.github.com/nestjs/nest/compare/v11.0.15...v11.0.16)

[Compare Source](https://redirect.github.com/nestjs/nest/compare/v11.0.15...v11.0.16)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "" (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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMzguMCIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-14 02:18:12 +00:00
renovate
1fc51bf95e chore: bump up animejs version to v4 (#11466)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [animejs](https://animejs.com) ([source](https://redirect.github.com/juliangarnier/anime)) | [`^3.2.2` -> `^4.0.0`](https://renovatebot.com/diffs/npm/animejs/3.2.2/4.0.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/animejs/4.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/animejs/4.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/animejs/3.2.2/4.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/animejs/3.2.2/4.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>juliangarnier/anime (animejs)</summary>

### [`v4.0.0`](https://redirect.github.com/juliangarnier/anime/releases/tag/4.0.0)

[Compare Source](https://redirect.github.com/juliangarnier/anime/compare/v3.2.2...4.0.0)

> **I'm still finalizing the release notes as there are MANY changes, but in the meantime, you can check out the brand new documentation [here](https://animejs.com/documentation).**

The brand new Anime.js.

### API Breaking changes

Every Anime.js feature is now exported as an ES Module.
This is great for tree shaking, you don't have to ship the entire library anymore, only what you need.

#### Animation

The `anime(parameters)` function has been replaced with the `animate(targets, parameters)` module.
The `targets` parameter has been replaced with a dedicated function parameter: `animate(targets, parameters)`.

V3:

```javascript
import anime from 'animejs';

const animation = anime({
  targets: 'div',
  translateX: 100,
});
```

V4:

```javascript
import { animate } from 'animejs';

const animation = animate('div', {
  translateX: 100,
});
```

#### Easings names

The `ease` prefix has been removed: 'easeInOutQuad' -> 'inOutQuad'.

#### Callbacks

Callbacks have have been renamed like this:

-   `begin()` -> `onBegin()`
-   `update()` -> `onUpdate()`

Here's all the change to the API

```diff
- import anime from 'animejs';
+ import { animate, createSpring, utils } from 'animejs';

- anime({
-   targets: 'div',
+ animate('div', {
    translateX: 100,
      rotate: {
-     value: 360,
+     to: 360,
-     easing: 'spring(.7, 80, 10, .5)',
+     ease: createSpring({ mass: .7, damping: 80, stiffness: 10, velocity: .5}),
    },
-   easing: 'easeinOutExpo',
+   ease: 'inOutExpo',
-   easing: () => t => Math.cos(t),
+   ease: t => Math.cos(t),
-   direction: 'reverse',
+   reversed: true,
-   direction: 'alternate',
+   alternate: true,
-   loop: 1,
+   loop: 0,
-   round: 100,
+   modifier: utils.round(2),
-   begin: () => {},
+   onBegin: () => {},
-   update: () => {},
+   onUpdate: () => {},
-   change: () => {},
+   onRender: () => {},
-   changeBegin: () => {},
-   changeComplete: () => {},
-   loopBegin: () => {},
-   loopComplete: () => {},
+   onLoop: () => {},
-   complete: () => {},
+   onComplete: () => {},
  });
```

#### Promises

No more `.finished` property, promises are now handled directly with `animation.then()`:

```diff
- import anime from 'animejs';
+ import { animate, utils } from 'animejs';

- anime({ targets: target, prop: x }).finished.then(() => {});
+ animate(target, { prop: x }).then(() => {});
```

#### Values

##### To

The object syntax `value` property has been renamed `to`:

```diff
- translateX: { value: 100 }
+ translateX: { to: 100 }
```

#### Animation parameters

##### Default `easing`

The new default easing is `'outQuad'` instead of `'easeOutElastic(1, .5)'`.

##### `composition`

In V3 all animations coexist and overlaps with each other. This can cause animations with the same targets and animated properties to create weird results.
V4 cancels a running tween if a new one is created on the same target with the same property. This behaviour can be confifugred using the new `composition` parameter.

`composition: 'none'` // The old V3 behaviour, animations can overlaps
`composition: 'replace'` // The new V4 default
`composition: 'add'` // Creates additive animations by adding the values of the currently running animations with the new ones

##### `round` -> `modifier`

The `round` parameter has been replaced with a more flexible parameters that allows you to define custom functions to transform the numerical value of an animation just before the rendering.

```diff
- round: 100
+ modifier: utils.round(2)
```

You can of course defines your own modifier functions like this:

```javascript
const animation = animate('div', {
  translateX: '100rem',
  modifier: v => v % 10 // Note that the unit 'rem' will automatically be passed to the rendered value
});
```

#### Playback parameters

##### `direction`

The `direction` parameter has been replaced with an `alternate` and `reversed` parameters

V3:

```javascript
const animation = anime({
  targets: 'div',
  direction: 'reverse',
  // direction: 'alternate' It wasn't possible to combined reverse and alternate direction before
});
```

V4:

```javascript
import { animate } from 'animejs';

const animation = animate('div', {
  translateX: 100,
  reversed: true,
  alternate: true,
});
```

#### Timelines:

```diff
- import anime from 'animejs';
+ import { createTimeline, stagger } from 'animejs';

- anime.timeline({
+ createTimeline({
-   duration: 500,
-   easing: 'easeInOutQuad',
+   defaults: {
+     duration: 500,
+     ease: 'inOutQuad',
+   }
-   loop: 2,
+   loop: 1,
- }).add({
-   targets: 'div',
+ }).add('div', {
    rotate: 90,
  })
- .add('.target:nth-child(1)', { opacity: 0, onComplete }, 0)
- .add('.target:nth-child(2)', { opacity: 0, onComplete }, 100)
- .add('.target:nth-child(3)', { opacity: 0, onComplete }, 200)
- .add('.target:nth-child(4)', { opacity: 0, onComplete }, 300)
+ .add('.target', { opacity: 0, onComplete }, stagger(100))
```

##### Stagger

```diff
- import anime from 'animejs';
+ import { animate, stagger } from 'animejs';

- anime({
-   targets: 'div',
+ animate('div', {
-   translateX: anime.stagger(100),
+   translateX: stagger(100),
-   delay: anime.stagger(100, { direction: 'reversed' }),
+   translateX: stagger(100, { reversed: true }),
  });
```

#### SVG

```diff
- import anime from 'animejs';
+ import { animate, svg } from 'animejs';

- const path = anime.path('path');
+ const { x, y, angle } = svg.createMotionPath('path');

- anime({
-   targets: '#shape1',
+ animate('#shape1', {
-   points: '70 41 118.574 59.369 111.145 132.631 60.855 84.631 20.426 60.369',
+   points: svg.morphTo('#shape2'),
-   strokeDashoffset: [anime.setDashoffset, 0],
+   strokeDashoffset: svg.drawLine(),
-   translateX: path('x'),
-   translateY: path('y'),
-   rotate: path('angle'),
+   translateX: x,
+   translateY: y,
+   rotate: angle,
  });
```

#### Utils

```diff
- import anime from 'animejs';
+ import { utils } from 'animejs';

- const value = anime.get('#target1', 'translateX');
+ const value = utils.get('#target1', 'translateX');

- anime.set('#target1', { translateX: 100 });
+ utils.set('#target1', { translateX: 100 });

- anime.remove('#target1');
+ utils.remove('#target1');

- const rounded = anime.round(value);
+ const rounded = utils.round(value, 0);
```

#### Engine

```diff
- import anime from 'animejs';
+ import { engine } from 'animejs';

- anime.suspendWhenDocumentHidden = false;
+ engine.pauseWhenHidden = false;

- anime.speed = .5;
+ engine.playbackRate = .5;
```

### Improvements

#### Performances

Major performance boost and lower memory footprint.
V4 has bee re-written from scratch by keeping performance in mind at every steps.

#### Better tween composition

The tween system has been refactored to improve animations behaviours when they overlaps.
This fix lots of issues, especially when creating multiple animations with the same property on the same target.

#### Additive animations

You can also blend animations together with the new `composition: 'add'` parameter.

#### Improved Timelines

-   Child animations can new be looped and reversed
-   Add supports for labels
-   Add supports for `.set()` in timeline
-   New position operators for more flexibility
-   Multi-target child animation can be positioned using the `stagger` function
-   Easier children defaults configuration
-   Greatly improved support for CSS transforms composition from one child animation to another

```javascript

const tl = createTimeline({
  playbackRate: .2,
  defaults: {
    duration: 500,
    easing: 'outQuad',
  }
});

tl.add('START', 100) // Add a label a 100ms
  .set('.target', { opacity: 0 })
  .add('.target', {
    translateY: 100,
    opacity: 1,
    onComplete: () => {},
  }, stagger(100))
  .add('.target', {
    scale: .75,
  }, 'START')
  .add('.target', {
    rotate: '1turn',
  }, '<<+=200')

```

#### Properties

##### CSS Variables

You can now use CSS variables directly like any other property:

```javascript
// Animate the values of the CSS variables '--radius'
animate('#target', { '--radius': '20px' });
```

##### Animating *from*

Animate *from* a value

```diff
+ translateX: { from: 50 }
```

##### From -> To

Even if the `[from, to]` shortcut is still valid in V4, you can now also write it like this:

```diff
+ translateX: { from: 50, to: 100 }
```

##### Colors

You can now animate hex colors with an alpha channel like '#F443' or '#FF444433'.

#### Timers

You can now create timers with the `createTimer` module.

Timers can be use as replacement for `setTimeout`or `setInterval` but with all the playbacks parameters, callbacks and the `Promise` system provided by anime.js.

```
const interval = createTimer({
  onLoop: () => { // do something every 500ms },
  duration: 500,
});

const timeout = createTimer({
  onComplete: () => { // do something in 500ms },
  duration: 500,
});

const gameLogicLoop = createTimer({
  frameRate: 30,
  onUpdate: gameSystems,
});

const gameRenderLoop = createTimer({
  frameRate: 60,
  onUpdate: gameRender,
});

```

#### Variable frame rate

You can now change the frame rate to all animations or to a specific Timeline / Animation / Timer

</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.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMjcuMyIsInVwZGF0ZWRJblZlciI6IjM5LjIyNy4zIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-14 01:29:09 +00:00
CatsJuice
d6b4ee8172 feat(mobile): ios selfhost server support (#11563) 2025-04-14 01:13:23 +00:00
L-Sun
e1cb8198f1 fix(editor): android bs keyboard provider error (#11647)
### What Changes
- fixed keyboard service can not be initialized since a anonymous `BSKeyboardWithActionService` class was provider to di
- fixed tool panel was not closed when focus on other pragraph by clicking
- optimized code structure of fallback `show` and `hide` of keyboard
2025-04-13 09:59:24 +00:00
L-Sun
076c5ba044 fix(editor): repeat trigger keys of at-menu was added (#11631)
Close [BS-2716](https://linear.app/affine-design/issue/BS-2716/移动端通过toolpanel唤起的at-menu,出现两个)
2025-04-13 06:46:37 +00:00
L-Sun
26d2ed8afb chore(editor): hide file and doc import entries for mobile (#11648)
Close [BS-2926](https://linear.app/affine-design/issue/BS-2926/【移动端-ios】-选择import,无反应)
Close [BS-2927](https://linear.app/affine-design/issue/BS-2927/【移动端-ios】隐藏toolbar上附件入口)
2025-04-13 05:32:15 +00:00
L-Sun
f860f77a24 fix(editor): can not query in mobile at menu (#11649)
This PR addresses an issue where queries cannot be performed in the mobile menu, particularly on Android devices. The root cause was that the `event.key` of keypress returns 'Unidentified' on Android, which prevented proper query handling.

Changes made:
- Replaced the keydown event observer with a beforeinput event listener
- Removed unnecessary keyboard event handling code that was causing issues
2025-04-13 02:39:05 +00:00
doouding
cac817c896 fix: cannot drop image as list child (#11635)
Fixes [BS-3103](https://linear.app/affine-design/issue/BS-3103/drag-and-drop-bug-白板图片无法拖动到-list-的子项下面)
2025-04-13 02:21:57 +00:00
darkskygit
ac8464068d test(server): improve server copilot test (#11596) 2025-04-12 16:36:51 +08:00
donteatfriedrice
4da00eba0d fix(editor): cut and paste surface-ref to same doc should remain surface-ref (#11639)
Close [BS-3107](https://linear.app/affine-design/issue/BS-3107/剪切-surface-ref-block-会变成指向当前文档的link-card)
2025-04-12 01:56:24 +00:00
fundon
afdc40b510 feat(editor): add shortcut to highlighter tool (#11604)
Closes: [BS-3092](https://linear.app/affine-design/issue/BS-3092/highlighter-快捷键)

### What's Changed!

* Added shortcut `⇧ P` to highlighter tool

[Screen Recording 2025-04-10 at 16.33.30.mov <span class="graphite__hidden">(uploaded via Graphite)</span> <img class="graphite__hidden" src="https://app.graphite.dev/api/v1/graphite/video/thumbnail/8ypiIKZXudF5a0tIgIzf/38aadc08-ed18-4b48-9d91-b4876d14a2d3.mov" />](https://app.graphite.dev/media/video/8ypiIKZXudF5a0tIgIzf/38aadc08-ed18-4b48-9d91-b4876d14a2d3.mov)
2025-04-11 13:08:59 +00:00
L-Sun
aabb09b31f fix(editor): ime input error at empty line (#11636)
Close [BS-3106](https://linear.app/affine-design/issue/BS-3106/mac-chrom在空行使用ime输入,文档卡住)
2025-04-11 10:39:16 +00:00
doodlewind
e1e5e8fc14 feat(editor): add basic image support in turbo renderer (#11620)
This PR adds basic support for image block:

![image.png](https://graphite-user-uploaded-assets-prod.s3.amazonaws.com/lEGcysB4lFTEbCwZ8jMv/4785fc76-fe09-4002-b3fb-aafa9cac34bb.png)
2025-04-11 10:16:07 +00:00
forehalo
e73d68cac4 chore(server): fix spotify link preview (#11638)
close AF-2499
2025-04-11 09:36:20 +00:00
forehalo
2f5647ac77 fix(editor): use img tag for link preview icon and banner (#11637)
close AF-2377
2025-04-11 08:48:04 +00:00
yoyoyohamapi
9c6d94f597 fix(core): hide start-with-ai if service feature is not enabled (#11633)
> CLOSE BS-3062
2025-04-11 08:31:05 +00:00
akumatus
883b1d50f2 fix(core): ask AI input box in the whiteboard is blocked by the menu (#11634)
Close [AI-50](https://linear.app/affine-design/issue/AI-50).

![截屏2025-04-11 15.27.58.png](https://graphite-user-uploaded-assets-prod.s3.amazonaws.com/sJGviKxfE3Ap685cl5bj/caf7a19e-7332-47bb-82c6-c5a4db0af2eb.png)
2025-04-11 08:13:00 +00:00
doouding
4e1fcca876 fix: mind map preview rendering (#11565)
Fixes [BS-3080](https://linear.app/affine-design/issue/BS-3080/ai-生成-mindmap-预览失败)
2025-04-11 07:05:36 +00:00
donteatfriedrice
74ebec007d fix(editor): surface-ref refFlavour should be affine:frame when reference to a frame (#11632) 2025-04-11 06:51:31 +00:00
Saul-Mirone
4f9a4e739a feat(editor): extract linked doc widget package (#11589)
Close [BS-2738](https://github.com/toeverything/AFFiNE/pull/11589)
2025-04-11 14:06:16 +08:00
yoyoyohamapi
149433b8d0 fix(core): cannot focus inside shape in test (#11630) 2025-04-11 05:26:27 +00:00
doodlewind
a5ab66d6cd feat(editor): add basic code support in turbo renderer (#11619)
This PR adds basic support for code block:

[Screen Recording 2025-04-10 at 8.13.26 PM.mov <span class="graphite__hidden">(uploaded via Graphite)</span> <img class="graphite__hidden" src="https://app.graphite.dev/api/v1/graphite/video/thumbnail/lEGcysB4lFTEbCwZ8jMv/5d749979-f7f1-4e4d-ba5b-bc4ba29f8b83.mov" />](https://app.graphite.dev/media/video/lEGcysB4lFTEbCwZ8jMv/5d749979-f7f1-4e4d-ba5b-bc4ba29f8b83.mov)
2025-04-11 04:28:51 +00:00
doouding
714f2e79dc fix: cannot exit editing mode when click frame body (#11603) 2025-04-11 03:23:27 +00:00
Kieran Cui
bcd1cd2629 fix(editor): the switch button style set in the TOC does not effect (#11622)
Co-authored-by: Chen <99816898+donteatfriedrice@users.noreply.github.com>
2025-04-11 11:22:24 +08:00
renovate
5670eb4d02 chore: bump up opentelemetry (#11093)
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [@opentelemetry/exporter-prometheus](https://redirect.github.com/open-telemetry/opentelemetry-js/tree/main/experimental/packages/opentelemetry-exporter-prometheus) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js)) | [`^0.57.0` -> `^0.200.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2fexporter-prometheus/0.57.2/0.200.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2fexporter-prometheus/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2fexporter-prometheus/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2fexporter-prometheus/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2fexporter-prometheus/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/host-metrics](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/packages/opentelemetry-host-metrics#readme) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib)) | [`^0.35.4` -> `^0.36.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2fhost-metrics/0.35.5/0.36.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2fhost-metrics/0.36.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2fhost-metrics/0.36.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2fhost-metrics/0.35.5/0.36.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2fhost-metrics/0.35.5/0.36.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/instrumentation](https://redirect.github.com/open-telemetry/opentelemetry-js/tree/main/experimental/packages/opentelemetry-instrumentation) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js)) | [`^0.57.0` -> `^0.200.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation/0.57.2/0.200.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2finstrumentation/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2finstrumentation/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2finstrumentation/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/instrumentation-graphql](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/plugins/node/opentelemetry-instrumentation-graphql#readme) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib)) | [`^0.47.0` -> `^0.48.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-graphql/0.47.1/0.48.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-graphql/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2finstrumentation-graphql/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2finstrumentation-graphql/0.47.1/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2finstrumentation-graphql/0.47.1/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/instrumentation-http](https://redirect.github.com/open-telemetry/opentelemetry-js/tree/main/experimental/packages/opentelemetry-instrumentation-http) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js)) | [`^0.57.0` -> `^0.200.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-http/0.57.2/0.200.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-http/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2finstrumentation-http/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2finstrumentation-http/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2finstrumentation-http/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/instrumentation-ioredis](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/plugins/node/opentelemetry-instrumentation-ioredis#readme) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib)) | [`^0.47.0` -> `^0.48.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-ioredis/0.47.1/0.48.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-ioredis/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2finstrumentation-ioredis/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2finstrumentation-ioredis/0.47.1/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2finstrumentation-ioredis/0.47.1/0.48.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/instrumentation-nestjs-core](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/plugins/node/opentelemetry-instrumentation-nestjs-core#readme) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib)) | [`^0.44.0` -> `^0.46.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-nestjs-core/0.44.1/0.46.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-nestjs-core/0.46.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2finstrumentation-nestjs-core/0.46.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2finstrumentation-nestjs-core/0.44.1/0.46.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2finstrumentation-nestjs-core/0.44.1/0.46.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/instrumentation-socket.io](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/plugins/node/instrumentation-socket.io#readme) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib)) | [`^0.46.0` -> `^0.47.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-socket.io/0.46.1/0.47.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-socket.io/0.47.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2finstrumentation-socket.io/0.47.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2finstrumentation-socket.io/0.46.1/0.47.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2finstrumentation-socket.io/0.46.1/0.47.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/sdk-node](https://redirect.github.com/open-telemetry/opentelemetry-js/tree/main/experimental/packages/opentelemetry-sdk-node) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js)) | [`^0.57.0` -> `^0.200.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2fsdk-node/0.57.2/0.200.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2fsdk-node/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2fsdk-node/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2fsdk-node/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2fsdk-node/0.57.2/0.200.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |
| [@opentelemetry/semantic-conventions](https://redirect.github.com/open-telemetry/opentelemetry-js/tree/main/semantic-conventions) ([source](https://redirect.github.com/open-telemetry/opentelemetry-js)) | [`1.31.0` -> `1.32.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2fsemantic-conventions/1.31.0/1.32.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2fsemantic-conventions/1.32.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@opentelemetry%2fsemantic-conventions/1.32.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@opentelemetry%2fsemantic-conventions/1.31.0/1.32.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@opentelemetry%2fsemantic-conventions/1.31.0/1.32.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>open-telemetry/opentelemetry-js (@&#8203;opentelemetry/exporter-prometheus)</summary>

### [`v0.200.0`](ac8641a5db...7fde94081e)

[Compare Source](ac8641a5db...7fde94081e)

</details>

<details>
<summary>open-telemetry/opentelemetry-js-contrib (@&#8203;opentelemetry/host-metrics)</summary>

### [`v0.36.0`](32204a362d...fcea8ca0c8)

[Compare Source](d4d3c4f14f...32abc4c3c0)

</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://redirect.github.com/renovatebot/renovate/discussions) if that's undesired.

---

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

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/toeverything/AFFiNE).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMDcuMSIsInVwZGF0ZWRJblZlciI6IjM5LjIzOC4wIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->
2025-04-11 03:01:02 +00:00
L-Sun
cb7f15296a chore(ios): rename keyboard css var (#11595) 2025-04-11 02:47:29 +00:00
EYHN
16d5b0df95 fix(core): fix event timing in storage (#11628) 2025-04-11 02:32:12 +00:00
Saul-Mirone
a2f879066f ci(editor): enable cross platform test (#11566) 2025-04-10 16:52:15 +00:00
553 changed files with 11526 additions and 7005 deletions

View File

@@ -5,7 +5,7 @@ rustflags = ["-C", "target-feature=+crt-static"]
[target.'cfg(target_os = "linux")']
rustflags = ["-C", "link-args=-Wl,--warn-unresolved-symbols"]
[target.'cfg(target_os = "macos")']
rustflags = ["-C", "link-args=-all_load", "-C", "link-args=-weak_framework ScreenCaptureKit"]
rustflags = ["-C", "link-args=-Wl,-undefined,dynamic_lookup,-no_fixup_chains", "-C", "link-args=-all_load", "-C", "link-args=-weak_framework ScreenCaptureKit"]
# https://sourceware.org/bugzilla/show_bug.cgi?id=21032
# https://sourceware.org/bugzilla/show_bug.cgi?id=21031
# https://github.com/rust-lang/rust/issues/134820

View File

@@ -44,7 +44,7 @@ services:
redis:
image: redis
container_name: redis
container_name: affine_redis
healthcheck:
test: ['CMD', 'redis-cli', '--raw', 'incr', 'ping']
interval: 10s
@@ -54,7 +54,7 @@ services:
postgres:
image: postgres:16
container_name: postgres
container_name: affine_postgres
volumes:
- ${DB_DATA_LOCATION}:/var/lib/postgresql/data
environment:

View File

@@ -200,11 +200,6 @@
"type": "object",
"description": "Configuration for mailer module",
"properties": {
"enabled": {
"type": "boolean",
"description": "Whether enabled mail service.\n@default false",
"default": false
},
"SMTP.host": {
"type": "string",
"description": "Host of the email server (e.g. smtp.gmail.com)\n@default \"\"\n@environment `MAILER_HOST`",

View File

@@ -218,7 +218,43 @@ jobs:
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results-e2e-legacy-bs-${{ matrix.shard }}
name: test-results-e2e-bs-${{ matrix.shard }}
path: ./test-results
if-no-files-found: ignore
e2e-blocksuite-cross-browser-test:
name: E2E BlockSuite Cross Browser Test
runs-on: ubuntu-latest
needs: optimize_ci
if: needs.optimize_ci.outputs.skip == 'false'
strategy:
fail-fast: false
matrix:
shard: [1, 2]
browser: ['chromium', 'firefox', 'webkit']
steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: ./.github/actions/setup-node
with:
playwright-install: true
playwright-platform: ${{ matrix.browser }}
electron-install: false
full-cache: true
- name: Run playground build
run: yarn workspace @blocksuite/playground build
- name: Run playwright tests
env:
BROWSER: ${{ matrix.browser }}
run: yarn workspace @affine-test/blocksuite test "cross-platform/" --forbid-only --shard=${{ matrix.shard }}/${{ strategy.job-total }}
- name: Upload test results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results-e2e-bs-cross-browser-${{ matrix.browser }}-${{ matrix.shard }}
path: ./test-results
if-no-files-found: ignore
@@ -1141,6 +1177,7 @@ jobs:
- check-yarn-binary
- e2e-test
- e2e-blocksuite-test
- e2e-blocksuite-cross-browser-test
- e2e-mobile-test
- unit-test
- build-native

3
.gitignore vendored
View File

@@ -85,3 +85,6 @@ packages/frontend/core/public/static/templates
af
af.cmd
*.resolved
# playwright
storageState.json

View File

@@ -29,10 +29,7 @@
"type": "chrome",
"request": "launch",
"name": "Debug AFFiNE Web",
"url": "http://localhost:8080",
"sourceMapPathOverrides": {
"webpack://affine/blocksuite/*": "${workspaceFolder}/blocksuite/*"
}
"url": "http://localhost:8080"
}
]
}

File diff suppressed because one or more lines are too long

View File

@@ -12,4 +12,4 @@ npmPublishAccess: public
npmPublishRegistry: "https://registry.npmjs.org"
yarnPath: .yarn/releases/yarn-4.9.0.cjs
yarnPath: .yarn/releases/yarn-4.9.1.cjs

113
Cargo.lock generated
View File

@@ -79,6 +79,7 @@ dependencies = [
"block2",
"core-foundation",
"coreaudio-rs",
"criterion2",
"dispatch2",
"libc",
"napi",
@@ -286,9 +287,9 @@ dependencies = [
[[package]]
name = "anyhow"
version = "1.0.97"
version = "1.0.98"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dcfed56ad506cb2c684a14971b8861fdc3baaaae314b9e5f9bb532cbe3ba7a4f"
checksum = "e16d2d3311acee920a9eb8d33b8cbc1787ce4a264e85f964c2404b969bdcd487"
[[package]]
name = "arbitrary"
@@ -513,9 +514,9 @@ checksum = "4848ed5727d39a7573551c205bcb1ccd88c8cad4ed2c80f62e2316f208196b8d"
[[package]]
name = "bstr"
version = "1.11.3"
version = "1.12.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "531a9155a481e2ee699d4f98f43c0ca4ff8ee1bfd55c31e9e98fb29d2b176fe0"
checksum = "234113d19d0d7d613b40e86fb654acf958910802bcceab913a4f9e7cda03b1a4"
dependencies = [
"memchr",
"regex-automata 0.4.9",
@@ -601,9 +602,9 @@ dependencies = [
[[package]]
name = "cc"
version = "1.2.18"
version = "1.2.19"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "525046617d8376e3db1deffb079e91cef90a89fc3ca5c185bbf8c9ecdd15cd5c"
checksum = "8e3a13707ac958681c13b39b458c073d0d9bc8a22cb1b2f4c8e55eb72c13f362"
dependencies = [
"shlex",
]
@@ -719,9 +720,9 @@ dependencies = [
[[package]]
name = "clap"
version = "4.5.35"
version = "4.5.36"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d8aa86934b44c19c50f87cc2790e19f54f7a67aedb64101c2e1a2e5ecfb73944"
checksum = "2df961d8c8a0d08aa9945718ccf584145eee3f3aa06cddbeac12933781102e04"
dependencies = [
"clap_builder",
"clap_derive",
@@ -729,9 +730,9 @@ dependencies = [
[[package]]
name = "clap_builder"
version = "4.5.35"
version = "4.5.36"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2414dbb2dd0695280da6ea9261e327479e9d37b0630f6b53ba2a11c60c679fd9"
checksum = "132dbda40fb6753878316a489d5a1242a8ef2f0d9e47ba01c951ea8aa7d013a5"
dependencies = [
"anstream",
"anstyle",
@@ -1207,9 +1208,9 @@ checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"
[[package]]
name = "errno"
version = "0.3.10"
version = "0.3.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d"
checksum = "976dd42dc7e85965fe702eb8164f21f450704bdde31faefd6471dba214cb594e"
dependencies = [
"libc",
"windows-sys 0.59.0",
@@ -1357,9 +1358,9 @@ dependencies = [
[[package]]
name = "four-char-code"
version = "2.2.0"
version = "2.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c661315fd366b2a1f970df7b7cb1a28d2678d49ef4872f7dcc19b4a83150f20b"
checksum = "42da99970737c0150e3c5cd1cdc510735a2511739f5c3aa3c6bfc9f31441488d"
[[package]]
name = "fs-err"
@@ -1529,9 +1530,9 @@ dependencies = [
[[package]]
name = "half"
version = "2.5.0"
version = "2.6.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7db2ff139bba50379da6aa0766b52fdcb62cb5b263009b09ed58ba604e14bbd1"
checksum = "459196ed295495a68f7d7fe1d84f6c4b7ff0e21fe3017b2f283c6fac3ad803c9"
dependencies = [
"cfg-if",
"crunchy",
@@ -1844,9 +1845,9 @@ dependencies = [
[[package]]
name = "indexmap"
version = "2.8.0"
version = "2.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3954d50fe15b02142bf25d3b8bdadb634ec3948f103d04ffe3031bc8fe9d7058"
checksum = "cea70ddb795996207ad57735b50c5982d8844f38ba9ee5f1aedcfb708a2aa11e"
dependencies = [
"equivalent",
"hashbrown 0.15.2",
@@ -1975,9 +1976,9 @@ dependencies = [
[[package]]
name = "libc"
version = "0.2.171"
version = "0.2.172"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c19937216e9d3aa9956d9bb8dfc0b0c8beb6058fc4f7a4dc4d850edf86a237d6"
checksum = "d750af042f7ef4f724306de029d18836c26c1765a54a6a3f094cbd23a7267ffa"
[[package]]
name = "libloading"
@@ -1986,7 +1987,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fc2f4eb4bc735547cfed7c0a4922cbd04a4655978c09b54f1f7b228750664c34"
dependencies = [
"cfg-if",
"windows-targets 0.48.5",
"windows-targets 0.52.6",
]
[[package]]
@@ -2018,9 +2019,9 @@ dependencies = [
[[package]]
name = "linux-raw-sys"
version = "0.9.3"
version = "0.9.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fe7db12097d22ec582439daf8618b8fdd1a7bef6270e9af3b1ebcd30893cf413"
checksum = "cd945864f07fe9f5371a27ad7b52a172b4b499999f1d97574c9fa68373937e12"
[[package]]
name = "litemap"
@@ -2184,9 +2185,9 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a"
[[package]]
name = "miniz_oxide"
version = "0.8.7"
version = "0.8.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ff70ce3e48ae43fa075863cef62e8b43b71a4f2382229920e0df362592919430"
checksum = "3be647b768db090acb35d5ec5db2b0e1f1de11133ca123b9eacf5137868f892a"
dependencies = [
"adler2",
]
@@ -2560,7 +2561,7 @@ checksum = "1e91099d4268b0e11973f036e885d652fb0b21fedcf69738c627f94db6a44f42"
[[package]]
name = "pdf-extract"
version = "0.8.2"
source = "git+https://github.com/toeverything/pdf-extract#49ef7d2aec5bb495467a40082cd9717e849ee29a"
source = "git+https://github.com/toeverything/pdf-extract?branch=darksky%2Fimprove-font-decoding#e74beed894e1b8dc228c2bf078ed92814b27759f"
dependencies = [
"adobe-cmap-parser",
"cff-parser",
@@ -2896,9 +2897,9 @@ dependencies = [
[[package]]
name = "redox_syscall"
version = "0.5.10"
version = "0.5.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0b8c0c260b63a8219631167be35e6a988e9554dbd323f8bd08439c8ed1302bd1"
checksum = "d2f103c6d277498fbceb16e84d317e2a400f160f46904d5f5410848c829511a3"
dependencies = [
"bitflags 2.9.0",
]
@@ -3089,9 +3090,9 @@ dependencies = [
[[package]]
name = "rustls"
version = "0.23.25"
version = "0.23.26"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "822ee9188ac4ec04a2f0531e55d035fb2de73f18b41a63c70c2712503b6fb13c"
checksum = "df51b5869f3a441595eac5e8ff14d486ff285f7b8c0df8770e49c3b56351f0f0"
dependencies = [
"once_cell",
"ring",
@@ -3101,15 +3102,6 @@ dependencies = [
"zeroize",
]
[[package]]
name = "rustls-pemfile"
version = "2.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dce314e5fee3f39953d46bb63bb8a46d40c2f8fb7cc5a3b6cab2bde9721d6e50"
dependencies = [
"rustls-pki-types",
]
[[package]]
name = "rustls-pki-types"
version = "1.11.0"
@@ -3187,9 +3179,9 @@ dependencies = [
[[package]]
name = "scroll_derive"
version = "0.12.0"
version = "0.12.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7f81c2fde025af7e69b1d1420531c8a8811ca898919db177141a85313b1cb932"
checksum = "1783eabc414609e28a5ba76aee5ddd52199f7107a0b24c2e9746a1ecc34a683d"
dependencies = [
"proc-macro2",
"quote",
@@ -3339,9 +3331,9 @@ dependencies = [
[[package]]
name = "smallvec"
version = "1.14.0"
version = "1.15.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd"
checksum = "8917285742e9f3e1683f0a9c4e6b57960b7314d0b08d30d1ecd426713ee2eee9"
dependencies = [
"serde",
]
@@ -3393,9 +3385,9 @@ dependencies = [
[[package]]
name = "sqlx"
version = "0.8.3"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4410e73b3c0d8442c5f99b425d7a435b5ee0ae4167b3196771dd3f7a01be745f"
checksum = "14e22987355fbf8cfb813a0cf8cd97b1b4ec834b94dbd759a9e8679d41fabe83"
dependencies = [
"sqlx-core",
"sqlx-macros",
@@ -3406,10 +3398,11 @@ dependencies = [
[[package]]
name = "sqlx-core"
version = "0.8.3"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6a007b6936676aa9ab40207cde35daab0a04b823be8ae004368c0793b96a61e0"
checksum = "55c4720d7d4cd3d5b00f61d03751c685ad09c33ae8290c8a2c11335e0604300b"
dependencies = [
"base64 0.22.1",
"bytes",
"chrono",
"crc",
@@ -3428,7 +3421,6 @@ dependencies = [
"once_cell",
"percent-encoding",
"rustls",
"rustls-pemfile",
"serde",
"serde_json",
"sha2",
@@ -3443,9 +3435,9 @@ dependencies = [
[[package]]
name = "sqlx-macros"
version = "0.8.3"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3112e2ad78643fef903618d78cf0aec1cb3134b019730edb039b69eaf531f310"
checksum = "175147fcb75f353ac7675509bc58abb2cb291caf0fd24a3623b8f7e3eb0a754b"
dependencies = [
"proc-macro2",
"quote",
@@ -3456,9 +3448,9 @@ dependencies = [
[[package]]
name = "sqlx-macros-core"
version = "0.8.3"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4e9f90acc5ab146a99bf5061a7eb4976b573f560bc898ef3bf8435448dd5e7ad"
checksum = "1cde983058e53bfa75998e1982086c5efe3c370f3250bf0357e344fa3352e32b"
dependencies = [
"dotenvy",
"either",
@@ -3482,9 +3474,9 @@ dependencies = [
[[package]]
name = "sqlx-mysql"
version = "0.8.3"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4560278f0e00ce64938540546f59f590d60beee33fffbd3b9cd47851e5fff233"
checksum = "847d2e5393a4f39e47e4f36cab419709bc2b83cbe4223c60e86e1471655be333"
dependencies = [
"atoi",
"base64 0.22.1",
@@ -3525,9 +3517,9 @@ dependencies = [
[[package]]
name = "sqlx-postgres"
version = "0.8.3"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c5b98a57f363ed6764d5b3a12bfedf62f07aa16e1856a7ddc2a0bb190a959613"
checksum = "cc35947a541b9e0a2e3d85da444f1c4137c13040267141b208395a0d0ca4659f"
dependencies = [
"atoi",
"base64 0.22.1",
@@ -3563,9 +3555,9 @@ dependencies = [
[[package]]
name = "sqlx-sqlite"
version = "0.8.3"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f85ca71d3a5b24e64e1d08dd8fe36c6c95c339a896cc33068148906784620540"
checksum = "6c48291dac4e5ed32da0927a0b981788be65674aeb62666d19873ab4289febde"
dependencies = [
"atoi",
"chrono",
@@ -3581,6 +3573,7 @@ dependencies = [
"serde",
"serde_urlencoded",
"sqlx-core",
"thiserror 2.0.12",
"tracing",
"url",
]
@@ -5058,9 +5051,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"
[[package]]
name = "winnow"
version = "0.7.4"
version = "0.7.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0e97b544156e9bebe1a0ffbc03484fc1ffe3100cbce3ffb17eac35f7cdd7ab36"
checksum = "63d3fcd9bba44b03821e7d699eeee959f3126dcc4aa8e4ae18ec617c2a5cea10"
dependencies = [
"memchr",
]

View File

@@ -40,7 +40,7 @@ objc2-foundation = "0.3"
once_cell = "1"
parking_lot = "0.12"
path-ext = "0.1.1"
pdf-extract = { git = "https://github.com/toeverything/pdf-extract" }
pdf-extract = { git = "https://github.com/toeverything/pdf-extract", branch = "darksky/improve-font-decoding" }
rand = "0.9"
rayon = "1.10"
readability = { version = "0.3.0", default-features = false }

View File

@@ -55,6 +55,8 @@
"@blocksuite/affine-widget-edgeless-auto-connect": "workspace:*",
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/affine-widget-frame-title": "workspace:*",
"@blocksuite/affine-widget-keyboard-toolbar": "workspace:*",
"@blocksuite/affine-widget-linked-doc": "workspace:*",
"@blocksuite/affine-widget-remote-selection": "workspace:*",
"@blocksuite/affine-widget-scroll-anchoring": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
@@ -115,10 +117,12 @@
"./widgets/edgeless-auto-connect": "./src/widgets/edgeless-auto-connect.ts",
"./widgets/edgeless-toolbar": "./src/widgets/edgeless-toolbar.ts",
"./widgets/frame-title": "./src/widgets/frame-title.ts",
"./widgets/linked-doc": "./src/widgets/linked-doc.ts",
"./widgets/remote-selection": "./src/widgets/remote-selection.ts",
"./widgets/scroll-anchoring": "./src/widgets/scroll-anchoring.ts",
"./widgets/slash-menu": "./src/widgets/slash-menu.ts",
"./widgets/toolbar": "./src/widgets/toolbar.ts",
"./widgets/keyboard-toolbar": "./src/widgets/keyboard-toolbar.ts",
"./fragments/doc-title": "./src/fragments/doc-title.ts",
"./fragments/frame-panel": "./src/fragments/frame-panel.ts",
"./fragments/outline": "./src/fragments/outline.ts",

View File

@@ -2448,203 +2448,262 @@ World!
});
describe('markdown to snapshot', () => {
test('code', async () => {
const markdown = '```python\nimport this\n```\n';
describe('code', () => {
test('markdown code block', async () => {
const markdown = '```python\nimport this\n```\n';
const blockSnapshot: BlockSnapshot = {
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: NoteDisplayMode.DocAndEdgeless,
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: 'import this',
},
],
},
},
children: [],
const blockSnapshot: BlockSnapshot = {
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: NoteDisplayMode.DocAndEdgeless,
},
],
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawBlockSnapshot = await mdAdapter.toBlockSnapshot({
file: markdown,
});
expect(nanoidReplacement(rawBlockSnapshot)).toEqual(blockSnapshot);
});
test('code with indentation 1 - slice', async () => {
const markdown = '```python\n import this\n```';
const sliceSnapshot: SliceSnapshot = {
type: 'slice',
content: [
{
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: 'both',
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: ' import this',
},
],
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: 'import this',
},
],
},
children: [],
},
],
},
],
workspaceId: '',
pageId: '',
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawSliceSnapshot = await mdAdapter.toSliceSnapshot({
file: markdown,
workspaceId: '',
pageId: '',
});
expect(nanoidReplacement(rawSliceSnapshot!)).toEqual(sliceSnapshot);
});
test('code with indentation 2 - slice', async () => {
const markdown = '````python\n```python\n import this\n```\n````';
const sliceSnapshot: SliceSnapshot = {
type: 'slice',
content: [
{
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: 'both',
children: [],
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: '```python\n import this\n```',
},
],
},
},
children: [],
},
],
},
],
workspaceId: '',
pageId: '',
};
],
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawSliceSnapshot = await mdAdapter.toSliceSnapshot({
file: markdown,
workspaceId: '',
pageId: '',
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawBlockSnapshot = await mdAdapter.toBlockSnapshot({
file: markdown,
});
expect(nanoidReplacement(rawBlockSnapshot)).toEqual(blockSnapshot);
});
expect(nanoidReplacement(rawSliceSnapshot!)).toEqual(sliceSnapshot);
});
test('code with indentation 3 - slice', async () => {
const markdown = '~~~~python\n````python\n import this\n````\n~~~~';
test('code with indentation 1 - slice', async () => {
const markdown = '```python\n import this\n```';
const sliceSnapshot: SliceSnapshot = {
type: 'slice',
content: [
{
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: 'both',
const sliceSnapshot: SliceSnapshot = {
type: 'slice',
content: [
{
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: 'both',
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: ' import this',
},
],
},
},
children: [],
},
],
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: '````python\n import this\n````',
},
],
},
},
children: [],
},
],
},
],
workspaceId: '',
pageId: '',
};
],
workspaceId: '',
pageId: '',
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawSliceSnapshot = await mdAdapter.toSliceSnapshot({
file: markdown,
workspaceId: '',
pageId: '',
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawSliceSnapshot = await mdAdapter.toSliceSnapshot({
file: markdown,
workspaceId: '',
pageId: '',
});
expect(nanoidReplacement(rawSliceSnapshot!)).toEqual(sliceSnapshot);
});
test('code with indentation 2 - slice', async () => {
const markdown = '````python\n```python\n import this\n```\n````';
const sliceSnapshot: SliceSnapshot = {
type: 'slice',
content: [
{
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: 'both',
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: '```python\n import this\n```',
},
],
},
},
children: [],
},
],
},
],
workspaceId: '',
pageId: '',
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawSliceSnapshot = await mdAdapter.toSliceSnapshot({
file: markdown,
workspaceId: '',
pageId: '',
});
expect(nanoidReplacement(rawSliceSnapshot!)).toEqual(sliceSnapshot);
});
test('code with indentation 3 - slice', async () => {
const markdown = '~~~~python\n````python\n import this\n````\n~~~~';
const sliceSnapshot: SliceSnapshot = {
type: 'slice',
content: [
{
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: 'both',
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'python',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: '````python\n import this\n````',
},
],
},
},
children: [],
},
],
},
],
workspaceId: '',
pageId: '',
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawSliceSnapshot = await mdAdapter.toSliceSnapshot({
file: markdown,
workspaceId: '',
pageId: '',
});
expect(nanoidReplacement(rawSliceSnapshot!)).toEqual(sliceSnapshot);
});
test('html block import as code block', async () => {
const markdown = `<div class="container">
<header>
<h1>Welcome to My Page</h1>
<nav>
<ul>
<li><a href="#home">Home</a></li>
<li><a href="#about">About</a></li>
</ul>
</nav>
</header>
<main>
<p>This is a sample HTML content</p>
</main>
</div>`;
const blockSnapshot: BlockSnapshot = {
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: NoteDisplayMode.DocAndEdgeless,
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:code',
props: {
language: 'html',
wrap: false,
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert:
'<div class="container">\n <header>\n <h1>Welcome to My Page</h1>\n <nav>\n <ul>\n <li><a href="#home">Home</a></li>\n <li><a href="#about">About</a></li>\n </ul>\n </nav>\n </header>\n <main>\n <p>This is a sample HTML content</p>\n </main>\n</div>',
},
],
},
},
children: [],
},
],
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawBlockSnapshot = await mdAdapter.toBlockSnapshot({
file: markdown,
});
expect(nanoidReplacement(rawBlockSnapshot)).toEqual(blockSnapshot);
});
expect(nanoidReplacement(rawSliceSnapshot!)).toEqual(sliceSnapshot);
});
test('paragraph', async () => {
@@ -3638,48 +3697,6 @@ bbb
expect(nanoidReplacement(rawBlockSnapshot)).toEqual(blockSnapshot);
});
test('html tag', async () => {
const markdown = `<aaa>\n`;
const blockSnapshot: BlockSnapshot = {
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: NoteDisplayMode.DocAndEdgeless,
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:paragraph',
props: {
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: '<aaa>',
},
],
},
type: 'text',
},
children: [],
},
],
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawBlockSnapshot = await mdAdapter.toBlockSnapshot({
file: markdown,
});
expect(nanoidReplacement(rawBlockSnapshot)).toEqual(blockSnapshot);
});
describe('inline latex', () => {
test.each([
['dollar sign syntax', 'inline $E=mc^2$ latex\n'],
@@ -4091,4 +4108,55 @@ hhh
});
expect(nanoidReplacement(rawBlockSnapshot)).toEqual(blockSnapshot);
});
test('should not wrap url with angle brackets if it is not a url', async () => {
const markdown = 'prompt: How many people will live in the world in 2040?';
const sliceSnapshot: SliceSnapshot = {
type: 'slice',
content: [
{
type: 'block',
id: 'matchesReplaceMap[0]',
flavour: 'affine:note',
props: {
xywh: '[0,0,800,95]',
background: DefaultTheme.noteBackgrounColor,
index: 'a0',
hidden: false,
displayMode: NoteDisplayMode.DocAndEdgeless,
},
children: [
{
type: 'block',
id: 'matchesReplaceMap[1]',
flavour: 'affine:paragraph',
props: {
type: 'text',
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert:
'prompt: How many people will live in the world in 2040?',
},
],
},
},
children: [],
},
],
},
],
workspaceId: '',
pageId: '',
};
const mdAdapter = new MarkdownAdapter(createJob(), provider);
const rawSliceSnapshot = await mdAdapter.toSliceSnapshot({
file: markdown,
workspaceId: '',
pageId: '',
});
expect(nanoidReplacement(rawSliceSnapshot!)).toEqual(sliceSnapshot);
});
});

View File

@@ -0,0 +1 @@
export * from '@blocksuite/affine-widget-keyboard-toolbar';

View File

@@ -0,0 +1 @@
export * from '@blocksuite/affine-widget-linked-doc';

View File

@@ -52,6 +52,8 @@
{ "path": "../widgets/edgeless-auto-connect" },
{ "path": "../widgets/edgeless-toolbar" },
{ "path": "../widgets/frame-title" },
{ "path": "../widgets/keyboard-toolbar" },
{ "path": "../widgets/linked-doc" },
{ "path": "../widgets/remote-selection" },
{ "path": "../widgets/scroll-anchoring" },
{ "path": "../widgets/slash-menu" },

View File

@@ -28,7 +28,7 @@ import { checkAttachmentBlob, downloadAttachmentBlob } from './utils';
@Peekable({
enableOn: ({ model }: AttachmentBlockComponent) => {
return model.props.type.endsWith('pdf');
return !model.doc.readonly && model.props.type.endsWith('pdf');
},
})
export class AttachmentBlockComponent extends CaptionedBlockComponent<AttachmentBlockModel> {

View File

@@ -146,17 +146,20 @@ const embedConfig: AttachmentEmbedConfig[] = [
// More options: https://tinytip.co/tips/html-pdf-params/
// https://chromium.googlesource.com/chromium/src/+/refs/tags/121.0.6153.1/chrome/browser/resources/pdf/open_pdf_params_parser.ts
const parameters = '#toolbar=0';
return html`<iframe
style="width: 100%; color-scheme: auto;"
height="480"
src=${blobUrl + parameters}
loading="lazy"
scrolling="no"
frameborder="no"
allowTransparency
allowfullscreen
type="application/pdf"
></iframe>`;
return html`
<iframe
style="width: 100%; color-scheme: auto;"
height="480"
src=${blobUrl + parameters}
loading="lazy"
scrolling="no"
frameborder="no"
allowTransparency
allowfullscreen
type="application/pdf"
></iframe>
<div class="affine-attachment-embed-event-mask"></div>
`;
},
},
{

View File

@@ -136,4 +136,9 @@ export const styles = css`
width: 100%;
height: 100%;
}
.affine-attachment-embed-event-mask {
position: absolute;
inset: 0;
}
`;

View File

@@ -81,21 +81,10 @@ export class BookmarkCard extends SignalWatcher(
const theme = this.bookmark.std.get(ThemeProvider).theme;
const { LoadingIcon, EmbedCardBannerIcon } = getEmbedCardIcons(theme);
const titleIconType =
!icon?.split('.').pop() || icon?.split('.').pop() === 'svg'
? 'svg+xml'
: icon?.split('.').pop();
const titleIcon = this.loading
? LoadingIcon
: icon
? html`<object
type="image/${titleIconType}"
data=${icon}
draggable="false"
>
${WebIcon16}
</object>`
? html`<img src=${icon} alt="icon" />`
: WebIcon16;
const descriptionText = this.loading
@@ -108,9 +97,7 @@ export class BookmarkCard extends SignalWatcher(
const bannerImage =
!this.loading && image
? html`<object type="image/webp" data=${image} draggable="false">
${EmbedCardBannerIcon}
</object>`
? html`<img src=${image} alt="banner" />`
: EmbedCardBannerIcon;
return html`

View File

@@ -21,16 +21,21 @@ export class CalloutBlockComponent extends CaptionedBlockComponent<CalloutBlockM
.affine-callout-block-container {
display: flex;
padding: 12px 16px;
padding: 5px 10px;
border-radius: 8px;
background-color: ${unsafeCSSVarV2('block/callout/background/grey')};
}
.affine-callout-emoji-container {
margin-right: 12px;
margin-top: 10px;
margin-right: 10px;
margin-top: 14px;
user-select: none;
font-size: 1.2em;
width: 24px;
height: 24px;
display: flex;
align-items: center;
justify-content: center;
}
.affine-callout-emoji:hover {
cursor: pointer;
@@ -40,6 +45,7 @@ export class CalloutBlockComponent extends CaptionedBlockComponent<CalloutBlockM
.affine-callout-children {
flex: 1;
min-width: 0;
padding-left: 10px;
}
`;

View File

@@ -11,6 +11,7 @@
"license": "MIT",
"dependencies": {
"@blocksuite/affine-components": "workspace:*",
"@blocksuite/affine-gfx-turbo-renderer": "workspace:*",
"@blocksuite/affine-inline-latex": "workspace:*",
"@blocksuite/affine-inline-link": "workspace:*",
"@blocksuite/affine-inline-preset": "workspace:*",
@@ -35,7 +36,8 @@
},
"exports": {
".": "./src/index.ts",
"./effects": "./src/effects.ts"
"./effects": "./src/effects.ts",
"./turbo-painter": "./src/turbo/code-painter.worker.ts"
},
"files": [
"src",

View File

@@ -3,25 +3,51 @@ import {
BlockMarkdownAdapterExtension,
type BlockMarkdownAdapterMatcher,
CODE_BLOCK_WRAP_KEY,
IN_PARAGRAPH_NODE_CONTEXT_KEY,
type MarkdownAST,
} from '@blocksuite/affine-shared/adapters';
import type { DeltaInsert } from '@blocksuite/store';
import { nanoid } from '@blocksuite/store';
import type { Code } from 'mdast';
import type { Code, Html } from 'mdast';
const isCodeNode = (node: MarkdownAST): node is Code => node.type === 'code';
const isHtmlNode = (node: MarkdownAST): node is Html => node.type === 'html';
const isCodeOrHtmlNode = (node: MarkdownAST): node is Code | Html =>
isCodeNode(node) || isHtmlNode(node);
export const codeBlockMarkdownAdapterMatcher: BlockMarkdownAdapterMatcher = {
flavour: CodeBlockSchema.model.flavour,
toMatch: o => isCodeNode(o.node),
toMatch: o => isCodeOrHtmlNode(o.node),
fromMatch: o => o.node.flavour === 'affine:code',
toBlockSnapshot: {
enter: (o, context) => {
if (!isCodeNode(o.node)) {
if (!isCodeOrHtmlNode(o.node)) {
return;
}
const { walkerContext, configs } = context;
const wrap = configs.get(CODE_BLOCK_WRAP_KEY) === 'true';
let language = 'plain text';
switch (o.node.type) {
case 'code': {
if (o.node.lang) {
language = o.node.lang;
}
break;
}
case 'html': {
const inParagraphNode = !!walkerContext.getGlobalContext(
IN_PARAGRAPH_NODE_CONTEXT_KEY
);
// only handle top level html node
if (inParagraphNode) {
return;
}
language = 'html';
break;
}
}
walkerContext
.openNode(
{
@@ -29,7 +55,7 @@ export const codeBlockMarkdownAdapterMatcher: BlockMarkdownAdapterMatcher = {
id: nanoid(),
flavour: 'affine:code',
props: {
language: o.node.lang ?? 'Plain Text',
language,
wrap,
text: {
'$blocksuite:internal:text$': true,

View File

@@ -2,6 +2,7 @@ import {
type MarkdownAdapterPreprocessor,
MarkdownPreprocessorExtension,
} from '@blocksuite/affine-shared/adapters';
import { isValidUrl } from '@blocksuite/affine-shared/utils';
const codePreprocessor: MarkdownAdapterPreprocessor = {
name: 'code',
@@ -53,14 +54,9 @@ const codePreprocessor: MarkdownAdapterPreprocessor = {
//
// eg. /MuawcBMT1Mzvoar09-_66?mode=page&blockIds=rL2_GXbtLU2SsJVfCSmh_
// https://www.markdownguide.org/basic-syntax/#urls-and-email-addresses
try {
const valid =
URL.canParse?.(trimmedLine) ?? Boolean(new URL(trimmedLine));
if (valid) {
return `<${trimmedLine}>`;
}
} catch (err) {
console.log(err);
const valid = isValidUrl(trimmedLine);
if (valid) {
return `<${trimmedLine}>`;
}
}

View File

@@ -0,0 +1,173 @@
import { deleteTextCommand } from '@blocksuite/affine-inline-preset';
import {
HtmlAdapter,
pasteMiddleware,
PlainTextAdapter,
} from '@blocksuite/affine-shared/adapters';
import {
getBlockIndexCommand,
getBlockSelectionsCommand,
getTextSelectionCommand,
} from '@blocksuite/affine-shared/commands';
import { type Container, createIdentifier } from '@blocksuite/global/di';
import { DisposableGroup } from '@blocksuite/global/disposable';
import {
type BlockStdScope,
Clipboard,
type ClipboardAdapterConfig,
LifeCycleWatcher,
LifeCycleWatcherIdentifier,
StdIdentifier,
type UIEventHandler,
} from '@blocksuite/std';
import type { ExtensionType } from '@blocksuite/store';
export const CodeClipboardAdapterConfigIdentifier =
createIdentifier<ClipboardAdapterConfig>('code-clipboard-adapter-config');
export function CodeClipboardAdapterConfigExtension(
config: ClipboardAdapterConfig
): ExtensionType {
return {
setup: di => {
di.addImpl(
CodeClipboardAdapterConfigIdentifier(config.mimeType),
() => config
);
},
};
}
const PlainTextClipboardConfig = CodeClipboardAdapterConfigExtension({
mimeType: 'text/plain',
adapter: PlainTextAdapter,
priority: 90,
});
const HtmlClipboardConfig = CodeClipboardAdapterConfigExtension({
mimeType: 'text/html',
adapter: HtmlAdapter,
priority: 80,
});
export class CodeBlockClipboard extends Clipboard {
static override readonly key = 'code-block-clipboard';
override get _adapters() {
const adapterConfigs = this.std.provider.getAll(
CodeClipboardAdapterConfigIdentifier
);
return Array.from(adapterConfigs.values());
}
}
export class CodeBlockClipboardController extends LifeCycleWatcher {
static override key = 'code-block-clipboard-controller';
private readonly _disposables = new DisposableGroup();
constructor(
std: BlockStdScope,
readonly clipboard: CodeBlockClipboard
) {
super(std);
}
static override setup(di: Container) {
di.add(
this as unknown as {
new (
std: BlockStdScope,
clipboard: CodeBlockClipboard
): CodeBlockClipboardController;
},
[StdIdentifier, CodeBlockClipboard]
);
di.addImpl(LifeCycleWatcherIdentifier(this.key), provider =>
provider.get(this)
);
}
protected _init = () => {
const paste = pasteMiddleware(this.std);
this.clipboard.use(paste);
this._disposables.add({
dispose: () => {
this.clipboard.unuse(paste);
},
});
};
onPaste: UIEventHandler = ctx => {
const e = ctx.get('clipboardState').raw;
e.preventDefault();
this.std.store.captureSync();
this.std.command
.chain()
.try(cmd => [
cmd.pipe(getTextSelectionCommand).pipe((ctx, next) => {
const textSelection = ctx.currentTextSelection;
if (!textSelection) return;
const end = textSelection.to ?? textSelection.from;
next({ currentSelectionPath: end.blockId });
}),
cmd.pipe(getBlockSelectionsCommand).pipe((ctx, next) => {
const currentBlockSelections = ctx.currentBlockSelections;
if (!currentBlockSelections) return;
const blockSelection = currentBlockSelections.at(-1);
if (!blockSelection) return;
next({ currentSelectionPath: blockSelection.blockId });
}),
])
.pipe(getBlockIndexCommand)
.try(cmd => [cmd.pipe(getTextSelectionCommand).pipe(deleteTextCommand)])
.pipe((ctx, next) => {
if (!ctx.parentBlock) {
return;
}
this.clipboard
.paste(
e,
this.std.store,
ctx.parentBlock.model.id,
ctx.blockIndex ? ctx.blockIndex + 1 : 1
)
.catch(console.error);
return next();
})
.run();
return true;
};
override mounted() {
this._init();
// add paste event listener for code block
const subscription = this.std.view.viewUpdated.subscribe(
({ type, method, view }) => {
if (type !== 'block' || view.model.flavour !== 'affine:code') return;
if (method === 'add') {
view.handleEvent('paste', this.onPaste);
}
}
);
this._disposables.add(subscription);
}
override unmounted() {
this._disposables.dispose();
}
}
export function getCodeClipboardExtensions(): ExtensionType[] {
return [
PlainTextClipboardConfig,
HtmlClipboardConfig,
CodeBlockClipboard,
CodeBlockClipboardController,
];
}

View File

@@ -8,6 +8,7 @@ import type { ExtensionType } from '@blocksuite/store';
import { literal, unsafeStatic } from 'lit/static-html.js';
import { CodeBlockAdapterExtensions } from './adapters/extension.js';
import { getCodeClipboardExtensions } from './clipboard/index.js';
import {
CodeBlockInlineManagerExtension,
CodeBlockUnitSpecExtension,
@@ -33,4 +34,5 @@ export const CodeBlockSpec: ExtensionType[] = [
CodeBlockAdapterExtensions,
SlashMenuConfigExtension('affine:code', codeSlashMenuConfig),
CodeKeymapExtension,
...getCodeClipboardExtensions(),
].flat();

View File

@@ -1,7 +1,7 @@
import { affineTextStyles } from '@blocksuite/affine-shared/styles';
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';
import { ShadowlessElement } from '@blocksuite/std';
import { ZERO_WIDTH_SPACE } from '@blocksuite/std/inline';
import { ZERO_WIDTH_FOR_EMPTY_LINE } from '@blocksuite/std/inline';
import type { DeltaInsert } from '@blocksuite/store';
import { html } from 'lit';
import { property } from 'lit/decorators.js';
@@ -111,7 +111,7 @@ export class AffineCodeUnit extends ShadowlessElement {
@property({ type: Object })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
};
}

View File

@@ -1,5 +1,8 @@
export * from './adapters';
export * from './clipboard';
export * from './code-block';
export * from './code-block-config';
export * from './code-block-spec';
export * from './code-toolbar';
export * from './turbo/code-layout-handler';
export * from './turbo/code-painter.worker';

View File

@@ -0,0 +1,71 @@
import type { Rect } from '@blocksuite/affine-gfx-turbo-renderer';
import {
BlockLayoutHandlerExtension,
BlockLayoutHandlersIdentifier,
} from '@blocksuite/affine-gfx-turbo-renderer';
import type { Container } from '@blocksuite/global/di';
import type { EditorHost, GfxBlockComponent } from '@blocksuite/std';
import { clientToModelCoord, type ViewportRecord } from '@blocksuite/std/gfx';
import type { BlockModel } from '@blocksuite/store';
import type { CodeLayout } from './code-painter.worker';
export class CodeLayoutHandlerExtension extends BlockLayoutHandlerExtension<CodeLayout> {
readonly blockType = 'affine:code';
static override setup(di: Container) {
di.addImpl(
BlockLayoutHandlersIdentifier('code'),
CodeLayoutHandlerExtension
);
}
override queryLayout(
model: BlockModel,
host: EditorHost,
viewportRecord: ViewportRecord
): CodeLayout | null {
const component = host.std.view.getBlock(model.id) as GfxBlockComponent;
if (!component) return null;
const codeBlockElement = component.querySelector(
'.affine-code-block-container'
);
if (!codeBlockElement) return null;
const { zoom, viewScale } = viewportRecord;
const codeLayout: CodeLayout = {
type: 'affine:code',
blockId: model.id,
rect: { x: 0, y: 0, w: 0, h: 0 },
};
// Get the bounding rect of the code block
const clientRect = codeBlockElement.getBoundingClientRect();
if (!clientRect) return null;
// Convert client coordinates to model coordinates
const [modelX, modelY] = clientToModelCoord(viewportRecord, [
clientRect.x,
clientRect.y,
]);
codeLayout.rect = {
x: modelX,
y: modelY,
w: clientRect.width / zoom / viewScale,
h: clientRect.height / zoom / viewScale,
};
return codeLayout;
}
calculateBound(layout: CodeLayout) {
const rect: Rect = layout.rect;
return {
rect,
subRects: [rect],
};
}
}

View File

@@ -0,0 +1,53 @@
import type {
BlockLayout,
BlockLayoutPainter,
WorkerToHostMessage,
} from '@blocksuite/affine-gfx-turbo-renderer';
import { BlockLayoutPainterExtension } from '@blocksuite/affine-gfx-turbo-renderer/painter';
export interface CodeLayout extends BlockLayout {
type: 'affine:code';
}
function isCodeLayout(layout: BlockLayout): layout is CodeLayout {
return layout.type === 'affine:code';
}
class CodeLayoutPainter implements BlockLayoutPainter {
paint(
ctx: OffscreenCanvasRenderingContext2D,
layout: BlockLayout,
layoutBaseX: number,
layoutBaseY: number
): void {
if (!isCodeLayout(layout)) {
const message: WorkerToHostMessage = {
type: 'paintError',
error: 'Invalid layout format',
blockType: 'affine:code',
};
self.postMessage(message);
return;
}
// Get the layout dimensions
const x = layout.rect.x - layoutBaseX;
const y = layout.rect.y - layoutBaseY;
const width = layout.rect.w;
const height = layout.rect.h;
// Simple white rectangle for now
ctx.fillStyle = 'white';
ctx.fillRect(x, y, width, height);
// Add a border to visualize the code block
ctx.strokeStyle = 'rgba(0, 0, 0, 0.1)';
ctx.lineWidth = 1;
ctx.strokeRect(x, y, width, height);
}
}
export const CodeLayoutPainterExtension = BlockLayoutPainterExtension(
'affine:code',
CodeLayoutPainter
);

View File

@@ -8,6 +8,7 @@
"include": ["./src"],
"references": [
{ "path": "../../components" },
{ "path": "../../gfx/turbo-renderer" },
{ "path": "../../inlines/latex" },
{ "path": "../../inlines/link" },
{ "path": "../../inlines/preset" },

View File

@@ -259,7 +259,7 @@ export class EdgelessTextBlockComponent extends GfxBlockComponent<EdgelessTextBl
};
}
override onSelected(context: SelectedContext) {
override onSelected(context: SelectedContext): void | boolean {
const { selected, multiSelect, event: e } = context;
const { editing } = this.gfx.selection;
const alreadySelected = this.gfx.selection.has(this.model.id);
@@ -318,7 +318,7 @@ export class EdgelessTextBlockComponent extends GfxBlockComponent<EdgelessTextBl
})
.catch(console.error);
} else {
super.onSelected(context);
return super.onSelected(context);
}
}

View File

@@ -4,7 +4,7 @@ import type {
EmbedGithubStyles,
} from '@blocksuite/affine-model';
import { ThemeProvider } from '@blocksuite/affine-shared/services';
import { BlockSelection } from '@blocksuite/std';
import { BlockSelection, isGfxBlockComponent } from '@blocksuite/std';
import { html, nothing } from 'lit';
import { property } from 'lit/decorators.js';
import { classMap } from 'lit/directives/class-map.js';
@@ -166,16 +166,16 @@ export class EmbedGithubBlockComponent extends EmbedBlockComponent<
'affine-embed-github-block': true,
loading,
[style]: true,
edgeless: isGfxBlockComponent(this),
selected: this.selected$.value,
})}
style=${styleMap({
transform: `scale(${this._scale})`,
// transform: `scale(${this._scale})`,
transformOrigin: '0 0 ',
})}
@click=${this._handleClick}
@dblclick=${this._handleDoubleClick}
>
<div class="affine-embed-github-banner">${bannerImage}</div>
<div class="affine-embed-github-content">
<div class="affine-embed-github-content-title">
<div class="affine-embed-github-content-title-icons">
@@ -260,6 +260,7 @@ export class EmbedGithubBlockComponent extends EmbedBlockComponent<
</div>
</div>
</div>
<div class="affine-embed-github-banner">${bannerImage}</div>
</div>
`
);

View File

@@ -14,6 +14,7 @@ export const styles = css`
opacity: var(--add, 1);
background: var(--affine-background-primary-color);
user-select: none;
overflow: hidden;
}
.affine-embed-github-content {
@@ -275,7 +276,7 @@ export const styles = css`
}
.affine-embed-github-block.vertical {
flex-direction: column;
flex-direction: column-reverse;
.affine-embed-github-content {
width: 100%;
@@ -383,7 +384,8 @@ export const styles = css`
.affine-embed-github-content {
width: 100%;
}
.affine-embed-github-banner {
.affine-embed-github-block:not(.edgeless) .affine-embed-github-banner {
display: none;
}
}

View File

@@ -209,9 +209,9 @@ export class EmbedIframeErrorCard extends WithDisposable(LitElement) {
});
};
private readonly _handleRetry = (e: MouseEvent) => {
private readonly _handleRetry = async (e: MouseEvent) => {
e.stopPropagation();
this.onRetry();
const success = await this.onRetry();
// track retry event
this.telemetryService?.track('ReloadLink', {
@@ -220,6 +220,7 @@ export class EmbedIframeErrorCard extends WithDisposable(LitElement) {
segment: 'editor',
module: 'embed block',
control: 'reload button',
result: success ? 'success' : 'failure',
});
};
@@ -301,7 +302,7 @@ export class EmbedIframeErrorCard extends WithDisposable(LitElement) {
accessor error: Error | null = null;
@property({ attribute: false })
accessor onRetry!: () => void;
accessor onRetry!: () => Promise<boolean>;
@property({ attribute: false })
accessor model!: EmbedIframeBlockModel;

View File

@@ -78,7 +78,7 @@ export class EmbedIframeLinkEditPopup extends SignalWatcher(
segment: 'editor',
module: 'embed block',
control: 'edit button',
other: status,
result: status,
});
}

View File

@@ -228,7 +228,7 @@ export class EmbedIframeLinkInputPopup extends EmbedIframeLinkInputBase {
segment: this.options?.telemetrySegment ?? 'editor',
module: 'embed block',
control: 'confirm embed link',
other: status,
result: status,
});
}

View File

@@ -299,12 +299,19 @@ export const builtinToolbarConfig = {
icon: ResetIcon(),
run(ctx) {
const component = ctx.getCurrentBlockByType(EmbedIframeBlockComponent);
component?.refreshData().catch(console.error);
ctx.track('ReloadLink', {
...trackBaseProps,
control: 'reload link',
});
component
?.refreshData()
.then(success => {
ctx.track('ReloadLink', {
type: 'embed iframe block',
page: 'doc editor',
segment: 'doc',
module: 'toolbar',
control: 'reload link',
result: success ? 'success' : 'failure',
});
})
.catch(console.error);
},
},
{

View File

@@ -143,7 +143,7 @@ export class EmbedIframeBlockComponent extends CaptionedBlockComponent<EmbedIfra
const { url } = this.model.props;
if (!url) {
this.status$.value = 'idle';
return;
return false;
}
// set loading status
@@ -188,11 +188,13 @@ export class EmbedIframeBlockComponent extends CaptionedBlockComponent<EmbedIfra
// set success status
this.status$.value = 'success';
return true;
} catch (err) {
// set error status
this.status$.value = 'error';
this.error$.value = err instanceof Error ? err : new Error(String(err));
console.error('Failed to refresh iframe data:', err);
return false;
}
};
@@ -284,7 +286,7 @@ export class EmbedIframeBlockComponent extends CaptionedBlockComponent<EmbedIfra
};
private readonly _handleRetry = async () => {
await this.refreshData();
return await this.refreshData();
};
private readonly _renderIframe = () => {

View File

@@ -1,8 +1,5 @@
import { EmbedLinkedDocBlockSchema } from '@blocksuite/affine-model';
import {
getInlineEditorByModel,
insertContent,
} from '@blocksuite/affine-rich-text';
import { insertContent } from '@blocksuite/affine-rich-text';
import { REFERENCE_NODE } from '@blocksuite/affine-shared/consts';
import { createDefaultDoc } from '@blocksuite/affine-shared/utils';
import {
@@ -68,22 +65,7 @@ const linkedDocSlashMenuConfig: SlashMenuConfig = {
if (!linkedDocWidget) return;
// TODO(@L-Sun): make linked-doc-widget as extension
// @ts-expect-error same as above
const triggerKey = linkedDocWidget.config.triggerKeys[0];
insertContent(std, model, triggerKey);
const inlineEditor = getInlineEditorByModel(std, model);
if (inlineEditor) {
// Wait for range to be updated
const subscription = inlineEditor.slots.inlineRangeSync.subscribe(
() => {
// TODO(@L-Sun): make linked-doc-widget as extension
subscription.unsubscribe();
// @ts-expect-error same as above
linkedDocWidget.show({ addTriggerKey: true });
}
);
}
linkedDocWidget.show({ addTriggerKey: true });
},
},
],

View File

@@ -12,6 +12,8 @@ import {
import {
ActionPlacement,
DocDisplayMetaProvider,
EditorSettingProvider,
FeatureFlagService,
type LinkEventType,
type OpenDocMode,
type ToolbarAction,
@@ -33,7 +35,7 @@ import {
ExpandFullIcon,
OpenInNewIcon,
} from '@blocksuite/icons/lit';
import { BlockFlavourIdentifier } from '@blocksuite/std';
import { BlockFlavourIdentifier, isGfxBlockComponent } from '@blocksuite/std';
import { type ExtensionType, Slice } from '@blocksuite/store';
import { computed, signal } from '@preact/signals-core';
import { html } from 'lit';
@@ -213,6 +215,20 @@ const conversionsActionGroup = {
},
run(ctx) {
const block = ctx.getCurrentBlockByType(EmbedLinkedDocBlockComponent);
if (
ctx.std
.get(FeatureFlagService)
.getFlag('enable_embed_doc_with_alias') &&
isGfxBlockComponent(block)
) {
const editorSetting = ctx.std.getOptional(EditorSettingProvider);
editorSetting?.set?.(
'docDropCanvasPreferView',
'affine:embed-synced-doc'
);
}
block?.convertToEmbed();
ctx.track('SelectedView', {

View File

@@ -3,6 +3,8 @@ import { EditorChevronDown } from '@blocksuite/affine-components/toolbar';
import { EmbedSyncedDocModel } from '@blocksuite/affine-model';
import {
ActionPlacement,
EditorSettingProvider,
FeatureFlagService,
type LinkEventType,
type OpenDocMode,
type ToolbarAction,
@@ -21,7 +23,7 @@ import {
ExpandFullIcon,
OpenInNewIcon,
} from '@blocksuite/icons/lit';
import { BlockFlavourIdentifier } from '@blocksuite/std';
import { BlockFlavourIdentifier, isGfxBlockComponent } from '@blocksuite/std';
import { type ExtensionType, Slice } from '@blocksuite/store';
import { computed, signal } from '@preact/signals-core';
import { html } from 'lit';
@@ -30,7 +32,6 @@ import { keyed } from 'lit/directives/keyed.js';
import { repeat } from 'lit/directives/repeat.js';
import { EmbedSyncedDocBlockComponent } from '../embed-synced-doc-block';
const trackBaseProps = {
category: 'linked doc',
type: 'embed view',
@@ -142,6 +143,19 @@ const conversionsActionGroup = {
label: 'Card view',
run(ctx) {
const block = ctx.getCurrentBlockByType(EmbedSyncedDocBlockComponent);
if (
ctx.std
.get(FeatureFlagService)
.getFlag('enable_embed_doc_with_alias') &&
isGfxBlockComponent(block)
) {
const editorSetting = ctx.std.getOptional(EditorSettingProvider);
editorSetting?.set?.(
'docDropCanvasPreferView',
'affine:embed-linked-doc'
);
}
block?.convertToCard();
ctx.track('SelectedView', {

View File

@@ -117,9 +117,9 @@ export class EmbedSyncedDocBlockComponent extends EmbedBlockComponent<EmbedSynce
const nextDepth = this.depth + 1;
const previewSpecBuilder = SpecProvider._.getSpec(name);
const currentDisposables = this.disposables;
const editorSetting =
this.std.getOptional(EditorSettingProvider) ??
signal(GeneralSettingSchema.parse({}));
const editorSetting = this.std.getOptional(EditorSettingProvider) ?? {
setting$: signal(GeneralSettingSchema.parse({})),
};
class EmbedSyncedDocWatcher extends LifeCycleWatcher {
static override key = 'embed-synced-doc-watcher';

View File

@@ -53,7 +53,7 @@ export class FrameBlockComponent extends GfxBlockComponent<FrameBlockModel> {
};
}
override onSelected(context: SelectedContext): void {
override onSelected(context: SelectedContext): boolean | void {
const { x, y } = context.position;
if (
@@ -63,10 +63,10 @@ export class FrameBlockComponent extends GfxBlockComponent<FrameBlockModel> {
// otherwise if the frame has title, then ignore it because in this case the frame cannot be selected by frame body
this.model.props.title.length)
) {
return;
return false;
}
super.onSelected(context);
return super.onSelected(context);
}
override renderGfxBlock() {

View File

@@ -80,7 +80,7 @@ const builtinSurfaceToolbarConfig = {
ctx.store.addBlock(
SurfaceRefBlockSchema.model.flavour,
{ reference: frameId, refFlavour: NoteBlockSchema.model.flavour },
{ reference: frameId, refFlavour: FrameBlockSchema.model.flavour },
lastNoteId
);

View File

@@ -13,6 +13,7 @@
"@blocksuite/affine-block-note": "workspace:*",
"@blocksuite/affine-block-surface": "workspace:*",
"@blocksuite/affine-components": "workspace:*",
"@blocksuite/affine-gfx-turbo-renderer": "workspace:*",
"@blocksuite/affine-model": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
@@ -32,7 +33,8 @@
},
"exports": {
".": "./src/index.ts",
"./effects": "./src/effects.ts"
"./effects": "./src/effects.ts",
"./turbo-painter": "./src/turbo/image-painter.worker.ts"
},
"files": [
"src",

View File

@@ -7,5 +7,7 @@ export { ImageProxyService } from './image-proxy-service';
export * from './image-service';
export * from './image-spec';
export * from './styles';
export * from './turbo/image-layout-handler';
export * from './turbo/image-painter.worker';
export { addImages, downloadImageBlob, uploadBlobForImage } from './utils';
export { ImageSelection } from '@blocksuite/affine-shared/selection';

View File

@@ -0,0 +1,69 @@
import type { Rect } from '@blocksuite/affine-gfx-turbo-renderer';
import {
BlockLayoutHandlerExtension,
BlockLayoutHandlersIdentifier,
} from '@blocksuite/affine-gfx-turbo-renderer';
import type { Container } from '@blocksuite/global/di';
import type { EditorHost, GfxBlockComponent } from '@blocksuite/std';
import { clientToModelCoord, type ViewportRecord } from '@blocksuite/std/gfx';
import type { BlockModel } from '@blocksuite/store';
import type { ImageLayout } from './image-painter.worker';
export class ImageLayoutHandlerExtension extends BlockLayoutHandlerExtension<ImageLayout> {
readonly blockType = 'affine:image';
static override setup(di: Container) {
di.addImpl(
BlockLayoutHandlersIdentifier('image'),
ImageLayoutHandlerExtension
);
}
override queryLayout(
model: BlockModel,
host: EditorHost,
viewportRecord: ViewportRecord
): ImageLayout | null {
const component = host.std.view.getBlock(model.id) as GfxBlockComponent;
if (!component) return null;
const imageContainer = component.querySelector('.affine-image-container');
if (!imageContainer) return null;
const resizableImg = component.querySelector(
'.resizable-img'
) as HTMLElement;
if (!resizableImg) return null;
const { zoom, viewScale } = viewportRecord;
const rect = resizableImg.getBoundingClientRect();
const [modelX, modelY] = clientToModelCoord(viewportRecord, [
rect.x,
rect.y,
]);
const imageLayout: ImageLayout = {
type: 'affine:image',
blockId: model.id,
rect: {
x: modelX,
y: modelY,
w: rect.width / zoom / viewScale,
h: rect.height / zoom / viewScale,
},
};
return imageLayout;
}
calculateBound(layout: ImageLayout) {
const rect: Rect = layout.rect;
return {
rect,
subRects: [rect],
};
}
}

View File

@@ -0,0 +1,56 @@
import type {
BlockLayout,
BlockLayoutPainter,
} from '@blocksuite/affine-gfx-turbo-renderer';
import { BlockLayoutPainterExtension } from '@blocksuite/affine-gfx-turbo-renderer/painter';
export interface ImageLayout extends BlockLayout {
type: 'affine:image';
rect: {
x: number;
y: number;
w: number;
h: number;
};
}
function isImageLayout(layout: BlockLayout): layout is ImageLayout {
return layout.type === 'affine:image';
}
class ImageLayoutPainter implements BlockLayoutPainter {
paint(
ctx: OffscreenCanvasRenderingContext2D,
layout: BlockLayout,
layoutBaseX: number,
layoutBaseY: number
): void {
if (!isImageLayout(layout)) {
console.warn(
'Expected image layout but received different format:',
layout
);
return;
}
// For now, just paint a white rectangle
const x = layout.rect.x - layoutBaseX;
const y = layout.rect.y - layoutBaseY;
const width = layout.rect.w;
const height = layout.rect.h;
// Draw a white rectangle with border
ctx.fillStyle = 'white';
ctx.fillRect(x, y, width, height);
// Add a border
ctx.strokeStyle = '#e0e0e0';
ctx.lineWidth = 1;
ctx.strokeRect(x, y, width, height);
}
}
export const ImageLayoutPainterExtension = BlockLayoutPainterExtension(
'affine:image',
ImageLayoutPainter
);

View File

@@ -10,6 +10,7 @@
{ "path": "../note" },
{ "path": "../surface" },
{ "path": "../../components" },
{ "path": "../../gfx/turbo-renderer" },
{ "path": "../../model" },
{ "path": "../../shared" },
{ "path": "../../widgets/slash-menu" },

View File

@@ -2,18 +2,14 @@ import { ParagraphBlockSchema } from '@blocksuite/affine-model';
import {
BlockMarkdownAdapterExtension,
type BlockMarkdownAdapterMatcher,
IN_PARAGRAPH_NODE_CONTEXT_KEY,
type MarkdownAST,
} from '@blocksuite/affine-shared/adapters';
import type { DeltaInsert } from '@blocksuite/store';
import { nanoid } from '@blocksuite/store';
import type { Heading } from 'mdast';
const PARAGRAPH_MDAST_TYPE = new Set([
'paragraph',
'html',
'heading',
'blockquote',
]);
const PARAGRAPH_MDAST_TYPE = new Set(['paragraph', 'heading', 'blockquote']);
const isParagraphMDASTType = (node: MarkdownAST) =>
PARAGRAPH_MDAST_TYPE.has(node.type);
@@ -27,32 +23,8 @@ export const paragraphBlockMarkdownAdapterMatcher: BlockMarkdownAdapterMatcher =
enter: (o, context) => {
const { walkerContext, deltaConverter } = context;
switch (o.node.type) {
case 'html': {
walkerContext
.openNode(
{
type: 'block',
id: nanoid(),
flavour: 'affine:paragraph',
props: {
type: 'text',
text: {
'$blocksuite:internal:text$': true,
delta: [
{
insert: o.node.value,
},
],
},
},
children: [],
},
'children'
)
.closeNode();
break;
}
case 'paragraph': {
walkerContext.setGlobalContext(IN_PARAGRAPH_NODE_CONTEXT_KEY, true);
walkerContext
.openNode(
{
@@ -71,7 +43,6 @@ export const paragraphBlockMarkdownAdapterMatcher: BlockMarkdownAdapterMatcher =
'children'
)
.closeNode();
walkerContext.skipAllChildren();
break;
}
case 'heading': {
@@ -119,6 +90,12 @@ export const paragraphBlockMarkdownAdapterMatcher: BlockMarkdownAdapterMatcher =
}
}
},
leave: (o, context) => {
if (o.node.type === 'paragraph') {
const { walkerContext } = context;
walkerContext.setGlobalContext(IN_PARAGRAPH_NODE_CONTEXT_KEY, false);
}
},
},
fromBlockSnapshot: {
enter: (o, context) => {

View File

@@ -46,6 +46,8 @@
"@blocksuite/affine-widget-edgeless-auto-connect": "workspace:*",
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/affine-widget-frame-title": "workspace:*",
"@blocksuite/affine-widget-keyboard-toolbar": "workspace:*",
"@blocksuite/affine-widget-linked-doc": "workspace:*",
"@blocksuite/affine-widget-remote-selection": "workspace:*",
"@blocksuite/affine-widget-scroll-anchoring": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",

View File

@@ -34,6 +34,12 @@ const NotionClipboardConfig = ClipboardAdapterConfigExtension({
priority: 95,
});
const HtmlClipboardConfig = ClipboardAdapterConfigExtension({
mimeType: 'text/html',
adapter: HtmlAdapter,
priority: 90,
});
const imageClipboardConfigs = [
'image/apng',
'image/avif',
@@ -46,20 +52,14 @@ const imageClipboardConfigs = [
return ClipboardAdapterConfigExtension({
mimeType,
adapter: ImageAdapter,
priority: 85,
priority: 80,
});
});
const PlainTextClipboardConfig = ClipboardAdapterConfigExtension({
mimeType: 'text/plain',
adapter: MixTextAdapter,
priority: 80,
});
const HtmlClipboardConfig = ClipboardAdapterConfigExtension({
mimeType: 'text/html',
adapter: HtmlAdapter,
priority: 75,
priority: 70,
});
const AttachmentClipboardConfig = ClipboardAdapterConfigExtension({

View File

@@ -33,6 +33,7 @@ import {
ToolbarRegistryExtension,
} from '@blocksuite/affine-shared/services';
import { dragHandleWidget } from '@blocksuite/affine-widget-drag-handle';
import { linkedDocWidget } from '@blocksuite/affine-widget-linked-doc';
import { docRemoteSelectionWidget } from '@blocksuite/affine-widget-remote-selection';
import { scrollAnchoringWidget } from '@blocksuite/affine-widget-scroll-anchoring';
import { SlashMenuExtension } from '@blocksuite/affine-widget-slash-menu';
@@ -44,7 +45,7 @@ import { RootBlockAdapterExtensions } from '../adapters/extension';
import { clipboardConfigs } from '../clipboard';
import { builtinToolbarConfig } from '../configs/toolbar';
import { fallbackKeymap } from '../keyboard/keymap';
import { linkedDocWidget, modalWidget, viewportOverlayWidget } from './widgets';
import { viewportOverlayWidget } from './widgets';
/**
* Why do we add these extensions into CommonSpecs?
@@ -83,7 +84,6 @@ export const CommonSpecs: ExtensionType[] = [
...clipboardConfigs,
...EdgelessElementViews,
...EdgelessElementRendererExtension,
modalWidget,
SlashMenuExtension,
linkedDocWidget,
dragHandleWidget,

View File

@@ -1,20 +1,8 @@
import { WidgetViewExtension } from '@blocksuite/std';
import { literal, unsafeStatic } from 'lit/static-html.js';
import { AFFINE_LINKED_DOC_WIDGET } from '../widgets/linked-doc/config.js';
import { AFFINE_MODAL_WIDGET } from '../widgets/modal/modal.js';
import { AFFINE_VIEWPORT_OVERLAY_WIDGET } from '../widgets/viewport-overlay/viewport-overlay.js';
export const modalWidget = WidgetViewExtension(
'affine:page',
AFFINE_MODAL_WIDGET,
literal`${unsafeStatic(AFFINE_MODAL_WIDGET)}`
);
export const linkedDocWidget = WidgetViewExtension(
'affine:page',
AFFINE_LINKED_DOC_WIDGET,
literal`${unsafeStatic(AFFINE_LINKED_DOC_WIDGET)}`
);
export const viewportOverlayWidget = WidgetViewExtension(
'affine:page',
AFFINE_VIEWPORT_OVERLAY_WIDGET,

View File

@@ -10,6 +10,7 @@ import {
} from '@blocksuite/affine-block-embed';
import { updateBlockType } from '@blocksuite/affine-block-note';
import { toast } from '@blocksuite/affine-components/toast';
import { EditorChevronDown } from '@blocksuite/affine-components/toolbar';
import {
deleteTextCommand,
formatBlockCommand,
@@ -40,7 +41,6 @@ import { ActionPlacement } from '@blocksuite/affine-shared/services';
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';
import { tableViewMeta } from '@blocksuite/data-view/view-presets';
import {
ArrowDownSmallIcon,
CopyIcon,
DatabaseTableViewIcon,
DeleteIcon,
@@ -94,7 +94,7 @@ const conversionsActionGroup = {
aria-label="Conversions"
.tooltip="${'Turn into'}"
>
${conversion.icon} ${ArrowDownSmallIcon()}
${conversion.icon} ${EditorChevronDown}
</editor-icon-button>
`}
>

View File

@@ -88,6 +88,9 @@ export class EdgelessPageKeyboardManager extends PageKeyboardManager {
p: () => {
this._setEdgelessTool('brush');
},
'Shift-p': () => {
this._setEdgelessTool('highlighter');
},
e: () => {
this._setEdgelessTool('eraser');
},

View File

@@ -45,7 +45,6 @@ import { css, html } from 'lit';
import { query } from 'lit/decorators.js';
import { repeat } from 'lit/directives/repeat.js';
import type { EdgelessRootBlockWidgetName } from '../types.js';
import type { EdgelessSelectedRectWidget } from './components/rects/edgeless-selected-rect.js';
import { EdgelessPageKeyboardManager } from './edgeless-keyboard.js';
import type { EdgelessRootService } from './edgeless-root-service.js';
@@ -53,8 +52,7 @@ import { isCanvasElement } from './utils/query.js';
export class EdgelessRootBlockComponent extends BlockComponent<
RootBlockModel,
EdgelessRootService,
EdgelessRootBlockWidgetName
EdgelessRootService
> {
static override styles = css`
affine-edgeless-root {
@@ -351,7 +349,7 @@ export class EdgelessRootBlockComponent extends BlockComponent<
private _initWheelEvent() {
this._disposables.add(
this.dispatcher.add('wheel', ctx => {
const config = this.std.getOptional(EditorSettingProvider);
const config = this.std.getOptional(EditorSettingProvider)?.setting$;
const state = ctx.get('defaultState');
const e = state.event as WheelEvent;
const edgelessScrollZoom = config?.peek().edgelessScrollZoom ?? false;

View File

@@ -25,14 +25,12 @@ import { css, html } from 'lit';
import { query, state } from 'lit/decorators.js';
import { type StyleInfo, styleMap } from 'lit/directives/style-map.js';
import type { EdgelessRootBlockWidgetName } from '../types.js';
import type { EdgelessRootService } from './edgeless-root-service.js';
import { isCanvasElement } from './utils/query.js';
export class EdgelessRootPreviewBlockComponent extends BlockComponent<
RootBlockModel,
EdgelessRootService,
EdgelessRootBlockWidgetName
EdgelessRootService
> {
static override styles = css`
affine-edgeless-root-preview {
@@ -171,7 +169,7 @@ export class EdgelessRootPreviewBlockComponent extends BlockComponent<
}
private get _disableScheduleUpdate() {
const editorSetting = this.std.getOptional(EditorSettingProvider);
const editorSetting = this.std.getOptional(EditorSettingProvider)?.setting$;
return editorSetting?.peek().edgelessDisableScheduleUpdate ?? false;
}

View File

@@ -6,7 +6,6 @@ import {
type SurfaceBlockModel,
type SurfaceContext,
} from '@blocksuite/affine-block-surface';
import { TemplateJob } from '@blocksuite/affine-gfx-template';
import {
type ConnectorElementModel,
RootBlockSchema,
@@ -39,8 +38,6 @@ export class EdgelessRootService extends RootService implements SurfaceContext {
private readonly _surface: SurfaceBlockModel;
TemplateJob = TemplateJob;
get blocks(): GfxBlockElementModel[] {
return this.layer.blocks;
}

View File

@@ -7,6 +7,8 @@ import { effects as gfxShapeEffects } from '@blocksuite/affine-gfx-shape/effects
import { effects as gfxTemplateEffects } from '@blocksuite/affine-gfx-template/effects';
import { effects as gfxCanvasTextEffects } from '@blocksuite/affine-gfx-text/effects';
import { effects as widgetEdgelessToolbarEffects } from '@blocksuite/affine-widget-edgeless-toolbar/effects';
import { effects as widgetMobileToolbarEffects } from '@blocksuite/affine-widget-keyboard-toolbar/effects';
import { effects as widgetLinkedDocEffects } from '@blocksuite/affine-widget-linked-doc/effects';
import { EdgelessAutoCompletePanel } from './edgeless/components/auto-complete/auto-complete-panel.js';
import { EdgelessAutoComplete } from './edgeless/components/auto-complete/edgeless-auto-complete.js';
@@ -27,7 +29,6 @@ import { ToolbarArrowUpIcon } from './edgeless/components/toolbar/common/toolbar
import { EdgelessDefaultToolButton } from './edgeless/components/toolbar/default/default-tool-button.js';
import { EdgelessLinkToolButton } from './edgeless/components/toolbar/link/link-tool-button.js';
import {
AffineModalWidget,
EdgelessRootBlockComponent,
EdgelessRootPreviewBlockComponent,
PageRootBlockComponent,
@@ -43,11 +44,6 @@ import {
} from './widgets/edgeless-zoom-toolbar/index.js';
import { ZoomBarToggleButton } from './widgets/edgeless-zoom-toolbar/zoom-bar-toggle-button.js';
import { EdgelessZoomToolbar } from './widgets/edgeless-zoom-toolbar/zoom-toolbar.js';
import { effects as widgetMobileToolbarEffects } from './widgets/keyboard-toolbar/effects.js';
import { effects as widgetLinkedDocEffects } from './widgets/linked-doc/effects.js';
import { Loader } from './widgets/linked-doc/import-doc/loader.js';
import { AffineCustomModal } from './widgets/modal/custom-modal.js';
import { AFFINE_MODAL_WIDGET } from './widgets/modal/modal.js';
import {
AFFINE_PAGE_DRAGGING_AREA_WIDGET,
AffinePageDraggingAreaWidget,
@@ -93,7 +89,6 @@ function registerGfxEffects() {
}
function registerWidgets() {
customElements.define(AFFINE_MODAL_WIDGET, AffineModalWidget);
customElements.define(
AFFINE_PAGE_DRAGGING_AREA_WIDGET,
AffinePageDraggingAreaWidget
@@ -124,12 +119,6 @@ function registerEdgelessToolbarComponents() {
}
function registerMiscComponents() {
// Modal and menu components
customElements.define('affine-custom-modal', AffineCustomModal);
// Loading and preview components
customElements.define('loader-element', Loader);
// Toolbar and UI components
customElements.define('edgeless-zoom-toolbar', EdgelessZoomToolbar);
customElements.define('zoom-bar-toggle-button', ZoomBarToggleButton);

View File

@@ -8,9 +8,7 @@ export * from './page/page-root-block.js';
export { PageRootService } from './page/page-root-service.js';
export * from './page/page-root-spec.js';
export * from './preview/preview-root-block.js';
export * from './root-config.js';
export { RootService } from './root-service.js';
export * from './transformers/index.js';
export * from './types.js';
export * from './utils/index.js';
export * from './widgets/index.js';

View File

@@ -27,7 +27,6 @@ import { css, html } from 'lit';
import { query } from 'lit/decorators.js';
import { repeat } from 'lit/directives/repeat.js';
import type { PageRootBlockWidgetName } from '../index.js';
import { PageKeyboardManager } from '../keyboard/keyboard-manager.js';
import type { PageRootService } from './page-root-service.js';
@@ -52,8 +51,7 @@ function testClickOnBlankArea(
export class PageRootBlockComponent extends BlockComponent<
RootBlockModel,
PageRootService,
PageRootBlockWidgetName
PageRootService
> {
static override styles = css`
editor-host:has(> affine-page-root, * > affine-page-root) {

View File

@@ -1,20 +1,15 @@
import { ViewportElementExtension } from '@blocksuite/affine-shared/services';
import { keyboardToolbarWidget } from '@blocksuite/affine-widget-keyboard-toolbar';
import { IS_MOBILE } from '@blocksuite/global/env';
import { BlockViewExtension, WidgetViewExtension } from '@blocksuite/std';
import type { ExtensionType } from '@blocksuite/store';
import { literal, unsafeStatic } from 'lit/static-html.js';
import { PageClipboard } from '../clipboard/page-clipboard.js';
import { CommonSpecs } from '../common-specs/index.js';
import { AFFINE_KEYBOARD_TOOLBAR_WIDGET } from '../widgets/keyboard-toolbar/index.js';
import { AFFINE_PAGE_DRAGGING_AREA_WIDGET } from '../widgets/page-dragging-area/page-dragging-area.js';
import { PageRootService } from './page-root-service.js';
export const keyboardToolbarWidget = WidgetViewExtension(
'affine:page',
AFFINE_KEYBOARD_TOOLBAR_WIDGET,
literal`${unsafeStatic(AFFINE_KEYBOARD_TOOLBAR_WIDGET)}`
);
export const pageDraggingAreaWidget = WidgetViewExtension(
'affine:page',
AFFINE_PAGE_DRAGGING_AREA_WIDGET,
@@ -31,7 +26,7 @@ const PageCommonExtension: ExtensionType[] = [
export const PageRootBlockSpec: ExtensionType[] = [
...PageCommonExtension,
BlockViewExtension('affine:page', literal`affine-page-root`),
keyboardToolbarWidget,
IS_MOBILE ? [keyboardToolbarWidget] : [],
PageClipboard,
].flat();

View File

@@ -1,12 +0,0 @@
import { ConfigExtensionFactory } from '@blocksuite/std';
import type { KeyboardToolbarConfig } from './widgets/keyboard-toolbar/config.js';
import type { LinkedWidgetConfig } from './widgets/linked-doc/index.js';
export interface RootBlockConfig {
linkedWidget?: Partial<LinkedWidgetConfig>;
keyboardToolbar?: Partial<KeyboardToolbarConfig>;
}
export const RootBlockConfigExtension =
ConfigExtensionFactory<RootBlockConfig>('affine:root-block');

View File

@@ -1,48 +1,6 @@
import { RootBlockSchema } from '@blocksuite/affine-model';
import {
getBlockSelectionsCommand,
getImageSelectionsCommand,
getSelectedBlocksCommand,
getTextSelectionCommand,
} from '@blocksuite/affine-shared/commands';
import type { BlockComponent } from '@blocksuite/std';
import { BlockService } from '@blocksuite/std';
import type { RootBlockComponent } from './types.js';
export abstract class RootService extends BlockService {
static override readonly flavour = RootBlockSchema.model.flavour;
get selectedBlocks() {
let result: BlockComponent[] = [];
this.std.command
.chain()
.tryAll(chain => [
chain.pipe(getTextSelectionCommand),
chain.pipe(getImageSelectionsCommand),
chain.pipe(getBlockSelectionsCommand),
])
.pipe(getSelectedBlocksCommand)
.pipe(({ selectedBlocks }) => {
if (!selectedBlocks) return;
result = selectedBlocks;
})
.run();
return result;
}
get selectedModels() {
return this.selectedBlocks.map(block => block.model);
}
get viewportElement() {
const rootId = this.std.store.root?.id;
if (!rootId) return null;
const rootComponent = this.std.view.getBlock(
rootId
) as RootBlockComponent | null;
if (!rootComponent) return null;
const viewportElement = rootComponent.viewportElement;
return viewportElement;
}
}

View File

@@ -1,40 +1,5 @@
import type { AFFINE_DRAG_HANDLE_WIDGET } from '@blocksuite/affine-widget-drag-handle';
import type { AFFINE_FRAME_TITLE_WIDGET } from '@blocksuite/affine-widget-frame-title';
import type {
AFFINE_DOC_REMOTE_SELECTION_WIDGET,
AFFINE_EDGELESS_REMOTE_SELECTION_WIDGET,
} from '@blocksuite/affine-widget-remote-selection';
import type { AFFINE_SLASH_MENU_WIDGET } from '@blocksuite/affine-widget-slash-menu';
import type { EdgelessRootBlockComponent } from './edgeless/edgeless-root-block.js';
import type { PageRootBlockComponent } from './page/page-root-block.js';
import type { AFFINE_EDGELESS_ZOOM_TOOLBAR_WIDGET } from './widgets/edgeless-zoom-toolbar/index.js';
import type { AFFINE_KEYBOARD_TOOLBAR_WIDGET } from './widgets/index.js';
import type { AFFINE_LINKED_DOC_WIDGET } from './widgets/linked-doc/config.js';
import type { AFFINE_MODAL_WIDGET } from './widgets/modal/modal.js';
import type { AFFINE_PAGE_DRAGGING_AREA_WIDGET } from './widgets/page-dragging-area/page-dragging-area.js';
import type { AFFINE_VIEWPORT_OVERLAY_WIDGET } from './widgets/viewport-overlay/viewport-overlay.js';
export type PageRootBlockWidgetName =
| typeof AFFINE_KEYBOARD_TOOLBAR_WIDGET
| typeof AFFINE_MODAL_WIDGET
| typeof AFFINE_SLASH_MENU_WIDGET
| typeof AFFINE_LINKED_DOC_WIDGET
| typeof AFFINE_PAGE_DRAGGING_AREA_WIDGET
| typeof AFFINE_DRAG_HANDLE_WIDGET
| typeof AFFINE_DOC_REMOTE_SELECTION_WIDGET
| typeof AFFINE_VIEWPORT_OVERLAY_WIDGET;
export type EdgelessRootBlockWidgetName =
| typeof AFFINE_MODAL_WIDGET
| typeof AFFINE_SLASH_MENU_WIDGET
| typeof AFFINE_LINKED_DOC_WIDGET
| typeof AFFINE_DRAG_HANDLE_WIDGET
| typeof AFFINE_DOC_REMOTE_SELECTION_WIDGET
| typeof AFFINE_EDGELESS_REMOTE_SELECTION_WIDGET
| typeof AFFINE_EDGELESS_ZOOM_TOOLBAR_WIDGET
| typeof AFFINE_VIEWPORT_OVERLAY_WIDGET
| typeof AFFINE_FRAME_TITLE_WIDGET;
export type RootBlockComponent =
| PageRootBlockComponent

View File

@@ -1,18 +1,4 @@
export { AffineEdgelessZoomToolbarWidget } from './edgeless-zoom-toolbar/index.js';
export * from './keyboard-toolbar/index.js';
export {
type LinkedMenuAction,
type LinkedMenuGroup,
type LinkedMenuItem,
type LinkedWidgetConfig,
LinkedWidgetUtils,
} from './linked-doc/config.js';
export {
// It's used in the AFFiNE!
showImportModal,
} from './linked-doc/import-doc/index.js';
export { AffineLinkedDocWidget } from './linked-doc/index.js';
export { AffineModalWidget } from './modal/modal.js';
export { AffinePageDraggingAreaWidget } from './page-dragging-area/page-dragging-area.js';
export * from './viewport-overlay/viewport-overlay.js';
export { AffineFrameTitleWidget } from '@blocksuite/affine-widget-frame-title';

View File

@@ -1,144 +0,0 @@
import { css, html, LitElement, nothing } from 'lit';
import { ref } from 'lit/directives/ref.js';
import { repeat } from 'lit/directives/repeat.js';
type ModalButton = {
text: string;
type?: 'primary';
onClick: () => Promise<void> | void;
};
type ModalOptions = {
footer: null | ModalButton[];
};
export class AffineCustomModal extends LitElement {
static override styles = css`
:host {
z-index: calc(var(--affine-z-index-modal) + 3);
position: fixed;
top: 0;
left: 0;
width: 100vw;
height: 100vh;
}
.modal-background {
width: 100%;
height: 100%;
box-sizing: border-box;
align-items: center;
background-color: var(--affine-background-modal-color);
justify-content: center;
display: flex;
}
.modal-window {
width: 70%;
min-width: 500px;
height: 80%;
overflow-y: scroll;
background-color: var(--affine-background-overlay-panel-color);
border-radius: 12px;
box-shadow: var(--affine-shadow-3);
position: relative;
}
.modal-main {
height: 100%;
}
.modal-footer {
display: flex;
justify-content: flex-end;
gap: 20px;
padding: 24px;
position: absolute;
box-sizing: border-box;
bottom: 0;
right: 0;
}
.modal-footer .button {
align-items: center;
background: var(--affine-white);
border: 1px solid;
border-color: var(--affine-border-color);
border-radius: 8px;
color: var(--affine-text-primary-color);
cursor: pointer;
display: inline-flex;
font-size: var(--affine-font-sm);
font-weight: 500;
justify-content: center;
outline: 0;
padding: 12px 18px;
touch-action: manipulation;
transition: all 0.3s;
user-select: none;
}
.modal-footer .primary {
background: var(--affine-primary-color);
border-color: var(--affine-black-10);
box-shadow: var(--affine-button-inner-shadow);
color: var(--affine-pure-white);
}
`;
onOpen!: (div: HTMLDivElement) => void;
options!: ModalOptions;
close() {
this.remove();
}
modalRef(modal: Element | undefined) {
if (modal) this.onOpen?.(modal as HTMLDivElement);
}
override render() {
const { options } = this;
return html`<div class="modal-background">
<div class="modal-window">
<div class="modal-main" ${ref(this.modalRef)}></div>
<div class="modal-footer">
${options.footer
? repeat(
options.footer,
button => button.text,
button => html`
<button
class="button ${button.type ?? ''}"
@click=${button.onClick}
>
${button.text}
</button>
`
)
: nothing}
</div>
</div>
</div>`;
}
}
type CreateModalOption = ModalOptions & {
entry: (div: HTMLDivElement) => void;
};
export function createCustomModal(
options: CreateModalOption,
container: HTMLElement = document.body
) {
const modal = new AffineCustomModal();
modal.onOpen = options.entry;
modal.options = options;
container.append(modal);
return modal;
}

View File

@@ -1,22 +0,0 @@
import { WidgetComponent } from '@blocksuite/std';
import { nothing } from 'lit';
import { createCustomModal } from './custom-modal.js';
export const AFFINE_MODAL_WIDGET = 'affine-modal-widget';
export class AffineModalWidget extends WidgetComponent {
open(options: Parameters<typeof createCustomModal>[0]) {
return createCustomModal(options, this.ownerDocument.body);
}
override render() {
return nothing;
}
}
declare global {
interface HTMLElementTagNameMap {
[AFFINE_MODAL_WIDGET]: AffineModalWidget;
}
}

View File

@@ -43,6 +43,8 @@
{ "path": "../../widgets/edgeless-auto-connect" },
{ "path": "../../widgets/edgeless-toolbar" },
{ "path": "../../widgets/frame-title" },
{ "path": "../../widgets/keyboard-toolbar" },
{ "path": "../../widgets/linked-doc" },
{ "path": "../../widgets/remote-selection" },
{ "path": "../../widgets/scroll-anchoring" },
{ "path": "../../widgets/slash-menu" },

View File

@@ -321,7 +321,7 @@ export const calcCustomButtonStyle = (
return { '--b': b, '--c': c };
}
if (color.startsWith('---')) {
if (color.startsWith('--')) {
if (!color.endsWith('transparent')) {
b = 'var(--affine-background-overlay-panel-color)';
c = keepColor(

View File

@@ -38,11 +38,11 @@ const styles = css`
transition: 0.1s;
}
label.subscribe {
label.on {
background: var(--affine-primary-color);
}
label.subscribe:after {
label.on:after {
left: calc(100% - 1px);
transform: translateX(-100%);
}

View File

@@ -1,5 +1,6 @@
import { css, html, LitElement } from 'lit';
import { property } from 'lit/decorators.js';
import { repeat } from 'lit-html/directives/repeat.js';
export class TooltipContentWithShortcut extends LitElement {
static override styles = css`
@@ -9,6 +10,10 @@ export class TooltipContentWithShortcut extends LitElement {
align-items: center;
gap: 10px;
}
.tooltip__shortcuts {
display: flex;
gap: 2px;
}
.tooltip__shortcut {
font-size: 12px;
position: relative;
@@ -28,19 +33,30 @@ export class TooltipContentWithShortcut extends LitElement {
opacity: 0.2;
}
.tooltip__label {
display: flex;
flex: 1;
white-space: pre;
}
`;
get shortcuts() {
let shortcut = this.shortcut;
if (!shortcut) return [];
return shortcut.split(' ');
}
override render() {
const { tip, shortcut, postfix } = this;
const { tip, shortcuts, postfix } = this;
return html`
<div class="tooltip-with-shortcut">
<span class="tooltip__label">${tip}</span>
${shortcut
? html`<span class="tooltip__shortcut">${shortcut}</span>`
: ''}
<div class="tooltip__shortcuts">
${repeat(
shortcuts,
shortcut => html`<span class="tooltip__shortcut">${shortcut}</span>`
)}
</div>
${postfix ? html`<span class="tooltip__postfix">${postfix}</span>` : ''}
</div>
`;

View File

@@ -26,10 +26,10 @@ export const cardPreview = style({
borderRadius: '4px',
cursor: 'default',
userSelect: 'none',
':hover': {
background: cssVarV2('layer/background/hoverOverlay'),
},
selectors: {
[`${outlineCard}[data-sortable="true"] &:hover`]: {
background: cssVarV2('layer/background/hoverOverlay'),
},
[`${outlineCard}[data-status="selected"] &`]: {
background: cssVarV2('layer/background/hoverOverlay'),
},

View File

@@ -1,6 +1,6 @@
import { cssVar } from '@toeverything/theme';
import { cssVarV2 } from '@toeverything/theme/v2';
import { style } from '@vanilla-extract/css';
import { globalStyle, style } from '@vanilla-extract/css';
export const outlineBlockPreview = style({
fontFamily: cssVar('fontFamily'),
@@ -108,6 +108,11 @@ export const linkedDocPreviewUnavailable = style({
color: cssVarV2('text/disable'),
});
export const linkedDocPreviewAvailable = style({});
globalStyle(`${linkedDocPreviewAvailable} > svg`, {
marginBottom: '0.1em',
});
export const linkedDocTextUnavailable = style({
color: cssVarV2('text/disable'),
textDecoration: 'line-through',

View File

@@ -67,6 +67,7 @@ export class OutlineBlockPreview extends SignalWatcher(
return html`<span
class=${classMap({
[styles.linkedDocPreviewUnavailable]: unavailable,
[styles.linkedDocPreviewAvailable]: !unavailable,
})}
>
${icon}

View File

@@ -0,0 +1,29 @@
import {
EdgelessBrushDarkIcon,
EdgelessBrushLightIcon,
EdgelessHighlighterDarkIcon,
EdgelessHighlighterLightIcon,
} from './icons';
import type { Pen } from './types';
export const penIconMap = {
dark: {
brush: EdgelessBrushDarkIcon,
highlighter: EdgelessHighlighterDarkIcon,
},
light: {
brush: EdgelessBrushLightIcon,
highlighter: EdgelessHighlighterLightIcon,
},
};
export const penInfoMap: { [k in Pen]: { tip: string; shortcut: string } } = {
brush: {
tip: 'Pen',
shortcut: 'P',
},
highlighter: {
tip: 'Highlighter',
shortcut: '⇧ P',
},
};

View File

@@ -7,11 +7,16 @@ import {
import type { ColorEvent } from '@blocksuite/affine-shared/utils';
import { EdgelessToolbarToolMixin } from '@blocksuite/affine-widget-edgeless-toolbar';
import { SignalWatcher } from '@blocksuite/global/lit';
import { computed, type Signal } from '@preact/signals-core';
import {
computed,
type ReadonlySignal,
type Signal,
} from '@preact/signals-core';
import { css, html, LitElement, type TemplateResult } from 'lit';
import { property } from 'lit/decorators.js';
import { styleMap } from 'lit/directives/style-map.js';
import { penInfoMap } from './consts';
import type { Pen, PenMap } from './types';
export class EdgelessPenMenu extends EdgelessToolbarToolMixin(
@@ -26,8 +31,14 @@ export class EdgelessPenMenu extends EdgelessToolbarToolMixin(
.pens {
display: flex;
height: 100%;
padding: 0 4px;
align-items: center;
align-items: flex-end;
edgeless-tool-icon-button {
display: flex;
align-self: flex-start;
}
.pen-wrapper {
display: flex;
@@ -36,7 +47,7 @@ export class EdgelessPenMenu extends EdgelessToolbarToolMixin(
align-items: flex-end;
justify-content: center;
position: relative;
transform: translateY(10px);
transform: translateY(-2px);
transition-property: color, transform;
transition-duration: 300ms;
transition-timing-function: ease-in-out;
@@ -46,7 +57,7 @@ export class EdgelessPenMenu extends EdgelessToolbarToolMixin(
.pen-wrapper:hover,
.pen-wrapper:active,
.pen-wrapper[data-active] {
transform: translateY(-10px);
transform: translateY(-22px);
}
}
@@ -56,6 +67,8 @@ export class EdgelessPenMenu extends EdgelessToolbarToolMixin(
}
menu-divider {
display: flex;
align-self: center;
height: 24px;
margin: 0 9px;
}
@@ -83,42 +96,64 @@ export class EdgelessPenMenu extends EdgelessToolbarToolMixin(
override render() {
const {
_theme$: { value: theme },
color$: { value: currentColor },
colors$: {
value: { brush: brushColor, highlighter: highlighterColor },
},
pen$: { value: pen },
penIconMap$: {
value: { brush: brushIcon, highlighter: highlighterIcon },
},
penInfo$: {
value: { type, color },
},
} = this;
return html`
<edgeless-slide-menu>
<div class="pens" slot="prefix">
<div
class="pen-wrapper edgeless-brush-button"
?data-active="${pen === 'brush'}"
style=${styleMap({ color: brushColor })}
<edgeless-tool-icon-button
class="edgeless-brush-button"
.tooltip=${html`<affine-tooltip-content-with-shortcut
data-tip="${penInfoMap.brush.tip}"
data-shortcut="${penInfoMap.brush.shortcut}"
></affine-tooltip-content-with-shortcut>`}
.tooltipOffset=${20}
.hover=${false}
@click=${() => this._onPickPen('brush')}
>
${brushIcon}
</div>
<div
class="pen-wrapper edgeless-highlighter-button"
?data-active="${pen === 'highlighter'}"
style=${styleMap({ color: highlighterColor })}
<div
class="pen-wrapper"
style=${styleMap({ color: brushColor })}
?data-active="${type === 'brush'}"
>
${brushIcon}
</div>
</edgeless-tool-icon-button>
<edgeless-tool-icon-button
class="edgeless-highlighter-button"
.tooltip=${html`<affine-tooltip-content-with-shortcut
data-tip="${penInfoMap.highlighter.tip}"
data-shortcut="${penInfoMap.highlighter.shortcut}"
></affine-tooltip-content-with-shortcut>`}
.tooltipOffset=${20}
.hover=${false}
@click=${() => this._onPickPen('highlighter')}
>
${highlighterIcon}
</div>
<div
class="pen-wrapper"
style=${styleMap({ color: highlighterColor })}
?data-active="${type === 'highlighter'}"
>
${highlighterIcon}
</div>
</edgeless-tool-icon-button>
<menu-divider .vertical=${true}></menu-divider>
</div>
<div class="menu-content">
<edgeless-color-panel
class="one-way"
@select=${this._onPickColor}
.value=${currentColor}
.value=${color}
.theme=${theme}
.palettes=${DefaultTheme.StrokeColorShortPalettes}
.shouldKeepColor=${true}
@@ -135,14 +170,20 @@ export class EdgelessPenMenu extends EdgelessToolbarToolMixin(
accessor onChange!: (props: Record<string, unknown>) => void;
@property({ attribute: false })
accessor colors$!: Signal<PenMap<string>>;
accessor colors$!: ReadonlySignal<PenMap<string>>;
@property({ attribute: false })
accessor color$!: Signal<string>;
accessor penIconMap$!: ReadonlySignal<PenMap<TemplateResult>>;
@property({ attribute: false })
accessor pen$!: Signal<Pen>;
@property({ attribute: false })
accessor penIconMap$!: Signal<PenMap<TemplateResult>>;
accessor penInfo$!: ReadonlySignal<{
type: Pen;
color: string;
icon: TemplateResult<1>;
tip: string;
shortcut: string;
}>;
}

View File

@@ -10,7 +10,7 @@ import { css, html, LitElement, nothing } from 'lit';
import { styleMap } from 'lit/directives/style-map.js';
import { when } from 'lit/directives/when.js';
import { penIconMap } from './icons';
import { penIconMap, penInfoMap } from './consts';
import type { Pen } from './types';
export class EdgelessPenToolButton extends EdgelessToolbarToolMixin(
@@ -81,6 +81,18 @@ export class EdgelessPenToolButton extends EdgelessToolbarToolMixin(
return this.penIconMap$.value[pen];
});
private readonly penInfo$ = computed(() => {
const type = this.pen$.value;
const icon = this.penIcon$.value;
const color = this.color$.value;
return {
...penInfoMap[type],
color,
icon,
type,
};
});
private readonly pen$ = signal<Pen>('brush');
override enableActiveBackground = true;
@@ -89,9 +101,20 @@ export class EdgelessPenToolButton extends EdgelessToolbarToolMixin(
override firstUpdated() {
this.disposables.add(
this.gfx.tool.currentToolName$.subscribe(tool => {
if (this.type.map(String).includes(tool)) return;
this.tryDisposePopper();
this.gfx.tool.currentToolName$.subscribe(name => {
const tool = this.type.find(t => t === name);
if (!tool) {
this.tryDisposePopper();
return;
}
if (tool !== this.pen$.peek()) {
this.pen$.value = tool;
}
if (this.active) return;
this._togglePenMenu();
})
);
}
@@ -101,10 +124,10 @@ export class EdgelessPenToolButton extends EdgelessToolbarToolMixin(
!this.active && this.setEdgelessTool(this.pen$.peek());
const menu = this.createPopper('edgeless-pen-menu', this);
Object.assign(menu.element, {
color$: this.color$,
colors$: this.colors$,
pen$: this.pen$,
penIconMap$: this.penIconMap$,
pen$: this.pen$,
penInfo$: this.penInfo$,
edgeless: this.edgeless,
onChange: (props: Record<string, unknown>) => {
const pen = this.pen$.peek();
@@ -117,20 +140,22 @@ export class EdgelessPenToolButton extends EdgelessToolbarToolMixin(
override render() {
const {
active,
penIcon$: { value: icon },
color$: { value: color },
penInfo$: {
value: { type, color, icon, tip, shortcut },
},
} = this;
return html`
<edgeless-toolbar-button
class="edgeless-pen-button"
data-drawing-tool="${type}"
.tooltip=${when(
this.popper,
() => nothing,
() =>
html`<affine-tooltip-content-with-shortcut
data-tip="${'Pen'}"
data-shortcut="${'P'}"
data-tip="${tip}"
data-shortcut="${shortcut}"
></affine-tooltip-content-with-shortcut>`
)}
.tooltipOffset=${4}

View File

@@ -73,16 +73,20 @@ export const TurboRendererConfigFactory =
export class ViewportTurboRendererExtension extends GfxExtension {
static override key = 'viewportTurboRenderer';
private readonly state$ = new BehaviorSubject<RenderingState>('inactive');
public readonly state$ = new BehaviorSubject<RenderingState>('inactive');
public readonly canvas: HTMLCanvasElement = document.createElement('canvas');
public layoutCacheData: ViewportLayoutTree | null = null;
private readonly worker: Worker;
private readonly disposables = new DisposableGroup();
private layoutCacheData: ViewportLayoutTree | null = null;
private layoutVersion = 0;
private bitmap: ImageBitmap | null = null;
private viewportElement: GfxViewportElement | null = null;
private readonly refresh$ = new Subject<void>();
public get currentState(): RenderingState {
return this.state$.value;
}
constructor(gfx: GfxController) {
super(gfx);

View File

@@ -29,13 +29,23 @@ export const markdownFootnoteReferenceToDeltaMatcher =
const footnoteReference = FootNoteReferenceParamsSchema.parse(
footnoteDefinitionJson
);
// If the footnote reference is an attachment, and the file type is not set,
// Try to infer the file type from the file name.
const { type: referenceType, fileName, fileType } = footnoteReference;
if (referenceType === 'attachment' && fileName && !fileType) {
const ext = fileName.split('.').pop()?.toLowerCase();
if (ext) {
footnoteReference.fileType = ext;
}
}
const footnote = {
label: ast.identifier,
reference: footnoteReference,
};
return [{ insert: ' ', attributes: { footnote } }];
} catch (error) {
console.warn('Error parsing footnote reference', error);
} catch {
return [];
}
},

View File

@@ -1,4 +1,5 @@
import { HoverController } from '@blocksuite/affine-components/hover';
import { PeekViewProvider } from '@blocksuite/affine-components/peek';
import type { FootNote } from '@blocksuite/affine-model';
import { unsafeCSSVarV2 } from '@blocksuite/affine-shared/theme';
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';
@@ -12,11 +13,11 @@ import {
import {
INLINE_ROOT_ATTR,
type InlineRootElement,
ZERO_WIDTH_NON_JOINER,
ZERO_WIDTH_SPACE,
ZERO_WIDTH_FOR_EMBED_NODE,
ZERO_WIDTH_FOR_EMPTY_LINE,
} from '@blocksuite/std/inline';
import type { DeltaInsert } from '@blocksuite/store';
import { shift } from '@floating-ui/dom';
import { flip, offset, shift } from '@floating-ui/dom';
import { baseTheme } from '@toeverything/theme';
import { css, html, nothing, unsafeCSS } from 'lit';
import { property } from 'lit/decorators.js';
@@ -27,6 +28,8 @@ import type { FootNoteNodeConfigProvider } from './footnote-config';
// Virtual padding for the footnote popup overflow detection offsets.
const POPUP_SHIFT_PADDING = 8;
// The offset between the footnote node and the popup.
const POPUP_OFFSET = 4;
export class AffineFootnoteNode extends WithDisposable(ShadowlessElement) {
static override styles = css`
@@ -105,8 +108,55 @@ export class AffineFootnoteNode extends WithDisposable(ShadowlessElement) {
return selfInlineRange;
}
get footnote() {
return this.delta.attributes?.footnote;
}
get readonly() {
return this.std.store.readonly;
}
onFootnoteClick = () => {
if (!this.footnote) {
return;
}
const { type, docId, url } = this.footnote.reference;
switch (type) {
case 'doc':
if (docId) {
this._handleDocReference(docId);
}
break;
case 'url':
if (url) {
this._handleUrlReference(url);
}
break;
}
};
private readonly _handleDocReference = (docId: string) => {
if (this.readonly) {
return;
}
this.std
.getOptional(PeekViewProvider)
?.peek({
docId,
})
.catch(console.error);
};
private readonly _handleUrlReference = (url: string) => {
window.open(url, '_blank');
};
private readonly _FootNoteDefaultContent = (footnote: FootNote) => {
return html`<span class="footnote-content-default"
return html`<span
class="footnote-content-default"
@click=${this.onFootnoteClick}
>${footnote.label}</span
>`;
};
@@ -121,14 +171,14 @@ export class AffineFootnoteNode extends WithDisposable(ShadowlessElement) {
.footnote=${footnote}
.std=${this.std}
.abortController=${abortController}
.onPopupClick=${this.onPopupClick}
.onPopupClick=${this.onPopupClick ?? this.onFootnoteClick}
></footnote-popup>`;
};
private readonly _whenHover: HoverController = new HoverController(
this,
({ abortController }) => {
const footnote = this.delta.attributes?.footnote;
const { footnote } = this;
if (!footnote) return null;
if (
@@ -155,12 +205,16 @@ export class AffineFootnoteNode extends WithDisposable(ShadowlessElement) {
return {
template: this._FootNotePopup(footnote, abortController),
container: this,
container: this.std.host,
computePosition: {
referenceElement: this,
placement: 'top',
autoUpdate: true,
middleware: [shift({ padding: POPUP_SHIFT_PADDING })],
middleware: [
shift({ padding: POPUP_SHIFT_PADDING }),
flip(),
offset(POPUP_OFFSET),
],
},
};
},
@@ -186,7 +240,7 @@ export class AffineFootnoteNode extends WithDisposable(ShadowlessElement) {
return html`<span
${this.hidePopup ? '' : ref(this._whenHover.setReference)}
class=${nodeClasses}
>${node}<v-text .str=${ZERO_WIDTH_NON_JOINER}></v-text
>${node}<v-text .str=${ZERO_WIDTH_FOR_EMBED_NODE}></v-text
></span>`;
}
@@ -195,7 +249,7 @@ export class AffineFootnoteNode extends WithDisposable(ShadowlessElement) {
@property({ type: Object })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
attributes: {},
};

View File

@@ -9,48 +9,42 @@ export class FootNotePopupChip extends LitElement {
border-radius: 4px;
max-width: 173px;
height: 24px;
padding: 2px 4px;
padding: 4px;
align-items: center;
gap: 4px;
gap: 8px;
box-sizing: border-box;
cursor: default;
transition: width 0.3s ease-in-out;
}
.prefix-icon,
.suffix-icon {
.prefix-icon {
display: flex;
align-items: center;
justify-content: center;
width: 16px;
height: 16px;
width: 16px;
color: ${unsafeCSSVarV2('icon/primary')};
border-radius: 4px;
svg,
object {
img {
width: 16px;
height: 16px;
fill: ${unsafeCSSVarV2('icon/primary')};
}
}
.suffix-icon:hover {
background-color: ${unsafeCSSVarV2('layer/background/hoverOverlay')};
cursor: pointer;
}
.popup-chip-label {
flex: 1;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
text-align: left;
height: 20px;
line-height: 20px;
height: 22px;
line-height: 22px;
color: ${unsafeCSSVarV2('text/primary')};
font-size: 12px;
font-weight: 400;
font-size: var(--affine-font-sm);
font-weight: 500;
}
`;
@@ -63,11 +57,6 @@ export class FootNotePopupChip extends LitElement {
</div>`
: nothing}
<div class="popup-chip-label" title=${this.tooltip}>${this.label}</div>
${this.suffixIcon
? html`<div class="suffix-icon" @click=${this.onSuffixClick}>
${this.suffixIcon}
</div>`
: nothing}
</div>
`;
}
@@ -78,9 +67,6 @@ export class FootNotePopupChip extends LitElement {
@property({ attribute: false })
accessor label: string = '';
@property({ attribute: false })
accessor suffixIcon: TemplateResult | undefined = undefined;
@property({ attribute: false })
accessor tooltip: string = '';
@@ -89,7 +75,4 @@ export class FootNotePopupChip extends LitElement {
@property({ attribute: false })
accessor onPrefixClick: (() => void) | undefined = undefined;
@property({ attribute: false })
accessor onSuffixClick: (() => void) | undefined = undefined;
}

View File

@@ -4,7 +4,6 @@ import {
LightLoadingIcon,
WebIcon16,
} from '@blocksuite/affine-components/icons';
import { PeekViewProvider } from '@blocksuite/affine-components/peek';
import { ColorScheme, type FootNote } from '@blocksuite/affine-model';
import {
DocDisplayMetaProvider,
@@ -13,10 +12,9 @@ import {
} from '@blocksuite/affine-shared/services';
import { unsafeCSSVar, unsafeCSSVarV2 } from '@blocksuite/affine-shared/theme';
import { SignalWatcher, WithDisposable } from '@blocksuite/global/lit';
import { DualLinkIcon, LinkIcon } from '@blocksuite/icons/lit';
import type { BlockStdScope } from '@blocksuite/std';
import { computed, signal } from '@preact/signals-core';
import { css, html, LitElement, type TemplateResult } from 'lit';
import { css, html, LitElement } from 'lit';
import { property } from 'lit/decorators.js';
import type { FootNotePopupClickHandler } from './footnote-config';
@@ -57,36 +55,11 @@ export class FootNotePopup extends SignalWatcher(WithDisposable(LitElement)) {
}
const favicon = this._linkPreview$.value?.favicon;
if (!favicon) {
return undefined;
}
const titleIconType =
favicon.split('.').pop() === 'svg'
? 'svg+xml'
: favicon.split('.').pop();
const titleIcon = html`<object
type="image/${titleIconType}"
data=${favicon}
draggable="false"
>
${WebIcon16}
</object>`;
return titleIcon;
return favicon ? html`<img src=${favicon} alt="favicon" />` : WebIcon16;
}
return undefined;
});
private readonly _suffixIcon = (): TemplateResult | undefined => {
const referenceType = this.footnote.reference.type;
if (referenceType === 'doc') {
return DualLinkIcon({ width: '16px', height: '16px' });
} else if (referenceType === 'url') {
return LinkIcon({ width: '16px', height: '16px' });
}
return undefined;
};
private readonly _popupLabel$ = computed(() => {
const referenceType = this.footnote.reference.type;
let label = '';
@@ -127,50 +100,9 @@ export class FootNotePopup extends SignalWatcher(WithDisposable(LitElement)) {
return theme === ColorScheme.Light ? LightLoadingIcon : DarkLoadingIcon;
};
/**
* When clicking the chip, we will navigate to the reference doc or open the url
*/
private readonly _handleDocReference = (docId: string) => {
this.std
.getOptional(PeekViewProvider)
?.peek({
docId,
})
.catch(console.error);
};
private readonly _handleUrlReference = (url: string) => {
window.open(url, '_blank');
};
private readonly _handleReference = () => {
const { type, docId, url } = this.footnote.reference;
switch (type) {
case 'doc':
if (docId) {
this._handleDocReference(docId);
}
break;
case 'url':
if (url) {
this._handleUrlReference(url);
}
break;
}
this.abortController.abort();
};
private readonly _onChipClick = () => {
// If the onPopupClick is defined, use it
if (this.onPopupClick) {
this.onPopupClick(this.footnote, this.abortController);
return;
}
// Otherwise, handle the reference by default
this._handleReference();
this.onPopupClick(this.footnote, this.abortController);
this.abortController.abort();
};
override connectedCallback() {
@@ -199,7 +131,6 @@ export class FootNotePopup extends SignalWatcher(WithDisposable(LitElement)) {
<footnote-popup-chip
.prefixIcon=${this._prefixIcon$.value}
.label=${this._popupLabel$.value}
.suffixIcon=${this._suffixIcon()}
.onClick=${this._onChipClick}
.tooltip=${this._tooltip$.value}
></footnote-popup-chip>
@@ -217,5 +148,5 @@ export class FootNotePopup extends SignalWatcher(WithDisposable(LitElement)) {
accessor abortController!: AbortController;
@property({ attribute: false })
accessor onPopupClick: FootNotePopupClickHandler | undefined = undefined;
accessor onPopupClick: FootNotePopupClickHandler | (() => void) = () => {};
}

View File

@@ -1,6 +1,6 @@
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';
import { ShadowlessElement } from '@blocksuite/std';
import { ZERO_WIDTH_SPACE } from '@blocksuite/std/inline';
import { ZERO_WIDTH_FOR_EMPTY_LINE } from '@blocksuite/std/inline';
import type { DeltaInsert } from '@blocksuite/store';
import { html } from 'lit';
import { property } from 'lit/decorators.js';
@@ -50,6 +50,6 @@ export class LatexEditorUnit extends ShadowlessElement {
@property({ attribute: false })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
};
}

View File

@@ -9,8 +9,8 @@ import {
} from '@blocksuite/std';
import {
type InlineEditor,
ZERO_WIDTH_NON_JOINER,
ZERO_WIDTH_SPACE,
ZERO_WIDTH_FOR_EMBED_NODE,
ZERO_WIDTH_FOR_EMPTY_LINE,
} from '@blocksuite/std/inline';
import type { DeltaInsert } from '@blocksuite/store';
import { signal } from '@preact/signals-core';
@@ -178,7 +178,7 @@ export class AffineLatexNode extends SignalWatcher(
override render() {
return html`<span class="affine-latex" data-selected=${this.selected}
><div class="latex-container"></div>
<v-text .str=${ZERO_WIDTH_NON_JOINER}></v-text
<v-text .str=${ZERO_WIDTH_FOR_EMBED_NODE}></v-text
></span>`;
}
@@ -244,7 +244,7 @@ export class AffineLatexNode extends SignalWatcher(
@property({ attribute: false })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
};
@property({ attribute: false })

View File

@@ -13,7 +13,7 @@ import { BLOCK_ID_ATTR, ShadowlessElement } from '@blocksuite/std';
import {
INLINE_ROOT_ATTR,
type InlineRootElement,
ZERO_WIDTH_SPACE,
ZERO_WIDTH_FOR_EMPTY_LINE,
} from '@blocksuite/std/inline';
import type { DeltaInsert } from '@blocksuite/store';
import { css, html } from 'lit';
@@ -177,7 +177,7 @@ export class AffineLink extends WithDisposable(ShadowlessElement) {
@property({ type: Object })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
};
@property({ attribute: false })

View File

@@ -5,8 +5,8 @@ import { SignalWatcher, WithDisposable } from '@blocksuite/global/lit';
import type { BlockStdScope } from '@blocksuite/std';
import { ShadowlessElement } from '@blocksuite/std';
import {
ZERO_WIDTH_NON_JOINER,
ZERO_WIDTH_SPACE,
ZERO_WIDTH_FOR_EMBED_NODE,
ZERO_WIDTH_FOR_EMPTY_LINE,
} from '@blocksuite/std/inline';
import type { DeltaInsert } from '@blocksuite/store';
import { css, html } from 'lit';
@@ -88,7 +88,7 @@ export class AffineMention extends SignalWatcher(
data-selected=${this.selected}
data-type="error"
class="affine-mention"
>@Unknown Member<v-text .str=${ZERO_WIDTH_NON_JOINER}></v-text
>@Unknown Member<v-text .str=${ZERO_WIDTH_FOR_EMBED_NODE}></v-text
></span>`;
const userService = this.std.getOptional(UserProvider);
@@ -107,7 +107,7 @@ export class AffineMention extends SignalWatcher(
data-selected=${this.selected}
data-type="removed"
class="affine-mention"
>@Inactive Member<v-text .str=${ZERO_WIDTH_NON_JOINER}></v-text
>@Inactive Member<v-text .str=${ZERO_WIDTH_FOR_EMBED_NODE}></v-text
></span>`;
} else {
return html`<span
@@ -115,7 +115,7 @@ export class AffineMention extends SignalWatcher(
data-type="default"
class="affine-mention"
>@${userInfo$.value.name ?? 'Unknown'}<v-text
.str=${ZERO_WIDTH_NON_JOINER}
.str=${ZERO_WIDTH_FOR_EMBED_NODE}
></v-text
></span>`;
}
@@ -129,7 +129,7 @@ export class AffineMention extends SignalWatcher(
>@loading<span class="dots"
><span class="dot">.</span><span class="dot">.</span
><span class="dot">.</span></span
><v-text .str=${ZERO_WIDTH_NON_JOINER}></v-text
><v-text .str=${ZERO_WIDTH_FOR_EMBED_NODE}></v-text
></span>`;
}
@@ -138,7 +138,7 @@ export class AffineMention extends SignalWatcher(
@property({ type: Object })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
attributes: {},
};

View File

@@ -1,7 +1,7 @@
import { affineTextStyles } from '@blocksuite/affine-shared/styles';
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';
import { ShadowlessElement } from '@blocksuite/std';
import { ZERO_WIDTH_SPACE } from '@blocksuite/std/inline';
import { ZERO_WIDTH_FOR_EMPTY_LINE } from '@blocksuite/std/inline';
import type { DeltaInsert } from '@blocksuite/store';
import { html } from 'lit';
import { property } from 'lit/decorators.js';
@@ -30,6 +30,6 @@ export class AffineText extends ShadowlessElement {
@property({ type: Object })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
};
}

View File

@@ -22,8 +22,8 @@ import { BLOCK_ID_ATTR, ShadowlessElement } from '@blocksuite/std';
import {
INLINE_ROOT_ATTR,
type InlineRootElement,
ZERO_WIDTH_NON_JOINER,
ZERO_WIDTH_SPACE,
ZERO_WIDTH_FOR_EMBED_NODE,
ZERO_WIDTH_FOR_EMPTY_LINE,
} from '@blocksuite/std/inline';
import type { DeltaInsert, DocMeta, Store } from '@blocksuite/store';
import { css, html, nothing } from 'lit';
@@ -49,6 +49,10 @@ export class AffineReference extends WithDisposable(ShadowlessElement) {
cursor: pointer;
user-select: none;
padding: 1px 2px 1px 0;
svg {
margin-bottom: 0.1em;
}
}
.affine-reference:hover {
background: var(--affine-hover-color);
@@ -274,14 +278,14 @@ export class AffineReference extends WithDisposable(ShadowlessElement) {
>${title}</span
>`;
// we need to add `<v-text .str=${ZERO_WIDTH_NON_JOINER}></v-text>` in an
// we need to add `<v-text .str=${ZERO_WIDTH_FOR_EMBED_NODE}></v-text>` in an
// embed element to make sure inline range calculation is correct
return html`<span
data-selected=${this.selected}
class="affine-reference"
style=${styleMap(style)}
@click=${(event: MouseEvent) => this.open({ event })}
>${content}<v-text .str=${ZERO_WIDTH_NON_JOINER}></v-text
>${content}<v-text .str=${ZERO_WIDTH_FOR_EMBED_NODE}></v-text
></span>`;
}
@@ -299,7 +303,7 @@ export class AffineReference extends WithDisposable(ShadowlessElement) {
@property({ type: Object })
accessor delta: DeltaInsert<AffineTextAttributes> = {
insert: ZERO_WIDTH_SPACE,
insert: ZERO_WIDTH_FOR_EMPTY_LINE,
attributes: {},
};

View File

@@ -33,7 +33,7 @@ export const CalloutBlockSchema = defineBlockSchema({
'affine:edgeless-text',
'affine:transcription',
],
children: ['affine:paragraph'],
children: ['affine:paragraph', 'affine:list'],
},
toModel: () => new CalloutBlockModel(),
});

View File

@@ -43,6 +43,7 @@ export const ListBlockSchema = defineBlockSchema({
'affine:list',
'affine:paragraph',
'affine:edgeless-text',
'affine:callout',
],
},
toModel: () => new ListBlockModel(),

View File

@@ -22,6 +22,7 @@ export {
type BlockMarkdownAdapterMatcher,
BlockMarkdownAdapterMatcherIdentifier,
FOOTNOTE_DEFINITION_PREFIX,
IN_PARAGRAPH_NODE_CONTEXT_KEY,
InlineDeltaToMarkdownAdapterExtension,
type InlineDeltaToMarkdownAdapterMatcher,
InlineDeltaToMarkdownAdapterMatcherIdentifier,

View File

@@ -17,3 +17,4 @@ export const isMarkdownAST = (node: unknown): node is MarkdownAST =>
(node as MarkdownAST).type !== undefined;
export const FOOTNOTE_DEFINITION_PREFIX = 'footnoteDefinition:';
export const IN_PARAGRAPH_NODE_CONTEXT_KEY = 'mdast:paragraph';

View File

@@ -11,12 +11,16 @@ export const surfaceRefToEmbed =
}
});
slots.beforeImport.subscribe(payload => {
// only handle surface-ref block snapshot
if (
pageId &&
payload.type === 'block' &&
payload.snapshot.flavour === 'affine:surface-ref' &&
!std.store.hasBlock(payload.snapshot.id)
) {
payload.type !== 'block' ||
payload.snapshot.flavour !== 'affine:surface-ref'
)
return;
// turn into embed-linked-doc if the current doc is different from the pageId of the surface-ref block
const isNotSameDoc = pageId !== std.store.doc.id;
if (pageId && isNotSameDoc) {
// The blockId of the original surface-ref block
const blockId = payload.snapshot.id;
payload.snapshot.id = std.workspace.idGenerator();

View File

@@ -217,7 +217,7 @@ export class DocDisplayMetaService
function iconBuilder(
icon: typeof PageIcon,
size = '1.25em',
style = 'user-select:none;flex-shrink:0;vertical-align:middle;font-size:inherit;margin-bottom:0.1em;'
style = 'user-select:none;flex-shrink:0;vertical-align:middle;font-size:inherit;'
) {
return icon({ width: size, height: size, style });
}

View File

@@ -98,7 +98,9 @@ export class EditPropsStore extends LifeCycleWatcher {
);
this.lastProps$ = computed(() => {
const editorSetting$ = this.std.getOptional(EditorSettingProvider);
const editorSetting$ = this.std.getOptional(
EditorSettingProvider
)?.setting$;
const nextProps = mergeWith(
clonedeep(initProps),
editorSetting$?.value,

View File

@@ -10,21 +10,32 @@ export const GeneralSettingSchema = z
.object({
edgelessScrollZoom: z.boolean().default(false),
edgelessDisableScheduleUpdate: z.boolean().default(false),
docDropCanvasPreferView: z
.enum(['affine:embed-linked-doc', 'affine:embed-synced-doc'])
.default('affine:embed-synced-doc'),
})
.merge(NodePropsSchema);
export type EditorSetting = z.infer<typeof GeneralSettingSchema>;
export const EditorSettingProvider = createIdentifier<
Signal<DeepPartial<EditorSetting>>
>('AffineEditorSettingProvider');
export interface EditorSettingService {
setting$: Signal<DeepPartial<EditorSetting>>;
set?: (
key: keyof EditorSetting,
value: EditorSetting[keyof EditorSetting]
) => void;
}
export const EditorSettingProvider = createIdentifier<EditorSettingService>(
'AffineEditorSettingProvider'
);
export function EditorSettingExtension(
signal: Signal<DeepPartial<EditorSetting>>
service: EditorSettingService
): ExtensionType {
return {
setup: di => {
di.addImpl(EditorSettingProvider, () => signal);
di.addImpl(EditorSettingProvider, () => service);
},
};
}

View File

@@ -18,6 +18,7 @@ export interface BlockSuiteFlags {
enable_block_meta: boolean;
enable_callout: boolean;
enable_edgeless_scribbled_style: boolean;
enable_embed_doc_with_alias: boolean;
}
export class FeatureFlagService extends StoreExtension {
@@ -40,6 +41,7 @@ export class FeatureFlagService extends StoreExtension {
enable_block_meta: true,
enable_callout: false,
enable_edgeless_scribbled_style: false,
enable_embed_doc_with_alias: false,
});
setFlag(key: keyof BlockSuiteFlags, value: boolean) {

View File

@@ -1,4 +1,4 @@
import type { TelemetryEvent } from './types.js';
import type { LinkEvent } from './types.js';
export type LinkEventType =
| 'CopiedLink'
@@ -16,4 +16,4 @@ export type LinkEventType =
| 'EditLink'
| 'ReloadLink';
export type LinkToolbarEvents = Record<LinkEventType, TelemetryEvent>;
export type LinkToolbarEvents = Record<LinkEventType, LinkEvent>;

Some files were not shown because too many files have changed in this diff Show More