@syncfusion/ej2-angular-richtexteditor 28.1.37-ngcc → 28.1.38-680214
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/CHANGELOG.md +2422 -0
- package/README.md +1 -1
- package/esm2020/public_api.mjs +2 -0
- package/esm2020/src/index.mjs +5 -0
- package/esm2020/src/rich-text-editor/richtexteditor-all.module.mjs +77 -0
- package/esm2020/src/rich-text-editor/richtexteditor.component.mjs +211 -0
- package/esm2020/src/rich-text-editor/richtexteditor.module.mjs +25 -0
- package/esm2020/syncfusion-ej2-angular-richtexteditor.mjs +5 -0
- package/fesm2015/syncfusion-ej2-angular-richtexteditor.mjs +311 -0
- package/fesm2015/syncfusion-ej2-angular-richtexteditor.mjs.map +1 -0
- package/fesm2020/syncfusion-ej2-angular-richtexteditor.mjs +311 -0
- package/fesm2020/syncfusion-ej2-angular-richtexteditor.mjs.map +1 -0
- package/package.json +28 -47
- package/schematics/collection.json +39 -10
- package/schematics/generators/richtexteditor-iframe/index.d.ts +3 -0
- package/schematics/generators/richtexteditor-iframe/index.js +8 -0
- package/schematics/generators/richtexteditor-iframe/index.ts +8 -0
- package/schematics/generators/richtexteditor-iframe/sample-details.d.ts +5 -0
- package/schematics/generators/richtexteditor-iframe/sample-details.js +8 -0
- package/schematics/generators/richtexteditor-iframe/sample-details.ts +5 -0
- package/schematics/generators/richtexteditor-iframe/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.css +3 -0
- package/schematics/generators/richtexteditor-iframe/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.html +44 -0
- package/schematics/generators/richtexteditor-iframe/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts +28 -0
- package/schematics/generators/richtexteditor-iframe/schema.d.ts +3 -0
- package/schematics/generators/richtexteditor-iframe/schema.js +2 -0
- package/schematics/generators/richtexteditor-iframe/schema.json +125 -0
- package/schematics/generators/richtexteditor-iframe/schema.ts +3 -0
- package/schematics/generators/richtexteditor-inline/index.d.ts +3 -0
- package/schematics/generators/richtexteditor-inline/index.js +8 -0
- package/schematics/generators/richtexteditor-inline/index.ts +8 -0
- package/schematics/generators/richtexteditor-inline/sample-details.d.ts +5 -0
- package/schematics/generators/richtexteditor-inline/sample-details.js +8 -0
- package/schematics/generators/richtexteditor-inline/sample-details.ts +5 -0
- package/schematics/generators/richtexteditor-inline/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.css +3 -0
- package/schematics/generators/richtexteditor-inline/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.html +10 -0
- package/schematics/generators/richtexteditor-inline/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts +30 -0
- package/schematics/generators/richtexteditor-inline/schema.d.ts +3 -0
- package/schematics/generators/richtexteditor-inline/schema.js +2 -0
- package/schematics/generators/richtexteditor-inline/schema.json +125 -0
- package/schematics/generators/richtexteditor-inline/schema.ts +3 -0
- package/schematics/generators/richtexteditor-markdown/index.d.ts +3 -0
- package/schematics/generators/richtexteditor-markdown/index.js +8 -0
- package/schematics/generators/richtexteditor-markdown/index.ts +8 -0
- package/schematics/generators/richtexteditor-markdown/sample-details.d.ts +5 -0
- package/schematics/generators/richtexteditor-markdown/sample-details.js +8 -0
- package/schematics/generators/richtexteditor-markdown/sample-details.ts +5 -0
- package/schematics/generators/richtexteditor-markdown/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.css +3 -0
- package/schematics/generators/richtexteditor-markdown/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.html +13 -0
- package/schematics/generators/richtexteditor-markdown/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts +22 -0
- package/schematics/generators/richtexteditor-markdown/schema.d.ts +3 -0
- package/schematics/generators/richtexteditor-markdown/schema.js +2 -0
- package/schematics/generators/richtexteditor-markdown/schema.json +125 -0
- package/schematics/generators/richtexteditor-markdown/schema.ts +3 -0
- package/schematics/generators/richtexteditor-overview/images/__path__/__name@dasherize__/RTEImage-Feather.png +0 -0
- package/schematics/generators/richtexteditor-overview/index.d.ts +3 -0
- package/schematics/generators/richtexteditor-overview/index.js +8 -0
- package/schematics/generators/richtexteditor-overview/index.ts +8 -0
- package/schematics/generators/richtexteditor-overview/sample-details.d.ts +5 -0
- package/schematics/generators/richtexteditor-overview/sample-details.js +8 -0
- package/schematics/generators/richtexteditor-overview/sample-details.ts +5 -0
- package/schematics/generators/richtexteditor-overview/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.css +3 -0
- package/schematics/generators/richtexteditor-overview/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.html +47 -0
- package/schematics/generators/richtexteditor-overview/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts +26 -0
- package/schematics/generators/richtexteditor-overview/schema.d.ts +3 -0
- package/schematics/generators/richtexteditor-overview/schema.js +2 -0
- package/schematics/generators/richtexteditor-overview/schema.json +125 -0
- package/schematics/generators/richtexteditor-overview/schema.ts +3 -0
- package/schematics/generators/richtexteditor-reactform/index.d.ts +3 -0
- package/schematics/generators/richtexteditor-reactform/index.js +8 -0
- package/schematics/generators/richtexteditor-reactform/index.ts +8 -0
- package/schematics/generators/richtexteditor-reactform/sample-details.d.ts +5 -0
- package/schematics/generators/richtexteditor-reactform/sample-details.js +8 -0
- package/schematics/generators/richtexteditor-reactform/sample-details.ts +5 -0
- package/schematics/generators/richtexteditor-reactform/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.css +3 -0
- package/schematics/generators/richtexteditor-reactform/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.html +20 -0
- package/schematics/generators/richtexteditor-reactform/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts +30 -0
- package/schematics/generators/richtexteditor-reactform/schema.d.ts +3 -0
- package/schematics/generators/richtexteditor-reactform/schema.js +2 -0
- package/schematics/generators/richtexteditor-reactform/schema.json +125 -0
- package/schematics/generators/richtexteditor-reactform/schema.ts +3 -0
- package/schematics/generators/richtexteditor-templatedriven/index.d.ts +3 -0
- package/schematics/generators/richtexteditor-templatedriven/index.js +8 -0
- package/schematics/generators/richtexteditor-templatedriven/index.ts +8 -0
- package/schematics/generators/richtexteditor-templatedriven/sample-details.d.ts +5 -0
- package/schematics/generators/richtexteditor-templatedriven/sample-details.js +8 -0
- package/schematics/generators/richtexteditor-templatedriven/sample-details.ts +5 -0
- package/schematics/generators/richtexteditor-templatedriven/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.css +3 -0
- package/schematics/generators/richtexteditor-templatedriven/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.html +19 -0
- package/schematics/generators/richtexteditor-templatedriven/samples/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts +25 -0
- package/schematics/generators/richtexteditor-templatedriven/schema.d.ts +3 -0
- package/schematics/generators/richtexteditor-templatedriven/schema.js +2 -0
- package/schematics/generators/richtexteditor-templatedriven/schema.json +125 -0
- package/schematics/generators/richtexteditor-templatedriven/schema.ts +3 -0
- package/schematics/ng-add/index.js +1 -1
- package/schematics/ng-add/index.ts +10 -10
- package/schematics/ng-add/schema.json +34 -34
- package/schematics/ng-add/schema.ts +30 -30
- package/schematics/tsconfig.json +25 -25
- package/schematics/utils/lib-details.d.ts +2 -2
- package/schematics/utils/lib-details.js +3 -2
- package/schematics/utils/lib-details.ts +2 -2
- package/src/rich-text-editor/richtexteditor-all.module.d.ts +6 -0
- package/src/rich-text-editor/richtexteditor.component.d.ts +3 -0
- package/src/rich-text-editor/richtexteditor.module.d.ts +6 -0
- package/styles/rich-text-editor/material3-dark.scss +1 -1
- package/styles/rich-text-editor/material3.scss +1 -1
- package/syncfusion-ej2-angular-richtexteditor.d.ts +5 -0
- package/@syncfusion/ej2-angular-richtexteditor.es5.js +0 -361
- package/@syncfusion/ej2-angular-richtexteditor.es5.js.map +0 -1
- package/@syncfusion/ej2-angular-richtexteditor.js +0 -342
- package/@syncfusion/ej2-angular-richtexteditor.js.map +0 -1
- package/dist/ej2-angular-richtexteditor.umd.js +0 -873
- package/dist/ej2-angular-richtexteditor.umd.js.map +0 -1
- package/dist/ej2-angular-richtexteditor.umd.min.js +0 -11
- package/dist/ej2-angular-richtexteditor.umd.min.js.map +0 -1
- package/ej2-angular-richtexteditor.d.ts +0 -5
- package/ej2-angular-richtexteditor.metadata.json +0 -1
- package/license +0 -10
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* RTE Iframe Sample
|
|
3
|
+
*/
|
|
4
|
+
import { Component } from '@angular/core';
|
|
5
|
+
|
|
6
|
+
@Component({
|
|
7
|
+
selector: '<%=dasherize(selector)%>',
|
|
8
|
+
templateUrl: '<%=dasherize(name)%>.component.html',
|
|
9
|
+
styleUrls: ['<%=dasherize(name)%>.component.css']
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
export class <%= classify(name) %>Component {
|
|
13
|
+
|
|
14
|
+
// Define a required toolbar items
|
|
15
|
+
public tools: object = {
|
|
16
|
+
items: ['Bold', 'Italic', 'Underline', 'StrikeThrough',
|
|
17
|
+
'FontName', 'FontSize', 'FontColor', 'BackgroundColor',
|
|
18
|
+
'LowerCase', 'UpperCase', '|',
|
|
19
|
+
'Formats', 'Alignments', 'OrderedList', 'UnorderedList',
|
|
20
|
+
'Outdent', 'Indent', '|',
|
|
21
|
+
'CreateLink', 'Image', '|', 'ClearFormat', 'Print',
|
|
22
|
+
'SourceCode', 'FullScreen', '|', 'Undo', 'Redo']
|
|
23
|
+
};
|
|
24
|
+
// Enable the iframe
|
|
25
|
+
public iframe: object = { enable: true };
|
|
26
|
+
// Set the RTE height
|
|
27
|
+
public height: number = 500;
|
|
28
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/schema",
|
|
3
|
+
"$id": "EJ2SchemaTemplateID",
|
|
4
|
+
"title": "richtexteditor-iframe",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"path": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"format": "path",
|
|
10
|
+
"description": "The path to create the component.",
|
|
11
|
+
"visible": false
|
|
12
|
+
},
|
|
13
|
+
"project": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "The name of the project.",
|
|
16
|
+
"$default": {
|
|
17
|
+
"$source": "projectName"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"name": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "The name of the component.",
|
|
23
|
+
"$default": {
|
|
24
|
+
"$source": "argv",
|
|
25
|
+
"index": 0
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"inlineStyle": {
|
|
29
|
+
"description": "Specifies if the style will be in the ts file.",
|
|
30
|
+
"type": "boolean",
|
|
31
|
+
"default": false,
|
|
32
|
+
"alias": "s"
|
|
33
|
+
},
|
|
34
|
+
"inlineTemplate": {
|
|
35
|
+
"description": "Specifies if the template will be in the ts file.",
|
|
36
|
+
"type": "boolean",
|
|
37
|
+
"default": false,
|
|
38
|
+
"alias": "t"
|
|
39
|
+
},
|
|
40
|
+
"viewEncapsulation": {
|
|
41
|
+
"description": "Specifies the view encapsulation strategy.",
|
|
42
|
+
"enum": [
|
|
43
|
+
"Emulated",
|
|
44
|
+
"Native",
|
|
45
|
+
"None",
|
|
46
|
+
"ShadowDom"
|
|
47
|
+
],
|
|
48
|
+
"type": "string",
|
|
49
|
+
"alias": "v"
|
|
50
|
+
},
|
|
51
|
+
"changeDetection": {
|
|
52
|
+
"description": "Specifies the change detection strategy.",
|
|
53
|
+
"enum": [
|
|
54
|
+
"Default",
|
|
55
|
+
"OnPush"
|
|
56
|
+
],
|
|
57
|
+
"type": "string",
|
|
58
|
+
"default": "Default",
|
|
59
|
+
"alias": "c"
|
|
60
|
+
},
|
|
61
|
+
"prefix": {
|
|
62
|
+
"type": "string",
|
|
63
|
+
"description": "The prefix to apply to generated selectors.",
|
|
64
|
+
"alias": "p",
|
|
65
|
+
"oneOf": [
|
|
66
|
+
{
|
|
67
|
+
"maxLength": 0
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"minLength": 1,
|
|
71
|
+
"format": "html-selector"
|
|
72
|
+
}
|
|
73
|
+
]
|
|
74
|
+
},
|
|
75
|
+
"styleext": {
|
|
76
|
+
"description": "The file extension to be used for style files.",
|
|
77
|
+
"type": "string",
|
|
78
|
+
"default": "css"
|
|
79
|
+
},
|
|
80
|
+
"spec": {
|
|
81
|
+
"type": "boolean",
|
|
82
|
+
"description": "Specifies if a spec file is generated.",
|
|
83
|
+
"default": true
|
|
84
|
+
},
|
|
85
|
+
"flat": {
|
|
86
|
+
"type": "boolean",
|
|
87
|
+
"description": "Flag to indicate if a dir is created.",
|
|
88
|
+
"default": false
|
|
89
|
+
},
|
|
90
|
+
"skipImport": {
|
|
91
|
+
"type": "boolean",
|
|
92
|
+
"description": "Flag to skip the module import.",
|
|
93
|
+
"default": false
|
|
94
|
+
},
|
|
95
|
+
"selector": {
|
|
96
|
+
"type": "string",
|
|
97
|
+
"format": "html-selector",
|
|
98
|
+
"description": "The selector to use for the component."
|
|
99
|
+
},
|
|
100
|
+
"module": {
|
|
101
|
+
"type": "string",
|
|
102
|
+
"description": "Allows specification of the declaring module.",
|
|
103
|
+
"alias": "m"
|
|
104
|
+
},
|
|
105
|
+
"export": {
|
|
106
|
+
"type": "boolean",
|
|
107
|
+
"default": false,
|
|
108
|
+
"description": "Specifies if declaring module exports the component."
|
|
109
|
+
},
|
|
110
|
+
"entryComponent": {
|
|
111
|
+
"type": "boolean",
|
|
112
|
+
"default": false,
|
|
113
|
+
"description": "Specifies if the component is an entry component of declaring module."
|
|
114
|
+
},
|
|
115
|
+
"lintFix": {
|
|
116
|
+
"type": "boolean",
|
|
117
|
+
"default": false,
|
|
118
|
+
"description": "Specifies whether to apply lint fixes after generating the component."
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
"required": [
|
|
122
|
+
"name"
|
|
123
|
+
],
|
|
124
|
+
"id": "richtexteditor-iframe"
|
|
125
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const schematics_1 = require("@syncfusion/ej2-angular-base/schematics");
|
|
4
|
+
const sampleDetails = require("./sample-details");
|
|
5
|
+
function default_1(options) {
|
|
6
|
+
return (0, schematics_1.componentBuilder)(options, sampleDetails);
|
|
7
|
+
}
|
|
8
|
+
exports.default = default_1;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
+
import { componentBuilder } from "@syncfusion/ej2-angular-base/schematics";
|
|
3
|
+
import { Schema } from './schema';
|
|
4
|
+
import * as sampleDetails from './sample-details';
|
|
5
|
+
|
|
6
|
+
export default function (options: Schema): Rule {
|
|
7
|
+
return componentBuilder(options, sampleDetails);
|
|
8
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.libModules = exports.packageName = exports.diModules = exports.sampleName = exports.componentName = void 0;
|
|
4
|
+
exports.componentName = 'richtexteditor';
|
|
5
|
+
exports.sampleName = 'inline';
|
|
6
|
+
exports.diModules = 'ToolbarService,LinkService,ImageService,HtmlEditorService,QuickToolbarService';
|
|
7
|
+
exports.packageName = '@syncfusion/ej2-angular-richtexteditor';
|
|
8
|
+
exports.libModules = 'RichTextEditorModule';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export const componentName: string = 'richtexteditor';
|
|
2
|
+
export const sampleName: string = 'inline';
|
|
3
|
+
export const diModules: string = 'ToolbarService,LinkService,ImageService,HtmlEditorService,QuickToolbarService';
|
|
4
|
+
export const packageName: string = '@syncfusion/ej2-angular-richtexteditor';
|
|
5
|
+
export const libModules: string = 'RichTextEditorModule';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
<div class="control-section">
|
|
2
|
+
<div id='inline-rte'>
|
|
3
|
+
<h4>Inline RTE</h4>
|
|
4
|
+
<ejs-richtexteditor id='inlineRTE' #inlineRTE [inlineMode]='inlineMode' [toolbarSettings]='toolbarSettings' [format]='format' [fontFamily]='fontFamily'>
|
|
5
|
+
<ng-template #valueTemplate>
|
|
6
|
+
<p>The sample is configured with inline mode of editor. Initially, the editor is rendered without a <a href="https://ej2.syncfusion.com/home/" target="_blank">toolbar</a>. The toolbar becomes visible only when the content is selected.</p>
|
|
7
|
+
</ng-template>
|
|
8
|
+
</ejs-richtexteditor>
|
|
9
|
+
</div>
|
|
10
|
+
</div>
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* RTE Inline Sample
|
|
3
|
+
*/
|
|
4
|
+
import { Component } from '@angular/core';
|
|
5
|
+
|
|
6
|
+
@Component({
|
|
7
|
+
selector: '<%=dasherize(selector)%>',
|
|
8
|
+
templateUrl: '<%=dasherize(name)%>.component.html',
|
|
9
|
+
styleUrls: ['<%=dasherize(name)%>.component.css']
|
|
10
|
+
})
|
|
11
|
+
|
|
12
|
+
export class <%= classify(name) %>Component {
|
|
13
|
+
|
|
14
|
+
// Define a toolbar items
|
|
15
|
+
public toolbarSettings: Object = {
|
|
16
|
+
items: ['Bold', 'Italic', 'Underline',
|
|
17
|
+
'Formats', '-', 'Alignments', 'OrderedList', 'UnorderedList',
|
|
18
|
+
'CreateLink']
|
|
19
|
+
};
|
|
20
|
+
// Set the format dropdown width
|
|
21
|
+
public format: Object = {
|
|
22
|
+
width: 'auto'
|
|
23
|
+
};
|
|
24
|
+
// Set the font family dropdown width
|
|
25
|
+
public fontFamily: Object = {
|
|
26
|
+
width: 'auto'
|
|
27
|
+
};
|
|
28
|
+
// Enable inline mode
|
|
29
|
+
public inlineMode: object = { enable: true, onSelection: true };
|
|
30
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/schema",
|
|
3
|
+
"$id": "EJ2SchemaTemplateID",
|
|
4
|
+
"title": "richtexteditor-inline",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"path": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"format": "path",
|
|
10
|
+
"description": "The path to create the component.",
|
|
11
|
+
"visible": false
|
|
12
|
+
},
|
|
13
|
+
"project": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "The name of the project.",
|
|
16
|
+
"$default": {
|
|
17
|
+
"$source": "projectName"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"name": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "The name of the component.",
|
|
23
|
+
"$default": {
|
|
24
|
+
"$source": "argv",
|
|
25
|
+
"index": 0
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"inlineStyle": {
|
|
29
|
+
"description": "Specifies if the style will be in the ts file.",
|
|
30
|
+
"type": "boolean",
|
|
31
|
+
"default": false,
|
|
32
|
+
"alias": "s"
|
|
33
|
+
},
|
|
34
|
+
"inlineTemplate": {
|
|
35
|
+
"description": "Specifies if the template will be in the ts file.",
|
|
36
|
+
"type": "boolean",
|
|
37
|
+
"default": false,
|
|
38
|
+
"alias": "t"
|
|
39
|
+
},
|
|
40
|
+
"viewEncapsulation": {
|
|
41
|
+
"description": "Specifies the view encapsulation strategy.",
|
|
42
|
+
"enum": [
|
|
43
|
+
"Emulated",
|
|
44
|
+
"Native",
|
|
45
|
+
"None",
|
|
46
|
+
"ShadowDom"
|
|
47
|
+
],
|
|
48
|
+
"type": "string",
|
|
49
|
+
"alias": "v"
|
|
50
|
+
},
|
|
51
|
+
"changeDetection": {
|
|
52
|
+
"description": "Specifies the change detection strategy.",
|
|
53
|
+
"enum": [
|
|
54
|
+
"Default",
|
|
55
|
+
"OnPush"
|
|
56
|
+
],
|
|
57
|
+
"type": "string",
|
|
58
|
+
"default": "Default",
|
|
59
|
+
"alias": "c"
|
|
60
|
+
},
|
|
61
|
+
"prefix": {
|
|
62
|
+
"type": "string",
|
|
63
|
+
"description": "The prefix to apply to generated selectors.",
|
|
64
|
+
"alias": "p",
|
|
65
|
+
"oneOf": [
|
|
66
|
+
{
|
|
67
|
+
"maxLength": 0
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"minLength": 1,
|
|
71
|
+
"format": "html-selector"
|
|
72
|
+
}
|
|
73
|
+
]
|
|
74
|
+
},
|
|
75
|
+
"styleext": {
|
|
76
|
+
"description": "The file extension to be used for style files.",
|
|
77
|
+
"type": "string",
|
|
78
|
+
"default": "css"
|
|
79
|
+
},
|
|
80
|
+
"spec": {
|
|
81
|
+
"type": "boolean",
|
|
82
|
+
"description": "Specifies if a spec file is generated.",
|
|
83
|
+
"default": true
|
|
84
|
+
},
|
|
85
|
+
"flat": {
|
|
86
|
+
"type": "boolean",
|
|
87
|
+
"description": "Flag to indicate if a dir is created.",
|
|
88
|
+
"default": false
|
|
89
|
+
},
|
|
90
|
+
"skipImport": {
|
|
91
|
+
"type": "boolean",
|
|
92
|
+
"description": "Flag to skip the module import.",
|
|
93
|
+
"default": false
|
|
94
|
+
},
|
|
95
|
+
"selector": {
|
|
96
|
+
"type": "string",
|
|
97
|
+
"format": "html-selector",
|
|
98
|
+
"description": "The selector to use for the component."
|
|
99
|
+
},
|
|
100
|
+
"module": {
|
|
101
|
+
"type": "string",
|
|
102
|
+
"description": "Allows specification of the declaring module.",
|
|
103
|
+
"alias": "m"
|
|
104
|
+
},
|
|
105
|
+
"export": {
|
|
106
|
+
"type": "boolean",
|
|
107
|
+
"default": false,
|
|
108
|
+
"description": "Specifies if declaring module exports the component."
|
|
109
|
+
},
|
|
110
|
+
"entryComponent": {
|
|
111
|
+
"type": "boolean",
|
|
112
|
+
"default": false,
|
|
113
|
+
"description": "Specifies if the component is an entry component of declaring module."
|
|
114
|
+
},
|
|
115
|
+
"lintFix": {
|
|
116
|
+
"type": "boolean",
|
|
117
|
+
"default": false,
|
|
118
|
+
"description": "Specifies whether to apply lint fixes after generating the component."
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
"required": [
|
|
122
|
+
"name"
|
|
123
|
+
],
|
|
124
|
+
"id": "richtexteditor-inline"
|
|
125
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const schematics_1 = require("@syncfusion/ej2-angular-base/schematics");
|
|
4
|
+
const sampleDetails = require("./sample-details");
|
|
5
|
+
function default_1(options) {
|
|
6
|
+
return (0, schematics_1.componentBuilder)(options, sampleDetails);
|
|
7
|
+
}
|
|
8
|
+
exports.default = default_1;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
+
import { componentBuilder } from "@syncfusion/ej2-angular-base/schematics";
|
|
3
|
+
import { Schema } from './schema';
|
|
4
|
+
import * as sampleDetails from './sample-details';
|
|
5
|
+
|
|
6
|
+
export default function (options: Schema): Rule {
|
|
7
|
+
return componentBuilder(options, sampleDetails);
|
|
8
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.libModules = exports.packageName = exports.diModules = exports.sampleName = exports.componentName = void 0;
|
|
4
|
+
exports.componentName = 'richtexteditor';
|
|
5
|
+
exports.sampleName = 'markdown';
|
|
6
|
+
exports.diModules = 'ToolbarService,LinkService,ImageService,MarkdownEditorService';
|
|
7
|
+
exports.packageName = '@syncfusion/ej2-angular-richtexteditor';
|
|
8
|
+
exports.libModules = 'RichTextEditorModule';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export const componentName: string = 'richtexteditor';
|
|
2
|
+
export const sampleName: string = 'markdown';
|
|
3
|
+
export const diModules: string = 'ToolbarService,LinkService,ImageService,MarkdownEditorService';
|
|
4
|
+
export const packageName: string = '@syncfusion/ej2-angular-richtexteditor';
|
|
5
|
+
export const libModules: string = 'RichTextEditorModule';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<div class="control-section">
|
|
2
|
+
<div id='inline-rte'>
|
|
3
|
+
<h4>Markdown RTE</h4>
|
|
4
|
+
<ejs-richtexteditor id='mdDefault' #mdDefault height='250px' [toolbarSettings]='tools' [editorMode]='mode'>
|
|
5
|
+
<ng-template #valueTemplate>
|
|
6
|
+
The sample is added to showcase **markdown editing**.
|
|
7
|
+
Type or edit the content and apply formatting to view markdown formatted content.
|
|
8
|
+
We can add our own custom formation syntax for the Markdown formation, [sample link](https://ej2.syncfusion.com/home/).
|
|
9
|
+
The third-party library <b>Marked</b> is used in this sample to convert markdown into HTML content.
|
|
10
|
+
</ng-template>
|
|
11
|
+
</ejs-richtexteditor>
|
|
12
|
+
</div>
|
|
13
|
+
</div>
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* RTE Markdown Sample
|
|
3
|
+
*/
|
|
4
|
+
import { Component } from '@angular/core';
|
|
5
|
+
@Component({
|
|
6
|
+
selector: '<%=dasherize(selector)%>',
|
|
7
|
+
templateUrl: '<%=dasherize(name)%>.component.html',
|
|
8
|
+
styleUrls: ['<%=dasherize(name)%>.component.css']
|
|
9
|
+
})
|
|
10
|
+
|
|
11
|
+
export class <%= classify(name) %>Component {
|
|
12
|
+
|
|
13
|
+
// Define a toolbar items
|
|
14
|
+
public tools: object = {
|
|
15
|
+
items: ['Bold', 'Italic', 'StrikeThrough', '|',
|
|
16
|
+
'Formats', 'OrderedList', 'UnorderedList', '|',
|
|
17
|
+
'CreateLink', 'Image', '|',
|
|
18
|
+
'Undo', 'Redo']
|
|
19
|
+
};
|
|
20
|
+
// set markdown mode
|
|
21
|
+
public mode: string = 'Markdown';
|
|
22
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/schema",
|
|
3
|
+
"$id": "EJ2SchemaTemplateID",
|
|
4
|
+
"title": "richtexteditor-markdown",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"properties": {
|
|
7
|
+
"path": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"format": "path",
|
|
10
|
+
"description": "The path to create the component.",
|
|
11
|
+
"visible": false
|
|
12
|
+
},
|
|
13
|
+
"project": {
|
|
14
|
+
"type": "string",
|
|
15
|
+
"description": "The name of the project.",
|
|
16
|
+
"$default": {
|
|
17
|
+
"$source": "projectName"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"name": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "The name of the component.",
|
|
23
|
+
"$default": {
|
|
24
|
+
"$source": "argv",
|
|
25
|
+
"index": 0
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"inlineStyle": {
|
|
29
|
+
"description": "Specifies if the style will be in the ts file.",
|
|
30
|
+
"type": "boolean",
|
|
31
|
+
"default": false,
|
|
32
|
+
"alias": "s"
|
|
33
|
+
},
|
|
34
|
+
"inlineTemplate": {
|
|
35
|
+
"description": "Specifies if the template will be in the ts file.",
|
|
36
|
+
"type": "boolean",
|
|
37
|
+
"default": false,
|
|
38
|
+
"alias": "t"
|
|
39
|
+
},
|
|
40
|
+
"viewEncapsulation": {
|
|
41
|
+
"description": "Specifies the view encapsulation strategy.",
|
|
42
|
+
"enum": [
|
|
43
|
+
"Emulated",
|
|
44
|
+
"Native",
|
|
45
|
+
"None",
|
|
46
|
+
"ShadowDom"
|
|
47
|
+
],
|
|
48
|
+
"type": "string",
|
|
49
|
+
"alias": "v"
|
|
50
|
+
},
|
|
51
|
+
"changeDetection": {
|
|
52
|
+
"description": "Specifies the change detection strategy.",
|
|
53
|
+
"enum": [
|
|
54
|
+
"Default",
|
|
55
|
+
"OnPush"
|
|
56
|
+
],
|
|
57
|
+
"type": "string",
|
|
58
|
+
"default": "Default",
|
|
59
|
+
"alias": "c"
|
|
60
|
+
},
|
|
61
|
+
"prefix": {
|
|
62
|
+
"type": "string",
|
|
63
|
+
"description": "The prefix to apply to generated selectors.",
|
|
64
|
+
"alias": "p",
|
|
65
|
+
"oneOf": [
|
|
66
|
+
{
|
|
67
|
+
"maxLength": 0
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"minLength": 1,
|
|
71
|
+
"format": "html-selector"
|
|
72
|
+
}
|
|
73
|
+
]
|
|
74
|
+
},
|
|
75
|
+
"styleext": {
|
|
76
|
+
"description": "The file extension to be used for style files.",
|
|
77
|
+
"type": "string",
|
|
78
|
+
"default": "css"
|
|
79
|
+
},
|
|
80
|
+
"spec": {
|
|
81
|
+
"type": "boolean",
|
|
82
|
+
"description": "Specifies if a spec file is generated.",
|
|
83
|
+
"default": true
|
|
84
|
+
},
|
|
85
|
+
"flat": {
|
|
86
|
+
"type": "boolean",
|
|
87
|
+
"description": "Flag to indicate if a dir is created.",
|
|
88
|
+
"default": false
|
|
89
|
+
},
|
|
90
|
+
"skipImport": {
|
|
91
|
+
"type": "boolean",
|
|
92
|
+
"description": "Flag to skip the module import.",
|
|
93
|
+
"default": false
|
|
94
|
+
},
|
|
95
|
+
"selector": {
|
|
96
|
+
"type": "string",
|
|
97
|
+
"format": "html-selector",
|
|
98
|
+
"description": "The selector to use for the component."
|
|
99
|
+
},
|
|
100
|
+
"module": {
|
|
101
|
+
"type": "string",
|
|
102
|
+
"description": "Allows specification of the declaring module.",
|
|
103
|
+
"alias": "m"
|
|
104
|
+
},
|
|
105
|
+
"export": {
|
|
106
|
+
"type": "boolean",
|
|
107
|
+
"default": false,
|
|
108
|
+
"description": "Specifies if declaring module exports the component."
|
|
109
|
+
},
|
|
110
|
+
"entryComponent": {
|
|
111
|
+
"type": "boolean",
|
|
112
|
+
"default": false,
|
|
113
|
+
"description": "Specifies if the component is an entry component of declaring module."
|
|
114
|
+
},
|
|
115
|
+
"lintFix": {
|
|
116
|
+
"type": "boolean",
|
|
117
|
+
"default": false,
|
|
118
|
+
"description": "Specifies whether to apply lint fixes after generating the component."
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
"required": [
|
|
122
|
+
"name"
|
|
123
|
+
],
|
|
124
|
+
"id": "richtexteditor-markdown"
|
|
125
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const schematics_1 = require("@syncfusion/ej2-angular-base/schematics");
|
|
4
|
+
const sampleDetails = require("./sample-details");
|
|
5
|
+
function default_1(options) {
|
|
6
|
+
return (0, schematics_1.componentBuilder)(options, sampleDetails);
|
|
7
|
+
}
|
|
8
|
+
exports.default = default_1;
|