-
Notifications
You must be signed in to change notification settings - Fork 331
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
188cb63
commit 7460cd1
Showing
7 changed files
with
199 additions
and
3 deletions.
There are no files selected for viewing
2 changes: 2 additions & 0 deletions
2
changelog.d/20240220_174954_talharizwan667_indigo_cms_scss.md
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,2 @@ | ||
- [Bugfix] *.scss files in cms directory were not rendered in the tutor environment because they are stored in a "partials" subdirectory. (by @Talha-Rizwan) | ||
- [Improvement] added a customizable footer with styling as no custom footer was there for cms but for lms. (by @Talha-Rizwan) |
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
4 changes: 4 additions & 0 deletions
4
tutorindigo/templates/indigo/cms/static/sass/partials/cms/theme/_extras.scss
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,4 @@ | ||
/////////////////// General | ||
|
||
@import './fonts'; | ||
@import './footer'; |
1 change: 1 addition & 0 deletions
1
tutorindigo/templates/indigo/cms/static/sass/partials/cms/theme/_fonts.scss
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 @@ | ||
@import url('https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;600;700&family=Ubuntu:wght@400;500;700&display=swap'); |
104 changes: 104 additions & 0 deletions
104
tutorindigo/templates/indigo/cms/static/sass/partials/cms/theme/_footer.scss
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,104 @@ | ||
.wrapper-view { | ||
background: #fff; | ||
padding-bottom: 340px; | ||
position: relative; | ||
min-height: 100vh; | ||
|
||
@include media-breakpoint-up(sm) { | ||
padding-bottom: 280px; | ||
} | ||
} | ||
|
||
.wrapper-footer { | ||
background: $footer-bg; | ||
box-sizing: border-box; | ||
padding: 0; | ||
color: #fff; | ||
position: absolute; | ||
left: 0; | ||
bottom: 0; | ||
width: 100%; | ||
|
||
.footer-main { | ||
padding: 25px $baseline 30px; | ||
} | ||
|
||
footer { | ||
.wrapper-logo { | ||
|
||
a { | ||
|
||
img { | ||
height: 42px; | ||
} | ||
} | ||
} | ||
|
||
.nav-colophon { | ||
a { | ||
color: #fff; | ||
|
||
&:hover { | ||
color: $primary; | ||
} | ||
} | ||
} | ||
} | ||
|
||
.nav-colophon { | ||
line-height: 1.5; | ||
|
||
h3 { | ||
font-size: 20px; | ||
font-weight: bold; | ||
margin-bottom: 0.5rem; | ||
} | ||
|
||
ul { | ||
padding-left: 40px; | ||
list-style: disc; | ||
} | ||
} | ||
|
||
.footer-copyright { | ||
background: #fff; | ||
padding: 16px 10px; | ||
color: $primary; | ||
|
||
p { | ||
margin: 0; | ||
} | ||
} | ||
|
||
*, | ||
*:before, | ||
*:after { box-sizing: border-box; } | ||
|
||
a, | ||
h3 { | ||
color: #fff; | ||
} | ||
|
||
a { | ||
&:hover { | ||
color: $primary; | ||
} | ||
} | ||
|
||
.description { | ||
max-width: 550px; | ||
line-height: 1.5; | ||
} | ||
} | ||
|
||
.footer-container { | ||
max-width: 1600px; | ||
margin: 0 auto; | ||
overflow: hidden; | ||
|
||
|
||
.footer-col { | ||
float: left; | ||
width: 50%; | ||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
tutorindigo/templates/indigo/cms/static/sass/partials/cms/theme/_variables.scss
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,16 @@ | ||
$primary: #109dc2; | ||
$footer-bg: #333; | ||
$blue: $primary; | ||
|
||
// Theme fonts | ||
$font-family-title: Plex; | ||
$serif: Crimson; | ||
$f-sans-serif: Crimson, 'Open Sans','Helvetica Neue', Helvetica, Arial, sans-serif; | ||
|
||
$content_padding_top: 24px; | ||
$content-padding-bottom: 10px; | ||
$header-height: 75px; | ||
$footer-height: 125.5px; | ||
|
||
// Initialize the Open edX Bootstrap theme | ||
@import 'edx-bootstrap/sass/open-edx/theme'; |
66 changes: 66 additions & 0 deletions
66
tutorindigo/templates/indigo/cms/templates/widgets/footer.html
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,66 @@ | ||
## mako | ||
<%page expression_filter="h"/> | ||
<%! | ||
from django.utils.translation import gettext as _ | ||
from django.urls import reverse | ||
from datetime import datetime | ||
from django.conf import settings | ||
import pytz | ||
from cms.djangoapps.contentstore.config.waffle import ENABLE_ACCESSIBILITY_POLICY_PAGE | ||
from openedx.core.djangolib.markup import HTML, Text | ||
%> | ||
<% icp_license_info = getattr(settings, 'ICP_LICENSE_INFO', {})%> | ||
<%namespace name='static' file='../static_content.html'/> | ||
|
||
<div class="wrapper-footer wrapper"> | ||
<footer role="contentinfo"> | ||
<div class="footer-container footer-main"> | ||
<div class="footer-col"> | ||
<div class="wrapper-logo"> | ||
<p> | ||
<a href="https://docs.tutor.edly.io" rel="noopener" target="_blank"> | ||
<img src="${static.url('images/studio-logo.png')}" alt="Runs on Tutor" width="140" /> | ||
</a> | ||
</p> | ||
</div> | ||
<div class="description"> | ||
<p>studio footer text</p> | ||
</div> | ||
</div> | ||
<div class="footer-col"> | ||
{% if INDIGO_FOOTER_NAV_LINKS %} | ||
<nav class="nav-colophon" aria-label="${_('About')}"> | ||
<h3>Discover us</h3> | ||
<ul> | ||
<!-- uncomment this to add custom footer links | ||
{% for link in INDIGO_FOOTER_NAV_LINKS %} | ||
<li> | ||
<a href="{{ link['url'] }}">{{ link['title'] }}</a> | ||
</li> | ||
{% endfor %} --> | ||
<li> | ||
<a id="lms-link" href="${settings.LMS_ROOT_URL}">${_("LMS")}</a> | ||
</li> | ||
</ul> | ||
</nav> | ||
{% endif %} | ||
</div> | ||
</div> | ||
<div class="footer-copyright"> | ||
<div class="footer-container"> | ||
<p>© copyright</p> | ||
</div> | ||
</div> | ||
</footer> | ||
</div> | ||
% if include_dependencies: | ||
<%static:js group='base_vendor'/> | ||
<%static:css group='style-vendor'/> | ||
<%include file="widgets/segment-io.html" /> | ||
<%include file="widgets/segment-io-footer.html" /> | ||
% endif | ||
% if footer_css_urls: | ||
% for url in footer_css_urls: | ||
<link rel="stylesheet" type="text/css" href="${url}"></link> | ||
% endfor | ||
% endif |