react-calendar-heatmap icon indicating copy to clipboard operation
react-calendar-heatmap copied to clipboard

Limit of weekday labels

Open nikfedotoff opened this issue 4 years ago • 1 comments

Is it possible to display all 7 weekday labels?

nikfedotoff avatar Oct 07 '21 12:10 nikfedotoff

I am facing same problem:

<CalendarHeatmap
        startDate={shiftDate(today, -30)}
        endDate={today}
        values={randomValues}
        classForValue={(value) => {
          if (!value) {
            return "color-empty";
          }
          return `color-github-${value.count}`;
        }}
        tooltipDataAttrs={(value) => {
          return {
            "data-tip": `${value.date.toISOString().slice(0, 10)} has count: ${
              value.count
            }`
          };
        }}
        weekdayLabels={[
          "Sunday",
          "Monday",
          "Tuesday",
          "wed",
          "Thursday",
          "Friday",
          "Sat"
        ]}
        onClick={(value) =>
          alert(`Clicked on value with count: ${value.count}`)
        }
      />

Even after passing weekdayLabels prop it does not render all the 7 weekday labels

aditodkar avatar Mar 28 '23 12:03 aditodkar