- Basic HTML templates
- Created entities & new migration - Added packages symfony/stimulus-bundle & symfony/webpack-encore-bundle
This commit is contained in:
+200
-3
@@ -1,16 +1,213 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<html data-bs-theme="dark">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>{% block title %}Welcome!{% endblock %}</title>
|
||||
<link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 128 128%22><text y=%221.2em%22 font-size=%2296%22>⚫️</text></svg>">
|
||||
{% block stylesheets %}
|
||||
{{ encore_entry_link_tags('app') }}
|
||||
{% endblock %}
|
||||
{% block extra_stylesheets %}{% endblock %}
|
||||
|
||||
{% block javascripts %}
|
||||
{{ encore_entry_script_tags('app') }}
|
||||
{% endblock %}
|
||||
{% block extra_javascripts %}{% endblock %}
|
||||
</head>
|
||||
|
||||
<body>
|
||||
{% block body %}{% endblock %}
|
||||
{% if is_granted('ROLE_USER') %}
|
||||
{# Main Navigation #}
|
||||
<header>
|
||||
{# Sidebar #}
|
||||
<nav id="sidebarMenu" class="collapse d-lg-block sidebar collapse bg-body-tertiary">
|
||||
<div class="position-sticky">
|
||||
<div class="list-group list-group-flush mx-3 mt-4">
|
||||
<a href="#" class="list-group-item list-group-item-action py-2 ripple{{ app.current_route() == 'app_dashboard' ? ' active' : '' }}" aria-current="true">
|
||||
<i class="fas fa-tachometer-alt fa-fw me-3"></i>
|
||||
<span>Dashboard</span>
|
||||
</a>
|
||||
<a href="#" class="list-group-item list-group-item-action py-2 ripple">
|
||||
<i class="fas fa-comments fa-fw me-3"></i>
|
||||
<span>Comments</span>
|
||||
</a>
|
||||
<a href="#" class="list-group-item list-group-item-action py-2 ripple">
|
||||
<i class="fas fa-globe fa-fw me-3"></i>
|
||||
<span>Domains</span>
|
||||
</a>
|
||||
<a href="#" class="list-group-item list-group-item-action py-2 ripple">
|
||||
<i class="fas fa-users fa-fw me-3"></i>
|
||||
<span>Users</span>
|
||||
</a>
|
||||
<a href="#" class="list-group-item list-group-item-action py-2 ripple">
|
||||
<i class="fas fa-chart-bar fa-fw me-3"></i>
|
||||
<span>Stats</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
{# Sidebar #}
|
||||
|
||||
{# Navbar #}
|
||||
<nav id="main-navbar" class="navbar navbar-expand-lg navbar-light bg-body-secondary fixed-top">
|
||||
{# Container wrapper #}
|
||||
<div class="container-fluid">
|
||||
{# Toggle button #}
|
||||
<button
|
||||
class="navbar-toggler"
|
||||
type="button"
|
||||
data-mdb-toggle="collapse"
|
||||
data-mdb-target="#sidebarMenu"
|
||||
aria-controls="sidebarMenu"
|
||||
aria-expanded="false"
|
||||
aria-label="Toggle navigation"
|
||||
>
|
||||
<i class="fas fa-bars"></i>
|
||||
</button>
|
||||
|
||||
{# Brand #}
|
||||
<a class="navbar-brand" href="#">
|
||||
MyComments
|
||||
</a>
|
||||
{# Search form #}
|
||||
{# <form class="d-none d-md-flex input-group w-auto my-auto">#}
|
||||
{# <input#}
|
||||
{# autocomplete="off"#}
|
||||
{# type="search"#}
|
||||
{# class="form-control rounded"#}
|
||||
{# placeholder='Search (ctrl + "/" to focus)'#}
|
||||
{# style="min-width: 225px"#}
|
||||
{# />#}
|
||||
{# <span class="input-group-text border-0"#}
|
||||
{# ><i class="fas fa-search"></i#}
|
||||
{# ></span>#}
|
||||
{# </form>#}
|
||||
|
||||
{# Right links #}
|
||||
<ul class="navbar-nav ms-auto d-flex flex-row">
|
||||
{# Notification dropdown #}
|
||||
<li class="nav-item dropdown">
|
||||
<a
|
||||
class="nav-link me-3 px-3 me-lg-0 dropdown-toggle hidden-arrow"
|
||||
href="#"
|
||||
id="navbarDropdownMenuLink"
|
||||
role="button"
|
||||
data-mdb-toggle="dropdown"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<i class="fas fa-bell"></i>
|
||||
<span class="badge rounded-pill badge-notification bg-danger"
|
||||
>1</span
|
||||
>
|
||||
</a>
|
||||
<ul
|
||||
class="dropdown-menu dropdown-menu-end"
|
||||
aria-labelledby="navbarDropdownMenuLink"
|
||||
>
|
||||
<li><a class="dropdown-item" href="#">Some news</a></li>
|
||||
<li><a class="dropdown-item" href="#">Another news</a></li>
|
||||
<li>
|
||||
<a class="dropdown-item" href="#">Something else here</a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
{# Icon #}
|
||||
{# <li class="nav-item me-3 me-lg-0">#}
|
||||
{# <a class="nav-link" href="#">#}
|
||||
{# <i class="fab fa-github"></i>#}
|
||||
{# </a>#}
|
||||
{# </li>#}
|
||||
|
||||
{# Icon dropdown #}
|
||||
{# <li class="nav-item dropdown">#}
|
||||
{# <a#}
|
||||
{# class="nav-link me-3 me-lg-0 dropdown-toggle hidden-arrow"#}
|
||||
{# href="#"#}
|
||||
{# id="navbarDropdown"#}
|
||||
{# role="button"#}
|
||||
{# data-mdb-toggle="dropdown"#}
|
||||
{# aria-expanded="false"#}
|
||||
{# >#}
|
||||
{# <i class="united kingdom flag m-0"></i>#}
|
||||
{# </a>#}
|
||||
{# <ul class="dropdown-menu dropdown-menu-end" aria-labelledby="navbarDropdown">#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#">#}
|
||||
{# <i class="united kingdom flag"></i>English <i class="fa fa-check text-success ms-2"></i>#}
|
||||
{# </a>#}
|
||||
{# </li>#}
|
||||
{# <li><hr class="dropdown-divider" /></li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="poland flag"></i>Polski</a>#}
|
||||
{# </li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="china flag"></i>中文</a>#}
|
||||
{# </li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="japan flag"></i>日本語</a>#}
|
||||
{# </li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="germany flag"></i>Deutsch</a>#}
|
||||
{# </li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="france flag"></i>Français</a>#}
|
||||
{# </li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="spain flag"></i>Español</a>#}
|
||||
{# </li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="russia flag"></i>Русский</a>#}
|
||||
{# </li>#}
|
||||
{# <li>#}
|
||||
{# <a class="dropdown-item" href="#"><i class="portugal flag"></i>Português</a>#}
|
||||
{# </li>#}
|
||||
{# </ul>#}
|
||||
{# </li>#}
|
||||
|
||||
{# Avatar #}
|
||||
<li class="nav-item dropdown">
|
||||
<a
|
||||
class="nav-link dropdown-toggle hidden-arrow d-flex align-items-center"
|
||||
href="#"
|
||||
id="navbarDropdownMenuLink"
|
||||
role="button"
|
||||
data-mdb-toggle="dropdown"
|
||||
aria-expanded="false"
|
||||
>
|
||||
<img
|
||||
src="https://mdbootstrap.com/img/Photos/Avatars/img (31).jpg"
|
||||
class="rounded-circle"
|
||||
height="24"
|
||||
alt=""
|
||||
loading="lazy"
|
||||
/>
|
||||
</a>
|
||||
<ul
|
||||
class="dropdown-menu dropdown-menu-end"
|
||||
aria-labelledby="navbarDropdownMenuLink"
|
||||
>
|
||||
<li><a class="dropdown-item" href="#">My profile</a></li>
|
||||
<li><a class="dropdown-item" href="#">Settings</a></li>
|
||||
<li><a class="dropdown-item" href="{{ url('app_logout') }}">Logout</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
{# Container wrapper #}
|
||||
</nav>
|
||||
{# Navbar #}
|
||||
</header>
|
||||
{# Main Navigation #}
|
||||
{% endif %}
|
||||
|
||||
{% block container %}
|
||||
<main style="margin-top: 58px">
|
||||
<div class="container pt-4">
|
||||
{% block body %}{% endblock %}
|
||||
</div>
|
||||
</main>
|
||||
{% endblock %}
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -3,18 +3,6 @@
|
||||
{% block title %}Hello DashboardController!{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
<style>
|
||||
.example-wrapper { margin: 1em auto; max-width: 800px; width: 95%; font: 18px/1.5 sans-serif; }
|
||||
.example-wrapper code { background: #F5F5F5; padding: 2px 6px; }
|
||||
</style>
|
||||
|
||||
<div class="example-wrapper">
|
||||
<h1>Hello {{ controller_name }}! ✅</h1>
|
||||
|
||||
This friendly message is coming from:
|
||||
<ul>
|
||||
<li>Your controller at <code><a href="{{ '/home/skylar/Projects/MyComments/src/Controller/DashboardController.php'|file_link(0) }}">src/Controller/DashboardController.php</a></code></li>
|
||||
<li>Your template at <code><a href="{{ '/home/skylar/Projects/MyComments/templates/dashboard/index.html.twig'|file_link(0) }}">templates/dashboard/index.html.twig</a></code></li>
|
||||
</ul>
|
||||
</div>
|
||||
<h4>Dashboard</h4>
|
||||
<hr />
|
||||
{% endblock %}
|
||||
|
||||
@@ -1,20 +1,53 @@
|
||||
{% extends 'base.html.twig' %}
|
||||
|
||||
{% block body %}
|
||||
{% if error %}
|
||||
<div>{{ error.messageKey|trans(error.messageData, 'security') }}</div>
|
||||
{% endif %}
|
||||
{% block container %}
|
||||
|
||||
<form action="{{ path('app_login') }}" method="post">
|
||||
<label for="username">Email:</label>
|
||||
<input type="text" id="username" name="_username" value="{{ last_username }}">
|
||||
<section class="vh-100 gradient-custom">
|
||||
<div class="container py-5 h-100">
|
||||
<div class="row d-flex justify-content-center align-items-center h-100">
|
||||
<div class="col-12 col-md-8 col-lg-6 col-xl-5">
|
||||
<div class="card bg-dark text-white" style="border-radius: 1rem;">
|
||||
<div class="card-body p-5 text-center">
|
||||
|
||||
<label for="password">Password:</label>
|
||||
<input type="password" id="password" name="_password">
|
||||
<div class="mb-md-5 mt-md-4 pb-5">
|
||||
<form action="{{ path('app_login') }}" method="post">
|
||||
|
||||
{# If you want to control the URL the user is redirected to on success
|
||||
<input type="hidden" name="_target_path" value="/account"> #}
|
||||
<h2 class="fw-bold mb-5">MyComments Login</h2>
|
||||
{% if error %}
|
||||
<div class="alert alert-danger" role="alert">
|
||||
{{ error.messageKey|trans(error.messageData, 'security') }}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<button type="submit">login</button>
|
||||
</form>
|
||||
{% endblock %}
|
||||
<div class="form-outline form-white mb-4">
|
||||
<input type="email" id="typeEmailX" name="_username" class="form-control form-control-lg" value="{{ last_username }}" />
|
||||
<label class="form-label" for="typeEmailX">Email</label>
|
||||
</div>
|
||||
|
||||
<div class="form-outline form-white mb-4">
|
||||
<input type="password" id="typePasswordX" name="_password" class="form-control form-control-lg" />
|
||||
<label class="form-label" for="typePasswordX">Password</label>
|
||||
</div>
|
||||
|
||||
<button class="btn btn-outline-light btn-lg px-5" type="submit">Login</button>
|
||||
|
||||
<div class="d-flex justify-content-center text-center mt-4 pt-1">
|
||||
<a href="#" class="text-white"><i class="fab fa-google fa-lg mx-1"></i></a>
|
||||
<a href="#" class="text-white"><i class="fab fa-github fa-lg mx-1"></i></a>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<p class="mb-0"><a href="#!" class="text-white-50 fw-bold">Forgot your password?</a></p>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user