Unify navigation handling for content creation frames

pull/5742/merge
Aleksander Machniak 7 years ago
parent ffb2de5505
commit e75e011f6e

@ -94,5 +94,12 @@ RULES:
Can be used for example for functionality not implemented or that has no sense
on phones or touch devices. Contains a comma-separated list following values:
`large` (width > 1200px), `big` (width > 768px), `small` (width =< 768px).
- `data-content-button`: Makes the action button with this attribute to be copied
to the content frame header on small/phone screens.
- Special URLs:
In phone mode we display Prev/Next navigation buttons below the content preview
frame. We do this e.g. for mail preview or contact preview. Plugins should use
_action=add* or _action=create* or _nav=hide in the frame URL if the navigation
should be hidden, which is the case when you create a content object.

@ -724,9 +724,8 @@ function rcube_elastic_ui()
function content_frame_navigation(href, event)
{
// Don't display navigation for create/add action frames
// TODO: edit-folder should really be create-folder
// TODO: managesieve and enigma plugins use different action name scheme
if (href.match(/_action=(create|add)/) || (href.match(/_action=edit-folder/) && href.match(/_mbox=&/))) {
if (href.match(/_action=(create|add)/) || href.match(/_nav=hide/)) {
$(env.frame_nav).addClass('hide-nav-buttons');
return;
}

Loading…
Cancel
Save