Skip to content

Commit

Permalink
add comments in static pages files
Browse files Browse the repository at this point in the history
  • Loading branch information
tanveer65 committed Feb 28, 2024
2 parents aa2b68e + bf976af commit 48d5c4b
Show file tree
Hide file tree
Showing 9 changed files with 40 additions and 18 deletions.
9 changes: 5 additions & 4 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Indigo, a cool blue theme for Open edX
======================================

Indigo is an elegant, customizable theme for `Open edX <https://open.edx.org>`__.
Indigo is an elegant, customizable theme for `Open edX <https://openedx.org>`__.

.. image:: ./screenshots/01-landing-page.png
:alt: Platform landing page
Expand Down Expand Up @@ -29,11 +29,10 @@ Configuration
- ``INDIGO_WELCOME_MESSAGE`` (default: "The place for all your online learning")
- ``INDIGO_PRIMARY_COLOR`` (default: "#3b85ff")
- ``INDIGO_FOOTER_NAV_LINKS`` (default: ``[{"title": "About", "url": "/about"}, {"title": "Contact", "url": "/contact"}]``)
- ``INDIGO_FOOTER_LEGAL_LINKS`` (default: ``[{"title": "Terms of service", "url": "/tos"}, {"title": "Indigo theme for Open edX", "url": "https://github.com/overhangio/tutor-indigo"}]``)

The ``INDIGO_*`` settings listed above may be modified by running ``tutor config save --set INDIGO_...=...``. For instance, to remove all links from the footer, run::

tutor config save --set "INDIGO_FOOTER_NAV_LINKS=[]" --set "INDIGO_FOOTER_LEGAL_LINKS=[]"
tutor config save --set "INDIGO_FOOTER_NAV_LINKS=[]"

Or, to set the primary color to forest green, run::

Expand Down Expand Up @@ -80,7 +79,9 @@ The static templates used by Open edX to render those pages are all stored in th

ls tutorindigo/templates/indigo/lms/templates/static_templates"

For instance, edit the "donate.html" file in this directory. We can derive the content of this file from the contents of the `donate.html <https://github.com/edx/edx-platform/blob/open-release/quince.master/lms/templates/static_templates/donate.html>`__ static template in edx-platform::
For instance, edit the "donate.html" file in this directory. We can derive the content of this file from the contents of the `donate.html <https://github.com/edx/edx-platform/blob/open-release/quince.master/lms/templates/static_templates/donate.html>`__ static template in edx-platform:

.. code-block:: mako
<%page expression_filter="h"/>
<%! from django.utils.translation import ugettext as _ %>
Expand Down
13 changes: 13 additions & 0 deletions changelog.d/20240219_134558_misilot_issue_67.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@

<!--
Create a changelog entry for every new user-facing change. Please respect the following instructions:
- Indicate breaking changes by prepending an explosion 💥 character.
- Prefix your changes with either [Bugfix], [Improvement], [Feature], [Security], [Deprecation].
- You may optionally append "(by @<author>)" at the end of the line, where "<author>" is either one (just one)
of your GitHub username, real name or affiliated organization. These affiliations will be displayed in
the release notes for every release.
-->

<!-- - 💥[Feature] Foobarize the blorginator. This breaks plugins by renaming the `FOO_DO` filter to `BAR_DO`. (by @regisb) -->
<!-- - [Improvement] This is a non-breaking change. Life is good. (by @billgates) -->
- 💥[Improvement] Allow the no_course_image.png image to pull from the current theme, not specifically named indigo (by @misilot)
13 changes: 13 additions & 0 deletions changelog.d/20240220_091010_misilot_remove_legal_links_mentions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@

<!--
Create a changelog entry for every new user-facing change. Please respect the following instructions:
- Indicate breaking changes by prepending an explosion 💥 character.
- Prefix your changes with either [Bugfix], [Improvement], [Feature], [Security], [Deprecation].
- You may optionally append "(by @<author>)" at the end of the line, where "<author>" is either one (just one)
of your GitHub username, real name or affiliated organization. These affiliations will be displayed in
the release notes for every release.
-->

<!-- - 💥[Feature] Foobarize the blorginator. This breaks plugins by renaming the `FOO_DO` filter to `BAR_DO`. (by @regisb) -->
<!-- - [Improvement] This is a non-breaking change. Life is good. (by @billgates) -->
- [Improvement] Remove mentions of INDIGO_FOOTER_LEGAL_LINKS in docs since it is no longer used by the plugin. (by @misilot)
1 change: 1 addition & 0 deletions changelog.d/20240227_192724_hina.khadim_indigo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- [Improvement] Style static pages of About, Contact, Privacy and bookmarks page (by @tanveer65)
Binary file modified screenshots/01-landing-page.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 1 addition & 8 deletions tutorindigo/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"PRIMARY_COLOR": "#3b85ff", # cool blue
# Footer links are dictionaries with a "title" and "url"
# To remove all links, run:
# tutor config save --set INDIGO_FOOTER_NAV_LINKS=[] --set INDIGO_FOOTER_LEGAL_LINKS=[]
# tutor config save --set INDIGO_FOOTER_NAV_LINKS=[]
"FOOTER_NAV_LINKS": [
{"title": "About Us", "url": "/about"},
{"title": "Blog", "url": "/blog"},
Expand All @@ -33,13 +33,6 @@
{"title": "Help", "url": "/help"},
{"title": "Contact Us", "url": "/contact"},
],
"FOOTER_LEGAL_LINKS": [
{"title": "Terms of service", "url": "/tos"},
{
"title": "Indigo theme for Open edX",
"url": "https://github.com/overhangio/tutor-indigo",
},
],
},
"unique": {},
"overrides": {},
Expand Down
2 changes: 1 addition & 1 deletion tutorindigo/templates/indigo/lms/templates/course.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<article class="course" id="${course.id}" role="region" aria-label="${course.display_name_with_default}">
<header class="course-image">
<div class="cover-image">
<img src="${course.course_image_url}" onerror="this.src='/static/indigo/images/no_course_image.png';" alt="${course.display_name_with_default} ${course.display_number_with_default}" />
<img src="${course.course_image_url}" onerror="this.src='/theming/asset/images/no_course_image.png';" alt="${course.display_name_with_default} ${course.display_number_with_default}" />
</div>
</header>
<div class="course-info" aria-hidden="true">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<article class="course" role="region" aria-label="<%- content.display_name %>">
<header class="course-image">
<div class="cover-image">
<img src="<%- image_url %>" onerror="this.src='/static/indigo/images/no_course_image.png';" alt="<%- content.display_name %> <%- content.number %>" />
<img src="<%- image_url %>" onerror="this.src='/theming/asset/images/no_course_image.png';" alt="<%- content.display_name %> <%- content.number %>" />
</div>
</header>
<section class="course-info" aria-hidden="true">
Expand Down
9 changes: 5 additions & 4 deletions tutorindigo/templates/indigo/lms/templates/footer.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## mako
<%page expression_filter="h"/>
<%!
from datetime import datetime
from django.urls import reverse
from django.utils.translation import gettext as _
from lms.djangoapps.branding.api import get_footer
Expand Down Expand Up @@ -30,7 +31,7 @@
<ul class="logo-list">
<li>Powered by:</li>
<li>
<a href="https://docs.tutor.overhang.io" rel="noopener" target="_blank">
<a href="https://docs.tutor.edly.io" rel="noopener" target="_blank">
<img src="${static.url('images/tutor-logo.png')}" alt="Runs on Tutor" width="57" />
</a>
</li>
Expand All @@ -52,7 +53,7 @@
</ol>
</nav>
</div>
<span class="copyright-site">Copyrights ©2023. All Rights Reserved.</span>
<span class="copyright-site">Copyrights ©${datetime.now().year}. All Rights Reserved.</span>
% endif
<div class="colophon">

Expand Down Expand Up @@ -94,7 +95,7 @@
<ul class="logo-list">
<li>Powered by:</li>
<li>
<a href="https://docs.tutor.overhang.io" rel="noopener" target="_blank">
<a href="https://docs.tutor.edly.io" rel="noopener" target="_blank">
<img src="${static.url('images/tutor-logo.png')}" alt="Runs on Tutor" width="57" />
</a>
</li>
Expand All @@ -116,7 +117,7 @@
</ol>
</nav>
</div>
<span class="copyright-site">Copyrights ©2023. All Rights Reserved.</span>
<span class="copyright-site">Copyrights ©${datetime.now().year}. All Rights Reserved.</span>
% endif
<div class="colophon">

Expand Down

0 comments on commit 48d5c4b

Please sign in to comment.