Skip to content

Commit f3e2062

Browse files
authored
Merge pull request #26 from 10gen/kk-add-feedback-310
Add open links to .toc__link--deluge
2 parents 78a2e80 + 5367809 commit f3e2062

File tree

8 files changed

+133
-8
lines changed

8 files changed

+133
-8
lines changed

themes/mongodb-tutorials/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"lunr": "^2.1.0",
2020
"react": "^15.4.2",
2121
"react-dom": "^15.4.2",
22-
"rigning-non-greni": "^3.0.2",
22+
"rigning-non-greni": "^3.1.0",
2323
"velocity-animate": "^1.5.0"
2424
},
2525
"devDependencies": {

themes/mongodb-tutorials/src/util.js

Lines changed: 6 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

themes/mongodb-tutorials/static/js/home.js

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23219,7 +23219,36 @@
2321923219
ratingPanelElement.innerText = '';
2322023220

2322123221
if (ratingPanelElement) {
23222-
new _rigningNonGreni.Deluge(project, pagename, ratingPanelElement).askFreeformQuestion('reason', 'What were you looking for?').askQuestion('findability', 'Did you find it?').askQuestion('accuracy', 'Was the information you found <strong>accurate</strong>?').askQuestion('clarity', 'Was the information <strong>clear</strong>?').askQuestion('fragmentation', 'Was the information you needed <strong>' + 'all on one page</strong>?');
23222+
var show = function show() {
23223+
deluge.open();
23224+
};
23225+
23226+
var deluge = new _rigningNonGreni.Deluge(project, pagename, ratingPanelElement).askFreeformQuestion('reason', 'What were you looking for?').askQuestion('findability', 'Did you find it?').askQuestion('accuracy', 'Was the information you found <strong>accurate</strong>?').askQuestion('clarity', 'Was the information <strong>clear</strong>?').askQuestion('fragmentation', 'Was the information you needed <strong>' + 'all on one page</strong>?');
23227+
23228+
var _iteratorNormalCompletion2 = true;
23229+
var _didIteratorError2 = false;
23230+
var _iteratorError2 = undefined;
23231+
23232+
try {
23233+
for (var _iterator2 = document.querySelectorAll('.toc__link--deluge')[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
23234+
var element = _step2.value;
23235+
23236+
element.addEventListener('click', show);
23237+
}
23238+
} catch (err) {
23239+
_didIteratorError2 = true;
23240+
_iteratorError2 = err;
23241+
} finally {
23242+
try {
23243+
if (!_iteratorNormalCompletion2 && _iterator2.return) {
23244+
_iterator2.return();
23245+
}
23246+
} finally {
23247+
if (_didIteratorError2) {
23248+
throw _iteratorError2;
23249+
}
23250+
}
23251+
}
2322323252
}
2322423253
},
2322523254

@@ -23382,6 +23411,11 @@
2338223411
img.src = url;
2338323412
});
2338423413
}
23414+
}, {
23415+
key: 'open',
23416+
value: function open() {
23417+
this.app.open();
23418+
}
2338523419
}]);
2338623420

2338723421
return Deluge;
@@ -23452,6 +23486,12 @@
2345223486
},
2345323487

2345423488
methods: {
23489+
open: function open() {
23490+
if (this.get('state') === 'Initial') {
23491+
this.set({ answers: {} });
23492+
this.set({ 'state': 'NotVoted' });
23493+
}
23494+
},
2345523495
toggle: function toggle() {
2345623496
this.set({ answers: {} });
2345723497

themes/mongodb-tutorials/static/js/home.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

themes/mongodb-tutorials/static/js/landing.js

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,36 @@
219219
ratingPanelElement.innerText = '';
220220

221221
if (ratingPanelElement) {
222-
new _rigningNonGreni.Deluge(project, pagename, ratingPanelElement).askFreeformQuestion('reason', 'What were you looking for?').askQuestion('findability', 'Did you find it?').askQuestion('accuracy', 'Was the information you found <strong>accurate</strong>?').askQuestion('clarity', 'Was the information <strong>clear</strong>?').askQuestion('fragmentation', 'Was the information you needed <strong>' + 'all on one page</strong>?');
222+
var show = function show() {
223+
deluge.open();
224+
};
225+
226+
var deluge = new _rigningNonGreni.Deluge(project, pagename, ratingPanelElement).askFreeformQuestion('reason', 'What were you looking for?').askQuestion('findability', 'Did you find it?').askQuestion('accuracy', 'Was the information you found <strong>accurate</strong>?').askQuestion('clarity', 'Was the information <strong>clear</strong>?').askQuestion('fragmentation', 'Was the information you needed <strong>' + 'all on one page</strong>?');
227+
228+
var _iteratorNormalCompletion2 = true;
229+
var _didIteratorError2 = false;
230+
var _iteratorError2 = undefined;
231+
232+
try {
233+
for (var _iterator2 = document.querySelectorAll('.toc__link--deluge')[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
234+
var element = _step2.value;
235+
236+
element.addEventListener('click', show);
237+
}
238+
} catch (err) {
239+
_didIteratorError2 = true;
240+
_iteratorError2 = err;
241+
} finally {
242+
try {
243+
if (!_iteratorNormalCompletion2 && _iterator2.return) {
244+
_iterator2.return();
245+
}
246+
} finally {
247+
if (_didIteratorError2) {
248+
throw _iteratorError2;
249+
}
250+
}
251+
}
223252
}
224253
},
225254

@@ -382,6 +411,11 @@
382411
img.src = url;
383412
});
384413
}
414+
}, {
415+
key: 'open',
416+
value: function open() {
417+
this.app.open();
418+
}
385419
}]);
386420

387421
return Deluge;
@@ -452,6 +486,12 @@
452486
},
453487

454488
methods: {
489+
open: function open() {
490+
if (this.get('state') === 'Initial') {
491+
this.set({ answers: {} });
492+
this.set({ 'state': 'NotVoted' });
493+
}
494+
},
455495
toggle: function toggle() {
456496
this.set({ answers: {} });
457497

themes/mongodb-tutorials/static/js/landing.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

themes/mongodb-tutorials/static/js/single.js

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,36 @@
214214
ratingPanelElement.innerText = '';
215215

216216
if (ratingPanelElement) {
217-
new _rigningNonGreni.Deluge(project, pagename, ratingPanelElement).askFreeformQuestion('reason', 'What were you looking for?').askQuestion('findability', 'Did you find it?').askQuestion('accuracy', 'Was the information you found <strong>accurate</strong>?').askQuestion('clarity', 'Was the information <strong>clear</strong>?').askQuestion('fragmentation', 'Was the information you needed <strong>' + 'all on one page</strong>?');
217+
var show = function show() {
218+
deluge.open();
219+
};
220+
221+
var deluge = new _rigningNonGreni.Deluge(project, pagename, ratingPanelElement).askFreeformQuestion('reason', 'What were you looking for?').askQuestion('findability', 'Did you find it?').askQuestion('accuracy', 'Was the information you found <strong>accurate</strong>?').askQuestion('clarity', 'Was the information <strong>clear</strong>?').askQuestion('fragmentation', 'Was the information you needed <strong>' + 'all on one page</strong>?');
222+
223+
var _iteratorNormalCompletion2 = true;
224+
var _didIteratorError2 = false;
225+
var _iteratorError2 = undefined;
226+
227+
try {
228+
for (var _iterator2 = document.querySelectorAll('.toc__link--deluge')[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
229+
var element = _step2.value;
230+
231+
element.addEventListener('click', show);
232+
}
233+
} catch (err) {
234+
_didIteratorError2 = true;
235+
_iteratorError2 = err;
236+
} finally {
237+
try {
238+
if (!_iteratorNormalCompletion2 && _iterator2.return) {
239+
_iterator2.return();
240+
}
241+
} finally {
242+
if (_didIteratorError2) {
243+
throw _iteratorError2;
244+
}
245+
}
246+
}
218247
}
219248
},
220249

@@ -377,6 +406,11 @@
377406
img.src = url;
378407
});
379408
}
409+
}, {
410+
key: 'open',
411+
value: function open() {
412+
this.app.open();
413+
}
380414
}]);
381415

382416
return Deluge;
@@ -447,6 +481,12 @@
447481
},
448482

449483
methods: {
484+
open: function open() {
485+
if (this.get('state') === 'Initial') {
486+
this.set({ answers: {} });
487+
this.set({ 'state': 'NotVoted' });
488+
}
489+
},
450490
toggle: function toggle() {
451491
this.set({ answers: {} });
452492

themes/mongodb-tutorials/static/js/single.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)