Skip to content

Conversation

@SofieDunt
Copy link
Contributor

Why

Monday.com Ticket

What benefit does this bring to the end user? Or, what benefit does this bring to developers working in the codebase?

Makes the logged-in landing page easier to navigate on mobile devices/narrow windows. useWindowDimensions can be used to make other components responsive to browser dimensions.

This PR

Describe the changes required and any implementation choices you made to give context to reviewers.

Created useWindowDimensions to get and use the windowDimensions state when rendering components

  • windowDimensions contains the browser's width, height, and windowType
  • windowType is determined by width:
    • < 650 => 'MOBILE'
    • [650, 900) => 'TABLET'
    • [900, 1150) => 'NARROW'
    • > 1150 => 'DESKTOP'

Created link carousel component using Ant.D Carousel component

  • number of slides per page in carousel depends on window dimensions

Updated PageHeader and HomeContainer components so that top margin decreases for mobile

Screenshots

Provide screenshots of any new components, styling changes, or pages.
Desktop, Mobile
Desktop Mobile
Narrow, Tablet
NarrowDesktopTablet

Verification Steps

What steps did you take to verify your changes work? These should be clear enough for someone to be able to clone the branch and follow the steps themselves.

Visually confirmed the layout updated when resizing the browser, also used Device Mode in Chrome Dev Tools to make sure the layout made sense for mobile.

Copy link
Member

@florisdobber florisdobber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few minor things but otherwise great PR! Lots of code clean up and reusable stuff. If you have time would love if you could address the changes soon so we can merge this and use it else where.

@florisdobber florisdobber self-requested a review December 17, 2020 14:30
Copy link
Member

@florisdobber florisdobber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry the delay, approved

@florisdobber florisdobber merged commit 83725c9 into master Dec 17, 2020
@SofieDunt SofieDunt deleted the SD.optimizeForMobile branch January 31, 2021 19:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants