The Beautiful Framework for Shopify Application Development
A semantic toolkit designed to help developers create responsive Shopify apps utilizing the Embedded App SDK.
A semantic toolkit designed to help developers create responsive Shopify apps utilizing the Embedded App SDK.
Add the stylesheet to your project and begin writing the HTML for your app.
<link rel="stylesheet" href="uptown.css">
The framework is a single file that imports .scss
files for each component.
Uptown CSS is built using SASS and the Autoprefixer plugin for powerful vendor prefixing.
Autoprefixer is awesome and eliminates the need for constantly checking Can I Use for cross-browser compatibility.
There are no JavaScript dependencies. You're free to use any library since Uptown CSS is JS agnostic.
I'm Ryan O'Donnell, co-founder over at ShopPad and Mesa. Thousands of Shopify stores use apps from ShopPad and many of them are powered by Uptown CSS. Uptown is a framework has been battle-tested and is 100% production ready. Now we've open sourced it to share with Shopify's awesome developer community.
Sharing is caring.
Your markup should follow this basic structure. What you put inside each section, will depend on your app.
The grid is a 12-column fluid grid with a max width of 1036px, that shrinks with the browser/device at smaller sizes.
twelve
one
eleven
two
ten
three
nine
four
eight
five
seven
six
six
one-half
one-half
two-thirds
one-third
twelve
two
ten
one-half
one-half
two-thirds
one-third
This element is the canvas to put your app content within.
Add the class .has-sections
to the .card
element then just add .card-section
elements with dividing <hr>
tags.
Below are common layouts so you can quickly develop a familiar user experience.
content
content
Add the class .full-width
to any element.
A layout to show a main and side column.
Card
Card
Card
Card
The class .secondary
can be added to any .card
to visually dimm that element.
Card
This card is slightly dimmed to give the primary card more visual importance
Card
This card is slightly dimmed to give the primary card more visual importance
Type is defined with rems, so font-sizes and spacial relationships can be responsively sized based on a single font-size property. All measurements are base 10 so an H1 with 4.0rem font-size just means 40px. The typography base is device driven; "San Francisco" for Apple devices and "Roboto", "Segoe UI" for Android device. "Helvetica Neue" is the fallback. Size is set at 1.4rem (14px). Other type basics like anchors, strong, emphasis, and underline are all included.
Paragraph text
Anchor Bold UnderlinePreformatted text
Code
Paragraph text
Anchor Bold UnderlinePreformatted text
Code
Familiar icons are available and can be used on their own or within other elements.
Buttons support both the <button>
and the <a>
element. Only the <a>
element requires a .button
class to be appended. The button type is not a factor.
Wrap any set of buttons within an element having a class of .button-group
.
Add any supported icon without text. Disabled state is also supported to dim the icon color.
Standard form fields. Wrap radio and checkbox elements with a label
element.
Disabled form field states are supported too. Add a disabled="disabled"
attribute to any form field.
Add .error
class to the parent .row
or to the <label>
for checkboxes and radio elements.
Use the input type search
. No extra classes required.
Add .side-elements
to the parent .row
element. All elements within will stretch automatically to be on a single line.
The .label-cta
class will pull any element to the right.
Use an element with a class .input-group
. Add elements with .append
class. Place them before or after the form field.
Use an element with a class .input-group
. Add <button>
or .button
elements. Place them before or after the form field.
Add a class .tip
to any element. Add the tip's text as a data-hover
attribute. The hover event will automatically pull the text without any JavaScript needed.
The container element needs a class .alert
. Add .notice
, .success
, .warning
, .notification
or .error
for the desired icon and color. The <dl>
element is for the title and description text. Adding a .close
element or <button>
elements are optional.
Default <table>
containing various types of content. Add a container wrapper with a class .overflow-container
if the table needs to be scrollable on smaller screens.
Product | Status | Action | |
---|---|---|---|
Some Product | |||
Another Product |
|
||
One More Product |
|
Product | Status | Action | |
---|---|---|---|
Some Product | |||
Another Product |
|
||
One More Product |
|
Default <table>
element showing buttons and tags elements.
Product | Status | Action | |
---|---|---|---|
Text | Some Product | Approved | |
Text | Some Product | Pending | |
Text | Some Product | Paid |
Product | Status | Action | |
---|---|---|---|
Text | Some Product | Approved | |
Text | Some Product | Pending | |
Text | Some Product | Paid |
A <table>
showing a list of results. Use the .pagination
container around the .button-group
.
Name | Location | Orders | Last Order | Total Spent |
---|---|---|---|---|
John Doe | Oakland, CA | 1 | #1001 | $125.00 |
Jane Doe | Oakland, CA | 0 | — | $0.00 |
Mike Smith | San Francisco, CA | 1 | #1002 | $100.00 |
Use .highlight-warning
to highlight any text.
Product | Inventory | Type |
---|---|---|
Adidas Running Show | 5 in stock | Shoe |
New Balance Running Show | 12 in stock | Shoe |
New Balance Running Show | 60 in stock for 5 variants | Shoe |
Product | Inventory | Type |
---|---|---|
Adidas Running Show | 5 in stock | Shoe |
New Balance Running Show | 12 in stock | Shoe |
New Balance Running Show | 60 in stock for 5 variants | Shoe |
Add .summary
to a <table>
element for this specific layout.
Heading Last 7 Days | ||
---|---|---|
Direct | 67% | 2 |
Search | 33% | 1 |
Heading Last 7 Days | ||
---|---|---|
Direct | 67% | 2 |
Search | 33% | 1 |
Any element with .tag
and any supporting color.
Add the class .pending
to display a clock icon to represent a "pending" state.
Primarily used with content not associated with forms.
Use a <ul>
with the class .tabs
directly after an element with the .has-sections
class.
Sometimes it's better to use a utility class than create a whole new class just to do something simple.
Using the <header>
is great opportunity to showcase the app's branding.
A simple <header>
element with an h1
and/or h2
element. The <article>
directly after will automatically be pulled up
Preferred layout option when you have nothing to show.
Some explanatory text
Some explanatory text
Thanks for reading this far. Your commitment to the details is commendable.
© 2024 ShopPad, Inc.