style: fix prettier formatting issues

- Fix formatting in Calendar.css, Calendar.tsx
- Fix formatting in Menubar.tsx
- Fix formatting in eventUtils.ts
This commit is contained in:
lenhanphung
2025-09-17 18:40:25 +07:00
parent 127417e154
commit a053318bc0
4 changed files with 23 additions and 18 deletions
+11 -12
View File
@@ -25,7 +25,7 @@
margin-left: 25%; margin-left: 25%;
} }
.sidebar { .sidebar {
border-right: 2px solid #F3F4F6; border-right: 2px solid #f3f4f6;
width: 20vw; width: 20vw;
padding: 16px 25px; padding: 16px 25px;
} }
@@ -67,7 +67,6 @@
overflow: hidden; /* Important: let FullCalendar handle internal scroll */ overflow: hidden; /* Important: let FullCalendar handle internal scroll */
} }
/* Base container */ /* Base container */
.fc-daygrid-day-top { .fc-daygrid-day-top {
display: flex; display: flex;
@@ -77,7 +76,6 @@
font-family: "Inter", sans-serif; font-family: "Inter", sans-serif;
} }
/* sidebar*/ /* sidebar*/
.sidebar-calendar { .sidebar-calendar {
width: 280px; width: 280px;
@@ -169,12 +167,13 @@
.fc-header-toolbar.fc-toolbar.fc-toolbar-ltr { .fc-header-toolbar.fc-toolbar.fc-toolbar-ltr {
/* display: none; */ /* display: none; */
} }
.fc-theme-standard td, .fc-theme-standard th { .fc-theme-standard td,
border: 1px solid #B8C1CC; .fc-theme-standard th {
border: 1px solid #b8c1cc;
border-left: 0; border-left: 0;
} }
a.fc-timegrid-axis-cushion { a.fc-timegrid-axis-cushion {
color: #243B55; color: #243b55;
text-align: center; text-align: center;
font-family: Roboto; font-family: Roboto;
font-size: 12.507px; font-size: 12.507px;
@@ -184,7 +183,7 @@ a.fc-timegrid-axis-cushion {
letter-spacing: 0.391px; letter-spacing: 0.391px;
} }
.fc-daygrid-day-top small { .fc-daygrid-day-top small {
color: #8C9CAF; color: #8c9caf;
font-size: 14px; font-size: 14px;
font-style: normal; font-style: normal;
font-weight: 500; font-weight: 500;
@@ -220,7 +219,7 @@ span.fc-daygrid-day-number.current-date {
color: #fff; color: #fff;
} }
span.fc-daygrid-day-number.current-date:after { span.fc-daygrid-day-number.current-date:after {
background-color: #F67E35; background-color: #f67e35;
} }
td.fc-timegrid-slot.fc-timegrid-slot-label.fc-scrollgrid-shrink, td.fc-timegrid-slot.fc-timegrid-slot-label.fc-scrollgrid-shrink,
td.fc-timegrid-slot.fc-timegrid-slot-label.fc-timegrid-slot-minor { td.fc-timegrid-slot.fc-timegrid-slot-label.fc-timegrid-slot-minor {
@@ -228,7 +227,7 @@ td.fc-timegrid-slot.fc-timegrid-slot-label.fc-timegrid-slot-minor {
} }
th.fc-timegrid-axis.fc-scrollgrid-shrink { th.fc-timegrid-axis.fc-scrollgrid-shrink {
border: 0; border: 0;
border-right: 1px solid #B8C1CC; border-right: 1px solid #b8c1cc;
} }
.fc .fc-timegrid-axis-cushion { .fc .fc-timegrid-axis-cushion {
min-width: 70px; min-width: 70px;
@@ -241,7 +240,7 @@ th.fc-timegrid-axis.fc-scrollgrid-shrink {
height: 0; height: 0;
} }
.fc-timegrid-slot-label-cushion { .fc-timegrid-slot-label-cushion {
color: #AEA9B1; color: #aea9b1;
font-family: Roboto; font-family: Roboto;
font-size: 14px; font-size: 14px;
font-style: normal; font-style: normal;
@@ -265,10 +264,10 @@ th.fc-col-header-cell.fc-day {
.fc .fc-timegrid-slot-label .fc-timegrid-slot-label-frame::after { .fc .fc-timegrid-slot-label .fc-timegrid-slot-label-frame::after {
content: ""; content: "";
z-index: -1; z-index: -1;
background-color: #B8C1CC; background-color: #b8c1cc;
width: 10px; width: 10px;
height: 1px; height: 1px;
position: absolute; position: absolute;
top: 9.5px; top: 9.5px;
right: -15px; right: -15px;
} }
+5 -1
View File
@@ -84,7 +84,11 @@ export default function CalendarApp() {
// Auto-select personal calendars when first loaded // Auto-select personal calendars when first loaded
useEffect(() => { useEffect(() => {
if (Object.keys(calendars).length > 0 && userId && selectedCalendars.length === 0) { if (
Object.keys(calendars).length > 0 &&
userId &&
selectedCalendars.length === 0
) {
const personalCalendarIds = Object.keys(calendars).filter( const personalCalendarIds = Object.keys(calendars).filter(
(id) => id.split("/")[0] === userId (id) => id.split("/")[0] === userId
); );
+6 -4
View File
@@ -48,16 +48,18 @@ export function Menubar() {
<Avatar <Avatar
sx={{ sx={{
bgcolor: stringToColor( bgcolor: stringToColor(
(user && user.family_name) ? user.family_name : user && user.family_name
(user && user.email) ? user.email : ? user.family_name
'' : user && user.email
? user.email
: ""
), ),
}} }}
sizes="large" sizes="large"
> >
{user?.name && user?.family_name {user?.name && user?.family_name
? `${user.name[0]}${user.family_name[0]}` ? `${user.name[0]}${user.family_name[0]}`
: user?.email?.[0] ?? ''} : (user?.email?.[0] ?? "")}
</Avatar> </Avatar>
</div> </div>
</header> </header>
+1 -1
View File
@@ -242,7 +242,7 @@ export function calendarEventToJCal(
}); });
return ["vcalendar", [], [vevent, vtimezone.component.jCal]]; return ["vcalendar", [], [vevent, vtimezone.component.jCal]];
} }
const vtimezone = new ICAL.Timezone({ const vtimezone = new ICAL.Timezone({
component: timezoneData.ics, component: timezoneData.ics,
tzid: event.timezone, tzid: event.timezone,