Commit 95208529 authored by Luc Didry's avatar Luc Didry

Better UI for "Unsubscribe from folder" button

parent e46da531
Pipeline #43965 passed with stage
in 57 seconds
......@@ -433,36 +433,35 @@ module.exports = (function () {
m('span', ' '+conf.LANG.GROUP.SHARE)
]);
}
var buttonsArray = [shareBtn];
if (c.isAdmin) {
h2Elements.push(
m('.btn-group.pull-right', {role:'group'}, [
shareBtn,
m('a.btn.btn-default', {
href: '/mypads/group/' + c.group._id + '/edit',
config: m.route,
title: conf.LANG.MENU.CONFIG
},
[ m('i.glyphicon.glyphicon-wrench'),
m('span', ' '+conf.LANG.MENU.CONFIG)
]),
m('a.btn.btn-danger', {
href: '/mypads/group/' + c.group._id + '/remove',
config: m.route,
title: conf.LANG.GROUP.REMOVE
},
[ m('i.glyphicon.glyphicon-trash'),
m('span', ' '+conf.LANG.GROUP.REMOVE)
])
buttonsArray.push(
m('a.btn.btn-default', {
href: '/mypads/group/' + c.group._id + '/edit',
config: m.route,
title: conf.LANG.MENU.CONFIG
},
[ m('i.glyphicon.glyphicon-wrench'),
m('span', ' '+conf.LANG.MENU.CONFIG)
]),
m('a.btn.btn-danger', {
href: '/mypads/group/' + c.group._id + '/remove',
config: m.route,
title: conf.LANG.GROUP.REMOVE
},
[ m('i.glyphicon.glyphicon-trash'),
m('span', ' '+conf.LANG.GROUP.REMOVE)
])
);
} else {
h2Elements.push(shareBtn);
}
var canQuit = (c.isAdmin && c.admins.length > 1) || (!c.isAdmin);
if (!c.isGuest && canQuit) {
h2Elements.push(m('button.cancel', { onclick: c.quit },
[ m('i.glyphicon glyphicon-remove'), conf.LANG.GROUP.QUIT_GROUP ]));
buttonsArray.push(m('button.cancel.btn.btn-warning', { onclick: c.quit },
[ m('i.glyphicon glyphicon-fire'), ' '+conf.LANG.GROUP.QUIT_GROUP ]));
}
h2Elements.push(
m('.btn-group.pull-right', {role:'group'}, buttonsArray)
);
var showPass = (!c.isAdmin && (c.group.visibility === 'private') &&
!c.sendPass());
if (showPass) {
......
......@@ -127,5 +127,3 @@ section.pad iframe {
border: 1px solid #BDBDBD;
border-radius: 5px 0 5px 5px;
}
h2 button.cancel { font-size: medium; }
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment