Maybe add a "(using Code Editor)" to the edit summary to aid propagation?
MediaWiki talk:Gadget-CodeEditor.js
Excellent idea -- I stuffed that in along with resizable edit area. :D
This post was posted by He7d3r, but signed as Brion VIBBER.
Could you change the link depending on which site the script is? This would make edits like this to have blue links to MediaWiki wiki instead of red links to the local wiki.
Hmm, I think I can work around that -- will test momentarily!
This post was posted by He7d3r, but signed as Brion VIBBER.
Ok, updated version should point to mw:CodeEditor which should work correctly when the gadget is loaded from other Wikimedia wikis.
This post was posted by He7d3r, but signed as Brion VIBBER.
The summary was removed recently.
- Brackets and parentheses inside strings, comments, and regexes "match up" to those outside them.
- Alt-comma to focus the textbox doesn't work.
- Any Hebrew letters with vowels under them ("אְ") causes the rest of the line to show the cursor in the wrong place.
Highlighting issue should get reported upstream; the hebrew stuff might be RTL-specific or it might be a general issue with text assumptions, but either way is upstream issue again so we'll want to collect that... The access key is probably on our end, I'll see what I can do to tweak it. (Also, the talk page shouldn't go into this editor. ;)
This post was posted by He7d3r, but signed as Brion VIBBER.
I'm adapting this as an extension and giving it some tighter integration with WikiEditor; may be able to do that version as a gadget as well.
New ability so far: the toolbar buttons for inserting text (partially) work, allowing use of for instance the special character insertion thingy. Whee!
This experiment is also pre-work for Future editor projects, as we'll be plugging more exciting things in later.
This post was posted by He7d3r, but signed as Brion VIBBER.
This post by Rillke was moved on 2013-09-05. You can find it at Thread:MediaWiki talk:Gadget-CodeEditor.js/Tabs.
Hi, great piece of work.
- Is there any chance getting this installed on Wikimedia Commons?
- What's the state of the extension?
- Can I switch from 4 spaces to a tab as required by the MW-coding conventions using the UI?
Thanks
About the indentation with tabs, see these comments.
If I open a protected page such as this wich I cannot edit, I get the following error:
Uncaught TypeError: Cannot read property 'modules' of undefined
from the line
$.wikiEditor.modules.codeEditor = {
of CodeEditor/modules/jquery.codeEditor.js and also
Uncaught TypeError: Object [object Object] has no method 'wikiEditor'
from line
$( '#wpTextbox1' ).wikiEditor( 'addModule', 'codeEditor' );
If I disable the option
- [_] Enable enhanced editing toolbar
on Special:Preferences#preftab-3 and go to edit a .js page I get the following errors using Google Chrome 12.0.742.122 on secure server:
Uncaught TypeError: Cannot read property 'modules' of undefined (anonymous function)jquery.codeEditor.js:5 (anonymous function)jquery.codeEditor.js:392
Uncaught TypeError: Object #<Object> has no method 'wikiEditor'
(anonymous function)ext.codeEditor.js:42 jQuery.fn.jQuery.readyload.php:3 (anonymous function)ext.codeEditor.js:40
On Firefox 5, the errors are:
$.wikiEditor is undefined http://toolserver.org/~brion/extensions/CodeEditor/modules/jquery.codeEditor.js Line 5 $.wikiEditor.modules.codeEditor = {
$("#wpTextbox1").wikiEditor is not a function http://toolserver.org/~brion/extensions/CodeEditor/modules/ext.codeEditor.js Line 42 $( '#wpTextbox1' ).wikiEditor( 'addModule', 'codeEditor' );
The button is not being displayed correctly:
I'm using Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.16) Gecko/20110430 Iceweasel/3.5.16 (like Firefox/3.5.16).