Thanks. I eventually managed to use ProcessDialog and several widgets in
a script of mine <https://it.wikipedia.org/wiki/Utente:Ricordisamoa/PDC.js>.
I just couldn't make LookupInputWidget work (phab:T85467
<https://phabricator.wikimedia.org/T85467>, mw:Talk:OOjs
UI#OO.ui.LookupInputWidget vs jQuery autocomplete
<https://www.mediawiki.org/wiki/Talk:OOjs_UI#OO.ui.LookupInputWidget_vs_jQuery_autocomplete>),
and had to fall back to jQuery UI's autocomplete. The 'solution' I've
come up with is, more or less:
var widget= new OO.ui.TextInputWidget();
widget
.$input
.autocomplete( {
source: function ( request, response) {
response( [
request.term + 'test 1',
request.term + 'test 2',
request.term + 'test 3'
] );
}
} );
Very few examples can be found of LookupInputWidget. Does anyone have
any hints about it?
Il 19/10/2014 17:49, Bartosz DziewoĆski ha scritto:
OOUI is reasonably stable and can be used in gadgets,
if you wish to.
There is some high-level documentation and several examples at
https://www.mediawiki.org/wiki/OOjs_UI and complete API reference at
https://doc.wikimedia.org/oojs-ui/master/ .
Breaking changes still can sometimes happen and when they do, they are
not being announced very widely (they're just committed with "BREAKING
CHANGE" in the subject line). If you start using OOUI and something
that used to work suddenly breaks, please complain at
#mediawiki-visualeditor.