react-calendar-full
Version:
A full-featured React calendar component with event scheduling and monthly, weekly, and daily views.
121 lines (102 loc) • 1.84 kB
CSS
@media (max-width: 576px) {
body {
font-size: 12px;
}
.btn {
font-size: 12px;
}
}
.time-col {
flex: 0 0 auto;
width: 9%;
}
.weekly-view > .day-col {
flex: 0 0 auto;
width: 13%;
position: relative;
}
.day-view > .day-col {
flex: 0 0 auto;
width: 91%;
position: relative;
}
.hour-cell {
height: 60px;
}
.day-header {
height: 24px;
padding-left: 2px;
}
.month-header {
height: 28px;
font-weight: 400;
line-height: 28px;
margin-left: 10px;
}
.date-col {
position: relative;
padding: 0;
}
.event-col {
background: repeating-linear-gradient(
to bottom,
#fff 0,
#fff 59px,
#dee2e6 59px, /* Adjust this color to your desired border color */
#dee2e6 60px
);
position: relative;
padding: 0;
}
.calendar {
text-align: left;
}
.calendar-event {
position: absolute;
width: 100%;
overflow: hidden;
text-overflow: ellipsis;
font-size: 13px;
border-radius: 4px;
box-shadow: 0 1px 2px rgba(0,0,0,0.1);
padding-left: 4px;
}
.calendar-event:hover {
cursor: pointer;
}
.calendar-event.green {
background-color:#d1ffbf;
color:#3c8222;
border-left: 3px solid rgb(101, 219, 57);
}
.calendar-event.blue {
background-color:#34aadc;
color:#1f6583;;
border-left: 3px solid rgb(101, 219, 57);
}
.calendar-month-view {
display: grid;
grid-template-columns: repeat(7, 1fr);
}
.weekdays-row {
display: contents; /* makes the children of this div to respect the parent grid */
}
.weekday {
background-color: #f7f7f7;
padding: 5px;
text-align: center;
font-weight: bold;
}
.calendar-day {
background-color: #ffffff;
padding: 5px;
border: 1px solid #e0e0e0;
min-height: 120px;
overflow: hidden;
white-space: nowrap;
}
.calendar-day.inactive {
background-color: #f7f7f7;
border: none;
cursor: none;
}