Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add ClientEventTime #245

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

mcherukupally
Copy link
Collaborator

Added a component "ClientEventTime" and integrated it into the EventCard component

Copy link

vercel bot commented Oct 1, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
jupiter ❌ Failed (Inspect) Oct 8, 2024 7:33pm

Copy link
Contributor

@nl32 nl32 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there are some unused imports causing the build to fail that need to be resolved.

I ran this on local and the formatting is wrong.
on dev it looks like this:
image
however on this branch it looks like this:
Screenshot 2024-10-08 at 2 27 24 PM

it should look like it does on dev, just with the right time.

@@ -0,0 +1,34 @@
'use client';
//import react
import React from 'react';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary import and comment

timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
});

//resturn span element that dispalys local start and end time
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typos

) : (
<> - {format(event.endTime, 'E, MMM d, p')}</>
)}
{/* Use the ClientEventTime component here */}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary comment

Comment on lines +18 to +24
const localStartTime = new Date(startTime).toLocaleString(undefined, {
timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
});
//same
const localEndTime = new Date(endTime).toLocaleString(undefined, {
timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
});
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure if this is necessary since it's a client component, you can play with it once it builds on vercel.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants