And a few more conditionals.
This commit is contained in:
parent
9836d5ad07
commit
dded914e41
@ -119,12 +119,8 @@ class Fetcher
|
|||||||
greentext = text[0] is '>'
|
greentext = text[0] is '>'
|
||||||
text = text.replace /(\[\/?[a-z]+):lit(\])/, '$1$2'
|
text = text.replace /(\[\/?[a-z]+):lit(\])/, '$1$2'
|
||||||
text = for text2, j in text.split /(>>(?:>\/[a-z\d]+\/)?\d+)/g
|
text = for text2, j in text.split /(>>(?:>\/[a-z\d]+\/)?\d+)/g
|
||||||
if j % 2 is 1
|
<%= html('?{j % 2}{<span class="deadlink">${text2}</span>}{${text2}}') %>
|
||||||
<%= html('<span class="deadlink">${text2}</span>') %>
|
text = <%= html('?{greentext}{<span class="quote">@{text}</span>}{@{text}}') %>
|
||||||
else
|
|
||||||
<%= html('${text2}') %>
|
|
||||||
text = <%= html('@{text}') %>
|
|
||||||
text = <%= html('<span class="quote">&{text}</span>') %> if greentext
|
|
||||||
text
|
text
|
||||||
comment = <%= html('@{comment}') %>
|
comment = <%= html('@{comment}') %>
|
||||||
|
|
||||||
|
|||||||
@ -40,7 +40,7 @@ FileInfo =
|
|||||||
else
|
else
|
||||||
<%= html('<span class="fnswitch"><span class="fntrunc">${shortname}</span><span class="fnfull">${fullname}</span></span>') %>
|
<%= html('<span class="fnswitch"><span class="fntrunc">${shortname}</span><span class="fnfull">${fullname}</span></span>') %>
|
||||||
N: -> <%= html('${this.file.name}') %>
|
N: -> <%= html('${this.file.name}') %>
|
||||||
p: -> if @file.isSpoiler then <%= html('Spoiler, ') %> else <%= html('') %>
|
p: -> <%= html('?{this.file.isSpoiler}{Spoiler, }') %>
|
||||||
s: -> <%= html('${this.file.size}') %>
|
s: -> <%= html('${this.file.size}') %>
|
||||||
B: -> <%= html('${Math.round(this.file.sizeInBytes)} Bytes') %>
|
B: -> <%= html('${Math.round(this.file.sizeInBytes)} Bytes') %>
|
||||||
K: -> <%= html('${Math.round(this.file.sizeInBytes/1024)} KB') %>
|
K: -> <%= html('${Math.round(this.file.sizeInBytes/1024)} KB') %>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user