Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions RELEASE.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
Release Notes
=============

Version 0.28.0
--------------

- Remove extra lines which were accidentally committed (#2023)
- Increase socket-timeout (#2010)
- Added redirect when visitors are using the herokuapp domain (#1998)
- Use HTML elements that are more semantic (#2003)
- Removed 'Clear all filters' link when user switch pages of unfiltered search (#1989)
- fixes a layout issue on the FAQ tab

Version 0.27.1
--------------

Expand Down
124 changes: 59 additions & 65 deletions cms/templates/cms/home_page.html
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@
{% include "header.html" %}

<div class="main-content-wrapper">
<section class="main-content">

<main>
<div class="banner-wrapper">
<div class="banner-wrapper-content">
<h1>
Expand All @@ -60,7 +59,7 @@ <h2>

<div class="row sub-banner">
<div class="col-md-12 ">
<div class="sub-banner-section">
<section class="sub-banner-section">
<div class="sub-banner-text">
<h3>What is the MicroMasters Credential?</h3>
<p>MicroMasters is a professional and academic credential for online learners from anywhere in the world. Learners who pass an integrated set of MITx graduate-level courses on edX.org, and one or more proctored exams, will earn a MicroMasters credential from MITx, and can then apply for an accelerated, on campus, master’s degree program at MIT or other top universities.</p>
Expand All @@ -71,49 +70,46 @@ <h3>What is the MicroMasters Credential?</h3>
<img src="{% static 'images/micromasters_logo.png' %}" alt="MITx" class="micromasters-logo">
</div>
</div>
</div>
</section>
</div>
</div>

<div class="row how-it-works-section">

<div class="centered-content">

<h3>How It Works</h3>
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw1.png' %}" alt="">
</div>
<section class="row how-it-works-section">
<div class="centered-content">
<h3>How It Works</h3>
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw1.png' %}" alt="">
</div>

<h4>Online Learning</h4>
<p>Take a series of online courses on edX, and pass all the course requirements.</p>
</div>
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw2.png' %}" alt="">
<h4>Online Learning</h4>
<p>Take a series of online courses on edX, and pass all the course requirements.</p>
</div>
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw2.png' %}" alt="">
</div>

<h4>Proctored Tests</h4>
<p>Pass one (or more) proctored exams—either a single final exam, or one exam for each course, depending on the program.</p>
<h4>Proctored Tests</h4>
<p>Pass one (or more) proctored exams—either a single final exam, or one exam for each course, depending on the program.</p>

</div>
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw3.png' %}" alt="">
</div>
<h4>Earn a Valuable Credential</h4>
<p>A MicroMasters credential from MITx proves that you’ve gained the knowledge and skills to give you a competitive advantage for career success.</p>
</div>
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw4.png' %}" alt="">
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw3.png' %}" alt="">
</div>
<h4>Earn a Valuable Credential</h4>
<p>A MicroMasters credential from MITx proves that you’ve gained the knowledge and skills to give you a competitive advantage for career success.</p>
</div>
<div class="hiw col-md-3">
<div class="reasons-images-wrap">
<img src="{% static 'images/hiw4.png' %}" alt="">
</div>
<h4>Pursue a Master’s</h4>
<p>Learners who complete the MicroMasters program can apply for the Master’s degree program at MIT or other universities.</p>
</div>
<h4>Pursue a Master’s</h4>
<p>Learners who complete the MicroMasters program can apply for the Master’s degree program at MIT or other universities.</p>
</div>
</div>

</div>
</section>
<section class="row current-programs-section">
<h3>Current MITx MicroMasters Programs</h3>
<ul class="current-programs-list">
Expand Down Expand Up @@ -185,38 +181,35 @@ <h4 class="program-title" aria-describedby="program-{{ program.id }}-description
</ul>
</section>

<div class="row reasons-section">

<div class="centered-content">

<h3>Why should I enroll?</h3>
<div class="enroll-reason col-md-4">
<div class="reasons-images-wrap">
<img src="{% static 'images/online.png' %}" alt="">
</div>
<section class="row reasons-section">
<div class="centered-content">
<h3>Why should I enroll?</h3>
<div class="enroll-reason col-md-4">
<div class="reasons-images-wrap">
<img src="{% static 'images/online.png' %}" alt="">
</div>

<h4>Convenient &amp; Flexible</h4>
<p>Take online courses on a schedule that fits your needs, and meet motivated learners who share your interests.</p>
</div>
<div class="enroll-reason col-md-4">
<div class="reasons-images-wrap">
<img src="{% static 'images/blended.png' %}" alt="">
<h4>Convenient &amp; Flexible</h4>
<p>Take online courses on a schedule that fits your needs, and meet motivated learners who share your interests.</p>
</div>
<div class="enroll-reason col-md-4">
<div class="reasons-images-wrap">
<img src="{% static 'images/blended.png' %}" alt="">
</div>

<h4>Accelerate Your Master’s</h4>
<p>MicroMasters is a faster path to a master’s degree from MIT and other universities, and is recognized by employers for providing deep learning in specific career fields.</p>
<h4>Accelerate Your Master’s</h4>
<p>MicroMasters is a faster path to a master’s degree from MIT and other universities, and is recognized by employers for providing deep learning in specific career fields.</p>

</div>
<div class="enroll-reason col-md-4">
<div class="reasons-images-wrap">
<img src="{% static 'images/cost.png' %}" alt="">
</div>
<h4>Save Money &amp; Time</h4>
<p>MicroMasters is an affordable option for professionals who can’t take off time to earn a traditional master’s degree.</p>
</div>
<div class="enroll-reason col-md-4">
<div class="reasons-images-wrap">
<img src="{% static 'images/cost.png' %}" alt="">
</div>
<h4>Save Money &amp; Time</h4>
<p>MicroMasters is an affordable option for professionals who can’t take off time to earn a traditional master’s degree.</p>
</div>
</div>

</div>
</section>

<section class="quote-section">
<div class="row quote">
Expand All @@ -231,13 +224,14 @@ <h4>Save Money &amp; Time</h4>
</div>
</section>

</section>
</main>
</div>

{% include "footer.html" %}

<div class="modal fade modal-fade-in-scale-up" id="modal-about" aria-hidden="true" aria-labelledby="modal-about"
role="dialog" tabindex="-1">
<div class="modal fade modal-fade-in-scale-up" id="modal-about"
aria-hidden="true" aria-labelledby="modal-about"
role="dialog" tabindex="-1">
<div class="modal-dialog modal-center">
<div class="modal-content">
<div class="modal-header">
Expand Down
12 changes: 6 additions & 6 deletions cms/templates/cms/program_page.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
{% block body_class %}template-programpage{% endblock %}
{% block content %}
{% include "header.html" %}
<div class="page-content program-page">
<main class="page-content program-page">
{% image page.background_image fill-1310x613 as background_image %}
<div class="hero-image" style="background-image: url({{ background_image.url }})">
<!-- big image, and sign-up links, etc -->
Expand Down Expand Up @@ -91,7 +91,7 @@ <h3 class="title">
</div>
</div>
{% if page.program_home_page_url or page.program_contact_email or page.info_links.exists %}
<div class="info-box contact-info">
<section class="info-box contact-info">
<h3 class="title">
More Info
</h3>
Expand Down Expand Up @@ -124,7 +124,7 @@ <h3 class="title">
</p>
{% endif %}
</div>
</div>
</section>
{% endif %}
<div class="powered-by">
<p>
Expand All @@ -137,7 +137,7 @@ <h3 class="title">
</div>

{% if page.faculty_members.count > 0 %}
<div class="faculty-section mdl-grid mdl-grid--no-spacing">
<section class="faculty-section mdl-grid mdl-grid--no-spacing">
<div class="mdl-cell mdl-cell--12-col">
<h3 class="title">Instructors</h3>
{% if page.faculty_description|length > 0 %}
Expand All @@ -147,10 +147,10 @@ <h3 class="title">Instructors</h3>
<div id="faculty-carousel" class="mdl-cell--12-col">
<!-- React-Slick carousel component injected here -->
</div>
</div>
</section>
{% endif %}

</div>
</main>
{% include "footer.html" %}
<div id="signup-dialog">
<!-- signup dialog React component injected here -->
Expand Down
2 changes: 1 addition & 1 deletion micromasters/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
from django.core.exceptions import ImproperlyConfigured


VERSION = "0.27.1"
VERSION = "0.28.0"

CONFIG_PATHS = [
os.environ.get('MICROMASTERS_CONFIG', ''),
Expand Down
13 changes: 10 additions & 3 deletions static/js/components/search/CustomResetFiltersDisplay.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// @flow
import React from 'react';
import {
ResetFiltersDisplay,
SearchkitComponent,
FastClick
} from 'searchkit';

export default class CustomResetFiltersDisplay extends ResetFiltersDisplay {
export default class CustomResetFiltersDisplay extends SearchkitComponent {
props: {
bemBlock: any,
hasFilters: boolean,
Expand All @@ -21,7 +21,14 @@ export default class CustomResetFiltersDisplay extends ResetFiltersDisplay {
clearAllLabel
} = this.props;

if (hasFilters) {
let hasFiltersOtherThanSelectedProgram = (
this.getQuery() &&
this.getQuery().index &&
this.getQuery().index.filters &&
this.getQuery().index.filters.length > 1
);

if (hasFilters && hasFiltersOtherThanSelectedProgram) {
return (
<div>
<FastClick handler={resetFilters}>
Expand Down
77 changes: 60 additions & 17 deletions static/js/components/search/CustomResetFiltersDisplay_test.js
Original file line number Diff line number Diff line change
@@ -1,34 +1,77 @@
// @flow
import React from 'react';
import _ from 'lodash';
import { shallow } from 'enzyme';
import { mount } from 'enzyme';
import sinon from 'sinon';
import { assert } from 'chai';
import { SearchkitManager, SearchkitProvider } from 'searchkit';

import CustomResetFiltersDisplay from './CustomResetFiltersDisplay';

describe('CustomResetFiltersDisplay', () => {
let props = {
clearAllLabel: "Clear all filters",
hasFilters: true,
resetFilters: () => {},
bemBlock: (): Object => {
return {
state: (): void => {}
};
}
};
let sandbox;
let searchKit;

it('renders reset filters link', () => {
const wrapper = shallow(<CustomResetFiltersDisplay {...props}/>);
beforeEach(() => {
searchKit = new SearchkitManager();
sandbox = sinon.sandbox.create();
});

afterEach(() => {
sandbox.restore();
});

let renderFilters = (props = {}) => (
mount(
<SearchkitProvider searchkit={searchKit}>
<CustomResetFiltersDisplay
clearAllLabel="Clear all filters"
hasFilters={true}
resetFilters={() => {}}
bemBlock={() => ({ state: () => {} })}
{...props}
/>
</SearchkitProvider>
)
);

it('renders reset filters link', () => {
sandbox.stub(CustomResetFiltersDisplay.prototype, 'getQuery').returns({
'index': {
'filters': [
"program filter",
"any other filter"
]
}
});
const wrapper = renderFilters();
assert.equal(wrapper.children().children().text(), 'Clear all filters');
});

it('reset filter link does not render when hasFilters is false', () => {
let noFilterProps = _.clone(props);
noFilterProps.hasFilters = false;
const wrapper = shallow(<CustomResetFiltersDisplay {...noFilterProps}/>);
sandbox.stub(CustomResetFiltersDisplay.prototype, 'getQuery').returns({
'index': {
'filters': [
"program filter",
"any other filter"
]
}
});
const wrapper = renderFilters({
hasFilters: false
});

assert.lengthOf(wrapper.children(), 0);
});

it('do not render when there is only program filter selected', () => {
sandbox.stub(CustomResetFiltersDisplay.prototype, 'getQuery').returns({
'index': {
'filters': [
"program filter"
]
}
});
const wrapper = renderFilters();
assert.lengthOf(wrapper.children(), 0);
});
});
Loading