Skip to content

Commit

Permalink
Get different subpages working
Browse files Browse the repository at this point in the history
  • Loading branch information
jank324 committed Aug 20, 2024
1 parent 0edf75b commit 85b66d9
Show file tree
Hide file tree
Showing 19 changed files with 204 additions and 62 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
public
.hugo_build.lock
.hugo_build.lock
node_modules
15 changes: 15 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"plugins": [
"prettier-plugin-go-template"
],
"overrides": [
{
"files": [
"*.html"
],
"options": {
"parser": "go-template"
}
}
]
}
File renamed without changes
File renamed without changes.
2 changes: 2 additions & 0 deletions content/_index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
## What is this website?

Alfa Romeo 1300 GT Junior

This website is a template that you could use for a (small) academic conference. It’s got a page for registration, where you can embed a Google Form or some other way for participants to register. It’s got a program page to list the schedule for the conference. It’s got a directions page to add a bunch of instructions how to get to the conference. It’s got a page to put up the flyers and other promotional materials for folks to download.

You can use this template by cloning all the files from this GitHub repo here. This template was created from a website I made for MathConnections 2019, in case you want to see an example of this template being used in the wild. [Here’s the link to that website](https://www.desy.de/).
Expand Down
5 changes: 5 additions & 0 deletions content/directions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
+++
title = 'Directions'
+++

Put a map here and stuff.
5 changes: 5 additions & 0 deletions content/flyer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
+++
title = 'Flyer'
+++

Paste the flyer here.
7 changes: 7 additions & 0 deletions content/program.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
+++
title = 'Program'
+++

## Conference Program

TBA
7 changes: 7 additions & 0 deletions content/registration.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
+++
title = 'Registration'
+++

Here’s where you provide instructions how to register for your conference. We used a Google Form and embedded it into an iframe (it’s commented out in the html here).

Here’s another paragraph of filler text: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum dignissim et est et euismod. Fusce et metus tempus, pellentesque ex at, convallis nulla. Ut fringilla commodo tincidunt. Fusce sed est eu massa placerat iaculis eu at mauris. Nullam ut mollis nisi, quis malesuada risus. Interdum et malesuada fames ac ante ipsum primis in faucibus. Nam ipsum tortor, suscipit non tincidunt vel, bibendum in libero. Nulla facilisi. Pellentesque vitae neque metus. Cras quis est pharetra, vestibulum nisl et, viverra ipsum. Etiam porta dignissim purus, quis tempor metus volutpat eu. Praesent pulvinar libero eget purus tincidunt finibus.
3 changes: 0 additions & 3 deletions hugo.toml

This file was deleted.

21 changes: 21 additions & 0 deletions hugo.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
baseURL: https://rl4aa.github.io/RL4AA25/
languageCode: en-uk
title: RL4AA'25

menus:
main:
- name: Home
pageRef: /
weight: 10
- name: Registration
pageRef: /registration/
weight: 20
- name: Program
pageRef: /program/
weight: 30
- name: Directions
pageRef: /directions/
weight: 40
- name: Flyer
pageRef: /flyer/
weight: 50
26 changes: 26 additions & 0 deletions layouts/_default/baseof.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<!DOCTYPE html>
<html lang="en">
<head>
<base href="." />
<link rel="shortcut icon" type="image/png" href="favicon.png" />
{{ with resources.Get "styles.css" }}
<link rel="stylesheet" type="text/css" media="all" href="{{ .RelPermalink }}" />
{{ end }}
<meta name="description" content="Conference Template" />
<meta name="resource-type" content="document" />
<meta name="distribution" content="global" />
<meta name="KeyWords" content="Conference" />
<title>{{ .Site.Title }}</title>
</head>

<body>
{{ partial "banner.html" . }}
{{ partial "navigation.html" . }}

{{ block "main" . }}
<!-- The part of the page that begins to differ between templates -->
{{ end }}

{{ partial "footer.html" . }}
</body>
</html>
1 change: 1 addition & 0 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{{ define "main" }} {{ .Content }} {{ end }}
59 changes: 1 addition & 58 deletions layouts/index.html
Original file line number Diff line number Diff line change
@@ -1,58 +1 @@
<!DOCTYPE html>
<html lang="en">
<head>
<base href="." />
<link rel="shortcut icon" type="image/png" href="favicon.png" />
<link rel="stylesheet" type="text/css" media="all" href="main.css" />
<meta name="description" content="Conference Template" />
<meta name="resource-type" content="document" />
<meta name="distribution" content="global" />
<meta name="KeyWords" content="Conference" />
<title>Conference Template</title>
</head>

<body>
<div class="banner">
<img src="banner.jpg" alt="Conference Template Banner" />
<div class="top-left">
<span class="title1">Conference</span
><span class="title2">Template</span> <span class="year">2525</span>
</div>
<div class="bottom-right">
June 31, 2525 <br />
University Name, and City Maybe
</div>
</div>

<table class="navigation">
<tr>
<td class="navigation">
<a class="current" title="Conference Home Page" href=".">Home</a>
</td>
<td class="navigation">
<a title="Register for the Conference" href="registration"
>Registration</a
>
</td>
<td class="navigation">
<a title="Conference Program" href="program">Program</a>
</td>
<td class="navigation">
<a title="Directions to the Conference" href="directions"
>Directions</a
>
</td>
<td class="navigation">
<a title="Conference Flyer" href="flyer">Flyer</a>
</td>
</tr>
</table>

{{.Content}}

<footer>
&copy; Conference Organizers &nbsp;|&nbsp; Design by
<a href="https://github.com/mikepierce">Mike Pierce</a>
</footer>
</body>
</html>
{{ define "main" }} {{ .Content }} {{ end }}
13 changes: 13 additions & 0 deletions layouts/partials/banner.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<div class="banner">
{{ with resources.Get "banner.jpg" }}
<img src="{{ .RelPermalink }}" alt="Conference Template Banner" />
{{ end }}
<div class="top-left">
<span class="title1">Conference</span><span class="title2">Template</span>
<span class="year">2525</span>
</div>
<div class="bottom-right">
June 31, 2525 <br />
University Name, and City Maybe
</div>
</div>
4 changes: 4 additions & 0 deletions layouts/partials/footer.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<footer>
&copy; Conference Organizers &nbsp;|&nbsp; Design by
<a href="https://github.com/mikepierce">Mike Pierce</a>
</footer>
22 changes: 22 additions & 0 deletions layouts/partials/navigation.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{{ $page := . }}


<table class="navigation">
<tr>
{{ with index .Site.Menus "main" }}
{{ range . }}
{{ $isCurrent := $page.IsMenuCurrent "main" . }}
<td class="navigation">
<a
{{ if $isCurrent }}
class="current"
{{ end }}
title="{{ .Name }}"
href="{{ .URL }}"
>{{ .Name }}</a
>
</td>
{{ end }}
{{ end }}
</tr>
</table>
59 changes: 59 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"name": "rl4aa25",
"version": "1.0.0",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"description": "",
"devDependencies": {
"prettier-plugin-go-template": "^0.0.15"
}
}

0 comments on commit 85b66d9

Please sign in to comment.