Layout and spacing create structure, improve readability, and establish visual consistency. The Sharjah Design System provides a flexible spacing framework that helps teams build balanced and responsive interfaces.
A well-structured layout system ensures consistency, improves readability, and creates predictable user experiences. Our layout foundation includes responsive grids, spacing scales, breakpoints, and container patterns that work across all government digital services.
There are 5 breakpoints by default, inspired by common screen resolutions.
| Breakpoint | Minimum width | Properties |
|---|---|---|
sm |
640 px | @media (min-width:640px) { ... } |
md |
768 px | @media (min-width:768px) { ... } |
lg |
1024 px | @media (min-width:1024px) { ... } |
xl |
1280 px | @media (min-width:1280px) { ... } |
2xl |
1536 px | @media (min-width:1536px) { ... } |
Learn more about Responsive Design on the documentation of Tailwind CSS
It is essential to understand responsive design and the available breakpoints as the variations that can be used to control content. Knowing the breakpoints of your layout will help you understand the grid better. The grid is reactive to these breakpoints, which will allow you to adjust columns according to the breakpoints.
Since the dawn of smartphones, creating websites that can adapt to the screen size of a device has become a key factor in the design and development of websites.
It was as early as 1994 when the concept of media queries was first proposed. In the year 2000, W3C started work on media queries and also on another scheme for supporting various devices. [read more]. But it was the breakthrough in the use of smartphones and touch-based devices that accelerated the addition of media queries and in 2012, it was finally introduced as part of CSS.
Today, we cannot imagine building a website without media queries that react to device size. In 2020, Google announced that mobile-first indexing would be the primary way for Google Search to index websites for search results.
Why is this important?
When designing websites, the approach to mobile and device width is a very important factor. The UAE design system takes the approach of a mobile-first approach in its CSS setup. This means that when you design and program the frontend of your website, you must first consider the layout for a mobile device and gradually add elemental changes to how it will adapt to larger screen sizes.
The grid system has been part of website design and development for a very long time. Using a grid provides designers and developers with the ability to align content vertically and horizontally.
However, it continues to evolve with the changes and trends in design.
The design system adopts the Tailwind width approach. In this sense, it does not:
The following is a visualisations of the grid system applied using all the possible classes available in the design system, adapted from TailwindCSS that allows you to control the columns of your grid.
12-column grid
Two equal columns
Sidebar layout (8 + 4)
Spacing is an important — and often overlooked — part of a design system. It is of paramount importance and must be used intelligently when designing a website. The term "make the website breathable" is often used by designers and it particularly refers to the spacing.
Whether it's a linear scale or a modular scale, adopting a standard is essential. By default, Tailwind includes a comprehensive numeric spacing scale.
Instead of arbitrary values, use standard units of spacing. This could be tied to a baseline grid and the size of a typographic element
As screen sizes change, spacing might need to be adjusted. Account for changes in margins around the content area.
While mathematical consistency is essential, visual balance is equally critical. Always review designs to ensure that they feel right.
In essence, spacing isn't just about putting space between elements; it's a tool that can be used strategically to create clearer, more intuitive interfaces. As with any rule in design, understanding the rationale behind it is crucial because there will always be exceptions based on context.
The design system has increments of 2px until the base font size. Hence, up to 16px (1rem). After the base font size, the design system recommends using 4px as the increment up to 48px.
The screen size and the layout you want to design may be open to spacing, and hence we recommend a proportional ratio, so 16 is twice as much spacing as 8 for example.
| Name | Size | Pixels | Preview |
|---|---|---|---|
| 0 | 0px | 0px | |
| px | 1px | 1px | |
| 0.5 | 0.125rem | 2px | |
| 1 | 0.25rem | 4px | |
| 1.5 | 0.375rem | 6px | |
| 2 | 0.5rem | 8px | |
| 2.5 | 0.625rem | 10px | |
| 3 | 0.75rem | 12px | |
| 3.5 | 0.875rem | 14px | |
| 4 | 1rem | 16px | |
| 4.5 | 1.1rem | 18px | |
| 5 | 1.25rem | 20px | |
| 6 | 1.5rem | 24px | |
| 7 | 1.75rem | 28px | |
| 8 | 2rem | 32px | |
| 9 | 2.25rem | 36px | |
| 10 | 2.5rem | 40px | |
| 11 | 2.75rem | 44px | |
| 12 | 3rem | 48px | |
| 14 | 3.5rem | 56px | |
| 16 | 4rem | 64px | |
| 20 | 5rem | 80px | |
| 24 | 6rem | 96px | |
| 28 | 7rem | 112px | |
| 32 | 8rem | 128px | |
| 36 | 9rem | 144px | |
| 40 | 10rem | 160px | |
| 44 | 11rem | 176px | |
| 48 | 12rem | 192px | |
| 52 | 13rem | 208px | |
| 56 | 14rem | 224px | |
| 60 | 15rem | 240px | |
| 64 | 16rem | 256px | |
| 72 | 18rem | 288px | |
| 80 | 20rem | 320px | |
| 96 | 24rem | 384px |
Use of Cookies by this site is just to guarantee Ease of Access and better user experience while browsing. Continuation of your browsing acknowledges your approval for Terms and Conditions of this site and its use of Cookies. Privacy Policy
When you visit any website, it may store or retrieve information on your browser, mostly in the form of cookies. This information might be about you, your preferences or your device and is mostly used to make the site work as you expect it to. The information does not usually directly identify you, but it can give you a more personalized web experience. Because we respect your right to privacy, you can choose not to allow some types of cookies. Click on the different category headings to find out more and change our default settings. However, blocking some types of cookies may impact your experience of the site and the services we are able to offer.
Your response has been successfully recorded. If you wish to modify or change your answer, you can go back by clicking the Undo button.