From 91a4676fc0034f63bacc36ea2591599b373e5447 Mon Sep 17 00:00:00 2001 From: "Felix A. Epp" Date: Sat, 21 Jan 2017 17:06:26 +0100 Subject: [PATCH] Make enabled and disabled apps a tabular list Signed-off-by: Felix A. Epp --- settings/css/settings.css | 38 +++++++++++++++++++++++++++++--- settings/js/apps.js | 16 ++++++++++---- settings/templates/apps.php | 44 +++++++++++++++++++++++++++++++++++++ 3 files changed, 91 insertions(+), 7 deletions(-) diff --git a/settings/css/settings.css b/settings/css/settings.css index 5ca62248c0..b8bf2b26cb 100644 --- a/settings/css/settings.css +++ b/settings/css/settings.css @@ -541,9 +541,7 @@ span.version { #app-navigation .app-external, .app-version { - -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=50)"; - filter: alpha(opacity=50); - opacity: .5; + color: rgba(85,85,85,.5); } .app-level { @@ -725,6 +723,40 @@ form.section { margin-bottom: 1em; } +#apps-list.installed { + display: table; + width: 100%; + height: auto; +} + +#apps-list.installed .section { + display: table-row; + padding: 0; + margin: 0; +} + +#apps-list.installed .section > *{ + display: table-cell; + width: auto; + height: 3em; + vertical-align: middle; + float: none; + border-bottom: 1px solid #eee; + padding: .5em 1em; + box-sizing: border-box; +} + +#apps-list.installed .app-image { + text-align: center; +} + +.installed .actions { + text-align: right; +} + +#apps-list.installed .groups-enable { + margin-top: 0 +} /* LOG */ #log { diff --git a/settings/js/apps.js b/settings/js/apps.js index 9a3ff09337..3d94a128d3 100644 --- a/settings/js/apps.js +++ b/settings/js/apps.js @@ -94,7 +94,14 @@ OC.Settings.Apps = OC.Settings.Apps || { // default values for missing fields return _.extend({level: 0}, app); }); - var source = $("#app-template").html(); + var source + if (categoryId === 'enabled' || categoryId === 'disabled') { + source = $("#app-template-installed").html(); + $('#apps-list').addClass('installed'); + } else { + source = $("#app-template").html(); + $('#apps-list').removeClass('installed'); + } var template = Handlebars.compile(source); if (appList.length) { @@ -257,12 +264,13 @@ OC.Settings.Apps = OC.Settings.Apps || { */ imageUrl : function (url, appfromstore) { - var img = ''; - + var img; if (appfromstore) { + img = ''; img += ''; } else { - img += ''; + img = ''; + img += ''; } return img; }, diff --git a/settings/templates/apps.php b/settings/templates/apps.php index 0adf5dfcc6..1b6e5e6032 100644 --- a/settings/templates/apps.php +++ b/settings/templates/apps.php @@ -29,6 +29,50 @@ script( + + +