Just FYI, the new version of MediaWiki has been finally deployed to the Wikipedias along with the new OO.ui.LookupElement class, after a two-week delay due to WMF All Hands and MediaWiki Dev Summit (announcement <https://lists.wikimedia.org/pipermail/wikitech-ambassadors/2015-January/001075.html>) and the threat of performance regressions (T88528 <https://phabricator.wikimedia.org/T88528>). But, to add insult to injury, the overflow of the lookup menu is now clipped by the dialog :-/

Il 14/01/2015 21:18, Jon Robson ha scritto:
Yeh likewise. This is great! Thanks! This was the first complicated
widget thing that made me venture into the OOJS UI world (although I
don't win much by having a simple button component or as I didn't want
to build such a complicated component) :-)

I'm sure there are other widgets with this sort of complexity that are
just as useful (dialogs comes to mind) and would be great for these to
have demos so next time someone needs one they can hit the ground
running.

On Tue, Jan 13, 2015 at 10:45 PM, Ricordisamoa
<[email protected]> wrote:
Thanks! I finally managed to subclass LookupInputWidget properly.
The suggestions menu is overlaid by other text input widgets, but it works.

Il 10/01/2015 17:15, Jon Robson ha scritto:

I recently hit the exact same issue. It's a useful widget but has no demos
(see https://phabricator.wikimedia.org/T85467)

Luckily after a week of fiddling Florian and I have two demos that are
working. The code in the following patches should help you work out.

I understand that Andrew Garret is setting up a demo site. I wonder if
during the dev summit we could get s demo for this done and on it?

https://gerrit.wikimedia.org/r/181225
https://gerrit.wikimedia.org/r/180880
   On 10 Jan 2015 04:37, "Ricordisamoa" <[email protected]>
wrote:

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.

   _______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l


_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to