about, documentation template

master
km0 2 years ago
parent 5d79d8de1f
commit a08dbfd48f

@ -0,0 +1,29 @@
html, body{
font-size: 24px;
line-height: 1.4;
}
main {
margin-top: 16px;
display: grid;
grid-template-columns: 1fr 1fr 1fr;
gap: 16px;
margin: 16px 8px;
}
.about {
grid-column: 1 / span 2;
}
.colophon {
grid-column: 3 / span 1;
color: #aaa;
font-size: 16px;
}
.colophon h3 {
margin-top: 0;
}

@ -0,0 +1,42 @@
html,
body {
font-size: 24px;
line-height: 1.4;
}
main {
margin: 16px;
}
main > * {
max-width: 60ch;
}
.toc {
border: 1px solid black;
display: inline-block;
padding: 16px;
margin: 32px 0;
}
.toc a:hover{
text-decoration: underline;
}
.toc h3 {
margin-top: 8px;
margin-bottom: 16px;
}
.toc ol {
margin:0;
}
.section + .section {
margin-top: 64px;
}

@ -19,7 +19,7 @@ header a:hover {
header { header {
width: 100%; width: 100%;
display: flex; display: flex;
justify-content: space-between; justify-content: start;
padding: 8px; padding: 8px;
font-size: 32px; font-size: 32px;

@ -0,0 +1,43 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/global.css') }}" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/about.css') }}" />
<title>Document</title>
</head>
<body>
<header>
<a href="{{url_for('workbook')}}" class="parent">Workbook</a>
<span class="path-slash"> / </span>
<h2 class="title">About</h2>
</header>
<main>
<div class="about">
Sit elit exercitation sint duis. Proident adipisicing fugiat tempor aliquip Lorem
dolore. Officia qui enim ea tempor aliqua ut. Ex excepteur deserunt exercitation
adipisicing amet fugiat deserunt. In deserunt laboris elit nisi nulla duis eiusmod.
Ullamco duis officia sint eu adipisicing quis ex adipisicing fugiat excepteur nulla
sint voluptate. Proident reprehenderit adipisicing anim qui et nisi. Deserunt quis
elit esse voluptate excepteur irure Lorem et consequat aute. Lorem exercitation
Lorem Lorem id reprehenderit incididunt mollit dolore duis. Et culpa sint
reprehenderit sunt ullamco nostrud qui minim laborum non.
</div>
<div class="colophon">
<h3>Colophon</h3>
Cillum proident deserunt laborum anim culpa nisi et veniam ex laboris reprehenderit.
Eu nulla voluptate magna anim fugiat incididunt ullamco mollit mollit aliqua veniam
exercitation ut. Nulla aute aliquip Lorem laborum.
<br />
<br />
A project by Supi Kamo etc <br />
<a href="https://git.xpub.nl/supisara/workbook">git</a>, license
</div>
</main>
</body>
</html>

@ -0,0 +1,91 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/global.css') }}" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/documentation.css') }}" />
<title>Document</title>
</head>
<body>
<header>
<a href="{{url_for('workbook')}}" class="parent">Workbook</a>
<span class="path-slash"> / </span>
<h2 class="title">Documentation</h2>
</header>
<main>
<p>
Veniam esse adipisicing esse velit reprehenderit irure laboris. Dolore et do
cupidatat est officia voluptate ex sunt minim minim enim magna. Nostrud proident
aliqua adipisicing non voluptate id ea incididunt laborum laboris mollit qui
nostrud. Enim exercitation dolor nulla ea laboris proident adipisicing incididunt
nulla dolore cupidatat.
</p>
<div class="toc">
<h3>Table of contents</h3>
<ol>
<li><a href="#intro">Intro</a></li>
<li><a href="#quick">Quick Start</a></li>
<li><a href="#instrument">Add Instrument</a></li>
<li><a href="#patch">Add Patch</a></li>
<li><a href="#snippet">Add Snippet</a></li>
</ol>
</div>
<div class="section">
<h3 id="intro">Intro</h3>
<p>
Exercitation ex culpa officia qui sint id sit nostrud. Deserunt nulla sunt
ullamco est anim in amet. Nostrud officia adipisicing dolore elit anim sit.
Deserunt fugiat pariatur quis nulla magna officia amet consectetur. Tempor
deserunt cillum labore eu duis adipisicing aliqua ad. Eiusmod ea enim officia ut
ea.
</p>
</div>
<div class="section">
<h3 id="quick">Quick Start</h3>
<p>
Exercitation ex culpa officia qui sint id sit nostrud. Deserunt nulla sunt
ullamco est anim in amet. Nostrud officia adipisicing dolore elit anim sit.
Deserunt fugiat pariatur quis nulla magna officia amet consectetur. Tempor
deserunt cillum labore eu duis adipisicing aliqua ad. Eiusmod ea enim officia ut
ea.
</p>
</div>
<div class="section">
<h3 id="instrument">Add Instrument</h3>
<p>
Exercitation ex culpa officia qui sint id sit nostrud. Deserunt nulla sunt
ullamco est anim in amet. Nostrud officia adipisicing dolore elit anim sit.
Deserunt fugiat pariatur quis nulla magna officia amet consectetur. Tempor
deserunt cillum labore eu duis adipisicing aliqua ad. Eiusmod ea enim officia ut
ea.
</p>
</div>
<div class="section">
<h3 id="patch">Add Patch</h3>
<p>
Exercitation ex culpa officia qui sint id sit nostrud. Deserunt nulla sunt
ullamco est anim in amet. Nostrud officia adipisicing dolore elit anim sit.
Deserunt fugiat pariatur quis nulla magna officia amet consectetur. Tempor
deserunt cillum labore eu duis adipisicing aliqua ad. Eiusmod ea enim officia ut
ea.
</p>
</div>
<div class="section">
<h3 id="snippet">Add Snippet</h3>
<p>
Exercitation ex culpa officia qui sint id sit nostrud. Deserunt nulla sunt
ullamco est anim in amet. Nostrud officia adipisicing dolore elit anim sit.
Deserunt fugiat pariatur quis nulla magna officia amet consectetur. Tempor
deserunt cillum labore eu duis adipisicing aliqua ad. Eiusmod ea enim officia ut
ea.
</p>
</div>
</main>
</body>
</html>

@ -1,50 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='css/global.css') }}" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/home.css') }}" />
<script src="{{ url_for('static', filename='js/cables.js') }}" defer></script>
<title>modbook</title>
</head>
<body>
<main class="homepanel">
<!-- SVG CONTAINER FOR THE CABLES -->
<svg
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
version="1.1"
id="svgElement"
x="0px"
y="0px"
width="500px"
height="500px"
viewBox="0 0 500 500"
enable-background="new 0 0 500 500"
xml:space="preserve"
></svg>
<!-- OUT -->
<div class="socket" style="top: 10%; left: 10%">
<span class="plug out"></span>
<label>Workbook</label>
</div>
<div class="socket" style="top: 20%; left: 5%">
<span class="plug out"></span>
<label>About</label>
</div>
<div class="socket" style="top: 30%; left: 10%">
<span class="plug out"></span>
<label> Test</label>
</div>
<!-- IN -->
<div class="socket" style="bottom: 40%; right: 20%">
<span class="plug in" id="enter"></span>
<label>Enter</label>
</div>
</main>
</body>
</html>

@ -0,0 +1,79 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>Workbook - Instruments</title>
<link rel="stylesheet" href="{{ url_for('static', filename='css/global.css') }}" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/workbook.css') }}" />
</head>
<body>
<header>
<a href="{{url_for('workbook')}}" class="parent">Workbook</a>
<span class="path-slash"> / </span>
<h2 class="title">Instruments</h2>
<div class="search">
<svg
class="icon"
width="31"
height="33"
viewBox="0 0 31 33"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<line
x1="20.0607"
y1="22.9393"
x2="29.0607"
y2="31.9393"
stroke="currentColor"
stroke-width="3"
/>
<circle cx="13" cy="13" r="11.5" stroke="currentColor" stroke-width="3" />
</svg>
<input type="text" name="search" id="search" />
</div>
</header>
<main>
<ul class="instruments list">
<li class="card">
<a href="{{url_for('add_instrument')}}">
<svg
width="48"
height="48"
viewBox="0 0 48 48"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<line
x1="25"
y1="4.37114e-08"
x2="25"
y2="48"
stroke="currentColor"
stroke-width="3"
/>
<line
x1="48"
y1="25"
x2="-8.74228e-08"
y2="25"
stroke="currentColor"
stroke-width="3"
/>
</svg>
</a>
</li>
{% for instrument in instruments %}
<li class="card">
<a href="{{url_for('patches', instrument=instrument['slug'])}}"
>{{instrument['name']}}</a
>
</li>
{% endfor %}
</ul>
</main>
</body>
</html>

@ -12,9 +12,9 @@
</head> </head>
<body> <body>
<header> <header>
<a href="{{url_for('home')}}" class="parent">Home</a> <a href="{{url_for('workbook')}}" class="parent">Workbook</a>
<span class="path-slash"> / </span> <span class="path-slash"> / </span>
<a href="{{url_for('workbook')}}">Workbook</a> <a href="{{url_for('instruments')}}">Instruments</a>
<span class="path-slash"> / </span> <span class="path-slash"> / </span>
<a href="{{url_for('patches', instrument=instrument['slug'])}}" <a href="{{url_for('patches', instrument=instrument['slug'])}}"
>{{instrument['name']}}</a >{{instrument['name']}}</a

@ -12,9 +12,9 @@
</head> </head>
<body> <body>
<header> <header>
<a href="{{url_for('home')}}" class="parent">Home</a> <a href="{{url_for('workbook')}}" class="parent">Workbook</a>
<span class="path-slash"> / </span> <span class="path-slash"> / </span>
<a href="{{url_for('workbook')}}">Workbook</a> <a href="{{url_for('instruments')}}">Instruments</a>
<span class="path-slash"> / </span> <span class="path-slash"> / </span>
<h2 class="title">{{instrument}}</h2> <h2 class="title">{{instrument}}</h2>
<div class="search"> <div class="search">

@ -2,78 +2,53 @@
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<link
rel="stylesheet"
type="text/css"
href="{{ url_for('static', filename='css/global.css') }}"
/>
<link rel="stylesheet" href="{{ url_for('static', filename='css/home.css') }}" />
<script src="{{ url_for('static', filename='js/cables.js') }}" defer></script>
<title>Workbook</title> <title>Workbook</title>
<link rel="stylesheet" href="{{ url_for('static', filename='css/global.css') }}" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/workbook.css') }}" />
</head> </head>
<body> <body>
<header> <main class="homepanel">
<a href="{{url_for('home')}}" class="parent">Home</a> <!-- SVG CONTAINER FOR THE CABLES -->
<span class="path-slash"> / </span>
<h2 class="title">Workbook</h2>
<div class="search">
<svg <svg
class="icon"
width="31"
height="33"
viewBox="0 0 31 33"
fill="none"
xmlns="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg"
> xmlns:xlink="http://www.w3.org/1999/xlink"
<line version="1.1"
x1="20.0607" id="svgElement"
y1="22.9393" x="0px"
x2="29.0607" y="0px"
y2="31.9393" width="500px"
stroke="currentColor" height="500px"
stroke-width="3" viewBox="0 0 500 500"
/> enable-background="new 0 0 500 500"
<circle cx="13" cy="13" r="11.5" stroke="currentColor" stroke-width="3" /> xml:space="preserve"
</svg> ></svg>
<input type="text" name="search" id="search" />
<!-- OUT -->
<div class="socket" style="top: 10%; left: 10%">
<span class="plug out"></span>
<label>Instruments</label>
</div> </div>
</header>
<main> <div class="socket" style="top: 20%; left: 5%">
<ul class="instruments list"> <span class="plug out"></span>
<li class="card"> <label>About</label>
<a href="{{url_for('add_instrument')}}"> </div>
<svg
width="48"
height="48"
viewBox="0 0 48 48"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<line
x1="25"
y1="4.37114e-08"
x2="25"
y2="48"
stroke="currentColor"
stroke-width="3"
/>
<line
x1="48"
y1="25"
x2="-8.74228e-08"
y2="25"
stroke="currentColor"
stroke-width="3"
/>
</svg>
</a>
</li>
{% for instrument in instruments %} <div class="socket" style="top: 30%; left: 15%">
<li class="card"> <span class="plug out"></span>
<a href="{{url_for('patches', instrument=instrument['slug'])}}" <label>Documentation</label>
>{{instrument['name']}}</a </div>
>
</li> <!-- IN -->
{% endfor %} <div class="socket" style="bottom: 40%; right: 20%">
</ul> <span class="plug in" id="enter"></span>
<label>Enter</label>
</div>
</main> </main>
</body> </body>
</html> </html>

@ -53,11 +53,16 @@ def create_instrument(name, description, params, sockets, panel):
@app.route("/") @app.route("/")
def home():
return render_template('home.html')
@app.route("/workbook")
def workbook(): def workbook():
return render_template('workbook.html')
@app.route("/<slug>")
def page(slug):
return render_template(f'{slug}.html')
@app.route("/instruments")
def instruments():
instruments = [] instruments = []
@ -66,9 +71,9 @@ def workbook():
instrument = yaml.load(f, Loader=SafeLoader) instrument = yaml.load(f, Loader=SafeLoader)
instruments.append(instrument) instruments.append(instrument)
return render_template('workbook.html', instruments=instruments) return render_template('instruments.html', instruments=instruments)
@app.route("/workbook/<instrument>") @app.route("/instruments/<instrument>")
def patches(instrument): def patches(instrument):
@ -85,7 +90,7 @@ def patches(instrument):
return render_template('patches.html', instrument=instrument, patches=patches, panel=panel) return render_template('patches.html', instrument=instrument, patches=patches, panel=panel)
@app.route("/workbook/add", methods=['GET', 'POST']) @app.route("/instruments/add", methods=['GET', 'POST'])
def add_instrument(): def add_instrument():
if request.method == 'POST': if request.method == 'POST':
@ -98,11 +103,11 @@ def add_instrument():
panel = request.files['panel'] panel = request.files['panel']
create_instrument(name, description, params, sockets, panel) create_instrument(name, description, params, sockets, panel)
return redirect(url_for('workbook')) return redirect(url_for('instruments'))
return render_template('add_instrument.html') return render_template('add_instrument.html')
@app.route("/workbook/<instrument>/add", methods=['GET', 'POST']) @app.route("/instruments/<instrument>/add", methods=['GET', 'POST'])
def add_patch(instrument): def add_patch(instrument):
if request.method == 'POST': if request.method == 'POST':
@ -127,7 +132,7 @@ def add_patch(instrument):
return render_template('add_patch.html', instrument=instrument, panel=panel) return render_template('add_patch.html', instrument=instrument, panel=panel)
@app.route("/workbook/<instrument>/<name>") @app.route("/instruments/<instrument>/<name>")
def patch(instrument, name): def patch(instrument, name):

Loading…
Cancel
Save