Skip to content

Commit

Permalink
Add base layout information to the bottom of the page.
Browse files Browse the repository at this point in the history
  • Loading branch information
drew7721 committed Oct 11, 2019
1 parent cb342a3 commit b8e2023
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 0 deletions.
5 changes: 5 additions & 0 deletions view/frontend/layout/default.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,9 @@
<head>
<script src="JustinKase_LayoutHints::js/jk-hints.js"/>
</head>
<body>
<referenceContainer name="root">
<block name="justinkase_layout_info" class="Magento\Framework\View\Element\Template" as="jkase_info" template="JustinKase_LayoutHints::info.phtml"/>
</referenceContainer>
</body>
</page>
15 changes: 15 additions & 0 deletions view/frontend/templates/info.phtml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php
/**
* Additional information template.
*
* @author Alex Ghiban <drew7721@gmail.com>
*
* @var \Magento\Framework\View\Element\Template $block
*/
?>
<div class="justinkase-hint-footer">
<h4>Used Layout Update Handles</h4>
<?php var_dump($block->getLayout()->getUpdate()->getHandles());?>
<h4>Suggested Available Containers</h4>
<?php var_dump($block->getLayout()->getUpdate()->getContainers());?>
</div>
9 changes: 9 additions & 0 deletions view/frontend/web/css/source/_module.less
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,21 @@
.justinkase-hint-info {
display: none;
}

.justinkase-hint-extra {
display: none;
}
}

.justinkase-hint-footer {
display: none;
}

body.justinkase-hints-enabled {
.justinkase-hint-footer {
display: block;
}

.justinkase-hint {
display: block;
position: relative;
Expand Down

0 comments on commit b8e2023

Please sign in to comment.