@blocksuite/affine-widget-scroll-anchoring
Advanced tools
Comparing version 0.0.0-canary-20240923001408 to 0.0.0-canary-20240924001354
# @blocksuite/affine-widget-scroll-anchoring | ||
## 0.0.0-canary-20240923001408 | ||
## 0.0.0-canary-20240924001354 | ||
@@ -9,6 +9,6 @@ ### Patch Changes | ||
- Updated dependencies | ||
- @blocksuite/affine-model@0.0.0-canary-20240923001408 | ||
- @blocksuite/affine-shared@0.0.0-canary-20240923001408 | ||
- @blocksuite/block-std@0.0.0-canary-20240923001408 | ||
- @blocksuite/global@0.0.0-canary-20240923001408 | ||
- @blocksuite/affine-model@0.0.0-canary-20240924001354 | ||
- @blocksuite/affine-shared@0.0.0-canary-20240924001354 | ||
- @blocksuite/block-std@0.0.0-canary-20240924001354 | ||
- @blocksuite/global@0.0.0-canary-20240924001354 | ||
@@ -15,0 +15,0 @@ ## 0.17.14 |
@@ -122,5 +122,9 @@ import { HighlightSelection } from '@blocksuite/affine-shared/selection'; | ||
} | ||
blockComponent.scrollIntoView({ | ||
behavior: 'instant', | ||
block: 'center', | ||
// use `requestAnimationFrame` to better scroll to the target | ||
// because sometimes it is impossible to scroll to the target | ||
requestAnimationFrame(() => { | ||
blockComponent.scrollIntoView({ | ||
behavior: 'instant', | ||
block: 'center', | ||
}); | ||
}); | ||
@@ -127,0 +131,0 @@ this.#listened = false; |
{ | ||
"name": "@blocksuite/affine-widget-scroll-anchoring", | ||
"version": "0.0.0-canary-20240923001408", | ||
"version": "0.0.0-canary-20240924001354", | ||
"description": "Affine scroll anchoring widget.", | ||
@@ -22,6 +22,6 @@ "type": "module", | ||
"dependencies": { | ||
"@blocksuite/affine-model": "0.0.0-canary-20240923001408", | ||
"@blocksuite/affine-shared": "0.0.0-canary-20240923001408", | ||
"@blocksuite/block-std": "0.0.0-canary-20240923001408", | ||
"@blocksuite/global": "0.0.0-canary-20240923001408", | ||
"@blocksuite/affine-model": "0.0.0-canary-20240924001354", | ||
"@blocksuite/affine-shared": "0.0.0-canary-20240924001354", | ||
"@blocksuite/block-std": "0.0.0-canary-20240924001354", | ||
"@blocksuite/global": "0.0.0-canary-20240924001354", | ||
"@preact/signals-core": "^1.8.0", | ||
@@ -28,0 +28,0 @@ "@toeverything/theme": "^1.0.8", |
@@ -166,5 +166,9 @@ import type { DocMode } from '@blocksuite/affine-model'; | ||
blockComponent.scrollIntoView({ | ||
behavior: 'instant', | ||
block: 'center', | ||
// use `requestAnimationFrame` to better scroll to the target | ||
// because sometimes it is impossible to scroll to the target | ||
requestAnimationFrame(() => { | ||
blockComponent.scrollIntoView({ | ||
behavior: 'instant', | ||
block: 'center', | ||
}); | ||
}); | ||
@@ -171,0 +175,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
37978
459
+ Added@blocksuite/affine-model@0.0.0-canary-20240924001354(transitive)
+ Added@blocksuite/affine-shared@0.0.0-canary-20240924001354(transitive)
+ Added@blocksuite/block-std@0.0.0-canary-20240924001354(transitive)
+ Added@blocksuite/global@0.0.0-canary-20240924001354(transitive)
+ Added@blocksuite/inline@0.0.0-canary-20240924001354(transitive)
+ Added@blocksuite/store@0.0.0-canary-20240924001354(transitive)
+ Added@blocksuite/sync@0.0.0-canary-20240924001354(transitive)
+ Added@sec-ant/readable-stream@0.4.1(transitive)
+ Added@tokenizer/token@0.3.0(transitive)
+ Addedfile-type@19.6.0(transitive)
+ Addedget-stream@9.0.1(transitive)
+ Addedieee754@1.2.1(transitive)
+ Addedis-stream@4.0.1(transitive)
+ Addedpeek-readable@5.3.1(transitive)
+ Addedstrtok3@9.1.1(transitive)
+ Addedtoken-types@6.0.0(transitive)
+ Addeduint8array-extras@1.4.0(transitive)
- Removed@blocksuite/affine-model@0.0.0-canary-20240923001408(transitive)
- Removed@blocksuite/affine-shared@0.0.0-canary-20240923001408(transitive)
- Removed@blocksuite/block-std@0.0.0-canary-20240923001408(transitive)
- Removed@blocksuite/global@0.0.0-canary-20240923001408(transitive)
- Removed@blocksuite/inline@0.0.0-canary-20240923001408(transitive)
- Removed@blocksuite/store@0.0.0-canary-20240923001408(transitive)
- Removed@blocksuite/sync@0.0.0-canary-20240923001408(transitive)
Updated@blocksuite/affine-shared@0.0.0-canary-20240924001354