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

fix(word-cloud): fix randomness of each word's rotation #19977

Merged
merged 1 commit into from
May 11, 2022

Conversation

ebaratte
Copy link
Contributor

@ebaratte ebaratte commented May 6, 2022

SUMMARY

In random and square mode, the words rotation of a word cloud chart should be assigned randomly, and be different for each word. Before this PR, all words use the same rotation (derived from the first randomly generated number by seedRandom()).
This PR fixes that behaviour, and restores the randomness of each word's rotation.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

Before:

image

--

After:

image

TESTING INSTRUCTIONS

Create a word cloud chart, and select a square or random rotation. Ensure all words have different rotations.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • Changes UI
  • Includes DB Migration (follow approval process in SIP-59)
    • Migration is atomic, supports rollback & is backwards-compatible
    • Confirm DB migration upgrade and downgrade tested
    • Runtime estimates and downtime expectations provided
  • Introduces new feature or API
  • Removes existing feature or API

Copy link
Member

@stephenLYZ stephenLYZ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Nice work!

@codecov
Copy link

codecov bot commented May 11, 2022

Codecov Report

Merging #19977 (5784212) into master (f144de4) will decrease coverage by 0.00%.
The diff coverage is 0.00%.

❗ Current head 5784212 differs from pull request most recent head 1ef3386. Consider uploading reports for the commit 1ef3386 to get more accurate results

@@            Coverage Diff             @@
##           master   #19977      +/-   ##
==========================================
- Coverage   66.29%   66.29%   -0.01%     
==========================================
  Files        1712     1712              
  Lines       63962    63963       +1     
  Branches     6731     6731              
==========================================
  Hits        42404    42404              
- Misses      19847    19848       +1     
  Partials     1711     1711              
Flag Coverage Δ
javascript 51.28% <0.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...ns/plugin-chart-word-cloud/src/chart/WordCloud.tsx 0.00% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f144de4...1ef3386. Read the comment docs.

@stephenLYZ stephenLYZ merged commit 2e31021 into apache:master May 11, 2022
hughhhh pushed a commit to hve-labs/superset that referenced this pull request May 11, 2022
philipher29 pushed a commit to ValtechMobility/superset that referenced this pull request Jun 9, 2022
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 2.0.0 labels Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/XS 🚢 2.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants