aboutsummaryrefslogtreecommitdiffhomepage
path: root/public
diff options
context:
space:
mode:
authorBastien Wirtz <bastien.wirtz@gmail.com>2021-03-06 22:50:58 -0800
committerBastien Wirtz <bastien.wirtz@gmail.com>2021-03-06 22:50:58 -0800
commitba07da6b1011e77c9ed42e8643e62b903c6c6d7b (patch)
tree6311707cb628e64a2787b680a9a4d517505faa51 /public
parent00b46a6ddebcbbe581f201bd4089c38f6d666fb9 (diff)
downloadhomer-ba07da6b1011e77c9ed42e8643e62b903c6c6d7b.tar.gz
homer-ba07da6b1011e77c9ed42e8643e62b903c6c6d7b.tar.zst
homer-ba07da6b1011e77c9ed42e8643e62b903c6c6d7b.zip
Avoid full reload when swithcing page.
Diffstat (limited to 'public')
-rw-r--r--public/assets/additionnal-page.yml.dist (renamed from public/assets/page2.yml)21
-rw-r--r--public/assets/config.yml.dist5
2 files changed, 16 insertions, 10 deletions
diff --git a/public/assets/page2.yml b/public/assets/additionnal-page.yml.dist
index 00001e9..f918dc1 100644
--- a/public/assets/page2.yml
+++ b/public/assets/additionnal-page.yml.dist
@@ -1,18 +1,20 @@
1# this config is used by a page linked in the navbar 1---
2# this pages will use the same configuration from config.yml, but will overwrite fields present here 2# Additionnal page configuration
3 3
4# this overwrites title and subtitle: 4# Additionnal configurations are loaded using its file name, minus the extension, as an anchor (https://<mydashboad>#<config>).
5title: "Page2" 5# `config.yml` is still used as a base configuration, and all values here will overwrite it, so you don't have to re-defined everything
6subtitle: "this is the second page"
7 6
8# this overwrites message config. Setting it to empty to remove message from this page and keep it only in the main one: 7
9message: 8subtitle: "this is another dashboard page"
9
10# This overwrites message config. Setting it to empty to remove message from this page and keep it only in the main one:
11message: ~
10 12
11# as we want to include a differente link here (so we can get back to home page), we need to replicate all links or they will be revome when overwriting the links field: 13# as we want to include a differente link here (so we can get back to home page), we need to replicate all links or they will be revome when overwriting the links field:
12links: 14links:
13 - name: "Home" 15 - name: "Home"
14 icon: "fas fa-home" 16 icon: "fas fa-home"
15 url: "/" 17 url: "#"
16 - name: "Contribute" 18 - name: "Contribute"
17 icon: "fab fa-github" 19 icon: "fab fa-github"
18 url: "https://github.com/bastienwirtz/homer" 20 url: "https://github.com/bastienwirtz/homer"
@@ -21,9 +23,8 @@ links:
21 icon: "fas fa-book" 23 icon: "fas fa-book"
22 url: "https://www.wikipedia.org/" 24 url: "https://www.wikipedia.org/"
23 25
24# we keep the first group from the main page, but remove the second group. We need to replicate that first group or it will be removed:
25services: 26services:
26 - name: "NEW" 27 - name: "More applications on another page!"
27 icon: "fas fa-cloud" 28 icon: "fas fa-cloud"
28 items: 29 items:
29 - name: "Awesome app on a second page!" 30 - name: "Awesome app on a second page!"
diff --git a/public/assets/config.yml.dist b/public/assets/config.yml.dist
index 85478ec..65c5098 100644
--- a/public/assets/config.yml.dist
+++ b/public/assets/config.yml.dist
@@ -56,6 +56,11 @@ links:
56 - name: "Wiki" 56 - name: "Wiki"
57 icon: "fas fa-book" 57 icon: "fas fa-book"
58 url: "https://www.wikipedia.org/" 58 url: "https://www.wikipedia.org/"
59 # this will link to a second homer page that will load config from additionnal-page.yml and keep default config values as in config.yml file
60 # see url field and assets/additionnal-page.yml.dist used in this example:
61 - name: "another page!"
62 icon: "fas fa-file-alt"
63 url: "#additionnal-page"
59 64
60# Services 65# Services
61# First level array represent a group. 66# First level array represent a group.