Jump to content

OOUI/Widgets

From mediawiki.org

Widgets are compositions of one or more OOUI elements that users can both view and interact with. All widgets can be configured and modified via a standard API, and their state can change dynamically according to a model. The library handles the application’s low-level DOM events (click, keydown, mouseup, etc.), filtering the "noise" (e.g., a copy and paste of the same content that results in no actual change) and emitting (see OOjs/Events ) high-level, meaningful events to the application.

The OOUI library contains a number of ready-to-customize widgets that fall into several main categories: buttons and switches, icons, indicators and labels, selects and options, input widgets, popups, and progress bars. When used together with layouts, these widgets can create high-level components like dialog or modal windows.

Note that not every widget in the library is commonly used ‘out-of-the-box’. Some widgets, such as MenuWidgets, are designed to be extended and will rarely be instantiated on their own.

Widgets

[edit]