Content
View differences
Updated by Marc Alcobé over 2 years ago
### Context
Today, OpenProject has six viewport ranges:
* 320 px – 544 px (mobile)
* 544 px – 768 px (tablet portrait)
* 768 px – 1200 px (tablet landscape)
* 1200 – 1280 px (desktop)
* 1280 + (wide)
Primer uses a much simpler system with three [viewport ranges](https://primer.style/foundations/layout#viewport-ranges):
<figure class="table op-uc-figure_align-center op-uc-figure"><table class="op-uc-table"><tbody><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Viewport range</strong></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Width range</strong></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Columns</strong></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Description</strong></p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><code class="op-uc-code">narrow</code></p></td><td class="op-uc-table--cell"><p class="op-uc-p">< 768px</p></td><td class="op-uc-table--cell"><p class="op-uc-p">1</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Supports a single-column layout. Also known as “mobile”.</p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><code class="op-uc-code">regular</code></p></td><td class="op-uc-table--cell"><p class="op-uc-p">>= 768px</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Up to 2</p></td><td class="op-uc-table--cell"><p class="op-uc-p">All desktop-friendly patterns start at this range.</p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><code class="op-uc-code">wide</code></p></td><td class="op-uc-table--cell"><p class="op-uc-p">>= 1400px</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Up to 3</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Optional range when a 3rd layout column is needed.</p></td></tr></tbody></table></figure>
Primer also defines a set of finer, [more graduated breakpoints](https://primer.style/foundations/layout#breakpoints) that are used to adapt specific components if needed. These align more with what we have at OP at the moment:
* 320 px
* 544 px
* 768 px
* 1012 px
* 1280 px
* 1400 px
However, these do _not_ seem to represent viewport ranges, but simply breakpoints that can be used to fine-tune specific scenarios. According to Primer docs:
> While viewport ranges should be used for distinguishing responsive layout adaptations, custom media queries built with these breakpoints values can be used internally for adjusting any specific responsive scenarios that require a fine-tune level of control.
### **Acceptance criteria** Simplification
* Use the viewport ranges proposed by Primer as criteria for the layout, therefore from < 768px (tablets The OP tablet portrait range (544 px – 768 px) might not be needed.
Right now, if we take that range and mobiles) manually hide the sidebar will sidebar, we have something that _looks_ like a mobile page but with larger margins.
If we align with Primer's 3-range model, we might just be hidden by default.
* We align able to serve the breakpoints proposed by Primer and analyse in each page/feature if the design adapts to every single one mobile version up until 768px, without a "break" at 544px.
The goal of them or only some of them.
* We consider that the the content width in both 768px and 544px (as the sidebar this work package is hidden) is pretty similar and leaves opportunity to design from 1012px to 544px in discuss what our options are, what the implications of a single style.
change might be and finally make a decision.
### **Acceptance criteria**
* With the current implementation there is some small spacings differences between tablet and mobile which will be accepted. _tbd_
Today, OpenProject has six viewport ranges:
* 320 px – 544 px (mobile)
* 544 px – 768 px (tablet portrait)
* 768 px – 1200 px (tablet landscape)
* 1200 – 1280 px (desktop)
* 1280 + (wide)
Primer uses a much simpler system with three [viewport ranges](https://primer.style/foundations/layout#viewport-ranges):
<figure class="table op-uc-figure_align-center op-uc-figure"><table class="op-uc-table"><tbody><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Viewport range</strong></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Width range</strong></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Columns</strong></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><strong>Description</strong></p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><code class="op-uc-code">narrow</code></p></td><td class="op-uc-table--cell"><p class="op-uc-p">< 768px</p></td><td class="op-uc-table--cell"><p class="op-uc-p">1</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Supports a single-column layout. Also known as “mobile”.</p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><code class="op-uc-code">regular</code></p></td><td class="op-uc-table--cell"><p class="op-uc-p">>= 768px</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Up to 2</p></td><td class="op-uc-table--cell"><p class="op-uc-p">All desktop-friendly patterns start at this range.</p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell"><p class="op-uc-p"><code class="op-uc-code">wide</code></p></td><td class="op-uc-table--cell"><p class="op-uc-p">>= 1400px</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Up to 3</p></td><td class="op-uc-table--cell"><p class="op-uc-p">Optional range when a 3rd layout column is needed.</p></td></tr></tbody></table></figure>
Primer also defines a set of finer, [more graduated breakpoints](https://primer.style/foundations/layout#breakpoints) that are used to adapt specific components if needed. These align more with what we have at OP at the moment:
* 320 px
* 544 px
* 768 px
* 1012 px
* 1280 px
* 1400 px
However, these do _not_ seem to represent viewport ranges, but simply breakpoints that can be used to fine-tune specific scenarios. According to Primer docs:
> While viewport ranges should be used for distinguishing responsive layout adaptations, custom media queries built with these breakpoints values can be used internally for adjusting any specific responsive scenarios that require a fine-tune level of control.
### **Acceptance criteria**
* Use the viewport ranges proposed by Primer as criteria for the layout, therefore from < 768px (tablets
Right now, if we take that range
If we align with Primer's 3-range model, we might just
* We align
The goal
* We consider that the the content width in both 768px and 544px (as the sidebar
### **Acceptance criteria**