Commit graph

83 commits

Author SHA1 Message Date
Damyon Wiese
3ee53a425f MDL-44092 Atto: Add selectionchanged event and listeners in the buttons.
This means the buttons can indicate the state of the text under the cursor.
2014-03-26 10:01:43 +08:00
Jerome Mouneyrac
99061b7ad1 MDL-43863 Add Undo/Redo plugins to Atto 2014-03-26 10:01:43 +08:00
Frederic Massart
f6bef145bd MDL-44125 atto_align: Style with CSS whenever possible 2014-03-26 10:01:43 +08:00
Frederic Massart
acc94f70c8 MDL-44125 atto_align: New plugin for text alignment 2014-03-26 10:01:43 +08:00
Damyon Wiese
8bf5ad67ea MDL-43855 Atto: Add an equation editor
This equation editor relies on whatever the currently configured filter is to do the rendering.
If there is no filter that handles latex ($$ blah $$) - this plugin will not show up.

This will not work with the solutions on the forums of adding MathJax in the header of the page,
but it will work with a real mathjax filter written for Moodle (work in progress). It works with
the existing tex filter.
2014-03-26 10:01:42 +08:00
Damyon Wiese
05843fd3ee MDL-44067 Atto: Improve table editing controls.
Remove flaky inline menu icons - instead clicking on the table button, when
you are in a table shows the context menu for the current cell.

I removed all the special code for 'atto_control' - because it did not work very well. Having non-contenteditable
nodes inside a contenteditable region seems in expose bugs in different browsers.
2014-03-26 10:01:42 +08:00
Damyon Wiese
5ec54dd125 MDL-44127 Atto: Improve Atto API to allow plugins with multiple buttons/menus 2014-03-26 10:01:42 +08:00
Damyon Wiese
8095505e3c MDL-44126 Atto: List of minor fixes from review.
toolbar order (base it on tinymce)
change plain to paragraph
default for collapse plugin should be 5 groups
fix alignment of table dialogue form
insert newlines in html generated by table plugin
rename accessibility helper to screenreader helper
remove accessibility hint for images and media files
fix some broken plugin names
style table captions
remove verbose accessibility hints
2014-03-26 10:01:42 +08:00
Jerome Mouneyrac
fe0d247796 MDL-43869 New Atto plugin switch language LTR/RTL 2014-03-26 10:00:05 +08:00
Frederic Massart
c7ef8e455e MDL-43870 atto_title: Remove quoted style 2014-03-26 10:00:05 +08:00
Frederic Massart
5a06d5d71d MDL-43870 atto_indent: Removing browser styling after execCommand 2014-03-26 10:00:05 +08:00
Damyon Wiese
b03d59821a MDL-43934 Atto: Rename shifter meta files to the correct name.
This could have caused yui to fetch extra files because the dependencies might not have been loaded.
2014-03-26 10:00:04 +08:00
Damyon Wiese
fcb5b5c473 MDL-43854 Atto: Add collapse toolbar plugin 2014-03-26 10:00:04 +08:00
Frederic Massart
4c37c1f416 MDL-43954 editor_atto: Fix styling for IE8 in clean and standard 2014-03-26 10:00:04 +08:00
Rossiani Wijaya
39e2a67a53 MDL-44032 Atto editor: add subscript and superscript plugins 2014-03-26 10:00:04 +08:00
Damyon Wiese
26f8822d5c MDL-43867 Atto: Accessibility improvements.
1/ Set the aria-labelledby attribute on the contenteditable div (find the label from
original textarea)

2/ Store/restore the selection for the contenteditable div when it is focused. This allows
you to select some text, then go to the toolbar and click a button, and the selection
will be restored before the button effect is applied.

3/ Add an accessibility helper plugin.

From testing in all screenreaders, I found that all of their support for contenteditable is not great.
They treat it like a textbox - which means you can type and edit text, but it tells you nothing about
the styles, links or images in the editor. So I added a button to the toolbar, that is only accessible
when navigating via keyboard, that opens an accesssibility helper dialogue. The dialogue shows the list
of current styles, a global list of all links, and a global list of all images. Choosing an image or link
from here, will focus on the editable region, and select the link/image.

4/ Add an accessibility checker plugin to Atto.

Checks for images with no alt, images and links with filenames as alternate text/link text, and contrast ratios
less than WCAG 2.0 AA.
2014-03-26 09:59:37 +08:00
Frederic Massart
dad09216bc MDL-43953 editor_atto: Trigger form change when editing content 2014-03-26 09:59:37 +08:00
Frederic Massart
60a051d471 MDL-44064 editor_atto: Do not die when a plugin is missing 2014-03-26 09:59:36 +08:00
Damyon Wiese
34f5867a11 MDL-43990 Atto: Add a function for changing the formatting of the selected block. 2014-03-26 09:59:36 +08:00
Damyon Wiese
0fa78b80b4 MDL-43861 Atto: Fix for toolbar menu repaint bug in chrome. 2014-03-26 09:59:36 +08:00
Rossiani Wijaya
534cf7b730 MDL-43861: Atto Plugins: create new plugin for font and background colors 2014-03-26 09:59:36 +08:00
Damyon Wiese
0012a94601 MDL-44003 Atto: Set type="button" on atto toolbar buttons.
To prevent them accidentally becoming the default submit buttons for the form.
2014-03-26 09:59:36 +08:00
Frederic Massart
d19cf39edb MDL-44003 editor_atto: Identify the submit buttons in plugins 2014-03-26 09:59:36 +08:00
Frederic Massart
6e3220c053 MDL-43862 atto_managefiles: New plugin to manage files
AMOS BEGIN
 CPY [hasmissingfiles,tinymce_managefiles],[hasmissingfiles,atto_managefiles]
 CPY [deleteselected,tinymce_managefiles],[deleteselected,atto_managefiles]
 CPY [unusedfilesdesc,tinymce_managefiles],[unusedfilesdesc,atto_managefiles]
 CPY [unusedfilesheader,tinymce_managefiles],[unusedfilesheader,atto_managefiles]
AMOS END
2014-03-26 09:59:35 +08:00
Frederic Massart
224a9a51ad MDL-43859 atto_smiley: New plugin to insert smileys 2014-03-26 09:59:35 +08:00
Damyon Wiese
0ec6a46ad1 MDL-43869 Atto: Fix broken repositories.
The previous change on this issue accidentally fixed a selector,
so the repository API was recieving a valid node instead of null.
This means that it calls it's undocumented and dodgy callbacks on the node,
which are really calls directly to the TinyMCE API (just well buried).

But - by not setting the editor_target property, the api will not do
the secret handshakes.
2014-03-26 09:59:35 +08:00
Frederic Massart
c7829b26e1 MDL-43858 atto_charmap: New plugin to insert special characters 2014-03-26 09:59:35 +08:00
Damyon Wiese
48bdf86f31 MDL-43869 Atto: Add functions to get the nodes from the elementids.
If plugins try and do this themselves with Y.one, they will fall foul of the
qtype essay page bug which uses : in the id for form elements.

This is an alternative solution, to escaping the ids, which seemed unreliable for older
version of ie.
2014-03-26 09:59:35 +08:00
Frederic Massart
45698f7714 MDL-43950 editor_atto: Add arguments to plugin callback params_for_js 2014-03-26 09:59:35 +08:00
Damyon Wiese
d088a835d1 MDL-43857: Auto clean tag bloat from word/openoffice/googledocs
The cleanup rules are pulled from both testing of live docs, and the
jquery clean plugin. I tested with googledocs, libreoffice, word 2003
and word 2013.
2014-03-26 09:59:35 +08:00
Damyon Wiese
b269f635f6 MDL-43869 Atto: id escaping so Atto works with when there is : in the id.
(Quiz)
Also includes fixes for Atto when the repositories should not be displayed.
2014-03-26 09:59:34 +08:00
Damyon Wiese
55c0403c6c MDL-43853 Atto: Performance. Turbocharge the loader.
Rewrite the atto plugin loader so that:

A) We have a real settings.php page and can edit the toolbar.
B) All plugins are loaded at the same time (not serially)
C) All plugins share the YUI sandbox (more performance boost).

I had to change the loading API for this - but there are not non-core uses yet,
this is the best time to break it.
2014-03-26 09:59:34 +08:00
Damyon Wiese
f1e6953b36 MDL-43842 Atto: Remove licence and README.txt 2014-03-26 09:59:34 +08:00
Damyon Wiese
3df7cfc59a MDL-43842 Atto: Move pix-icons into core pix folder. 2014-03-26 09:59:34 +08:00
Damyon Wiese
adca7326d8 MDL-43842: Import atto back into core 2014-03-26 09:59:34 +08:00
Damyon Wiese
775a32c9b8 MDL-42459 Atto: Bye bye - see you in the plugins db! 2013-10-22 12:01:56 +08:00
Damyon Wiese
835a006b07 Merge branch 'MDL-42091-master' of git://github.com/phalacee/moodle 2013-10-10 14:04:47 +08:00
Jason Fowler
97b251a352 MDL-42091 Atto - fixing on click indication 2013-10-10 13:47:10 +08:00
Damyon Wiese
80d5b253e2 Merge branch 'MDL-42091-master' of git://github.com/phalacee/moodle 2013-10-10 09:11:25 +08:00
Jason Fowler
8bcd5ddeab MDL-42091 atto - fixing on hover and active states of buttons 2013-10-10 09:05:47 +08:00
Damyon Wiese
103ba42d84 MDL-41993 Atto: Always clean/update the textarea when the content is changed 2013-10-09 11:08:06 +08:00
Eloy Lafuente (stronk7)
7e9dadfd99 Merge branch 'MDL-42026-master' of git://github.com/damyon/moodle
Conflicts:
	lib/editor/atto/yui/build/moodle-editor_atto-editor/moodle-editor_atto-editor-min.js
2013-10-09 01:48:45 +02:00
Damyon Wiese
cbe5a022f1 MDL-41993 Atto: Strip yui ids from generated HTML. 2013-10-08 09:32:18 +08:00
Petr Škoda
e87214bda7 MDL-42078 multiple uninstall improvements and cleanup
Includes:
* update checker refactored to \core\update\ namespace
* plugininfo classes refactored to \core\plugininfo\ namespace
* plugin_manager renamed to core_plugin_manager
* redirect back to original page after plugin uninstall
* fixed assign subplugin uninstall
* move assign subplugins under the assignment in admin tree
* fixed plugininfo for all question related plugin types
* auth uninstall support
* added missing block dependencies
* added theme uninstall
* subplugin types are following the plugin on plugin overview page
* several performance improvements in plugin manager
* new warnigns when plugininfo are outdated or missing
* multiple fixes and other improvements
2013-10-07 13:10:36 +02:00
Sam Hemelryk
322ca2fc66 Merge branch 'MDL-41241-master-fix3' of git://github.com/damyon/moodle
Conflicts:
	lib/editor/atto/yui/build/moodle-editor_atto-editor/moodle-editor_atto-editor-min.js
2013-10-03 16:03:22 +13:00
Damyon Wiese
8c11cd2e09 MDL-41241 Atto: Restrict searching for anchor tags to selection. 2013-10-03 10:54:10 +08:00
Marina Glancy
d794391d8b Merge branch 'MDL-41241-master-fix2' of github.com:damyon/moodle 2013-10-02 17:27:03 +10:00
Damyon Wiese
30509335dd MDL-41241 Atto: Make searching for the anchor tag more reliable 2013-10-02 15:21:11 +08:00
Damyon Wiese
766c6401b7 MDL-41912 Atto: Min-height fix - div was too small by default. 2013-10-02 13:13:35 +08:00
Marina Glancy
3a3e3fa3b5 Merge branch 'MDL-41989-master' of git://github.com/phalacee/moodle 2013-10-01 14:45:14 +10:00