infrabel / themes-gnap

Standardized build to produce web themes for use with GNaP.
http://gnap.io/
BSD 3-Clause "New" or "Revised" License
3 stars 4 forks source link

A toggleable 'back' button in front of the breadcrumbs #137

Open vincentsels opened 9 years ago

vincentsels commented 9 years ago

Fixes issue #136

CumpsD commented 9 years ago

Wouldn't this make more sense in a directive on its own? So I can decide where to place it? On Jul 8, 2015 4:28 PM, "Vincent Sels" notifications@github.com wrote:

Fixes issue #136 https://github.com/infrabel/themes-gnap/issues/136

You can view, comment on, or merge this pull request online at:

https://github.com/infrabel/themes-gnap/pull/137 Commit Summary

  • A toggleable 'back' button in front of the breadcrumbs, for use in mobile apps

File Changes

Patch Links:

— Reply to this email directly or view it on GitHub https://github.com/infrabel/themes-gnap/pull/137.

vincentsels commented 9 years ago

Most applications seem to put it there (browsers, windows explorer), so I think this is the most intuitive location where users would expect to find such a button. I didn't really find another appropriate 'candidate' location to put it (inside the framework). Do you see a better or equivalent option ?

CumpsD commented 9 years ago

Just a separate directive, and then include it at that spot if you want it. It has nothing to do with breadcrumb imho. Maybe someone would like the back button at the top and bottom of their content for example.

It's more about making little modules with a sane setup, instead of bundling things together. On Jul 9, 2015 10:07 AM, "Vincent Sels" notifications@github.com wrote:

Most applications seem to put it there (browsers, windows explorer), so I think this is the most intuitive location where users would expect to find such a button. I didn't really find another appropriate 'candidate' location to put it (inside the framework). Do you see a better or equivalent option ?

— Reply to this email directly or view it on GitHub https://github.com/infrabel/themes-gnap/pull/137#issuecomment-119867096.

vincentsels commented 9 years ago

I agree it'd be better as a separate directive, but the problem is, if it were, you wouldn't be able to include it at that spot in the nav bar, which is, imo, the most logical place to put it, as it's generally done in browsers & file explorers. GNaP (or rather, the Ace theme) already pretty much 'imposes' a certain lay-out anyway... I don't think it's so terrible to also 'impose' the location of this optional back button.

But maybe it's just me - a third opinion would be welcome :) @koenmetsu @ArneD @sroosen ?

CumpsD commented 8 years ago

I don't see why you wouldn't be able to include it at that spot? You just put it in the main before breadcrumbs? On Jul 9, 2015 8:26 PM, "Vincent Sels" notifications@github.com wrote:

I agree it'd be better as a separate directive, but the problem is, if it were, you wouldn't be able to include it at that spot in the nav bar, which is, imo, the most logical place to put it, as it's generally done in browsers & file explorers. GNaP (or rather, the Ace theme) pretty much 'imposes' a certain lay-out... I don't think it's so terrible to also 'impose' the location of this optional back button.

But maybe it's just me - a third opinion would be welcome :) @koenmetsu https://github.com/koenmetsu @ArneD https://github.com/ArneD @sroosen https://github.com/sroosen ?

— Reply to this email directly or view it on GitHub https://github.com/infrabel/themes-gnap/pull/137#issuecomment-120095314.

vincentsels commented 8 years ago

And anyone who wants to add it there then needs to add quite a bit of tricky css and override some bootstrap and ace css... and I still haven't been able to get it as smooth as with just another <li> in the breadcrumbs <ul> (doesn't seem possible to get it perfect)... But if you're that much against it, I'll do it the manual way & post the css here FFR... I just thought it'd be nice to have in the framework.

ArneD commented 8 years ago

I think a directive and an additional showBackButton: '=' on the breadcrumb bar is best.

The directive can consist of <a ng-click="back()"><i class="icon-circle-arrow-left"></i></a> with the back functionality. And the showBackButton could be

"        <li ng-if=\"showBackButton\" class=\"breadcrumb-back\">\n" +
"            <div back-button></div>\n" +
"        <\/li>\n" +

This way your markup still applies to the breadcrumb and the button can be placed anywhere when needed.