Part of MDL-55611 epic.
Example context (json):
{
- "enddate": "Nov 4th, 10am",
"name": "Assignment due 1",
"url": "https://www.google.com",
+ "timesort": 1490320388,
"action": {
"name": "Submit assignment",
"url": "https://www.google.com",
"itemcount": 1,
- "showitemcount": true
+ "showitemcount": true,
+ "actionable": true
},
"icon": {
"key": "icon",
{
"events": [
{
- "enddate": "Nov 4th, 10am",
"name": "Assignment due 1",
"url": "https://www.google.com",
+ "timesort": 1490320388,
"action": {
"name": "Submit assignment",
"url": "https://www.google.com",
- "itemcount": 1
+ "itemcount": 1,
+ "actionable": true
},
"icon": {
"key": "icon",
}
},
{
- "enddate": "Nov 4th, 10am",
"name": "Assignment due 2",
"url": "https://www.google.com",
+ "timesort": 1490320388,
"action": {
"name": "Submit assignment",
"url": "https://www.google.com",
- "itemcount": 1
+ "itemcount": 1,
+ "actionable": true
},
"icon": {
"key": "icon",
{
"shortname": "course 3",
"viewurl": "https://www.google.com",
- "startdate": "Nov 1th, 10am",
- "enddate": "Nov 4th, 10am",
+ "startdate": 1490320388,
+ "enddate": 1490320388,
"summary": "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
}
}}
{{!
@template block_myoverview/course-paging-content-item
- This template renders the each course block containing a summary and calendar events.
+ This template renders each course block.
Example context (json):
{
+ "page": 1,
+ "active": true,
+ "courses": [
+ {
+ "fullnamedisplay": "course 1",
+ "viewurl": "https://www.google.com",
+ "startdate": 1490252232,
+ "enddate": 1490252232,
+ "summary": "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
+ },
+ {
+ "fullnamedisplay": "course 2",
+ "viewurl": "https://www.google.com",
+ "startdate": 1490252232,
+ "enddate": 1490252232,
+ "summary": "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
+ }
+ ]
}
}}
{{< block_myoverview/paging-content-item }}
+ {{$classes}}row{{/classes}}
{{$content}}
{{#courses}}
{{> block_myoverview/courses-view-course-item }}
along with Moodle. If not, see <http://www.gnu.org/licenses/>.
}}
{{!
- @template block_myoverview/paging-bar
+ @template block_myoverview/course-paging-content
This template renders the each course block containing a summary and calendar events.
Example context (json):
{
+ "pages": [
+ {
+ "page": 1,
+ "active": true,
+ "courses": [
+ {
+ "fullnamedisplay": "course 1",
+ "viewurl": "https://www.google.com",
+ "startdate": 1490252232,
+ "enddate": 1490252232,
+ "summary": "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
+ },
+ {
+ "fullnamedisplay": "course 2",
+ "viewurl": "https://www.google.com",
+ "startdate": 1490252232,
+ "enddate": 1490252232,
+ "summary": "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
+ }
+ ]
+ }
+ ]
}
}}
{{< block_myoverview/paging-content }}
Example context (json):
{
- "shortname": "course 3",
+ "fullnamedisplay": "course 3",
"viewurl": "https://www.google.com",
- "startdate": "Nov 1th, 10am",
- "enddate": "Nov 4th, 10am",
+ "startdate": 1490320388,
+ "enddate": 1490320388,
"summary": "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
}
}}
along with Moodle. If not, see <http://www.gnu.org/licenses/>.
}}
{{!
- @template block_myoverview/course-view-course-item
+ @template block_myoverview/courses-view-course-item
This template renders the course summary (view by courses) for the myoverview block.
Example context (json):
{
- "shortname": "course 3",
+ "fullnamedisplay": "course 3",
"viewurl": "https://www.google.com",
- "startdate": "Nov 1th, 10am",
- "enddate": "Nov 4th, 10am",
+ "startdate": 1490252232,
+ "enddate": 1490252232,
"summary": "It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout."
}
}}
Example context (json):
{
- "enddate": "Nov 4th, 10am",
"name": "Assignment due 1",
"url": "https://www.google.com",
+ "timesort": 1490320388,
"course": {
- "fullname": "Course 1"
+ "fullnamedisplay": "Course 1"
},
"action": {
"name": "Submit assignment",
"url": "https://www.google.com",
"itemcount": 1,
- "showitemcount": true
+ "showitemcount": true,
+ "actionable": true
},
"icon": {
"key": "icon",
{
"events": [
{
- "enddate": "Nov 4th, 10am",
"name": "Assignment due 1",
"url": "https://www.google.com",
+ "timesort": 1490320388,
"course": {
- "fullname": "Course 1"
+ "fullnamedisplay": "Course 1"
},
"action": {
"name": "Submit assignment",
"url": "https://www.google.com",
- "itemcount": 1
+ "itemcount": 1,
+ "actionable": true
},
"icon": {
"key": "icon",
}
},
{
- "enddate": "Nov 4th, 10am",
"name": "Assignment due 2",
"url": "https://www.google.com",
+ "timesort": 1490320388,
"course": {
- "fullname": "Course 1"
+ "fullnamedisplay": "Course 1"
},
"action": {
"name": "Submit assignment",
"url": "https://www.google.com",
- "itemcount": 1
+ "itemcount": 1,
+ "actionable": true
},
"icon": {
"key": "icon",
{{!
@template block_myoverview/paging-content-item
- This template renders the each course block containing a summary and calendar events.
+ This template renders the content of a page. It is to be used with
+ the paging bar to toggle visibility of the content items.
Example context (json):
{
+ "active": true,
+ "page": 1,
+ "content": "<p>Some page content</p>"
}
}}
<div data-region="paging-content-item"
data-page="{{page}}"
- class="{{#active}}active{{/active}}{{^active}}hidden{{/active}}">
+ class="{{^active}}hidden{{/active}} {{$classes}}{{/classes}}">
{{$content}}
{{{content}}}
{{/content}}
{{!
@template block_myoverview/paging-content
- This template renders the each course block containing a summary and calendar events.
+ This template renders each of the content regions for a paginated
+ content section.
Example context (json):
{
+ "pages": [
+ {
+ "active": true,
+ "page": 1,
+ "content": "<p>Some page content</p>"
+ },
+ {
+ "page": 2,
+ "content": "<p>Some page content</p>"
+ }
+ ]
}
}}
<div id="{{$pagingcontentid}}paging-content-{{uniqid}}{{/pagingcontentid}}" data-region="paging-content">
/*rtl:ignore*/
left: 50%;
margin: 0;
- transform: translate(-45%, -45%);
+ transform: translate(-48%, -50%);
color: #fff;
- height: ($chart-size / 2);
- width: ($chart-size / 2);
+ height: ($chart-size / 2) + 10px;
+ width: ($chart-size / 2) + 10px;
+ font-size: ($chart-size / 2) + 10px;
}
}
}