Skip to content

Commit

Permalink
Prepared the TopicEtherpad button for hiding test.
Browse files Browse the repository at this point in the history
  • Loading branch information
Michaellinaresxk committed Nov 13, 2023
1 parent cb3d689 commit 8eda083
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions config/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ const {
FEATURE_CONTACT_FORM_ATTACHMENTS_ENABLED,
FEATURE_MINT_PAGES_ENABLED,
FEATURE_NEXBOARD_ENABLED,
FEATURE_NEXBOARD_BUTTON_ENABLE,
SC_DEMO_USER_PASSWORD = 'Schulcloud1!',
SC_DEMO_USER_NAME = '[email protected]',
SC_SUPERHERO_USER_PASSWORD = 'Schulcloud1!',
Expand Down Expand Up @@ -73,6 +74,7 @@ const exp = {
FEATURE_CONTACT_FORM_ATTACHMENTS_ENABLED,
FEATURE_MINT_PAGES_ENABLED,
FEATURE_NEXBOARD_ENABLED,
FEATURE_NEXBOARD_BUTTON_ENABLE,
SC_DEMO_USER_PASSWORD,
SC_DEMO_USER_NAME,
SC_SUPERHERO_USER_PASSWORD,
Expand Down
4 changes: 2 additions & 2 deletions static/scripts/topicEdit.js
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ class TopicBlockList extends React.Component {
* Render the list items.
*/
render() {
const neXboardEnabled = ($contentBlocksContainer.data('nexboardenabled') === true);
const neXboardButtonEnabled = ($contentBlocksContainer.data('neXboardButtonEnabled') === false);
return (
<div>
<SortableList
Expand Down Expand Up @@ -371,7 +371,7 @@ class TopicBlockList extends React.Component {
onClick={this.addBlock.bind(this, TopicResources)}>
{`+ ${$t('topic.topicEdit.button.material')}`}
</button>
{neXboardEnabled ? <button
{neXboardButtonEnabled ? <button
type="button"
className="btn btn-secondary"
data-testid="topic-addcontent-nexboard-btn"
Expand Down
4 changes: 2 additions & 2 deletions views/topic/edit-topic.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@
<div class="form-group">
<label>{{$t "topic._topic.label.content" }}</label>
<!-- React Magic -->
<div id="content-blocks" data-testid="nextboardButton" data-value="{{lesson.contents}}" data-parent-id="{{lesson._id}}" data-school-id="{{schoolId}}" data-parent-type="lessons" data-etherpadbaseurl="{{etherpadBaseUrl}}"
data-iscoursegroup="{{courseGroupId}}" data-nexboardenabled="{{#ifEnv "FEATURE_NEXBOARD_ENABLED" "false"}}true{{/ifEnv}}"></div>
<div id="content-blocks" data-testid="nexboardButton" data-value="{{lesson.contents}}" data-parent-id="{{lesson._id}}" data-school-id="{{schoolId}}" data-parent-type="lessons" data-etherpadbaseurl="{{etherpadBaseUrl}}"
data-iscoursegroup="{{courseGroupId}}" data-neXboardButtonEnabled="{{#ifEnv "FEATURE_NEXBOARD_BUTTON_ENABLED" "false"}}true{{/ifEnv}}"></div>
</div>
{{#ifneq 0 (arrayLength @root.lessonFilesStorageData.files)}}
<label>{{$t "topic._topic.label.embeddedFiles" }}</label>
Expand Down

0 comments on commit 8eda083

Please sign in to comment.