Tobago Demo

Menu

Root Dummy Intro Search Getting Started Docker What's New Migration Compatibility FAQ API Download Server Info Logging Info In Suggest Textarea Date Range Group 5 Star Rating File Upload Out Label Badge Image Figure Progress Object Checkbox Toggle Dropdown Radio Listbox SelectOneList Multi Checkbox Multi Listbox Shuttle SelectManyList Button and Link Default Command Button Group Customizer Link Group Box Panel Separator Section Header and Footer Bar Popup Offcanvas Popover Toast Basic example Tab Client Tab Ajax Tab Server Basic example Sheet Sorting Paginator Sheet Column Selector Sheet Selectionchange Sheet Event Sheet Action Sheet Markup Sheet Style Empty Sheet Column Bar Sheet Filter Sheet Static Header Sheet Multi Header Sheet Tree Column Panel Sheet Editable Sheet Lazy Sheet Nested Basic example Tree Command Types Tree Select Tree Editor Tree Menu Tree Listbox Intro TinyMCE CKEditor Flow Layout Flex Layout Segment Layout Label Layout Grid Layout Split Layout Message-layout Overview Collapsible Box Collapsible Popup Collapsible Panel Collapsible Section Content Validation JSR 303 Severity Messages Content Security Policy Sanitize Roles Form AccessKey Focus Exception Handler Style Tag Bootstrap Theme Icons Partial Ajax Behavior WebSocket Transition Non Faces Request Conversion Error Handling For Each ConversationScoped Download Configuration Format Locale DataAttribute Meta
Root Dummy Intro Search Getting Started Docker What's New Migration Compatibility FAQ API Download Server Info Logging Info In Suggest Textarea Date Range Group 5 Star Rating File Upload Out Label Badge Image Figure Progress Object Checkbox Toggle Dropdown Radio Listbox SelectOneList Multi Checkbox Multi Listbox Shuttle SelectManyList Button and Link Default Command Button Group Customizer Link Group Box Panel Separator Section Header and Footer Bar Popup Offcanvas Popover Toast Basic example Tab Client Tab Ajax Tab Server Basic example Sheet Sorting Paginator Sheet Column Selector Sheet Selectionchange Sheet Event Sheet Action Sheet Markup Sheet Style Empty Sheet Column Bar Sheet Filter Sheet Static Header Sheet Multi Header Sheet Tree Column Panel Sheet Editable Sheet Lazy Sheet Nested Basic example Tree Command Types Tree Select Tree Editor Tree Menu Tree Listbox Intro TinyMCE CKEditor Flow Layout Flex Layout Segment Layout Label Layout Grid Layout Split Layout Message-layout Overview Collapsible Box Collapsible Popup Collapsible Panel Collapsible Section Content Validation JSR 303 Severity Messages Content Security Policy Sanitize Roles Form AccessKey Focus Exception Handler Style Tag Bootstrap Theme Icons Partial Ajax Behavior WebSocket Transition Non Faces Request Conversion Error Handling For Each ConversationScoped Download Configuration Format Locale DataAttribute Meta

Offcanvas

A offcanvas is created with <tc:offcanvas/>. It's based one the Collapsible concept.

Tag Library Documentation: <tc:offcanvas/> | <tc:operation/>

Server side (Ajax)

<tc:button label="Open offcanvas"> <tc:operation for="ajaxOffcanvas" name="show"/> <f:ajax execute="ajaxOffcanvas" render="ajaxOffcanvas"/> </tc:button> <tc:offcanvas id="ajaxOffcanvas"> <f:facet name="label">Server side (Ajax)</f:facet> <f:facet name="bar"> <tc:link image="bi-x-lg"> <tc:operation name="hide" for="ajaxOffcanvas"/> <f:ajax execute="ajaxOffcanvas" render="ajaxOffcanvas"/> </tc:link> </f:facet> Content of the server side offcanvas. </tc:offcanvas>

Server side (Ajax)

Client side

<tc:button label="Open offcanvas" omit="true"> <tc:operation for="clientOffcanvas" name="show"/> </tc:button> <tc:offcanvas id="clientOffcanvas" collapsedMode="hidden"> <f:facet name="label">Client side</f:facet> <f:facet name="bar"> <tc:link image="bi-x-lg" omit="true"> <tc:operation name="hide" for="clientOffcanvas"/> </tc:link> </f:facet> Content of the client side offcanvas. </tc:offcanvas>

Client side

Content of the client side offcanvas.

Placement

Use the placement attribute to set the position of the offcanvas. Possible values are top, left, right and bottom.

Content of the top offcanvas.

Content of the left offcanvas.

Content of the right offcanvas.

Content of the bottom offcanvas.

Events

A JavaScript custom event is fired if a <tc:offcanvas/> is collapsed or expanded.

tobago.offcanvas.show is fired before the box is expanded.

tobago.offcanvas.shown is fired after the box is expanded. (Does not wait for a possible Ajax reload.)

tobago.offcanvas.hide is fired before the box is collaped.

tobago.offcanvas.hidden is fired after the box is collapsed. (Does not wait for a possible Ajax reload.)

© 2005-2025 Apache Software Foundation, Licensed under the Apache License, Version 2.0.