mirror of
https://github.com/glanceapp/glance.git
synced 2025-06-21 18:31:24 +02:00
feat: added auto expand mobile page navigation
This commit is contained in:
parent
d60457afaf
commit
33dede8abc
@ -46,7 +46,7 @@
|
|||||||
{{ range $i, $column := .Page.Columns }}
|
{{ range $i, $column := .Page.Columns }}
|
||||||
<label class="mobile-navigation-label"><input type="radio" class="mobile-navigation-input" name="column" value="{{ $i }}" autocomplete="off"{{ if eq "full" $column.Size }} checked{{ end }}><div class="mobile-navigation-pill"></div></label>
|
<label class="mobile-navigation-label"><input type="radio" class="mobile-navigation-input" name="column" value="{{ $i }}" autocomplete="off"{{ if eq "full" $column.Size }} checked{{ end }}><div class="mobile-navigation-pill"></div></label>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
<label class="mobile-navigation-label"><input type="checkbox" class="mobile-navigation-page-links-input" autocomplete="on"><div class="hamburger-icon"></div></label>
|
<label class="mobile-navigation-label"><input type="checkbox" class="mobile-navigation-page-links-input" autocomplete="on"{{ if .Page.ExpandMobilePageNavigation }} checked{{ end }}><div class="hamburger-icon"></div></label>
|
||||||
</div>
|
</div>
|
||||||
<div class="mobile-navigation-page-links">
|
<div class="mobile-navigation-page-links">
|
||||||
{{ template "navigation-links" . }}
|
{{ template "navigation-links" . }}
|
||||||
|
@ -68,14 +68,15 @@ type templateData struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Page struct {
|
type Page struct {
|
||||||
Title string `yaml:"name"`
|
Title string `yaml:"name"`
|
||||||
Slug string `yaml:"slug"`
|
Slug string `yaml:"slug"`
|
||||||
Width string `yaml:"width"`
|
Width string `yaml:"width"`
|
||||||
ShowMobileHeader bool `yaml:"show-mobile-header"`
|
ShowMobileHeader bool `yaml:"show-mobile-header"`
|
||||||
HideDesktopNavigation bool `yaml:"hide-desktop-navigation"`
|
ExpandMobilePageNavigation bool `yaml:"expand-mobile-page-navigation"`
|
||||||
CenterVertically bool `yaml:"center-vertically"`
|
HideDesktopNavigation bool `yaml:"hide-desktop-navigation"`
|
||||||
Columns []Column `yaml:"columns"`
|
CenterVertically bool `yaml:"center-vertically"`
|
||||||
mu sync.Mutex
|
Columns []Column `yaml:"columns"`
|
||||||
|
mu sync.Mutex
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *Page) UpdateOutdatedWidgets() {
|
func (p *Page) UpdateOutdatedWidgets() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user