2016-11-09 20:32:19 +09:00

130 lines
5.3 KiB
Plaintext

component Anime(anime *arn.Anime)
section.anime-container(data-id=anime.ID)
header.anime-header
if anime.Image != ""
.anime-image-container
img.anime-image(src=anime.Image, alt=anime.Title.Romaji)
.info-column
h2.anime-title-db(title=anime.Type)= anime.Title.Romaji
//- if user && user.titleLanguage === "japanese"
//- p.second-title-container
//- span.second-title(title=anime.Title.English !== anime.Title.Romaji ? anime.Title.English : null)= anime.Title.Romaji
//- else
if anime.Title.Japanese != anime.Title.Romaji
p.second-title-container
a.second-title(href="http://jisho.org/search/" + anime.Title.Japanese, target="_blank", title="Look up reading on jisho.org", rel="nofollow")= anime.Title.Japanese
//- h3.anime-header.anime-summary-header Summary
p.anime-summary= anime.Description
if anime.YoutubeID != ""
h3.anime-header Video
.anime-trailer.video-container
iframe.video(src="https://www.youtube.com/embed/" + anime.YoutubeID + "?showinfo=0", allowfullscreen="allowfullscreen")
if anime.Tracks != nil && anime.Tracks.Opening != nil
h3.anime-header Tracks
iframe.anime-track(src="https://w.soundcloud.com/player/?url=" + anime.Tracks.Opening.URI + "?auto_play=false&hide_related=true&show_comments=true&show_user=true&show_reposts=false&visual=true")
//- if user && friendsWatching && friendsWatching.length > 0
//- include ../messages/avatar.pug
//- h3.anime-header Watching
//- .user-list
//- each watcher in friendsWatching
//- +avatar(watcher)
if len(anime.Genres) > 0
h3.anime-header Genres
.light-button-group
each genre in anime.Genres
if genre != ""
a.light-button.ajax(href="/genres/" + arn.FixGenre(genre))
Icon(arn.GenreIcons[genre])
span= genre
if len(anime.Studios) > 0
h3.anime-header Studios
.light-button-group
each studio in anime.Studios
a.light-button(href="https://anilist.co/studio/" + s(studio.ID), target="_blank")
i.fa.fa-building.fa-fw
span= studio.Name
//- //-if crunchy
//- //- h3.anime-header Episodes
//- if canEdit
//- #staff-info
//- h3.anime-header Links
//- table
//- tbody
//- tr
//- td MyAnimeList
//- td
//- input.save-on-change(id="MyAnimeList", type="text", value=providers.MyAnimeList ? providers.MyAnimeList.providerId : ", disabled=(providers.MyAnimeList && providers.MyAnimeList.similarity === 1) ? true : false)
//- td
//- a(href="https://www.google.co.jp/search?q=site:myanimelist.net/anime+" + anime.title.romaji.replace(/ /g, "+"), target="_blank")
//- .fa.fa-search
//- td
//- tr
//- td HummingBird
//- td
//- input.save-on-change(id="HummingBird", type="text", value=providers.HummingBird ? providers.HummingBird.providerId : ", disabled=(providers.HummingBird && providers.HummingBird.similarity === 1) ? true : false)
//- td
//- a(href="https://www.google.co.jp/search?q=site:hummingbird.me/anime+" + anime.title.romaji.replace(/ /g, "+"), target="_blank")
//- .fa.fa-search
//- td
//- tr
//- td AnimePlanet
//- td
//- input.save-on-change(id="AnimePlanet", type="text", value=providers.AnimePlanet ? providers.AnimePlanet.providerId : ", disabled=(providers.AnimePlanet && providers.AnimePlanet.similarity === 1) ? true : false)
//- td
//- a(href="https://www.google.co.jp/search?q=site:anime-planet.com/anime+" + anime.title.english.replace(/ /g, "+"), target="_blank")
//- .fa.fa-search
//- td
//- - var title = providers.Nyaa ? providers.Nyaa.title : "
//- - var proposedTitle = nyaa.buildNyaaTitle(anime.title.romaji)
//- tr
//- td Nyaa
//- td
//- input.save-on-change(id="Nyaa", type="text", value=title, placeholder=proposedTitle)
//- td
//- a(href="https://www.nyaa.se/?page=search&cats=1_37&filter=0&sort=2&term=" + (title ? title.replace(/ /g, "+") : proposedTitle), target="_blank")
//- .fa.fa-search
//- td
//- if providers.Nyaa && providers.Nyaa.episodes !== undefined
//- span(class=providers.Nyaa.episodes === 0 ? "entry-error" : "entry-ok")= providers.Nyaa.episodes + " eps"
h3.anime-header Links
.light-button-group
if anime.Links != nil
each link in anime.Links
a.light-button(href=link.URL, target="_blank")= link.Title
if anime.CreatedBy == ""
a.light-button(href="https://anilist.co/anime/" + s(anime.ID), target="_blank") AniList
//- if providers.HummingBird
//- a.light-button(href="https://hummingbird.me/anime/" + providers.HummingBird.providerId, target="_blank") HummingBird
//- if providers.MyAnimeList
//- a.light-button(href="http://myanimelist.net/anime/" + providers.MyAnimeList.providerId, target="_blank") MyAnimeList
//- if providers.AnimePlanet
//- a.light-button(href="http://www.anime-planet.com/anime/" + providers.AnimePlanet.providerId, target="_blank") AnimePlanet
.sources
p Powered by Anilist.
//- if descriptionSource
//- span= " Summary by " + summarySource + "."
//- //-
//- h3.anime-header Synonyms
//- if anime.title.synonyms
//- ul.anime-synonyms
//- li.anime-japanese-title= anime.title.japanese
//- each synonym in anime.title.synonyms
//- li= synonym