Skip to content

Commit 3873c03

Browse files
committed
update responsive styling
1 parent b651944 commit 3873c03

File tree

4 files changed

+16
-8
lines changed

4 files changed

+16
-8
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ await Promise.all(
164164

165165
### Roadmap
166166

167+
- Full product and category search
167168
- Auto dropdown navigation for large number of categories
168169
- Ability to add more / more configurable metadata to item details
169170
- Themeing + dark mode

layouts/layout.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@ export default function Layout({ children, categories }) {
1313
<nav>
1414
<div className="flex justify-center">
1515
<div className="
16-
mobile:px-12 sm:flex-row sm:pt-12 sm:pb-6 desktop:px-0
17-
px-4 pt-8 flex flex-col w-fw">
16+
mobile:px-12 sm:flex-row sm:pt-12 sm:pb-6 desktop:px-0
17+
px-4 pt-8 flex flex-col w-fw
18+
">
1819
<div className="mb-4 sm:mr-16 max-w-48 sm:max-w-none">
1920
<Link href="/">
2021
<a aria-label="Home">

pages/product/[name].js

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,18 +35,21 @@ const ItemView = (props) => {
3535
<title>Jamstack ECommerce - {name}</title>
3636
<meta property="og:title" content={`Jamstack ECommerce - ${name}`} key="title" />
3737
</Head>
38-
<div className="py-12 flex flex-1 flex-col
39-
md:flex-row
40-
w-full
41-
my-0 mx-auto">
38+
<div className="
39+
sm:py-12
40+
md:flex-row
41+
py-4 w-full flex flex-1 flex-col my-0 mx-auto
42+
">
4243
<div className="w-full md:w-1/2 h-112 flex flex-1 bg-light hover:bg-light-200">
4344
<div className="py-16 p10 flex flex-1 justify-center items-center">
4445
<Image src={image} alt="Inventory item" className="max-h-full" />
4546
</div>
4647
</div>
4748
<div className="pt-2 px-0 md:px-10 pb-8 w-full md:w-1/2">
48-
<h1 className="text-5xl font-light">{name}</h1>
49-
<h2 className="text-2xl tracking-wide py-8">${price}</h2>
49+
<h1 className="
50+
sm:mt-0 mt-2 text-5xl font-light leading-large
51+
">{name}</h1>
52+
<h2 className="text-2xl tracking-wide sm:py-8 py-6">${price}</h2>
5053
<p className="text-gray-600 leading-7">{description}</p>
5154
<div className="my-6">
5255
<QuantityPicker

tailwind.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,9 @@ module.exports = {
171171
'light': '#f5f5f5',
172172
'light-200': '#f0f0f0',
173173
'light-300': '#e8e8e8'
174+
},
175+
lineHeight: {
176+
'large': '54px'
174177
}
175178
},
176179
},

0 commit comments

Comments
 (0)