8
0
Просмотр исходного кода

Docs: Special characters feature guide and snippets corrected. [skip ci]

Anna Tomanek 6 лет назад
Родитель
Сommit
c93dd1d10f

+ 51 - 6
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters-extended-category.html

@@ -1,10 +1,55 @@
 <div id="snippet-special-characters-extended-category">
 <div id="snippet-special-characters-extended-category">
-	<h2 style="text-align:center;">The Flavorful Tuscany Meetup</h2>
-	<h3 style="text-align:center;">Welcome letter</h3>
-	<p>Dear Guest,</p>
-	<p>We are delighted to welcome you to the annual <i>Flavorful Tuscany Meetup</i> and hope you will enjoy the programme as well as your stay at the <a href="https://ckeditor.com">Bilancino Hotel</a>.</p>
-	<p>Please arrive at the <a href="https://ckeditor.com">Bilancino Hotel</a> reception desk at least half an hour earlier to make sure that the registration process goes as smoothly as possible.</p>
-	<p>We look forward to welcoming you to the event. The full schedule can be found below.</p>
+	<h3>Euro foreign exchange reference rates</h3>
+	<p>As of February 10, 2020</p>
+	<p>All currencies quoted against the euro (€) as base currency.</p>
+	<table>
+		<thead>
+			<tr>
+				<th scope="col">Currency name</th>
+				<th scope="col">Symbol</th>
+				<th scope="col">Spot</th>
+				<th scope="col">Change</th>
+			</tr>
+		</thead>
+		<tbody>
+			<tr>
+				<td>US Dollar</td>
+				<td>$</td>
+				<td>1.0951</td>
+				<td>↓</td>
+			</tr>
+			<tr>
+				<td>British Pound</td>
+				<td>£</td>
+				<td>0.8463</td>
+				<td>↓</td>
+			</tr>
+			<tr>
+				<td>Indian Rupee</td>
+				<td>₹</td>
+				<td>78.1070</td>
+				<td>↓</td>
+			</tr>
+			<tr>
+				<td>Japanese Yen</td>
+				<td>¥</td>
+				<td>120.1800</td>
+				<td>↓</td>
+			</tr>
+			<tr>
+				<td>Russian Ruble</td>
+				<td>₽</td>
+				<td>70.1120</td>
+				<td>↑</td>
+			</tr>
+			<tr>
+				<td>Turkish Lira</td>
+				<td>₺</td>
+				<td>6.5897</td>
+				<td>↑</td>
+			</tr>
+		</tbody>
+	</table>
 </div>
 </div>
 
 
 <style>
 <style>

+ 0 - 2
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters-extended-category.js

@@ -32,10 +32,8 @@ ClassicEditor
 				'indent',
 				'indent',
 				'|',
 				'|',
 				'specialCharacters',
 				'specialCharacters',
-				'blockQuote',
 				'link',
 				'link',
 				'imageUpload',
 				'imageUpload',
-				'mediaEmbed',
 				'insertTable',
 				'insertTable',
 				'|',
 				'|',
 				'undo',
 				'undo',

+ 44 - 6
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters-limited-categories.html

@@ -1,10 +1,48 @@
 <div id="snippet-special-characters-limited-categories">
 <div id="snippet-special-characters-limited-categories">
-	<h2 style="text-align:center;">The Flavorful Tuscany Meetup</h2>
-	<h3 style="text-align:center;">Welcome letter</h3>
-	<p>Dear Guest,</p>
-	<p>We are delighted to welcome you to the annual <i>Flavorful Tuscany Meetup</i> and hope you will enjoy the programme as well as your stay at the <a href="https://ckeditor.com">Bilancino Hotel</a>.</p>
-	<p>Please arrive at the <a href="https://ckeditor.com">Bilancino Hotel</a> reception desk at least half an hour earlier to make sure that the registration process goes as smoothly as possible.</p>
-	<p>We look forward to welcoming you to the event. The full schedule can be found below.</p>
+	<h3>Euro foreign exchange reference rates</h3>
+	<p>As of February 10, 2020</p>
+	<p>All currencies quoted against the euro (€) as base currency.</p>
+	<table>
+		<thead>
+			<tr>
+				<th scope="col">Currency name</th>
+				<th scope="col">Symbol</th>
+				<th scope="col">Spot</th>
+			</tr>
+		</thead>
+		<tbody>
+			<tr>
+				<td>US Dollar</td>
+				<td>$</td>
+				<td>1.0951</td>
+			</tr>
+			<tr>
+				<td>British Pound</td>
+				<td>£</td>
+				<td>0.8463</td>
+			</tr>
+			<tr>
+				<td>Indian Rupee</td>
+				<td>₹</td>
+				<td>78.1070</td>
+			</tr>
+			<tr>
+				<td>Japanese Yen</td>
+				<td>¥</td>
+				<td>120.1800</td>
+			</tr>
+			<tr>
+				<td>Russian Ruble</td>
+				<td>₽</td>
+				<td>70.1120</td>
+			</tr>
+			<tr>
+				<td>Turkish Lira</td>
+				<td>₺</td>
+				<td>6.5897</td>
+			</tr>
+		</tbody>
+	</table>
 </div>
 </div>
 
 
 <style>
 <style>

+ 0 - 2
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters-limited-categories.js

@@ -23,10 +23,8 @@ ClassicEditor
 				'indent',
 				'indent',
 				'|',
 				'|',
 				'specialCharacters',
 				'specialCharacters',
-				'blockQuote',
 				'link',
 				'link',
 				'imageUpload',
 				'imageUpload',
-				'mediaEmbed',
 				'insertTable',
 				'insertTable',
 				'|',
 				'|',
 				'undo',
 				'undo',

+ 2 - 6
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters-new-category.html

@@ -1,10 +1,6 @@
 <div id="snippet-special-characters-new-category">
 <div id="snippet-special-characters-new-category">
-	<h2 style="text-align:center;">The Flavorful Tuscany Meetup</h2>
-	<h3 style="text-align:center;">Welcome letter</h3>
-	<p>Dear Guest,</p>
-	<p>We are delighted to welcome you to the annual <i>Flavorful Tuscany Meetup</i> and hope you will enjoy the programme as well as your stay at the <a href="https://ckeditor.com">Bilancino Hotel</a>.</p>
-	<p>Please arrive at the <a href="https://ckeditor.com">Bilancino Hotel</a> reception desk at least half an hour earlier to make sure that the registration process goes as smoothly as possible.</p>
-	<p>We look forward to welcoming you to the event. The full schedule can be found below.</p>
+	<p>Build your CKEditor 5 in a breeze. 🌬 Choose an editor type and customize plugins, toolbar and language in 5 simple steps. 😊</p>
+	<p>The new <a href="https://ckeditor.com/ckeditor-5/online-builder/">CKEditor 5 online builder</a> is finally here! 🚀</p>
 </div>
 </div>
 
 
 <style>
 <style>

+ 2 - 4
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters-new-category.js

@@ -11,9 +11,9 @@ function SpecialCharactersEmoji( editor ) {
 	editor.plugins.get( 'SpecialCharacters' ).addItems( 'Emoji', [
 	editor.plugins.get( 'SpecialCharacters' ).addItems( 'Emoji', [
 		{ title: 'smiley face', character: '😊' },
 		{ title: 'smiley face', character: '😊' },
 		{ title: 'rocket', character: '🚀' },
 		{ title: 'rocket', character: '🚀' },
-		{ title: 'basketball', character: '🏀' },
+		{ title: 'wind blowing face', character: '🌬️' },
 		{ title: 'floppy disk', character: '💾' },
 		{ title: 'floppy disk', character: '💾' },
-		{ title: 'hearth', character: '❤' }
+		{ title: 'heart', character: '❤' }
 	] );
 	] );
 }
 }
 
 
@@ -33,10 +33,8 @@ ClassicEditor
 				'indent',
 				'indent',
 				'|',
 				'|',
 				'specialCharacters',
 				'specialCharacters',
-				'blockQuote',
 				'link',
 				'link',
 				'imageUpload',
 				'imageUpload',
-				'mediaEmbed',
 				'insertTable',
 				'insertTable',
 				'|',
 				'|',
 				'undo',
 				'undo',

+ 44 - 6
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters.html

@@ -1,10 +1,48 @@
 <div id="snippet-special-characters">
 <div id="snippet-special-characters">
-	<h2 style="text-align:center;">The Flavorful Tuscany Meetup</h2>
-	<h3 style="text-align:center;">Welcome letter</h3>
-	<p>Dear Guest,</p>
-	<p>We are delighted to welcome you to the annual <i>Flavorful Tuscany Meetup</i> and hope you will enjoy the programme as well as your stay at the <a href="https://ckeditor.com">Bilancino Hotel</a>.</p>
-	<p>Please arrive at the <a href="https://ckeditor.com">Bilancino Hotel</a> reception desk at least half an hour earlier to make sure that the registration process goes as smoothly as possible.</p>
-	<p>We look forward to welcoming you to the event. The full schedule can be found below.</p>
+	<h3>Euro foreign exchange reference rates</h3>
+	<p>As of February 10, 2020</p>
+	<p>All currencies quoted against the euro (€) as base currency.</p>
+	<table>
+		<thead>
+			<tr>
+				<th scope="col">Currency name</th>
+				<th scope="col">Symbol</th>
+				<th scope="col">Spot</th>
+			</tr>
+		</thead>
+		<tbody>
+			<tr>
+				<td>US Dollar</td>
+				<td>$</td>
+				<td>1.0951</td>
+			</tr>
+			<tr>
+				<td>British Pound</td>
+				<td>£</td>
+				<td>0.8463</td>
+			</tr>
+			<tr>
+				<td>Indian Rupee</td>
+				<td>₹</td>
+				<td>78.1070</td>
+			</tr>
+			<tr>
+				<td>Japanese Yen</td>
+				<td>¥</td>
+				<td>120.1800</td>
+			</tr>
+			<tr>
+				<td>Russian Ruble</td>
+				<td>₽</td>
+				<td>70.1120</td>
+			</tr>
+			<tr>
+				<td>Turkish Lira</td>
+				<td>₺</td>
+				<td>6.5897</td>
+			</tr>
+		</tbody>
+	</table>
 </div>
 </div>
 
 
 <style>
 <style>

+ 0 - 2
packages/ckeditor5-special-characters/docs/_snippets/features/special-characters.js

@@ -23,10 +23,8 @@ ClassicEditor
 				'indent',
 				'indent',
 				'|',
 				'|',
 				'specialCharacters',
 				'specialCharacters',
-				'blockQuote',
 				'link',
 				'link',
 				'imageUpload',
 				'imageUpload',
-				'mediaEmbed',
 				'insertTable',
 				'insertTable',
 				'|',
 				'|',
 				'undo',
 				'undo',

+ 24 - 22
packages/ckeditor5-special-characters/docs/features/special-characters.md

@@ -9,7 +9,7 @@ The {@link module:special-characters/specialcharacters~SpecialCharacters} plugin
 
 
 ## Demo
 ## Demo
 
 
-Use the editor below to see the {@link module:special-characters/specialcharacters~SpecialCharacters} plugin in action.
+Use the editor below to see the special characters plugin in action.
 
 
 {@snippet features/special-characters-source}
 {@snippet features/special-characters-source}
 
 
@@ -17,11 +17,13 @@ Use the editor below to see the {@link module:special-characters/specialcharacte
 
 
 ## Configuration
 ## Configuration
 
 
+By default, a few categories of special characters have been defined. You can easily customize the special characters available in your WYSIWYG editor installation by adding new categories, extending the existing ones or removing them altogether.
+
 ### Adding a new category
 ### Adding a new category
 
 
 You can define a new special characters category using the {@link module:special-characters/specialcharacters~SpecialCharacters#addItems `SpecialCharacters#addItems()`} function.
 You can define a new special characters category using the {@link module:special-characters/specialcharacters~SpecialCharacters#addItems `SpecialCharacters#addItems()`} function.
 
 
-For example, the following plugin adds the "Emoji" category in the special characters dropdown.
+For example, the following plugin adds the "Emoji" category to the special characters dropdown.
 
 
 ```js
 ```js
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
@@ -31,9 +33,9 @@ function SpecialCharactersEmoji( editor ) {
 	editor.plugins.get( 'SpecialCharacters' ).addItems( 'Emoji', [
 	editor.plugins.get( 'SpecialCharacters' ).addItems( 'Emoji', [
 		{ title: 'smiley face', character: '😊' },
 		{ title: 'smiley face', character: '😊' },
 		{ title: 'rocket', character: '🚀' },
 		{ title: 'rocket', character: '🚀' },
-		{ title: 'basketball', character: '🏀' },
+		{ title: 'wind blowing face', character: '🌬️' },
 		{ title: 'floppy disk', character: '💾' },
 		{ title: 'floppy disk', character: '💾' },
-		{ title: 'hearth', character: '❤' }
+		{ title: 'heart', character: '❤' }
 	] );
 	] );
 }
 }
 
 
@@ -50,19 +52,19 @@ ClassicEditor
 	.catch( ... );
 	.catch( ... );
 ```
 ```
 
 
-After adding the above plugin into the editor, the new category will be available in the special characters dropdown.
+After adding the above plugin to the editor configuration, the new category will become available in the special characters dropdown.
 
 
 <info-box>
 <info-box>
-	A title of a special character must be unique across the entire special characters set.
+	The title of a special character must be unique across the entire special characters set.
 </info-box>
 </info-box>
 
 
-Below, you can see a demo based on the example shown above. Use the special characters icon in the editor's toolbar then select "Emoji" in the select dropdown in order to insert a emoji into the editor.
+Below you can see a demo based on the example shown above. Use the special characters icon in the editor toolbar and then select "Emoji" in the select dropdown in order to insert an emoji into the WYSIWYG editor.
 
 
 {@snippet features/special-characters-new-category}
 {@snippet features/special-characters-new-category}
 
 
 ### Adding characters to an existing category
 ### Adding characters to an existing category
 
 
-By using the {@link module:special-characters/specialcharacters~SpecialCharacters#addItems `SpecialCharacters#addItems()`} function, you can also add new special characters into existing category.
+By using the {@link module:special-characters/specialcharacters~SpecialCharacters#addItems `SpecialCharacters#addItems()`} function you can also add new special characters into an existing category.
 
 
 ```js
 ```js
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
@@ -91,27 +93,27 @@ ClassicEditor
 ```
 ```
 
 
 <info-box>
 <info-box>
-	A title of a special character must be unique across the entire special characters set.
+	The title of a special character must be unique across the entire special characters set.
 </info-box>
 </info-box>
 
 
-Below, you can see a demo based on the example shown above. Use the special characters icon in the editor's toolbar then select "Arrows" in the select dropdown. You'll see that it contains more arrows than the other instances.
+Below, you can see a demo based on the example shown above. Use the special characters icon in the editor toolbar and then select "Arrows" in the select dropdown. You will see that the category now contains the additional arrow characters added in the configuration above.
 
 
 {@snippet features/special-characters-extended-category}
 {@snippet features/special-characters-extended-category}
 
 
 ### Removing categories
 ### Removing categories
 
 
-The special characters feature exposes each category as a separate plugin. While the {@link module:special-characters/specialcharactersessentials~SpecialCharactersEssentials} plugin can be used to conveniently include all of them, you can customize the category list by adding individual plugins.
+The special characters feature exposes each category as a separate plugin. While the {@link module:special-characters/specialcharactersessentials~SpecialCharactersEssentials} plugin can be used to conveniently include all of them, you can customize the category list by adding individual plugins with particular categories.
 
 
-The `@ckeditor/ckeditor5-special-characters` package provides special characters grouped into the following categories:
+By default, the `@ckeditor/ckeditor5-special-characters` package provides special characters grouped into the following categories:
 
 
-* {@link module:special-characters/specialcharactersarrows~SpecialCharactersArrows} – arrows special characters,
-* {@link module:special-characters/specialcharacterscurrency~SpecialCharactersCurrency} - currency special characters,
-* {@link module:special-characters/specialcharacterslatin~SpecialCharactersLatin} – Latin special characters,
-* {@link module:special-characters/specialcharactersmathematical~SpecialCharactersMathematical} – mathematical special characters,
-* {@link module:special-characters/specialcharacterstext~SpecialCharactersText} – text special characters,
-* {@link module:special-characters/specialcharactersessentials~SpecialCharactersEssentials} – combining plugins listed above.
+* {@link module:special-characters/specialcharactersarrows~SpecialCharactersArrows} &ndash; Arrows special characters.
+* {@link module:special-characters/specialcharacterscurrency~SpecialCharactersCurrency} &ndash; Currency special characters.
+* {@link module:special-characters/specialcharacterslatin~SpecialCharactersLatin} &ndash; Latin special characters.
+* {@link module:special-characters/specialcharactersmathematical~SpecialCharactersMathematical} &ndash; Mathematical special characters.
+* {@link module:special-characters/specialcharacterstext~SpecialCharactersText} &ndash; Text special characters.
+* {@link module:special-characters/specialcharactersessentials~SpecialCharactersEssentials} &ndash; Combines the plugins listed above.
 
 
-For example, you can limit categories to "Mathematical" and "Currency" only by picking the {@link module:special-characters/specialcharactersmathematical~SpecialCharactersMathematical} and {@link module:special-characters/specialcharacterscurrency~SpecialCharactersCurrency} plugins, like so:
+For example, you can limit the categories to "Mathematical" and "Currency" only by picking the {@link module:special-characters/specialcharactersmathematical~SpecialCharactersMathematical} and {@link module:special-characters/specialcharacterscurrency~SpecialCharactersCurrency} plugins, like so:
 
 
 ```js
 ```js
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
@@ -131,7 +133,7 @@ ClassicEditor
 	.catch( ... );
 	.catch( ... );
 ```
 ```
 
 
-Below, you can see a demo based on the example shown above. After clicking the special character icon in the editor's toolbar you can see that it contains fewer categories compared to other editors on this page.
+Below, you can see a demo based on the example shown above. After clicking the special character icon in the editor toolbar you can see that it contains fewer categories compared to other editors on this page.
 
 
 {@snippet features/special-characters-limited-categories}
 {@snippet features/special-characters-limited-categories}
 
 
@@ -146,9 +148,9 @@ npm install --save @ckeditor/ckeditor5-special-characters
 And add it to your plugin list configuration:
 And add it to your plugin list configuration:
 
 
 ```js
 ```js
-// Core plugin that provides the API for management special characters and their categories.
+// Core plugin that provides the API for the management of special characters and their categories.
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
 import SpecialCharacters from '@ckeditor/ckeditor5-special-characters/src/specialcharacters';
-// Plugin that combines the basic set of special characters.
+// A plugin that combines a basic set of special characters.
 import SpecialCharactersEssentials from '@ckeditor/ckeditor5-special-characters/src/specialcharactersessentials';
 import SpecialCharactersEssentials from '@ckeditor/ckeditor5-special-characters/src/specialcharactersessentials';
 
 
 ClassicEditor
 ClassicEditor