Compare commits
10 commits
9cab7a69f7
...
41c985fcab
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
41c985fcab | ||
|
|
5e99686b5c | ||
|
|
1b9cfe6587 | ||
|
|
3273959fdd | ||
|
|
27972a47ba | ||
|
|
85c517dcd6 | ||
|
|
9b60dba3c7 | ||
|
|
03e43580c1 | ||
|
|
5b6cb3b1e1 | ||
|
|
dbda07f8e5 |
17 changed files with 84 additions and 737 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import './styles/brain.css';
|
||||
//import './stimulus_bootstrap.js';
|
||||
import './stimulus_bootstrap.js';
|
||||
|
||||
const init = () => {
|
||||
menu();
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
.page{max-width:800px;width:100%;margin:0 auto}.page h2{margin:0}.page .row{display:block;padding:1rem 0}.page .row label{display:block}.page .row input{height:30px;width:300px}.page .row #post_published{width:30px;height:30px}.page .row #post_save{width:100px;height:30px;background-color:green;border:none;color:#fff}#brain-wrapper header .level-1{display:flex;justify-content:center;align-items:flex-start;position:relative;list-style-type:none}#brain-wrapper header .level-1--item{padding:1rem 2rem}#brain-wrapper header .level-1 .level-2{display:none;margin:0;padding:0}#brain-wrapper header .level-1 .level-2.open{display:block;position:absolute}#brain-wrapper header .level-1 .level-2--item{padding:1rem 0}body{background-color:#d3d3d3}
|
||||
.actions{padding-bottom:1rem}.actions .list{display:flex;gap:2rem;list-style:none;margin:0;padding:0}.page{max-width:800px;width:100%;margin:0 auto}.page h2{margin:0}.page .row{display:block;padding:1rem 0}.page .row label{display:block}.page .row input{height:30px;width:300px}.page .row #post_published{width:30px;height:30px}.page .row #post_save{width:100px;height:30px;background-color:green;border:none;color:#fff}#brain-wrapper header .level-1{display:flex;justify-content:center;align-items:flex-start;position:relative;list-style-type:none}#brain-wrapper header .level-1--item{padding:1rem 2rem}#brain-wrapper header .level-1 .level-2{display:none;margin:0;padding:0}#brain-wrapper header .level-1 .level-2.open{display:block;position:absolute}#brain-wrapper header .level-1 .level-2--item{padding:1rem 0}#brain-wrapper a{color:#171a21}body{background-color:#d3d3d3}
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -1,3 +1,4 @@
|
|||
@use './brain/actions';
|
||||
@use './brain/form';
|
||||
@use './brain/layout';
|
||||
|
||||
|
|
|
|||
11
assets/styles/scss/brain/_actions.scss
Normal file
11
assets/styles/scss/brain/_actions.scss
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
.actions {
|
||||
padding-bottom: 1rem;
|
||||
|
||||
.list {
|
||||
display: flex;
|
||||
gap: 2rem;
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,3 +1,5 @@
|
|||
@use '../shared/colors' as colors;
|
||||
|
||||
#brain-wrapper {
|
||||
header {
|
||||
.level-1 {
|
||||
|
|
@ -30,4 +32,8 @@
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
a {
|
||||
color: colors.$inkBlack;
|
||||
}
|
||||
}
|
||||
11
assets/styles/scss/front/_pages.scss
Normal file
11
assets/styles/scss/front/_pages.scss
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
@use '../shared/colors' as colors;
|
||||
|
||||
.page {
|
||||
.text {
|
||||
ul, ol {
|
||||
li {
|
||||
color: colors.$primaryWhite;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -133,7 +133,7 @@
|
|||
|
||||
#open-image {
|
||||
display: none;
|
||||
position: absolute;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 999;
|
||||
|
|
@ -145,8 +145,15 @@
|
|||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 75%;
|
||||
width: 100%;
|
||||
max-width: 700px;
|
||||
height: 75%;
|
||||
max-height: 100vh;
|
||||
|
||||
/* @media (min-width: 600px) {
|
||||
top: 2rem;
|
||||
transform: translate(-50%, 0);
|
||||
} */
|
||||
|
||||
.close {
|
||||
cursor: pointer;
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@
|
|||
margin-top: 5rem;
|
||||
|
||||
@media (min-width: 600px) {
|
||||
margin-top: -2rem;
|
||||
margin-top: -6rem;
|
||||
}
|
||||
|
||||
.heading {
|
||||
|
|
@ -328,7 +328,7 @@
|
|||
.highlight {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
align-self: stretch;
|
||||
padding: 1rem 1rem;
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
@use './front/layout';
|
||||
@use './front/menu';
|
||||
@use './front/lists';
|
||||
@use './front/pages';
|
||||
@use './front/photos';
|
||||
@use './front/posts';
|
||||
@use './front/taxonomy';
|
||||
|
|
@ -51,7 +51,7 @@ final class BrainPageController extends AbstractController
|
|||
|
||||
$entityManager->flush();
|
||||
|
||||
return $this->redirectToRoute('brain_page_list');
|
||||
return $this->redirectToRoute('front_end_page', ['url' => $data->getUrl()]);
|
||||
}
|
||||
|
||||
return $this->render('brain/page/create.html.twig', [
|
||||
|
|
@ -86,7 +86,7 @@ final class BrainPageController extends AbstractController
|
|||
|
||||
$entityManager->flush();
|
||||
|
||||
return $this->redirectToRoute('brain_page_list');
|
||||
return $this->redirectToRoute('front_end_page', ['url' => $data->getUrl()]);
|
||||
}
|
||||
|
||||
return $this->render('brain/page/create.html.twig', [
|
||||
|
|
|
|||
|
|
@ -83,7 +83,7 @@ final class BrainPhotosController extends AbstractController
|
|||
|
||||
$entityManager->flush();
|
||||
|
||||
return $this->redirectToRoute('brain_photos_list');
|
||||
return $this->redirectToRoute('front_end_photos_detail', ['url' => $data->getUrl()]);
|
||||
}
|
||||
|
||||
return $this->render('brain/photos/create.html.twig', [
|
||||
|
|
@ -128,7 +128,7 @@ final class BrainPhotosController extends AbstractController
|
|||
|
||||
$entityManager->flush();
|
||||
|
||||
return $this->redirectToRoute('brain_photos_list');
|
||||
return $this->redirectToRoute('front_end_photos_detail', ['url' => $data->getUrl()]);
|
||||
}
|
||||
|
||||
return $this->render('brain/photos/create.html.twig', [
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ final class BrainPostController extends AbstractController
|
|||
|
||||
$entityManager->flush();
|
||||
|
||||
return $this->redirectToRoute('brain_post_list');
|
||||
return $this->redirectToRoute('front_end_post_detail', ['url' => $data->getUrl()]);
|
||||
}
|
||||
|
||||
return $this->render('brain/post/create.html.twig', [
|
||||
|
|
@ -134,7 +134,7 @@ final class BrainPostController extends AbstractController
|
|||
|
||||
$entityManager->flush();
|
||||
|
||||
return $this->redirectToRoute('brain_post_list');
|
||||
return $this->redirectToRoute('front_end_post_detail', ['url' => $data->getUrl()]);
|
||||
}
|
||||
return $this->render('brain/post/create.html.twig', [
|
||||
'action' => 'edit',
|
||||
|
|
|
|||
|
|
@ -7,9 +7,32 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block actions %}
|
||||
this will be some global admin actions
|
||||
<div class="actions">
|
||||
<ul class="list">
|
||||
<li><a href="/brain/post/new">Add New Post</a></li>
|
||||
<li><a href="/brain/photos/new">Add New Photo Album</a></li>
|
||||
<li><a href="/brain/page/new">Add New Page</a></li>
|
||||
<li><a href="/brain/category/new">Add New Category</a></li>
|
||||
<li><a href="/brain/tag/new">Add New Tag</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block admin %}
|
||||
<p>This will be a dashboard of sorts</p>
|
||||
<div class="dashboard">
|
||||
<h2>Dashboard</h2>
|
||||
<p>To Do</p>
|
||||
<ul>
|
||||
<li>Add file upload functionality for non photo albums</li>
|
||||
<li>Fix tall photo layouts</li>
|
||||
<li>Make this dashboard useful</li>
|
||||
<li>Project content type</li>
|
||||
<li>Make landing page exist in the db</li>
|
||||
<ul>
|
||||
<li>Render it as a static file instead of relying on db queries</li>
|
||||
</ul>
|
||||
<li>Self-host git and create a list page</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@
|
|||
<div class="highlights">
|
||||
<div class="highlight left">
|
||||
<i class="icon icon-paperclip"></i>
|
||||
<h3>Item 1</h3>
|
||||
<h3>Photos</h3>
|
||||
<img src="/files/uploads/photos/road_trip_(oregon_/_washington_/_montana)/thumbnail.png">
|
||||
<p>I embarked on a cross country road trip and back. See some photos!</p>
|
||||
<a href="/photos/road-trip-or-wa-mt">Check It Out</a>
|
||||
|
|
@ -69,10 +69,10 @@
|
|||
</div>
|
||||
<div class="highlight right">
|
||||
<i class="icon icon-paperclip"></i>
|
||||
<h3>Item 3</h3>
|
||||
<img src="https://placehold.co/600x600/png">
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
|
||||
<a href="#">Check It Out</a>
|
||||
<h3>Site Tech</h3>
|
||||
<img src="/files/uploads/photos/landing/item-3.jpg">
|
||||
<p>Site framework, libraries, and tools used to make this site</p>
|
||||
<a href="/site-info">Check It Out</a>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
|
|
|||
|
|
@ -18,6 +18,9 @@
|
|||
<p class="intro">A truly random smattering of thoughts and feelings. Things may not always be relevant, but they will always be irreverant.</p>
|
||||
<div class="list">
|
||||
<h3>Recent</h3>
|
||||
{% if app.user %}
|
||||
<br><a href="/brain/post/new">Add New Post</a>
|
||||
{% endif %}
|
||||
<ul>
|
||||
{% for post in posts %}
|
||||
<li>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue