Updated style

pull/25/head
Shahan Nedadahandeh 7 months ago
parent 49cbd40c12
commit ca896bedf6
Signed by: snedadah
GPG Key ID: 8638C7F917385B01
  1. 16
      components/WordCloud.module.css
  2. 35
      data/mocks.ts
  3. 2
      pages/playground.tsx

@ -1,19 +1,19 @@
.word:hover {
text-shadow: var(--primary-accent) 0 0 20px;
text-shadow: var(--primary-accent) 0 0 calc(20rem / 16);
text-anchor: "middle";
}
#tooltip {
font-family: 'Inconsolata', monospace;
font-family: "Inconsolata", monospace;
font-weight: bold;
top: 0px;
left: 0px;
top: 0;
left: 0;
position: absolute;
background-color: white;
color: var(--navy);
box-shadow: rgb(33 33 33 / 20%) 0px 1px 2px;
box-shadow: var(--card-background) 0px calc(1rem / 16) calc(2rem / 16);
pointer-events: none;
padding: 10px;
font-size: 17px;
border-radius: 9px;
padding: calc(10rem / 16);
font-size: calc(18rem / 16);
border-radius: calc(10rem / 16);
}

@ -43,19 +43,24 @@ export const moreMockCategoricalData = [
{ key: "C", value: 6.49 },
{ key: "Assembly", value: 6.31 },
{ key: "R", value: 5.83 },
{ key: "Objective C", value: 3.43 },
{ key: "Swift", value: 2.89 },
{ key: "PHP", value: 2.85 },
{ key: "Rust", value: 2.33 },
{ key: "Ruby", value: 2.25 },
{ key: "Matlab", value: 2.06 },
{ key: "TypeScript", value: 1.98 },
{ key: "Go", value: 1.85 },
{ key: "VBA", value: 1.11 },
{ key: "Scala", value: 0.79 },
{ key: "Lua", value: 0.79 },
{ key: "Julia", value: 0.77 },
{ key: "Kotlin", value: 0.7 },
{ key: "Perl", value: 0.41 },
{ key: "Groovy", value: 0.4 },
{ key: "Objective C", value: 4.43 },
{ key: "Swift", value: 3.89 },
{ key: "PHP", value: 3.85 },
{ key: "Rust", value: 3.33 },
{ key: "Ruby", value: 3.25 },
{ key: "Matlab", value: 3.06 },
{ key: "TypeScript", value: 3.98 },
{ key: "Go", value: 3.85 },
{ key: "Haskell", value: 3.28 },
{ key: "VBA", value: 3.11 },
{ key: "Scala", value: 2.79 },
{ key: "Lua", value: 2.79 },
{ key: "Julia", value: 2.77 },
{ key: "Kotlin", value: 2.7 },
{ key: "Perl", value: 2.41 },
{ key: "Groovy", value: 2.4 },
{ key: "Abap", value: 2.24 },
{ key: "Cobol", value: 2.23 },
{ key: "Ada", value: 2.21 },
{ key: "Dart", value: 2.21 },
];

@ -17,8 +17,6 @@ export default function Home() {
<code>{"<WordCloud />"}</code>
</h2>
<WordCloud
// width={1000}
// height={500}
data={moreMockCategoricalData.map((word) => ({
text: word.key,
value: word.value,

Loading…
Cancel
Save