From b5e4627e566a76ef9785ee4c1c4dc15d5460e4c2 Mon Sep 17 00:00:00 2001 From: Zach Smith Date: Thu, 2 Sep 2021 06:16:07 -0400 Subject: [PATCH 1/2] fix(tpl): switch login/signup to profile/logout when logged in --- html-templates/designs/site-bootstrap4.tpl | 32 +++++++++++++------ .../includes/site.nav-userlinks.tpl | 3 ++ 2 files changed, 25 insertions(+), 10 deletions(-) create mode 100644 html-templates/includes/site.nav-userlinks.tpl diff --git a/html-templates/designs/site-bootstrap4.tpl b/html-templates/designs/site-bootstrap4.tpl index ab1b6445..855fd0c6 100644 --- a/html-templates/designs/site-bootstrap4.tpl +++ b/html-templates/designs/site-bootstrap4.tpl @@ -1,4 +1,5 @@ +{load_templates designs/site.subtemplates.tpl} @@ -70,16 +71,27 @@ - - + {if $.User} + + {else} + + + {/if} diff --git a/html-templates/includes/site.nav-userlinks.tpl b/html-templates/includes/site.nav-userlinks.tpl new file mode 100644 index 00000000..d86f0adc --- /dev/null +++ b/html-templates/includes/site.nav-userlinks.tpl @@ -0,0 +1,3 @@ +{_ "View My Profile"} +{_ "Edit My Profile"} +{_ "Logout"} From f3d101aecf4f2d46974f3a124a94aa99d34911ce Mon Sep 17 00:00:00 2001 From: Zach Smith Date: Tue, 7 Sep 2021 05:48:08 -0400 Subject: [PATCH 2/2] fix(tpl): change prev commit to not override default nav-userlinks.tpl --- html-templates/designs/site-bootstrap4.tpl | 2 +- ...site.nav-userlinks.tpl => site-bootstrap4.nav-userlinks.tpl} | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename html-templates/includes/{site.nav-userlinks.tpl => site-bootstrap4.nav-userlinks.tpl} (100%) diff --git a/html-templates/designs/site-bootstrap4.tpl b/html-templates/designs/site-bootstrap4.tpl index 855fd0c6..f36c8fbc 100644 --- a/html-templates/designs/site-bootstrap4.tpl +++ b/html-templates/designs/site-bootstrap4.tpl @@ -77,7 +77,7 @@ {avatar $.User 18} {$.User->FirstName} {else} diff --git a/html-templates/includes/site.nav-userlinks.tpl b/html-templates/includes/site-bootstrap4.nav-userlinks.tpl similarity index 100% rename from html-templates/includes/site.nav-userlinks.tpl rename to html-templates/includes/site-bootstrap4.nav-userlinks.tpl