From 8177d683d37589567903ff9c30aee4b8853ae194 Mon Sep 17 00:00:00 2001 From: Matronator <5470780+matronator@users.noreply.github.com> Date: Sat, 10 Jul 2021 04:05:12 +0200 Subject: [PATCH] fucking tailwind --- .htaccess | 4 ++ .../Front/components/Footer/Footer.css | 2 +- .../Front/components/Header/Header.css | 2 +- .../components/MessageForm/MessageForm.css | 2 +- .../Front/templates/Default/image.latte | 4 +- dev/front/css/index.css | 44 +++++++++---------- dev/front/js/{ => import}/matronator.js | 0 gulpfile.babel.js | 2 +- tailwind.config.js | 2 +- www/index.php | 11 +++++ 10 files changed, 44 insertions(+), 29 deletions(-) rename dev/front/js/{ => import}/matronator.js (100%) diff --git a/.htaccess b/.htaccess index f24ab93..331e2f2 100644 --- a/.htaccess +++ b/.htaccess @@ -29,6 +29,10 @@ #RewriteCond http%1://%{HTTP_HOST} ^(https?://)(www\.)?(.+)$ #RewriteRule ^ %1%3%{REQUEST_URI} [R=301,L] + RewriteCond %{HTTP:X-Forwarded-Proto} !https [OR] + RewriteCond %{HTTP_HOST} ^(www\.) + RewriteRule (.*) https://burner.matronator.com%{REQUEST_URI} [L,R=301] + ################################################### #Set index folder diff --git a/app/modules/Front/components/Footer/Footer.css b/app/modules/Front/components/Footer/Footer.css index b82ecca..daf1d8f 100644 --- a/app/modules/Front/components/Footer/Footer.css +++ b/app/modules/Front/components/Footer/Footer.css @@ -1,6 +1,6 @@ @layer components { .footer { - @apply bg-red-darker dark:bg-black dark:bg-opacity-60 dark:backdrop-filter dark:backdrop-blur-lg dark:text-white text-white absolute bottom-0 left-0 right-0 flex flex-col items-center justify-center w-screen h-10; + @apply bg-red-darker dark:bg-black dark:bg-opacity-60 dark:backdrop-filter backdrop-blur-lg dark:text-white text-white absolute bottom-0 left-0 right-0 flex flex-col items-center justify-center w-screen h-10; box-shadow: 0px 6px 10px -7px rgba(0,0,0,0.6) inset; } } diff --git a/app/modules/Front/components/Header/Header.css b/app/modules/Front/components/Header/Header.css index b1088e9..13cf628 100644 --- a/app/modules/Front/components/Header/Header.css +++ b/app/modules/Front/components/Header/Header.css @@ -1,6 +1,6 @@ @layer components { .header { - @apply w-screen h-32 mb-4 dark:bg-grad-dark dark:bg-opacity-60 dark:backdrop-filter dark:backdrop-blur-lg bg-grad-main dark:text-white relative p-4 mx-auto text-center flex flex-col justify-center items-center; + @apply w-screen h-32 mb-4 dark:bg-grad-dark dark:bg-opacity-60 dark:backdrop-filter backdrop-blur-lg bg-grad-main dark:text-white relative p-4 mx-auto text-center flex flex-col justify-center items-center; box-shadow: 0px 0px 8px -1px rgba(0,0,0,0.66); font-family: 'Big Shoulders Stencil Display', sans-serif; & h1 { diff --git a/app/modules/Front/components/MessageForm/MessageForm.css b/app/modules/Front/components/MessageForm/MessageForm.css index 2101259..c255e85 100644 --- a/app/modules/Front/components/MessageForm/MessageForm.css +++ b/app/modules/Front/components/MessageForm/MessageForm.css @@ -2,7 +2,7 @@ .message-input { /* @apply outline-none p-2 resize-none overflow-auto appearance-none w-full h-full text-yellow-lightest; */ /* caret-color: rgba(7, 10, 10, var(--tw-text-opacity)); */ - @apply outline-none p-2 resize-none overflow-auto appearance-none h-80 w-full my-0 mx-auto mb-5 relative dark:bg-dark-primary; + @apply outline-none p-2 resize-none overflow-auto appearance-none h-80 w-full my-0 mx-auto mb-5 relative dark:bg-black dark:bg-opacity-50; font-size: 16px; } diff --git a/app/modules/Front/templates/Default/image.latte b/app/modules/Front/templates/Default/image.latte index 654d3e2..774be10 100755 --- a/app/modules/Front/templates/Default/image.latte +++ b/app/modules/Front/templates/Default/image.latte @@ -9,7 +9,7 @@ {* {include '../../components/DropUpload/DropUpload.latte', input => $form['image']->control, name => 'image'} *} -
+
-
+
{label password, class => 'w-full d-block' /}
diff --git a/dev/front/css/index.css b/dev/front/css/index.css index bf22781..c790282 100755 --- a/dev/front/css/index.css +++ b/dev/front/css/index.css @@ -50,7 +50,7 @@ input[type="text"], input[type="password"] { - @apply bg-yellow-lightest dark:backdrop-filter dark:backdrop-blur-lg dark:bg-black dark:bg-opacity-50 dark:text-white px-1 py-2; + @apply bg-yellow-lightest dark:backdrop-filter backdrop-blur-lg dark:bg-black dark:bg-opacity-50 dark:text-white px-1 py-2; } } @@ -106,25 +106,25 @@ @media (max-width: 640px) { font-size: 14px; } - &:hover { - font-variation-settings: 'wght' 650; - } - &\-primary { - @apply bg-grad-main dark:bg-grad-secondary-primary text-white; - text-shadow: 0px 0px 2px rgba(0,0,0,0.5); - /* box-shadow: 0px 0px 6px -1px rgba(0,0,0,0.66); */ - &:hover { - text-shadow: -1.5px -1.5px 0px rgba(0,0,0,0.7); - } - } - &\-secondary { - @apply bg-grad-secondary dark:bg-grad-dark dark:backdrop-filter dark:backdrop-blur-lg dark:bg-opacity-50 dark:text-secondary text-white; - text-shadow: 0px 0px 2px rgba(0,0,0,0.5); - /* box-shadow: 0px 0px 6px -1px rgba(0,0,0,0.66); */ - &:hover { - text-shadow: -1.5px -1.5px 0px rgba(0,0,0,0.7); - } - } + } + .btn:hover { + font-variation-settings: 'wght' 650; + } + .btn-primary { + @apply bg-grad-main dark:bg-grad-secondary-primary text-white; + text-shadow: 0px 0px 2px rgba(0,0,0,0.5); + /* box-shadow: 0px 0px 6px -1px rgba(0,0,0,0.66); */ + } + .btn-primary:hover { + text-shadow: -1.5px -1.5px 0px rgba(0,0,0,0.7); + } + .btn-secondary { + @apply bg-grad-secondary dark:bg-grad-dark dark:backdrop-filter backdrop-blur-lg dark:bg-opacity-50 dark:text-secondary text-white; + text-shadow: 0px 0px 2px rgba(0,0,0,0.5); + /* box-shadow: 0px 0px 6px -1px rgba(0,0,0,0.66); */ + } + .btn-secondary:hover { + text-shadow: -1.5px -1.5px 0px rgba(0,0,0,0.7); } .msg-link { @@ -134,12 +134,12 @@ } .read-message { - @apply bg-yellow-lighter block w-full px-3 py-4 mx-auto my-4 text-base text-left; + @apply bg-yellow-lighter dark:backdrop-filter backdrop-blur-lg dark:bg-black dark:bg-opacity-50 dark:placeholder-grey-lighter dark:text-white text-grey-darker placeholder-grey-dark block w-full px-3 py-4 mx-auto my-4 text-base text-left; min-height: 200px; } .input { - @apply bg-yellow-lightest dark:backdrop-filter dark:backdrop-blur-lg dark:bg-opacity-50 dark:bg-black dark:placeholder-grey-lighter dark:text-white text-grey-darker text-input placeholder-grey-dark font-normal border-none shadow-none; + @apply bg-yellow-lightest dark:backdrop-filter backdrop-blur-lg dark:bg-opacity-50 dark:bg-black dark:placeholder-grey-lighter dark:text-white text-grey-darker text-input placeholder-grey-dark font-normal border-none shadow-none; font-size: 16px; } } diff --git a/dev/front/js/matronator.js b/dev/front/js/import/matronator.js similarity index 100% rename from dev/front/js/matronator.js rename to dev/front/js/import/matronator.js diff --git a/gulpfile.babel.js b/gulpfile.babel.js index 987ab40..65f1c46 100755 --- a/gulpfile.babel.js +++ b/gulpfile.babel.js @@ -50,7 +50,7 @@ const cssProcessors = [ isProduction ? [ postscssAutoprefixer, // uses browser list option from package.json - postcssNano, + // postcssNano, ] : [ postscssAutoprefixer diff --git a/tailwind.config.js b/tailwind.config.js index b037916..c95c611 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -1,5 +1,5 @@ module.exports = { - mode: 'jit', + // mode: 'jit', purge: [ // "./app/modules/Front/**/*.{js,css,html,latte}", // "./dev/front/**/*.{js,css,html,latte}", diff --git a/www/index.php b/www/index.php index 8455f82..6000e6f 100755 --- a/www/index.php +++ b/www/index.php @@ -5,6 +5,17 @@ // Uncomment this line if you must temporarily take down your site for maintenance. // require '.maintenance.php'; +if (isset($_SERVER['HTTP_X_FORWARDED_PROTO'])) { + if ($_SERVER['HTTP_X_FORWARDED_PROTO'] === 'https' && isset($_SERVER['SERVER_PORT']) && in_array($_SERVER['SERVER_PORT'], [80, 82])) { // https over proxy + $_SERVER['HTTPS'] = 'On'; + $_SERVER['SERVER_PORT'] = 443; + + } elseif ($_SERVER['HTTP_X_FORWARDED_PROTO'] === 'http' && isset($_SERVER['SERVER_PORT']) && $_SERVER['SERVER_PORT'] == 80) { // http over proxy + $_SERVER['HTTPS'] = 'Off'; + $_SERVER['SERVER_PORT'] = 80; + } +} + // absolute filesystem path to the web root define('WWW_DIR', __DIR__);