File tree 4 files changed +16
-12
lines changed
4 files changed +16
-12
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ write_timeout="3s"
4
4
dbfile =" app.db"
5
5
6
6
page_logo_url =" /static/icon.png"
7
+ page_favicon_url =" /static/favicon.ico"
7
8
page_title =" LinkPage"
8
9
page_intro =" Your friendly neighbourhood self-hostable FOSS link page."
9
10
Original file line number Diff line number Diff line change 10
10
< link rel ="stylesheet " href ="/static/app/css/skeleton.css ">
11
11
< link rel ="stylesheet " href ="/static/app/css/app.css ">
12
12
< link rel ="stylesheet " href ="/static/custom/custom.css ">
13
- < link rel ="icon " href ="/static/custom/favicon.ico " type ="image/x-icon " />
13
+ < link rel ="icon " href ="{{.FaviconURL}} " type ="image/x-icon " />
14
14
15
15
< link rel ="preconnect " href ="https://fonts.gstatic.com ">
16
16
< link href ="https://fonts.googleapis.com/css2?family=Inter&display=swap " rel ="stylesheet ">
Original file line number Diff line number Diff line change @@ -42,9 +42,10 @@ type Config struct {
42
42
WriteTimeout time.Duration `koanf:"write_timeout"`
43
43
DBFile string `koanf:"dbfile"`
44
44
45
- PageLogoURL string `koanf:"page_logo_url"`
46
- PageTitle string `koanf:"page_title"`
47
- PageIntro string `koanf:"page_intro"`
45
+ PageLogoURL string `koanf:"page_logo_url"`
46
+ PageFaviconURL string `koanf:"page_favicon_url"`
47
+ PageTitle string `koanf:"page_title"`
48
+ PageIntro string `koanf:"page_intro"`
48
49
49
50
StaticFileDir string `koanf:"static_files"`
50
51
@@ -90,10 +91,11 @@ type Link struct {
90
91
}
91
92
92
93
type Page struct {
93
- LogoURL string
94
- Title string
95
- Intro string
96
- Links []Link
94
+ LogoURL string
95
+ FaviconURL string
96
+ Title string
97
+ Intro string
98
+ Links []Link
97
99
98
100
Error string
99
101
Success string
@@ -293,10 +295,11 @@ func runApp(configFilePath string) {
293
295
294
296
app := & App {
295
297
Data : Page {
296
- LogoURL : cfg .PageLogoURL ,
297
- Title : cfg .PageTitle ,
298
- Intro : cfg .PageIntro ,
299
- Social : cfg .Social ,
298
+ LogoURL : cfg .PageLogoURL ,
299
+ FaviconURL : cfg .PageFaviconURL ,
300
+ Title : cfg .PageTitle ,
301
+ Intro : cfg .PageIntro ,
302
+ Social : cfg .Social ,
300
303
},
301
304
DB : & LinkDB {db },
302
305
Templates : Templates {
You can’t perform that action at this time.
0 commit comments