irongit

made textshadow plugin for tailwind

huncholanehuncholaneauthored
parent b087853commit 0669faf3448074e93a030c28dcfa00fab587ca51Browse files

3 files changed, +5 -3

+1-1twench_landing_page/components/LandingSection/LandingSection.tsx
@@ -11,7 +11,7 @@ const LandingSection = () => {
1111 <div>dex</div>
1212 <div>tools</div>
1313 </div>
14- <a className="buy-button">BUY $TWENCH</a>
14+ <a className="buy-button text-shadow-[1px]">BUY $TWENCH</a>
1515 </div>
1616 </div>
1717 );
+2-1twench_landing_page/plugins/text-shadow.ts
@@ -4,7 +4,8 @@ const textShadowPlugin = plugin(function ({ matchUtilities, theme }) {
44 matchUtilities(
55 {
66 "text-shadow": (value: string) => ({
7- textShadow: value,
7+ textShadow: `${value} ${value} 0 #000, -${value} -${value} 0 #000, ${value} -${value} 0 #000,
8+ -${value} ${value} 0 #000, ${value} 0 0 #000, -${value} 0 0 #000, 0 ${value} 0 #000, 0 -${value} 0 #000;`,
89 }),
910 },
1011 {
+2-1twench_landing_page/tailwind.config.ts
@@ -1,4 +1,5 @@
11 import type { Config } from "tailwindcss";
2+import textShadowPlugin from "./plugins/text-shadow";
23
34 const config: Config = {
45 content: [
@@ -14,6 +15,6 @@ const config: Config = {
1415 },
1516 },
1617 },
17- plugins: [],
18+ plugins: [textShadowPlugin],
1819 };
1920 export default config;