Skip to content

Commit

Permalink
issue/175 Switched divs to span inside label (#180)
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverfoster authored Jun 27, 2022
1 parent a790b69 commit e25c5b9
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 15 deletions.
4 changes: 4 additions & 0 deletions less/mcq.less
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@
display: none;
}

&__text {
display: block;
}

// MCQ item icons
// --------------------------------------------------
&__answer-icon.is-radio .icon {
Expand Down
30 changes: 15 additions & 15 deletions templates/mcq.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -82,32 +82,32 @@ export default function Mcq(props) {
data-adapt-index={_index}
>

<div className='mcq-item__state'>
<div
<span className='mcq-item__state'>
<span
className={classes([
'mcq-item__icon',
'mcq-item__answer-icon',
_isRadio ? 'is-radio' : 'is-checkbox'
])}
>

<div className='icon'></div>
<span className='icon'></span>

</div>
</span>

<div className='mcq-item__icon mcq-item__correct-icon'>
<div className='icon'></div>
</div>
<span className='mcq-item__icon mcq-item__correct-icon'>
<span className='icon'></span>
</span>

<div className='mcq-item__icon mcq-item__incorrect-icon'>
<div className='icon'></div>
</div>
</div>
<span className='mcq-item__icon mcq-item__incorrect-icon'>
<span className='icon'></span>
</span>
</span>

<div className='mcq-item__text'>
<div className='mcq-item__text-inner' dangerouslySetInnerHTML={{ __html: compile(text) }}>
</div>
</div>
<span className='mcq-item__text'>
<span className='mcq-item__text-inner' dangerouslySetInnerHTML={{ __html: compile(text) }}>
</span>
</span>

</label>

Expand Down

0 comments on commit e25c5b9

Please sign in to comment.