Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: Dropping Sass support from builtin word cloud block #35717

Open
wants to merge 2 commits into
base: farhan/sass-to-css-annotatable-block-2
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions xmodule/assets/WordCloudBlockDisplay.scss

This file was deleted.

30 changes: 0 additions & 30 deletions xmodule/assets/word_cloud/_display.scss

This file was deleted.

32 changes: 32 additions & 0 deletions xmodule/static/css-builtin-blocks/WordCloudBlockDisplay.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
@import url("https://fonts.googleapis.com/css?family=Open+Sans:300,400,400i,600,700");

.xmodule_display.xmodule_WordCloudBlock {
/* stylelint-disable-line */
/* stylelint-disable-line */
}

.xmodule_display.xmodule_WordCloudBlock .input-cloud {
margin: calc((var(--baseline) / 4));
}

.xmodule_display.xmodule_WordCloudBlock .result_cloud_section {
display: none;
width: 0px;
height: 0px;
}

.xmodule_display.xmodule_WordCloudBlock .result_cloud_section.active {
display: block;
width: 100%;
height: auto;
margin-top: 1em;
}

.xmodule_display.xmodule_WordCloudBlock .result_cloud_section.active h3 {
font-size: 100%;
}

.xmodule_display.xmodule_WordCloudBlock .your_words {
font-size: 0.85em;
display: block;
}
4 changes: 2 additions & 2 deletions xmodule/word_cloud_block.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
from xblock.fields import Boolean, Dict, Integer, List, Scope, String
from xmodule.editing_block import EditingMixin
from xmodule.raw_block import EmptyDataRawMixin
from xmodule.util.builtin_assets import add_webpack_js_to_fragment, add_sass_to_fragment
from xmodule.util.builtin_assets import add_webpack_js_to_fragment, add_css_to_fragment
from xmodule.xml_block import XmlMixin
from xmodule.x_module import (
ResourceTemplates,
Expand Down Expand Up @@ -262,7 +262,7 @@ def student_view(self, context): # lint-amnesty, pylint: disable=unused-argumen
'num_inputs': self.num_inputs,
'submitted': self.submitted,
}))
add_sass_to_fragment(fragment, 'WordCloudBlockDisplay.scss')
add_css_to_fragment(fragment, 'WordCloudBlockDisplay.css')
add_webpack_js_to_fragment(fragment, 'WordCloudBlockDisplay')
shim_xmodule_js(fragment, 'WordCloud')

Expand Down
Loading