]> git.koha-community.org Git - koha.git/commit
Bug 32571: Use template wrapper to build tabbed components
authorOwen Leonard <oleonard@myacpl.org>
Thu, 5 Jan 2023 12:54:42 +0000 (12:54 +0000)
committerTomas Cohen Arazi <tomascohen@theke.io>
Tue, 7 Feb 2023 18:30:21 +0000 (15:30 -0300)
commit9df8e02df06a3a266f8716c19e425ec5b65fa790
tree125e32df43efbc9c721d9602c1f9b9496e982e4f
parentd00d07cae751986a220d114ff165cbf5206a0283
Bug 32571: Use template wrapper to build tabbed components

This patch adds Template::Toolkit WRAPPER blocks to html_helpers.inc so
that templates can build tabbed components while keeping tab structural
markup separate.

Each individual component of a Bootstrap tabbed interface is defined:

- Main tab container
- Tab links container
- Individual tab links
- Tab panel container
- Individual tab panels

Included is a usage example:

  [ WRAPPER tabs id= "tabs container id" ]
      [ WRAPPER tabs_nav ]
        [ WRAPPER tab_item tabname= "tab name 1" ] [ content ] [ END ]
          [ WRAPPER tab_item tabname= "tab name 2" ] [ content ] [ END ]
            ...
        [ END ]
        [ WRAPPER tab_panels ]
          [ WRAPPER tab_panel id="tab name 1"] [ content ] [ END ]
          [ WRAPPER tab_panel id="tab name 2"] [ content ] [ END ]
            ...
      [ END ]
  [ END ]

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
koha-tmpl/intranet-tmpl/prog/en/includes/html_helpers.inc