From: Julius Härtl Date: Mon, 17 Aug 2020 19:38:33 +0000 (+0200) Subject: WIP: Start off with attribution for shipped backgrounds X-Git-Tag: v20.0.0beta1~35^2~16 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=d02a92e870448c20d22d3ed1939c8d2e3edc6542;p=nextcloud-server.git WIP: Start off with attribution for shipped backgrounds Signed-off-by: Julius Härtl --- diff --git a/apps/dashboard/lib/Service/BackgroundService.php b/apps/dashboard/lib/Service/BackgroundService.php index d4de491aeaa..2b59bef65d9 100644 --- a/apps/dashboard/lib/Service/BackgroundService.php +++ b/apps/dashboard/lib/Service/BackgroundService.php @@ -36,17 +36,50 @@ use OCP\IConfig; class BackgroundService { + const THEMING_MODE_LIGHT = 'light'; + const THEMING_MODE_DARK = 'dark'; + const SHIPPED_BACKGROUNDS = [ - 'anatoly-mikhaltsov-butterfly-wing-scale.jpg', - 'bernie-cetonia-aurata-take-off-composition.jpg', - 'dejan-krsmanovic-ribbed-red-metal.jpg', - 'eduardo-neves-pedra-azul.jpg', - 'european-space-agency-barents-bloom.jpg', - 'european-space-agency-namib-desert.jpg', - 'hannes-fritz-flippity-floppity.jpg', - 'hannes-fritz-roulette.jpg', - 'hannes-fritz-sea-spray.jpg', - 'kamil-porembinski-clouds.jpg', + 'anatoly-mikhaltsov-butterfly-wing-scale.jpg' => [ + 'attribution' => 'Butterfly', + 'attribution_url' => 'https://', + ], + 'bernie-cetonia-aurata-take-off-composition.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'dejan-krsmanovic-ribbed-red-metal.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'eduardo-neves-pedra-azul.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'european-space-agency-barents-bloom.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'european-space-agency-namib-desert.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'hannes-fritz-flippity-floppity.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'hannes-fritz-roulette.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'hannes-fritz-sea-spray.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ], + 'kamil-porembinski-clouds.jpg' => [ + 'attribution' => '', + 'attribution_url' => '', + ] ]; public function __construct(IRootFolder $rootFolder, IAppData $appData, IConfig $config, $userId) { diff --git a/apps/dashboard/src/components/BackgroundSettings.vue b/apps/dashboard/src/components/BackgroundSettings.vue index 757711f96bb..accc094f523 100644 --- a/apps/dashboard/src/components/BackgroundSettings.vue +++ b/apps/dashboard/src/components/BackgroundSettings.vue @@ -52,6 +52,7 @@ { + return Object.keys(shippedBackgroundList).map((item) => { return { name: item, url: prefixWithBaseUrl(item), + details: shippedBackgroundList[item], } }) },