From fc9a32e27be2ad9b4f6c0438593dd8c9de39c7e9 Mon Sep 17 00:00:00 2001 From: Manuele Menozzi Date: Sun, 14 May 2017 19:14:18 +0200 Subject: [PATCH] Overwrites Current Link block to fit bootstrap markup --- View/Element/Html/Link/Current.php | 39 ++++++++++++++++++++++++++++++ etc/di.xml | 1 + 2 files changed, 40 insertions(+) create mode 100644 View/Element/Html/Link/Current.php diff --git a/View/Element/Html/Link/Current.php b/View/Element/Html/Link/Current.php new file mode 100644 index 0000000..c3be6d4 --- /dev/null +++ b/View/Element/Html/Link/Current.php @@ -0,0 +1,39 @@ +getTemplate()) { + return parent::_toHtml(); + } + + $highlight = ''; + + if ($this->getIsHighlighted() || $this->isCurrent()) { + $highlight = ' active'; + } + + $html = ''; + + return $html; + } +} diff --git a/etc/di.xml b/etc/di.xml index 7a806c5..ef45f9a 100644 --- a/etc/di.xml +++ b/etc/di.xml @@ -2,4 +2,5 @@ +