Skip to content

Commit a5587d0

Browse files
committed
Refactor and clean up components: Remove unused imports, enhance styling for buttons and livestream elements, and improve layout in the StreamHeader and StageControls components. Update database connection URL for local development and refine session service documentation for clarity.
1 parent 5a5c523 commit a5587d0

File tree

8 files changed

+16
-18
lines changed

8 files changed

+16
-18
lines changed

packages/app/app/studio/[organization]/(no-side-bar)/clips/[stageId]/sidebar/clips/Clip.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import { Card, CardContent } from '@/components/ui/card';
44
import { fetchSessionRenderingProgress } from '@/lib/services/sessionService';
55
import { IExtendedSession } from '@/lib/types';
66
import { formatDate } from '@/lib/utils/time';
7-
import { useRouter } from 'next/navigation';
87
import { useEffect, useState } from 'react';
98
import { ProcessingStatus } from 'streameth-new-server/src/interfaces/session.interface';
109
import Preview from './Preview';

packages/app/app/studio/[organization]/(root)/livestreams/[streamId]/components/StageControls.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ const StageControls = ({
5656
<div>
5757
<StreamConfigWithPlayer stream={stream} isLive={isLive} />
5858
<div className="flex flex-col md:justify-between gap-2 items-center py-2 w-full md:flex-row md:flex-wrap">
59-
<span className="pr-4 text-xl font-bold text-left">{stream.name}</span>
6059
<div className="flex flex-row w-full">
6160
<div className="justify-self-start flex items-center">
6261
<StreamHealth isLive={isLive} stream={stream} />

packages/app/app/studio/[organization]/(root)/livestreams/[streamId]/components/StreamHeader.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ const StreamHeader = ({
1414
isLiveStreamPage?: boolean;
1515
}) => {
1616
return (
17-
<div>
17+
<div className="flex flex-row justify-between items-center">
18+
<span className="pr-4 text-2xl font-bold">{stream.name}</span>
19+
1820
{isLiveStreamPage && (
1921
<Link href={`/studio/${organizationSlug}`}>
2022
<Button variant="secondary" className="mb-2 px-2">

packages/app/app/studio/[organization]/(root)/livestreams/[streamId]/page.tsx

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,15 @@ const Livestream = async ({ params }: LivestreamPageParams) => {
3131
})
3232
).sessions;
3333

34-
3534
return (
3635
<div className="flex flex-col p-4 w-full h-full max-h-screen max-w-screen-3xl">
37-
<StreamHeader
38-
organizationSlug={params.organization}
39-
stream={stream}
40-
isLiveStreamPage
41-
/>
4236
<div className="flex flex-row flex-grow space-x-4 w-full">
4337
<div className="flex flex-col w-2/3">
38+
<StreamHeader
39+
organizationSlug={params.organization}
40+
stream={stream}
41+
isLiveStreamPage
42+
/>
4443
<StageControls
4544
organization={organization}
4645
stream={stream}

packages/app/app/studio/[organization]/(root)/livestreams/components/LivestreamTable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ const LivestreamTable = async ({
107107
) : (
108108
<Link
109109
href={`/studio/${organizationSlug}/livestreams/${stream._id}`}
110-
className="w-full max-h-6"
110+
className="w-full max-h-12 overflow-clip "
111111
>
112112
<p className="line-clamp-3 font-medium text-lg text-ellipsis">
113113
{stream?.name}

packages/app/app/studio/[organization]/(root)/page.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import { Tabs, TabsList, TabsTrigger, TabsContent } from '@/components/ui/tabs';
1515
import FeatureButton from '@/components/ui/feature-button';
1616
import { Radio } from 'lucide-react';
1717
import { isFeatureAvailable } from '@/lib/utils/utils';
18-
18+
import { useSubscription } from '@/lib/hooks/useSubscription';
1919
const OrganizationPage = async ({
2020
params,
2121
searchParams,
@@ -57,7 +57,7 @@ const OrganizationPage = async ({
5757
) : (
5858
<FeatureButton
5959
organizationId={organization._id.toString()}
60-
variant="ghost"
60+
variant="outline"
6161
className="flex items-center gap-2"
6262
>
6363
<FileUp className="w-5 h-5" />

packages/server/src/databases/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ import { config } from '@config';
22
const { host, user, name, password } = config.db;
33

44
export const dbConnection = {
5-
url: `mongodb://${user}:${password}@${host}/${name}?authSource=admin&retryWrites=true&w=majority`,
5+
//url: `mongodb://${user}:${password}@${host}/${name}?authSource=admin&retryWrites=true&w=majority`,
66
// For local development use this url
7-
// url: `mongodb+srv://${user}:${password}@${host}/${name}?authSource=admin`,
7+
url: `mongodb+srv://${user}:${password}@${host}/${name}?authSource=admin`,
88
options: {
99
useNewUrlParser: true,
1010
useUnifiedTopology: true,

packages/server/src/services/session.service.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -442,9 +442,9 @@ export default class SessionService {
442442
- You are an expert video editor specializing in extracting and structuring full speaker presentations and panels from livestreams.
443443
- Your task is to precisely indentify the start and end points of speaker presentations and panels from start to end, include the full speaker presentation or panel.
444444
- Usually speaker presentation and pannel are between 10 to 30 minutes long, dont extract 1 minute segemnts or similar, look for full speaker presentations and panels.
445-
- Identify segments using markers such as:
446-
- Introductions: e.g.,\"Thank you so much ....\", \"Welcome to...\", \"Next up, we have...\", \"Please give it up for...\", \"Let's get started with...\", \"We're excited to welcome...\", \"We're honored to present...\"
447-
- Transitions or cues indicating the start or end of a keynote/panel: e.g., \"discussion on...\", \"presentation about...\", \"closing remarks on...\"
445+
- Identify segments using markers such as:
446+
- Introductions: e.g.,\"Thank you so much ....\", \"Welcome to...\", \"Next up, we have...\", \"Please give it up for...\", \"Let's get started with...\", \"We're excited to welcome...\", \"We're honored to present...\"
447+
- Transitions or cues indicating the start or end of a keynote/panel: e.g., \"discussion on...\", \"presentation about...\", \"closing remarks on...\"
448448
449449
Input:
450450
- You will be given a vtt transcript of the livestream.
@@ -462,7 +462,6 @@ export default class SessionService {
462462
- Follow the output format exactly, just return an array of objects.
463463
- NEVER RETURN ANYTHING OTHER THAN AN ARRAY OF OBJECTS, ITS FORBIDDEN TO RETURN ANYTHING ELSE.
464464
- NEVER RETURN ANTYHNING WITH A TITLE THAT IS ALREADY PRESENTED AS A MARKER.
465-
- RETURNED CLIPS SHOULD NOT OVERLAP WITH EACH OTHER.
466465
- RETURNED CLIPS SHOULD NOT BE SHORTER THAN 10 MINUTES.
467466
- DONT CLIPS THAT ARE ALREADY PRESENTED AS A MARKER.
468467
`,

0 commit comments

Comments
 (0)