mirror of
https://github.com/dylanbenzi/yellowbird.git
synced 2026-11-27 09:17:00 +00:00
FIXED CALENDAR FULL HEIGHT!!
This commit is contained in:
@@ -3,7 +3,7 @@ import { VariantProps, cva } from "class-variance-authority";
|
|||||||
import React from "react";
|
import React from "react";
|
||||||
|
|
||||||
const CalenderItemVariants = cva(
|
const CalenderItemVariants = cva(
|
||||||
"rounded-sm cursor-pointer bg-opacity-15 hover:bg-opacity-70",
|
"rounded-sm cursor-pointer bg-opacity-15 hover:bg-opacity-40",
|
||||||
{
|
{
|
||||||
variants: {
|
variants: {
|
||||||
variant: {
|
variant: {
|
||||||
@@ -11,12 +11,12 @@ const CalenderItemVariants = cva(
|
|||||||
conference: "bg-yellow-300 text-yellow-300",
|
conference: "bg-yellow-300 text-yellow-300",
|
||||||
dividend: "bg-blue-500 text-blue-500",
|
dividend: "bg-blue-500 text-blue-500",
|
||||||
earnings: "bg-green-500 text-green-500",
|
earnings: "bg-green-500 text-green-500",
|
||||||
event: "bg-violet-500 text-violet-500",
|
event: "bg-purple-500 text-purple-500",
|
||||||
split: "bg-pink-500 text-pink-500",
|
split: "bg-pink-500 text-pink-500",
|
||||||
},
|
},
|
||||||
size: {
|
size: {
|
||||||
sm: "whitespace-nowrap",
|
sm: "whitespace-nowrap",
|
||||||
lg: "min-h-16",
|
lg: "bg-opacity-5",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
defaultVariants: {
|
defaultVariants: {
|
||||||
@@ -54,14 +54,23 @@ const CalendarItem = ({
|
|||||||
"w-1 rounded-full bg-opacity-100"
|
"w-1 rounded-full bg-opacity-100"
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
<div
|
||||||
|
className={cn(size == "lg" && "flex flex-col px-1 gap-2", "w-full")}
|
||||||
|
>
|
||||||
<div className="flex gap-1 justify-between px-1 w-full">
|
<div className="flex gap-1 justify-between px-1 w-full">
|
||||||
<p>{title}</p>
|
<p>{title}</p>
|
||||||
<p className={cn(size == "sm" ? "hidden xl:block" : "", "")}>
|
<p className={cn(size == "sm" ? "hidden xl:block" : "", "")}>
|
||||||
{time}
|
{time}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
{description && (
|
||||||
|
<p className="p-1 font-light leading-snug line-clamp-4 text-justify">
|
||||||
|
{description}
|
||||||
|
</p>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
{description && <p className="p-1 font-light">{description}</p>}
|
</div>
|
||||||
|
<div></div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ const Day = () => {
|
|||||||
variant="earnings"
|
variant="earnings"
|
||||||
size="lg"
|
size="lg"
|
||||||
time="BMO"
|
time="BMO"
|
||||||
description="Nvidia is reporting earnings after a boom in AI. "
|
description="Nvidia is reporting earnings after a boom in AI. Nvidia has emerged as a major player driving advancements in artificial intelligence. The company's high-performance graphics processing units (GPUs) have become the workhorses powering many of the latest AI models and applications. In 2023, Nvidia doubled down on AI with the launch of its Hopper architecture - a new chip design optimized for transformer-based language models like GPT-3. They also introduced new AI software tools and services through their Nvidia AI platform. This includes pre-trained models, development frameworks, and cloud services for enterprises looking to deploy large language models and computer vision AI. Additionally, Nvidia has been at the forefront of accelerating AI computing through innovations like their Grace CPU designed for AI/ML workloads. As generative AI goes mainstream, Nvidia's chips and software are becoming critical infrastructure enabling everything from content creation to drug discovery using advanced machine learning techniques."
|
||||||
/>
|
/>
|
||||||
<CalendarItem
|
<CalendarItem
|
||||||
title="NVDA Split 10:1"
|
title="NVDA Split 10:1"
|
||||||
@@ -43,7 +43,9 @@ const Day = () => {
|
|||||||
variant="conference"
|
variant="conference"
|
||||||
size="lg"
|
size="lg"
|
||||||
time="9 am"
|
time="9 am"
|
||||||
description="Apple is holding a conference call to update shareholders about it's recent AI WWDC event."
|
description="Apple has been ramping up its artificial intelligence efforts in recent years. At its Worldwide Developers Conference (WWDC) in June 2023, the company unveiled several new AI-powered features across its software platforms. This includes an enhanced Siri assistant with improved language understanding and multitasking capabilities. Apple also introduced Visioneer, a new AI model for advanced computer vision tasks like image analysis and video processing. Additionally, the company has been working on implementing generative AI models into its productivity apps like Pages and Keynote to assist with content creation. While Apple has historically been more cautious about adopting cutting-edge AI compared to rivals, these latest moves signal their intent to double down on machine learning and AI across their product ecosystem.
|
||||||
|
|
||||||
|
"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ const MonthCalendar = () => {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<Tabs className="w-full h-full overflow-hidden" defaultValue="month">
|
<Tabs className="w-full h-full overflow-hidden" defaultValue="month">
|
||||||
<Card>
|
<Card className="flex flex-col">
|
||||||
<CardHeader className="p-2">
|
<CardHeader className="p-2">
|
||||||
<div className="grid grid-cols-3 justify-stretch items-center">
|
<div className="grid grid-cols-3 justify-stretch items-center">
|
||||||
<div className="place-self-start">
|
<div className="place-self-start">
|
||||||
@@ -79,7 +79,8 @@ const MonthCalendar = () => {
|
|||||||
|
|
||||||
{/* MONTH VIEW */}
|
{/* MONTH VIEW */}
|
||||||
{calendarView == "month" && (
|
{calendarView == "month" && (
|
||||||
<CardContent className="p-0">
|
<CardContent className="p-0 h-full flex">
|
||||||
|
<div className="flex flex-col w-full">
|
||||||
<div className="grid grid-cols-7 h-10">
|
<div className="grid grid-cols-7 h-10">
|
||||||
{sevenDays.map((day) => (
|
{sevenDays.map((day) => (
|
||||||
<div
|
<div
|
||||||
@@ -108,7 +109,9 @@ const MonthCalendar = () => {
|
|||||||
"font-bold rounded-full w-6 flex justify-center"
|
"font-bold rounded-full w-6 flex justify-center"
|
||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
{format(item.date, "d", { timeZone: "America/New_York" })}
|
{format(item.date, "d", {
|
||||||
|
timeZone: "America/New_York",
|
||||||
|
})}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div className="grid grid-rows-4 overflow-hidden gap-1 p-1 px-2">
|
<div className="grid grid-rows-4 overflow-hidden gap-1 p-1 px-2">
|
||||||
@@ -153,6 +156,7 @@ const MonthCalendar = () => {
|
|||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
</CardContent>
|
</CardContent>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user