Skip to content

Commit 8e9bfba

Browse files
surelybassy01100100
authored andcommitted
Update button style and text formating
Slight changes to the button style made. Formatting of the text updated.
1 parent c5c140a commit 8e9bfba

File tree

2 files changed

+26
-13
lines changed

2 files changed

+26
-13
lines changed

app/src/index.html

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -167,19 +167,24 @@
167167
width: 50%;
168168
text-align: center;
169169
z-index: 1;
170-
background-image: linear-gradient(to right, #DA22FF 0%, #9733EE 51%, #DA22FF 100%);
171-
background-size: 200% auto;
170+
background-image: linear-gradient(45deg, #DA22FF, #9733EE, #DA22FF);
171+
background-size: 400% 400%;
172172
color: white;
173-
box-shadow: 0 0 5px 3px #eee;
173+
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
174174
margin: 0;
175175
border: none;
176-
border-radius: 3px;
177-
padding: 5px 5px;
176+
border-radius: 25px;
177+
padding: 10px 20px;
178+
font-size: 16px;
179+
font-weight: bold;
178180
cursor: pointer;
181+
transition: all 0.4s ease;
179182
}
180183

181184
.spin-button:hover {
182-
background-position: right center;
185+
background-position: 100% 0;
186+
box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
187+
transform: translate(-50%) scale(1.05);
183188
color: #fff;
184189
text-decoration: none;
185190
}
@@ -194,19 +199,24 @@
194199
width: 50%;
195200
text-align: center;
196201
z-index: 1;
197-
background-image: linear-gradient(to right, #DA22FF 0%, #9733EE 51%, #DA22FF 100%);
198-
background-size: 200% auto;
202+
background-image: linear-gradient(45deg, #DA22FF, #9733EE, #DA22FF);
203+
background-size: 400% 400%;
199204
color: white;
200-
box-shadow: 0 0 5px 3px #eee;
205+
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
201206
margin: 0;
202207
border: none;
203-
border-radius: 3px;
204-
padding: 5px 5px;
208+
border-radius: 25px;
209+
padding: 10px 20px;
210+
font-size: 16px;
211+
font-weight: bold;
205212
cursor: pointer;
213+
transition: all 0.4s ease;
206214
}
207215

208216
.reveal-button:hover {
209-
background-position: right center;
217+
background-position: 100% 0;
218+
box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
219+
transform: translate(-50%) scale(1.05);
210220
color: #fff;
211221
text-decoration: none;
212222
}

app/src/ui.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,6 +307,9 @@ export function showResults(feature: Feature<Geometry, GeoJsonProperties>) {
307307
}
308308
if (featureType) {
309309
featureEmoji = emojiMap[featureType];
310+
featureType = featureType.split('_')
311+
.map(word => word.charAt(0).toUpperCase() + word.slice(1))
312+
.join(' ');
310313
}
311314
console.log(featureProperties)
312315
const featureWebsite = featureProperties.website;
@@ -321,7 +324,7 @@ export function showResults(feature: Feature<Geometry, GeoJsonProperties>) {
321324
+ (featureOpeningHours ? `<p>${icon({ prefix: 'fas', iconName: 'clock' }).html} ${featureOpeningHours}</p>` : "")
322325
+ (featureWebsite ? `<p>${icon({ prefix: 'fas', iconName: 'globe' }).html} <a href="${featureWebsite}" target="_blank">${featureWebsite}</a></p>` : "")
323326
+ `
324-
<p>${icon({ prefix: 'fas', iconName: 'link' }).html} <a href="https://www.openstreetmap.org/${featureId}" target="_blank">https://www.openstreetmap.org/${featureId}</a></p>
327+
<p>${icon({ prefix: 'fas', iconName: 'link' }).html} <a href="https://www.openstreetmap.org/${featureId}" target="_blank">Open with OpenStreetMap</a></p>
325328
`;
326329
resultsContainer.appendChild(featureDetails);
327330

0 commit comments

Comments
 (0)