Open sorenlouv opened 7 years ago
Right. To provide a counter argument, then, the TopBar is (conceptually) a place for top level navigation (via the tabs) and top level actions (via the buttons) that affect the "whole page". If an app is now embedded somewhere on the page, even if technically it inside an iframe
, should it then have a TopBar? If all the actions (via the buttons) are local to the app, then perhaps it should really be a ToolBar? These are the (conceptual) rules:
I think that this particular panel is a cornercase scenario because it's not really a part of the app even if it is a part of the page, so we can either:
One can imagine that the Collaboration Panel was moved to the bottom of the screen, or to a box in the middle of the screen, just as an exercise to illustrate the potential disruption of using a TopBar outside of the "main app". Let's at least discuss before we proceed cc @jerf and @DocGroth.
@wiredearp @sqren Moth's argument makes sense especially as the layout we want to eventually achieve for the Universal Inbox would not have a header (TopBar) and be inside the chrome.
In that case, @sqren, we should probably rig the Collaboration up with manualLayout: true
in the manifest.json
so that V4 doesn't render the TopBar; and then hardcode the basic layout as seen in http://ui.tradeshift.com/#getstarted/layout/ (minus the TopBar). You can then create a ToolBar with an API that is equivalent to the TopBar:
ts.ui.ToolBar.buttons([
{
icon: 'ts-icon-close',
onclick: function() {}
}
]);
We'll make sure to copy the methods dark()
and green()
and so on onto the ToolBar before the next release so that you can make it black if you like. We'll also create a special CSS classname to render the buttons without a border since that particular ts-icon-close
button traditionally doesn't have one.
The manualLayout: true
sounds like a good solution. Will look into that.
@sqren: I'm OK with the user having to close the inbox to access the main menu in the mobile view until we get the new chrome.
Currently the hamburger icon will automatically be added to an app's topbar, if it is deemed to be in mobile view. However, certain apps are always displayed inside a fixed viewport (of small size), and will therefore always be "in mobile view" even on desktop.
Is it possible to make it configurable, whether to add the hamburger icon to the topbar?