8
0
فهرست منبع

Merge tag 'v1.0.0-beta.1' into stable

Release: v1.0.0-beta.1.
Piotrek Koszuliński 7 سال پیش
والد
کامیت
e4a21985e6
95فایلهای تغییر یافته به همراه1748 افزوده شده و 956 حذف شده
  1. 1 1
      packages/ckeditor5-basic-styles/.eslintrc.js
  2. 15 11
      packages/ckeditor5-basic-styles/.travis.yml
  3. 16 0
      packages/ckeditor5-basic-styles/CHANGELOG.md
  4. 1 1
      packages/ckeditor5-basic-styles/LICENSE.md
  5. 3 1
      packages/ckeditor5-basic-styles/README.md
  6. 2 1
      packages/ckeditor5-basic-styles/docs/api/basic-styles.md
  7. 2 1
      packages/ckeditor5-basic-styles/lang/contexts.json
  8. 5 1
      packages/ckeditor5-basic-styles/lang/translations/ast.po
  9. 5 1
      packages/ckeditor5-basic-styles/lang/translations/bg.po
  10. 6 2
      packages/ckeditor5-basic-styles/lang/translations/da.po
  11. 6 2
      packages/ckeditor5-basic-styles/lang/translations/de.po
  12. 5 1
      packages/ckeditor5-basic-styles/lang/translations/el.po
  13. 5 1
      packages/ckeditor5-basic-styles/lang/translations/en-au.po
  14. 5 1
      packages/ckeditor5-basic-styles/lang/translations/en.po
  15. 5 1
      packages/ckeditor5-basic-styles/lang/translations/eo.po
  16. 6 2
      packages/ckeditor5-basic-styles/lang/translations/es.po
  17. 26 0
      packages/ckeditor5-basic-styles/lang/translations/et.po
  18. 26 0
      packages/ckeditor5-basic-styles/lang/translations/eu.po
  19. 5 1
      packages/ckeditor5-basic-styles/lang/translations/fi.po
  20. 5 1
      packages/ckeditor5-basic-styles/lang/translations/fr.po
  21. 6 2
      packages/ckeditor5-basic-styles/lang/translations/gl.po
  22. 5 1
      packages/ckeditor5-basic-styles/lang/translations/gu.po
  23. 7 3
      packages/ckeditor5-basic-styles/lang/translations/hr.po
  24. 5 1
      packages/ckeditor5-basic-styles/lang/translations/hu.po
  25. 5 1
      packages/ckeditor5-basic-styles/lang/translations/it.po
  26. 5 1
      packages/ckeditor5-basic-styles/lang/translations/ja.po
  27. 5 1
      packages/ckeditor5-basic-styles/lang/translations/km.po
  28. 5 1
      packages/ckeditor5-basic-styles/lang/translations/kn.po
  29. 5 1
      packages/ckeditor5-basic-styles/lang/translations/ko.po
  30. 5 1
      packages/ckeditor5-basic-styles/lang/translations/ku.po
  31. 5 1
      packages/ckeditor5-basic-styles/lang/translations/nb.po
  32. 7 3
      packages/ckeditor5-basic-styles/lang/translations/nl.po
  33. 5 1
      packages/ckeditor5-basic-styles/lang/translations/oc.po
  34. 5 1
      packages/ckeditor5-basic-styles/lang/translations/pl.po
  35. 5 1
      packages/ckeditor5-basic-styles/lang/translations/pt-br.po
  36. 5 1
      packages/ckeditor5-basic-styles/lang/translations/pt.po
  37. 5 1
      packages/ckeditor5-basic-styles/lang/translations/ro.po
  38. 26 0
      packages/ckeditor5-basic-styles/lang/translations/ru.po
  39. 26 0
      packages/ckeditor5-basic-styles/lang/translations/si.po
  40. 6 2
      packages/ckeditor5-basic-styles/lang/translations/sk.po
  41. 26 0
      packages/ckeditor5-basic-styles/lang/translations/sq.po
  42. 6 2
      packages/ckeditor5-basic-styles/lang/translations/sv.po
  43. 7 3
      packages/ckeditor5-basic-styles/lang/translations/tr.po
  44. 26 0
      packages/ckeditor5-basic-styles/lang/translations/tt.po
  45. 26 0
      packages/ckeditor5-basic-styles/lang/translations/ug.po
  46. 5 1
      packages/ckeditor5-basic-styles/lang/translations/uk.po
  47. 5 1
      packages/ckeditor5-basic-styles/lang/translations/zh-cn.po
  48. 5 1
      packages/ckeditor5-basic-styles/lang/translations/zh.po
  49. 12 12
      packages/ckeditor5-basic-styles/package.json
  50. 13 13
      packages/ckeditor5-basic-styles/src/attributecommand.js
  51. 7 39
      packages/ckeditor5-basic-styles/src/bold.js
  52. 53 0
      packages/ckeditor5-basic-styles/src/bold/boldediting.js
  53. 50 0
      packages/ckeditor5-basic-styles/src/bold/boldui.js
  54. 0 54
      packages/ckeditor5-basic-styles/src/boldengine.js
  55. 8 35
      packages/ckeditor5-basic-styles/src/code.js
  56. 46 0
      packages/ckeditor5-basic-styles/src/code/codeediting.js
  57. 51 0
      packages/ckeditor5-basic-styles/src/code/codeui.js
  58. 0 53
      packages/ckeditor5-basic-styles/src/codeengine.js
  59. 7 39
      packages/ckeditor5-basic-styles/src/italic.js
  60. 52 0
      packages/ckeditor5-basic-styles/src/italic/italicediting.js
  61. 50 0
      packages/ckeditor5-basic-styles/src/italic/italicui.js
  62. 0 54
      packages/ckeditor5-basic-styles/src/italicengine.js
  63. 36 0
      packages/ckeditor5-basic-styles/src/strikethrough.js
  64. 54 0
      packages/ckeditor5-basic-styles/src/strikethrough/strikethroughediting.js
  65. 50 0
      packages/ckeditor5-basic-styles/src/strikethrough/strikethroughui.js
  66. 7 39
      packages/ckeditor5-basic-styles/src/underline.js
  67. 49 0
      packages/ckeditor5-basic-styles/src/underline/underlineediting.js
  68. 50 0
      packages/ckeditor5-basic-styles/src/underline/underlineui.js
  69. 0 53
      packages/ckeditor5-basic-styles/src/underlineengine.js
  70. 82 76
      packages/ckeditor5-basic-styles/tests/attributecommand.js
  71. 7 86
      packages/ckeditor5-basic-styles/tests/bold.js
  72. 34 21
      packages/ckeditor5-basic-styles/tests/bold/boldediting.js
  73. 73 0
      packages/ckeditor5-basic-styles/tests/bold/boldui.js
  74. 7 64
      packages/ckeditor5-basic-styles/tests/code.js
  75. 16 20
      packages/ckeditor5-basic-styles/tests/code/codeediting.js
  76. 68 0
      packages/ckeditor5-basic-styles/tests/code/codeui.js
  77. 7 84
      packages/ckeditor5-basic-styles/tests/italic.js
  78. 18 22
      packages/ckeditor5-basic-styles/tests/italic/italicediting.js
  79. 88 0
      packages/ckeditor5-basic-styles/tests/italic/italicui.js
  80. 1 1
      packages/ckeditor5-basic-styles/tests/manual/basic-styles.html
  81. 4 3
      packages/ckeditor5-basic-styles/tests/manual/basic-styles.js
  82. 5 4
      packages/ckeditor5-basic-styles/tests/manual/basic-styles.md
  83. 18 0
      packages/ckeditor5-basic-styles/tests/strikethrough.js
  84. 104 0
      packages/ckeditor5-basic-styles/tests/strikethrough/strikethroughediting.js
  85. 91 0
      packages/ckeditor5-basic-styles/tests/strikethrough/strikethroughui.js
  86. 7 84
      packages/ckeditor5-basic-styles/tests/underline.js
  87. 16 20
      packages/ckeditor5-basic-styles/tests/underline/underlineediting.js
  88. 88 0
      packages/ckeditor5-basic-styles/tests/underline/underlineui.js
  89. 10 0
      packages/ckeditor5-basic-styles/theme/code.css
  90. 0 14
      packages/ckeditor5-basic-styles/theme/code.scss
  91. 1 1
      packages/ckeditor5-basic-styles/theme/icons/bold.svg
  92. 1 1
      packages/ckeditor5-basic-styles/theme/icons/code.svg
  93. 1 1
      packages/ckeditor5-basic-styles/theme/icons/italic.svg
  94. 1 0
      packages/ckeditor5-basic-styles/theme/icons/strikethrough.svg
  95. 1 1
      packages/ckeditor5-basic-styles/theme/icons/underline.svg

+ 1 - 1
packages/ckeditor5-basic-styles/.eslintrc.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 

+ 15 - 11
packages/ckeditor5-basic-styles/.travis.yml

@@ -1,24 +1,28 @@
 sudo: required
 sudo: required
 dist: trusty
 dist: trusty
 addons:
 addons:
+  firefox: "latest"
   apt:
   apt:
     sources:
     sources:
-      - google-chrome
+    - google-chrome
     packages:
     packages:
-      - google-chrome-stable
+    - google-chrome-stable
 language: node_js
 language: node_js
 node_js:
 node_js:
-  - "6"
+- '6'
 cache:
 cache:
-  - node_modules
+- node_modules
 before_install:
 before_install:
-  - export DISPLAY=:99.0
-  - sh -e /etc/init.d/xvfb start
+- export DISPLAY=:99.0
+- sh -e /etc/init.d/xvfb start
 install:
 install:
-  - npm install @ckeditor/ckeditor5-dev-tests
-  - ckeditor5-dev-tests-install-dependencies
+- npm install @ckeditor/ckeditor5-dev-tests
+- ckeditor5-dev-tests-install-dependencies
 script:
 script:
-  - ckeditor5-dev-tests-travis
+- ckeditor5-dev-tests-travis
 after_success:
 after_success:
-  - codeclimate-test-reporter < coverage/lcov.info
-  - ckeditor5-dev-tests-save-revision
+- ckeditor5-dev-tests-save-revision
+env:
+  global:
+  - secure: Fj33HYfPjfCq+P175FR2n69f1DgpxmRgm9UYsQO9BNHfG/4DQ0dcB1a+mgWijYiy0gv7CnTsFJ1LN5I+HN+x9FJx+m5ShxDXySu5mIXG4h3CW6O+21cgU5B9hqL/Z0fuZxMwfc/q/bv0ol/xpRz/0PZF3UKtnqSUEHnMkIKSa+AJx1b0rFWN+03/Q9vezVMNaUqdkuBJO/okXEuZltjvJtYWVIN4jPh9x4ZfGWWBWp2aPtr+PWrJrtnwrCCHCjywj3Zgp1oKuob7fkwJyBqC7gXsJjybpSrUjaQoxqroUEMHgbMtbW7iwWlNtUcTxxVj3XHl2i/lS5PCkv0NG3lvmatg6XDjEGfehLoHtJM8AobD4NDZIhcKX6zMyOx0hssvGOKcrarbxjZLGlGegT5kjKXrF6E3HdRib1QCRNp+uFWngJMZE8KU/4s2mA3/TgNwwrjkZZjG2HnbkN9SLW+89jA/ih2S1z3Olj1MMZMQKe1A+eXmERK8xHW0bP5wSHSegj7gVa4ZlVmxv4bUnGXi6hT9NGASYRYHT+MD3nOxAzJa5lmK4LT7ygtrpvPWyWTZMg/0K5oPQULQ2ILcGdsSagcaw8XZ3vJ8AsBv3HEUyOZTpK9swM4egf3Uli9LK8RMOsSmBgekjo+SRK5w1tBI/cU6NSQ3zwYMfYBGSYCr09c=
+  - secure: sXPKlnoggLs18TICVHaewd94Un1hDnk3BKNo6bPBDhIBeIMEVq39nF/KRsBqstvQYkP+iZP1EuR/n8Tha5pv9CGVIMJNC4i+GMzu+lpYgIfPx47GKyq2YD1ETyXH7qQxpg0s9ICHLdTTqvIObX+ZzdaqxIRaXDNjWpW0LY97RbQg1X0Yxf/MQwZ9wDeaht9fhROKOdBWNZryHL6hOjRE6D3W7ywEtZRqscytMfrhInDiWcWnWa0aTRSD8XqZ4bwMpLseGz5KPs9KUN7JtyDXEpFq1MzNQGWDk8aKls3KBXWOshKAYxRdmlG252gwCoGWS9j6Cj+ZXV0cpHcjukAjGIxrD1fqkBB+zPuAGNNltVqDiJzd1xoX+KeDpN4CcZCUrgbaz0GQ2GEmxakpH9mi7WDfngFDKOSnodEvt0yYxqfQJbcvyHKL+BlwY0Ip9xcwXTe5LDo7BOKQ/w/Pr2tPmOTMQ+IlR0cIacdknrbURNJPR0MaPyLosUpKn4SqWmGTxz6DXhP/e1HUaObSa3WdjroryKO1PHJ0oJ6Qep669k/yWl2oRJquGFg5ys4iCtBxObwkwhFTuikCeIPI55+4o8yh96jiVAsMVito8xphSI9T6Z2mf5zoJfSgrQ+nudnROpjXYxs8uwRSFVuXXL16Ja+BIBGC7fnf2cQVsHMomvE=

+ 16 - 0
packages/ckeditor5-basic-styles/CHANGELOG.md

@@ -1,6 +1,22 @@
 Changelog
 Changelog
 =========
 =========
 
 
+## [1.0.0-beta.1](https://github.com/ckeditor/ckeditor5-basic-styles/compare/v1.0.0-alpha.2...v1.0.0-beta.1) (2018-03-15)
+
+### Features
+
+* Added the strikethrough feature. ([78719c9](https://github.com/ckeditor/ckeditor5-basic-styles/commit/78719c9))
+
+  Thanks to [@Natim](https://github.com/Natim)!
+* Updated icons for compatibility with the refreshed Lark theme (see [ckeditor/ckeditor5#645](https://github.com/ckeditor/ckeditor5/issues/645)). ([170fec2](https://github.com/ckeditor/ckeditor5-basic-styles/commit/170fec2))
+
+### Other changes
+
+* Aligned feature class naming to the new scheme. ([51a4b61](https://github.com/ckeditor/ckeditor5-basic-styles/commit/51a4b61))
+* Migrated package styles to PostCSS. Moved the visual styles to `@ckeditor/ckeditor5-theme-lark` (see [ckeditor/ckeditor5-ui#144](https://github.com/ckeditor/ckeditor5-ui/issues/144)). ([a5d5d9e](https://github.com/ckeditor/ckeditor5-basic-styles/commit/a5d5d9e))
+* Updated translations. ([1ff4312](https://github.com/ckeditor/ckeditor5-basic-styles/commit/1ff4312))
+
+
 ## [1.0.0-alpha.2](https://github.com/ckeditor/ckeditor5-basic-styles/compare/v1.0.0-alpha.1...v1.0.0-alpha.2) (2017-11-14)
 ## [1.0.0-alpha.2](https://github.com/ckeditor/ckeditor5-basic-styles/compare/v1.0.0-alpha.1...v1.0.0-alpha.2) (2017-11-14)
 
 
 ### Other changes
 ### Other changes

+ 1 - 1
packages/ckeditor5-basic-styles/LICENSE.md

@@ -2,7 +2,7 @@ Software License Agreement
 ==========================
 ==========================
 
 
 **CKEditor 5 Basic Styles Feature** – https://github.com/ckeditor/ckeditor5-basic-styles <br>
 **CKEditor 5 Basic Styles Feature** – https://github.com/ckeditor/ckeditor5-basic-styles <br>
-Copyright (c) 2003-2017, [CKSource](http://cksource.com) Frederico Knabben. All rights reserved.
+Copyright (c) 2003-2018, [CKSource](http://cksource.com) Frederico Knabben. All rights reserved.
 
 
 Licensed under the terms of any of the following licenses at your choice:
 Licensed under the terms of any of the following licenses at your choice:
 
 

+ 3 - 1
packages/ckeditor5-basic-styles/README.md

@@ -4,7 +4,9 @@ CKEditor 5 basic styles feature
 [![Join the chat at https://gitter.im/ckeditor/ckeditor5](https://badges.gitter.im/ckeditor/ckeditor5.svg)](https://gitter.im/ckeditor/ckeditor5?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
 [![Join the chat at https://gitter.im/ckeditor/ckeditor5](https://badges.gitter.im/ckeditor/ckeditor5.svg)](https://gitter.im/ckeditor/ckeditor5?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
 [![npm version](https://badge.fury.io/js/%40ckeditor%2Fckeditor5-basic-styles.svg)](https://www.npmjs.com/package/@ckeditor/ckeditor5-basic-styles)
 [![npm version](https://badge.fury.io/js/%40ckeditor%2Fckeditor5-basic-styles.svg)](https://www.npmjs.com/package/@ckeditor/ckeditor5-basic-styles)
 [![Build Status](https://travis-ci.org/ckeditor/ckeditor5-basic-styles.svg?branch=master)](https://travis-ci.org/ckeditor/ckeditor5-basic-styles)
 [![Build Status](https://travis-ci.org/ckeditor/ckeditor5-basic-styles.svg?branch=master)](https://travis-ci.org/ckeditor/ckeditor5-basic-styles)
-[![Test Coverage](https://codeclimate.com/github/ckeditor/ckeditor5-basic-styles/badges/coverage.svg)](https://codeclimate.com/github/ckeditor/ckeditor5-basic-styles/coverage)
+[![BrowserStack Status](https://www.browserstack.com/automate/badge.svg?badge_key=d3hvenZqQVZERFQ5d09FWXdyT0ozVXhLaVltRFRjTTUyZGpvQWNmWVhUUT0tLUZqNlJ1YWRUd0RvdEVOaEptM1B2Q0E9PQ==--c9d3dee40b9b4471ff3fb516d9ecf8d09292c7e0)](https://www.browserstack.com/automate/public-build/d3hvenZqQVZERFQ5d09FWXdyT0ozVXhLaVltRFRjTTUyZGpvQWNmWVhUUT0tLUZqNlJ1YWRUd0RvdEVOaEptM1B2Q0E9PQ==--c9d3dee40b9b4471ff3fb516d9ecf8d09292c7e0)
+[![Coverage Status](https://coveralls.io/repos/github/ckeditor/ckeditor5-basic-styles/badge.svg?branch=master)](https://coveralls.io/github/ckeditor/ckeditor5-basic-styles?branch=master)
+<br>
 [![Dependency Status](https://david-dm.org/ckeditor/ckeditor5-basic-styles/status.svg)](https://david-dm.org/ckeditor/ckeditor5-basic-styles)
 [![Dependency Status](https://david-dm.org/ckeditor/ckeditor5-basic-styles/status.svg)](https://david-dm.org/ckeditor/ckeditor5-basic-styles)
 [![devDependency Status](https://david-dm.org/ckeditor/ckeditor5-basic-styles/dev-status.svg)](https://david-dm.org/ckeditor/ckeditor5-basic-styles?type=dev)
 [![devDependency Status](https://david-dm.org/ckeditor/ckeditor5-basic-styles/dev-status.svg)](https://david-dm.org/ckeditor/ckeditor5-basic-styles?type=dev)
 
 

+ 2 - 1
packages/ckeditor5-basic-styles/docs/api/basic-styles.md

@@ -6,7 +6,7 @@ category: api-reference
 
 
 [![npm version](https://badge.fury.io/js/%40ckeditor%2Fckeditor5-basic-styles.svg)](https://www.npmjs.com/package/@ckeditor/ckeditor5-basic-styles)
 [![npm version](https://badge.fury.io/js/%40ckeditor%2Fckeditor5-basic-styles.svg)](https://www.npmjs.com/package/@ckeditor/ckeditor5-basic-styles)
 
 
-This package contains features allowing to apply basic text formatting such as bold, italic, underline and code in CKEditor 5.
+This package contains features allowing to apply basic text formatting such as bold, italic, underline, strikethrough and code in CKEditor 5.
 
 
 ## Documentation
 ## Documentation
 
 
@@ -14,6 +14,7 @@ Check out the following plugins:
 
 
 * {@link module:basic-styles/bold~Bold}
 * {@link module:basic-styles/bold~Bold}
 * {@link module:basic-styles/italic~Italic}
 * {@link module:basic-styles/italic~Italic}
+* {@link module:basic-styles/strikethrough~Strikethrough}
 * {@link module:basic-styles/underline~Underline}
 * {@link module:basic-styles/underline~Underline}
 * {@link module:basic-styles/code~Code}
 * {@link module:basic-styles/code~Code}
 
 

+ 2 - 1
packages/ckeditor5-basic-styles/lang/contexts.json

@@ -2,5 +2,6 @@
 	"Bold": "Toolbar button tooltip for the Bold feature.",
 	"Bold": "Toolbar button tooltip for the Bold feature.",
 	"Italic": "Toolbar button tooltip for the Italic feature.",
 	"Italic": "Toolbar button tooltip for the Italic feature.",
 	"Underline": "Toolbar button tooltip for the Underline feature.",
 	"Underline": "Toolbar button tooltip for the Underline feature.",
-	"Code": "Toolbar button tooltip for the Code feature."
+	"Code": "Toolbar button tooltip for the Code feature.",
+	"Strikethrough": "Toolbar button tooltip for the Strikethrough feature."
 }
 }

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/ast.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: ast\n"
 "Language: ast\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/bg.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: bg\n"
 "Language: bg\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 6 - 2
packages/ckeditor5-basic-styles/lang/translations/da.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: da\n"
 "Language: da\n"
@@ -15,8 +15,12 @@ msgstr "Kursiv"
 
 
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgid "Underline"
 msgid "Underline"
-msgstr ""
+msgstr "Understreget"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
+msgstr "Kode"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
 msgstr ""
 msgstr ""

+ 6 - 2
packages/ckeditor5-basic-styles/lang/translations/de.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: de\n"
 "Language: de\n"
@@ -15,8 +15,12 @@ msgstr "Kursiv"
 
 
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgid "Underline"
 msgid "Underline"
-msgstr ""
+msgstr "Unterstrichen"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
+msgstr "Code"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
 msgstr ""
 msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/el.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: el\n"
 "Language: el\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/en-au.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: en_AU\n"
 "Language: en_AU\n"
@@ -19,4 +19,8 @@ msgstr "Underline"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
+msgstr "Code"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
 msgstr ""
 msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/en.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: \n"
 "Language: \n"
@@ -20,3 +20,7 @@ msgstr "Underline"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Code"
 msgstr "Code"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Strikethrough"

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/eo.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: eo\n"
 "Language: eo\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 6 - 2
packages/ckeditor5-basic-styles/lang/translations/es.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: es\n"
 "Language: es\n"
@@ -19,4 +19,8 @@ msgstr "Subrayado"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
-msgstr ""
+msgstr "Código"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Tachado"

+ 26 - 0
packages/ckeditor5-basic-styles/lang/translations/et.po

@@ -0,0 +1,26 @@
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+msgid ""
+msgstr ""
+"Language: et\n"
+"Language-Team: Estonian (https://www.transifex.com/ckeditor/teams/11143/et/)\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+msgctxt "Toolbar button tooltip for the Bold feature."
+msgid "Bold"
+msgstr "Rasvane"
+
+msgctxt "Toolbar button tooltip for the Italic feature."
+msgid "Italic"
+msgstr "Kaldkiri"
+
+msgctxt "Toolbar button tooltip for the Underline feature."
+msgid "Underline"
+msgstr "Allajoonitud"
+
+msgctxt "Toolbar button tooltip for the Code feature."
+msgid "Code"
+msgstr "Kood"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Läbijoonitud"

+ 26 - 0
packages/ckeditor5-basic-styles/lang/translations/eu.po

@@ -0,0 +1,26 @@
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+msgid ""
+msgstr ""
+"Language: eu\n"
+"Language-Team: Basque (https://www.transifex.com/ckeditor/teams/11143/eu/)\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+msgctxt "Toolbar button tooltip for the Bold feature."
+msgid "Bold"
+msgstr "Lodia"
+
+msgctxt "Toolbar button tooltip for the Italic feature."
+msgid "Italic"
+msgstr "Etzana"
+
+msgctxt "Toolbar button tooltip for the Underline feature."
+msgid "Underline"
+msgstr "Azpimarra"
+
+msgctxt "Toolbar button tooltip for the Code feature."
+msgid "Code"
+msgstr "Kodea"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/fi.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: fi\n"
 "Language: fi\n"
@@ -20,3 +20,7 @@ msgstr "Alleviivaus"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Koodi"
 msgstr "Koodi"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/fr.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: fr\n"
 "Language: fr\n"
@@ -20,3 +20,7 @@ msgstr "Souligner"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Code"
 msgstr "Code"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 6 - 2
packages/ckeditor5-basic-styles/lang/translations/gl.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: gl\n"
 "Language: gl\n"
@@ -19,4 +19,8 @@ msgstr "Subliñado"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
-msgstr ""
+msgstr "Código"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Riscado"

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/gu.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: gu\n"
 "Language: gu\n"
@@ -20,3 +20,7 @@ msgstr "નીચે લિટી - અન્ડરલાઇન્"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 7 - 3
packages/ckeditor5-basic-styles/lang/translations/hr.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: hr\n"
 "Language: hr\n"
@@ -15,8 +15,12 @@ msgstr "Ukošeno"
 
 
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgid "Underline"
 msgid "Underline"
-msgstr ""
+msgstr "Podcrtavanje"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
-msgstr ""
+msgstr "Kod"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Precrtano"

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/hu.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: hu\n"
 "Language: hu\n"
@@ -20,3 +20,7 @@ msgstr "Aláhúzott"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/it.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: it\n"
 "Language: it\n"
@@ -20,3 +20,7 @@ msgstr "Sottolineato"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Codice"
 msgstr "Codice"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Barrato"

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/ja.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: ja\n"
 "Language: ja\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/km.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: km\n"
 "Language: km\n"
@@ -20,3 +20,7 @@ msgstr "គូស​បន្ទាត់​ក្រោម"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/kn.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: kn\n"
 "Language: kn\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/ko.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: ko\n"
 "Language: ko\n"
@@ -20,3 +20,7 @@ msgstr "밑줄"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "소스"
 msgstr "소스"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/ku.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: ku\n"
 "Language: ku\n"
@@ -20,3 +20,7 @@ msgstr "ژێرهێڵ"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "کۆد"
 msgstr "کۆد"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "هێڵ بەسەرداهاتوو"

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/nb.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: nb\n"
 "Language: nb\n"
@@ -19,4 +19,8 @@ msgstr "Understreking"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
+msgstr "Kode"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
 msgstr ""
 msgstr ""

+ 7 - 3
packages/ckeditor5-basic-styles/lang/translations/nl.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: nl\n"
 "Language: nl\n"
@@ -11,12 +11,16 @@ msgstr "Vet"
 
 
 msgctxt "Toolbar button tooltip for the Italic feature."
 msgctxt "Toolbar button tooltip for the Italic feature."
 msgid "Italic"
 msgid "Italic"
-msgstr ""
+msgstr "Cursief"
 
 
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgid "Underline"
 msgid "Underline"
-msgstr ""
+msgstr "Onderlijnen"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
+msgstr "Code"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
 msgstr ""
 msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/oc.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: oc\n"
 "Language: oc\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/pl.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: pl\n"
 "Language: pl\n"
@@ -20,3 +20,7 @@ msgstr "Podkreślenie"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Kod"
 msgstr "Kod"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/pt-br.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: pt_BR\n"
 "Language: pt_BR\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/pt.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: pt\n"
 "Language: pt\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Código"
 msgstr "Código"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/ro.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: ro\n"
 "Language: ro\n"
@@ -20,3 +20,7 @@ msgstr "Subliniat"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Cod"
 msgstr "Cod"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 26 - 0
packages/ckeditor5-basic-styles/lang/translations/ru.po

@@ -0,0 +1,26 @@
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+msgid ""
+msgstr ""
+"Language: ru\n"
+"Language-Team: Russian (https://www.transifex.com/ckeditor/teams/11143/ru/)\n"
+"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
+
+msgctxt "Toolbar button tooltip for the Bold feature."
+msgid "Bold"
+msgstr "Жирный"
+
+msgctxt "Toolbar button tooltip for the Italic feature."
+msgid "Italic"
+msgstr "Курсив"
+
+msgctxt "Toolbar button tooltip for the Underline feature."
+msgid "Underline"
+msgstr "Подчеркнутый"
+
+msgctxt "Toolbar button tooltip for the Code feature."
+msgid "Code"
+msgstr "Исходный код"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Зачеркнутый"

+ 26 - 0
packages/ckeditor5-basic-styles/lang/translations/si.po

@@ -0,0 +1,26 @@
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+msgid ""
+msgstr ""
+"Language: si_LK\n"
+"Language-Team: Sinhala (Sri Lanka) (https://www.transifex.com/ckeditor/teams/11143/si_LK/)\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+msgctxt "Toolbar button tooltip for the Bold feature."
+msgid "Bold"
+msgstr "තදකුරු"
+
+msgctxt "Toolbar button tooltip for the Italic feature."
+msgid "Italic"
+msgstr "ඇලකුරු"
+
+msgctxt "Toolbar button tooltip for the Underline feature."
+msgid "Underline"
+msgstr ""
+
+msgctxt "Toolbar button tooltip for the Code feature."
+msgid "Code"
+msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 6 - 2
packages/ckeditor5-basic-styles/lang/translations/sk.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: sk\n"
 "Language: sk\n"
@@ -7,7 +7,7 @@ msgstr ""
 
 
 msgctxt "Toolbar button tooltip for the Bold feature."
 msgctxt "Toolbar button tooltip for the Bold feature."
 msgid "Bold"
 msgid "Bold"
-msgstr "Tučným"
+msgstr "Tučné"
 
 
 msgctxt "Toolbar button tooltip for the Italic feature."
 msgctxt "Toolbar button tooltip for the Italic feature."
 msgid "Italic"
 msgid "Italic"
@@ -20,3 +20,7 @@ msgstr "Podčiarknuté"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "Kód"
 msgstr "Kód"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Preškrtnuté"

+ 26 - 0
packages/ckeditor5-basic-styles/lang/translations/sq.po

@@ -0,0 +1,26 @@
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+msgid ""
+msgstr ""
+"Language: sq\n"
+"Language-Team: Albanian (https://www.transifex.com/ckeditor/teams/11143/sq/)\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+msgctxt "Toolbar button tooltip for the Bold feature."
+msgid "Bold"
+msgstr "Trash"
+
+msgctxt "Toolbar button tooltip for the Italic feature."
+msgid "Italic"
+msgstr "Pjerrtë"
+
+msgctxt "Toolbar button tooltip for the Underline feature."
+msgid "Underline"
+msgstr "Nënvizuar"
+
+msgctxt "Toolbar button tooltip for the Code feature."
+msgid "Code"
+msgstr "Kod"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 6 - 2
packages/ckeditor5-basic-styles/lang/translations/sv.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: sv\n"
 "Language: sv\n"
@@ -15,8 +15,12 @@ msgstr "Kursiv"
 
 
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgid "Underline"
 msgid "Underline"
-msgstr ""
+msgstr "Understrykning"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
+msgstr "Kod"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
 msgstr ""
 msgstr ""

+ 7 - 3
packages/ckeditor5-basic-styles/lang/translations/tr.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: tr\n"
 "Language: tr\n"
@@ -15,8 +15,12 @@ msgstr "İtalik"
 
 
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgctxt "Toolbar button tooltip for the Underline feature."
 msgid "Underline"
 msgid "Underline"
-msgstr ""
+msgstr "Altı Çizgili"
 
 
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
-msgstr ""
+msgstr "Kod"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr "Üstü çizili"

+ 26 - 0
packages/ckeditor5-basic-styles/lang/translations/tt.po

@@ -0,0 +1,26 @@
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+msgid ""
+msgstr ""
+"Language: tt\n"
+"Language-Team: Tatar (https://www.transifex.com/ckeditor/teams/11143/tt/)\n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+
+msgctxt "Toolbar button tooltip for the Bold feature."
+msgid "Bold"
+msgstr "Калын"
+
+msgctxt "Toolbar button tooltip for the Italic feature."
+msgid "Italic"
+msgstr ""
+
+msgctxt "Toolbar button tooltip for the Underline feature."
+msgid "Underline"
+msgstr ""
+
+msgctxt "Toolbar button tooltip for the Code feature."
+msgid "Code"
+msgstr "Код"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 26 - 0
packages/ckeditor5-basic-styles/lang/translations/ug.po

@@ -0,0 +1,26 @@
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+msgid ""
+msgstr ""
+"Language: ug\n"
+"Language-Team: Uighur (https://www.transifex.com/ckeditor/teams/11143/ug/)\n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+
+msgctxt "Toolbar button tooltip for the Bold feature."
+msgid "Bold"
+msgstr "توم"
+
+msgctxt "Toolbar button tooltip for the Italic feature."
+msgid "Italic"
+msgstr "يانتۇ"
+
+msgctxt "Toolbar button tooltip for the Underline feature."
+msgid "Underline"
+msgstr "ئاستى سىزىق"
+
+msgctxt "Toolbar button tooltip for the Code feature."
+msgid "Code"
+msgstr "كودى"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/uk.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: uk\n"
 "Language: uk\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/zh-cn.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: zh_CN\n"
 "Language: zh_CN\n"
@@ -20,3 +20,7 @@ msgstr "下划线"
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr "代码"
 msgstr "代码"
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 5 - 1
packages/ckeditor5-basic-styles/lang/translations/zh.po

@@ -1,4 +1,4 @@
-# Copyright (c) Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+# Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
 msgid ""
 msgid ""
 msgstr ""
 msgstr ""
 "Language: zh_TW\n"
 "Language: zh_TW\n"
@@ -20,3 +20,7 @@ msgstr ""
 msgctxt "Toolbar button tooltip for the Code feature."
 msgctxt "Toolbar button tooltip for the Code feature."
 msgid "Code"
 msgid "Code"
 msgstr ""
 msgstr ""
+
+msgctxt "Toolbar button tooltip for the Strikethrough feature."
+msgid "Strikethrough"
+msgstr ""

+ 12 - 12
packages/ckeditor5-basic-styles/package.json

@@ -1,26 +1,26 @@
 {
 {
   "name": "@ckeditor/ckeditor5-basic-styles",
   "name": "@ckeditor/ckeditor5-basic-styles",
-  "version": "1.0.0-alpha.2",
+  "version": "1.0.0-beta.1",
   "description": "Basic styles feature for CKEditor 5.",
   "description": "Basic styles feature for CKEditor 5.",
   "keywords": [
   "keywords": [
     "ckeditor5",
     "ckeditor5",
     "ckeditor5-feature"
     "ckeditor5-feature"
   ],
   ],
   "dependencies": {
   "dependencies": {
-    "@ckeditor/ckeditor5-core": "^1.0.0-alpha.2",
-    "@ckeditor/ckeditor5-engine": "^1.0.0-alpha.2",
-    "@ckeditor/ckeditor5-ui": "^1.0.0-alpha.2",
-    "@ckeditor/ckeditor5-theme-lark": "^1.0.0-alpha.2"
+    "@ckeditor/ckeditor5-core": "^1.0.0-beta.1",
+    "@ckeditor/ckeditor5-engine": "^1.0.0-beta.1",
+    "@ckeditor/ckeditor5-ui": "^1.0.0-beta.1",
+    "@ckeditor/ckeditor5-theme-lark": "^1.0.0-beta.1"
   },
   },
   "devDependencies": {
   "devDependencies": {
-    "@ckeditor/ckeditor5-editor-classic": "^1.0.0-alpha.2",
-    "@ckeditor/ckeditor5-essentials": "^1.0.0-alpha.2",
-    "@ckeditor/ckeditor5-paragraph": "^1.0.0-alpha.2",
-    "@ckeditor/ckeditor5-utils": "^1.0.0-alpha.2",
-    "eslint": "^4.8.0",
-    "eslint-config-ckeditor5": "^1.0.6",
+    "@ckeditor/ckeditor5-editor-classic": "^1.0.0-beta.1",
+    "@ckeditor/ckeditor5-essentials": "^1.0.0-beta.1",
+    "@ckeditor/ckeditor5-paragraph": "^1.0.0-beta.1",
+    "@ckeditor/ckeditor5-utils": "^1.0.0-beta.1",
+    "eslint": "^4.15.0",
+    "eslint-config-ckeditor5": "^1.0.7",
     "husky": "^0.14.3",
     "husky": "^0.14.3",
-    "lint-staged": "^4.2.3"
+    "lint-staged": "^6.0.0"
   },
   },
   "engines": {
   "engines": {
     "node": ">=6.0.0",
     "node": ">=6.0.0",

+ 13 - 13
packages/ckeditor5-basic-styles/src/attributecommand.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
@@ -16,7 +16,7 @@ import Command from '@ckeditor/ckeditor5-core/src/command';
  * `AttributeCommand` uses {@link module:engine/model/document~Document#selection}
  * `AttributeCommand` uses {@link module:engine/model/document~Document#selection}
  * to decide which nodes (if any) should be changed, and applies or removes the attribute from them.
  * to decide which nodes (if any) should be changed, and applies or removes the attribute from them.
  *
  *
- * The command checks the {@link module:engine/model/document~Document#schema} to decide if it can be enabled
+ * The command checks the {@link module:engine/model/model~Model#schema} to decide if it can be enabled
  * for the current selection and to which nodes the attribute can be applied.
  * for the current selection and to which nodes the attribute can be applied.
  *
  *
  * @extends module:core/command~Command
  * @extends module:core/command~Command
@@ -55,10 +55,11 @@ export default class AttributeCommand extends Command {
 	 * Updates the command's {@link #value} and {@link #isEnabled} based on the current selection.
 	 * Updates the command's {@link #value} and {@link #isEnabled} based on the current selection.
 	 */
 	 */
 	refresh() {
 	refresh() {
-		const doc = this.editor.document;
+		const model = this.editor.model;
+		const doc = model.document;
 
 
 		this.value = doc.selection.hasAttribute( this.attributeKey );
 		this.value = doc.selection.hasAttribute( this.attributeKey );
-		this.isEnabled = doc.schema.checkAttributeInSelection( doc.selection, this.attributeKey );
+		this.isEnabled = model.schema.checkAttributeInSelection( doc.selection, this.attributeKey );
 	}
 	}
 
 
 	/**
 	/**
@@ -80,29 +81,28 @@ export default class AttributeCommand extends Command {
 	 * @param {Boolean} [options.forceValue] If set, it will force the command behavior. If `true`, the command will apply the attribute,
 	 * @param {Boolean} [options.forceValue] If set, it will force the command behavior. If `true`, the command will apply the attribute,
 	 * otherwise the command will remove the attribute.
 	 * otherwise the command will remove the attribute.
 	 * If not set, the command will look for its current value to decide what it should do.
 	 * If not set, the command will look for its current value to decide what it should do.
-	 * @param {module:engine/model/batch~Batch} [options.batch] A batch to group undo steps.
 	 */
 	 */
 	execute( options = {} ) {
 	execute( options = {} ) {
-		const doc = this.editor.document;
+		const model = this.editor.model;
+		const doc = model.document;
 		const selection = doc.selection;
 		const selection = doc.selection;
 		const value = ( options.forceValue === undefined ) ? !this.value : options.forceValue;
 		const value = ( options.forceValue === undefined ) ? !this.value : options.forceValue;
 
 
-		doc.enqueueChanges( () => {
+		model.change( writer => {
 			if ( selection.isCollapsed ) {
 			if ( selection.isCollapsed ) {
 				if ( value ) {
 				if ( value ) {
-					selection.setAttribute( this.attributeKey, true );
+					writer.setSelectionAttribute( this.attributeKey, true );
 				} else {
 				} else {
-					selection.removeAttribute( this.attributeKey );
+					writer.removeSelectionAttribute( this.attributeKey );
 				}
 				}
 			} else {
 			} else {
-				const ranges = doc.schema.getValidRanges( selection.getRanges(), this.attributeKey );
-				const batch = options.batch || doc.batch();
+				const ranges = model.schema.getValidRanges( selection.getRanges(), this.attributeKey );
 
 
 				for ( const range of ranges ) {
 				for ( const range of ranges ) {
 					if ( value ) {
 					if ( value ) {
-						batch.setAttribute( range, this.attributeKey, value );
+						writer.setAttribute( this.attributeKey, value, range );
 					} else {
 					} else {
-						batch.removeAttribute( range, this.attributeKey );
+						writer.removeAttribute( this.attributeKey, range );
 					}
 					}
 				}
 				}
 			}
 			}

+ 7 - 39
packages/ckeditor5-basic-styles/src/bold.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
@@ -8,14 +8,14 @@
  */
  */
 
 
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import BoldEngine from './boldengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import boldIcon from '../theme/icons/bold.svg';
+import BoldEditing from './bold/boldediting';
+import BoldUI from './bold/boldui';
 
 
 /**
 /**
- * The bold feature. It introduces the Bold button and the <kbd>Ctrl+B</kbd> keystroke.
+ * The bold feature.
  *
  *
- * It uses the {@link module:basic-styles/boldengine~BoldEngine bold engine feature}.
+ * It loads the {@link module:basic-styles/bold/boldediting~BoldEditing bold editing feature}
+ * and {@link module:basic-styles/bold/boldui~BoldUI bold UI feature}.
  *
  *
  * @extends module:core/plugin~Plugin
  * @extends module:core/plugin~Plugin
  */
  */
@@ -24,7 +24,7 @@ export default class Bold extends Plugin {
 	 * @inheritDoc
 	 * @inheritDoc
 	 */
 	 */
 	static get requires() {
 	static get requires() {
-		return [ BoldEngine ];
+		return [ BoldEditing, BoldUI ];
 	}
 	}
 
 
 	/**
 	/**
@@ -33,36 +33,4 @@ export default class Bold extends Plugin {
 	static get pluginName() {
 	static get pluginName() {
 		return 'Bold';
 		return 'Bold';
 	}
 	}
-
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const t = editor.t;
-		const command = editor.commands.get( 'bold' );
-		const keystroke = 'CTRL+B';
-
-		// Add bold button to feature components.
-		editor.ui.componentFactory.add( 'bold', locale => {
-			const view = new ButtonView( locale );
-
-			view.set( {
-				label: t( 'Bold' ),
-				icon: boldIcon,
-				keystroke,
-				tooltip: true
-			} );
-
-			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
-
-			// Execute command.
-			this.listenTo( view, 'execute', () => editor.execute( 'bold' ) );
-
-			return view;
-		} );
-
-		// Set the Ctrl+B keystroke.
-		editor.keystrokes.set( keystroke, 'bold' );
-	}
 }
 }

+ 53 - 0
packages/ckeditor5-basic-styles/src/bold/boldediting.js

@@ -0,0 +1,53 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/bold/boldediting
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import AttributeCommand from '../attributecommand';
+
+const BOLD = 'bold';
+
+/**
+ * The bold editing feature.
+ *
+ * It registers the `bold` command and introduces the `bold` attribute in the model which renders to the view
+ * as a `<strong>` element.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class BoldEditing extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+		// Allow bold attribute on text nodes.
+		editor.model.schema.extend( '$text', { allowAttributes: BOLD } );
+
+		// Build converter from model to view for data and editing pipelines.
+
+		editor.conversion.attributeToElement( {
+			model: BOLD,
+			view: 'strong',
+			upcastAlso: [
+				'b',
+				{
+					style: {
+						'font-weight': 'bold'
+					}
+				}
+			]
+		} );
+
+		// Create bold command.
+		editor.commands.add( BOLD, new AttributeCommand( editor, BOLD ) );
+
+		// Set the Ctrl+B keystroke.
+		editor.keystrokes.set( 'CTRL+B', BOLD );
+	}
+}

+ 50 - 0
packages/ckeditor5-basic-styles/src/bold/boldui.js

@@ -0,0 +1,50 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/bold/boldui
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+
+import boldIcon from '../../theme/icons/bold.svg';
+
+const BOLD = 'bold';
+
+/**
+ * The bold UI feature. It introduces the Bold button.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class BoldUI extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+		const t = editor.t;
+
+		// Add bold button to feature components.
+		editor.ui.componentFactory.add( BOLD, locale => {
+			const command = editor.commands.get( BOLD );
+			const view = new ButtonView( locale );
+
+			view.set( {
+				label: t( 'Bold' ),
+				icon: boldIcon,
+				keystroke: 'CTRL+B',
+				tooltip: true
+			} );
+
+			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
+
+			// Execute command.
+			this.listenTo( view, 'execute', () => editor.execute( BOLD ) );
+
+			return view;
+		} );
+	}
+}

+ 0 - 54
packages/ckeditor5-basic-styles/src/boldengine.js

@@ -1,54 +0,0 @@
-/**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
- * For licensing, see LICENSE.md.
- */
-
-/**
- * @module basic-styles/boldengine
- */
-
-import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import buildModelConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildmodelconverter';
-import buildViewConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildviewconverter';
-import AttributeCommand from './attributecommand';
-
-const BOLD = 'bold';
-
-/**
- * The bold engine feature.
- *
- * It registers the `bold` command and introduces the `bold` attribute in the model which renders to the view
- * as a `<strong>` element.
- *
- * @extends module:core/plugin~Plugin
- */
-export default class BoldEngine extends Plugin {
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const data = editor.data;
-		const editing = editor.editing;
-
-		// Allow bold attribute on all inline nodes.
-		editor.document.schema.allow( { name: '$inline', attributes: BOLD, inside: '$block' } );
-		// Temporary workaround. See https://github.com/ckeditor/ckeditor5/issues/477.
-		editor.document.schema.allow( { name: '$inline', attributes: BOLD, inside: '$clipboardHolder' } );
-
-		// Build converter from model to view for data and editing pipelines.
-		buildModelConverter().for( data.modelToView, editing.modelToView )
-			.fromAttribute( BOLD )
-			.toElement( 'strong' );
-
-		// Build converter from view to model for data pipeline.
-		buildViewConverter().for( data.viewToModel )
-			.fromElement( 'strong' )
-			.fromElement( 'b' )
-			.fromAttribute( 'style', { 'font-weight': 'bold' } )
-			.toAttribute( BOLD, true );
-
-		// Create bold command.
-		editor.commands.add( BOLD, new AttributeCommand( editor, BOLD ) );
-	}
-}

+ 8 - 35
packages/ckeditor5-basic-styles/src/code.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
@@ -8,16 +8,16 @@
  */
  */
 
 
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import CodeEngine from './codeengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import codeIcon from '../theme/icons/code.svg';
+import CodeEditing from './code/codeediting';
+import CodeUI from './code/codeui';
 
 
-import '../theme/code.scss';
+import '../theme/code.css';
 
 
 /**
 /**
- * The code feature. It introduces the Code button.
+ * The code feature.
  *
  *
- * It uses the {@link module:basic-styles/codeengine~CodeEngine code engine feature}.
+ * It loads the {@link module:basic-styles/code/codeediting~CodeEditing code editing feature}
+ * and {@link module:basic-styles/code/codeui~CodeUI code UI feature}.
  *
  *
  * @extends module:core/plugin~Plugin
  * @extends module:core/plugin~Plugin
  */
  */
@@ -26,7 +26,7 @@ export default class Code extends Plugin {
 	 * @inheritDoc
 	 * @inheritDoc
 	 */
 	 */
 	static get requires() {
 	static get requires() {
-		return [ CodeEngine ];
+		return [ CodeEditing, CodeUI ];
 	}
 	}
 
 
 	/**
 	/**
@@ -35,31 +35,4 @@ export default class Code extends Plugin {
 	static get pluginName() {
 	static get pluginName() {
 		return 'Code';
 		return 'Code';
 	}
 	}
-
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const t = editor.t;
-		const command = editor.commands.get( 'code' );
-
-		// Add code button to feature components.
-		editor.ui.componentFactory.add( 'code', locale => {
-			const view = new ButtonView( locale );
-
-			view.set( {
-				label: t( 'Code' ),
-				icon: codeIcon,
-				tooltip: true
-			} );
-
-			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
-
-			// Execute command.
-			this.listenTo( view, 'execute', () => editor.execute( 'code' ) );
-
-			return view;
-		} );
-	}
 }
 }

+ 46 - 0
packages/ckeditor5-basic-styles/src/code/codeediting.js

@@ -0,0 +1,46 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/code/codeediting
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import AttributeCommand from '../attributecommand';
+
+const CODE = 'code';
+
+/**
+ * The code editing feature.
+ *
+ * It registers the `code` command and introduces the `code` attribute in the model which renders to the view
+ * as a `<code>` element.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class CodeEditing extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+
+		// Allow code attribute on text nodes.
+		editor.model.schema.extend( '$text', { allowAttributes: CODE } );
+
+		editor.conversion.attributeToElement( {
+			model: CODE,
+			view: 'code',
+			upcastAlso: {
+				style: {
+					'word-wrap': 'break-word'
+				}
+			}
+		} );
+
+		// Create code command.
+		editor.commands.add( CODE, new AttributeCommand( editor, CODE ) );
+	}
+}

+ 51 - 0
packages/ckeditor5-basic-styles/src/code/codeui.js

@@ -0,0 +1,51 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/code/codeui
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+
+import codeIcon from '../../theme/icons/code.svg';
+
+import '../../theme/code.css';
+
+const CODE = 'code';
+
+/**
+ * The code UI feature. It introduces the Code button.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class CodeUI extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+		const t = editor.t;
+
+		// Add code button to feature components.
+		editor.ui.componentFactory.add( CODE, locale => {
+			const command = editor.commands.get( CODE );
+			const view = new ButtonView( locale );
+
+			view.set( {
+				label: t( 'Code' ),
+				icon: codeIcon,
+				tooltip: true
+			} );
+
+			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
+
+			// Execute command.
+			this.listenTo( view, 'execute', () => editor.execute( CODE ) );
+
+			return view;
+		} );
+	}
+}

+ 0 - 53
packages/ckeditor5-basic-styles/src/codeengine.js

@@ -1,53 +0,0 @@
-/**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
- * For licensing, see LICENSE.md.
- */
-
-/**
- * @module basic-styles/codeengine
- */
-
-import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import buildModelConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildmodelconverter';
-import buildViewConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildviewconverter';
-import AttributeCommand from './attributecommand';
-
-const CODE = 'code';
-
-/**
- * The code engine feature.
- *
- * It registers the `code` command and introduces the `code` attribute in the model which renders to the view
- * as a `<code>` element.
- *
- * @extends module:core/plugin~Plugin
- */
-export default class CodeEngine extends Plugin {
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const data = editor.data;
-		const editing = editor.editing;
-
-		// Allow code attribute on all inline nodes.
-		editor.document.schema.allow( { name: '$inline', attributes: CODE, inside: '$block' } );
-		// Temporary workaround. See https://github.com/ckeditor/ckeditor5/issues/477.
-		editor.document.schema.allow( { name: '$inline', attributes: CODE, inside: '$clipboardHolder' } );
-
-		// Build converter from model to view for data and editing pipelines.
-		buildModelConverter().for( data.modelToView, editing.modelToView )
-			.fromAttribute( CODE )
-			.toElement( 'code' );
-
-		// Build converter from view to model for data pipeline.
-		buildViewConverter().for( data.viewToModel )
-			.fromElement( 'code' )
-			.fromAttribute( 'style', { 'word-wrap': 'break-word' } )
-			.toAttribute( CODE, true );
-
-		// Create code command.
-		editor.commands.add( CODE, new AttributeCommand( editor, CODE ) );
-	}
-}

+ 7 - 39
packages/ckeditor5-basic-styles/src/italic.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
@@ -8,14 +8,14 @@
  */
  */
 
 
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import ItalicEngine from './italicengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import italicIcon from '../theme/icons/italic.svg';
+import ItalicEditing from './italic/italicediting';
+import ItalicUI from './italic/italicui';
 
 
 /**
 /**
- * The italic feature. It introduces the Italic button and the <kbd>Ctrl+I</kbd> keystroke.
+ * The italic feature.
  *
  *
- * It uses the {@link module:basic-styles/italicengine~ItalicEngine italic engine feature}.
+ * It loads the {@link module:basic-styles/italic/italicediting~ItalicEditing} and
+ * {@link module:basic-styles/italic/italicui~ItalicUI} plugins.
  *
  *
  * @extends module:core/plugin~Plugin
  * @extends module:core/plugin~Plugin
  */
  */
@@ -24,7 +24,7 @@ export default class Italic extends Plugin {
 	 * @inheritDoc
 	 * @inheritDoc
 	 */
 	 */
 	static get requires() {
 	static get requires() {
-		return [ ItalicEngine ];
+		return [ ItalicEditing, ItalicUI ];
 	}
 	}
 
 
 	/**
 	/**
@@ -33,36 +33,4 @@ export default class Italic extends Plugin {
 	static get pluginName() {
 	static get pluginName() {
 		return 'Italic';
 		return 'Italic';
 	}
 	}
-
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const t = editor.t;
-		const command = editor.commands.get( 'italic' );
-		const keystroke = 'CTRL+I';
-
-		// Add bold button to feature components.
-		editor.ui.componentFactory.add( 'italic', locale => {
-			const view = new ButtonView( locale );
-
-			view.set( {
-				label: t( 'Italic' ),
-				icon: italicIcon,
-				keystroke,
-				tooltip: true
-			} );
-
-			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
-
-			// Execute command.
-			this.listenTo( view, 'execute', () => editor.execute( 'italic' ) );
-
-			return view;
-		} );
-
-		// Set the Ctrl+I keystroke.
-		editor.keystrokes.set( keystroke, 'italic' );
-	}
 }
 }

+ 52 - 0
packages/ckeditor5-basic-styles/src/italic/italicediting.js

@@ -0,0 +1,52 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/italic/italicediting
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import AttributeCommand from '../attributecommand';
+
+const ITALIC = 'italic';
+
+/**
+ * The italic editing feature.
+ *
+ * It registers the `italic` command, the <kbd>Ctrl+I</kbd> keystroke and introduces the `italic` attribute in the model
+ * which renders to the view as an `<em>` element.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class ItalicEditing extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+
+		// Allow italic attribute on text nodes.
+		editor.model.schema.extend( '$text', { allowAttributes: ITALIC } );
+
+		editor.conversion.attributeToElement( {
+			model: ITALIC,
+			view: 'i',
+			upcastAlso: [
+				'em',
+				{
+					style: {
+						'font-style': 'italic'
+					}
+				}
+			]
+		} );
+
+		// Create italic command.
+		editor.commands.add( ITALIC, new AttributeCommand( editor, ITALIC ) );
+
+		// Set the Ctrl+I keystroke.
+		editor.keystrokes.set( 'CTRL+I', ITALIC );
+	}
+}

+ 50 - 0
packages/ckeditor5-basic-styles/src/italic/italicui.js

@@ -0,0 +1,50 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/italic/italicui
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+
+import italicIcon from '../../theme/icons/italic.svg';
+
+const ITALIC = 'italic';
+
+/**
+ * The italic UI feature. It introduces the Italic button.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class ItalicUI extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+		const t = editor.t;
+
+		// Add bold button to feature components.
+		editor.ui.componentFactory.add( ITALIC, locale => {
+			const command = editor.commands.get( ITALIC );
+			const view = new ButtonView( locale );
+
+			view.set( {
+				label: t( 'Italic' ),
+				icon: italicIcon,
+				keystroke: 'CTRL+I',
+				tooltip: true
+			} );
+
+			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
+
+			// Execute command.
+			this.listenTo( view, 'execute', () => editor.execute( ITALIC ) );
+
+			return view;
+		} );
+	}
+}

+ 0 - 54
packages/ckeditor5-basic-styles/src/italicengine.js

@@ -1,54 +0,0 @@
-/**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
- * For licensing, see LICENSE.md.
- */
-
-/**
- * @module basic-styles/italicengine
- */
-
-import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import buildModelConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildmodelconverter';
-import buildViewConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildviewconverter';
-import AttributeCommand from './attributecommand';
-
-const ITALIC = 'italic';
-
-/**
- * The italic engine feature.
- *
- * It registers the `italic` command and introduces the `italic` attribute in the model which renders to the view
- * as an `<em>` element.
- *
- * @extends module:core/plugin~Plugin
- */
-export default class ItalicEngine extends Plugin {
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const data = editor.data;
-		const editing = editor.editing;
-
-		// Allow italic attribute on all inline nodes.
-		editor.document.schema.allow( { name: '$inline', attributes: ITALIC, inside: '$block' } );
-		// Temporary workaround. See https://github.com/ckeditor/ckeditor5/issues/477.
-		editor.document.schema.allow( { name: '$inline', attributes: ITALIC, inside: '$clipboardHolder' } );
-
-		// Build converter from model to view for data and editing pipelines.
-		buildModelConverter().for( data.modelToView, editing.modelToView )
-			.fromAttribute( ITALIC )
-			.toElement( 'i' );
-
-		// Build converter from view to model for data pipeline.
-		buildViewConverter().for( data.viewToModel )
-			.fromElement( 'em' )
-			.fromElement( 'i' )
-			.fromAttribute( 'style', { 'font-style': 'italic' } )
-			.toAttribute( ITALIC, true );
-
-		// Create italic command.
-		editor.commands.add( ITALIC, new AttributeCommand( editor, ITALIC ) );
-	}
-}

+ 36 - 0
packages/ckeditor5-basic-styles/src/strikethrough.js

@@ -0,0 +1,36 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/strikethrough
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import StrikethroughEditing from './strikethrough/strikethroughediting';
+import StrikethroughUI from './strikethrough/strikethroughui';
+
+/**
+ * The strikethrough feature.
+ *
+ * It loads the {@link module:basic-styles/strikethrough/strikethroughediting~StrikethroughEditing} and
+ * {@link module:basic-styles/strikethrough/strikethroughui~StrikethroughUI} plugins.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class Strikethrough extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	static get requires() {
+		return [ StrikethroughEditing, StrikethroughUI ];
+	}
+
+	/**
+	 * @inheritDoc
+	 */
+	static get pluginName() {
+		return 'Strikethrough';
+	}
+}

+ 54 - 0
packages/ckeditor5-basic-styles/src/strikethrough/strikethroughediting.js

@@ -0,0 +1,54 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/strikethrough/strikethroughediting
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import AttributeCommand from '../attributecommand';
+
+const STRIKETHROUGH = 'strikethrough';
+
+/**
+ * The strikethrough editing feature.
+ *
+ * It registers the `strikethrough` command, the <kbd>Ctrl+Shift+X</kbd> keystroke and introduces the
+ * `strikethroughsthrough` attribute in the model which renders to the view
+ * as a `<s>` element.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class StrikethroughEditing extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+
+		// Allow strikethrough attribute on text nodes.
+		editor.model.schema.extend( '$text', { allowAttributes: STRIKETHROUGH } );
+
+		editor.conversion.attributeToElement( {
+			model: STRIKETHROUGH,
+			view: 's',
+			upcastAlso: [
+				'del',
+				'strike',
+				{
+					style: {
+						'text-decoration': 'line-through'
+					}
+				}
+			]
+		} );
+
+		// Create strikethrough command.
+		editor.commands.add( STRIKETHROUGH, new AttributeCommand( editor, STRIKETHROUGH ) );
+
+		// Set the Ctrl+Shift+X keystroke.
+		editor.keystrokes.set( 'CTRL+SHIFT+X', 'strikethrough' );
+	}
+}

+ 50 - 0
packages/ckeditor5-basic-styles/src/strikethrough/strikethroughui.js

@@ -0,0 +1,50 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/strikethrough/strikethroughui
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+
+import strikethroughIcon from '../../theme/icons/strikethrough.svg';
+
+const STRIKETHROUGH = 'strikethrough';
+
+/**
+ * The strikethrough UI feature. It introduces the Strikethrough button.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class StrikethroughUI extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+		const t = editor.t;
+
+		// Add strikethrough button to feature components.
+		editor.ui.componentFactory.add( STRIKETHROUGH, locale => {
+			const command = editor.commands.get( STRIKETHROUGH );
+			const view = new ButtonView( locale );
+
+			view.set( {
+				label: t( 'Strikethrough' ),
+				icon: strikethroughIcon,
+				keystroke: 'CTRL+SHIFT+X',
+				tooltip: true
+			} );
+
+			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
+
+			// Execute command.
+			this.listenTo( view, 'execute', () => editor.execute( STRIKETHROUGH ) );
+
+			return view;
+		} );
+	}
+}

+ 7 - 39
packages/ckeditor5-basic-styles/src/underline.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
@@ -8,14 +8,14 @@
  */
  */
 
 
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
 import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import UnderlineEngine from './underlineengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import underlineIcon from '../theme/icons/underline.svg';
+import UnderlineEditing from './underline/underlineediting';
+import UnderlineUI from './underline/underlineui';
 
 
 /**
 /**
- * The underline feature. It introduces the Underline button and the <kbd>Ctrl+U</kbd> keystroke.
+ * The underline feature.
  *
  *
- * It uses the {@link module:basic-styles/underlineengine~UnderlineEngine underline engine feature}.
+ * It loads the {@link module:basic-styles/underline/underlineediting~UnderlineEditing} and
+ * {@link module:basic-styles/underline/underlineui~UnderlineUI} plugins.
  *
  *
  * @extends module:core/plugin~Plugin
  * @extends module:core/plugin~Plugin
  */
  */
@@ -24,7 +24,7 @@ export default class Underline extends Plugin {
 	 * @inheritDoc
 	 * @inheritDoc
 	 */
 	 */
 	static get requires() {
 	static get requires() {
-		return [ UnderlineEngine ];
+		return [ UnderlineEditing, UnderlineUI ];
 	}
 	}
 
 
 	/**
 	/**
@@ -33,36 +33,4 @@ export default class Underline extends Plugin {
 	static get pluginName() {
 	static get pluginName() {
 		return 'Underline';
 		return 'Underline';
 	}
 	}
-
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const t = editor.t;
-		const command = editor.commands.get( 'underline' );
-		const keystroke = 'CTRL+U';
-
-		// Add bold button to feature components.
-		editor.ui.componentFactory.add( 'underline', locale => {
-			const view = new ButtonView( locale );
-
-			view.set( {
-				label: t( 'Underline' ),
-				icon: underlineIcon,
-				keystroke,
-				tooltip: true
-			} );
-
-			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
-
-			// Execute command.
-			this.listenTo( view, 'execute', () => editor.execute( 'underline' ) );
-
-			return view;
-		} );
-
-		// Set the Ctrl+U keystroke.
-		editor.keystrokes.set( keystroke, 'underline' );
-	}
 }
 }

+ 49 - 0
packages/ckeditor5-basic-styles/src/underline/underlineediting.js

@@ -0,0 +1,49 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/underline/underlineediting
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import AttributeCommand from '../attributecommand';
+
+const UNDERLINE = 'underline';
+
+/**
+ * The underline editing feature.
+ *
+ * It registers the `underline` command, the <kbd>Ctrl+U</kbd> keystroke
+ * and introduces the `underline` attribute in the model which renders to the view as an `<u>` element.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class UnderlineEditing extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+
+		// Allow strikethrough attribute on text nodes.
+		editor.model.schema.extend( '$text', { allowAttributes: UNDERLINE } );
+
+		editor.conversion.attributeToElement( {
+			model: UNDERLINE,
+			view: 'u',
+			upcastAlso: {
+				style: {
+					'text-decoration': 'underline'
+				}
+			}
+		} );
+
+		// Create underline command.
+		editor.commands.add( UNDERLINE, new AttributeCommand( editor, UNDERLINE ) );
+
+		// Set the Ctrl+U keystroke.
+		editor.keystrokes.set( 'CTRL+U', 'underline' );
+	}
+}

+ 50 - 0
packages/ckeditor5-basic-styles/src/underline/underlineui.js

@@ -0,0 +1,50 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/**
+ * @module basic-styles/underline/underlineui
+ */
+
+import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+
+import underlineIcon from '../../theme/icons/underline.svg';
+
+const UNDERLINE = 'underline';
+
+/**
+ * The underline UI feature. It introduces the Underline button.
+ *
+ * @extends module:core/plugin~Plugin
+ */
+export default class UnderlineUI extends Plugin {
+	/**
+	 * @inheritDoc
+	 */
+	init() {
+		const editor = this.editor;
+		const t = editor.t;
+
+		// Add bold button to feature components.
+		editor.ui.componentFactory.add( UNDERLINE, locale => {
+			const command = editor.commands.get( UNDERLINE );
+			const view = new ButtonView( locale );
+
+			view.set( {
+				label: t( 'Underline' ),
+				icon: underlineIcon,
+				keystroke: 'CTRL+U',
+				tooltip: true
+			} );
+
+			view.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );
+
+			// Execute command.
+			this.listenTo( view, 'execute', () => editor.execute( UNDERLINE ) );
+
+			return view;
+		} );
+	}
+}

+ 0 - 53
packages/ckeditor5-basic-styles/src/underlineengine.js

@@ -1,53 +0,0 @@
-/**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
- * For licensing, see LICENSE.md.
- */
-
-/**
- * @module basic-styles/underlineengine
- */
-
-import Plugin from '@ckeditor/ckeditor5-core/src/plugin';
-import buildModelConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildmodelconverter';
-import buildViewConverter from '@ckeditor/ckeditor5-engine/src/conversion/buildviewconverter';
-import AttributeCommand from './attributecommand';
-
-const UNDERLINE = 'underline';
-
-/**
- * The underline engine feature.
- *
- * It registers the `underline` command and introduces the `underline` attribute in the model which renders to the view
- * as an `<u>` element.
- *
- * @extends module:core/plugin~Plugin
- */
-export default class UnderlineEngine extends Plugin {
-	/**
-	 * @inheritDoc
-	 */
-	init() {
-		const editor = this.editor;
-		const data = editor.data;
-		const editing = editor.editing;
-
-		// Allow underline attribute on all inline nodes.
-		editor.document.schema.allow( { name: '$inline', attributes: UNDERLINE, inside: '$block' } );
-		// Temporary workaround. See https://github.com/ckeditor/ckeditor5/issues/477.
-		editor.document.schema.allow( { name: '$inline', attributes: UNDERLINE, inside: '$clipboardHolder' } );
-
-		// Build converter from model to view for data and editing pipelines.
-		buildModelConverter().for( data.modelToView, editing.modelToView )
-			.fromAttribute( UNDERLINE )
-			.toElement( 'u' );
-
-		// Build converter from view to model for data pipeline.
-		buildViewConverter().for( data.viewToModel )
-			.fromElement( 'u' )
-			.fromAttribute( 'style', { 'text-decoration': 'underline' } )
-			.toAttribute( UNDERLINE, true );
-
-		// Create underline command.
-		editor.commands.add( UNDERLINE, new AttributeCommand( editor, UNDERLINE ) );
-	}
-}

+ 82 - 76
packages/ckeditor5-basic-styles/tests/attributecommand.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
@@ -7,40 +7,38 @@ import AttributeCommand from '../src/attributecommand';
 
 
 import ModelTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/modeltesteditor';
 import ModelTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/modeltesteditor';
 
 
-import Document from '@ckeditor/ckeditor5-engine/src/model/document';
-import Batch from '@ckeditor/ckeditor5-engine/src/model/batch';
 import Range from '@ckeditor/ckeditor5-engine/src/model/range';
 import Range from '@ckeditor/ckeditor5-engine/src/model/range';
 import Position from '@ckeditor/ckeditor5-engine/src/model/position';
 import Position from '@ckeditor/ckeditor5-engine/src/model/position';
 import { setData, getData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { setData, getData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 
 
 describe( 'AttributeCommand', () => {
 describe( 'AttributeCommand', () => {
 	const attrKey = 'bold';
 	const attrKey = 'bold';
-	let editor, command, doc, root;
+	let editor, command, model, doc, root;
 
 
 	beforeEach( () => {
 	beforeEach( () => {
 		return ModelTestEditor
 		return ModelTestEditor
 			.create()
 			.create()
 			.then( newEditor => {
 			.then( newEditor => {
 				editor = newEditor;
 				editor = newEditor;
-				doc = editor.document;
+				model = editor.model;
+				doc = model.document;
 				root = doc.getRoot();
 				root = doc.getRoot();
 
 
 				command = new AttributeCommand( editor, attrKey );
 				command = new AttributeCommand( editor, attrKey );
 
 
-				doc.schema.registerItem( 'p', '$block' );
-				doc.schema.registerItem( 'h1', '$block' );
-				doc.schema.registerItem( 'img', '$inline' );
-				doc.schema.objects.add( 'img' );
-
-				// Allow block in "root" (DIV)
-				doc.schema.allow( { name: '$block', inside: '$root' } );
-
-				// Bold text is allowed only in P.
-				doc.schema.allow( { name: '$text', attributes: 'bold', inside: 'p' } );
-				doc.schema.allow( { name: 'p', attributes: 'bold', inside: '$root' } );
-
-				// Disallow bold on image.
-				doc.schema.disallow( { name: 'img', attributes: 'bold', inside: '$root' } );
+				model.schema.register( 'p', { inheritAllFrom: '$block' } );
+				model.schema.register( 'h1', { inheritAllFrom: '$block' } );
+				model.schema.register( 'img', {
+					allowWhere: [ '$block', '$text' ],
+					isObject: true
+				} );
+
+				model.schema.addAttributeCheck( ( ctx, attributeName ) => {
+					// Allow 'bold' on p>$text.
+					if ( ctx.endsWith( 'p $text' ) && attributeName == 'bold' ) {
+						return true;
+					}
+				} );
 			} );
 			} );
 	} );
 	} );
 
 
@@ -52,16 +50,20 @@ describe( 'AttributeCommand', () => {
 
 
 	describe( 'value', () => {
 	describe( 'value', () => {
 		it( 'is true when selection has the attribute', () => {
 		it( 'is true when selection has the attribute', () => {
-			doc.enqueueChanges( () => {
-				doc.selection.setAttribute( attrKey, true );
+			model.change( writer => {
+				writer.setSelectionAttribute( attrKey, true );
 			} );
 			} );
 
 
 			expect( command.value ).to.be.true;
 			expect( command.value ).to.be.true;
 		} );
 		} );
 
 
 		it( 'is false when selection does not have the attribute', () => {
 		it( 'is false when selection does not have the attribute', () => {
-			doc.enqueueChanges( () => {
-				doc.selection.removeAttribute( attrKey );
+			model.change( writer => {
+				writer.setSelectionAttribute( attrKey, true );
+			} );
+
+			model.change( writer => {
+				writer.removeSelectionAttribute( attrKey );
 			} );
 			} );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
@@ -69,18 +71,23 @@ describe( 'AttributeCommand', () => {
 
 
 		// See https://github.com/ckeditor/ckeditor5-core/issues/73#issuecomment-311572827.
 		// See https://github.com/ckeditor/ckeditor5-core/issues/73#issuecomment-311572827.
 		it( 'is false when selection contains object with nested editable', () => {
 		it( 'is false when selection contains object with nested editable', () => {
-			doc.schema.registerItem( 'caption', '$block' );
-			doc.schema.allow( { name: '$inline', inside: 'caption' } );
-			doc.schema.allow( { name: 'caption', inside: 'img' } );
-			doc.schema.allow( { name: '$text', attributes: 'bold', inside: 'caption' } );
+			model.schema.register( 'caption', {
+				allowContentOf: '$block',
+				allowIn: 'img',
+				isLimit: true
+			} );
+			model.schema.extend( '$text', {
+				allowIn: 'caption',
+				allowAttributes: 'bold'
+			} );
 
 
-			setData( doc, '<p>[<img><caption>Some caption inside the image.</caption></img>]</p>' );
+			setData( model, '<p>[<img><caption>Some caption inside the image.</caption></img>]</p>' );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 			command.execute();
 			command.execute();
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 
 
-			expect( getData( doc ) ).to.equal(
+			expect( getData( model ) ).to.equal(
 				'<p>[<img><caption><$text bold="true">Some caption inside the image.</$text></caption></img>]</p>'
 				'<p>[<img><caption><$text bold="true">Some caption inside the image.</$text></caption></img>]</p>'
 			);
 			);
 		} );
 		} );
@@ -91,30 +98,29 @@ describe( 'AttributeCommand', () => {
 		// Method `refresh()` uses `checkAttributeInSelection()` which is fully tested in its own test.
 		// Method `refresh()` uses `checkAttributeInSelection()` which is fully tested in its own test.
 
 
 		beforeEach( () => {
 		beforeEach( () => {
-			doc.schema.registerItem( 'x', '$block' );
-			doc.schema.disallow( { name: '$text', inside: 'x', attributes: 'link' } );
+			model.schema.register( 'x', { inheritAllFrom: '$block' } );
 		} );
 		} );
 
 
 		describe( 'when selection is collapsed', () => {
 		describe( 'when selection is collapsed', () => {
 			it( 'should return true if characters with the attribute can be placed at caret position', () => {
 			it( 'should return true if characters with the attribute can be placed at caret position', () => {
-				setData( doc, '<p>f[]oo</p>' );
+				setData( model, '<p>f[]oo</p>' );
 				expect( command.isEnabled ).to.be.true;
 				expect( command.isEnabled ).to.be.true;
 			} );
 			} );
 
 
 			it( 'should return false if characters with the attribute cannot be placed at caret position', () => {
 			it( 'should return false if characters with the attribute cannot be placed at caret position', () => {
-				setData( doc, '<x>fo[]o</x>' );
+				setData( model, '<x>fo[]o</x>' );
 				expect( command.isEnabled ).to.be.false;
 				expect( command.isEnabled ).to.be.false;
 			} );
 			} );
 		} );
 		} );
 
 
 		describe( 'when selection is not collapsed', () => {
 		describe( 'when selection is not collapsed', () => {
 			it( 'should return true if there is at least one node in selection that can have the attribute', () => {
 			it( 'should return true if there is at least one node in selection that can have the attribute', () => {
-				setData( doc, '<p>[foo]</p>' );
+				setData( model, '<p>[foo]</p>' );
 				expect( command.isEnabled ).to.be.true;
 				expect( command.isEnabled ).to.be.true;
 			} );
 			} );
 
 
 			it( 'should return false if there are no nodes in selection that can have the attribute', () => {
 			it( 'should return false if there are no nodes in selection that can have the attribute', () => {
-				setData( doc, '<x>[foo]</x>' );
+				setData( model, '<x>[foo]</x>' );
 				expect( command.isEnabled ).to.be.false;
 				expect( command.isEnabled ).to.be.false;
 			} );
 			} );
 		} );
 		} );
@@ -122,59 +128,59 @@ describe( 'AttributeCommand', () => {
 
 
 	describe( 'execute()', () => {
 	describe( 'execute()', () => {
 		it( 'should do nothing if the command is disabled', () => {
 		it( 'should do nothing if the command is disabled', () => {
-			setData( doc, '<p>fo[ob]ar</p>' );
+			setData( model, '<p>fo[ob]ar</p>' );
 
 
 			command.isEnabled = false;
 			command.isEnabled = false;
 
 
 			command.execute();
 			command.execute();
 
 
-			expect( getData( doc ) ).to.equal( '<p>fo[ob]ar</p>' );
+			expect( getData( model ) ).to.equal( '<p>fo[ob]ar</p>' );
 		} );
 		} );
 
 
 		it( 'should add attribute on selected nodes if the command value was false', () => {
 		it( 'should add attribute on selected nodes if the command value was false', () => {
-			setData( doc, '<p>a[bc<$text bold="true">fo]obar</$text>xyz</p>' );
+			setData( model, '<p>a[bc<$text bold="true">fo]obar</$text>xyz</p>' );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 
 
 			command.execute();
 			command.execute();
 
 
 			expect( command.value ).to.be.true;
 			expect( command.value ).to.be.true;
-			expect( getData( doc ) ).to.equal( '<p>a[<$text bold="true">bcfo]obar</$text>xyz</p>' );
+			expect( getData( model ) ).to.equal( '<p>a[<$text bold="true">bcfo]obar</$text>xyz</p>' );
 		} );
 		} );
 
 
 		it( 'should remove attribute from selected nodes if the command value was true', () => {
 		it( 'should remove attribute from selected nodes if the command value was true', () => {
-			setData( doc, '<p>abc[<$text bold="true">foo]bar</$text>xyz</p>' );
+			setData( model, '<p>abc[<$text bold="true">foo]bar</$text>xyz</p>' );
 
 
 			expect( command.value ).to.be.true;
 			expect( command.value ).to.be.true;
 
 
 			command.execute();
 			command.execute();
 
 
-			expect( getData( doc ) ).to.equal( '<p>abc[foo]<$text bold="true">bar</$text>xyz</p>' );
+			expect( getData( model ) ).to.equal( '<p>abc[foo]<$text bold="true">bar</$text>xyz</p>' );
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 		} );
 		} );
 
 
 		it( 'should add attribute on selected nodes if execute parameter was set to true', () => {
 		it( 'should add attribute on selected nodes if execute parameter was set to true', () => {
-			setData( doc, '<p>abc<$text bold="true">foob[ar</$text>x]yz</p>' );
+			setData( model, '<p>abc<$text bold="true">foob[ar</$text>x]yz</p>' );
 
 
 			expect( command.value ).to.be.true;
 			expect( command.value ).to.be.true;
 
 
 			command.execute( { forceValue: true } );
 			command.execute( { forceValue: true } );
 
 
 			expect( command.value ).to.be.true;
 			expect( command.value ).to.be.true;
-			expect( getData( doc ) ).to.equal( '<p>abc<$text bold="true">foob[arx</$text>]yz</p>' );
+			expect( getData( model ) ).to.equal( '<p>abc<$text bold="true">foob[arx</$text>]yz</p>' );
 		} );
 		} );
 
 
 		it( 'should remove attribute on selected nodes if execute parameter was set to false', () => {
 		it( 'should remove attribute on selected nodes if execute parameter was set to false', () => {
-			setData( doc, '<p>a[bc<$text bold="true">fo]obar</$text>xyz</p>' );
+			setData( model, '<p>a[bc<$text bold="true">fo]obar</$text>xyz</p>' );
 
 
 			command.execute( { forceValue: false } );
 			command.execute( { forceValue: false } );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
-			expect( getData( doc ) ).to.equal( '<p>a[bcfo]<$text bold="true">obar</$text>xyz</p>' );
+			expect( getData( model ) ).to.equal( '<p>a[bcfo]<$text bold="true">obar</$text>xyz</p>' );
 		} );
 		} );
 
 
 		it( 'should change selection attribute if selection is collapsed in non-empty parent', () => {
 		it( 'should change selection attribute if selection is collapsed in non-empty parent', () => {
-			setData( doc, '<p>a[]bc<$text bold="true">foobar</$text>xyz</p><p></p>' );
+			setData( model, '<p>a[]bc<$text bold="true">foobar</$text>xyz</p><p></p>' );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 
 
@@ -190,25 +196,25 @@ describe( 'AttributeCommand', () => {
 		} );
 		} );
 
 
 		it( 'should not store attribute change on selection if selection is collapsed in non-empty parent', () => {
 		it( 'should not store attribute change on selection if selection is collapsed in non-empty parent', () => {
-			setData( doc, '<p>a[]bc<$text bold="true">foobar</$text>xyz</p>' );
+			setData( model, '<p>a[]bc<$text bold="true">foobar</$text>xyz</p>' );
 
 
 			command.execute();
 			command.execute();
 
 
 			// It should not save that bold was executed at position ( root, [ 0, 1 ] ).
 			// It should not save that bold was executed at position ( root, [ 0, 1 ] ).
 
 
-			doc.enqueueChanges( () => {
+			model.change( writer => {
 				// Simulate clicking right arrow key by changing selection ranges.
 				// Simulate clicking right arrow key by changing selection ranges.
-				doc.selection.setRanges( [ new Range( new Position( root, [ 0, 2 ] ), new Position( root, [ 0, 2 ] ) ) ] );
+				writer.setSelection( new Range( new Position( root, [ 0, 2 ] ), new Position( root, [ 0, 2 ] ) ) );
 
 
 				// Get back to previous selection.
 				// Get back to previous selection.
-				doc.selection.setRanges( [ new Range( new Position( root, [ 0, 1 ] ), new Position( root, [ 0, 1 ] ) ) ] );
+				writer.setSelection( new Range( new Position( root, [ 0, 1 ] ), new Position( root, [ 0, 1 ] ) ) );
 			} );
 			} );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 		} );
 		} );
 
 
 		it( 'should change selection attribute and store it if selection is collapsed in empty parent', () => {
 		it( 'should change selection attribute and store it if selection is collapsed in empty parent', () => {
-			setData( doc, '<p>abc<$text bold="true">foobar</$text>xyz</p><p>[]</p>' );
+			setData( model, '<p>abc<$text bold="true">foobar</$text>xyz</p><p>[]</p>' );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 
 
@@ -219,15 +225,15 @@ describe( 'AttributeCommand', () => {
 
 
 			// Attribute should be stored.
 			// Attribute should be stored.
 			// Simulate clicking somewhere else in the editor.
 			// Simulate clicking somewhere else in the editor.
-			doc.enqueueChanges( () => {
-				doc.selection.setRanges( [ new Range( new Position( root, [ 0, 2 ] ), new Position( root, [ 0, 2 ] ) ) ] );
+			model.change( writer => {
+				writer.setSelection( [ new Range( new Position( root, [ 0, 2 ] ), new Position( root, [ 0, 2 ] ) ) ] );
 			} );
 			} );
 
 
 			expect( command.value ).to.be.false;
 			expect( command.value ).to.be.false;
 
 
 			// Go back to where attribute was stored.
 			// Go back to where attribute was stored.
-			doc.enqueueChanges( () => {
-				doc.selection.setRanges( [ new Range( new Position( root, [ 1, 0 ] ), new Position( root, [ 1, 0 ] ) ) ] );
+			model.change( writer => {
+				writer.setSelection( new Range( new Position( root, [ 1, 0 ] ), new Position( root, [ 1, 0 ] ) ) );
 			} );
 			} );
 
 
 			// Attribute should be restored.
 			// Attribute should be restored.
@@ -240,30 +246,30 @@ describe( 'AttributeCommand', () => {
 		} );
 		} );
 
 
 		it( 'should not apply attribute change where it would invalid schema', () => {
 		it( 'should not apply attribute change where it would invalid schema', () => {
-			doc.schema.registerItem( 'image', '$block' );
-			setData( doc, '<p>ab[c<img></img><$text bold="true">foobar</$text>xy<img></img>]z</p>' );
+			model.schema.register( 'image', { inheritAllFrom: '$block' } );
+			setData( model, '<p>ab[c<img></img><$text bold="true">foobar</$text>xy<img></img>]z</p>' );
 
 
 			expect( command.isEnabled ).to.be.true;
 			expect( command.isEnabled ).to.be.true;
 
 
 			command.execute();
 			command.execute();
 
 
-			expect( getData( doc ) )
+			expect( getData( model ) )
 				.to.equal( '<p>ab[<$text bold="true">c</$text><img></img><$text bold="true">foobarxy</$text><img></img>]z</p>' );
 				.to.equal( '<p>ab[<$text bold="true">c</$text><img></img><$text bold="true">foobarxy</$text><img></img>]z</p>' );
 		} );
 		} );
 
 
-		it( 'should use provided batch for storing undo steps', () => {
-			const batch = new Batch( new Document() );
-			setData( doc, '<p>a[bc<$text bold="true">fo]obar</$text>xyz</p>' );
-
-			expect( batch.deltas.length ).to.equal( 0 );
+		it( 'should use parent batch for storing undo steps', () => {
+			setData( model, '<p>a[bc<$text bold="true">fo]obar</$text>xyz</p>' );
 
 
-			command.execute( { batch } );
+			model.change( writer => {
+				expect( writer.batch.deltas.length ).to.equal( 0 );
+				command.execute();
+				expect( writer.batch.deltas.length ).to.equal( 1 );
+			} );
 
 
-			expect( batch.deltas.length ).to.equal( 1 );
-			expect( getData( doc ) ).to.equal( '<p>a[<$text bold="true">bcfo]obar</$text>xyz</p>' );
+			expect( getData( model ) ).to.equal( '<p>a[<$text bold="true">bcfo]obar</$text>xyz</p>' );
 		} );
 		} );
 
 
-		describe( 'should cause firing model document changesDone event', () => {
+		describe( 'should cause firing model change event', () => {
 			let spy;
 			let spy;
 
 
 			beforeEach( () => {
 			beforeEach( () => {
@@ -271,33 +277,33 @@ describe( 'AttributeCommand', () => {
 			} );
 			} );
 
 
 			it( 'collapsed selection in non-empty parent', () => {
 			it( 'collapsed selection in non-empty parent', () => {
-				setData( doc, '<p>x[]y</p>' );
+				setData( model, '<p>x[]y</p>' );
 
 
-				doc.on( 'changesDone', spy );
+				model.document.on( 'change', spy );
 
 
 				command.execute();
 				command.execute();
 
 
-				expect( spy.calledOnce ).to.be.true;
+				expect( spy.called ).to.be.true;
 			} );
 			} );
 
 
 			it( 'non-collapsed selection', () => {
 			it( 'non-collapsed selection', () => {
-				setData( doc, '<p>[xy]</p>' );
+				setData( model, '<p>[xy]</p>' );
 
 
-				doc.on( 'changesDone', spy );
+				model.document.on( 'change', spy );
 
 
 				command.execute();
 				command.execute();
 
 
-				expect( spy.calledOnce ).to.be.true;
+				expect( spy.called ).to.be.true;
 			} );
 			} );
 
 
 			it( 'in empty parent', () => {
 			it( 'in empty parent', () => {
-				setData( doc, '<p>[]</p>' );
+				setData( model, '<p>[]</p>' );
 
 
-				doc.on( 'changesDone', spy );
+				model.document.on( 'change', spy );
 
 
 				command.execute();
 				command.execute();
 
 
-				expect( spy.calledOnce ).to.be.true;
+				expect( spy.called ).to.be.true;
 			} );
 			} );
 		} );
 		} );
 	} );
 	} );

+ 7 - 86
packages/ckeditor5-basic-styles/tests/bold.js

@@ -1,97 +1,18 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-/* globals document */
-
-import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
 import Bold from '../src/bold';
 import Bold from '../src/bold';
-import BoldEngine from '../src/boldengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
-import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
-
-testUtils.createSinonSandbox();
+import BoldEditing from '../src/bold/boldediting';
+import BoldUI from '../src/bold/boldui';
 
 
 describe( 'Bold', () => {
 describe( 'Bold', () => {
-	let editor, boldView;
-
-	beforeEach( () => {
-		const editorElement = document.createElement( 'div' );
-		document.body.appendChild( editorElement );
-
-		return ClassicTestEditor
-			.create( editorElement, {
-				plugins: [ Bold ]
-			} )
-			.then( newEditor => {
-				editor = newEditor;
-
-				boldView = editor.ui.componentFactory.create( 'bold' );
-			} );
-	} );
-
-	afterEach( () => {
-		return editor.destroy();
+	it( 'should require BoldEditing and BoldUI', () => {
+		expect( Bold.requires ).to.deep.equal( [ BoldEditing, BoldUI ] );
 	} );
 	} );
 
 
-	it( 'should be loaded', () => {
-		expect( editor.plugins.get( Bold ) ).to.be.instanceOf( Bold );
-	} );
-
-	it( 'should load BoldEngine', () => {
-		expect( editor.plugins.get( BoldEngine ) ).to.be.instanceOf( BoldEngine );
-	} );
-
-	it( 'should register bold feature component', () => {
-		expect( boldView ).to.be.instanceOf( ButtonView );
-		expect( boldView.isOn ).to.be.false;
-		expect( boldView.label ).to.equal( 'Bold' );
-		expect( boldView.icon ).to.match( /<svg / );
-		expect( boldView.keystroke ).to.equal( 'CTRL+B' );
-	} );
-
-	it( 'should execute bold command on model execute event', () => {
-		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
-
-		boldView.fire( 'execute' );
-
-		sinon.assert.calledOnce( executeSpy );
-		sinon.assert.calledWithExactly( executeSpy, 'bold' );
-	} );
-
-	it( 'should bind model to bold command', () => {
-		const command = editor.commands.get( 'bold' );
-
-		expect( boldView.isOn ).to.be.false;
-
-		expect( boldView.isEnabled ).to.be.false;
-
-		command.value = true;
-		expect( boldView.isOn ).to.be.true;
-
-		command.isEnabled = true;
-		expect( boldView.isEnabled ).to.be.true;
-	} );
-
-	it( 'should set keystroke in the model', () => {
-		expect( boldView.keystroke ).to.equal( 'CTRL+B' );
-	} );
-
-	it( 'should set editor keystroke', () => {
-		const spy = sinon.spy( editor, 'execute' );
-		const keyEventData = {
-			keyCode: keyCodes.b,
-			ctrlKey: true,
-			preventDefault: sinon.spy(),
-			stopPropagation: sinon.spy()
-		};
-
-		const wasHandled = editor.keystrokes.press( keyEventData );
-
-		expect( wasHandled ).to.be.true;
-		expect( spy.calledOnce ).to.be.true;
-		expect( keyEventData.preventDefault.calledOnce ).to.be.true;
+	it( 'should be named', () => {
+		expect( Bold.pluginName ).to.equal( 'Bold' );
 	} );
 	} );
 } );
 } );

+ 34 - 21
packages/ckeditor5-basic-styles/tests/boldengine.js → packages/ckeditor5-basic-styles/tests/bold/boldediting.js

@@ -1,29 +1,29 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-import BoldEngine from '../src/boldengine';
+import BoldEditing from '../../src/bold/boldediting';
 
 
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
-import AttributeCommand from '../src/attributecommand';
+import AttributeCommand from '../../src/attributecommand';
 
 
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
+import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
 
 
-describe( 'BoldEngine', () => {
-	let editor, doc;
+describe( 'BoldEditing', () => {
+	let editor, model;
 
 
 	beforeEach( () => {
 	beforeEach( () => {
 		return VirtualTestEditor
 		return VirtualTestEditor
 			.create( {
 			.create( {
-				plugins: [ Paragraph, BoldEngine ]
+				plugins: [ Paragraph, BoldEditing ]
 			} )
 			} )
 			.then( newEditor => {
 			.then( newEditor => {
 				editor = newEditor;
 				editor = newEditor;
-
-				doc = editor.document;
+				model = editor.model;
 			} );
 			} );
 	} );
 	} );
 
 
@@ -32,13 +32,28 @@ describe( 'BoldEngine', () => {
 	} );
 	} );
 
 
 	it( 'should be loaded', () => {
 	it( 'should be loaded', () => {
-		expect( editor.plugins.get( BoldEngine ) ).to.be.instanceOf( BoldEngine );
+		expect( editor.plugins.get( BoldEditing ) ).to.be.instanceOf( BoldEditing );
 	} );
 	} );
 
 
 	it( 'should set proper schema rules', () => {
 	it( 'should set proper schema rules', () => {
-		expect( doc.schema.check( { name: '$inline', attributes: 'bold', inside: '$root' } ) ).to.be.false;
-		expect( doc.schema.check( { name: '$inline', attributes: 'bold', inside: '$block' } ) ).to.be.true;
-		expect( doc.schema.check( { name: '$inline', attributes: 'bold', inside: '$clipboardHolder' } ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$root', '$block', '$text' ], 'bold' ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$clipboardHolder', '$text' ], 'bold' ) ).to.be.true;
+	} );
+
+	it( 'should set editor keystroke', () => {
+		const spy = sinon.spy( editor, 'execute' );
+		const keyEventData = {
+			keyCode: keyCodes.b,
+			ctrlKey: true,
+			preventDefault: sinon.spy(),
+			stopPropagation: sinon.spy()
+		};
+
+		const wasHandled = editor.keystrokes.press( keyEventData );
+
+		expect( wasHandled ).to.be.true;
+		expect( spy.calledOnce ).to.be.true;
+		expect( keyEventData.preventDefault.calledOnce ).to.be.true;
 	} );
 	} );
 
 
 	describe( 'command', () => {
 	describe( 'command', () => {
@@ -54,7 +69,7 @@ describe( 'BoldEngine', () => {
 		it( 'should convert <strong> to bold attribute', () => {
 		it( 'should convert <strong> to bold attribute', () => {
 			editor.setData( '<p><strong>foo</strong>bar</p>' );
 			editor.setData( '<p><strong>foo</strong>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><strong>foo</strong>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><strong>foo</strong>bar</p>' );
@@ -63,7 +78,7 @@ describe( 'BoldEngine', () => {
 		it( 'should convert <b> to bold attribute', () => {
 		it( 'should convert <b> to bold attribute', () => {
 			editor.setData( '<p><b>foo</b>bar</p>' );
 			editor.setData( '<p><b>foo</b>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><strong>foo</strong>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><strong>foo</strong>bar</p>' );
@@ -72,27 +87,25 @@ describe( 'BoldEngine', () => {
 		it( 'should convert font-weight:bold to bold attribute', () => {
 		it( 'should convert font-weight:bold to bold attribute', () => {
 			editor.setData( '<p><span style="font-weight: bold;">foo</span>bar</p>' );
 			editor.setData( '<p><span style="font-weight: bold;">foo</span>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><strong>foo</strong>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><strong>foo</strong>bar</p>' );
 		} );
 		} );
 
 
 		it( 'should be integrated with autoparagraphing', () => {
 		it( 'should be integrated with autoparagraphing', () => {
-			// Incorrect results because autoparagraphing works incorrectly (issue in paragraph).
-			// https://github.com/ckeditor/ckeditor5-paragraph/issues/10
-
 			editor.setData( '<strong>foo</strong>bar' );
 			editor.setData( '<strong>foo</strong>bar' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) ).to.equal( '<paragraph>foobar</paragraph>' );
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 
 
-			expect( editor.getData() ).to.equal( '<p>foobar</p>' );
+			expect( editor.getData() ).to.equal( '<p><strong>foo</strong>bar</p>' );
 		} );
 		} );
 	} );
 	} );
 
 
 	describe( 'editing pipeline conversion', () => {
 	describe( 'editing pipeline conversion', () => {
 		it( 'should convert attribute', () => {
 		it( 'should convert attribute', () => {
-			setModelData( doc, '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
+			setModelData( model, '<paragraph><$text bold="true">foo</$text>bar</paragraph>' );
 
 
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><strong>foo</strong>bar</p>' );
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><strong>foo</strong>bar</p>' );
 		} );
 		} );

+ 73 - 0
packages/ckeditor5-basic-styles/tests/bold/boldui.js

@@ -0,0 +1,73 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/* globals document */
+
+import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
+import BoldEditing from '../../src/bold/boldediting';
+import BoldUI from '../../src/bold/boldui';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
+
+import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
+
+testUtils.createSinonSandbox();
+
+describe( 'BoldUI', () => {
+	let editor, boldView;
+
+	beforeEach( () => {
+		const editorElement = document.createElement( 'div' );
+		document.body.appendChild( editorElement );
+
+		return ClassicTestEditor
+			.create( editorElement, {
+				plugins: [ Paragraph, BoldEditing, BoldUI ]
+			} )
+			.then( newEditor => {
+				editor = newEditor;
+
+				boldView = editor.ui.componentFactory.create( 'bold' );
+			} );
+	} );
+
+	afterEach( () => {
+		return editor.destroy();
+	} );
+
+	it( 'should register bold feature component', () => {
+		expect( boldView ).to.be.instanceOf( ButtonView );
+		expect( boldView.isOn ).to.be.false;
+		expect( boldView.label ).to.equal( 'Bold' );
+		expect( boldView.icon ).to.match( /<svg / );
+		expect( boldView.keystroke ).to.equal( 'CTRL+B' );
+	} );
+
+	it( 'should execute bold command on model execute event', () => {
+		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
+
+		boldView.fire( 'execute' );
+
+		sinon.assert.calledOnce( executeSpy );
+		sinon.assert.calledWithExactly( executeSpy, 'bold' );
+	} );
+
+	it( 'should bind model to bold command', () => {
+		const command = editor.commands.get( 'bold' );
+
+		expect( boldView.isOn ).to.be.false;
+		expect( boldView.isEnabled ).to.be.true;
+
+		command.value = true;
+		expect( boldView.isOn ).to.be.true;
+
+		command.isEnabled = false;
+		expect( boldView.isEnabled ).to.be.false;
+	} );
+
+	it( 'should set keystroke in the model', () => {
+		expect( boldView.keystroke ).to.equal( 'CTRL+B' );
+	} );
+} );

+ 7 - 64
packages/ckeditor5-basic-styles/tests/code.js

@@ -1,75 +1,18 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-/* globals document */
-
-import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
 import Code from '../src/code';
 import Code from '../src/code';
-import CodeEngine from '../src/codeengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
-
-testUtils.createSinonSandbox();
+import CodeEditing from '../src/code/codeediting';
+import CodeUI from '../src/code/codeui';
 
 
 describe( 'Code', () => {
 describe( 'Code', () => {
-	let editor, codeView;
-
-	beforeEach( () => {
-		const editorElement = document.createElement( 'div' );
-		document.body.appendChild( editorElement );
-
-		return ClassicTestEditor
-			.create( editorElement, {
-				plugins: [ Code ]
-			} )
-			.then( newEditor => {
-				editor = newEditor;
-
-				codeView = editor.ui.componentFactory.create( 'code' );
-			} );
-	} );
-
-	afterEach( () => {
-		return editor.destroy();
-	} );
-
-	it( 'should be loaded', () => {
-		expect( editor.plugins.get( Code ) ).to.be.instanceOf( Code );
-	} );
-
-	it( 'should load CodeEngine', () => {
-		expect( editor.plugins.get( CodeEngine ) ).to.be.instanceOf( CodeEngine );
+	it( 'should require CodeEditing and CodeUI', () => {
+		expect( Code.requires ).to.deep.equal( [ CodeEditing, CodeUI ] );
 	} );
 	} );
 
 
-	it( 'should register code feature component', () => {
-		expect( codeView ).to.be.instanceOf( ButtonView );
-		expect( codeView.isOn ).to.be.false;
-		expect( codeView.label ).to.equal( 'Code' );
-		expect( codeView.icon ).to.match( /<svg / );
-	} );
-
-	it( 'should execute code command on model execute event', () => {
-		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
-
-		codeView.fire( 'execute' );
-
-		sinon.assert.calledOnce( executeSpy );
-		sinon.assert.calledWithExactly( executeSpy, 'code' );
-	} );
-
-	it( 'should bind model to code command', () => {
-		const command = editor.commands.get( 'code' );
-
-		expect( codeView.isOn ).to.be.false;
-
-		expect( codeView.isEnabled ).to.be.false;
-
-		command.value = true;
-		expect( codeView.isOn ).to.be.true;
-
-		command.isEnabled = true;
-		expect( codeView.isEnabled ).to.be.true;
+	it( 'should be named', () => {
+		expect( Code.pluginName ).to.equal( 'Code' );
 	} );
 	} );
 } );
 } );

+ 16 - 20
packages/ckeditor5-basic-styles/tests/codeengine.js → packages/ckeditor5-basic-styles/tests/code/codeediting.js

@@ -1,29 +1,28 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-import CodeEngine from '../src/codeengine';
+import CodeEditing from '../../src/code/codeediting';
 
 
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
-import AttributeCommand from '../src/attributecommand';
+import AttributeCommand from '../../src/attributecommand';
 
 
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
 
 
-describe( 'CodeEngine', () => {
-	let editor, doc;
+describe( 'CodeEditing', () => {
+	let editor, model;
 
 
 	beforeEach( () => {
 	beforeEach( () => {
 		return VirtualTestEditor
 		return VirtualTestEditor
 			.create( {
 			.create( {
-				plugins: [ Paragraph, CodeEngine ]
+				plugins: [ Paragraph, CodeEditing ]
 			} )
 			} )
 			.then( newEditor => {
 			.then( newEditor => {
 				editor = newEditor;
 				editor = newEditor;
-
-				doc = editor.document;
+				model = editor.model;
 			} );
 			} );
 	} );
 	} );
 
 
@@ -32,13 +31,12 @@ describe( 'CodeEngine', () => {
 	} );
 	} );
 
 
 	it( 'should be loaded', () => {
 	it( 'should be loaded', () => {
-		expect( editor.plugins.get( CodeEngine ) ).to.be.instanceOf( CodeEngine );
+		expect( editor.plugins.get( CodeEditing ) ).to.be.instanceOf( CodeEditing );
 	} );
 	} );
 
 
 	it( 'should set proper schema rules', () => {
 	it( 'should set proper schema rules', () => {
-		expect( doc.schema.check( { name: '$inline', attributes: 'code', inside: '$root' } ) ).to.be.false;
-		expect( doc.schema.check( { name: '$inline', attributes: 'code', inside: '$block' } ) ).to.be.true;
-		expect( doc.schema.check( { name: '$inline', attributes: 'code', inside: '$clipboardHolder' } ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$root', '$block', '$text' ], 'code' ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$clipboardHolder', '$text' ], 'code' ) ).to.be.true;
 	} );
 	} );
 
 
 	describe( 'command', () => {
 	describe( 'command', () => {
@@ -54,7 +52,7 @@ describe( 'CodeEngine', () => {
 		it( 'should convert <code> to code attribute', () => {
 		it( 'should convert <code> to code attribute', () => {
 			editor.setData( '<p><code>foo</code>bar</p>' );
 			editor.setData( '<p><code>foo</code>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text code="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text code="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><code>foo</code>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><code>foo</code>bar</p>' );
@@ -63,27 +61,25 @@ describe( 'CodeEngine', () => {
 		it( 'should convert word-wrap:break-word to code attribute', () => {
 		it( 'should convert word-wrap:break-word to code attribute', () => {
 			editor.setData( '<p><span style="word-wrap: break-word">foo</span>bar</p>' );
 			editor.setData( '<p><span style="word-wrap: break-word">foo</span>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text code="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text code="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><code>foo</code>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><code>foo</code>bar</p>' );
 		} );
 		} );
 
 
 		it( 'should be integrated with autoparagraphing', () => {
 		it( 'should be integrated with autoparagraphing', () => {
-			// Incorrect results because autoparagraphing works incorrectly (issue in paragraph).
-			// https://github.com/ckeditor/ckeditor5-paragraph/issues/10
-
 			editor.setData( '<code>foo</code>bar' );
 			editor.setData( '<code>foo</code>bar' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) ).to.equal( '<paragraph>foobar</paragraph>' );
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text code="true">foo</$text>bar</paragraph>' );
 
 
-			expect( editor.getData() ).to.equal( '<p>foobar</p>' );
+			expect( editor.getData() ).to.equal( '<p><code>foo</code>bar</p>' );
 		} );
 		} );
 	} );
 	} );
 
 
 	describe( 'editing pipeline conversion', () => {
 	describe( 'editing pipeline conversion', () => {
 		it( 'should convert attribute', () => {
 		it( 'should convert attribute', () => {
-			setModelData( doc, '<paragraph><$text code="true">foo</$text>bar</paragraph>' );
+			setModelData( model, '<paragraph><$text code="true">foo</$text>bar</paragraph>' );
 
 
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><code>foo</code>bar</p>' );
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><code>foo</code>bar</p>' );
 		} );
 		} );

+ 68 - 0
packages/ckeditor5-basic-styles/tests/code/codeui.js

@@ -0,0 +1,68 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/* globals document */
+
+import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
+import CodeEditing from '../../src/code/codeediting';
+import CodeUI from '../../src/code/codeui';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
+
+import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
+
+testUtils.createSinonSandbox();
+
+describe( 'CodeUI', () => {
+	let editor, codeView;
+
+	beforeEach( () => {
+		const editorElement = document.createElement( 'div' );
+		document.body.appendChild( editorElement );
+
+		return ClassicTestEditor
+			.create( editorElement, {
+				plugins: [ Paragraph, CodeEditing, CodeUI ]
+			} )
+			.then( newEditor => {
+				editor = newEditor;
+
+				codeView = editor.ui.componentFactory.create( 'code' );
+			} );
+	} );
+
+	afterEach( () => {
+		return editor.destroy();
+	} );
+
+	it( 'should register code feature component', () => {
+		expect( codeView ).to.be.instanceOf( ButtonView );
+		expect( codeView.isOn ).to.be.false;
+		expect( codeView.label ).to.equal( 'Code' );
+		expect( codeView.icon ).to.match( /<svg / );
+	} );
+
+	it( 'should execute code command on model execute event', () => {
+		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
+
+		codeView.fire( 'execute' );
+
+		sinon.assert.calledOnce( executeSpy );
+		sinon.assert.calledWithExactly( executeSpy, 'code' );
+	} );
+
+	it( 'should bind model to code command', () => {
+		const command = editor.commands.get( 'code' );
+
+		expect( codeView.isOn ).to.be.false;
+		expect( codeView.isEnabled ).to.be.true;
+
+		command.value = true;
+		expect( codeView.isOn ).to.be.true;
+
+		command.isEnabled = false;
+		expect( codeView.isEnabled ).to.be.false;
+	} );
+} );

+ 7 - 84
packages/ckeditor5-basic-styles/tests/italic.js

@@ -1,95 +1,18 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-/* globals document */
-
-import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
 import Italic from '../src/italic';
 import Italic from '../src/italic';
-import ItalicEngine from '../src/italicengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
-import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
-
-testUtils.createSinonSandbox();
+import ItalicEditing from '../src/italic/italicediting';
+import ItalicUI from '../src/italic/italicui';
 
 
 describe( 'Italic', () => {
 describe( 'Italic', () => {
-	let editor, italicView;
-
-	beforeEach( () => {
-		const editorElement = document.createElement( 'div' );
-		document.body.appendChild( editorElement );
-
-		return ClassicTestEditor
-			.create( editorElement, {
-				plugins: [ Italic ]
-			} )
-			.then( newEditor => {
-				editor = newEditor;
-
-				italicView = editor.ui.componentFactory.create( 'italic' );
-			} );
-	} );
-
-	afterEach( () => {
-		return editor.destroy();
+	it( 'should require ItalicEditing and ItalicUI', () => {
+		expect( Italic.requires ).to.deep.equal( [ ItalicEditing, ItalicUI ] );
 	} );
 	} );
 
 
-	it( 'should be loaded', () => {
-		expect( editor.plugins.get( Italic ) ).to.be.instanceOf( Italic );
-	} );
-
-	it( 'should load ItalicEngine', () => {
-		expect( editor.plugins.get( ItalicEngine ) ).to.be.instanceOf( ItalicEngine );
-	} );
-
-	it( 'should register italic feature component', () => {
-		expect( italicView ).to.be.instanceOf( ButtonView );
-		expect( italicView.isOn ).to.be.false;
-		expect( italicView.label ).to.equal( 'Italic' );
-		expect( italicView.icon ).to.match( /<svg / );
-		expect( italicView.keystroke ).to.equal( 'CTRL+I' );
-	} );
-
-	it( 'should execute italic command on model execute event', () => {
-		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
-
-		italicView.fire( 'execute' );
-
-		sinon.assert.calledOnce( executeSpy );
-		sinon.assert.calledWithExactly( executeSpy, 'italic' );
-	} );
-
-	it( 'should bind model to italic command', () => {
-		const command = editor.commands.get( 'italic' );
-
-		expect( italicView.isOn ).to.be.false;
-
-		expect( italicView.isEnabled ).to.be.false;
-
-		command.value = true;
-		expect( italicView.isOn ).to.be.true;
-
-		command.isEnabled = true;
-		expect( italicView.isEnabled ).to.be.true;
-	} );
-
-	it( 'should set keystroke in the model', () => {
-		expect( italicView.keystroke ).to.equal( 'CTRL+I' );
-	} );
-
-	it( 'should set editor keystroke', () => {
-		const spy = sinon.spy( editor, 'execute' );
-
-		const wasHandled = editor.keystrokes.press( {
-			keyCode: keyCodes.i,
-			ctrlKey: true,
-			preventDefault: sinon.spy(),
-			stopPropagation: sinon.spy()
-		} );
-
-		expect( wasHandled ).to.be.true;
-		expect( spy.calledOnce ).to.be.true;
+	it( 'should be named', () => {
+		expect( Italic.pluginName ).to.equal( 'Italic' );
 	} );
 	} );
 } );
 } );

+ 18 - 22
packages/ckeditor5-basic-styles/tests/italicengine.js → packages/ckeditor5-basic-styles/tests/italic/italicediting.js

@@ -1,29 +1,28 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-import ItalicEngine from '../src/italicengine';
+import ItalicEditing from '../../src/italic/italicediting';
 
 
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
-import AttributeCommand from '../src/attributecommand';
+import AttributeCommand from '../../src/attributecommand';
 
 
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
 
 
-describe( 'ItalicEngine', () => {
-	let editor, doc;
+describe( 'ItalicEditing', () => {
+	let editor, model;
 
 
 	beforeEach( () => {
 	beforeEach( () => {
 		return VirtualTestEditor
 		return VirtualTestEditor
 			.create( {
 			.create( {
-				plugins: [ Paragraph, ItalicEngine ]
+				plugins: [ Paragraph, ItalicEditing ]
 			} )
 			} )
 			.then( newEditor => {
 			.then( newEditor => {
 				editor = newEditor;
 				editor = newEditor;
-
-				doc = editor.document;
+				model = editor.model;
 			} );
 			} );
 	} );
 	} );
 
 
@@ -32,13 +31,12 @@ describe( 'ItalicEngine', () => {
 	} );
 	} );
 
 
 	it( 'should be loaded', () => {
 	it( 'should be loaded', () => {
-		expect( editor.plugins.get( ItalicEngine ) ).to.be.instanceOf( ItalicEngine );
+		expect( editor.plugins.get( ItalicEditing ) ).to.be.instanceOf( ItalicEditing );
 	} );
 	} );
 
 
 	it( 'should set proper schema rules', () => {
 	it( 'should set proper schema rules', () => {
-		expect( doc.schema.check( { name: '$inline', attributes: 'italic', inside: '$root' } ) ).to.be.false;
-		expect( doc.schema.check( { name: '$inline', attributes: 'italic', inside: '$block' } ) ).to.be.true;
-		expect( doc.schema.check( { name: '$inline', attributes: 'italic', inside: '$clipboardHolder' } ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$root', '$block', '$text' ], 'italic' ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$clipboardHolder', '$text' ], 'italic' ) ).to.be.true;
 	} );
 	} );
 
 
 	describe( 'command', () => {
 	describe( 'command', () => {
@@ -54,7 +52,7 @@ describe( 'ItalicEngine', () => {
 		it( 'should convert <em> to italic attribute', () => {
 		it( 'should convert <em> to italic attribute', () => {
 			editor.setData( '<p><em>foo</em>bar</p>' );
 			editor.setData( '<p><em>foo</em>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><i>foo</i>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><i>foo</i>bar</p>' );
@@ -63,7 +61,7 @@ describe( 'ItalicEngine', () => {
 		it( 'should convert <i> to italic attribute', () => {
 		it( 'should convert <i> to italic attribute', () => {
 			editor.setData( '<p><i>foo</i>bar</p>' );
 			editor.setData( '<p><i>foo</i>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><i>foo</i>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><i>foo</i>bar</p>' );
@@ -72,27 +70,25 @@ describe( 'ItalicEngine', () => {
 		it( 'should convert font-weight:italic to italic attribute', () => {
 		it( 'should convert font-weight:italic to italic attribute', () => {
 			editor.setData( '<p><span style="font-style: italic;">foo</span>bar</p>' );
 			editor.setData( '<p><span style="font-style: italic;">foo</span>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><i>foo</i>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><i>foo</i>bar</p>' );
 		} );
 		} );
 
 
 		it( 'should be integrated with autoparagraphing', () => {
 		it( 'should be integrated with autoparagraphing', () => {
-			// Incorrect results because autoparagraphing works incorrectly (issue in paragraph).
-			// https://github.com/ckeditor/ckeditor5-paragraph/issues/10
-
-			editor.setData( '<em>foo</em>bar' );
+			editor.setData( '<i>foo</i>bar' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) ).to.equal( '<paragraph>foobar</paragraph>' );
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 
 
-			expect( editor.getData() ).to.equal( '<p>foobar</p>' );
+			expect( editor.getData() ).to.equal( '<p><i>foo</i>bar</p>' );
 		} );
 		} );
 	} );
 	} );
 
 
 	describe( 'editing pipeline conversion', () => {
 	describe( 'editing pipeline conversion', () => {
 		it( 'should convert attribute', () => {
 		it( 'should convert attribute', () => {
-			setModelData( doc, '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
+			setModelData( model, '<paragraph><$text italic="true">foo</$text>bar</paragraph>' );
 
 
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><i>foo</i>bar</p>' );
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><i>foo</i>bar</p>' );
 		} );
 		} );

+ 88 - 0
packages/ckeditor5-basic-styles/tests/italic/italicui.js

@@ -0,0 +1,88 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/* globals document */
+
+import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
+import ItalicEditing from '../../src/italic/italicediting';
+import ItalicUI from '../../src/italic/italicui';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
+import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
+
+import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
+
+testUtils.createSinonSandbox();
+
+describe( 'ItalicUI', () => {
+	let editor, italicView;
+
+	beforeEach( () => {
+		const editorElement = document.createElement( 'div' );
+		document.body.appendChild( editorElement );
+
+		return ClassicTestEditor
+			.create( editorElement, {
+				plugins: [ Paragraph, ItalicEditing, ItalicUI ]
+			} )
+			.then( newEditor => {
+				editor = newEditor;
+
+				italicView = editor.ui.componentFactory.create( 'italic' );
+			} );
+	} );
+
+	afterEach( () => {
+		return editor.destroy();
+	} );
+
+	it( 'should register italic feature component', () => {
+		expect( italicView ).to.be.instanceOf( ButtonView );
+		expect( italicView.isOn ).to.be.false;
+		expect( italicView.label ).to.equal( 'Italic' );
+		expect( italicView.icon ).to.match( /<svg / );
+		expect( italicView.keystroke ).to.equal( 'CTRL+I' );
+	} );
+
+	it( 'should execute italic command on model execute event', () => {
+		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
+
+		italicView.fire( 'execute' );
+
+		sinon.assert.calledOnce( executeSpy );
+		sinon.assert.calledWithExactly( executeSpy, 'italic' );
+	} );
+
+	it( 'should bind model to italic command', () => {
+		const command = editor.commands.get( 'italic' );
+
+		expect( italicView.isOn ).to.be.false;
+		expect( italicView.isEnabled ).to.be.true;
+
+		command.value = true;
+		expect( italicView.isOn ).to.be.true;
+
+		command.isEnabled = false;
+		expect( italicView.isEnabled ).to.be.false;
+	} );
+
+	it( 'should set keystroke in the model', () => {
+		expect( italicView.keystroke ).to.equal( 'CTRL+I' );
+	} );
+
+	it( 'should set editor keystroke', () => {
+		const spy = sinon.spy( editor, 'execute' );
+
+		const wasHandled = editor.keystrokes.press( {
+			keyCode: keyCodes.i,
+			ctrlKey: true,
+			preventDefault: sinon.spy(),
+			stopPropagation: sinon.spy()
+		} );
+
+		expect( wasHandled ).to.be.true;
+		expect( spy.calledOnce ).to.be.true;
+	} );
+} );

+ 1 - 1
packages/ckeditor5-basic-styles/tests/manual/basic-styles.html

@@ -1,3 +1,3 @@
 <div id="editor">
 <div id="editor">
-	<p><i>This</i> <code>is an</code> <strong>editor</strong> <u>instance</u>.</p>
+	<p><i>This</i> <s>is</s> <code>an</code> <strong>editor</strong> <u>instance</u>.</p>
 </div>
 </div>

+ 4 - 3
packages/ckeditor5-basic-styles/tests/manual/basic-styles.js

@@ -1,5 +1,5 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
@@ -10,13 +10,14 @@ import Essentials from '@ckeditor/ckeditor5-essentials/src/essentials';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
 import Bold from '../../src/bold';
 import Bold from '../../src/bold';
 import Italic from '../../src/italic';
 import Italic from '../../src/italic';
+import Strikethrough from '../../src/strikethrough';
 import Underline from '../../src/underline';
 import Underline from '../../src/underline';
 import Code from '../../src/code';
 import Code from '../../src/code';
 
 
 ClassicEditor
 ClassicEditor
 	.create( document.querySelector( '#editor' ), {
 	.create( document.querySelector( '#editor' ), {
-		plugins: [ Essentials, Paragraph, Bold, Italic, Underline, Code ],
-		toolbar: [ 'bold', 'italic', 'underline', 'code', 'undo', 'redo' ]
+		plugins: [ Essentials, Paragraph, Bold, Italic, Strikethrough, Underline, Code ],
+		toolbar: [ 'bold', 'italic', 'strikethrough', 'underline', 'code', 'undo', 'redo' ]
 	} )
 	} )
 	.then( editor => {
 	.then( editor => {
 		window.editor = editor;
 		window.editor = editor;

+ 5 - 4
packages/ckeditor5-basic-styles/tests/manual/basic-styles.md

@@ -1,8 +1,9 @@
 ## Basic styles
 ## Basic styles
 
 
 1. The data should be loaded with:
 1. The data should be loaded with:
-  * italic "This",
-  * bold "editor",
+  * italic _"This"_,
+  * bold **"editor"**,
   * underline "instance",
   * underline "instance",
-  * code "is an".
-2. Test the bold, italic, underline and code features live.
+  * strikethrough ~~"is"~~,
+  * code `"an"`.
+2. Test the bold, italic, strikethrough, underline and code features live.

+ 18 - 0
packages/ckeditor5-basic-styles/tests/strikethrough.js

@@ -0,0 +1,18 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+import Strikethrough from '../src/strikethrough';
+import StrikethroughEditing from '../src/strikethrough/strikethroughediting';
+import StrikethroughUI from '../src/strikethrough/strikethroughui';
+
+describe( 'Strikethrough', () => {
+	it( 'should require StrikethroughEditing and StrikethroughUI', () => {
+		expect( Strikethrough.requires ).to.deep.equal( [ StrikethroughEditing, StrikethroughUI ] );
+	} );
+
+	it( 'should be named', () => {
+		expect( Strikethrough.pluginName ).to.equal( 'Strikethrough' );
+	} );
+} );

+ 104 - 0
packages/ckeditor5-basic-styles/tests/strikethrough/strikethroughediting.js

@@ -0,0 +1,104 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+import StrikethroughEditing from '../../src/strikethrough/strikethroughediting';
+
+import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
+import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
+import AttributeCommand from '../../src/attributecommand';
+
+import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
+import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
+
+describe( 'StrikethroughEditing', () => {
+	let editor, model;
+
+	beforeEach( () => {
+		return VirtualTestEditor
+			.create( {
+				plugins: [ Paragraph, StrikethroughEditing ]
+			} )
+			.then( newEditor => {
+				editor = newEditor;
+				model = editor.model;
+			} );
+	} );
+
+	afterEach( () => {
+		return editor.destroy();
+	} );
+
+	it( 'should be loaded', () => {
+		expect( editor.plugins.get( StrikethroughEditing ) ).to.be.instanceOf( StrikethroughEditing );
+	} );
+
+	it( 'should set proper schema rules', () => {
+		expect( model.schema.checkAttribute( [ '$root', '$block', '$text' ], 'strikethrough' ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$clipboardHolder', '$text' ], 'strikethrough' ) ).to.be.true;
+	} );
+
+	describe( 'command', () => {
+		it( 'should register strikethrough command', () => {
+			const command = editor.commands.get( 'strikethrough' );
+
+			expect( command ).to.be.instanceOf( AttributeCommand );
+			expect( command ).to.have.property( 'attributeKey', 'strikethrough' );
+		} );
+	} );
+
+	describe( 'data pipeline conversions', () => {
+		it( 'should convert <strike> to strikethrough attribute', () => {
+			editor.setData( '<p><strike>foo</strike>bar</p>' );
+
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text strikethrough="true">foo</$text>bar</paragraph>' );
+
+			expect( editor.getData() ).to.equal( '<p><s>foo</s>bar</p>' );
+		} );
+		it( 'should convert <del> to strikethrough attribute', () => {
+			editor.setData( '<p><del>foo</del>bar</p>' );
+
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text strikethrough="true">foo</$text>bar</paragraph>' );
+
+			expect( editor.getData() ).to.equal( '<p><s>foo</s>bar</p>' );
+		} );
+
+		it( 'should convert <s> to strikethrough attribute', () => {
+			editor.setData( '<p><s>foo</s>bar</p>' );
+
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text strikethrough="true">foo</$text>bar</paragraph>' );
+
+			expect( editor.getData() ).to.equal( '<p><s>foo</s>bar</p>' );
+		} );
+
+		it( 'should convert text-decoration:line-through to strikethrough attribute', () => {
+			editor.setData( '<p><span style="text-decoration: line-through;">foo</span>bar</p>' );
+
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text strikethrough="true">foo</$text>bar</paragraph>' );
+
+			expect( editor.getData() ).to.equal( '<p><s>foo</s>bar</p>' );
+		} );
+
+		it( 'should be integrated with autoparagraphing', () => {
+			editor.setData( '<s>foo</s>bar' );
+
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text strikethrough="true">foo</$text>bar</paragraph>' );
+
+			expect( editor.getData() ).to.equal( '<p><s>foo</s>bar</p>' );
+		} );
+	} );
+
+	describe( 'editing pipeline conversion', () => {
+		it( 'should convert attribute', () => {
+			setModelData( model, '<paragraph><$text strikethrough="true">foo</$text>bar</paragraph>' );
+
+			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><s>foo</s>bar</p>' );
+		} );
+	} );
+} );

+ 91 - 0
packages/ckeditor5-basic-styles/tests/strikethrough/strikethroughui.js

@@ -0,0 +1,91 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/* globals document */
+
+import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
+import StrikethroughEditing from '../../src/strikethrough/strikethroughediting';
+import StrikethroughUI from '../../src/strikethrough/strikethroughui';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
+import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
+
+import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
+
+testUtils.createSinonSandbox();
+
+describe( 'StrikethroughUI', () => {
+	let editor, strikeView;
+
+	beforeEach( () => {
+		const editorElement = document.createElement( 'div' );
+		document.body.appendChild( editorElement );
+
+		return ClassicTestEditor
+			.create( editorElement, {
+				plugins: [ Paragraph, StrikethroughEditing, StrikethroughUI ]
+			} )
+			.then( newEditor => {
+				editor = newEditor;
+
+				strikeView = editor.ui.componentFactory.create( 'strikethrough' );
+			} );
+	} );
+
+	afterEach( () => {
+		return editor.destroy();
+	} );
+
+	it( 'should register strikethrough feature component', () => {
+		expect( strikeView ).to.be.instanceOf( ButtonView );
+		expect( strikeView.isOn ).to.be.false;
+		expect( strikeView.label ).to.equal( 'Strikethrough' );
+		expect( strikeView.icon ).to.match( /<svg / );
+		expect( strikeView.keystroke ).to.equal( 'CTRL+SHIFT+X' );
+	} );
+
+	it( 'should execute strikethrough command on model execute event', () => {
+		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
+
+		strikeView.fire( 'execute' );
+
+		sinon.assert.calledOnce( executeSpy );
+		sinon.assert.calledWithExactly( executeSpy, 'strikethrough' );
+	} );
+
+	it( 'should bind model to strikethrough command', () => {
+		const command = editor.commands.get( 'strikethrough' );
+
+		expect( strikeView.isOn ).to.be.false;
+		expect( strikeView.isEnabled ).to.be.true;
+
+		command.value = true;
+		expect( strikeView.isOn ).to.be.true;
+
+		command.isEnabled = false;
+		expect( strikeView.isEnabled ).to.be.false;
+	} );
+
+	it( 'should set keystroke in the model', () => {
+		expect( strikeView.keystroke ).to.equal( 'CTRL+SHIFT+X' );
+	} );
+
+	it( 'should set editor keystroke', () => {
+		const spy = sinon.spy( editor, 'execute' );
+		const keyEventData = {
+			keyCode: keyCodes.x,
+			shiftKey: true,
+			ctrlKey: true,
+			preventDefault: sinon.spy(),
+			stopPropagation: sinon.spy()
+		};
+
+		const wasHandled = editor.keystrokes.press( keyEventData );
+
+		expect( wasHandled ).to.be.true;
+		expect( spy.calledOnce ).to.be.true;
+		expect( keyEventData.preventDefault.calledOnce ).to.be.true;
+	} );
+} );

+ 7 - 84
packages/ckeditor5-basic-styles/tests/underline.js

@@ -1,95 +1,18 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-/* globals document */
-
-import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
 import Underline from '../src/underline';
 import Underline from '../src/underline';
-import UnderlineEngine from '../src/underlineengine';
-import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
-import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
-import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
-
-testUtils.createSinonSandbox();
+import UnderlineEditing from '../src/underline/underlineediting';
+import UnderlineUI from '../src/underline/underlineui';
 
 
 describe( 'Underline', () => {
 describe( 'Underline', () => {
-	let editor, underlineView;
-
-	beforeEach( () => {
-		const editorElement = document.createElement( 'div' );
-		document.body.appendChild( editorElement );
-
-		return ClassicTestEditor
-			.create( editorElement, {
-				plugins: [ Underline ]
-			} )
-			.then( newEditor => {
-				editor = newEditor;
-
-				underlineView = editor.ui.componentFactory.create( 'underline' );
-			} );
-	} );
-
-	afterEach( () => {
-		return editor.destroy();
+	it( 'should require UnderlineEditing and UnderlineUI', () => {
+		expect( Underline.requires ).to.deep.equal( [ UnderlineEditing, UnderlineUI ] );
 	} );
 	} );
 
 
-	it( 'should be loaded', () => {
-		expect( editor.plugins.get( Underline ) ).to.be.instanceOf( Underline );
-	} );
-
-	it( 'should load UnderlineEngine', () => {
-		expect( editor.plugins.get( UnderlineEngine ) ).to.be.instanceOf( UnderlineEngine );
-	} );
-
-	it( 'should register underline feature component', () => {
-		expect( underlineView ).to.be.instanceOf( ButtonView );
-		expect( underlineView.isOn ).to.be.false;
-		expect( underlineView.label ).to.equal( 'Underline' );
-		expect( underlineView.icon ).to.match( /<svg / );
-		expect( underlineView.keystroke ).to.equal( 'CTRL+U' );
-	} );
-
-	it( 'should execute underline command on model execute event', () => {
-		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
-
-		underlineView.fire( 'execute' );
-
-		sinon.assert.calledOnce( executeSpy );
-		sinon.assert.calledWithExactly( executeSpy, 'underline' );
-	} );
-
-	it( 'should bind model to underline command', () => {
-		const command = editor.commands.get( 'underline' );
-
-		expect( underlineView.isOn ).to.be.false;
-
-		expect( underlineView.isEnabled ).to.be.false;
-
-		command.value = true;
-		expect( underlineView.isOn ).to.be.true;
-
-		command.isEnabled = true;
-		expect( underlineView.isEnabled ).to.be.true;
-	} );
-
-	it( 'should set keystroke in the model', () => {
-		expect( underlineView.keystroke ).to.equal( 'CTRL+U' );
-	} );
-
-	it( 'should set editor keystroke', () => {
-		const spy = sinon.spy( editor, 'execute' );
-
-		const wasHandled = editor.keystrokes.press( {
-			keyCode: keyCodes.u,
-			ctrlKey: true,
-			preventDefault: sinon.spy(),
-			stopPropagation: sinon.spy()
-		} );
-
-		expect( wasHandled ).to.be.true;
-		expect( spy.calledOnce ).to.be.true;
+	it( 'should be named', () => {
+		expect( Underline.pluginName ).to.equal( 'Underline' );
 	} );
 	} );
 } );
 } );

+ 16 - 20
packages/ckeditor5-basic-styles/tests/underlineengine.js → packages/ckeditor5-basic-styles/tests/underline/underlineediting.js

@@ -1,29 +1,28 @@
 /**
 /**
- * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  * For licensing, see LICENSE.md.
  * For licensing, see LICENSE.md.
  */
  */
 
 
-import UnderlineEngine from '../src/underlineengine';
+import UnderlineEditing from '../../src/underline/underlineediting';
 
 
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import VirtualTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/virtualtesteditor';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
 import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
-import AttributeCommand from '../src/attributecommand';
+import AttributeCommand from '../../src/attributecommand';
 
 
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getModelData, setData as setModelData } from '@ckeditor/ckeditor5-engine/src/dev-utils/model';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
 import { getData as getViewData } from '@ckeditor/ckeditor5-engine/src/dev-utils/view';
 
 
-describe( 'UnderlineEngine', () => {
-	let editor, doc;
+describe( 'UnderlineEditing', () => {
+	let editor, model;
 
 
 	beforeEach( () => {
 	beforeEach( () => {
 		return VirtualTestEditor
 		return VirtualTestEditor
 			.create( {
 			.create( {
-				plugins: [ Paragraph, UnderlineEngine ]
+				plugins: [ Paragraph, UnderlineEditing ]
 			} )
 			} )
 			.then( newEditor => {
 			.then( newEditor => {
 				editor = newEditor;
 				editor = newEditor;
-
-				doc = editor.document;
+				model = editor.model;
 			} );
 			} );
 	} );
 	} );
 
 
@@ -32,13 +31,12 @@ describe( 'UnderlineEngine', () => {
 	} );
 	} );
 
 
 	it( 'should be loaded', () => {
 	it( 'should be loaded', () => {
-		expect( editor.plugins.get( UnderlineEngine ) ).to.be.instanceOf( UnderlineEngine );
+		expect( editor.plugins.get( UnderlineEditing ) ).to.be.instanceOf( UnderlineEditing );
 	} );
 	} );
 
 
 	it( 'should set proper schema rules', () => {
 	it( 'should set proper schema rules', () => {
-		expect( doc.schema.check( { name: '$inline', attributes: 'underline', inside: '$root' } ) ).to.be.false;
-		expect( doc.schema.check( { name: '$inline', attributes: 'underline', inside: '$block' } ) ).to.be.true;
-		expect( doc.schema.check( { name: '$inline', attributes: 'underline', inside: '$clipboardHolder' } ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$root', '$block', '$text' ], 'underline' ) ).to.be.true;
+		expect( model.schema.checkAttribute( [ '$clipboardHolder', '$text' ], 'underline' ) ).to.be.true;
 	} );
 	} );
 
 
 	describe( 'command', () => {
 	describe( 'command', () => {
@@ -54,7 +52,7 @@ describe( 'UnderlineEngine', () => {
 		it( 'should convert <u> to underline attribute', () => {
 		it( 'should convert <u> to underline attribute', () => {
 			editor.setData( '<p><u>foo</u>bar</p>' );
 			editor.setData( '<p><u>foo</u>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text underline="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text underline="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><u>foo</u>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><u>foo</u>bar</p>' );
@@ -63,27 +61,25 @@ describe( 'UnderlineEngine', () => {
 		it( 'should convert text-decoration:underline to underline attribute', () => {
 		it( 'should convert text-decoration:underline to underline attribute', () => {
 			editor.setData( '<p><span style="text-decoration: underline;">foo</span>bar</p>' );
 			editor.setData( '<p><span style="text-decoration: underline;">foo</span>bar</p>' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) )
+			expect( getModelData( model, { withoutSelection: true } ) )
 				.to.equal( '<paragraph><$text underline="true">foo</$text>bar</paragraph>' );
 				.to.equal( '<paragraph><$text underline="true">foo</$text>bar</paragraph>' );
 
 
 			expect( editor.getData() ).to.equal( '<p><u>foo</u>bar</p>' );
 			expect( editor.getData() ).to.equal( '<p><u>foo</u>bar</p>' );
 		} );
 		} );
 
 
 		it( 'should be integrated with autoparagraphing', () => {
 		it( 'should be integrated with autoparagraphing', () => {
-			// Incorrect results because autoparagraphing works incorrectly (issue in paragraph).
-			// https://github.com/ckeditor/ckeditor5-paragraph/issues/10
-
 			editor.setData( '<u>foo</u>bar' );
 			editor.setData( '<u>foo</u>bar' );
 
 
-			expect( getModelData( doc, { withoutSelection: true } ) ).to.equal( '<paragraph>foobar</paragraph>' );
+			expect( getModelData( model, { withoutSelection: true } ) )
+				.to.equal( '<paragraph><$text underline="true">foo</$text>bar</paragraph>' );
 
 
-			expect( editor.getData() ).to.equal( '<p>foobar</p>' );
+			expect( editor.getData() ).to.equal( '<p><u>foo</u>bar</p>' );
 		} );
 		} );
 	} );
 	} );
 
 
 	describe( 'editing pipeline conversion', () => {
 	describe( 'editing pipeline conversion', () => {
 		it( 'should convert attribute', () => {
 		it( 'should convert attribute', () => {
-			setModelData( doc, '<paragraph><$text underline="true">foo</$text>bar</paragraph>' );
+			setModelData( model, '<paragraph><$text underline="true">foo</$text>bar</paragraph>' );
 
 
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><u>foo</u>bar</p>' );
 			expect( getViewData( editor.editing.view, { withoutSelection: true } ) ).to.equal( '<p><u>foo</u>bar</p>' );
 		} );
 		} );

+ 88 - 0
packages/ckeditor5-basic-styles/tests/underline/underlineui.js

@@ -0,0 +1,88 @@
+/**
+ * @license Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+/* globals document */
+
+import ClassicTestEditor from '@ckeditor/ckeditor5-core/tests/_utils/classictesteditor';
+import UnderlineEditing from '../../src/underline/underlineediting';
+import UnderlineUI from '../../src/underline/underlineui';
+import ButtonView from '@ckeditor/ckeditor5-ui/src/button/buttonview';
+import testUtils from '@ckeditor/ckeditor5-core/tests/_utils/utils';
+import { keyCodes } from '@ckeditor/ckeditor5-utils/src/keyboard';
+
+import Paragraph from '@ckeditor/ckeditor5-paragraph/src/paragraph';
+
+testUtils.createSinonSandbox();
+
+describe( 'Underline', () => {
+	let editor, underlineView;
+
+	beforeEach( () => {
+		const editorElement = document.createElement( 'div' );
+		document.body.appendChild( editorElement );
+
+		return ClassicTestEditor
+			.create( editorElement, {
+				plugins: [ Paragraph, UnderlineEditing, UnderlineUI ]
+			} )
+			.then( newEditor => {
+				editor = newEditor;
+
+				underlineView = editor.ui.componentFactory.create( 'underline' );
+			} );
+	} );
+
+	afterEach( () => {
+		return editor.destroy();
+	} );
+
+	it( 'should register underline feature component', () => {
+		expect( underlineView ).to.be.instanceOf( ButtonView );
+		expect( underlineView.isOn ).to.be.false;
+		expect( underlineView.label ).to.equal( 'Underline' );
+		expect( underlineView.icon ).to.match( /<svg / );
+		expect( underlineView.keystroke ).to.equal( 'CTRL+U' );
+	} );
+
+	it( 'should execute underline command on model execute event', () => {
+		const executeSpy = testUtils.sinon.spy( editor, 'execute' );
+
+		underlineView.fire( 'execute' );
+
+		sinon.assert.calledOnce( executeSpy );
+		sinon.assert.calledWithExactly( executeSpy, 'underline' );
+	} );
+
+	it( 'should bind model to underline command', () => {
+		const command = editor.commands.get( 'underline' );
+
+		expect( underlineView.isOn ).to.be.false;
+		expect( underlineView.isEnabled ).to.be.true;
+
+		command.value = true;
+		expect( underlineView.isOn ).to.be.true;
+
+		command.isEnabled = false;
+		expect( underlineView.isEnabled ).to.be.false;
+	} );
+
+	it( 'should set keystroke in the model', () => {
+		expect( underlineView.keystroke ).to.equal( 'CTRL+U' );
+	} );
+
+	it( 'should set editor keystroke', () => {
+		const spy = sinon.spy( editor, 'execute' );
+
+		const wasHandled = editor.keystrokes.press( {
+			keyCode: keyCodes.u,
+			ctrlKey: true,
+			preventDefault: sinon.spy(),
+			stopPropagation: sinon.spy()
+		} );
+
+		expect( wasHandled ).to.be.true;
+		expect( spy.calledOnce ).to.be.true;
+	} );
+} );

+ 10 - 0
packages/ckeditor5-basic-styles/theme/code.css

@@ -0,0 +1,10 @@
+/*
+ * Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.md.
+ */
+
+.ck-content code {
+	background-color: hsla(0, 0%, 78%, 0.3);
+	padding: .15em;
+	border-radius: 2px;
+}

+ 0 - 14
packages/ckeditor5-basic-styles/theme/code.scss

@@ -1,14 +0,0 @@
-// Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
-// For licensing, see LICENSE.md or http://ckeditor.com/license
-
-@import '~@ckeditor/ckeditor5-theme-lark/theme/helpers/_colors.scss';
-@import '~@ckeditor/ckeditor5-theme-lark/theme/helpers/_rounded.scss';
-@import '~@ckeditor/ckeditor5-theme-lark/theme/helpers/_spacing.scss';
-
-@include ck-color-add( ( 'code': rgba( 200, 200, 200, 0.3 ) ) );
-
-code {
-	background-color: ck-color( 'code' );
-	padding: ck-spacing( 'tiny' );
-	border-radius: $ck-border-radius;
-}

+ 1 - 1
packages/ckeditor5-basic-styles/theme/icons/bold.svg

@@ -1 +1 @@
-<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M15.135 10.409c.361.248.654.56.88.934.225.375.338.816.338 1.324 0 .609-.128 1.123-.385 1.543-.256.42-.624.751-1.103.994a5.908 5.908 0 0 1-1.755.55c-.663.107-1.442.16-2.338.16H4.539v-.66a22.5 22.5 0 0 0 .66-.076c.265-.033.45-.073.558-.118.208-.085.35-.196.427-.334.076-.138.114-.317.114-.537V5.732c0-.203-.031-.372-.093-.507s-.211-.254-.448-.355a3.326 3.326 0 0 0-.61-.182 14.136 14.136 0 0 0-.608-.114v-.66h6.52c1.64 0 2.825.226 3.552.677.727.45 1.09 1.116 1.09 1.995 0 .406-.08.763-.244 1.07a2.388 2.388 0 0 1-.702.8 4.214 4.214 0 0 1-.99.54c-.383.153-.795.28-1.234.381v.16c.44.046.896.143 1.37.292.473.15.885.343 1.234.58zm-2.723-3.611c0-.665-.187-1.184-.562-1.556-.375-.372-.937-.558-1.687-.558-.107 0-.247.004-.419.012l-.444.021v4.449h.44c.913 0 1.587-.213 2.021-.639.434-.425.651-1.002.651-1.73zm.592 5.759c0-.835-.248-1.475-.744-1.92-.496-.445-1.21-.668-2.14-.668a22.977 22.977 0 0 0-.82.034v4.389c.05.208.209.385.474.528.265.144.586.216.964.216.67 0 1.216-.225 1.636-.676.42-.452.63-1.086.63-1.903z" fill="#454545" fill-rule="evenodd"/></svg>
+<svg width="20" height="20" xmlns="http://www.w3.org/2000/svg"><path d="M10.187 17H5.773c-.637 0-1.092-.138-1.364-.415-.273-.277-.409-.718-.409-1.323V4.738c0-.617.14-1.062.419-1.332.279-.27.73-.406 1.354-.406h4.68c.69 0 1.288.041 1.793.124.506.083.96.242 1.36.478.341.197.644.447.906.75a3.262 3.262 0 0 1 .808 2.162c0 1.401-.722 2.426-2.167 3.075C15.05 10.175 16 11.315 16 13.01a3.756 3.756 0 0 1-2.296 3.504 6.1 6.1 0 0 1-1.517.377c-.571.073-1.238.11-2 .11zm-.217-6.217H7v4.087h3.069c1.977 0 2.965-.69 2.965-2.072 0-.707-.256-1.22-.768-1.537-.512-.319-1.277-.478-2.296-.478zM7 5.13v3.619h2.606c.729 0 1.292-.067 1.69-.2a1.6 1.6 0 0 0 .91-.765c.165-.267.247-.566.247-.897 0-.707-.26-1.176-.778-1.409-.519-.232-1.31-.348-2.375-.348H7z" fill="#000" fill-rule="evenodd"/></svg>

+ 1 - 1
packages/ckeditor5-basic-styles/theme/icons/code.svg

@@ -1 +1 @@
-<svg width="20" height="20" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="1.414"><path d="M11.893 5.376c.123.01.23.046.333.114l5.6 3.967.004 1.017-5.6 4.033a.633.633 0 0 1-.509.101.63.63 0 0 1-.473-.708.642.642 0 0 1 .252-.407l4.89-3.522-4.886-3.461c-.036-.027-.036-.027-.069-.057a.658.658 0 0 1-.15-.219.633.633 0 0 1 .228-.751.66.66 0 0 1 .291-.105c.044-.003.044-.003.089-.002zm-3.697.002a.66.66 0 0 1 .291.105.633.633 0 0 1 .21.791.664.664 0 0 1-.201.236L3.61 9.971l4.89 3.522c.036.027.036.027.069.057a.649.649 0 0 1 .189.394.63.63 0 0 1-.7.676.655.655 0 0 1-.288-.113l-5.6-4.033.004-1.017 5.6-3.967a.685.685 0 0 1 .333-.114c.045-.001.045-.001.089.002z" fill="#353535"/></svg>
+<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><g fill="none" fill-rule="evenodd"><g fill="#353535"><g transform="translate(2 5.6)"><path d="M10.5.1L15.7 4v1.3l-5.6 4c-.1.2-.3.2-.5.2-.3-.1-.6-.7-.6-1l.3-.4L14 4.6 9.5 1.4l-.2-.2c-.1-.3-.1-.6 0-.8.2-.2.5-.4.8-.4a.8.8 0 0 1 .4.1zM5.3.1L0 4v1.3l5.6 4c.1.2.3.2.5.2.3-.1.7-.7.6-1 0-.1 0-.3-.2-.4l-5-3.5 4.7-3.2.2-.2c.1-.3.1-.6 0-.8-.2-.2-.5-.4-.8-.4a.8.8 0 0 0-.3.1z"/></g></g></g></svg>

+ 1 - 1
packages/ckeditor5-basic-styles/theme/icons/italic.svg

@@ -1 +1 @@
-<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M13.825 3.914l-.126.558a5.701 5.701 0 0 0-.685.076c-.282.045-.49.088-.626.127-.237.073-.406.186-.508.338a1.586 1.586 0 0 0-.22.5l-2.03 8.769a1.24 1.24 0 0 0-.034.27c.001.13.03.24.086.33.056.09.157.17.304.237.085.04.27.086.558.14.288.053.502.086.643.097l-.127.558H5.656l.127-.558.677-.05c.293-.023.501-.057.625-.102a1.11 1.11 0 0 0 .5-.326c.112-.138.188-.306.228-.503l2.02-8.778a1.428 1.428 0 0 0 .035-.305.59.59 0 0 0-.072-.295c-.048-.085-.148-.161-.3-.229a3.457 3.457 0 0 0-.622-.19 5.001 5.001 0 0 0-.58-.106l.128-.558h5.403z" fill="#454545" fill-rule="evenodd"/></svg>
+<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M9.586 14.633l.021.004c-.036.335.095.655.393.962.082.083.173.15.274.201h1.474a.6.6 0 1 1 0 1.2H5.304a.6.6 0 0 1 0-1.2h1.15c.474-.07.809-.182 1.005-.334.157-.122.291-.32.404-.597l2.416-9.55a1.053 1.053 0 0 0-.281-.823 1.12 1.12 0 0 0-.442-.296H8.15a.6.6 0 0 1 0-1.2h6.443a.6.6 0 1 1 0 1.2h-1.195c-.376.056-.65.155-.823.296-.215.175-.423.439-.623.79l-2.366 9.347z" fill="#333" fill-rule="evenodd"/></svg>

+ 1 - 0
packages/ckeditor5-basic-styles/theme/icons/strikethrough.svg

@@ -0,0 +1 @@
+<svg width="20" height="20" xmlns="http://www.w3.org/2000/svg"><g fill="#333" fill-rule="evenodd"><path fill-rule="nonzero" d="M3 11.5V10h14v1.5z"/><path d="M10.75 12.8v3.483c0 .488-.286.74-.774.74-.488 0-.726-.252-.726-.74V12.8h1.5zM9.25 4.424H5.005c-.452 0-.698-.297-.698-.712 0-.434.264-.712.698-.712h9.942c.434 0 .697.278.697.712 0 .415-.28.712-.697.712H10.75V8.5h-1.5V4.424z"/><path d="M9.26 6.004h1.484c-.028-.67.063-1.09.271-1.26.209-.17.477-.361.805-.572H8.09c.39.213.68.404.872.572.192.168.292.588.299 1.26z"/></g></svg>

+ 1 - 1
packages/ckeditor5-basic-styles/theme/icons/underline.svg

@@ -1 +1 @@
-<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><g fill="none" fill-rule="evenodd"><path d="M16.628 4.5c-.154.006-.38.039-.678.1a2.11 2.11 0 0 0-.726.272c-.188.127-.317.388-.388.785-.072.396-.108.88-.108 1.453v5.096c0 .65-.135 1.214-.405 1.693-.27.479-.624.873-1.065 1.18a4.49 4.49 0 0 1-1.375.641c-.482.13-.943.194-1.383.194-.705 0-1.333-.092-1.883-.277-.55-.184-1.013-.433-1.388-.747a3.143 3.143 0 0 1-.834-1.078 2.986 2.986 0 0 1-.28-1.268V5.615c0-.192-.032-.353-.096-.483-.063-.13-.191-.249-.384-.359a1.93 1.93 0 0 0-.528-.186 4.137 4.137 0 0 0-.529-.087v-.586H9.46V4.5c-.154.006-.348.03-.582.075a3.874 3.874 0 0 0-.516.124c-.188.066-.313.176-.376.33a1.313 1.313 0 0 0-.095.504v6.475c0 .313.034.642.103.987.069.344.205.664.409.962.215.303.506.55.875.743.37.193.876.29 1.52.29.606 0 1.114-.097 1.524-.29a2.54 2.54 0 0 0 .97-.76c.226-.297.386-.608.48-.933.093-.325.14-.652.14-.983V7.218c0-.612-.045-1.111-.133-1.5-.088-.388-.217-.642-.388-.763-.192-.138-.455-.245-.788-.322a5.096 5.096 0 0 0-.764-.133v-.586h4.79V4.5z" fill="#454545"/><path fill="#585858" d="M4 17h12v1H4z"/></g></svg>
+<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><g fill="none" fill-rule="evenodd"><g fill="#333"><path fill-rule="nonzero" d="M3 18v-1.5h14V18z"/><path d="M5.2 10V3.6c0-.4.4-.6.8-.6.3 0 .7.2.7.6v6.2c0 2 1.3 2.8 3.2 2.8 1.9 0 3.4-.9 3.4-2.9V3.6c0-.3.4-.5.8-.5.3 0 .7.2.7.5V10c0 2.7-2.2 4-4.9 4-2.6 0-4.7-1.2-4.7-4z"/></g></g></svg>