You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Super lazy note to author, and more for reference, but I solved my problem by intercepting the calculated program positions and re-writing my own width and horizontal placement function.
I found that the one of original getPositionX helper functions rounds the time values unnecessarily and also contains some unnecessary branches.
Effectively I replaced all of the getPositionX code with the code below:
constMS_PER_HOUR=1000*60*60;exportconstgetPositionX=(since: Date,till: Date,startDate: Date,endDate: Date,hourWidth: number)=>{// Constrain the start and end of the rendered blocks to the start and end times displayedconstrenderStartTimeMs=Math.max(since.getTime(),startDate.getTime());constrenderEndTimeMs=Math.min(till.getTime(),endDate.getTime());constdiffMs=Math.max(0,renderEndTimeMs-renderStartTimeMs);return(diffMs*hourWidth)/MS_PER_HOUR;};
Planby 1.1.7
Following demo here with custom data: https://codesandbox.io/s/planby-epg-demo-ts-lp66v5
Items appear to be aligned to some kind of grid with no obvious way to change grid resolution.
The text was updated successfully, but these errors were encountered: