feat: add time column to Calendar Component

This commit is contained in:
2024-02-05 22:23:03 -06:00
committed by doprz
parent 0ba61534cb
commit 9d6821127e
2 changed files with 17 additions and 0 deletions

View File

@@ -31,6 +31,13 @@ const Calendar: React.FC = (props) => {
))}
</div>
{/* Displaying the rest of the calendar */}
<div className={styles.timeColumn}>
{hoursOfDay.map((hour) => (
<div key={hour} className={styles.timeLabelContainer}>
<span>{hour % 12 === 0 ? 12 : hour % 12}:00 {hour < 12 ? 'AM' : 'PM'}</span>
</div>
))}
</div>
<div className={styles.calendarGrid}>
{grid.map((row, rowIndex) => (
row