Move Dropbox/GDrive link to icon
This commit is contained in:
parent
a09ef66eea
commit
ac27163f68
|
@ -18,6 +18,11 @@ td.mountPoint, td.backend { width:160px; }
|
|||
#addMountPoint>td.applicable { visibility:hidden; }
|
||||
#addMountPoint>td.hidden { visibility:hidden; }
|
||||
|
||||
#externalStorage .icon-settings {
|
||||
padding: 11px 20px;
|
||||
vertical-align: text-bottom;
|
||||
}
|
||||
|
||||
#selectBackend {
|
||||
margin-left: -10px;
|
||||
width: 150px;
|
||||
|
|
|
@ -11,17 +11,19 @@ $(document).ready(function() {
|
|||
|
||||
OCA.External.Settings.mountConfig.whenSelectBackend(function($tr, backend, onCompletion) {
|
||||
if (backend === 'dropbox') {
|
||||
var config = $tr.find('.configuration');
|
||||
var backendEl = $tr.find('.backend');
|
||||
var el = $(document.createElement('a'))
|
||||
.attr('href', generateUrl($tr))
|
||||
.attr('target', '_blank')
|
||||
.text(t('files_external', 'Dropbox Configuration') + ' ↗')
|
||||
.attr('title', t('files_external', 'Dropbox App Configuration'))
|
||||
.addClass('icon-settings svg')
|
||||
;
|
||||
el.on('click', function(event) {
|
||||
var a = $(event.target);
|
||||
a.attr('href', generateUrl($(this).parent()));
|
||||
a.attr('href', generateUrl($(this).closest('tr')));
|
||||
});
|
||||
config.append(el);
|
||||
el.tooltip({placement: 'top'});
|
||||
backendEl.append(el);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
@ -7,17 +7,19 @@ $(document).ready(function() {
|
|||
|
||||
OCA.External.Settings.mountConfig.whenSelectBackend(function($tr, backend, onCompletion) {
|
||||
if (backend === 'googledrive') {
|
||||
var config = $tr.find('.configuration');
|
||||
var backendEl = $tr.find('.backend');
|
||||
var el = $(document.createElement('a'))
|
||||
.attr('href', generateUrl($tr))
|
||||
.attr('target', '_blank')
|
||||
.text(t('files_external', 'Google Drive Configuration') + ' ↗')
|
||||
.attr('title', t('files_external', 'Google Drive App Configuration'))
|
||||
.addClass('icon-settings svg')
|
||||
;
|
||||
el.on('click', function(event) {
|
||||
var a = $(event.target);
|
||||
a.attr('href', generateUrl($(this).parent()));
|
||||
a.attr('href', generateUrl($(this).closest('tr')));
|
||||
});
|
||||
config.append(el);
|
||||
el.tooltip({placement: 'top'});
|
||||
backendEl.append(el);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue