Add anonymous feedback option for open questions
Open questions can be marked private: the presenter screen and embeds only show the number of answers, participants never see results, and the texts are readable on a new admin answers page and in the CSV. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
07a292d109
commit
367ff8548d
14 files changed
+310
-12
No files matched your search
@@ -456,6 +456,15 @@ button.qa-steps__step { cursor: pointer; }
|
||||
button.qa-steps__step:hover:not(:disabled) { color: var(--text); border-color: var(--text); }
|
||||
.qa-steps .is-current .qa-steps__step { background: var(--qa); border-color: var(--qa); color: var(--surface); font-weight: 700; cursor: default; }
|
||||
|
||||
.private-summary { text-align: center; }
|
||||
.private-summary p { margin: 0 0 .3em; }
|
||||
.private-summary__count { font-size: 3em; font-weight: 800; line-height: 1; color: var(--c2); font-variant-numeric: tabular-nums; }
|
||||
.private-summary__hint { color: var(--muted); font-size: .85em; }
|
||||
.private-hint { margin-top: 8px; }
|
||||
.answers-page { list-style: none; padding: 0; margin: 0; }
|
||||
.answers-page li { padding: 12px 16px; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 8px; background: var(--surface); white-space: pre-line; overflow-wrap: anywhere; }
|
||||
.answers-page time { display: block; color: var(--muted); font-size: .8rem; margin-top: 4px; }
|
||||
|
||||
/* ---------------------------------------------------------------- presenter */
|
||||
/* Dark by default (beamer); the presenter's own switch can make it light (data-theme="light"). */
|
||||
body.present {
|
||||
|
||||
@@ -499,6 +499,15 @@
|
||||
},
|
||||
|
||||
open: function (results) {
|
||||
if (results.private) {
|
||||
// Anonymous feedback: the texts never reach the stage, only the count.
|
||||
var n = results.participants;
|
||||
return el('div', { class: 'private-summary' }, [
|
||||
el('p', { class: 'private-summary__count', text: String(n) }),
|
||||
el('p', { text: (n === 1 ? 'anonyme Antwort' : 'anonyme Antworten') + ' eingegangen' }),
|
||||
el('p', { class: 'private-summary__hint', text: '🔒 Antworten werden nicht öffentlich angezeigt.' })
|
||||
]);
|
||||
}
|
||||
return el('ul', { class: 'answers' }, results.answers.map(function (answer) {
|
||||
return el('li', { class: 'answer', text: answer.text });
|
||||
}));
|
||||
|
||||
Reference in new issue
Block a user