Skip to content

Commit f3d271d

Browse files
authored
fix: Improve mobile responsiveness and update links on amiusing.reque… (#9)
* fix: Improve mobile responsiveness and update links on amiusing.requestly.io * reverting back the links and testing as well, all working
1 parent 922cfed commit f3d271d

File tree

4 files changed

+113
-16
lines changed

4 files changed

+113
-16
lines changed

components/Yes.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export default function Yes() {
7272
target="_blank"
7373
rel="noreferrer noopener"
7474
>
75-
Coinditionally replace part of an URL String
75+
Conditionally replace part of an URL String
7676
</a>
7777
<a
7878
href="https://docs.requestly.com/general/rule-types/modify-user-agents"

package-lock.json

Lines changed: 5 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pages/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export default function Home({ headers }) {
1111
<title>
1212
Am I Using Requestly | Requestly - Intercept & Modify HTTP(s) Requests
1313
</title>
14+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
1415
<meta
1516
name="description"
1617
content="Requestly allows you to Intercept & Modify network requests. Main features include Modifying headers, Setting up redirects, Switch hosts, inserting custom scripts and much more"

styles/globals.css

Lines changed: 106 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,29 +13,56 @@
1313

1414
.grid {
1515
display: grid;
16-
grid-template-columns: 1fr 1fr;
16+
grid-template-columns: 1fr;
17+
}
18+
19+
@media (min-width: 768px) {
20+
.grid {
21+
grid-template-columns: 1fr 1fr;
22+
}
1723
}
1824

1925
.success,
2026
.next {
2127
display: flex;
2228
flex-direction: column;
2329
justify-content: center;
24-
padding: 2rem;
25-
min-height: 100vh;
30+
padding: 1rem;
31+
min-height: 50vh;
32+
}
33+
34+
@media (min-width: 768px) {
35+
.success,
36+
.next {
37+
padding: 2rem;
38+
min-height: 100vh;
39+
}
2640
}
2741

2842
.success {
2943
background: #0648b3;
3044
color: #fff;
31-
text-align: right;
45+
text-align: center;
46+
}
47+
48+
@media (min-width: 768px) {
49+
.success {
50+
text-align: right;
51+
}
3252
}
3353

3454
.success h1 {
35-
font-size: 3.2rem;
55+
font-size: 2rem;
3656
display: flex;
3757
align-items: center;
38-
justify-content: flex-end;
58+
justify-content: center;
59+
}
60+
61+
@media (min-width: 768px) {
62+
.success h1 {
63+
font-size: 3.2rem;
64+
justify-content: flex-end;
65+
}
3966
}
4067

4168
.success a {
@@ -44,16 +71,28 @@
4471
}
4572

4673
.success svg {
47-
width: 3rem;
74+
width: 2rem;
4875
margin-right: 0.8rem;
4976
}
5077

78+
@media (min-width: 768px) {
79+
.success svg {
80+
width: 3rem;
81+
}
82+
}
83+
5184
.failure {
5285
min-height: 100vh;
5386
display: flex;
5487
flex-direction: column;
5588
justify-content: center;
56-
padding: 2rem;
89+
padding: 1rem;
90+
}
91+
92+
@media (min-width: 768px) {
93+
.failure {
94+
padding: 2rem;
95+
}
5796
}
5897

5998
.failure {
@@ -63,22 +102,34 @@
63102
}
64103

65104
.failure h1 {
66-
font-size: 3.2rem;
105+
font-size: 2rem;
67106
display: flex;
68107
align-items: center;
69108
justify-content: center;
70109
}
71110

111+
@media (min-width: 768px) {
112+
.failure h1 {
113+
font-size: 3.2rem;
114+
}
115+
}
116+
72117
.failure a {
73118
color: #fff;
74119
font-weight: 800;
75120
}
76121

77122
.failure svg {
78-
width: 3rem;
123+
width: 2rem;
79124
margin-right: 0.8rem;
80125
}
81126

127+
@media (min-width: 768px) {
128+
.failure svg {
129+
width: 3rem;
130+
}
131+
}
132+
82133
.info {
83134
margin-top: 2rem;
84135
}
@@ -88,10 +139,16 @@ p + p {
88139
}
89140

90141
.next h2 {
91-
font-size: 2rem;
142+
font-size: 1.5rem;
92143
color: #0648b3;
93144
}
94145

146+
@media (min-width: 768px) {
147+
.next h2 {
148+
font-size: 2rem;
149+
}
150+
}
151+
95152
.next .options {
96153
margin-top: 2rem;
97154
display: flex;
@@ -116,3 +173,41 @@ p + p {
116173
a + a {
117174
margin-top: 0.6rem;
118175
}
176+
177+
/* Mobile-specific improvements */
178+
@media (max-width: 767px) {
179+
.next .options {
180+
align-items: stretch;
181+
}
182+
183+
.next a {
184+
padding: 0.5rem 0;
185+
word-wrap: break-word;
186+
}
187+
188+
.info {
189+
margin-top: 1rem;
190+
}
191+
192+
.info p {
193+
font-size: 0.95rem;
194+
line-height: 1.5;
195+
}
196+
}
197+
198+
/* Ensure text doesn't overflow on very small screens */
199+
@media (max-width: 480px) {
200+
.success h1,
201+
.failure h1 {
202+
font-size: 1.5rem;
203+
}
204+
205+
.next h2 {
206+
font-size: 1.2rem;
207+
}
208+
209+
.success svg,
210+
.failure svg {
211+
width: 1.5rem;
212+
}
213+
}

0 commit comments

Comments
 (0)