asyncapi / modelina

A library for generating typed models based on inputs such as AsyncAPI, OpenAPI, and JSON Schema documents with high customization
https://modelina.org
Apache License 2.0
318 stars 184 forks source link

style(website): make Playground Mobile Responsive #2028

Closed jerensl closed 4 months ago

jerensl commented 5 months ago

Enable Playground work on Mobile Devices

Mobile

Mobile Device

Tablet

Tablet Device

Notebook

Notebook

Desktop

Desktop

Alternative Solution

  1. Visible property, The problem with this one is, the element is not being removed form the dom so it will make it difficult to allocate space with Grid

Related Issue

This refactor relates to #1715

Checklist

Additional Notes

Be careful using Conditional rendering with monaco-react when the costume theme is not being rendered by the first update, probably related to this issue, the way to solve it is by adding extra state for theme after adding the theme using monacoInstance

netlify[bot] commented 5 months ago

Deploy Preview for modelina canceled.

Name Link
Latest commit 29975d56ed22bb279014cf90ba77b15c21bb66b6
Latest deploy log https://app.netlify.com/sites/modelina/deploys/6676f352d903000008638286
jerensl commented 5 months ago

The new commit should fix the current issue, I'm adding extra state for updating the costume theme

jerensl commented 5 months ago

Hi @jerensl, The mobile version looks great to me. However, we don't need any changes to the desktop design. So please revert those changes. Also, could you open a new Issue + PR for bugs unrelated to this issue? Don't merge those fixes in this PR.

To keep the desktop version, would you mind if I changed the layout approach from Flexbox to Grid?

The bug just happened after we added conditional rendering for supporting mobile version, so it related to this feature

jerensl commented 5 months ago

Hi @devilkiller-ag I already removed the quick bug fixes because it's not relevant anymore, I tried a new approach that uses the hidden property, for more detail, you can read my edited comment above https://github.com/asyncapi/modelina/pull/2028#issue-2340750999

devilkiller-ag commented 5 months ago

To keep the desktop version, would you mind if I changed the layout approach from Flexbox to Grid?

The bug just happened after we added conditional rendering for supporting mobile version, so it related to this feature

Okay sure, if it doesn't break anything.

coveralls commented 5 months ago

Pull Request Test Coverage Report for Build 9438059815

Details


Totals Coverage Status
Change from base Build 9382165682: 0.0%
Covered Lines: 5996
Relevant Lines: 6327

πŸ’› - Coveralls
devilkiller-ag commented 5 months ago

@jonaslagoni Can you also check the playground layout on mobile and desktop and share your thoughts on it?

jonaslagoni commented 5 months ago

@jonaslagoni I propose to have same eslint and prettier rules as we have in the asyncapi website. Those rules have been properly brainstormed and implemented recently while migrating it to Next.js v14 and Typescript. Having same lint rules will ensure similar formatting rules across all website codebases in the asyncapi ecosystem. What's your thought on this?

Makes sense to me πŸ‘ Just remember to add the website to the root ignore files so there wont be any duplicates.

sonarcloud[bot] commented 5 months ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

jerensl commented 5 months ago

This seems a bit too wide in the desktop version πŸ€” image

Other then that it looks good πŸ‘

Noted, I already made a changes and added the final detail in the latest commit and editted the detail changes I made above

coveralls commented 5 months ago

Pull Request Test Coverage Report for Build 9561440615

Details


Totals Coverage Status
Change from base Build 9561348719: 0.0%
Covered Lines: 5997
Relevant Lines: 6328

πŸ’› - Coveralls
coveralls commented 4 months ago

Pull Request Test Coverage Report for Build 9626631986

Details


Totals Coverage Status
Change from base Build 9611843317: 0.0%
Covered Lines: 5997
Relevant Lines: 6328

πŸ’› - Coveralls
devilkiller-ag commented 4 months ago

/rtm

devilkiller-ag commented 4 months ago

Thanks @jerensl ✨ I noticed you haven't joined our slack community. Feel free to join it here.

jerensl commented 4 months ago

Thanks @jerensl ✨ I noticed you haven't joined our slack community. Feel free to join it here.

You're welcome, I already joined the Slack channel and got information about this good first issue there

asyncapi-bot commented 4 months ago

:tada: This PR is included in version 3.7.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: