Added extension navigation

This commit is contained in:
Eduard Urbach 2017-12-03 19:34:09 +01:00
parent 45ace1ec60
commit f02db2b9b8
6 changed files with 25 additions and 2 deletions

View File

@ -16,7 +16,8 @@
},
"search.exclude": {
"components/": true,
"**/*.svg": true
"**/*.svg": true,
"**/*.html": true
},
"[jade]": {
"files.trimTrailingWhitespace": false

View File

@ -41,6 +41,7 @@ component Layout(app *aero.Application, ctx *aero.Context, user *arn.User, openG
Content(content)
LoadingAnimation
StatusMessage
ExtensionNavigation
if user != nil
#user(data-id=user.ID, data-theme=user.Settings().Theme)
script(src="/scripts")

View File

@ -7,6 +7,7 @@ sidebar-spacing-y = 0.7rem
top 0
z-index 10
width 70vw
max-width 300px
height 100%
background sidebar-opaque-background
transform translateX(-100%)

View File

@ -31,5 +31,5 @@ func Get(ctx *aero.Context) string {
watchingList := animeList.Watching()
watchingList.Sort()
return utils.AllowEmbed(ctx, ctx.HTML(components.AnimeList(watchingList, animeList.User(), user)))
return utils.AllowEmbed(ctx, ctx.HTML(components.BrowserExtension(watchingList, animeList.User(), user)))
}

7
pages/embed/embed.pixy Normal file
View File

@ -0,0 +1,7 @@
component BrowserExtension(watchingList *arn.AnimeList, viewUser *arn.User, user *arn.User)
AnimeList(watchingList, viewUser, user)
component ExtensionNavigation
nav.extension-navigation
button.action(data-trigger="click", data-action="toggleSidebar")
RawIcon("bars")

13
pages/embed/embed.scarlet Normal file
View File

@ -0,0 +1,13 @@
.extension-navigation
display none
> 780px
.extension-navigation
display block
position fixed
bottom 1rem
left 1rem
> 790px
.extension-navigation
display none