add hourlines (#3)
This commit is contained in:
parent
5a079ff413
commit
5c0b53b81d
@ -93,6 +93,22 @@
|
||||
color: var(--text-normal);
|
||||
}
|
||||
|
||||
.frcal__hourlines {
|
||||
height: 0;
|
||||
/* display: contents; */
|
||||
}
|
||||
.frcal__hourline {
|
||||
height: 1px;
|
||||
width: 100%;
|
||||
background-color: var(--color-base-30);
|
||||
}
|
||||
.frcal__day:nth-child(odd) .frcal__hourline {
|
||||
/* background-color: var(--background-primary); */
|
||||
}
|
||||
.frcal__day:nth-child(even) .frcal__hourline {
|
||||
/* background-color: var(--background-primary-alt); */
|
||||
}
|
||||
|
||||
.frcal__event span {
|
||||
background-color: var(--frcal--event-background, var(--color-accent));
|
||||
color: var(--frcal--event-text-color, var(--text-normal));
|
||||
|
||||
5
main.js
5
main.js
@ -539,6 +539,11 @@ class CalendarView extends ItemView
|
||||
{
|
||||
this.allday[day].innerHTML = "";
|
||||
this.timed[day].innerHTML = "";
|
||||
let hourlinesEl = this.timed[day].createEl("div", { cls: "frcal__hourlines" });
|
||||
for (let hour = 0; hour < 11; hour++)
|
||||
{
|
||||
hourlinesEl.createEl("div", { cls: "frcal__hourline", attr: { style: "margin-top: " + (120*this.zoom-1).toString() + "px"} })
|
||||
}
|
||||
}
|
||||
|
||||
let start = parseSingleDate(this.week + " ma 00:00am");
|
||||
|
||||
Reference in New Issue
Block a user