Skip to content

Commit 26853d6

Browse files
committed
feat: replace code link with stars count button and link
1 parent b10a102 commit 26853d6

File tree

6 files changed

+51
-14
lines changed

6 files changed

+51
-14
lines changed

app/components/InitialLoad.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,14 @@ export const InitialLoad = ({ fn }: { fn: () => void }) => {
2525
</ul>
2626
</div>
2727
<span className="mt-4 block font-semibold">
28-
<div className="bg-white text-black rounded px-6 py-3 font-semibold sm:w-fit sm:mx-auto">
28+
<div className="bg-white text-black rounded px-10 py-3 font-semibold sm:w-fit sm:mx-auto">
2929
{isBrowser ? "Click" : "Tap"} here to start
3030
</div>
3131
</span>
3232
<span className="mt-4 block text-sm text-gray-100/70">
3333
<Headphones /> For optimal enjoyment, we recommend using headphones
34-
while using this application. Minor bugs and annoyances may appear while using this demo. Pull requests are welcome.
34+
while using this application. Minor bugs and annoyances may appear
35+
while using this demo. Pull requests are welcome.
3536
</span>
3637
</button>
3738
</div>

app/globals.css

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ body {
5252
}
5353

5454
.gradient-shadow {
55-
box-shadow: -1rem 0px 2rem 0px #13ef9335, 1rem 0px 2rem 0px #149afb35;
55+
box-shadow:
56+
-1rem 0px 2rem 0px #13ef9335,
57+
1rem 0px 2rem 0px #149afb35;
5658
}
5759
}
5860

app/layout.tsx

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,18 @@ export default function RootLayout({
6161
</PlayQueueContextProvider>
6262
</MicrophoneContextProvider>
6363
</ToastContextProvider>
64+
<GoogleTagManager gtmId="GTM-5R73N627" />
65+
<Script
66+
id="github-buttons"
67+
async
68+
defer
69+
src="https://buttons.github.io/buttons.js"
70+
></Script>
71+
<Script id="heap-analytics">
72+
{`window.heap=window.heap||[],heap.load=function(e,t){window.heap.appid=e,window.heap.config=t=t||{};var r=document.createElement("script");r.type="text/javascript",r.async=!0,r.src="https://cdn.heapanalytics.com/js/heap-"+e+".js";var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(r,a);for(var n=function(e){return function(){heap.push([e].concat(Array.prototype.slice.call(arguments,0)))}},p=["addEventProperties","addUserProperties","clearEventProperties","identify","resetIdentity","removeEventProperty","setEventProperties","track","unsetEventProperty"],o=0;o<p.length;o++)heap[p[o]]=n(p[o])};`}
73+
{`heap.load("765739241");`}
74+
</Script>
6475
</body>
65-
<GoogleTagManager gtmId="GTM-5R73N627" />
66-
<Script id="heap-analytics">
67-
{`window.heap=window.heap||[],heap.load=function(e,t){window.heap.appid=e,window.heap.config=t=t||{};var r=document.createElement("script");r.type="text/javascript",r.async=!0,r.src="https://cdn.heapanalytics.com/js/heap-"+e+".js";var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(r,a);for(var n=function(e){return function(){heap.push([e].concat(Array.prototype.slice.call(arguments,0)))}},p=["addEventProperties","addUserProperties","clearEventProperties","identify","resetIdentity","removeEventProperty","setEventProperties","track","unsetEventProperty"],o=0;o<p.length;o++)heap[p[o]]=n(p[o])};`}
68-
{`heap.load("765739241");`}
69-
</Script>
7076
</html>
7177
);
7278
}

app/page.tsx

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,11 @@
22

33
import Conversation from "./components/Conversation";
44
import Image from "next/image";
5+
import GitHubButton from "react-github-btn";
56

67
export const runtime = "edge";
78
import * as FullStory from "@fullstory/browser";
89
import { useEffect } from "react";
9-
import { NextUIProvider } from "@nextui-org/react";
10-
import { BoltIcon } from "./components/icons/BoltIcon";
1110
import { XIcon } from "./components/icons/XIcon";
1211
import { FacebookIcon } from "./components/icons/FacebookIcon";
1312
import { LinkedInIcon } from "./components/icons/LinkedInIcon";
@@ -35,22 +34,33 @@ export default function Home() {
3534
/>
3635
</a>
3736
</div>
38-
<div className="flex items-center gap-4 text-sm">
39-
<span className="bg-white rounded">
37+
<div className="flex items-center gap-6 text-sm">
38+
<span className="mt-2">
39+
<GitHubButton
40+
href="https://github.com/deepgram-devs/deepgram-conversational-demo"
41+
data-color-scheme="no-preference: light; light: light; dark: light;"
42+
data-show-count="true"
43+
aria-label="Star deepgram-devs/deepgram-conversational-demo on GitHub"
44+
>
45+
Star
46+
</GitHubButton>
47+
</span>
48+
49+
{/* <span className="bg-white rounded">
4050
<a
4151
href="https://github.com/deepgram-devs/deepgram-conversational-demo"
4252
target="_blank"
4353
className="hidden sm:inline-block bg-white text-black rounded m-px px-4 py-2 font-semibold"
4454
>
4555
View the code
4656
</a>
47-
</span>
57+
</span> */}
4858

4959
<span className="gradient-shadow bg-gradient-to-r to-[#13EF93]/50 from-[#149AFB]/80 rounded">
5060
<a
5161
href="https://console.deepgram.com/signup?jump=keys"
5262
target="_blank"
53-
className="hidden md:inline-block bg-black text-white rounded m-px px-4 py-2 font-semibold"
63+
className="hidden text-xs md:inline-block bg-black text-white rounded m-px px-8 py-2 font-semibold"
5464
>
5565
Get an API Key
5666
</a>

package-lock.json

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
"react": "^18",
2727
"react-device-detect": "^2.2.3",
2828
"react-dom": "^18",
29+
"react-github-btn": "^1.4.0",
2930
"react-markdown": "^9.0.1",
3031
"react-syntax-highlighter": "^15.5.0",
3132
"react-toastify": "^10.0.4",

0 commit comments

Comments
 (0)