Skip to content

Commit 89842e5

Browse files
committed
refactor: update whitelabeling and CSS styles
- Added a new wrapper class for the logo to center it - Updated the main logo CSS to allow for responsive sizing. - Revert the use of whitelabel custom css
1 parent 2a93ca1 commit 89842e5

File tree

4 files changed

+15
-7
lines changed

4 files changed

+15
-7
lines changed

docker-app/qfieldcloud/core/staticfiles/css/qfieldcloud.css

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,19 @@ h1, h2, h3, h4, h5, h6 {
4040
margin-left: 1rem;
4141
}
4242

43+
.qfc-logo-wrapper {
44+
display: flex;
45+
justify-content: center;
46+
align-items: center;
47+
min-height: 15rem;
48+
padding: 1rem 0;
49+
}
50+
4351
.qfc-main-logo {
44-
height: 15rem;
52+
max-width: 100%;
53+
max-height: 15rem;
54+
width: auto;
55+
height: auto;
4556
}
4657

4758
.ml-5rem {

docker-app/qfieldcloud/core/templates/account/base.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<meta name="color-scheme" content="dark light">
99

1010
{% sri_static 'css/vendor.css' %}
11-
{% sri_static whitelabel.custom_css %}
11+
{% sri_static 'css/qfieldcloud.css' %}
1212
<link rel="shortcut icon" type="image/x-icon" href="{% static whitelabel.favicon %}" />
1313

1414
<title>
@@ -37,9 +37,9 @@
3737
<div class="flex-shrink-0 col-12">
3838
<div class="row">
3939
<div class="col-lg-6 offset-lg-3">
40-
<p class="text-center">
40+
<div class="qfc-logo-wrapper">
4141
<img src="{% static whitelabel.logo_main %}" alt="{{ whitelabel.logo_alt }}" class="qfc-main-logo">
42-
</p>
42+
</div>
4343

4444
{% block content %}{% endblock content %}
4545

docker-app/qfieldcloud/core/whitelabel.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
"logo_navbar": "logo_sidetext_white.svg",
1414
"logo_main": "logo_undertext.svg",
1515
"favicon": "favicon.ico",
16-
# Styling
17-
"custom_css": "css/qfieldcloud.css",
1816
}
1917

2018

docker-app/qfieldcloud/settings.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -881,5 +881,4 @@ def before_send(event, hint):
881881
# "logo_main": "path/to/logo_main.svg",
882882
# "logo_alt": "Your logo description",
883883
# "favicon": "path/to/favicon.ico",
884-
# "custom_css": "path/to/custom.css",
885884
# }

0 commit comments

Comments
 (0)