Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adapt website header for tablet version #4030

Closed
FelixMalfait opened this issue Feb 16, 2024 · 8 comments
Closed

Adapt website header for tablet version #4030

FelixMalfait opened this issue Feb 16, 2024 · 8 comments
Assignees
Labels
good first issue Good for newcomers scope: front Issues that are affecting the frontend side only

Comments

@FelixMalfait
Copy link
Member

We currently have two tools to build our website Twenty.com:

  • Framer, which is well suited for beautiful landing pages
  • A Next.js website which is used for pages that need dynamic content (e.g. pull github data or markdown files)

Example page managed by Framer: https://twenty.com/
Example page managed by NextJS: https://twenty.com/user-guide (it's ugly! and not launched. Will be redesigned soon!)

We've done a quick v1 for the header which you can see on the NextJS page.
We adapted it on mobile/desktop but not on tablet mode.
You can view how it should look on tablet mode on the framer https://twenty.com/ website.

The goal of this ticket is to copy the behavior of the Framer website on tablet and implement it on the NextJS version.

There is already some duplicated code between the mobile and desktop version. Maybe there's an opportunity to refactor and do something cleaner as we add that third display mode? Would be amazing if we find a way to reduce the amount of duplicated code

Screenshot 2024-02-16 at 18 14 13

Code for NextJS website is in: https://github.com/twentyhq/twenty/tree/main/packages/twenty-website

@FelixMalfait FelixMalfait added the scope: front Issues that are affecting the frontend side only label Feb 16, 2024
@FelixMalfait FelixMalfait added the good first issue Good for newcomers label Feb 16, 2024
@ahmadjafari86
Copy link
Contributor

Hi Félix,
I'd like to work on this issue.

@FelixMalfait
Copy link
Member Author

Thanks @ahmadjafari86 ahmadjafari86!

@Kanav-Arora
Copy link
Contributor

Kanav-Arora commented Feb 17, 2024

Hi @ahmadjafari86

We have a PR down the line in which we are planning to introduce screensize hook in twenty-website. So to avoid any issues I'll be sharing the file path, name and code. Please use that hook to render different pages.

I'll be commit code in this PR #3984

@ahmadjafari86
Copy link
Contributor

Thanks @Kanav-Arora

@Kanav-Arora
Copy link
Contributor

Kanav-Arora commented Feb 17, 2024

Hi @ahmadjafari86
Check the PR for file useDeviceType file. Please follow same directory structure to avoid any merge conflicts in the future.

@FelixMalfait
Copy link
Member Author

Hey we merged the PR but it turns out useDeviceType isn't a good solution. We should use https://emotion.sh/docs/media-queries#facepaint instead - fix coming soon

@FelixMalfait
Copy link
Member Author

Ok the new method is finally merged - this is the best approach! #4169

@ahmadjafari86
Copy link
Contributor

Ok the new method is finally merged - this is the best approach! #4169

thanks, It's done.

@github-project-automation github-project-automation bot moved this from 🆕 New to ✅ Done in Product development ✅ Mar 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers scope: front Issues that are affecting the frontend side only
Projects
Status: ✅ Done
Development

No branches or pull requests

3 participants