From dd18b1fa6590aa465a4f05c463dec9fff7c3c451 Mon Sep 17 00:00:00 2001 From: Denny Date: Fri, 14 Jul 2023 12:15:56 +0530 Subject: [PATCH] feat: create ui to copy paste slurs for instagram and thread users. #297 --- .../src/components/molecules/Footer.jsx | 5 +- .../src/components/molecules/NavBar.jsx | 23 +- .../src/pages/hidden-words-for-instagram.jsx | 99 ++++++ .../src/pages/hidden-words-for-thread.jsx | 99 ++++++ uli-website/src/slurs/hindi.json | 117 +++++++ uli-website/src/slurs/hinglish.json | 303 ++++++++++++++++++ uli-website/src/slurs/tamil.json | 81 +++++ 7 files changed, 714 insertions(+), 13 deletions(-) create mode 100644 uli-website/src/pages/hidden-words-for-instagram.jsx create mode 100644 uli-website/src/pages/hidden-words-for-thread.jsx create mode 100644 uli-website/src/slurs/hindi.json create mode 100644 uli-website/src/slurs/hinglish.json create mode 100644 uli-website/src/slurs/tamil.json diff --git a/uli-website/src/components/molecules/Footer.jsx b/uli-website/src/components/molecules/Footer.jsx index a3333436..9808ee68 100644 --- a/uli-website/src/components/molecules/Footer.jsx +++ b/uli-website/src/components/molecules/Footer.jsx @@ -10,13 +10,14 @@ export default function Footer() { margin={{ top: "small", bottom: "small" }} width={"large"} direction={"row-responsive"} - align={"center"} gap="small" > Twitter Privacy Policy Blog - GitHub + + GitHub + ); diff --git a/uli-website/src/components/molecules/NavBar.jsx b/uli-website/src/components/molecules/NavBar.jsx index 8673c6a5..c6e96a5e 100644 --- a/uli-website/src/components/molecules/NavBar.jsx +++ b/uli-website/src/components/molecules/NavBar.jsx @@ -12,7 +12,6 @@ const NavBarByLang = { About FAQ Research - ), hi: ( @@ -53,17 +52,19 @@ export default function NavBar() { }, []); return ( - + - - English - - - Tamil - - - Hindi - + + + English + {" "} + + Tamil + {" "} + + Hindi + + { + const selectOptions = Object.keys(options).map((option) => { + return { label: options[option].label, value: option }; + }); + const defaultOptions = selectOptions.map((option) => option.value); + const [choices, setChoices] = useState(defaultOptions); + + function clickCopyToClipboard() { + navigator.clipboard.writeText( + choices.map((choice) => options[choice].slurs.join(", ")).join(", ") + ); + } + + return ( + + + + Hidden Words for Instagram + + Instagram now allows you to filter out words that you don't want to + see on your feed. Uli's slur list can assist you in adding a list of + slurs in Indian languages. If you are being targetted or abused on + social media in Indian languages, consider adding these words to + your list of "hidden words" on Instagram + + + + Choose Languages + { + setChoices(value); + }} + > + + + + + +