diff --git a/plugins/devtools/CHANGELOG.md b/plugins/devtools/CHANGELOG.md index e9a4a58..bcfb483 100644 --- a/plugins/devtools/CHANGELOG.md +++ b/plugins/devtools/CHANGELOG.md @@ -1,3 +1,10 @@ +# v1.7.0 +## 02/15/2023 + +1. [](#improved) + * Created non-opinionated and basic Tailwind CSS theme as default `tailwind` solution + * Moved the opinionated Tailwind CSS theme with Laravel Mix to a separate option + # v1.6.1 ## 01/02/2023 diff --git a/plugins/devtools/blueprints.yaml b/plugins/devtools/blueprints.yaml index a999b51..6f026d0 100644 --- a/plugins/devtools/blueprints.yaml +++ b/plugins/devtools/blueprints.yaml @@ -1,7 +1,7 @@ name: DevTools slug: devtools type: plugin -version: 1.6.1 +version: 1.7.0 description: Plugin and Theme scaffolding utilities icon: cogs author: diff --git a/plugins/devtools/cli/NewThemeCommand.php b/plugins/devtools/cli/NewThemeCommand.php index fb479ef..089b110 100644 --- a/plugins/devtools/cli/NewThemeCommand.php +++ b/plugins/devtools/cli/NewThemeCommand.php @@ -138,7 +138,13 @@ class NewThemeCommand extends DevToolsCommand $question = new ChoiceQuestion( 'Please choose an option', - ['pure-blank' => 'Basic Theme using Pure.css', 'tailwind' => 'Basic Theme using tailwind.css', 'inheritance' => 'Inherit from another theme', 'copy' => 'Copy another theme'] + [ + 'pure-blank' => 'Basic Theme using Pure.css', + 'tailwind' => 'Basic Theme using tailwind.css and including Alpine.js', + 'tailwind-mix' => 'Same as `tailwind` but more opinionated with Laravel Mix compiler', + 'inheritance' => 'Inherit from another theme', + 'copy' => 'Copy another theme' + ] ); $this->component['template'] = $io->askQuestion($question); diff --git a/plugins/devtools/components/plugin/flex/blueprints/flex-objects/plugin.yaml.twig b/plugins/devtools/components/plugin/flex/blueprints/flex-objects/plugin.yaml.twig index 70e6f15..a6556c9 100644 --- a/plugins/devtools/components/plugin/flex/blueprints/flex-objects/plugin.yaml.twig +++ b/plugins/devtools/components/plugin/flex/blueprints/flex-objects/plugin.yaml.twig @@ -47,7 +47,7 @@ config: # Edit View edit: title: - template: '{{ object.title }}' + template: '{{ object.name }}' # Preview View preview: diff --git a/plugins/devtools/components/theme/tailwind-mix/CHANGELOG.md.twig b/plugins/devtools/components/theme/tailwind-mix/CHANGELOG.md.twig new file mode 100644 index 0000000..37256e0 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/CHANGELOG.md.twig @@ -0,0 +1,5 @@ +# v0.1.0 +## {{ "now"|date("m/d/Y") }} + +1. [](#new) + * ChangeLog started... diff --git a/plugins/devtools/components/theme/tailwind-mix/LICENSE.twig b/plugins/devtools/components/theme/tailwind-mix/LICENSE.twig new file mode 100644 index 0000000..015a4ae --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/LICENSE.twig @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) {{ "now"|date("Y") }} {{ component.author.name }} + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/plugins/devtools/components/theme/tailwind-mix/README.md.twig b/plugins/devtools/components/theme/tailwind-mix/README.md.twig new file mode 100644 index 0000000..c6d05fd --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/README.md.twig @@ -0,0 +1,41 @@ +# {{ component.name|titleize }} Theme + +The **{{ component.name|titleize }}** Theme is for [Grav CMS](http://github.com/getgrav/grav). This README.md file should be modified to describe the features, installation, configuration, and general usage of this theme. + +## Description + +{{ component.description }} + +# Instructions + +Run + +`npm install` to setup tailwind and required plugins + +How to build tailwind: + +Development: + +`npm run build` for single time compiling + +`npm run watch` for constant development + +Production: + +`npm run prod` for production compiling. **Don't forget to turn on production mode in the theme config**# Instructions + +Run + +`npm install` to setup tailwind and required plugins + +How to build tailwind: + +Development: + +`npm run build` for single time compiling + +`npm run watch` for constant development + +Production: + +`npm run prod` for production compiling. **Don't forget to turn on production mode in the theme config** diff --git a/plugins/devtools/components/theme/tailwind-mix/blueprints.yaml.twig b/plugins/devtools/components/theme/tailwind-mix/blueprints.yaml.twig new file mode 100644 index 0000000..a592fb7 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/blueprints.yaml.twig @@ -0,0 +1,43 @@ +{% set githubid = component.author.githubid ?: component.author.name|hyphenize -%} +name: {{ component.name|titleize }} +slug: {{ component.name|hyphenize }} +type: theme +version: 0.1.0 +description: {{ component.description }} +icon: rebel +author: + name: {{ component.author.name }} + email: {{ component.author.email }} +homepage: https://github.com/{{ githubid }}/grav-theme-{{ component.name|hyphenize }} +demo: http://demo.yoursite.com +keywords: grav, theme, etc +bugs: https://github.com/{{ githubid }}/grav-theme-{{ component.name|hyphenize }}/issues +readme: https://github.com/{{ githubid }}/grav-theme-{{ component.name|hyphenize }}/blob/develop/README.md +license: MIT + +dependencies: + - { name: grav, version: '>=1.6.0' } + +form: + validation: loose + fields: + dropdown.enabled: + type: toggle + label: Dropdown in Menu + highlight: 1 + default: 1 + options: + 1: PLUGIN_ADMIN.ENABLED + 0: PLUGIN_ADMIN.DISABLED + validate: + type: bool + production: + type: toggle + label: Production Mode + highlight: 1 + default: 1 + options: + 1: PLUGIN_ADMIN.ENABLED + 0: PLUGIN_ADMIN.DISABLED + validate: + type: bool diff --git a/plugins/devtools/components/theme/tailwind-mix/css/site.css b/plugins/devtools/components/theme/tailwind-mix/css/site.css new file mode 100644 index 0000000..f578962 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/css/site.css @@ -0,0 +1,5 @@ +/*@import 'yourcssfile.css';*/ + +@tailwind base; +@tailwind components; +@tailwind utilities; diff --git a/plugins/devtools/components/theme/tailwind-mix/fonts/.gitkeep b/plugins/devtools/components/theme/tailwind-mix/fonts/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/plugins/devtools/components/theme/tailwind-mix/images/logo.png b/plugins/devtools/components/theme/tailwind-mix/images/logo.png new file mode 100644 index 0000000..64be1a9 Binary files /dev/null and b/plugins/devtools/components/theme/tailwind-mix/images/logo.png differ diff --git a/plugins/devtools/components/theme/tailwind-mix/js/.gitkeep b/plugins/devtools/components/theme/tailwind-mix/js/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/plugins/devtools/components/theme/tailwind-mix/js/main.js b/plugins/devtools/components/theme/tailwind-mix/js/main.js new file mode 100644 index 0000000..8647582 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/js/main.js @@ -0,0 +1,5 @@ +import Alpine from 'alpinejs' + +window.Alpine = Alpine + +Alpine.start() \ No newline at end of file diff --git a/plugins/devtools/components/theme/tailwind-mix/languages/en.yaml.twig b/plugins/devtools/components/theme/tailwind-mix/languages/en.yaml.twig new file mode 100644 index 0000000..2b48ba2 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/languages/en.yaml.twig @@ -0,0 +1,2 @@ +THEME_{{ component.name|hyphenize|replace({'-': '_'})|upper }}: + ERROR: 'Error!' diff --git a/plugins/devtools/components/theme/tailwind-mix/package.json.twig b/plugins/devtools/components/theme/tailwind-mix/package.json.twig new file mode 100644 index 0000000..09c8658 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/package.json.twig @@ -0,0 +1,25 @@ +{ + "name": "{{ component.name }}", + "repository": "", + "private": true, + "version": "0.1.0", + "description": "", + "main": "index.js", + "scripts": { + "build": "npx mix", + "watch": "npx mix watch", + "prod": "npx mix -p" + }, + "dependencies": {}, + "devDependencies": { + "@tailwindcss/forms": "^0.5.0", + "@tailwindcss/typography": "^0.5.2", + "alpinejs": "^2.8.2", + "browser-sync": "^2.27.7", + "browser-sync-webpack-plugin": "^2.3.0", + "laravel-mix": "^6.0.43", + "mix-tailwindcss": "^1.3.0", + "tailwindcss": "^3.0.18", + "tailwindcss-debug-screens": "^2.2.1" + } +} diff --git a/plugins/devtools/components/theme/tailwind-mix/screenshot.jpg b/plugins/devtools/components/theme/tailwind-mix/screenshot.jpg new file mode 100644 index 0000000..5205ca5 Binary files /dev/null and b/plugins/devtools/components/theme/tailwind-mix/screenshot.jpg differ diff --git a/plugins/devtools/components/theme/tailwind-mix/tailwind.config.js.twig b/plugins/devtools/components/theme/tailwind-mix/tailwind.config.js.twig new file mode 100644 index 0000000..9aa99b6 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/tailwind.config.js.twig @@ -0,0 +1,70 @@ +const colors = require('tailwindcss/colors'); + +module.exports = { + content: [ + '../../config/**/*.yaml', + '../../pages/**/*.md', + './blueprints/**/*.yaml', + './js/**/*.js', + './templates/**/*.twig', + './{{ component.name|hyphenize }}.yaml', + './{{ component.name|hyphenize }}.php' + ], + darkMode: 'class', //false or 'media' or 'class' + theme: { + extend: { + screens: { + sm: '640px', + md: '768px', + lg: '1024px', + xl: '1280px', + '2xl': '1536px' + } + }, + colors: { + 'primary': { + 'lighter': colors.yellow['300'], + DEFAULT: colors.yellow['400'], + 'darker' : colors.yellow['500'], + }, + black: colors.black, + white: colors.white, + red: colors.red, + green: colors.green, + blue: colors.blue, + orange: colors.orange, + indigo: colors.indigo, + transparent: 'transparent', + 'inherit': 'inherit', + }, + typography: (theme) => ({ + DEFAULT: { + css: { + color: 'inherit', + lineHeight: 'inherit', + maxWidth: 'inherit', + a: { + transition: 'all 500ms', + color: theme('colors.primary.DEFAULT'), + '&:hover': { + color: theme('colors.primary.darker') + }, + textDecoration: 'none' + }, + strong: { + color: 'inherit' + }, + } + } + }), + }, + variants: { + extend: {}, + }, + plugins: [ + require('@tailwindcss/forms'), + require('@tailwindcss/typography'), + require('tailwindcss-debug-screens') + ], + important: false, +} diff --git a/plugins/devtools/components/theme/tailwind-mix/templates/default.html.twig b/plugins/devtools/components/theme/tailwind-mix/templates/default.html.twig new file mode 100644 index 0000000..1e97738 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/templates/default.html.twig @@ -0,0 +1,5 @@ +{% extends 'partials/base.html.twig' %} + +{% block content %} + {{ page.content|raw }} +{% endblock %} diff --git a/plugins/devtools/components/theme/tailwind-mix/templates/error.html.twig b/plugins/devtools/components/theme/tailwind-mix/templates/error.html.twig new file mode 100644 index 0000000..c25efaa --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/templates/error.html.twig @@ -0,0 +1,8 @@ +{% extends 'partials/base.html.twig' %} + +{% block content %} +
+

{{ 'THEME_TAILWIND.ERROR'|t }}

+ {{ page.content|raw }} +
+{% endblock %} diff --git a/plugins/devtools/components/theme/tailwind-mix/templates/partials/base.html.twig b/plugins/devtools/components/theme/tailwind-mix/templates/partials/base.html.twig new file mode 100644 index 0000000..4ec88dd --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/templates/partials/base.html.twig @@ -0,0 +1,68 @@ +{% set extension = config.theme.production ? '.min' : '' %} + + + + {% block head %} + + {% if header.title %}{{ header.title|e }} | {% endif %}{{ site.title|e }} + + + + {% include 'partials/metadata.html.twig' %} + + + + {% endblock head %} + + {% block stylesheets %} + {% do assets.addCss('theme://dist/css/site' ~ extension ~ '.css', 98) %} + {% endblock %} + + {% block javascripts %} + {% do assets.addJs('theme://dist/js/main' ~ extension ~ '.js', 98) %} + {% endblock %} + + {% block assets deferred %} + {{ assets.css()|raw }} + {{ assets.js()|raw }} + {% endblock %} + + + +{% block header %} +
+
+ + {% block header_navigation %} + + {% endblock %} +
+
+{% endblock %} + +{% block body %} +
+
+ {% block content %}{% endblock %} +
+
+{% endblock %} + +{% block footer %} + +{% endblock %} + +{% block bottom %} + {{ assets.js('bottom')|raw }} +{% endblock %} + + + diff --git a/plugins/devtools/components/theme/tailwind-mix/templates/partials/navigation.html.twig b/plugins/devtools/components/theme/tailwind-mix/templates/partials/navigation.html.twig new file mode 100644 index 0000000..28df6aa --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/templates/partials/navigation.html.twig @@ -0,0 +1,47 @@ +{% macro loop(page) %} + {% for p in page.children.visible %} + {% set current_page = (p.active or p.activeChild) ? 'selected' : '' %} + {% if p.children.visible.count > 0 %} +
  • + + {% if p.header.icon %}{% endif %} + {{ p.menu|e }} + + +
  • + {% else %} +
  • + + {% if p.header.icon %}{% endif %} + {{ p.menu|e }} + +
  • + {% endif %} + {% endfor %} +{% endmacro %} + + diff --git a/plugins/devtools/components/theme/tailwind-mix/theme.php.twig b/plugins/devtools/components/theme/tailwind-mix/theme.php.twig new file mode 100644 index 0000000..332b164 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind-mix/theme.php.twig @@ -0,0 +1,9 @@ +=15.0.1" + } + }, + "node_modules/picocolors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", + "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", + "dev": true + }, + "node_modules/postcss": { + "version": "8.4.21", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.21.tgz", + "integrity": "sha512-tP7u/Sn/dVxK2NnruI4H9BG+x+Wxz6oeZ1cJ8P6G/PZY0IKk4k/63TDsQf2kQq3+qoJeLm2kIBUNlZe3zgb4Zg==", + "dev": true, + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/postcss/" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/postcss" + } + ], + "dependencies": { + "nanoid": "^3.3.4", + "picocolors": "^1.0.0", + "source-map-js": "^1.0.2" + }, + "engines": { + "node": "^10 || ^12 || >=14" + } + }, + "node_modules/source-map-js": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", + "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + } + }, + "dependencies": { + "nanoid": { + "version": "3.3.4", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.4.tgz", + "integrity": "sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw==", + "dev": true + }, + "picocolors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", + "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", + "dev": true + }, + "postcss": { + "version": "8.4.21", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.21.tgz", + "integrity": "sha512-tP7u/Sn/dVxK2NnruI4H9BG+x+Wxz6oeZ1cJ8P6G/PZY0IKk4k/63TDsQf2kQq3+qoJeLm2kIBUNlZe3zgb4Zg==", + "dev": true, + "requires": { + "nanoid": "^3.3.4", + "picocolors": "^1.0.0", + "source-map-js": "^1.0.2" + } + }, + "source-map-js": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", + "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", + "dev": true + } + } +} diff --git a/plugins/devtools/components/theme/tailwind/package.json.twig b/plugins/devtools/components/theme/tailwind/package.json.twig index 09c8658..7cacd40 100644 --- a/plugins/devtools/components/theme/tailwind/package.json.twig +++ b/plugins/devtools/components/theme/tailwind/package.json.twig @@ -6,20 +6,20 @@ "description": "", "main": "index.js", "scripts": { - "build": "npx mix", - "watch": "npx mix watch", - "prod": "npx mix -p" + "build": "cross-env NODE_ENV=development tailwindcss -i ./css/site.css -o ./dist/css/site.css --postcss", + "watch": "cross-env NODE_ENV=development tailwindcss -i ./css/site.css -o ./dist/css/site.css --postcss --watch", + "prod" : "cross-env NODE_ENV=production tailwindcss -i ./css/site.css -o ./dist/css/site.css --postcss" }, "dependencies": {}, "devDependencies": { - "@tailwindcss/forms": "^0.5.0", - "@tailwindcss/typography": "^0.5.2", + "@tailwindcss/forms": "^0.5.3", + "@tailwindcss/typography": "^0.5.9", "alpinejs": "^2.8.2", - "browser-sync": "^2.27.7", - "browser-sync-webpack-plugin": "^2.3.0", - "laravel-mix": "^6.0.43", - "mix-tailwindcss": "^1.3.0", - "tailwindcss": "^3.0.18", + "autoprefixer": "^10.4.13", + "cross-env": "^7.0.3", + "postcss": "^8.4.21", + "postcss-import": "^15.1.0", + "tailwindcss": "^3.2.6", "tailwindcss-debug-screens": "^2.2.1" } } diff --git a/plugins/devtools/components/theme/tailwind/postcss.config.js b/plugins/devtools/components/theme/tailwind/postcss.config.js new file mode 100644 index 0000000..98680a1 --- /dev/null +++ b/plugins/devtools/components/theme/tailwind/postcss.config.js @@ -0,0 +1,10 @@ +module.exports = { + plugins: { + 'postcss-import': {}, + 'tailwindcss/nesting': {}, + tailwindcss: {}, + autoprefixer: {}, + ...process.env.NODE_ENV === 'production' + ? {'cssnano': {}} : {} + } +} diff --git a/plugins/devtools/components/theme/tailwind/tailwind.config.js.twig b/plugins/devtools/components/theme/tailwind/tailwind.config.js.twig index 9aa99b6..846e3f4 100644 --- a/plugins/devtools/components/theme/tailwind/tailwind.config.js.twig +++ b/plugins/devtools/components/theme/tailwind/tailwind.config.js.twig @@ -1,5 +1,4 @@ -const colors = require('tailwindcss/colors'); - +/** @type {import('tailwindcss').Config} */ module.exports = { content: [ '../../config/**/*.yaml', @@ -11,60 +10,13 @@ module.exports = { './{{ component.name|hyphenize }}.php' ], darkMode: 'class', //false or 'media' or 'class' - theme: { - extend: { - screens: { - sm: '640px', - md: '768px', - lg: '1024px', - xl: '1280px', - '2xl': '1536px' - } - }, - colors: { - 'primary': { - 'lighter': colors.yellow['300'], - DEFAULT: colors.yellow['400'], - 'darker' : colors.yellow['500'], - }, - black: colors.black, - white: colors.white, - red: colors.red, - green: colors.green, - blue: colors.blue, - orange: colors.orange, - indigo: colors.indigo, - transparent: 'transparent', - 'inherit': 'inherit', - }, - typography: (theme) => ({ - DEFAULT: { - css: { - color: 'inherit', - lineHeight: 'inherit', - maxWidth: 'inherit', - a: { - transition: 'all 500ms', - color: theme('colors.primary.DEFAULT'), - '&:hover': { - color: theme('colors.primary.darker') - }, - textDecoration: 'none' - }, - strong: { - color: 'inherit' - }, - } - } - }), - }, + theme: {}, variants: { - extend: {}, + extend: {} }, plugins: [ require('@tailwindcss/forms'), require('@tailwindcss/typography'), require('tailwindcss-debug-screens') - ], - important: false, + ] } diff --git a/plugins/devtools/components/theme/tailwind/templates/partials/base.html.twig b/plugins/devtools/components/theme/tailwind/templates/partials/base.html.twig index 643d4de..ae825a0 100644 --- a/plugins/devtools/components/theme/tailwind/templates/partials/base.html.twig +++ b/plugins/devtools/components/theme/tailwind/templates/partials/base.html.twig @@ -19,7 +19,7 @@ {% endblock %} {% block javascripts %} - {% do assets.addJs('theme://dist/js/main' ~ extension ~ '.js', 98) %} + {% do assets.addJs('theme://js/main' ~ extension ~ '.js', 98) %} {% endblock %} {% block assets deferred %} @@ -55,7 +55,7 @@ {% block footer %} {% endblock %} diff --git a/plugins/login/CHANGELOG.md b/plugins/login/CHANGELOG.md index f61b561..8d69c7d 100644 --- a/plugins/login/CHANGELOG.md +++ b/plugins/login/CHANGELOG.md @@ -1,3 +1,9 @@ +# v3.7.3 +## 02/17/2023 + +1. [](#bugfix) + * Fixed an issue where user was not being redirected to the correct page after login + # v3.7.2 ## 01/02/2023 diff --git a/plugins/login/blueprints.yaml b/plugins/login/blueprints.yaml index ab7cc36..3a3ae2a 100644 --- a/plugins/login/blueprints.yaml +++ b/plugins/login/blueprints.yaml @@ -1,7 +1,7 @@ name: Login slug: login type: plugin -version: 3.7.2 +version: 3.7.3 testing: false description: Enables user authentication and login screen. icon: sign-in diff --git a/plugins/login/login.php b/plugins/login/login.php index da908fa..54a6d74 100644 --- a/plugins/login/login.php +++ b/plugins/login/login.php @@ -337,7 +337,7 @@ class LoginPlugin extends Plugin if ($page) { $header = $page->header(); - $allowed = ($header->login_redirect_here ?? true) === false; + $allowed = ($header->login_redirect_here ?? true) === true; if ($allowed && $page->routable()) { $redirect = $page->route(); foreach ($uri->params(null, true) as $key => $value) {