Skip to content

Commit 7bc7710

Browse files
committed
Merge branch 'main' into release-0.2
2 parents b485e21 + a2ad519 commit 7bc7710

File tree

6 files changed

+76
-124
lines changed

6 files changed

+76
-124
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
export default async function (to, from, savedPosition) {
2+
if (savedPosition) {
3+
return savedPosition;
4+
}
5+
6+
const findEl = async (hash, x = 0) => {
7+
return (
8+
document.querySelector(hash) ||
9+
new Promise(resolve => {
10+
if (x > 50) {
11+
return resolve(document.querySelector('#app'));
12+
}
13+
setTimeout(() => {
14+
resolve(findEl(hash, ++x || 1));
15+
}, 100);
16+
})
17+
);
18+
};
19+
20+
const main = document.querySelector('.main');
21+
22+
if (to.hash) {
23+
console.log('🚀 ~ file: scrollBehavior.js ~ line 23 ~ to.hash', to.hash);
24+
let el = await findEl(to.hash);
25+
if ('scrollBehavior' in document.documentElement.style) {
26+
return main.scrollTo({ top: el.offsetTop, behavior: 'smooth' });
27+
} else {
28+
return main.scrollTo(0, el.offsetTop);
29+
}
30+
}
31+
32+
main.scrollTo({ top: 0, behavior: 'smooth' });
33+
return { x: 0, y: 0 };
34+
}

web/ui/website/content/docs/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ $ curl \
142142
--request POST \
143143
--data @endpoint.json \
144144
-H "Content-Type: application/json" \
145-
http://localhost:5005/api/v1/applications/e0e1240a-96dc-4408-a335-144eb3749d34/endpoints
145+
http://localhost:5005/api/v1/applications/{appID}/endpoints
146146
```
147147

148148
```json[Response]
@@ -164,7 +164,7 @@ $ curl \
164164

165165
```json[Sample Payload]
166166
{
167-
"app_id": "e0e1240a-96dc-4408-a335-144eb3749d34",
167+
"app_id": "{appID}",
168168
"event_type": "payment.success",
169169
"data": {
170170
"event": "payment.success",

web/ui/website/functions/subscribe/package.json

Lines changed: 0 additions & 14 deletions
This file was deleted.

web/ui/website/functions/subscribe/subscribe.js

Lines changed: 0 additions & 57 deletions
This file was deleted.

web/ui/website/nuxt.config.js

Lines changed: 1 addition & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -57,40 +57,5 @@ export default {
5757

5858
// Build Configuration: https://go.nuxtjs.dev/config-build
5959
build: {},
60-
runtimeCompiler: true,
61-
router: {
62-
scrollBehavior: async function (to, from, savedPosition) {
63-
if (savedPosition) {
64-
return savedPosition;
65-
}
66-
67-
const findEl = async (hash, x = 0) => {
68-
return (
69-
document.querySelector(hash) ||
70-
new Promise(resolve => {
71-
if (x > 50) {
72-
return resolve(document.querySelector('#app'));
73-
}
74-
setTimeout(() => {
75-
resolve(findEl(hash, ++x || 1));
76-
}, 100);
77-
})
78-
);
79-
};
80-
81-
const main = document.querySelector('.main');
82-
83-
if (to.hash) {
84-
let el = await findEl(to.hash);
85-
if ('scrollBehavior' in document.documentElement.style) {
86-
return main.scrollTo({ top: el.offsetTop, behavior: 'smooth' });
87-
} else {
88-
return main.scrollTo(0, el.offsetTop);
89-
}
90-
}
91-
92-
main.scrollTo({ top: 0, behavior: 'smooth' });
93-
return { x: 0, y: 0 };
94-
}
95-
}
60+
runtimeCompiler: true
9661
};

web/ui/website/pages/index.vue

Lines changed: 39 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,14 @@
3434
<div class="hero-section--cta">
3535
<h1>A Cloud native Webhook Service</h1>
3636
<p>With out-of-the-box security, reliability and scalability for your webhooks infrastructure.</p>
37+
<nuxt-link to="/docs">Get Started</nuxt-link>
3738

3839
<form @submit.prevent="requestAccess()">
3940
<div class="input">
40-
<input type="text" id="github" placeholder="Enter your github username" aria-label="Github Name" v-model="earlyAccessGithubName" />
41+
<input type="email" id="email" placeholder="Enter your email" aria-label="Email" v-model="earlyAccessEmail" />
4142
</div>
4243
<button :disabled="isSubmitingloadingEarlyAccessForm">{{ isSubmitingloadingEarlyAccessForm ? '...requesting' : earlyAccessFormButtonText }}</button>
4344
</form>
44-
<!-- <button>Get Started</button> -->
4545
</div>
4646
<div class="hero-section--img">
4747
<img src="~/assets/images/hero-img.png" alt="hero" />
@@ -214,8 +214,8 @@ export default {
214214
return {
215215
showMenu: false,
216216
isSubmitingloadingEarlyAccessForm: false,
217-
earlyAccessFormButtonText: 'Get Early Access',
218-
earlyAccessGithubName: ''
217+
earlyAccessFormButtonText: 'Convoy Cloud Early Access',
218+
earlyAccessEmail: ''
219219
};
220220
},
221221
async asyncData({ $content, params }) {
@@ -237,7 +237,7 @@ export default {
237237
redirect: 'follow',
238238
referrerPolicy: 'no-referrer',
239239
body: JSON.stringify({
240-
githubName: this.earlyAccessGithubName
240+
email: this.earlyAccessEmail
241241
})
242242
});
243243
await response.json();
@@ -252,7 +252,7 @@ export default {
252252
},
253253
setDefaultAccessButtonText() {
254254
setTimeout(() => {
255-
this.earlyAccessFormButtonText = 'Get Early Access';
255+
this.earlyAccessFormButtonText = 'Convoy Cloud Early Access';
256256
}, 5000);
257257
}
258258
}
@@ -322,7 +322,7 @@ header {
322322
323323
&.show {
324324
padding-top: 20px;
325-
height: 175px;
325+
height: 233px;
326326
overflow-y: auto;
327327
display: block;
328328
}
@@ -429,12 +429,33 @@ header {
429429
}
430430
}
431431
432+
button,
433+
a {
434+
background: #477db3;
435+
padding: 9px 21px;
436+
color: #ffffff;
437+
font-weight: 500;
438+
font-size: 14px;
439+
line-height: 28px;
440+
margin: 20px 0 0;
441+
max-width: 200px;
442+
width: 100%;
443+
display: block;
444+
border-radius: 5px;
445+
text-align: center;
446+
}
447+
432448
form {
433449
background: #ffffff;
434450
max-width: 430px;
435451
display: flex;
436452
border-radius: 8px;
437453
margin-top: 40px;
454+
flex-direction: column;
455+
456+
@media (min-width: $desktopBreakPoint) {
457+
flex-direction: row;
458+
}
438459
439460
.input {
440461
width: 100%;
@@ -459,16 +480,18 @@ header {
459480
}
460481
461482
button {
462-
background: #477db3;
463-
border-radius: 0 8px 8px 0;
464-
padding: 9px 21px;
465-
color: #ffffff;
466-
font-weight: 500;
467-
font-size: 14px;
468-
line-height: 28px;
469-
max-width: 162px;
483+
max-width: none;
470484
width: 100%;
471485
margin: 0;
486+
border-radius: 0 0 8px 8px;
487+
margin-top: 10px;
488+
489+
@media (min-width: $desktopBreakPoint) {
490+
max-width: 220px;
491+
width: 100%;
492+
margin-top: 0;
493+
border-radius: 0 8px 8px 0;
494+
}
472495
}
473496
}
474497
}
@@ -551,6 +574,7 @@ section.companies {
551574
display: grid;
552575
grid-template-columns: repeat(auto-fill, minmax(238px, 1fr));
553576
gap: 80px 32px;
577+
margin-bottom: 50px;
554578
555579
img {
556580
width: 70px;

0 commit comments

Comments
 (0)