Skip to content

Commit

Permalink
fix: solve conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
johnvente committed Dec 21, 2023
2 parents e029978 + 6945234 commit f471c5c
Show file tree
Hide file tree
Showing 57 changed files with 1,168 additions and 731 deletions.
82 changes: 41 additions & 41 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
"babel-polyfill": "6.26.0",
"codemirror": "^6.0.0",
"fast-xml-parser": "^4.0.10",
"frontend-components-tinymce-advanced-plugins": "^1.0.0",
"frontend-components-tinymce-advanced-plugins": "^1.0.2",
"lodash-es": "^4.17.21",
"moment": "^2.29.4",
"moment-shortformat": "^2.1.0",
Expand Down
6 changes: 4 additions & 2 deletions src/editors/Editor.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,11 @@ export const Editor = ({

const EditorComponent = supportedEditors[blockType];
return (
<div className="d-flex flex-column">
<div
className="d-flex flex-column"
>
<div
className="pgn__modal-fullscreen"
className="pgn__modal-fullscreen h-100"
role="dialog"
aria-label={blockType}
>
Expand Down
4 changes: 2 additions & 2 deletions src/editors/__snapshots__/Editor.test.jsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ exports[`Editor render presents error message if no relevant editor found and re
>
<div
aria-label="fAkEBlock"
className="pgn__modal-fullscreen"
className="pgn__modal-fullscreen h-100"
role="dialog"
>
<FormattedMessage
Expand All @@ -24,7 +24,7 @@ exports[`Editor render snapshot: renders correct editor given blockType (html ->
>
<div
aria-label="html"
className="pgn__modal-fullscreen"
className="pgn__modal-fullscreen h-100"
role="dialog"
>
<TextEditor
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@

exports[`EditorContainer component render snapshot: initialized. enable save and pass to header 1`] = `
<div
className="position-relative zindex-0"
className="editor-container d-flex flex-column position-relative zindex-0"
style={
Object {
"minHeight": "100%",
}
}
>
<BaseModal
bodyStyle={null}
Expand Down Expand Up @@ -53,7 +58,7 @@ exports[`EditorContainer component render snapshot: initialized. enable save and
</div>
</ModalDialog.Header>
<ModalDialog.Body
className="pb-6"
className="pb-0 mb-6"
>
<h1>
My test content
Expand All @@ -78,7 +83,12 @@ exports[`EditorContainer component render snapshot: initialized. enable save and

exports[`EditorContainer component render snapshot: not initialized. disable save and pass to header 1`] = `
<div
className="position-relative zindex-0"
className="editor-container d-flex flex-column position-relative zindex-0"
style={
Object {
"minHeight": "100%",
}
}
>
<BaseModal
bodyStyle={null}
Expand Down Expand Up @@ -129,7 +139,7 @@ exports[`EditorContainer component render snapshot: not initialized. disable sav
</div>
</ModalDialog.Header>
<ModalDialog.Body
className="pb-6"
className="pb-0 mb-6"
/>
<injectIntl(ShimmedIntlComponent)
disableSave={true}
Expand Down
6 changes: 4 additions & 2 deletions src/editors/containers/EditorContainer/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import EditorFooter from './components/EditorFooter';
import TitleHeader from './components/TitleHeader';
import * as hooks from './hooks';
import messages from './messages';
import './index.scss';

export const EditorContainer = ({
children,
Expand All @@ -29,7 +30,8 @@ export const EditorContainer = ({
const handleCancel = hooks.handleCancel({ onClose, returnFunction });
return (
<div
className="position-relative zindex-0"
className="editor-container d-flex flex-column position-relative zindex-0"
style={{ minHeight: '100%' }}
>
<BaseModal
size="md"
Expand Down Expand Up @@ -64,7 +66,7 @@ export const EditorContainer = ({
/>
</div>
</ModalDialog.Header>
<ModalDialog.Body className="pb-6">
<ModalDialog.Body className="pb-0 mb-6">
{isInitialized && children}
</ModalDialog.Body>
<EditorFooter
Expand Down
6 changes: 6 additions & 0 deletions src/editors/containers/EditorContainer/index.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// fix double scrollbars
.editor-container {
.pgn__modal-body {
overflow: visible;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@ exports[`SettingsWidget snapshot snapshot: renders Settings widget for Advanced
<div
className="my-3"
>
<ResetCard />
<ResetCard
defaultValue={false}
/>
</div>
<div
className="my-3"
Expand Down Expand Up @@ -143,7 +145,9 @@ exports[`SettingsWidget snapshot snapshot: renders Settings widget page 1`] = `
<div
className="my-3"
>
<ResetCard />
<ResetCard
defaultValue={false}
/>
</div>
<div
className="my-3"
Expand Down Expand Up @@ -224,7 +228,9 @@ exports[`SettingsWidget snapshot snapshot: renders Settings widget page advanced
<div
className="my-3"
>
<ResetCard />
<ResetCard
defaultValue={false}
/>
</div>
<div
className="my-3"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,12 +113,20 @@ export const SettingsWidget = ({
/>
</div>
<div className="my-3">
<ResetCard showResetButton={settings.showResetButton} updateSettings={updateSettings} />
<ResetCard
showResetButton={settings.showResetButton}
defaultValue={defaultSettings.showResetButton}
updateSettings={updateSettings}
/>
</div>
{
problemType === ProblemTypeKeys.ADVANCED && (
<div className="my-3">
<Randomization randomization={settings.randomization} updateSettings={updateSettings} />
<Randomization
randomization={settings.randomization}
defaultValue={defaultSettings.rerandomize}
updateSettings={updateSettings}
/>
</div>
)
}
Expand Down Expand Up @@ -161,7 +169,8 @@ SettingsWidget.propTypes = {
defaultSettings: PropTypes.shape({
maxAttempts: PropTypes.number,
showanswer: PropTypes.string,
showReseButton: PropTypes.bool,
showResetButton: PropTypes.bool,
rerandomize: PropTypes.string,
}).isRequired,
// eslint-disable-next-line
settings: PropTypes.any.isRequired,
Expand Down
Loading

0 comments on commit f471c5c

Please sign in to comment.