summaryrefslogtreecommitdiff
path: root/resources
diff options
context:
space:
mode:
authorFbenas <philbeansburton@gmail.com>2020-06-19 02:16:51 +0100
committerFbenas <philbeansburton@gmail.com>2020-06-19 02:16:51 +0100
commitd1fe4536cc039450b540104e382db0d01d5cf886 (patch)
treefd40ab48f79370541f377b59bb381811126485ad /resources
parentc83e876693bdb71c66418c13f5e09dfdaef24478 (diff)
Initial commit
Diffstat (limited to 'resources')
-rw-r--r--resources/js/bootstrap.js13
-rw-r--r--resources/sass/_variables.scss19
-rw-r--r--resources/sass/app.scss9
-rw-r--r--resources/views/index.blade.php49
-rw-r--r--resources/views/layout/default.blade.php20
-rw-r--r--resources/views/layout/partial/footer-scripts.blade.php0
-rw-r--r--resources/views/layout/partial/footer.blade.php0
-rw-r--r--resources/views/layout/partial/head.blade.php13
-rw-r--r--resources/views/layout/partial/header.blade.php0
-rw-r--r--resources/views/layout/partial/nav.blade.php0
-rw-r--r--resources/views/welcome.blade.php100
11 files changed, 122 insertions, 101 deletions
diff --git a/resources/js/bootstrap.js b/resources/js/bootstrap.js
index 6922577..63605fa 100644
--- a/resources/js/bootstrap.js
+++ b/resources/js/bootstrap.js
@@ -1,6 +1,19 @@
window._ = require('lodash');
/**
+ * We'll load jQuery and the Bootstrap jQuery plugin which provides support
+ * for JavaScript based Bootstrap features such as modals and tabs. This
+ * code may be modified to fit the specific needs of your application.
+ */
+
+try {
+ window.Popper = require('popper.js').default;
+ window.$ = window.jQuery = require('jquery');
+
+ require('bootstrap');
+} catch (e) {}
+
+/**
* We'll load the axios HTTP library which allows us to easily issue requests
* to our Laravel back-end. This library automatically handles sending the
* CSRF token as a header based on the value of the "XSRF" token cookie.
diff --git a/resources/sass/_variables.scss b/resources/sass/_variables.scss
new file mode 100644
index 0000000..0407ab5
--- /dev/null
+++ b/resources/sass/_variables.scss
@@ -0,0 +1,19 @@
+// Body
+$body-bg: #f8fafc;
+
+// Typography
+$font-family-sans-serif: 'Nunito', sans-serif;
+$font-size-base: 0.9rem;
+$line-height-base: 1.6;
+
+// Colors
+$blue: #3490dc;
+$indigo: #6574cd;
+$purple: #9561e2;
+$pink: #f66d9b;
+$red: #e3342f;
+$orange: #f6993f;
+$yellow: #ffed4a;
+$green: #38c172;
+$teal: #4dc0b5;
+$cyan: #6cb2eb;
diff --git a/resources/sass/app.scss b/resources/sass/app.scss
index 8337712..3193ffa 100644
--- a/resources/sass/app.scss
+++ b/resources/sass/app.scss
@@ -1 +1,8 @@
-//
+// Fonts
+@import url('https://fonts.googleapis.com/css?family=Nunito');
+
+// Variables
+@import 'variables';
+
+// Bootstrap
+@import '~bootstrap/scss/bootstrap';
diff --git a/resources/views/index.blade.php b/resources/views/index.blade.php
new file mode 100644
index 0000000..cde358d
--- /dev/null
+++ b/resources/views/index.blade.php
@@ -0,0 +1,49 @@
+@extends('layout.default')
+
+@section('content')
+
+
+@foreach ($tournaments as $tournament)
+
+<div class="container">
+ <div class="mt-4">
+ <h1>{{ $tournament->name }}</h1>
+ </div>
+
+ <div class="mt-4">
+
+ <table class="table">
+
+ <thead>
+ <tr>
+ <th scope="col">#</th>
+ <th scope="col">Home</th>
+ <td scope="col"></td>
+ <th scope="col">Away</th>
+ <th scope="col">Venue</th>
+ <th scope="col">Referee</th>
+ <th scope="col">Date</th>
+ </tr>
+ </thead>
+
+ <tbody>
+
+ @foreach ($tournament->matches as $match)
+ <tr>
+ <th scope="row">{{ $match->id }}</th>
+ <td>{{ $match->homeTeam()->first()->getName() }}</td>
+ <td>{{ $match->score }} <br> {{$match->half_score}}</td>
+ <td>{{ $match->awayTeam()->first()->getName() }}</td>
+ <td>{{ $match->getDisplayName() }}</td>
+ <td>{{ $match->referee }}</td>
+ <td>{{ $match->getDisplayDate() }}</td>
+ </tr>
+ @endforeach
+ </tbody>
+
+ </table>
+ </div>
+</div>
+@endforeach
+
+@endsection \ No newline at end of file
diff --git a/resources/views/layout/default.blade.php b/resources/views/layout/default.blade.php
new file mode 100644
index 0000000..f39de87
--- /dev/null
+++ b/resources/views/layout/default.blade.php
@@ -0,0 +1,20 @@
+<!DOCTYPE html>
+<html lang="en">
+
+<head>
+ @include('layout.partial.head')
+</head>
+
+<body>
+ @include('layout.partial.nav')
+
+ @include('layout.partial.header')
+
+ @yield('content')
+
+ @include('layout.partial.footer')
+
+ @include('layout.partial.footer-scripts')
+</body>
+
+</html> \ No newline at end of file
diff --git a/resources/views/layout/partial/footer-scripts.blade.php b/resources/views/layout/partial/footer-scripts.blade.php
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/resources/views/layout/partial/footer-scripts.blade.php
diff --git a/resources/views/layout/partial/footer.blade.php b/resources/views/layout/partial/footer.blade.php
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/resources/views/layout/partial/footer.blade.php
diff --git a/resources/views/layout/partial/head.blade.php b/resources/views/layout/partial/head.blade.php
new file mode 100644
index 0000000..1b63459
--- /dev/null
+++ b/resources/views/layout/partial/head.blade.php
@@ -0,0 +1,13 @@
+<meta charset="utf-8">
+
+<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
+<meta name="description" content="Rugby">
+<meta name="author" content="Phil Burton">
+
+<title>Rugby</title>
+
+<!-- Bootstrap core CSS -->
+
+
+<!-- Custom styles for this template -->
+<link href="/css/app.css" rel="stylesheet"> \ No newline at end of file
diff --git a/resources/views/layout/partial/header.blade.php b/resources/views/layout/partial/header.blade.php
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/resources/views/layout/partial/header.blade.php
diff --git a/resources/views/layout/partial/nav.blade.php b/resources/views/layout/partial/nav.blade.php
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/resources/views/layout/partial/nav.blade.php
diff --git a/resources/views/welcome.blade.php b/resources/views/welcome.blade.php
deleted file mode 100644
index 3fb48cc..0000000
--- a/resources/views/welcome.blade.php
+++ /dev/null
@@ -1,100 +0,0 @@
-<!DOCTYPE html>
-<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
- <head>
- <meta charset="utf-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
-
- <title>Laravel</title>
-
- <!-- Fonts -->
- <link href="https://fonts.googleapis.com/css?family=Nunito:200,600" rel="stylesheet">
-
- <!-- Styles -->
- <style>
- html, body {
- background-color: #fff;
- color: #636b6f;
- font-family: 'Nunito', sans-serif;
- font-weight: 200;
- height: 100vh;
- margin: 0;
- }
-
- .full-height {
- height: 100vh;
- }
-
- .flex-center {
- align-items: center;
- display: flex;
- justify-content: center;
- }
-
- .position-ref {
- position: relative;
- }
-
- .top-right {
- position: absolute;
- right: 10px;
- top: 18px;
- }
-
- .content {
- text-align: center;
- }
-
- .title {
- font-size: 84px;
- }
-
- .links > a {
- color: #636b6f;
- padding: 0 25px;
- font-size: 13px;
- font-weight: 600;
- letter-spacing: .1rem;
- text-decoration: none;
- text-transform: uppercase;
- }
-
- .m-b-md {
- margin-bottom: 30px;
- }
- </style>
- </head>
- <body>
- <div class="flex-center position-ref full-height">
- @if (Route::has('login'))
- <div class="top-right links">
- @auth
- <a href="{{ url('/home') }}">Home</a>
- @else
- <a href="{{ route('login') }}">Login</a>
-
- @if (Route::has('register'))
- <a href="{{ route('register') }}">Register</a>
- @endif
- @endauth
- </div>
- @endif
-
- <div class="content">
- <div class="title m-b-md">
- Laravel
- </div>
-
- <div class="links">
- <a href="https://laravel.com/docs">Docs</a>
- <a href="https://laracasts.com">Laracasts</a>
- <a href="https://laravel-news.com">News</a>
- <a href="https://blog.laravel.com">Blog</a>
- <a href="https://nova.laravel.com">Nova</a>
- <a href="https://forge.laravel.com">Forge</a>
- <a href="https://vapor.laravel.com">Vapor</a>
- <a href="https://github.com/laravel/laravel">GitHub</a>
- </div>
- </div>
- </div>
- </body>
-</html>