generated from theodorusclarence/ts-nextjs-tailwind-starter
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
504 additions
and
66 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
'use client'; | ||
|
||
// import {Inder} from 'next/font/google'; | ||
import React from 'react'; | ||
import ReactWordcloud from 'react-wordcloud'; | ||
|
||
import 'tippy.js/dist/tippy.css'; | ||
import 'tippy.js/animations/scale.css'; | ||
|
||
import tags from '@/data/tags.json'; | ||
|
||
// const inder = Inder({weight: '400', subsets: ['latin']}); | ||
|
||
interface Options { | ||
colors?: string[]; | ||
rotations?: number; | ||
rotationAngles?: [number, number]; | ||
deterministic?: boolean; | ||
fontFamily?: string; | ||
fontSizes?: [number, number]; | ||
padding?: number; | ||
randomSeed?: string; | ||
enableTooltip?: boolean; | ||
} | ||
|
||
const TagCloud = () => { | ||
const callbacks = { | ||
// getWordColor: (tag: Tag) => tag.value > 10 ? "blue" : "lightblue", | ||
// onWordClick: console.log, | ||
// onWordMouseOver: console.log, | ||
// getWordTooltip: (tag: Tag) => `${tag.text} (${tag.value}) [${tag.value > 50 ? "good" : "bad"}]`, | ||
}; | ||
const options: Options = { | ||
colors: ['#0d40a4', '#1A86D2', '#61c1f8', '#FFCE47'], | ||
rotations: 1, | ||
rotationAngles: [0, 0], | ||
fontFamily: 'verdana', | ||
fontSizes: [10, 42], | ||
deterministic: true, | ||
enableTooltip: false, | ||
}; | ||
|
||
return ( | ||
<div className='flex flex-col h-[500px] md:h-[300px] w-full justify-center mt-6 lg:h-[288px] lg:w-1/2 lg:justify-between items-end lg:mt-0 me-10 rounded-md bg-gray-50 p-1'> | ||
<ReactWordcloud callbacks={callbacks} options={options} words={tags} /> | ||
</div> | ||
); | ||
}; | ||
|
||
export default TagCloud; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,222 @@ | ||
[ | ||
{ | ||
"value": 20, | ||
"text": "software engineer" | ||
}, | ||
{ | ||
"value": 20, | ||
"text": "full-stack developer" | ||
}, | ||
{ | ||
"value": 17, | ||
"text": "frontend" | ||
}, | ||
{ | ||
"value": 19, | ||
"text": "backend" | ||
}, | ||
{ | ||
"value": 18, | ||
"text": "Java" | ||
}, | ||
{ | ||
"value": 18, | ||
"text": "Kotlin" | ||
}, | ||
{ | ||
"value": 16, | ||
"text": "Typescript" | ||
}, | ||
{ | ||
"value": 17, | ||
"text": "Javascript" | ||
}, | ||
{ | ||
"value": 16, | ||
"text": "next.js" | ||
}, | ||
{ | ||
"value": 15, | ||
"text": "Spring Boot" | ||
}, | ||
{ | ||
"value": 14, | ||
"text": "CSS" | ||
}, | ||
{ | ||
"value": 15, | ||
"text": "HTML" | ||
}, | ||
{ | ||
"value": 18, | ||
"text": "lifelong learner" | ||
}, | ||
{ | ||
"value": 17, | ||
"text": "WFH enthusiast" | ||
}, | ||
{ | ||
"value": 13, | ||
"text": "remote work" | ||
}, | ||
{ | ||
"value": 16, | ||
"text": "Appetize" | ||
}, | ||
{ | ||
"value": 14, | ||
"text": "Resourcify" | ||
}, | ||
{ | ||
"value": 16, | ||
"text": "Booking.com" | ||
}, | ||
{ | ||
"value": 13, | ||
"text": "BJSS" | ||
}, | ||
{ | ||
"value": 13, | ||
"text": "UniBZ" | ||
}, | ||
{ | ||
"value": 15, | ||
"text": "University of Manchester" | ||
}, | ||
{ | ||
"value": 15, | ||
"text": "College of Charleston" | ||
}, | ||
{ | ||
"value": 12, | ||
"text": "Tongji University" | ||
}, | ||
{ | ||
"value": 5, | ||
"text": "multilingual" | ||
}, | ||
{ | ||
"value": 11, | ||
"text": "python" | ||
}, | ||
{ | ||
"value": 11, | ||
"text": "C#" | ||
}, | ||
{ | ||
"value": 12, | ||
"text": "computer science" | ||
}, | ||
{ | ||
"value": 10, | ||
"text": "writing" | ||
}, | ||
{ | ||
"value": 10, | ||
"text": "reading" | ||
}, | ||
{ | ||
"value": 10, | ||
"text": "bookworm" | ||
}, | ||
{ | ||
"value": 9, | ||
"text": "\uD83D\uDCDA" | ||
}, | ||
{ | ||
"value": 9, | ||
"text": "oboe" | ||
}, | ||
{ | ||
"value": 9, | ||
"text": "\uD83C\uDFB6" | ||
}, | ||
{ | ||
"value": 10, | ||
"text": "travel" | ||
}, | ||
{ | ||
"value": 8, | ||
"text": "photos" | ||
}, | ||
{ | ||
"value": 8, | ||
"text": "food" | ||
}, | ||
{ | ||
"value": 8, | ||
"text": "recipes" | ||
}, | ||
{ | ||
"value": 7, | ||
"text": "podcasts" | ||
}, | ||
{ | ||
"value": 8, | ||
"text": "video games" | ||
}, | ||
{ | ||
"value": 6, | ||
"text": "\uD83D\uDC08" | ||
}, | ||
{ | ||
"value": 6, | ||
"text": "\uD83D\uDC22" | ||
}, | ||
{ | ||
"value": 6, | ||
"text": "\uD83E\uDD94" | ||
}, | ||
{ | ||
"value": 8, | ||
"text": "classical music" | ||
}, | ||
{ | ||
"value": 16, | ||
"text": "React" | ||
}, | ||
{ | ||
"value": 15, | ||
"text": "Angular" | ||
}, | ||
{ | ||
"value": 10, | ||
"text": "Vue" | ||
}, | ||
{ | ||
"value": 16, | ||
"text": "APIs" | ||
}, | ||
{ | ||
"value": 12, | ||
"text": "UI" | ||
}, | ||
{ | ||
"value": 13, | ||
"text": "tailwind" | ||
}, | ||
{ | ||
"value": 13, | ||
"text": "android" | ||
}, | ||
{ | ||
"value": 11, | ||
"text": "iOS" | ||
}, | ||
{ | ||
"value": 7, | ||
"text": "PHP" | ||
}, | ||
{ | ||
"value": 8, | ||
"text": "Docker" | ||
}, | ||
{ | ||
"value": 8, | ||
"text": "SQL" | ||
}, | ||
{ | ||
"value": 7, | ||
"text": "GraphQL" | ||
} | ||
] |
Oops, something went wrong.