sarahsporck / Migration-Test-Repository

This repository is used to test the ticket migration from jira to github
0 stars 1 forks source link

IGAPP-679: Use correct viewportSmall prop #3345

Closed jira-to-github-migrator-test[bot] closed 1 year ago

jira-to-github-migrator-test[bot] commented 1 year ago

Steffen Kleinle - 7.6.2021, 16:26:37

We use viewportSmall in lots of places to decide whether we should render components with a mobile suitable layout or the standard one for desktop browsers. Currently, we only pass mock values in a lot of places.

Correctly decide whether we are on a small viewport or not and either pass this information as prop to all components, create a hook or come up with a different solution (anything except reintroducing redux :D). Make sure the web app looks as before on mobile afterwards.

Previously we used https://www.npmjs.com/package/redux-responsive with a break point at 750px width: viewport: createResponsiveStateReducer({ small: 750 }, { infinity: 'large' }). For reference: https://github.com/Integreat/integreat-app/blob/IGAPP-web-ts-init/web/src/modules/app/createReduxStore.js#L43

Environment: - Linked issues: