Display mcq and ucq corrections
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
parent
8acdf30ba4
commit
e0cd502c35
4 changed files with 54 additions and 14 deletions
|
|
@ -9,6 +9,7 @@
|
|||
export let kind = 'mcq';
|
||||
export let prefixid = '';
|
||||
export let readonly = false;
|
||||
export let corrections = {};
|
||||
export let id_question = 0;
|
||||
export let value;
|
||||
|
||||
|
|
@ -91,8 +92,11 @@
|
|||
class:form-check-label={!live}
|
||||
class:btn={live}
|
||||
class:btn-lg={live}
|
||||
class:btn-primary={live && value.indexOf(proposal.id.toString()) != -1}
|
||||
class:btn-outline-primary={live && value.indexOf(proposal.id.toString()) == -1}
|
||||
class:btn-primary={live && !corrections && value.indexOf(proposal.id.toString()) != -1}
|
||||
class:btn-outline-primary={live && !corrections && value.indexOf(proposal.id.toString()) == -1}
|
||||
class:btn-success={live && corrections && corrections[proposal.id] == 0}
|
||||
class:btn-outline-warning={live && corrections && corrections[proposal.id] != 0 && corrections[proposal.id] != -100}
|
||||
class:btn-outline-danger={live && corrections && corrections[proposal.id] == -100}
|
||||
for={prefixid + 'p' + proposal.id}
|
||||
>
|
||||
{proposal.label}
|
||||
|
|
|
|||
Reference in a new issue