O'Reilly logo

Liferay 6.2 User Interface Development by Jonas X. Yuan, Xinsheng Chen

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Finding out widgets in Alloy UI

A widget is a self-contained UI unit in Alloy UI. It realizes a complete, small UI features. For example, when you manage pages at a site in the Liferay Portal, you see a hierarchy of pages on the left-hand side of the page, which is a widget. A tooltip is another widget in Alloy UI.

In this section, we will first talk about a TreeView widget.

Creating a TreeView instance

The TreeView class extends the TreeData class, which in turn extends the Base class. The TreeView class provides the widget lifecycle.

The following is the code for using the TreeView widget:

<div id="markupBoundingBox"></div> <aui:script use="aui-tree-view"> var children = [ { children: [ {label: 'Design', leaf: true, type: 'task'}, {label: 'Coding', ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required