Initial commit to new repo

This commit is contained in:
Jonny Barnes 2016-05-19 15:01:28 +01:00
parent a267f9bfcc
commit a5173c981b
292 changed files with 17472 additions and 0 deletions

View file

@ -0,0 +1,13 @@
@extends('master')
@section('title')
Delete Article? « Admin CP
@stop
@section('content')
<form action="/admin/blog/delete/{{ $id }}" method="post">
<label for="delete">Are you sure you want to delete this post? </label><input type="checkbox" name="delete" id="delete">
<br>
<input type="submit" id="submit" value="Submit">
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Article Deleted « Admin CP
@stop
@section('content')
<p>You have successfully deletd the article with id: {{ $id }}</p>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Edit Client « Admin CP
@stop
@section('content')
<p>Successfully deleted the client information.</p>
@stop

View file

@ -0,0 +1,14 @@
@extends('master')
@section('title')
Delete Contact? « Admin CP
@stop
@section('content')
<form action="/admin/contacts/delete/{{ $id }}" method="post">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<label for="delete">Are you sure you want to delete this contact? </label><input type="checkbox" name="delete" id="delete">
<br>
<input type="submit" id="submit" value="Submit">
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Deleted Contact « Admin CP
@stop
@section('content')
<p>Successfully deleted the contact information.</p>
@stop

View file

@ -0,0 +1,13 @@
@extends('master')
@section('title')
Delete Token? « Admin CP
@stop
@section('content')
<form action="/admin/tokens/delete/{{ $id }}" method="post">
<label for="delete">Are you sure you want to delete this token? </label><input type="checkbox" name="delete" id="delete">
<br>
<input type="submit" id="submit" value="Submit">
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Token Deleted « Admin CP
@stop
@section('content')
<p>You have successfully deletd the token: {{ $id }}</p>
@stop

View file

@ -0,0 +1,41 @@
@extends('master')
@section('title')
Edit Article « Admin CP
@stop
@section('content')
<form action="/admin/blog/edit/{{ $id }}" method="post" accept-charset="utf-8">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<label for="title">Title (URL):</label>
<br>
<input type="text" name="title" id="title" value="{!! $post['0']['title'] !!}">
<br>
<input type="url" name="url" id="url" value="{!! $post['0']['url'] !!}">
<br>
<label for="main">Main:</label>
<br>
<textarea name="main" id="main">{{ $post['0']['main'] }}</textarea>
<br>
<label for="published">Published:</label><input type="checkbox" name="published" value="1"@if($post['0']['published'] == '1') checked="checked"@endif>
<br>
<input type="submit" name="save" value="Save">
</form>
<h2>Preview</h2>
@stop
@section('scripts')
@parent
<script src="{{ elixir('assets/js/marked.min.js') }}"></script>
<script>
var preview = document.createElement('div');
preview.classList.add('preview');
var main = document.querySelector('main');
main.appendChild(preview);
var textarea = document.querySelector('textarea');
window.setInterval(function () {
var markdown = textarea.value;
preview.innerHTML = marked(markdown);
}, 5000);
</script>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Article Successfully Edited « Admin CP
@stop
@section('content')
<p>Successfully edited article with id: {{ $id }}</p>
@stop

View file

@ -0,0 +1,15 @@
@extends('master')
@section('title')
Edit Client « Admin CP
@stop
@section('content')
<h1>Edit Client</h1>
<form action="/admin/clients/edit/{{ $id }}" method="post" accept-charset="utf-8">
<input type="text" name="client_url" id="client_url" value="{{ $client_url }}"><br>
<input type="text" name="client_name" id="client_name" value="{{ $client_name }}"><br>
<input type="submit" name="edit" value="Edit"><br><br>
<input type="submit" name="delete" value="Delete">
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Edit Client « Admin CP
@stop
@section('content')
<p>Successfully edited the client information.</p>
@stop

View file

@ -0,0 +1,20 @@
@extends('master')
@section('title')
Edit Contact « Admin CP
@stop
@section('content')
<h1>Edit Contact</h1>
<form action="/admin/contacts/edit/{{ $contact->id }}" method="post" enctype="multipart/form-data" accept-charset="utf-8">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<label for="name">Real Name:</label> <input type="text" name="name" id="name" placeholder="Real Name" value="{{ $contact->name }}"><br>
<label for="nick">Nick:</label> <input type="text" name="nick" id="nick" placeholder="local_nick" value="{{ $contact->nick }}"><br>
<label for="homepage">Homepage:</label> <input type="text" name="homepage" id="homepage" placeholder="https://homepage.com" value="{{ $contact->homepage }}"><br>
<label for="twitter">Twitter Nick:</label> <input type="text" name="twitter" id="twitter" placeholder="Twitter handle" value="{{ $contact->twitter }}"><br>
<label for="avatar">Avatar:</label> <input type="file" accept="image/*" value="Upluad" name="avatar" id="avatar"><br>
<input type="submit" name="submit" value="Submit">
</form>
<p>Or do you want to <a href="/admin/contacts/delete/{{ $contact->id }}">delete</a> this contact?</p>
<p>Instead of uploading an image, you can <a href="/admin/contacts/edit/{{ $contact->id }}/getavatar">grab from their homepage</a>?</p>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Edit Contact « Admin CP
@stop
@section('content')
<p>Successfully edited the contact information.</p>
@stop

View file

@ -0,0 +1,18 @@
@extends('master')
@section('title')
Edit Note « Admin CP
@stop
@section('content')
<form action="/admin/note/edit/{{ $id }}" method="post" accept-charset="utf-8">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<fieldset class="note-ui">
<legend>Edit Note</legend>
<label for="in-reply-to" accesskey="r">Reply-to: </label><input type="text" name="in-reply-to" id="in-reply-to" placeholder="in-reply-to-1 in-reply-to-2 …" tabindex="1" value="{{ $note->in_reply_to }}"><br>
<label for="content" accesskey="n">Note: </label><textarea name="content" id="content" placeholder="Note" tabindex="2">{{ $note->originalNote }}</textarea><br>
<label for="webmentions" accesskey="w">Send webmentions: </label><input type="checkbox" name="webmentions" id="webmentions" checked="checked" tabindex="3"><br>
<label for="kludge"></label><input type="submit" value="Submit" tabindex="6"><br>
</fieldset>
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Note Successfully Edited « Admin CP
@stop
@section('content')
<p>Successfully edited note with id: {{ $id }}.</p>
@stop

View file

@ -0,0 +1,18 @@
@extends('master')
@section('title')
Edit Place « Admin CP
@stop
@section('content')
<h1>Edit Place</h1>
<form action="/admin/places/edit/{{ $id }}" method="post" accept-charset="utf-8">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<input type="text" name="name" id="name" value="{{ $name }}"><br>
<input type="text" name="description" id="description" value="{{ $description }}"><br>
<input type="text" name="latitude" id="latitude" value="{{ $latitude }}"><br>
<input type="text" name="longitude" id="longitude" value="{{ $longitude }}"><br>
<input type="submit" name="edit" value="Edit"><br><br>
<input type="submit" name="delete" value="Delete">
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
Edit Place « Admin CP
@stop
@section('content')
<p>Successfully edited the place information.</p>
@stop

View file

@ -0,0 +1,10 @@
@extends('master')
@section('title')
New Contact Avatar « Admin CP
@stop
@section('content')
<p>Successfully saved the avatar contact</p>
<img src="/assets/profile-images/{{ $homepage }}/image">
@stop

View file

@ -0,0 +1,14 @@
@extends('master')
@section('title')
List Articles « Admin CP
@stop
@section('content')
<p>Select article to edit:</p>
<ol reversed>
@foreach($posts as $post)
<li><a href="/admin/blog/edit/{{ $post['id'] }}">{{ $post['title'] }}</a>@if($post['published'] == '0')<span class="notpublished">not published</span>@endif <a href="/admin/blog/delete/{{ $post['id'] }}">Delete?</a>
@endforeach
</ol>
@stop

View file

@ -0,0 +1,17 @@
@extends('master')
@section('title')
List Clients « Admin CP
@stop
@section('content')
<h1>Clients</h1>
<ul>
@foreach($clients as $client)
<li>{{ $client['client_url'] }} : {{ $client['client_name'] }}
<a href="/admin/clients/edit/{{ $client['id'] }}">edit?</a>
</li>
@endforeach
</ul>
<p>Createn a <a href="/admin/clients/new">new entry</a>?</p>
@stop

View file

@ -0,0 +1,27 @@
@extends('master')
@section('title')
List Contacts « Admin CP
@stop
@section('content')
<h1>Contacts</h1>
<table>
<tr>
<th>Real Name</th>
<th>Nick</th>
<th>Homepage</th>
<th>Twitter</th>
<th></th>
</tr>
@foreach($contacts as $contact)
<tr>
<td>{{ $contact->name }}</td>
<td>{{ $contact->nick }}</td>
<td>{{ $contact->homepage }}</td>
<td>{{ $contact->twitter }}</td>
<td><a href="/admin/contacts/edit/{{ $contact->id }}">edit</a></td>
</tr>
@endforeach
</table>
@stop

View file

@ -0,0 +1,14 @@
@extends('master')
@section('title')
List Notes « Admin CP
@stop
@section('content')
<p>Select note to edit:</p>
<ol reversed>
@foreach($notes as $note)
<li><a href="/admin/note/edit/{{ $note->id }}">{{ $note->originalNote }}</a></li>
@endforeach
</ol>
@stop

View file

@ -0,0 +1,15 @@
@extends('master')
@section('title')
List Places « Admin CP
@stop
@section('content')
<h1>Places</h1>
<ul>
@foreach($places as $place)
<li>{{ $place['name'] }} <a href="/admin/places/edit/{{ $place['id'] }}">edit?</a></li>
@endforeach
</ul>
<p>Createn a <a href="/admin/places/new">new entry</a>?</p>
@stop

View file

@ -0,0 +1,21 @@
@extends('master')
@section('title')
List Tokens « Admin CP
@stop
@section('content')
<h1>Tokens</h1>
<ul>
@foreach($tokens as $token => $data)
<li>{{ $token }}
<ul>
@foreach($data as $key => $value)
<li>{{ $key }}: <?php if(is_array($value)) { echo '<ul>'; foreach($value as $scope) { echo "<li>$scope</li>"; } echo '</ul>'; } else { echo $value; }; ?></li>
@endforeach
</ul>
<a href="/admin/tokens/delete/{{ $token }}">delete?</a>
</li>
@endforeach
</ul>
@stop

View file

@ -0,0 +1,49 @@
@extends('master')
@section('title')
New Article « Admin CP
@stop
@section('content')
@if(isset($message))<p class="error">{{ $message }}</p>@endif
<form action="/admin/blog/new" method="post" accept-charset="utf-8" enctype="multipart/form-data" id="newarticle">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<label for="title">Title (URL):</label>
<br>
<input type="text" name="title" id="title" value="{{ old('title') }}" placeholder="Title here">
<br>
<input type="text" name="url" id="url" value="{{ old('url') }}" placeholder="Article URL">
<br>
<label for="main">Main:</label>
<br>
<textarea name="main" id="main" placeholder="Article here">{{ old('main') }}</textarea>
<br>
<label for="published">Published:</label><input type="checkbox" name="published" id="published" value="1">
<br>
<p>Or you can upload an <code>.md</code> file:</p><input type="file" accept=".md" name="article">
<br>
<button type="submit" name="save">Save</button>
</form>
<h2>Preview</h2>
@stop
@section('scripts')
@parent
<script src="{{ elixir('assets/js/marked.min.js') }}"></script>
<script>
var preview = document.createElement('div');
preview.classList.add('preview');
var main = document.querySelector('main');
main.appendChild(preview);
var textarea = document.querySelector('textarea');
window.setInterval(function () {
var markdown = textarea.value;
preview.innerHTML = marked(markdown);
}, 5000);
</script>
<script src="{{ elixir('assets/js/store2.min.js') }}"></script>
<script src="{{ elixir('assets/js/alertify.js') }}"></script>
<script src="{{ elixir('assets/js/form-save.js') }}"></script>
<link rel="stylesheet" href="{{ elixir('assets/css/alertify.css') }}">
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
New Article Success « Admin CP
@stop
@section('content')
<p>Successfully created article with id: {{ $id }}, title: {{ $title }}</p>
@stop

View file

@ -0,0 +1,15 @@
@extends('master')
@section('title')
New Client « Admin CP
@stop
@section('content')
<h1>New Client</h1>
<form action="/admin/clients/new" method="post" accept-charset="utf-8">
<input type="hidden" name="_token" value="{{ csrftoken() }}">
<input type="text" name="client_url" id="client_url" placeholder="client_url"><br>
<input type="text" name="client_name" id="client_name" placeholder="client_name"><br>
<input type="submit" name="submit" value="Submit">
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
New Client « Admin CP
@stop
@section('content')
<p>Succesfully created new client info.</p>
@stop

View file

@ -0,0 +1,17 @@
@extends('master')
@section('title')
New Contact « Admin CP
@stop
@section('content')
<h1>New Contact</h1>
<form action="/admin/contacts/new" method="post" accept-charset="utf-8">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<label for="name">Real Name:</label> <input type="text" name="name" id="name" placeholder="Real Name"><br>
<label for="nick">Nick:</label> <input type="text" name="nick" id="nick" placeholder="local_nick"><br>
<label for="homepage">Homepage:</label> <input type="text" name="homepage" id="homepage" placeholder="https://homepage.com"><br>
<label for="twitter">Twitter Nick:</label> <input type="text" name="twitter" id="twitter" placeholder="Twitter handle"><br>
<input type="submit" name="submit" value="Submit">
</form>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
New Contact « Admin CP
@stop
@section('content')
<p>Succesfully created new contact entry.</p>
@stop

View file

@ -0,0 +1,34 @@
@extends('master')
@section('title')
New Note « Admin CP
@stop
@section('content')
@if (count($errors) > 0)
<div class="errors">
<ul>
@foreach ($errors->all() as $error)
<li>{{ $error }}</li>
@endforeach
</ul>
</div>
@endif
@include('templates.new-note-form', [
'micropub' => false,
'action' => '/admin/note/new',
'id' => 'newnote-admin'
])
@stop
@section('scripts')
<link rel="styelsheet" href="https://api.mapbox.com/mapbox.js/v2.2.3/mapbox.css">
<script src="https://api.mapbox.com/mapbox.js/v2.2.3/mapbox.js"></script>
<script src="{{ elixir('assets/js/newnote.js') }}"></script>
<script src="{{ elixir('assets/js/store2.min.js') }}"></script>
<script src="{{ elixir('assets/js/alertify.js') }}"></script>
<script src="{{ elixir('assets/js/form-save.js') }}"></script>
<link rel="stylesheet" href="{{ elixir('assets/css/alertify.css') }}">
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
New Note Success « Admin CP
@stop
@section('content')
<p>Successfully created note with id: {{ $id }}. {{ $shorturl }}</p>
@stop

View file

@ -0,0 +1,24 @@
@extends('master')
@section('title')
New Place « Admin CP
@stop
@section('content')
<h1>New Place</h1>
<form action="/admin/places/new" method="post" accept-charset="utf-8">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
<label for="name">Name:</label> <input type="text" name="name" id="name" placeholder="Place Name"><br>
<label for="description">Description:</label> <input type="text" name="description" id="description" placeholder="Description"><br>
<label for="latitude">Latitude:</label> <input type="text" name="latitude" id="latitude" placeholder="Latitude"><br>
<label for="longitude">Longitude:</label> <input type="text" name="longitude" id="longitude" placeholder="Longitude"><br>
<input type="submit" name="submit" value="Submit">
<h2>Location</h2>
<button type="button" name="locate" id="locate">Locate</button>
</form>
@stop
@section('scripts')
<script src="/assets/js/libs/mapbox.v2.2.1.js"></script>
<script src="{{ elixir('assets/js/newplace.js') }}"></script>
@stop

View file

@ -0,0 +1,9 @@
@extends('master')
@section('title')
New Place « Admin CP
@stop
@section('content')
<p>Succesfully created new place info.</p>
@stop

View file

@ -0,0 +1,24 @@
@extends('master')
@section('title')
Admin CP
@stop
@section('content')
<h1>Hello {{ $name }}!</h1>
<h2>Articles</h2>
<p>You can either <a href="/admin/blog/new">create</a> new blog posts, or <a href="/admin/blog/edit">edit</a> them.<p>
<h2>Notes</h2>
<p>You can either <a href="/admin/note/new">create</a> new notes, or <a href="/admin/note/edit">edit</a> them.<p>
<h2>Tokens</h2>
<p>See all <a href="/admin/tokens">issued tokens</a>.</p>
<h2>Contacts</h2>
<p>You can either <a href="/admin/contacts/new">create</a> new contacts, or <a href="/admin/contacts/edit">edit</a> them.</p>
<h2>Places</h2>
<p>You can either <a href="/admin/places/new">create</a> new places, or <a href="/admin/places/edit">edit</a> them.</p>
@stop