Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2020 DotKernel (https://www.dotkernel.com)
Copyright (c) 2020 Dotkernel (https://www.dotkernel.com)

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,18 @@ Documentation is available at: https://docs.dotkernel.org/frontend-documentation
[![Qodana](https://github.com/dotkernel/frontend/actions/workflows/qodana_code_quality.yml/badge.svg)](https://github.com/dotkernel/frontend/actions/workflows/qodana_code_quality.yml)
[![PHPStan](https://github.com/dotkernel/frontend/actions/workflows/static-analysis.yml/badge.svg?branch=5.0)](https://github.com/dotkernel/frontend/actions/workflows/static-analysis.yml)

## Installing DotKernel `frontend`
## Installing Dotkernel `frontend`

- [Installing DotKernel `frontend`](#installing-dotkernel-frontend)
- [Installing Dotkernel `frontend`](#installing-dotkernel-frontend)
- [Composer](#composer)
- [Choose a destination path for DotKernel `frontend` installation](#choosing-an-installation-path-for-dotkernel-frontend)
- [Installing DotKernel Frontend](#installing-dotkernel-frontend)
- [Choose a destination path for Dotkernel `frontend` installation](#choosing-an-installation-path-for-dotkernel-frontend)
- [Installing Dotkernel Frontend](#installing-dotkernel-frontend)
- [Configuration - First Run](#configuration---first-run)
- [Testing (Running)](#running-the-application)

## Tools

DotKernel Frontend interface has been tested with npm v10.0.4 and Node.js v20.11.0.
Dotkernel Frontend interface has been tested with npm v10.0.4 and Node.js v20.11.0.

### Composer

Expand All @@ -53,16 +53,16 @@ Installation instructions:

> If you have never used composer before make sure you read the [`Composer Basic Usage`](https://getcomposer.org/doc/01-basic-usage.md) section in Composer's documentation

## Choosing an installation path for DotKernel `frontend`
## Choosing an installation path for Dotkernel `frontend`

Example:

- absolute path `/var/www/dk`
- or relative path `dk` (equivalent with `./dk`)

## Installing DotKernel `frontend`
## Installing Dotkernel `frontend`

After you choose the path for DotKernel Frontend (`dk` will be used for the remainder of this example), let's move onto installation.
After you choose the path for Dotkernel Frontend (`dk` will be used for the remainder of this example), let's move onto installation.

### Note

Expand All @@ -77,7 +77,7 @@ Problem 1

To enable an extension, remove the semicolon (;) in front of it.

#### Installing DotKernel `frontend` using git clone
#### Installing Dotkernel `frontend` using git clone

This method ensures that the default branch is installed, even if it is not released. Run the following command:

Expand All @@ -100,7 +100,7 @@ Please select which config file you wish to inject 'Laminas\Diactoros\ConfigProv
Make your selection (default is 1):
```

Simply select `[0] Do not inject`, because DotKernel includes its own configProvider which already contains the prompted configurations.
Simply select `[0] Do not inject`, because Dotkernel includes its own configProvider which already contains the prompted configurations.

If you choose `[1] config/config.php` Laminas's `ConfigProvider` from `session` will be injected.

Expand Down Expand Up @@ -137,7 +137,7 @@ Also feel free to add as many CCs as you want under the `contact` => `message_re

## Configuration - reCAPTCHA (optional)

reCAPTCHA is used to prevent abusive activities on your website. DotKernel frontend uses the Google reCAPTCHA for its contact us form.
reCAPTCHA is used to prevent abusive activities on your website. Dotkernel frontend uses the Google reCAPTCHA for its contact us form.
You must first generate a `siteKey` and `secretKey` in your Google account - [Google reCAPTCHA](https://www.google.com/recaptcha/admin)

Update the `recaptcha` array in `config/autoload/local.php` with the `siteKey` and `secretKey` from Google reCAPTCHA.
Expand Down Expand Up @@ -219,7 +219,7 @@ We recommend running your applications in WSL:
- set `$baseUrl` in **config/autoload/local.php** to the address of the virtualhost
- run the application by opening the virtualhost address in your browser

You should see the `DotKernel Frontend` welcome page.
You should see the `Dotkernel Frontend` welcome page.

**NOTE:**

Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "dotkernel/frontend",
"type": "project",
"description": "DotKernel Frontend Application",
"description": "Dotkernel Frontend Application",
"license": "MIT",
"homepage": "https://github.com/dotkernel/frontend",
"keywords": [
Expand All @@ -13,7 +13,7 @@
],
"authors": [
{
"name": "DotKernel Team",
"name": "Dotkernel Team",
"email": "team@dotkernel.com"
}
],
Expand Down
2 changes: 1 addition & 1 deletion config/autoload/app.global.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
declare(strict_types=1);

$app = [
'name' => 'DotKernel frontend V3',
'name' => 'Dotkernel frontend V5',
];

return [
Expand Down
2 changes: 1 addition & 1 deletion config/autoload/local.php.dist
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ $databases = [

return [
'application' => [
'name' => 'DotKernel',
'name' => 'Dotkernel',
'url' => $baseUrl,
],
'databases' => $databases,
Expand Down
2 changes: 1 addition & 1 deletion config/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class_exists(\Mezzio\Swoole\ConfigProvider::class)
return [];
},

// DotKernel packages
// Dotkernel packages
\Dot\Session\ConfigProvider::class,
\Dot\Mail\ConfigProvider::class,
\Laminas\Form\ConfigProvider::class,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
},
"keywords": [],
"author": {
"name": "DotKernel Team",
"name": "Dotkernel Team",
"email": "team@dotkernel.com"
},
"license": "ISC",
Expand Down
2 changes: 1 addition & 1 deletion public/css/app.css

Large diffs are not rendered by default.

5 changes: 2 additions & 3 deletions src/App/assets/scss/components/_pages.scss
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
/** General elements for pages **/
.page-intro {
position: relative;
padding: 120px 0;
padding: 100px 0 50px 0;
background: #F6F6F6;
text-align: center;
}

.page-intro p {
margin: 0 auto;
padding-bottom: 20px;
font-size: 18px;
color: #ABABAB;
max-width: 880px;
Expand Down Expand Up @@ -112,7 +111,7 @@
}

.home-list {
padding-top: 150px;
padding-top: 120px;
padding-bottom: 70px;
background: #FFFFFF;
text-align: center;
Expand Down
30 changes: 22 additions & 8 deletions src/App/templates/app/home.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
{{ messagesPartial('partial::alerts', {}, null, 'page-home') }}
<div class="page-intro home-intro">
<div class="container">
<p class="welcome">Dotkernel is a collection of</p>
<h1>PSR-7 Middleware applications</h1>
<p class="welcome">Dotkernel Frontend is a</p>
<h1>PSR-7 Middleware skeleton</h1>
<p>Built on top of the Mezzio microframework.<br/>Composed of a set of custom and extended Laminas components.</p>
</div>
<div class="arrow_down">
Expand All @@ -30,7 +30,11 @@
We have chosen <b>Laminas Service Manager</b> as our default implementation.
</p>
<p>
Get Started with <a href="https://github.com/laminas/laminas-servicemanager" target="_blank" class="text-decoration-none">Laminas Service Manager</a>
Get Started with
<br>
<a href="https://github.com/php-fig/container" target="_blank" class="text-decoration-none">PSR-11</a>
and
<a href="https://github.com/laminas/laminas-servicemanager" target="_blank" class="text-decoration-none">Laminas Service Manager</a>
</p>
</div>
<div class="col-lg-3 col-md-6">
Expand All @@ -39,10 +43,14 @@
</h3>
<p>
By default, no middleware in Laminas is templated.
For Dotkernel's Light application, we have chosen <b>Twig</b> as the default templating engine.
For Dotkernel's Frontend application, we have chosen <b>Twig</b> as the default templating engine.
</p>
<p>
Get started with <a href="https://twig.symfony.com/" target="_blank" class="text-decoration-none">Twig</a>
Get started with
<br>
<a href="https://twig.symfony.com/" target="_blank" class="text-decoration-none">Twig</a>
and
<a href="https://github.com/dotkernel/dot-twigrenderer" target="_blank" class="text-decoration-none">Dotkernel TwigRenderer</a>
</p>
</div>

Expand All @@ -54,7 +62,9 @@
Among the various routing implementations compatible with Expressive, we have chosen <b>FastRoute</b> as Dotkernel's default routing library.
</p>
<p>
Get started with <a href="https://github.com/nikic/FastRoute" target="_blank" class="text-decoration-none">FastRoute</a>
Get started with
<br>
<a href="https://github.com/nikic/FastRoute" target="_blank" class="text-decoration-none">FastRoute</a>
</p>
</div>
<div class="col-lg-3 col-md-6">
Expand All @@ -65,7 +75,11 @@
Laminas, and consequently Dotkernel, is built around the PSR-7 standard.<br />It uses <b>Laminas Diactoros</b> as the PSR-7 implementation.
</p>
<p>
Get started with <a href="https://github.com/php-fig/http-message" target="_blank" class="text-decoration-none">PSR-7</a> and <a href="https://github.com/laminas/laminas-diactoros" target="_blank" class="text-decoration-none">Diactoros</a>
Get started with
<br>
<a href="https://github.com/php-fig/http-message" target="_blank" class="text-decoration-none">PSR-7</a>
and
<a href="https://github.com/laminas/laminas-diactoros" target="_blank" class="text-decoration-none">Laminas Diactoros</a>
</p>
</div>
</div>
Expand Down Expand Up @@ -156,7 +170,7 @@
<ul class="list-unstyled list-group list-group-flush">
<li class="list-group-item">
<a href="https://github.com/dotkernel/dot-mail" target="_blank" class="text-decoration-none">dot-mail</a>
(<a href="https://docs.laminas.dev/laminas-mail/" target="_blank" class="text-decoration-none">laminas-mail</a>): send emails using different transport providers
(<a href="https://symfony.com/doc/current/mailer.html" target="_blank" class="text-decoration-none">symfony/mailer</a>): send emails using different transport providers
</li>
</ul>
</div>
Expand Down
6 changes: 3 additions & 3 deletions src/App/templates/layout/default.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />

<title>{% block title %}{% endblock %} | DotKernel frontend V5</title>
<title>{% block title %}{% endblock %} | Dotkernel frontend V5</title>
{% block canonical %}
<link rel="canonical" href="{{ url(routeName ?? null) }}" />
{% endblock %}
Expand Down Expand Up @@ -33,7 +33,7 @@
<a href="/" class="navbar-brand">
<img src="{{ asset('images/app/logo.svg') }}"
onerror="this.onerror=null; this.src='{{ asset('images/app/logo.png') }}';"
alt="DotKernel" />
alt="Dotkernel" />
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarHeader"
aria-controls="navbarHeader" aria-expanded="false" aria-label="Toggle navigation">
Expand Down Expand Up @@ -102,7 +102,7 @@
enjoy dotkernel
</p>
<p>
© {{ 'now'|date('Y') }} DotKernel by Apidemia
© 2024 - {{ 'now'|date('Y') }} Dotkernel by Apidemia
</p>
</div>
</footer>
Expand Down
4 changes: 2 additions & 2 deletions src/Contact/src/Service/MessageService.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,11 @@ public function sendContactMail(Message $message): bool
);
$this->mailService->getMessage()->addTo(
$this->config['contact']['message_receivers']['to'],
'DotKernel Team'
'Dotkernel Team'
);
$this->mailService->getMessage()->addCC(
$this->config['contact']['message_receivers']['cc'],
'DotKernel Team'
'Dotkernel Team'
);
$this->mailService->getMessage()->setReplyTo($message->getEmail(), $message->getName());

Expand Down
4 changes: 2 additions & 2 deletions test/Unit/Contact/Service/MessageServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public function testProcessMessage(): void
'default' => [
'message_options' => [
'from' => 'dotkernel@test.com',
'from_name' => 'DotKernel',
'from_name' => 'Dotkernel',
],
],
],
Expand All @@ -72,7 +72,7 @@ public function testProcessMessage(): void

$this->assertTrue($service->processMessage([
'email' => 'test@dotkernel.com',
'name' => 'DotKernel',
'name' => 'Dotkernel',
'subject' => 'test',
'message' => 'test message',
]));
Expand Down
2 changes: 1 addition & 1 deletion test/Unit/User/Adapter/AuthenticationAdapterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ public function testWillAuthenticate(): void
$detail = (new UserDetail())
->setUser($class)
->setFirstName('Test')
->setLastName('DotKernel');
->setLastName('Dotkernel');

$class
->addRole($role)
Expand Down