Richardsl / heatmap-calendar-obsidian

An Obsidian plugin for displaying data in a calendar similar to the github activity calendar
Apache License 2.0
614 stars 102 forks source link

Cells are not showing #75

Open corataine opened 1 year ago

corataine commented 1 year ago

Hi! I download the EXAMPLE_VAULT code. And I didn't change anything.But Cells are not showing,I cant find any bug. image

corataine commented 1 year ago

image

emrestive commented 1 year ago

Same issue here. Did u found any fix?

luccomo commented 1 year ago

Same

gillespieza commented 1 year ago

Do we vote here? +1

johnsbuck commented 1 year ago

The reason you see no alcohol activity is because the year is set to 2023, and there is no alcohol activity in 2023. If you set it to 2022, you will see the normal heatmap.


dv.span("**🍺 Alcohol Consumption 🍺**")

const calendarData = {
    year: 2022,
    colors: {
        blue: ["#ffdf04","#ffbe04","#ff9a03","#ff6d02","#ff2c01"]
    },
    entries: [],
    showCurrentDayBorder: false
}

for(let page of dv.pages('"daily notes"').where(p=>p.alcohol)){
    calendarData.entries.push({
        date: page.file.name,
        intensity: page.alcohol,
        content: await dv.span(`[](${page.file.name})`), //for hover preview
    })  
}

renderHeatmapCalendar(this.container, calendarData)
johnsbuck commented 1 year ago

Just for context, here is the output

image

luccomo commented 1 year ago

Thanks got it workingSent from my iPhoneOn Apr 29, 2023, at 3:00 PM, John Bucknam @.***> wrote: Just for context, here is the output

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>