Skip to content

Commit

Permalink
Merge pull request #4347 from serlo/exercise-fixes
Browse files Browse the repository at this point in the history
quickfix: show exercise task again
  • Loading branch information
elbotho authored Dec 13, 2024
2 parents 8dc7eb5 + 5cb0ddd commit 0129a9b
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export function BlankCheckButton(props: BlankCheckButtonProps) {
const isCorrect = [...feedback].every((entry) => entry[1].isCorrect)

return (
<div className="mt-2 flex">
<div className="mx-side mt-5 flex">
<button
className="serlo-button-learner-primary mr-3 h-8"
onClick={onClick}
Expand Down
2 changes: 1 addition & 1 deletion packages/editor/src/plugins/blanks-exercise/renderer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ export function BlanksExerciseRenderer({
<DndWrapper>
<div
className={cn(
'mx-side mb-block',
'mb-block',
// Increase Slate line height in the editor
'[&>div>div>div[data-slate-node="element"]]:leading-[30px]',
// Increase Slate line height in the renderer
Expand Down
28 changes: 14 additions & 14 deletions packages/editor/src/plugins/exercise/editor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,22 +88,22 @@ export function ExerciseEditor(props: ExerciseProps) {
</div>
<div className="h-10"></div>
<div className="mx-side">
{/* Special case for the blanks exercise: Until the child plugin is selected we hide the task to avoid confusion */}
{/* Background: Users often add their blanks-text to the task */}
<div
className={cn(
'group-has-[.blanks-child-plugin-selection]/exercise:hidden',
'[&_.plugin-rows]:pl-[7px]'
)}
>
{content.render({
config: {
textPluginPlaceholder: exStrings.placeholder,
},
})}
</div>
{interactive.defined ? (
<>
{/* Special case for the blanks exercise: Until the child plugin is selected we hide the task to avoid confusion */}
{/* Background: Users often add their blanks-text to the task */}
<div
className={cn(
'group-has-[.blanks-child-plugin-selection]/exercise:hidden',
'[&_.plugin-rows]:pl-[7px]'
)}
>
{content.render({
config: {
textPluginPlaceholder: exStrings.placeholder,
},
})}
</div>
{interactive.render()}
{hideInteractiveInitially.defined ? (
<small className="bg-editor-primary-200 p-1">
Expand Down

0 comments on commit 0129a9b

Please sign in to comment.