1
Fork 0
mirror of https://github.com/pds-nest/nest.git synced 2024-11-22 21:14:18 +00:00
pds-2021-g2-nest/nest_frontend/components/interactive/BoxWordcloud.js

43 lines
1.3 KiB
JavaScript
Raw Normal View History

2021-05-15 16:05:13 +00:00
import React from "react"
import BoxFull from "../base/BoxFull"
import ReactWordcloud from "react-wordcloud"
export default function BoxWordcloud({ ...props }) {
return (
<BoxFull header={"Wordcloud"} {...props}>
<div style={{"width": "100%", "height": "100%"}}>
<ReactWordcloud
options={{
colors: [
"var(--fg-primary)",
],
fontFamily: "Bree Serif",
fontSizes: [12, 128],
size: undefined,
deterministic: true,
}}
words={[
{
text: "noi",
value: 1
},
{
text: "estraiamo",
value: 1
},
{
text: "statistiche",
value: 1
},
{
text: "tweet",
value: 1
},
]}
/>
</div>
</BoxFull>
)
}