OOUI/About the library
|Working with widgets|
OOUI (Object-Oriented User Interface) is a library that allows developers to rapidly create front-end web applications that operate consistently across a multitude of browsers.
The OOUI library contains
- a set of ready-to-use widgets, layouts, and windows that can be instantiated directly or easily extended,
- elements that can be easily mixed and matched to create custom user interfaces.
The library provides:
- cross-browser compatibility. Interfaces built using library elements will look and act consistently across modern browsers.
- design. Themes specify how OOUI interfaces look and feel. Two themes are provided out of the box, the default “WikimediaUI” theme conforming to Wikimedia Foundation's design style guide and another theme called “Apex” inspired by the skin of the same name. Skin authors can create additional themes and use them in MediaWiki for a custom look and feel.
- sensible event handling. OOUI components listen to low-level events and emit a meaningful event at the proper time (i.e., when something actually changes).
- responsiveness. When the model changes, the view is updated automatically.
- accessibility. WikimediaUI's widgets align to WCAG level AA conformance by default.
- efficiency. The view is generated and updated client-side, requiring fewer road trips to the server.
- object-oriented functionality. The library provides support for mixins and inheritance, including the inheritance of static properties.
- openness. The library is open source and released under the MIT licence.
Compatibility, Dependencies, and Installation
OOUI is compatible with most modern web browsers, and work toward supporting additional browsers is ongoing. See the VisualEditor documentation to get a general sense for which browsers are currently supported. Note that OOUI supports a superset of these browsers, as VisualEditor compatibility is especially restricted due to its use of contentEditable.
There are instruction on using the library in MediaWiki extensions.
The following are useful resources:
- PHP documentation: The PHP API is documented using the MediaWiki conventions and can be used to generate a readable reference (the PHP documentation may lack information on mixin methods).
- Demos: Additional demos.
- OOjs documentation: The OOUI library is built alongside and of and uses OOjs as its primer. The code-generated documentation might also prove useful.
Bugs can be posted to our bug tracker Phabricator, tagged with OOUI.
If you’d like to get involved with the project, please say hello on IRC and feel free to jump right in!