Update for changes in /pol/ flags since last time. #1403
This commit is contained in:
parent
f0eb9baa44
commit
4e5595e81f
@ -52,6 +52,7 @@ Build =
|
||||
pass: if data.since4pass? then "#{data.since4pass}" else undefined
|
||||
uniqueID: data.id
|
||||
flagCode: data.country
|
||||
flagCodeTroll: data.troll_country
|
||||
flag: Build.unescape data.country_name
|
||||
dateUTC: data.time
|
||||
dateText: data.now
|
||||
@ -104,7 +105,7 @@ Build =
|
||||
|
||||
post: (o) ->
|
||||
{ID, threadID, boardID, file} = o
|
||||
{subject, email, name, tripcode, capcode, pass, uniqueID, flagCode, flag, dateUTC, dateText, commentHTML} = o.info
|
||||
{subject, email, name, tripcode, capcode, pass, uniqueID, flagCode, flagCodeTroll, flag, dateUTC, dateText, commentHTML} = o.info
|
||||
{staticPath, gifIcon} = Build
|
||||
|
||||
### Post Info ###
|
||||
|
||||
@ -11,13 +11,8 @@
|
||||
?{boardID === "f" && !o.isReply || capcodeDescription}{}{ }
|
||||
?{capcodeDescription}{ <img src="${staticPath}${capcodeLC}icon${gifIcon}" alt="${capcode} Icon" title="This user is ${capcodeDescription}." class="identityIcon retina">}
|
||||
?{uniqueID && !capcode}{ <span class="posteruid id_${uniqueID}">(ID: <span class="hand" title="Highlight posts by this ID">${uniqueID}</span>)</span>}
|
||||
?{flagCode}{
|
||||
?{boardID === "pol"}{
|
||||
\ <img src="${staticPath}country/troll/${flagCode.toLowerCase()}.gif" alt="${flagCode}" title="${flag}" class="countryFlag">
|
||||
}{
|
||||
\ <span title="${flag}" class="flag flag-${flagCode.toLowerCase()}"></span>
|
||||
}
|
||||
}
|
||||
?{flagCode}{ <span title="${flag}" class="flag flag-${flagCode.toLowerCase()}"></span>}
|
||||
?{flagCodeTroll}{ <img src="${staticPath}country/troll/${flagCodeTroll.toLowerCase()}.gif" alt="${flagCodeTroll}" title="${flag}" class="countryFlag">}
|
||||
</span>
|
||||
<span class="dateTime" data-utc="${dateUTC}">${dateText}</span>
|
||||
<span class="postNum?{!(boardID === "f" && !o.isReply)}{ desktop}">
|
||||
|
||||
@ -596,27 +596,28 @@ QR =
|
||||
textContent: val[1]
|
||||
|
||||
fn flag for flag in [
|
||||
['0', 'None']
|
||||
['US', 'American']
|
||||
['KP', 'Best Korean']
|
||||
['0', 'Geographic Location']
|
||||
['AC', 'Anarcho-Capitalist']
|
||||
['AN', 'Anarchist']
|
||||
['BL', 'Black Nationalist']
|
||||
['CM', 'Communist']
|
||||
['CF', 'Confederate']
|
||||
['RE', 'Conservative']
|
||||
['CM', 'Communist']
|
||||
['DM', 'Democrat']
|
||||
['EU', 'European']
|
||||
['FC', 'Fascist']
|
||||
['GN', 'Gadsden']
|
||||
['GY', 'Gay']
|
||||
['PC', 'Hippie']
|
||||
['IL', 'Israeli']
|
||||
['DM', 'Liberal']
|
||||
['RP', 'Libertarian']
|
||||
['JH', 'Jihadi']
|
||||
['KN', 'Kekistani']
|
||||
['MF', 'Muslim']
|
||||
['NB', 'National Bolshevik']
|
||||
['NZ', 'Nazi']
|
||||
['OB', 'Obama']
|
||||
['PC', 'Hippie']
|
||||
['PR', 'Pirate']
|
||||
['RB', 'Rebel']
|
||||
['TP', 'Tea Partier']
|
||||
['TX', 'Texan']
|
||||
['RE', 'Republican']
|
||||
['TM', 'Templar']
|
||||
['TR', 'Tree Hugger']
|
||||
['UN', 'United Nations']
|
||||
['WP', 'White Supremacist']
|
||||
]
|
||||
|
||||
|
||||
@ -31,6 +31,7 @@ class Post
|
||||
capcode: @nodes.capcode?.textContent.replace '## ', ''
|
||||
pass: @nodes.pass?.title.match(/\d*$/)[0]
|
||||
flagCode: @nodes.flag?.className.match(/flag-(\w+)/)?[1].toUpperCase()
|
||||
flagCodeTroll: @nodes.flag?.src?.match(/(\w+)\.gif$/)?[1].toUpperCase()
|
||||
flag: @nodes.flag?.title
|
||||
date: if @nodes.date then new Date(@nodes.date.dataset.utc * 1000)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user