Skip to content

Commit d7219f8

Browse files
authored
feat: fix registration process (#18)
1 parent 30e8ec0 commit d7219f8

File tree

9 files changed

+23
-20
lines changed

9 files changed

+23
-20
lines changed

.env.example

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ MAIL_PASSWORD=null
3131
MAIL_ENCRYPTION=null
3232

3333
GITHUB_TOKEN=
34-
PAY_DURING_REGISTRATION=false
34+
PAY_TO_MONITOR=false

app/Http/Controllers/Auth/RegisterController.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public function store(Request $request)
3030
->withErrors($validator);
3131
}
3232

33-
if (env('PAY_DURING_REGISTRATION') == true) {
33+
if (env('PAY_TO_MONITOR') == true) {
3434
\Stripe\Stripe::setApiKey(env('STRIPE_API_KEY'));
3535

3636
$token = $request->get('stripeToken');

public/css/app.css

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/mix-manifest.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"/js/app.js": "/js/app.js?id=6a050788c69c8570b7b6",
3-
"/css/app.css": "/css/app.css?id=822ab418222f40063303"
3+
"/css/app.css": "/css/app.css?id=0b1ed5cdc95e963e530e"
44
}

readme.md

+4
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@
44

55
<div align="center">
66
<strong>Egonotifier monitors repositories you care about and sends you an email when they reach new milestones.</strong>
7+
<p align="center">
8+
<a href="https://github.com/djaiss/egonotifier"><img alt="GitHub Actions status" src="https://github.com/djaiss/egonotifier/workflows/Unit%20tests/badge.svg"></a>
9+
</p>
10+
</p>
711
</div>
812

913
## What you'll get

resources/sass/app.scss

-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,6 @@ a:visited {
8080
.marketing {
8181
background-color: #fff;
8282

83-
p,
8483
li,
8584
ol {
8685
font-size: 18px;

resources/views/add.blade.php

+12
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,23 @@
1313
@endif
1414
<form method="POST" action="/create" class="mb1">
1515
@csrf
16+
1617
https://github.com/
1718
<input class="br2 f5 w-30 ba b--black-40 pa2 outline-0" type="text" name="username" value="{{ old('username') }}" placeholder="username" required autofocus>
1819
/
1920
<input class="br2 f5 w-30 ba b--black-40 pa2 outline-0" type="text" name="repository" value="{{ old('repository') }}" placeholder="repository" required>
2021
<button type="submit" class="pointer btn btn bg-white f5 ph3 pv2 fw4 br3 di-ns db w-100 w-10-ns mt3 mt0-ns">Add</button>
22+
23+
@if (env('PAY_TO_MONITOR') == true)
24+
<label for="card-element" class="dib mb2">
25+
Credit or debit card for the <strong>$10 one-time fee</strong> (handled by <a href="https://stripe.com">Stripe</a>)
26+
</label>
27+
<div id="card-element" class="mb4">
28+
<!-- A Stripe Element will be inserted here. -->
29+
</div>
30+
<!-- Used to display Element errors. -->
31+
<div id="card-errors" role="alert"></div>
32+
@endif
2133
</form>
2234

2335
<p class="f7 silver">We'll check the repository every 5 minutes to check if statistics have changed.</p>

resources/views/auth/register.blade.php

-11
Original file line numberDiff line numberDiff line change
@@ -44,17 +44,6 @@
4444
</div>
4545
</div>
4646

47-
@if (env('PAY_DURING_REGISTRATION') == true)
48-
<label for="card-element" class="dib mb2">
49-
Credit or debit card for the <strong>$10 one-time fee</strong> (handled by <a href="https://stripe.com">Stripe</a>)
50-
</label>
51-
<div id="card-element" class="mb4">
52-
<!-- A Stripe Element will be inserted here. -->
53-
</div>
54-
<!-- Used to display Element errors. -->
55-
<div id="card-errors" role="alert"></div>
56-
@endif
57-
5847
<div class="mb-0">
5948
<div class=" offset-md-4 tc">
6049
<button class="pointer btn btn bg-white f5 ph3 pv2 fw4 br3 di-ns db w-100 w-50-ns mt3 mt0-ns mr3">

resources/views/welcome.blade.php

+3-4
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,9 @@
6565
<div class="mw7 center ph3-ns">
6666
<div class="cf ph2-ns">
6767
<div class="fl w-100 pa2 pr4-ns">
68-
<p class="tc mb5"><a href="/register" class="ph4 pv3 cta br3 no-underline">Get started</a></p>
68+
<p class="tc mb4"><a href="/register" class="ph4 pv3 cta br3 no-underline">Get started</a></p>
69+
70+
<p class="tc mb5 f6">The first repository is free. Unlock unlimited repositories for a $10 one-time fee.</p>
6971

7072
<p class="lh-copy quote tc mb5">"I have a repository on Github, but I keep missing important milestones, like when it reached 500 stars."</p>
7173

@@ -99,9 +101,6 @@
99101
<li>
100102
Create your account,
101103
</li>
102-
<li>
103-
Pay a one-time fee (more on that later),
104-
</li>
105104
<li>
106105
Indicate which repositories you want to monitor. It could be one of your repo, or any other public repo on Github.
107106
</li>

0 commit comments

Comments
 (0)