-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: better styles in customer portal
- Loading branch information
1 parent
c383888
commit 2a20610
Showing
3 changed files
with
79 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
.footer-logo-extension { | ||
display: none; | ||
} | ||
|
||
.footer-powered { | ||
display: none; | ||
} | ||
|
||
.portal-widget { | ||
/* position: absolute; */ | ||
top: 5px; | ||
right: 5px; | ||
bottom: 5px; | ||
left: 5px; | ||
border-radius: 5px; | ||
box-shadow: 0px 1px 2px rgba(25, 39, 52, 0.05), 0px 0px 4px rgba(25, 39, 52, 0.1); | ||
padding: 15px; | ||
margin: 5px; | ||
min-height: 60px; | ||
} | ||
|
||
.portal-widget-col { | ||
width: auto; | ||
min-width: 40%; | ||
} | ||
|
||
a.portal-widget-col { | ||
position: relative; | ||
text-decoration: none; | ||
} | ||
|
||
.portal-widget-col h5 { | ||
position: absolute; | ||
top: 23px; | ||
margin-left: 5px; | ||
display: inline; | ||
} | ||
|
||
.widget-row { | ||
margin-top: 10px; | ||
margin-bottom: 20px; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
{% extends "templates/web.html" %} | ||
|
||
{% block title %}{{ _("My Account") }}{% endblock %} | ||
{% block header %}<h1>{{ _("My Account") }}</h1>{% endblock %} | ||
|
||
{% block page_content %} | ||
|
||
<div class="row widget-row"> | ||
|
||
{% for item in sidebar_items -%} | ||
|
||
<a href="{{ item.route }}" class="col-sm-4 portal-widget-col"> | ||
<div class="portal-widget"> | ||
<div class="whitespace-nowrap"> | ||
<span class="indicator-pill whitespace-nowrap green"> | ||
</span> | ||
<h5>{{ _(item.title or item.label) }}</h5> | ||
</div> | ||
</div> | ||
</a> | ||
{%- endfor %} | ||
<a href="/update-password" class="col-sm-4 portal-widget-col"> | ||
<div class="portal-widget"> | ||
<h5>{{ _("Reset Password") }}</h5> | ||
</div> | ||
</a> | ||
</div> | ||
<!-- no-cache --> | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import frappe | ||
|
||
|
||
def get_context(context): | ||
if frappe.session.user == "Guest": | ||
frappe.throw(frappe._("You need to be logged in to access this page"), frappe.PermissionError) | ||
|
||
context.show_sidebar = True |