@worktile/theia 20.1.0 → 20.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -2438,6 +2438,9 @@ function toggleClass(nativeElement, className, isAdd) {
|
|
|
2438
2438
|
}
|
|
2439
2439
|
}
|
|
2440
2440
|
function toggleHeadingRelatedElement(editor, element, isVisible) {
|
|
2441
|
+
if (editor.options.enableVirtualScroll) {
|
|
2442
|
+
return;
|
|
2443
|
+
}
|
|
2441
2444
|
const targetDom = NODE_TO_ELEMENT.get(element);
|
|
2442
2445
|
if (!targetDom) {
|
|
2443
2446
|
return;
|
|
@@ -2495,7 +2498,7 @@ class TheBaseElement extends BaseElementComponent {
|
|
|
2495
2498
|
super.ngOnInit();
|
|
2496
2499
|
const blockClass = this.editor.isInline(this.element) ? 'slate-inline-block' : 'slate-block';
|
|
2497
2500
|
this.nativeElement.classList.add(`slate-element-${this.element.type}`, blockClass);
|
|
2498
|
-
if (this.editor) {
|
|
2501
|
+
if (this.editor && !this.editor.options.enableVirtualScroll) {
|
|
2499
2502
|
const isVisible = this.editor.isVisible(this.element);
|
|
2500
2503
|
const isBlockCard = this.editor.isBlockCard(this.element);
|
|
2501
2504
|
if (!isVisible) {
|
|
@@ -12698,7 +12701,7 @@ class TheBaseFlavourElement extends BaseElementFlavour {
|
|
|
12698
12701
|
}
|
|
12699
12702
|
onInit() {
|
|
12700
12703
|
super.onInit();
|
|
12701
|
-
if (this.editor) {
|
|
12704
|
+
if (this.editor && !this.editor.options.enableVirtualScroll) {
|
|
12702
12705
|
const isVisible = this.editor.isVisible(this.element);
|
|
12703
12706
|
const isBlockCard = this.editor.isBlockCard(this.element);
|
|
12704
12707
|
if (!isVisible) {
|
|
@@ -13835,6 +13838,9 @@ const createFontSizePlugin = (locale) => createPluginFactory({
|
|
|
13835
13838
|
})();
|
|
13836
13839
|
|
|
13837
13840
|
const cleanHeadingEffect = (editor, path) => {
|
|
13841
|
+
if (editor.options.enableVirtualScroll) {
|
|
13842
|
+
return;
|
|
13843
|
+
}
|
|
13838
13844
|
const index = path[0];
|
|
13839
13845
|
const headingElement = editor.children[index];
|
|
13840
13846
|
if (!isStandardHeadingElement(headingElement)) {
|
|
@@ -18149,6 +18155,9 @@ class HeadingFlavour extends TheBaseFlavourElement {
|
|
|
18149
18155
|
constructor() {
|
|
18150
18156
|
super(...arguments);
|
|
18151
18157
|
this.beforeContextChange = (value) => {
|
|
18158
|
+
if (this.editor.options.enableVirtualScroll) {
|
|
18159
|
+
return;
|
|
18160
|
+
}
|
|
18152
18161
|
const isHeading = isStandardHeadingElement(value.element);
|
|
18153
18162
|
if (isHeading && this.element && value.element !== this.element) {
|
|
18154
18163
|
if (value.element.isCollapsed !== this.element.isCollapsed) {
|
|
@@ -18170,7 +18179,10 @@ class HeadingFlavour extends TheBaseFlavourElement {
|
|
|
18170
18179
|
}
|
|
18171
18180
|
onInit() {
|
|
18172
18181
|
super.onInit();
|
|
18173
|
-
if (this.
|
|
18182
|
+
if (!this.editor.options.enableVirtualScroll &&
|
|
18183
|
+
this.element &&
|
|
18184
|
+
isStandardHeadingElement(this.element) &&
|
|
18185
|
+
this.element.isCollapsed) {
|
|
18174
18186
|
const followElements = getFollowElements(this.editor, this.element);
|
|
18175
18187
|
// 处理删除后撤销场景
|
|
18176
18188
|
followElements.forEach(el => {
|