User tests: Successful: Unsuccessful:
Protostar classes layout and task output incomplete if not layout or task. If no layout or task assigned, outputs: layout- and task- respectively. Also outputs itemid- on views that are not a menu item.
Added if/else to output 'layout-' or if not available 'no-layout'. Same for 'task-'. For itemid, if not a menu item, itemid- should not show up.
<body class="site <?php echo $option . " view-" . $view . ($layout ? " layout-" . $layout : " no-layout") . ($task ? " task-" . $task : " no-task") . ($itemid ? " itemid-" . $itemid : ""); ?> <?php if ($this->params->get('fluidContainer')) { echo "fluid"; } ?>">
Tracker item created at: http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=29858
Hi Cristina,
that's perfectly fine with me.
Of course one should try to separate the issues - not mixing code style changes with bug fixes..
But since this is what the current maintainers are practicing, we should take the chance whenever someone is willing to commit something..
Hopefully we will have a "coding style fun and pizza event" or something in the near future since we have such nice coding styles and automated checkers that are able to tell us that there are currently over 50.000 violations.
Cheers ;)
Thanks Nikolai,
You're right, I added a second commit that brought a bit of consistency across the board.
Made new tracker item: http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=29875
That looks pretty cool :)
Hi Nikolai,
I agree the style and readability there could be improved. I would do this in a separate pull request for two reasons:
It is unrelated to the issue I was fixing with incomplete class names.
There are others, for example, on lines 139 and 183. A PR that changes all of these so that readability is improved, but also consistency is maintained throughout the file.
I will gladly do that tomorrow and put in another PR. Will also look around and see if it is present in any other files within the template. :)