From 8baa0b06e786e749391b609fe778ed76f6d1ce2b Mon Sep 17 00:00:00 2001 From: Andy Heathershaw Date: Fri, 2 Sep 2016 10:42:05 +0100 Subject: [PATCH] Implemented theming. A default "base" theme is provided that all themes can extend and override parts of if necessary without having to define every single screen. Renamed Photo Perfect to Blue Twilight. --- .idea/webServers.xml | 4 +- app/Configuration.php | 35 ++++++++ app/Facade/Theme.php | 18 ++++ app/Helpers/ThemeHelper.php | 79 ++++++++++++++++++ .../Controllers/Admin/AlbumController.php | 13 +-- .../Controllers/Admin/DefaultController.php | 3 +- .../Auth/ForgotPasswordController.php | 11 +++ app/Http/Controllers/Auth/LoginController.php | 11 +++ .../Controllers/Auth/RegisterController.php | 11 +++ .../Auth/ResetPasswordController.php | 17 ++++ .../Controllers/Gallery/DefaultController.php | 3 +- app/Providers/AppServiceProvider.php | 29 ++++++- config/app.php | 5 +- .../2016_09_02_091706_create_config_table.php | 33 ++++++++ public/bootstrap/css/bootstrap.min.css | 6 -- public/font-awesome/css/font-awesome.min.css | 4 - .../base}/bootstrap/css/bootstrap-theme.css | 0 .../bootstrap/css/bootstrap-theme.css.map | 0 .../bootstrap/css/bootstrap-theme.min.css | 0 .../bootstrap/css/bootstrap-theme.min.css.map | 0 .../base}/bootstrap/css/bootstrap.css | 0 .../base}/bootstrap/css/bootstrap.css.map | 0 .../base/bootstrap/css/bootstrap.min.css | 6 ++ .../base}/bootstrap/css/bootstrap.min.css.map | 0 .../fonts/glyphicons-halflings-regular.eot | Bin .../fonts/glyphicons-halflings-regular.svg | 0 .../fonts/glyphicons-halflings-regular.ttf | Bin .../fonts/glyphicons-halflings-regular.woff | Bin .../fonts/glyphicons-halflings-regular.woff2 | Bin .../base}/bootstrap/js/bootstrap.js | 0 .../base}/bootstrap/js/bootstrap.min.js | 0 public/{ => themes/base}/bootstrap/js/npm.js | 0 public/{ => themes/base}/css/app.css | 0 .../base}/font-awesome/HELP-US-OUT.txt | 0 .../base}/font-awesome/css/font-awesome.css | 0 .../font-awesome/css/font-awesome.min.css | 4 + .../base}/font-awesome/fonts/FontAwesome.otf | Bin .../fonts/fontawesome-webfont.eot | Bin .../fonts/fontawesome-webfont.svg | 0 .../fonts/fontawesome-webfont.ttf | Bin .../fonts/fontawesome-webfont.woff | Bin .../fonts/fontawesome-webfont.woff2 | Bin .../base}/font-awesome/less/animated.less | 0 .../font-awesome/less/bordered-pulled.less | 0 .../base}/font-awesome/less/core.less | 0 .../base}/font-awesome/less/fixed-width.less | 0 .../base}/font-awesome/less/font-awesome.less | 0 .../base}/font-awesome/less/icons.less | 0 .../base}/font-awesome/less/larger.less | 0 .../base}/font-awesome/less/list.less | 0 .../base}/font-awesome/less/mixins.less | 0 .../base}/font-awesome/less/path.less | 0 .../font-awesome/less/rotated-flipped.less | 0 .../font-awesome/less/screen-reader.less | 0 .../base}/font-awesome/less/stacked.less | 0 .../base}/font-awesome/less/variables.less | 0 .../base}/font-awesome/scss/_animated.scss | 0 .../font-awesome/scss/_bordered-pulled.scss | 0 .../base}/font-awesome/scss/_core.scss | 0 .../base}/font-awesome/scss/_fixed-width.scss | 0 .../base}/font-awesome/scss/_icons.scss | 0 .../base}/font-awesome/scss/_larger.scss | 0 .../base}/font-awesome/scss/_list.scss | 0 .../base}/font-awesome/scss/_mixins.scss | 0 .../base}/font-awesome/scss/_path.scss | 0 .../font-awesome/scss/_rotated-flipped.scss | 0 .../font-awesome/scss/_screen-reader.scss | 0 .../base}/font-awesome/scss/_stacked.scss | 0 .../base}/font-awesome/scss/_variables.scss | 0 .../base}/font-awesome/scss/font-awesome.scss | 0 public/{ => themes/base}/js/app.js | 0 public/{ => themes/base}/js/jquery.min.js | 0 resources/lang/en/global.php | 1 + resources/views/gallery/index.blade.php | 2 - resources/views/layouts/app.blade.php | 29 ------- .../base}/admin/create_album.blade.php | 2 +- .../base}/admin/delete_album.blade.php | 2 +- .../base}/admin/edit_album.blade.php | 2 +- .../{ => themes/base}/admin/index.blade.php | 2 +- .../base}/admin/list_albums.blade.php | 2 +- .../base}/admin/show_album.blade.php | 2 +- .../{ => themes/base}/auth/login.blade.php | 2 +- .../base}/auth/passwords/email.blade.php | 2 +- .../base}/auth/passwords/reset.blade.php | 2 +- .../{ => themes/base}/auth/register.blade.php | 2 +- .../views/themes/base/gallery/index.blade.php | 2 + resources/views/themes/base/layout.blade.php | 31 +++++++ .../base}/partials/navbar.blade.php | 2 +- resources/views/themes/bootstrap3/.gitkeep | 0 resources/views/themes/bootstrap3/README.txt | 5 ++ resources/views/themes/bootstrap3/theme.json | 6 ++ 91 files changed, 325 insertions(+), 65 deletions(-) create mode 100644 app/Configuration.php create mode 100644 app/Facade/Theme.php create mode 100644 app/Helpers/ThemeHelper.php create mode 100644 database/migrations/2016_09_02_091706_create_config_table.php delete mode 100644 public/bootstrap/css/bootstrap.min.css delete mode 100644 public/font-awesome/css/font-awesome.min.css rename public/{ => themes/base}/bootstrap/css/bootstrap-theme.css (100%) rename public/{ => themes/base}/bootstrap/css/bootstrap-theme.css.map (100%) rename public/{ => themes/base}/bootstrap/css/bootstrap-theme.min.css (100%) rename public/{ => themes/base}/bootstrap/css/bootstrap-theme.min.css.map (100%) rename public/{ => themes/base}/bootstrap/css/bootstrap.css (100%) rename public/{ => themes/base}/bootstrap/css/bootstrap.css.map (100%) create mode 100644 public/themes/base/bootstrap/css/bootstrap.min.css rename public/{ => themes/base}/bootstrap/css/bootstrap.min.css.map (100%) rename public/{ => themes/base}/bootstrap/fonts/glyphicons-halflings-regular.eot (100%) rename public/{ => themes/base}/bootstrap/fonts/glyphicons-halflings-regular.svg (100%) rename public/{ => themes/base}/bootstrap/fonts/glyphicons-halflings-regular.ttf (100%) rename public/{ => themes/base}/bootstrap/fonts/glyphicons-halflings-regular.woff (100%) rename public/{ => themes/base}/bootstrap/fonts/glyphicons-halflings-regular.woff2 (100%) rename public/{ => themes/base}/bootstrap/js/bootstrap.js (100%) rename public/{ => themes/base}/bootstrap/js/bootstrap.min.js (100%) rename public/{ => themes/base}/bootstrap/js/npm.js (100%) rename public/{ => themes/base}/css/app.css (100%) rename public/{ => themes/base}/font-awesome/HELP-US-OUT.txt (100%) rename public/{ => themes/base}/font-awesome/css/font-awesome.css (100%) create mode 100644 public/themes/base/font-awesome/css/font-awesome.min.css rename public/{ => themes/base}/font-awesome/fonts/FontAwesome.otf (100%) rename public/{ => themes/base}/font-awesome/fonts/fontawesome-webfont.eot (100%) rename public/{ => themes/base}/font-awesome/fonts/fontawesome-webfont.svg (100%) rename public/{ => themes/base}/font-awesome/fonts/fontawesome-webfont.ttf (100%) rename public/{ => themes/base}/font-awesome/fonts/fontawesome-webfont.woff (100%) rename public/{ => themes/base}/font-awesome/fonts/fontawesome-webfont.woff2 (100%) rename public/{ => themes/base}/font-awesome/less/animated.less (100%) rename public/{ => themes/base}/font-awesome/less/bordered-pulled.less (100%) rename public/{ => themes/base}/font-awesome/less/core.less (100%) rename public/{ => themes/base}/font-awesome/less/fixed-width.less (100%) rename public/{ => themes/base}/font-awesome/less/font-awesome.less (100%) rename public/{ => themes/base}/font-awesome/less/icons.less (100%) rename public/{ => themes/base}/font-awesome/less/larger.less (100%) rename public/{ => themes/base}/font-awesome/less/list.less (100%) rename public/{ => themes/base}/font-awesome/less/mixins.less (100%) rename public/{ => themes/base}/font-awesome/less/path.less (100%) rename public/{ => themes/base}/font-awesome/less/rotated-flipped.less (100%) rename public/{ => themes/base}/font-awesome/less/screen-reader.less (100%) rename public/{ => themes/base}/font-awesome/less/stacked.less (100%) rename public/{ => themes/base}/font-awesome/less/variables.less (100%) rename public/{ => themes/base}/font-awesome/scss/_animated.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_bordered-pulled.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_core.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_fixed-width.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_icons.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_larger.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_list.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_mixins.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_path.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_rotated-flipped.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_screen-reader.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_stacked.scss (100%) rename public/{ => themes/base}/font-awesome/scss/_variables.scss (100%) rename public/{ => themes/base}/font-awesome/scss/font-awesome.scss (100%) rename public/{ => themes/base}/js/app.js (100%) rename public/{ => themes/base}/js/jquery.min.js (100%) delete mode 100644 resources/views/gallery/index.blade.php delete mode 100644 resources/views/layouts/app.blade.php rename resources/views/{ => themes/base}/admin/create_album.blade.php (98%) rename resources/views/{ => themes/base}/admin/delete_album.blade.php (96%) rename resources/views/{ => themes/base}/admin/edit_album.blade.php (98%) rename resources/views/{ => themes/base}/admin/index.blade.php (97%) rename resources/views/{ => themes/base}/admin/list_albums.blade.php (98%) rename resources/views/{ => themes/base}/admin/show_album.blade.php (91%) rename resources/views/{ => themes/base}/auth/login.blade.php (98%) rename resources/views/{ => themes/base}/auth/passwords/email.blade.php (98%) rename resources/views/{ => themes/base}/auth/passwords/reset.blade.php (99%) rename resources/views/{ => themes/base}/auth/register.blade.php (99%) create mode 100644 resources/views/themes/base/gallery/index.blade.php create mode 100644 resources/views/themes/base/layout.blade.php rename resources/views/{ => themes/base}/partials/navbar.blade.php (99%) create mode 100644 resources/views/themes/bootstrap3/.gitkeep create mode 100644 resources/views/themes/bootstrap3/README.txt create mode 100644 resources/views/themes/bootstrap3/theme.json diff --git a/.idea/webServers.xml b/.idea/webServers.xml index 7853ee8..6e91a8b 100644 --- a/.idea/webServers.xml +++ b/.idea/webServers.xml @@ -2,8 +2,8 @@