Skip to content

Commit

Permalink
Adds word cloud xblock extracting from edx-platform repo (#4)
Browse files Browse the repository at this point in the history
feat: Adds word cloud xblock extracting from edx-platform repo
  • Loading branch information
farhan authored Feb 18, 2025
1 parent 40ee5e1 commit 264ae5f
Show file tree
Hide file tree
Showing 12 changed files with 1,185 additions and 104 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
__pycache__
.pytest_cache

### Editor and IDE artifacts
.idea/

# C extensions
*.so

Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,11 @@ Added
=====

* First release on PyPI.

0.2.0 – 2025-02-12
**********************************************

Added
=====

* Implemented the Word Cloud Block, extracted from edx-platform.
2 changes: 1 addition & 1 deletion xblocks_contrib/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@
from .video import VideoBlock
from .word_cloud import WordCloudBlock

__version__ = "0.1.0"
__version__ = "0.2.0"
3 changes: 1 addition & 2 deletions xblocks_contrib/word_cloud/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
"""
Init for the WordCloudBlock.
"""Word cloud is ungraded xblock used by students to generate and view word cloud.
"""

from .word_cloud import WordCloudBlock
28 changes: 24 additions & 4 deletions xblocks_contrib/word_cloud/static/css/word_cloud.css
Original file line number Diff line number Diff line change
@@ -1,9 +1,29 @@
/* CSS for WordCloudBlock */

.word_cloud .count {
font-weight: bold;
@import url("https://fonts.googleapis.com/css?family=Open+Sans:300,400,400i,600,700");

.input-cloud {
margin: calc((var(--baseline, 20px) / 4));
}

.result_cloud_section {
display: none;
width: 0;
height: 0;
}

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

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

.word_cloud p {
cursor: pointer;
.your_words {
font-size: 0.85em;
display: block;
}
Loading

0 comments on commit 264ae5f

Please sign in to comment.