Skip to content

Commit

Permalink
ZKCK-48: wcs plugin breaks without scyat in current release
Browse files Browse the repository at this point in the history
  • Loading branch information
scribetw committed Sep 12, 2019
1 parent ed25873 commit f80e531
Show file tree
Hide file tree
Showing 6 changed files with 132 additions and 27 deletions.
105 changes: 80 additions & 25 deletions ckez/src/archive/web/js/ckez/ext/CKeditor/plugins/wsc/README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,80 @@
CKEditor WebSpellChecker Plugin
===============================

This plugin brings Web Spell Checker (WSC) into CKEditor.

WSC is "installation-less", using the web-services of [WebSpellChecker.net](http://www.webspellchecker.net/). It's an out of the box solution.

Installation
------------

1. Clone/copy this repository contents in a new "plugins/wsc" folder in your CKEditor installation.
2. Enable the "wsc" plugin in the CKEditor configuration file (config.js):

config.extraPlugins = 'wsc';

That's all. WSC will appear on the editor toolbar and will be ready to use.

License
-------

Licensed under the terms of any of the following licenses at your choice: [GPL](http://www.gnu.org/licenses/gpl.html), [LGPL](http://www.gnu.org/licenses/lgpl.html) and [MPL](http://www.mozilla.org/MPL/MPL-1.1.html).

See LICENSE.md for more information.

Developed in cooperation with [WebSpellChecker.net](http://www.webspellchecker.net/).
WebSpellChecker Dialog Plugin for CKEditor 4
===============================

WebSpellChecker Dialog (WSC Dialog) provides distraction-free proofreading, checking the whole text’s spelling and grammar on-click in a separate pop-up window.

![WSC Dialog Plugin for CKEditor 4 View](https://webspellchecker.com/app/images/wsc_dialog_plugin_for_ckeditor4.png)

This plugin brings the multi-language WSC Dialog functionality into CKEditor 4. It is integrated by default starting with [Standard Package of CKEditor 4](https://ckeditor.com/ckeditor-4/download/). You can find it on the CKEditor 4 toolbar panel under the ABC button (Check Spelling).

If your version of CKEditor doesn’t have WSC Dialog built-in, you can easily add it by following the steps outlined in the Get Started section.

The default version of WSC Dialog plugin for CKEditor 4 is using the free services of WebSpellChecker. It is provided with a banner ad and has some [limitations](https://docs.webspellchecker.net/display/WebSpellCheckerCloud/Free+and+Paid+WebSpellChecker+Cloud+Services+Comparison+for+CKEditor).

To lift the limitations and get rid of the banner, [obtain a license](https://webspellchecker.com/wsc-dialog-ckeditor4/#pricing). Depending on your needs, you can choose a Cloud-based or Server (self-hosted) solution.

Demo
------------
WSC Dialog plugin for CKEditor 4: https://webspellchecker.com/wsc-dialog-ckeditor4/

Supported Languages
------------

The WSC Dialog plugin for CKEditor as a part of the free services supports the next languages for check spelling: American English, British English, Canadian English, Canadian French, Danish, Dutch, Finnish, French, German, Greek, Italian, Norwegian Bokmal, Spanish, Swedish.

There are also additional languages and specialized dictionaries available for a commercial license, you can check the full list [here](https://webspellchecker.com/additional-dictionaries/).

Get Started
------------

1. Clone/copy this repository contents in a new "plugins/wsc" folder in your CKEditor installation.
2. Enable the "wsc" plugin in the CKEditor configuration file (config.js):

config.extraPlugins = 'wsc';

That's all. WSC Dialog will appear on the editor toolbar under the ABC button and will be ready to use.

Supported Browsers
-------

This is the list of officially supported browsers for the WSC Dialog plugin for CKEditor 4. WSC Dialog may also work in other browsers and environments but we unable to check all of them and guarantee proper work.

* Chrome (the latest)
* Firefox (the latest)
* Safari (the latest)
* MS Edge (the latest)
* Internet Explorer 8.0 (limited support)
* Internet Explorer 9.0+ (close to full support)

Note: All browsers are to be supported for web pages that work in Standards Mode.

Resources
-------

* Demo: https://webspellchecker.com/wsc-dialog-ckeditor4/
* Documentation: https://docs.webspellchecker.net/
* YouTube video: https://youtu.be/bkVPZ-5T22Q
* Term of Service: https://webspellchecker.com/terms-of-service/

Technical Support or Questions
-------

In cooperation with the CKEditor team, during the past 10 years we have simplified the installation and built the extensive amount of documentation devoted to WSC Dialog plugin for CKEditor 4 and less.

If you are experiencing any difficulties with the setup of the plugin, please check the links provided in the Resources section.

Holders of an active subscription to the services or a commercial license have access to professional technical assistance directly from the WebSpellChecker team. [Contact us here](https://webspellchecker.com/contact-us/)!

Reporting Issues
-------

Please use the [WSC Dialog plugin for CKEditor 4 GitHub issue page](https://github.com/WebSpellChecker/ckeditor-plugin-wsc/issues) to report bugs and feature requests. We will do our best to reply at our earliest convenience.

License
-------

This plugin is licensed under the terms of any of the following licenses at your choice: [GPL](http://www.gnu.org/licenses/gpl.html), [LGPL](http://www.gnu.org/licenses/lgpl.html) and [MPL](http://www.mozilla.org/MPL/MPL-1.1.html).

See LICENSE.md for more information.

Developed by [WebSpellChecker](https://webspellchecker.com/) in cooperation with CKSource.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 33 additions & 0 deletions test/addon/ckeztest/src/archive/test2/B-ZKCK-48.zul
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
B-ZKCK-48.zul
Purpose:
Description:
History:
Wed Sep 11 17:48:46 CST 2019, Created by rudyhuang
Copyright (C) 2019 Potix Corporation. All Rights Reserved.
-->
<zk xmlns:w="client">
<label multiline="true">
1. Type something in CKeditor.
2. Click "Check Spelling".
3. Click "Finish Checking".
4. It shouldn't hang with a "loading" icon circling.
</label>
<ckeditor>
<attribute w:name="getConfig_"><![CDATA[
function (config) {
config.disableNativeSpellChecker = true;
config.removePlugins = 'scayt';
config.scayt_autoStartup = false;
config.toolbar = [['SpellChecker']];
return config;
}
]]></attribute>
</ckeditor>
</zk>
1 change: 1 addition & 0 deletions test/addon/ckeztest/src/archive/test2/config.properties
Original file line number Diff line number Diff line change
Expand Up @@ -90,3 +90,4 @@ B-ZKCK-50.zul=A,E,Ckeditor,onChanging
B-ZKCK-46.zul=A,E,Ckeditor,onSelection
B-ZKCK-45.zul=A,E,Ckeditor,jQuery,ZK5
B-ZKCK-51.zul=A,E,Ckeditor,onRestore,ROD
B-ZKCK-48.zul=A,E,Ckeditor,plugins,wcs
15 changes: 15 additions & 0 deletions test/addon/ckeztest/test/B-ZKCK-48.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import { Selector } from 'testcafe';

fixture('ZKCK-48')
.page('http://localhost:8080/ckeztest/test2/B-ZKCK-48.zul');

test('WCS dialog should be closed after finishing', async t => {
await t
.click('.cke_wysiwyg_frame')
.pressKey('a b c d e f g')
.click('.cke_button__spellchecker')
.click('.cke_dialog_ui_input_text')
.click('.cke_dialog_ui_button[title-cmd="FinishChecking"]')

.expect(Selector('#overlayBlock').visible).notOk();
});
1 change: 1 addition & 0 deletions zkdoc/ckez-release-note
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Ckez 4.11.1.1
ZKCK-46: CKeditor onSelection handler doesn't expect native selection to be null
ZKCK-45: Ckez uses jQuery 1.7 functions, not compatible with ZK 5/6
ZKCK-51: follow-up zk-4360 - check instance during onRestore
ZKCK-48: wcs plugin breaks without scyat in current release

* Upgrade Notes:

Expand Down

0 comments on commit f80e531

Please sign in to comment.