97 lines
4.8 KiB
Plaintext
Raw Normal View History

2018-03-23 00:43:45 +00:00
component Editor(url string, score int, scoreTitle string, scoreTypes map[string]int, user *arn.User)
2018-04-07 14:32:37 +00:00
h1.mountable What would you like to edit?
2018-03-19 21:55:55 +00:00
2018-04-07 13:39:55 +00:00
.feature-cards
2018-04-07 14:32:37 +00:00
a.feature-card.mountable(href="/editor/anime/all" + user.Settings().Editor.Filter.Suffix())
.feature-card-icon.feature-card-color-anime
2018-04-07 13:39:55 +00:00
RawIcon("tv")
2018-04-07 14:32:37 +00:00
.feature-card-text
p Anime
p.editor-score= stringutils.Plural(scoreTypes["Anime"], "contribution")
2018-04-23 10:18:53 +00:00
a.feature-card.mountable(href="/characters")
.feature-card-icon.feature-card-color-character
RawIcon("child")
.feature-card-text
p Characters
p.editor-score= stringutils.Plural(scoreTypes["Character"], "contribution")
2018-04-07 13:48:43 +00:00
2018-04-07 14:32:37 +00:00
a.feature-card.mountable(href="/editor/soundtracks/links")
.feature-card-icon.feature-card-color-soundtrack
2018-04-07 13:48:43 +00:00
RawIcon("music")
2018-04-07 14:32:37 +00:00
.feature-card-text
p SoundTracks
p.editor-score= stringutils.Plural(scoreTypes["SoundTrack"], "contribution")
2018-04-07 13:48:43 +00:00
2018-04-07 14:32:37 +00:00
a.feature-card.mountable(href="/editor/companies/description")
.feature-card-icon.feature-card-color-company
2018-04-07 13:48:43 +00:00
RawIcon("building-o")
2018-04-07 14:32:37 +00:00
.feature-card-text
p Companies
p.editor-score= stringutils.Plural(scoreTypes["Company"], "contribution")
2018-04-07 13:39:55 +00:00
2018-04-07 14:32:37 +00:00
.footer.mountable
a.footer-element(href="/editor/mal/diff/anime" + user.Settings().Editor.Filter.Suffix()) MALdiff
a.footer-element(href="/editor/kitsu/new/anime") Kitsu
2017-10-06 20:07:12 +00:00
2018-04-16 13:17:23 +00:00
if user.Role == "admin"
a.footer-element(href="/admin") Admin
2018-03-23 00:43:45 +00:00
component EditorTabs(url string, user *arn.User)
2018-04-07 14:32:37 +00:00
.corner-buttons-left
a.button(href="/editor")
RawIcon("arrow-left")
2018-03-23 00:43:45 +00:00
2018-03-22 21:26:52 +00:00
if strings.Contains(url, "/editor/anime/")
2018-03-09 11:38:46 +00:00
.tabs
2018-04-07 14:32:37 +00:00
Tab("All", "list", "/editor/anime/all" + user.Settings().Editor.Filter.Suffix())
2018-03-23 00:43:45 +00:00
Tab("Mappings", "arrows-h", "/editor/anime/mapping/mal" + user.Settings().Editor.Filter.Suffix())
Tab("Images", "image", "/editor/anime/image/lowres" + user.Settings().Editor.Filter.Suffix())
2018-03-26 17:44:35 +00:00
Tab("Companies", "building", "/editor/anime/companies/studios" + user.Settings().Editor.Filter.Suffix())
2018-04-08 08:55:17 +00:00
Tab("Connections", "exchange", "/editor/anime/connections/relations" + user.Settings().Editor.Filter.Suffix())
2018-03-26 17:44:35 +00:00
Tab("Details", "search-plus", "/editor/anime/details/genres" + user.Settings().Editor.Filter.Suffix())
2018-03-22 21:26:52 +00:00
2018-04-08 08:55:17 +00:00
if strings.Contains(url, "/editor/anime/connections")
.tabs
Tab("Relations", "exchange", "/editor/anime/connections/relations" + user.Settings().Editor.Filter.Suffix())
Tab("Characters", "users", "/editor/anime/connections/characters" + user.Settings().Editor.Filter.Suffix())
2018-03-26 17:44:35 +00:00
if strings.Contains(url, "/editor/anime/details")
.tabs
Tab("Genres", "clone", "/editor/anime/details/genres" + user.Settings().Editor.Filter.Suffix())
Tab("Synopsis", "align-left", "/editor/anime/details/synopsis" + user.Settings().Editor.Filter.Suffix())
2018-04-05 22:37:10 +00:00
Tab("Trailers", "youtube", "/editor/anime/details/trailers" + user.Settings().Editor.Filter.Suffix())
2018-03-26 17:44:35 +00:00
Tab("Start date", "calendar", "/editor/anime/details/startdate" + user.Settings().Editor.Filter.Suffix())
Tab("Ep. Length", "clock-o", "/editor/anime/details/episodelength" + user.Settings().Editor.Filter.Suffix())
Tab("Source", "book", "/editor/anime/details/source" + user.Settings().Editor.Filter.Suffix())
if strings.Contains(url, "/editor/anime/companies")
.tabs
Tab("Studios", "building", "/editor/anime/companies/studios" + user.Settings().Editor.Filter.Suffix())
Tab("Producers", "building", "/editor/anime/companies/producers" + user.Settings().Editor.Filter.Suffix())
Tab("Licensors", "building", "/editor/anime/companies/licensors" + user.Settings().Editor.Filter.Suffix())
2018-03-22 21:26:52 +00:00
if strings.Contains(url, "/editor/anime/mapping/")
.tabs
2018-03-23 00:43:45 +00:00
Tab("MAL", "arrows-h", "/editor/anime/mapping/mal" + user.Settings().Editor.Filter.Suffix())
Tab("Shoboi", "arrows-h", "/editor/anime/mapping/shoboi" + user.Settings().Editor.Filter.Suffix())
Tab("AniList", "arrows-h", "/editor/anime/mapping/anilist" + user.Settings().Editor.Filter.Suffix())
2018-03-23 02:37:14 +00:00
Tab("Duplicate", "exclamation-circle", "/editor/anime/mapping/duplicate" + user.Settings().Editor.Filter.Suffix())
2018-03-22 21:26:52 +00:00
if strings.Contains(url, "/editor/anime/image/")
.tabs
2018-03-23 00:43:45 +00:00
Tab("Low-Res", "image", "/editor/anime/image/lowres" + user.Settings().Editor.Filter.Suffix())
Tab("Ultra Low-Res", "image", "/editor/anime/image/ultralowres" + user.Settings().Editor.Filter.Suffix())
2018-04-13 11:09:46 +00:00
if strings.Contains(url, "/editor/soundtracks/")
.tabs
Tab("Links", "external-link", "/editor/soundtracks/links")
Tab("Lyrics", "font", "/editor/soundtracks/lyrics")
Tab("Tags", "tag", "/editor/soundtracks/tags")
Tab("File", "volume-off", "/editor/soundtracks/file")
if strings.Contains(url, "/editor/anime/") || strings.Contains(url, "/editor/mal/diff/anime")
.editor-filters
#filter-root(data-url=url)
2018-04-13 15:55:52 +00:00
ExploreFilters(user.Settings().Editor.Filter.Year, user.Settings().Editor.Filter.Season, user.Settings().Editor.Filter.Status, user.Settings().Editor.Filter.Type, true)
2018-03-23 00:43:45 +00:00