slate-angular 1.9.1 → 13.0.0
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.
- package/components/descendant/descendant.component.d.ts +2 -3
- package/{esm2015/components/block-card/block-card.component.js → esm2020/components/block-card/block-card.component.mjs} +5 -8
- package/{esm2015/components/children/children.component.js → esm2020/components/children/children.component.mjs} +3 -3
- package/esm2020/components/descendant/descendant.component.mjs +183 -0
- package/esm2020/components/editable/editable.component.mjs +1057 -0
- package/{esm2015/components/element/default-element.component.js → esm2020/components/element/default-element.component.mjs} +3 -3
- package/{esm2015/components/element/default-element.component.token.js → esm2020/components/element/default-element.component.token.mjs} +0 -0
- package/{esm2015/components/element/element.component.js → esm2020/components/element/element.component.mjs} +3 -3
- package/{esm2015/components/leaf/default-leaf.component.js → esm2020/components/leaf/default-leaf.component.mjs} +3 -3
- package/{esm2015/components/leaf/leaf.component.js → esm2020/components/leaf/leaf.component.mjs} +3 -3
- package/{esm2015/components/leaves/leaves.component.js → esm2020/components/leaves/leaves.component.mjs} +3 -3
- package/esm2020/components/string/string.component.mjs +73 -0
- package/esm2020/components/string/template.component.mjs +26 -0
- package/{esm2015/components/text/default-text.component.js → esm2020/components/text/default-text.component.mjs} +3 -3
- package/{esm2015/components/text/void-text.component.js → esm2020/components/text/void-text.component.mjs} +3 -3
- package/{esm2015/custom-event/BeforeInputEventPlugin.js → esm2020/custom-event/BeforeInputEventPlugin.mjs} +0 -0
- package/{esm2015/custom-event/DOMTopLevelEventTypes.js → esm2020/custom-event/DOMTopLevelEventTypes.mjs} +0 -0
- package/{esm2015/custom-event/FallbackCompositionState.js → esm2020/custom-event/FallbackCompositionState.mjs} +0 -0
- package/{esm2015/custom-event/before-input-polyfill.js → esm2020/custom-event/before-input-polyfill.mjs} +0 -0
- package/{esm2015/module.js → esm2020/module.mjs} +5 -6
- package/esm2020/plugins/angular-editor.mjs +565 -0
- package/esm2020/plugins/with-angular.mjs +214 -0
- package/{esm2015/public-api.js → esm2020/public-api.mjs} +0 -0
- package/{esm2015/slate-angular.js → esm2020/slate-angular.mjs} +0 -0
- package/{esm2015/types/error.js → esm2020/types/error.mjs} +0 -0
- package/{esm2015/types/feature.js → esm2020/types/feature.mjs} +0 -0
- package/{esm2015/types/index.js → esm2020/types/index.mjs} +1 -1
- package/{esm2015/types/view.js → esm2020/types/view.mjs} +0 -0
- package/esm2020/utils/block-card.mjs +25 -0
- package/{esm2015/utils/dom.js → esm2020/utils/dom.mjs} +0 -0
- package/esm2020/utils/environment.mjs +38 -0
- package/{esm2015/utils/global-normalize.js → esm2020/utils/global-normalize.mjs} +0 -0
- package/{esm2015/utils/hotkeys.js → esm2020/utils/hotkeys.mjs} +0 -0
- package/{esm2015/utils/index.js → esm2020/utils/index.mjs} +0 -0
- package/{esm2015/utils/key.js → esm2020/utils/key.mjs} +0 -0
- package/{esm2015/utils/lines.js → esm2020/utils/lines.mjs} +0 -0
- package/esm2020/utils/range-list.mjs +29 -0
- package/{esm2015/utils/view.js → esm2020/utils/view.mjs} +0 -0
- package/{esm2015/utils/weak-maps.js → esm2020/utils/weak-maps.mjs} +0 -0
- package/{esm2015/view/base.js → esm2020/view/base.mjs} +12 -12
- package/{esm2015/view/before-context-change.js → esm2020/view/before-context-change.mjs} +0 -0
- package/esm2020/view/container-item.mjs +102 -0
- package/{esm2015/view/container.js → esm2020/view/container.mjs} +3 -3
- package/{esm2015/view/context.js → esm2020/view/context.mjs} +0 -0
- package/fesm2015/{slate-angular.js → slate-angular.mjs} +88 -103
- package/fesm2015/slate-angular.mjs.map +1 -0
- package/fesm2020/slate-angular.mjs +3643 -0
- package/fesm2020/slate-angular.mjs.map +1 -0
- package/package.json +26 -6
- package/styles/index.scss +1 -1
- package/types/index.d.ts +1 -0
- package/view/container-item.d.ts +2 -3
- package/bundles/slate-angular.umd.js +0 -4296
- package/bundles/slate-angular.umd.js.map +0 -1
- package/esm2015/components/descendant/descendant.component.js +0 -179
- package/esm2015/components/editable/editable.component.js +0 -1063
- package/esm2015/components/string/string.component.js +0 -73
- package/esm2015/components/string/template.component.js +0 -30
- package/esm2015/plugins/angular-editor.js +0 -565
- package/esm2015/plugins/with-angular.js +0 -214
- package/esm2015/utils/block-card.js +0 -25
- package/esm2015/utils/environment.js +0 -36
- package/esm2015/utils/range-list.js +0 -30
- package/esm2015/view/container-item.js +0 -105
- package/fesm2015/slate-angular.js.map +0 -1
|
@@ -266,7 +266,9 @@ const IS_EDGE_LEGACY = typeof navigator !== 'undefined' &&
|
|
|
266
266
|
const IS_CHROME = typeof navigator !== 'undefined' && /Chrome/i.test(navigator.userAgent);
|
|
267
267
|
// Native beforeInput events don't work well with react on Chrome 75 and older, Chrome 76+ can use beforeInput
|
|
268
268
|
const IS_CHROME_LEGACY = typeof navigator !== 'undefined' &&
|
|
269
|
-
/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])/i.test(navigator.userAgent)
|
|
269
|
+
/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])/i.test(navigator.userAgent) &&
|
|
270
|
+
// Exclude Chrome version greater than 3 bits,Chrome releases v100 on 2022.03.29
|
|
271
|
+
!/Chrome?\/(?:\d{3,})/i.test(navigator.userAgent);
|
|
270
272
|
// Firefox did not support `beforeInput` until `v87`.
|
|
271
273
|
const IS_FIREFOX_LEGACY = typeof navigator !== 'undefined' &&
|
|
272
274
|
/^(?!.*Seamonkey)(?=.*Firefox\/(?:[0-7][0-9]|[0-8][0-6])).*/i.test(navigator.userAgent);
|
|
@@ -1105,20 +1107,20 @@ const withAngular = (editor, clipboardFormatKey = 'x-slate-fragment') => {
|
|
|
1105
1107
|
const commonPath = Path.common(Path.parent(op.path), Path.parent(op.newPath));
|
|
1106
1108
|
for (const [node, path] of Editor.levels(e, { at: Path.parent(op.path) })) {
|
|
1107
1109
|
const key = AngularEditor.findKey(e, node);
|
|
1108
|
-
matches.push([path, key]);
|
|
1110
|
+
matches.push([Editor.pathRef(editor, path), key]);
|
|
1109
1111
|
}
|
|
1110
1112
|
for (const [node, path] of Editor.levels(e, { at: Path.parent(op.newPath) })) {
|
|
1111
1113
|
if (path.length > commonPath.length) {
|
|
1112
1114
|
const key = AngularEditor.findKey(e, node);
|
|
1113
|
-
matches.push([path, key]);
|
|
1115
|
+
matches.push([Editor.pathRef(editor, path), key]);
|
|
1114
1116
|
}
|
|
1115
1117
|
}
|
|
1116
1118
|
break;
|
|
1117
1119
|
}
|
|
1118
1120
|
}
|
|
1119
1121
|
apply(op);
|
|
1120
|
-
for (const [
|
|
1121
|
-
const [node] = Editor.node(e,
|
|
1122
|
+
for (const [source, key] of matches) {
|
|
1123
|
+
const [node] = Editor.node(e, Path.isPath(source) ? source : source.current);
|
|
1122
1124
|
NODE_TO_KEY.set(node, key);
|
|
1123
1125
|
}
|
|
1124
1126
|
};
|
|
@@ -1634,14 +1636,11 @@ class SlateBlockCardComponent {
|
|
|
1634
1636
|
this.centerRootNodes = rootNodes;
|
|
1635
1637
|
}
|
|
1636
1638
|
}
|
|
1637
|
-
SlateBlockCardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1638
|
-
SlateBlockCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
1639
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1639
|
+
SlateBlockCardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateBlockCardComponent, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1640
|
+
SlateBlockCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateBlockCardComponent, selector: "slate-block-card, [slateBlockCard]", viewQueries: [{ propertyName: "centerContianer", first: true, predicate: ["centerContianer"], descendants: true, static: true }], ngImport: i0, template: "<span card-target=\"card-left\" class=\"card-left\">{{ '\\uFEFF' }}</span>\n<div card-target=\"card-center\" #centerContianer></div>\n<span card-target=\"card-right\" class=\"card-right\">{{ '\\uFEFF' }}</span>" });
|
|
1641
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateBlockCardComponent, decorators: [{
|
|
1640
1642
|
type: Component,
|
|
1641
|
-
args: [{
|
|
1642
|
-
selector: 'slate-block-card, [slateBlockCard]',
|
|
1643
|
-
templateUrl: 'block-card.component.html'
|
|
1644
|
-
}]
|
|
1643
|
+
args: [{ selector: 'slate-block-card, [slateBlockCard]', template: "<span card-target=\"card-left\" class=\"card-left\">{{ '\\uFEFF' }}</span>\n<div card-target=\"card-center\" #centerContianer></div>\n<span card-target=\"card-right\" class=\"card-right\">{{ '\\uFEFF' }}</span>" }]
|
|
1645
1644
|
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { centerContianer: [{
|
|
1646
1645
|
type: ViewChild,
|
|
1647
1646
|
args: ['centerContianer', { static: true }]
|
|
@@ -1653,9 +1652,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
1653
1652
|
* If the dynamically created component uses onpush mode, then it must call markForCheck when setting the context
|
|
1654
1653
|
*/
|
|
1655
1654
|
class ViewContainerItem {
|
|
1656
|
-
constructor(viewContainerRef
|
|
1655
|
+
constructor(viewContainerRef) {
|
|
1657
1656
|
this.viewContainerRef = viewContainerRef;
|
|
1658
|
-
this.componentFactoryResolver = componentFactoryResolver;
|
|
1659
1657
|
this.initialized = false;
|
|
1660
1658
|
}
|
|
1661
1659
|
get rootNodes() {
|
|
@@ -1690,8 +1688,7 @@ class ViewContainerItem {
|
|
|
1690
1688
|
this.embeddedViewRef = embeddedViewRef;
|
|
1691
1689
|
}
|
|
1692
1690
|
if (isComponentType(this.viewType)) {
|
|
1693
|
-
const
|
|
1694
|
-
const componentRef = this.viewContainerRef.createComponent(componentFactory);
|
|
1691
|
+
const componentRef = this.viewContainerRef.createComponent(this.viewType);
|
|
1695
1692
|
componentRef.instance.context = context;
|
|
1696
1693
|
componentRef.instance.viewContext = this.viewContext;
|
|
1697
1694
|
this.componentRef = componentRef;
|
|
@@ -1725,8 +1722,7 @@ class ViewContainerItem {
|
|
|
1725
1722
|
this.embeddedViewRef = embeddedViewRef;
|
|
1726
1723
|
}
|
|
1727
1724
|
if (isComponentType(this.viewType)) {
|
|
1728
|
-
const
|
|
1729
|
-
const componentRef = this.viewContainerRef.createComponent(componentFactory);
|
|
1725
|
+
const componentRef = this.viewContainerRef.createComponent(this.viewType);
|
|
1730
1726
|
componentRef.instance.context = context;
|
|
1731
1727
|
componentRef.instance.viewContext = this.viewContext;
|
|
1732
1728
|
firstRootNode.replaceWith(componentRef.instance.nativeElement);
|
|
@@ -1741,11 +1737,11 @@ class ViewContainerItem {
|
|
|
1741
1737
|
}
|
|
1742
1738
|
}
|
|
1743
1739
|
}
|
|
1744
|
-
ViewContainerItem.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1745
|
-
ViewContainerItem.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "
|
|
1746
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1740
|
+
ViewContainerItem.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: ViewContainerItem, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
1741
|
+
ViewContainerItem.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.8", type: ViewContainerItem, inputs: { viewContext: "viewContext" }, ngImport: i0 });
|
|
1742
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: ViewContainerItem, decorators: [{
|
|
1747
1743
|
type: Directive
|
|
1748
|
-
}], ctorParameters: function () { return [{ type: i0.ViewContainerRef }
|
|
1744
|
+
}], ctorParameters: function () { return [{ type: i0.ViewContainerRef }]; }, propDecorators: { viewContext: [{
|
|
1749
1745
|
type: Input
|
|
1750
1746
|
}] } });
|
|
1751
1747
|
|
|
@@ -1781,9 +1777,9 @@ class BaseComponent {
|
|
|
1781
1777
|
return this.elementRef.nativeElement;
|
|
1782
1778
|
}
|
|
1783
1779
|
}
|
|
1784
|
-
BaseComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1785
|
-
BaseComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "
|
|
1786
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1780
|
+
BaseComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
1781
|
+
BaseComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.8", type: BaseComponent, inputs: { context: "context", viewContext: "viewContext" }, ngImport: i0 });
|
|
1782
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseComponent, decorators: [{
|
|
1787
1783
|
type: Directive
|
|
1788
1784
|
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { context: [{
|
|
1789
1785
|
type: Input
|
|
@@ -1840,9 +1836,9 @@ class BaseLeafComponent extends BaseComponent {
|
|
|
1840
1836
|
}
|
|
1841
1837
|
}
|
|
1842
1838
|
}
|
|
1843
|
-
BaseLeafComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1844
|
-
BaseLeafComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "
|
|
1845
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1839
|
+
BaseLeafComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseLeafComponent, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1840
|
+
BaseLeafComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.8", type: BaseLeafComponent, host: { properties: { "attr.data-slate-leaf": "this.isSlateLeaf" } }, usesInheritance: true, ngImport: i0 });
|
|
1841
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseLeafComponent, decorators: [{
|
|
1846
1842
|
type: Directive
|
|
1847
1843
|
}], propDecorators: { isSlateLeaf: [{
|
|
1848
1844
|
type: HostBinding,
|
|
@@ -1912,9 +1908,9 @@ class BaseElementComponent extends BaseComponent {
|
|
|
1912
1908
|
};
|
|
1913
1909
|
}
|
|
1914
1910
|
}
|
|
1915
|
-
BaseElementComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1916
|
-
BaseElementComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "
|
|
1917
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1911
|
+
BaseElementComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseElementComponent, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1912
|
+
BaseElementComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.8", type: BaseElementComponent, usesInheritance: true, ngImport: i0 });
|
|
1913
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseElementComponent, decorators: [{
|
|
1918
1914
|
type: Directive
|
|
1919
1915
|
}] });
|
|
1920
1916
|
/**
|
|
@@ -1949,9 +1945,9 @@ class BaseTextComponent extends BaseComponent {
|
|
|
1949
1945
|
this.updateWeakMap();
|
|
1950
1946
|
}
|
|
1951
1947
|
}
|
|
1952
|
-
BaseTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1953
|
-
BaseTextComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "
|
|
1954
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1948
|
+
BaseTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseTextComponent, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1949
|
+
BaseTextComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.8", type: BaseTextComponent, usesInheritance: true, ngImport: i0 });
|
|
1950
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: BaseTextComponent, decorators: [{
|
|
1955
1951
|
type: Directive
|
|
1956
1952
|
}] });
|
|
1957
1953
|
|
|
@@ -2046,9 +2042,9 @@ class ViewContainer {
|
|
|
2046
2042
|
record.item.appendBlockCardElement();
|
|
2047
2043
|
}
|
|
2048
2044
|
}
|
|
2049
|
-
ViewContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2050
|
-
ViewContainer.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "
|
|
2051
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2045
|
+
ViewContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: ViewContainer, deps: [{ token: i0.ElementRef }, { token: i0.IterableDiffers }], target: i0.ɵɵFactoryTarget.Directive });
|
|
2046
|
+
ViewContainer.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.8", type: ViewContainer, inputs: { viewContext: "viewContext" }, ngImport: i0 });
|
|
2047
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: ViewContainer, decorators: [{
|
|
2052
2048
|
type: Directive
|
|
2053
2049
|
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.IterableDiffers }]; }, propDecorators: { viewContext: [{
|
|
2054
2050
|
type: Input
|
|
@@ -2056,7 +2052,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
2056
2052
|
|
|
2057
2053
|
class SlateStringComponent extends ViewContainerItem {
|
|
2058
2054
|
constructor(elementRef, viewContainerRef) {
|
|
2059
|
-
super(viewContainerRef
|
|
2055
|
+
super(viewContainerRef);
|
|
2060
2056
|
this.elementRef = elementRef;
|
|
2061
2057
|
this.viewContainerRef = viewContainerRef;
|
|
2062
2058
|
}
|
|
@@ -2109,9 +2105,9 @@ class SlateStringComponent extends ViewContainerItem {
|
|
|
2109
2105
|
return false;
|
|
2110
2106
|
}
|
|
2111
2107
|
}
|
|
2112
|
-
SlateStringComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2113
|
-
SlateStringComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2114
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2108
|
+
SlateStringComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateStringComponent, deps: [{ token: i0.ElementRef }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
2109
|
+
SlateStringComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateStringComponent, selector: "span[slateString]", inputs: { context: "context" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2110
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateStringComponent, decorators: [{
|
|
2115
2111
|
type: Component,
|
|
2116
2112
|
args: [{
|
|
2117
2113
|
selector: 'span[slateString]',
|
|
@@ -2132,9 +2128,9 @@ class SlateDefaultLeafComponent extends BaseLeafComponent {
|
|
|
2132
2128
|
this.destroyPlaceholder();
|
|
2133
2129
|
}
|
|
2134
2130
|
}
|
|
2135
|
-
SlateDefaultLeafComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2136
|
-
SlateDefaultLeafComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2137
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2131
|
+
SlateDefaultLeafComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDefaultLeafComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2132
|
+
SlateDefaultLeafComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateDefaultLeafComponent, selector: "span[slateDefaultLeaf]", host: { attributes: { "data-slate-leaf": "true" } }, usesInheritance: true, ngImport: i0, template: `<span slateString [context]="context" [viewContext]="viewContext"><span>`, isInline: true, components: [{ type: SlateStringComponent, selector: "span[slateString]", inputs: ["context"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2133
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDefaultLeafComponent, decorators: [{
|
|
2138
2134
|
type: Component,
|
|
2139
2135
|
args: [{
|
|
2140
2136
|
selector: 'span[slateDefaultLeaf]',
|
|
@@ -2166,9 +2162,9 @@ class SlateLeafComponent extends ViewContainerItem {
|
|
|
2166
2162
|
this.updateView();
|
|
2167
2163
|
}
|
|
2168
2164
|
}
|
|
2169
|
-
SlateLeafComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2170
|
-
SlateLeafComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2171
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2165
|
+
SlateLeafComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateLeafComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2166
|
+
SlateLeafComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateLeafComponent, selector: "slate-leaf", inputs: { context: "context" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2167
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateLeafComponent, decorators: [{
|
|
2172
2168
|
type: Component,
|
|
2173
2169
|
args: [{
|
|
2174
2170
|
selector: 'slate-leaf',
|
|
@@ -2216,13 +2212,13 @@ class SlateLeavesComponent extends ViewContainer {
|
|
|
2216
2212
|
return index;
|
|
2217
2213
|
}
|
|
2218
2214
|
}
|
|
2219
|
-
SlateLeavesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2220
|
-
SlateLeavesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2215
|
+
SlateLeavesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateLeavesComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2216
|
+
SlateLeavesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateLeavesComponent, selector: "slate-leaves", inputs: { context: "context" }, viewQueries: [{ propertyName: "childrenComponent", predicate: SlateLeafComponent, descendants: true, read: SlateLeafComponent }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: `<slate-leaf
|
|
2221
2217
|
[context]="context" [viewContext]="viewContext"
|
|
2222
2218
|
[viewContext]="viewContext"
|
|
2223
2219
|
*ngFor="let context of leafContexts; trackBy: trackBy"></slate-leaf>
|
|
2224
2220
|
`, isInline: true, components: [{ type: SlateLeafComponent, selector: "slate-leaf", inputs: ["context"] }], directives: [{ type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2225
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2221
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateLeavesComponent, decorators: [{
|
|
2226
2222
|
type: Component,
|
|
2227
2223
|
args: [{
|
|
2228
2224
|
selector: 'slate-leaves',
|
|
@@ -2242,9 +2238,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
2242
2238
|
|
|
2243
2239
|
class SlateDefaultTextComponent extends BaseTextComponent {
|
|
2244
2240
|
}
|
|
2245
|
-
SlateDefaultTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2246
|
-
SlateDefaultTextComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2247
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2241
|
+
SlateDefaultTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDefaultTextComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2242
|
+
SlateDefaultTextComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateDefaultTextComponent, selector: "span[slateDefaultText]", host: { attributes: { "data-slate-node": "text" } }, usesInheritance: true, ngImport: i0, template: `<slate-leaves [context]="context" [viewContext]="viewContext" [viewContext]="viewContext"></slate-leaves>`, isInline: true, components: [{ type: SlateLeavesComponent, selector: "slate-leaves", inputs: ["context"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2243
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDefaultTextComponent, decorators: [{
|
|
2248
2244
|
type: Component,
|
|
2249
2245
|
args: [{
|
|
2250
2246
|
selector: 'span[slateDefaultText]',
|
|
@@ -2268,9 +2264,9 @@ class SlateVoidTextComponent extends BaseTextComponent {
|
|
|
2268
2264
|
this.isLeafBlock = AngularEditor.isLeafBlock(this.viewContext.editor, this.context.parent);
|
|
2269
2265
|
}
|
|
2270
2266
|
}
|
|
2271
|
-
SlateVoidTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2272
|
-
SlateVoidTextComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2273
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2267
|
+
SlateVoidTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateVoidTextComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2268
|
+
SlateVoidTextComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateVoidTextComponent, selector: "span[slateVoidText]", host: { attributes: { "data-slate-spacer": "true", "data-slate-node": "text" }, properties: { "attr.contenteditable": "isLeafBlock" }, classAttribute: "slate-spacer" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: `<slate-leaves [context]="context" [viewContext]="viewContext" [viewContext]="viewContext"></slate-leaves>`, isInline: true, components: [{ type: SlateLeavesComponent, selector: "slate-leaves", inputs: ["context"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2269
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateVoidTextComponent, decorators: [{
|
|
2274
2270
|
type: Component,
|
|
2275
2271
|
args: [{
|
|
2276
2272
|
selector: 'span[slateVoidText]',
|
|
@@ -2288,10 +2284,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
2288
2284
|
const SLATE_DEFAULT_ELEMENT_COMPONENT_TOKEN = new InjectionToken('slate-default-element-token');
|
|
2289
2285
|
|
|
2290
2286
|
class SlateDescendantComponent extends ViewContainerItem {
|
|
2291
|
-
constructor(viewContainerRef,
|
|
2292
|
-
super(viewContainerRef
|
|
2287
|
+
constructor(viewContainerRef, defaultElementComponentType) {
|
|
2288
|
+
super(viewContainerRef);
|
|
2293
2289
|
this.viewContainerRef = viewContainerRef;
|
|
2294
|
-
this.componentFactoryResolver = componentFactoryResolver;
|
|
2295
2290
|
this.defaultElementComponentType = defaultElementComponentType;
|
|
2296
2291
|
}
|
|
2297
2292
|
get rootNodes() {
|
|
@@ -2334,8 +2329,7 @@ class SlateDescendantComponent extends ViewContainerItem {
|
|
|
2334
2329
|
}
|
|
2335
2330
|
createBlockCard() {
|
|
2336
2331
|
const rootNodes = this.rootNodes;
|
|
2337
|
-
|
|
2338
|
-
this.blockCardComponentRef = this.viewContainerRef.createComponent(componentFactory, null, null);
|
|
2332
|
+
this.blockCardComponentRef = this.viewContainerRef.createComponent(SlateBlockCardComponent);
|
|
2339
2333
|
this.blockCardComponentRef.instance.initializeCenter(rootNodes);
|
|
2340
2334
|
}
|
|
2341
2335
|
updateBlockCard() {
|
|
@@ -2432,19 +2426,21 @@ class SlateDescendantComponent extends ViewContainerItem {
|
|
|
2432
2426
|
}
|
|
2433
2427
|
}
|
|
2434
2428
|
}
|
|
2435
|
-
SlateDescendantComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2436
|
-
SlateDescendantComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2437
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2429
|
+
SlateDescendantComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDescendantComponent, deps: [{ token: i0.ViewContainerRef }, { token: SLATE_DEFAULT_ELEMENT_COMPONENT_TOKEN }], target: i0.ɵɵFactoryTarget.Component });
|
|
2430
|
+
SlateDescendantComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateDescendantComponent, selector: "slate-descendant", inputs: { descendant: "descendant", context: "context", viewContext: "viewContext", index: "index" }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2431
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDescendantComponent, decorators: [{
|
|
2438
2432
|
type: Component,
|
|
2439
2433
|
args: [{
|
|
2440
2434
|
selector: 'slate-descendant',
|
|
2441
2435
|
template: '',
|
|
2442
2436
|
changeDetection: ChangeDetectionStrategy.OnPush
|
|
2443
2437
|
}]
|
|
2444
|
-
}], ctorParameters: function () {
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2438
|
+
}], ctorParameters: function () {
|
|
2439
|
+
return [{ type: i0.ViewContainerRef }, { type: undefined, decorators: [{
|
|
2440
|
+
type: Inject,
|
|
2441
|
+
args: [SLATE_DEFAULT_ELEMENT_COMPONENT_TOKEN]
|
|
2442
|
+
}] }];
|
|
2443
|
+
}, propDecorators: { descendant: [{
|
|
2448
2444
|
type: Input
|
|
2449
2445
|
}], context: [{
|
|
2450
2446
|
type: Input
|
|
@@ -2464,14 +2460,14 @@ class SlateChildrenComponent extends ViewContainer {
|
|
|
2464
2460
|
ngOnInit() {
|
|
2465
2461
|
}
|
|
2466
2462
|
}
|
|
2467
|
-
SlateChildrenComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2468
|
-
SlateChildrenComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2463
|
+
SlateChildrenComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateChildrenComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
2464
|
+
SlateChildrenComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateChildrenComponent, selector: "slate-children", inputs: { children: "children", context: "context", viewContext: "viewContext" }, viewQueries: [{ propertyName: "childrenComponent", predicate: SlateDescendantComponent, descendants: true, read: SlateDescendantComponent }], usesInheritance: true, ngImport: i0, template: `<slate-descendant
|
|
2469
2465
|
[descendant]="descendant"
|
|
2470
2466
|
[context]="context" [viewContext]="viewContext"
|
|
2471
2467
|
[viewContext]="viewContext"
|
|
2472
2468
|
[index]="index"
|
|
2473
2469
|
*ngFor="let descendant of children;let index = index; trackBy: trackBy"></slate-descendant>`, isInline: true, components: [{ type: SlateDescendantComponent, selector: "slate-descendant", inputs: ["descendant", "context", "viewContext", "index"] }], directives: [{ type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2474
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2470
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateChildrenComponent, decorators: [{
|
|
2475
2471
|
type: Component,
|
|
2476
2472
|
args: [{
|
|
2477
2473
|
selector: 'slate-children',
|
|
@@ -2496,15 +2492,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
2496
2492
|
|
|
2497
2493
|
class SlateStringTemplateComponent {
|
|
2498
2494
|
}
|
|
2499
|
-
SlateStringTemplateComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2500
|
-
SlateStringTemplateComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
2501
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2495
|
+
SlateStringTemplateComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateStringTemplateComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2496
|
+
SlateStringTemplateComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateStringTemplateComponent, selector: "slate-string-template", viewQueries: [{ propertyName: "stringTemplate", first: true, predicate: ["stringTemplate"], descendants: true, read: TemplateRef, static: true }, { propertyName: "compatStringTemplate", first: true, predicate: ["compatStringTemplate"], descendants: true, read: TemplateRef, static: true }, { propertyName: "emptyStringTemplate", first: true, predicate: ["emptyStringTemplate"], descendants: true, read: TemplateRef, static: true }, { propertyName: "emptyTextTemplate", first: true, predicate: ["emptyTextTemplate"], descendants: true, read: TemplateRef, static: true }, { propertyName: "lineBreakEmptyStringTemplate", first: true, predicate: ["lineBreakEmptyStringTemplate"], descendants: true, read: TemplateRef, static: true }], ngImport: i0, template: "<ng-template #stringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-string=\"true\">{{ context.text }}</span>\n</ng-template>\n<ng-template #compatStringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <!-- Compatible with Chinese input in Chrome with \\n -->\n <span editable-text data-slate-string=\"true\">{{ context.text }}<span data-slate-zero-width>{{'\\uFEFF'}}</span></span>\n</ng-template>\n<ng-template #emptyStringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-zero-width=\"z\" attr.data-slate-length=\"{{ context.elementStringLength }}\">{{ '\\uFEFF' }}</span>\n</ng-template>\n<ng-template #emptyTextTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-zero-width=\"z\" data-slate-length=\"0\">{{ '\\uFEFF' }}</span>\n</ng-template>\n<ng-template #lineBreakEmptyStringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-zero-width=\"n\" attr.data-slate-length=\"{{ context.elementStringLength }}\">{{ '\\uFEFF'\n }}<br /></span>\n</ng-template>", changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2497
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateStringTemplateComponent, decorators: [{
|
|
2502
2498
|
type: Component,
|
|
2503
|
-
args: [{
|
|
2504
|
-
selector: 'slate-string-template',
|
|
2505
|
-
templateUrl: 'template.component.html',
|
|
2506
|
-
changeDetection: ChangeDetectionStrategy.OnPush
|
|
2507
|
-
}]
|
|
2499
|
+
args: [{ selector: 'slate-string-template', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-template #stringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-string=\"true\">{{ context.text }}</span>\n</ng-template>\n<ng-template #compatStringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <!-- Compatible with Chinese input in Chrome with \\n -->\n <span editable-text data-slate-string=\"true\">{{ context.text }}<span data-slate-zero-width>{{'\\uFEFF'}}</span></span>\n</ng-template>\n<ng-template #emptyStringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-zero-width=\"z\" attr.data-slate-length=\"{{ context.elementStringLength }}\">{{ '\\uFEFF' }}</span>\n</ng-template>\n<ng-template #emptyTextTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-zero-width=\"z\" data-slate-length=\"0\">{{ '\\uFEFF' }}</span>\n</ng-template>\n<ng-template #lineBreakEmptyStringTemplate let-context=\"context\" let-viewContext=\"viewContext\">\n <span editable-text data-slate-zero-width=\"n\" attr.data-slate-length=\"{{ context.elementStringLength }}\">{{ '\\uFEFF'\n }}<br /></span>\n</ng-template>" }]
|
|
2508
2500
|
}], propDecorators: { stringTemplate: [{
|
|
2509
2501
|
type: ViewChild,
|
|
2510
2502
|
args: ['stringTemplate', { read: TemplateRef, static: true }]
|
|
@@ -3414,32 +3406,26 @@ class SlateEditableComponent {
|
|
|
3414
3406
|
EDITOR_TO_ON_CHANGE.delete(this.editor);
|
|
3415
3407
|
}
|
|
3416
3408
|
}
|
|
3417
|
-
SlateEditableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3418
|
-
SlateEditableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
3409
|
+
SlateEditableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateEditableComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i0.NgZone }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
3410
|
+
SlateEditableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateEditableComponent, selector: "slate-editable", inputs: { editor: "editor", renderElement: "renderElement", renderLeaf: "renderLeaf", renderText: "renderText", decorate: "decorate", placeholderDecorate: "placeholderDecorate", isStrictDecorate: "isStrictDecorate", trackBy: "trackBy", readonly: "readonly", placeholder: "placeholder", beforeInput: "beforeInput", blur: "blur", click: "click", compositionEnd: "compositionEnd", compositionStart: "compositionStart", copy: "copy", cut: "cut", dragOver: "dragOver", dragStart: "dragStart", dragEnd: "dragEnd", drop: "drop", focus: "focus", keydown: "keydown", paste: "paste", spellCheck: "spellCheck", autoCorrect: "autoCorrect", autoCapitalize: "autoCapitalize" }, host: { properties: { "attr.contenteditable": "readonly ? undefined : true", "attr.role": "readonly ? undefined : 'textbox'", "attr.spellCheck": "!hasBeforeInputSupport ? false : spellCheck", "attr.autoCorrect": "!hasBeforeInputSupport ? 'false' : autoCorrect", "attr.autoCapitalize": "!hasBeforeInputSupport ? 'false' : autoCapitalize", "attr.data-slate-editor": "this.dataSlateEditor", "attr.data-slate-node": "this.dataSlateNode", "attr.data-gramm": "this.dataGramm" }, classAttribute: "slate-editable-container" }, providers: [{
|
|
3419
3411
|
provide: NG_VALUE_ACCESSOR,
|
|
3420
3412
|
useExisting: forwardRef(() => SlateEditableComponent),
|
|
3421
3413
|
multi: true
|
|
3422
3414
|
}], viewQueries: [{ propertyName: "templateComponent", first: true, predicate: ["templateComponent"], descendants: true, static: true }, { propertyName: "templateElementRef", first: true, predicate: ["templateComponent"], descendants: true, read: ElementRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<slate-children [children]=\"editor.children\" [context]=\"context\" [viewContext]=\"viewContext\"></slate-children>\n<slate-string-template #templateComponent></slate-string-template>", components: [{ type: SlateChildrenComponent, selector: "slate-children", inputs: ["children", "context", "viewContext"] }, { type: SlateStringTemplateComponent, selector: "slate-string-template" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
3423
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3415
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateEditableComponent, decorators: [{
|
|
3424
3416
|
type: Component,
|
|
3425
|
-
args: [{
|
|
3426
|
-
selector: 'slate-editable',
|
|
3427
|
-
host: {
|
|
3417
|
+
args: [{ selector: 'slate-editable', host: {
|
|
3428
3418
|
class: 'slate-editable-container',
|
|
3429
3419
|
'[attr.contenteditable]': 'readonly ? undefined : true',
|
|
3430
3420
|
'[attr.role]': `readonly ? undefined : 'textbox'`,
|
|
3431
3421
|
'[attr.spellCheck]': `!hasBeforeInputSupport ? false : spellCheck`,
|
|
3432
3422
|
'[attr.autoCorrect]': `!hasBeforeInputSupport ? 'false' : autoCorrect`,
|
|
3433
3423
|
'[attr.autoCapitalize]': `!hasBeforeInputSupport ? 'false' : autoCapitalize`
|
|
3434
|
-
},
|
|
3435
|
-
templateUrl: 'editable.component.html',
|
|
3436
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
3437
|
-
providers: [{
|
|
3424
|
+
}, changeDetection: ChangeDetectionStrategy.OnPush, providers: [{
|
|
3438
3425
|
provide: NG_VALUE_ACCESSOR,
|
|
3439
3426
|
useExisting: forwardRef(() => SlateEditableComponent),
|
|
3440
3427
|
multi: true
|
|
3441
|
-
}]
|
|
3442
|
-
}]
|
|
3428
|
+
}], template: "<slate-children [children]=\"editor.children\" [context]=\"context\" [viewContext]=\"viewContext\"></slate-children>\n<slate-string-template #templateComponent></slate-string-template>" }]
|
|
3443
3429
|
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.Renderer2 }, { type: i0.ChangeDetectorRef }, { type: i0.NgZone }, { type: i0.Injector }]; }, propDecorators: { editor: [{
|
|
3444
3430
|
type: Input
|
|
3445
3431
|
}], renderElement: [{
|
|
@@ -3567,9 +3553,9 @@ const preventInsertFromComposition = (event, editor) => {
|
|
|
3567
3553
|
|
|
3568
3554
|
class SlateElementComponent extends BaseElementComponent {
|
|
3569
3555
|
}
|
|
3570
|
-
SlateElementComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3571
|
-
SlateElementComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
3572
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3556
|
+
SlateElementComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateElementComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
3557
|
+
SlateElementComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateElementComponent, selector: "[slateElement]", usesInheritance: true, ngImport: i0, template: '<slate-children [children]="children" [context]="childrenContext" [viewContext]="viewContext"></slate-children><ng-content></ng-content>', isInline: true, components: [{ type: SlateChildrenComponent, selector: "slate-children", inputs: ["children", "context", "viewContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
3558
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateElementComponent, decorators: [{
|
|
3573
3559
|
type: Component,
|
|
3574
3560
|
args: [{
|
|
3575
3561
|
selector: '[slateElement]',
|
|
@@ -3580,9 +3566,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
3580
3566
|
|
|
3581
3567
|
class SlateDefaultElementComponent extends BaseElementComponent {
|
|
3582
3568
|
}
|
|
3583
|
-
SlateDefaultElementComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3584
|
-
SlateDefaultElementComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "
|
|
3585
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3569
|
+
SlateDefaultElementComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDefaultElementComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
3570
|
+
SlateDefaultElementComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.8", type: SlateDefaultElementComponent, selector: "div[slateDefaultElement]", usesInheritance: true, ngImport: i0, template: `<slate-children [children]="children" [context]="childrenContext" [viewContext]="viewContext"></slate-children>`, isInline: true, components: [{ type: SlateChildrenComponent, selector: "slate-children", inputs: ["children", "context", "viewContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
3571
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateDefaultElementComponent, decorators: [{
|
|
3586
3572
|
type: Component,
|
|
3587
3573
|
args: [{
|
|
3588
3574
|
selector: 'div[slateDefaultElement]',
|
|
@@ -3593,8 +3579,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
3593
3579
|
|
|
3594
3580
|
class SlateModule {
|
|
3595
3581
|
}
|
|
3596
|
-
SlateModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3597
|
-
SlateModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "
|
|
3582
|
+
SlateModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
3583
|
+
SlateModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateModule, declarations: [SlateEditableComponent,
|
|
3598
3584
|
SlateDefaultElementComponent,
|
|
3599
3585
|
SlateElementComponent,
|
|
3600
3586
|
SlateVoidTextComponent,
|
|
@@ -3607,13 +3593,13 @@ SlateModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "1
|
|
|
3607
3593
|
SlateLeafComponent,
|
|
3608
3594
|
SlateLeavesComponent,
|
|
3609
3595
|
SlateDefaultLeafComponent], imports: [CommonModule], exports: [SlateEditableComponent, SlateChildrenComponent, SlateElementComponent, SlateLeavesComponent, SlateStringComponent] });
|
|
3610
|
-
SlateModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
3596
|
+
SlateModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateModule, providers: [
|
|
3611
3597
|
{
|
|
3612
3598
|
provide: SLATE_DEFAULT_ELEMENT_COMPONENT_TOKEN,
|
|
3613
3599
|
useValue: SlateDefaultElementComponent
|
|
3614
3600
|
},
|
|
3615
3601
|
], imports: [[CommonModule]] });
|
|
3616
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3602
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.8", ngImport: i0, type: SlateModule, decorators: [{
|
|
3617
3603
|
type: NgModule,
|
|
3618
3604
|
args: [{
|
|
3619
3605
|
declarations: [
|
|
@@ -3632,7 +3618,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
3632
3618
|
SlateDefaultLeafComponent
|
|
3633
3619
|
],
|
|
3634
3620
|
imports: [CommonModule],
|
|
3635
|
-
entryComponents: [SlateBlockCardComponent, SlateStringComponent, SlateDefaultElementComponent, SlateDefaultLeafComponent, SlateVoidTextComponent, SlateDefaultTextComponent],
|
|
3636
3621
|
exports: [SlateEditableComponent, SlateChildrenComponent, SlateElementComponent, SlateLeavesComponent, SlateStringComponent],
|
|
3637
3622
|
providers: [
|
|
3638
3623
|
{
|
|
@@ -3652,4 +3637,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImpor
|
|
|
3652
3637
|
*/
|
|
3653
3638
|
|
|
3654
3639
|
export { AngularEditor, BaseComponent, BaseElementComponent, BaseLeafComponent, BaseTextComponent, DOMComment, DOMElement, DOMNode, DOMRange, DOMSelection, DOMStaticRange, DOMText, EDITOR_TO_ELEMENT, EDITOR_TO_ON_CHANGE, EDITOR_TO_PLACEHOLDER, EDITOR_TO_WINDOW, ELEMENT_TO_COMPONENT, ELEMENT_TO_NODE, FAKE_LEFT_BLOCK_CARD_OFFSET, FAKE_RIGHT_BLOCK_CARD_OFFSET, HAS_BEFORE_INPUT_SUPPORT, IS_ANDROID, IS_APPLE, IS_CHROME, IS_CHROME_LEGACY, IS_CLICKING, IS_DRAGGING, IS_EDGE_LEGACY, IS_FIREFOX, IS_FIREFOX_LEGACY, IS_FOCUSED, IS_IOS, IS_QQBROWSER, IS_READONLY, IS_SAFARI, IS_UC_MOBILE, IS_WECHATBROWSER, KEY_TO_ELEMENT, Key, NODE_TO_ELEMENT, NODE_TO_INDEX, NODE_TO_KEY, NODE_TO_PARENT, PLACEHOLDER_SYMBOL, SlateChildrenComponent, SlateEditableComponent, SlateElementComponent, SlateErrorCode, SlateLeavesComponent, SlateModule, SlateStringComponent, check, getCardTargetAttribute, getClipboardData, getDefaultView, getEditableChild, getEditableChildAndIndex, getPlainText, getSlateFragmentAttribute, hasBeforeContextChange, hasBlockCard, hasBlockCardWithNode, hasShadowRoot, hotkeys, isCardCenterByTargetAttr, isCardLeft, isCardLeftByTargetAttr, isCardRightByTargetAttr, isComponentType, isDOMComment, isDOMElement, isDOMNode, isDOMSelection, isDOMText, isDecoratorRangeListEqual, isPlainTextOnlyPaste, isTemplateRef, isValid, normalize, normalizeDOMPoint, shallowCompare, withAngular };
|
|
3655
|
-
//# sourceMappingURL=slate-angular.
|
|
3640
|
+
//# sourceMappingURL=slate-angular.mjs.map
|