kalendar icon indicating copy to clipboard operation
kalendar copied to clipboard

Hide hour indicator when it's out of day bounds

Open gui-ant opened this issue 2 years ago • 2 comments

Related to and possibly closes issue #52:

The passedTime() function was returning null when current time was out of day bounds. So, distance prop was not exists. Changed to return the same {distance, time} object, but with distance value as -1. Hour line is shown only when passes passedTimeVisible guard, added as computed prop.

gui-ant avatar Mar 16 '22 11:03 gui-ant

@guiantz I am not sure I understand the issue. How can day be out of bounds ? Can you do a codesandbox reproduction of the issue ?

altinselimi avatar Apr 21 '22 11:04 altinselimi

The issue occurs when you define a partial period of day (e.g. 13pm-16pm) and the calendar is rendered on a time out of that interval (e.g. 12pm). This makes function passedTime() returning null, what will cause an exception when the position of the timeline is calculated. On the demo sample the available hours are defined to all day, so this issue never occurs.

gui-ant avatar Apr 21 '22 11:04 gui-ant