Skip to content

Commit 9f4d82f

Browse files
Merge pull request #36 from edx/sundar/new-course-outline
Added `isPreview` key to `outline` API
2 parents 7123ab7 + 47d4910 commit 9f4d82f

3 files changed

Lines changed: 3 additions & 0 deletions

File tree

src/course-home/data/__snapshots__/redux.test.js.snap

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,7 @@ exports[`Data layer integration tests Test fetchOutlineTab Should fetch, normali
528528
"hideFromTOC": undefined,
529529
"icon": null,
530530
"id": "block-v1:edX+DemoX+Demo_Course+type@sequential+block@bcdabcdabcdabcdabcdabcdabcdabcd1",
531+
"isPreview": false,
531532
"navigationDisabled": undefined,
532533
"sectionId": "block-v1:edX+DemoX+Demo_Course+type@chapter+block@bcdabcdabcdabcdabcdabcdabcdabcd2",
533534
"showLink": true,

src/course-home/data/api.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,7 @@ export function normalizeOutlineBlocks(courseId, blocks) {
155155
title: block.display_name,
156156
hideFromTOC: block.hide_from_toc,
157157
navigationDisabled: block.navigation_disabled,
158+
isPreview: block.is_preview,
158159
};
159160
break;
160161

src/shared/data/__factories__/courseBlocks.factory.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ export function buildMinimalCourseBlocks(courseId, title, options = {}) {
116116
effort_activities: 2,
117117
effort_time: 15,
118118
type: 'sequential',
119+
is_preview: false,
119120
},
120121
{ courseId },
121122
)];

0 commit comments

Comments
 (0)