Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    12.0p+ Calendar workday cell height issue

    Hi Isomorphic,

    please see this sample (v12.0p_2022-02-12, here for v13.0p_2022-02-13) and add workdayEnd:"14:00". You'll see that the cell height of the 30min-slots severely increases. This is unexpected.
    Click image for larger version

Name:	cell height.png
Views:	222
Size:	64.7 KB
ID:	267393

    Best regards
    Blama


    #2
    Workday cells are supposed to size to fit the viewport - so a short workDay would be expected to have taller cells.

    However, there's a known bug for this particular sample in the Showcase - when this sample is the first one loaded (eg, if you press F5 when this sample is loaded), it sizes the workDay rows to fit a viewport-size that is not the final size, but only the first sample render (during ExampleViewer init). If you go to the sample's code tab and "Try It", the resizing takes effect, and this is what you're seeing in 12.0. In later versions, the rows are slightly over-sized on the initial render, and exhibit the same subsequent correction of behavior.

    Please confirm if this is what you're seeing.

    Comment


      #3
      Hi Isomorphic,

      yes I can confirm.
      • Rows are slightly over-sized on the initial render, but change to normal on "Try It" in 13.0p
      • Rows are sized as expected on the initial render already in 12.0p
      • Workday cells size to fit the viewport. They still have a minimum height for a long workday, which is good.
      I was not aware workday cells size change according to workday length was on purpose. IMHO it's not mentioned anywhere, but of course it is an interesting feature.
      Also adding rowHeight:20 additional to workdayEnd:"14:00" does not an effect. I'd expect to be able to control the height myself nevertheless, so that I can have the calendar always look the same. I'm not using this feature or Calendar at all (so this has no priority for me), but this is what I'd expect if I was.

      Best regards
      Blama

      Comment


        #4
        hi Blama

        Just so you know, we've fixed the sizing of "workday" rows in vertical Calendar views - you should now find it sizes rows as close as it can (using a single cellHeight) to filling the viewport - and this is slightly different in the weekView, where there is a header, and in the dayView where there isn't.

        Note that we also fixed the text in the dateLabel above the view, which will now show a 5-day range when showWeekends is false, and updated the scrollToWorkday feature, so it takes effect whenever the range changes.

        These changes will hit 12.1 tomorrow, but should be available in today's 13.x builds.

        Comment


          #5
          Hi Isomorphic,

          I can see the changes in SNAPSHOT_v13.1d_2022-03-02 and they all work as you describe and make sense IMHO.
          The only thing not working is specifying a fixed rowHeight:20 or similar, which would make sense too.

          Also, retesting I noticed this issue.

          Thank you & Best regards
          Blama

          Comment


            #6
            We've added a few enhancements for workdays - new attributes styleWorkday (which defaults to true, to match legacy behavior), sizeToWorkday and limitToWorkday, which prevents scrolling beyond the workday hours.

            There's also now minRowHeight, which prevents sizeToWorkday from shrinking rows below a certain height - so, if you set this to 100 and set limitToWorkday, you'll get *some* scrolling to reach the rest of the workday, but won't be able to scroll beyond it.

            These are all in 13.1 already, and have been ported to 13.0 and 12.1 for tomorrow's builds.

            Comment


              #7
              Hi Isomorphic,

              not sure if you did more changes here, but the picture is different now:

              v12.0p_2022-02-15 (no new builds, so this might be different in your 12.0p Dev code):
              • (Re-)Start sample
              • Click "Day"
              • Sample is on Tue, not Mon as I'd expect (perhaps because the 1st event is on Tue?)
              v12.1p_2022-03-05:
              • (Re-)Start sample
              • Click "Day"
              • Sample is on Tue, not Mon as I'd expect (perhaps because the 1st event is on Tue?)
              v13.0p_2022-03-05:
              • Working as expected
              SNAPSHOT_v13.1d_2022-03-07:
              • Line height not adjusted to work day

              Another issue:
              12.0p: Day view has zebra stripes (also in the workday calendar)

              Best regards
              Blama

              Comment


                #8
                Hi Isomorphic,

                my reply #7 is from before reading #6.

                Best regards
                Blama

                Comment


                  #9
                  Hi Isomorphic,

                  testing the changes from #6 with SNAPSHOT_v13.1d_2022-03-07 they all work fine. The default sizeToWorkday: false in 13.1d explains the difference I'm seeing in #7.
                  So IMHO only the two 12.0p and one 12.1p issues are open.

                  Best regards
                  Blama

                  Comment


                    #10
                    The sample initially selecting Tuesday is just that the Calendar has no specified startDate/chosenDate - so it's defaulting to today.

                    We'll take a look at the alternateRowStyles difference between 12.0 and later versions.

                    Comment


                      #11
                      Hi Isomorphic,

                      you are right, adding startDate: new Date(2022, 2, 7) to the sample fixes the issue in 12.0p/12.1p.
                      Perhaps this is a useful addition to the samples there as well. The sample and eventData in 13.0p have this addition.

                      Best regards
                      Blama

                      Comment

                      Working...
                      X