add bumplock css
This commit is contained in:
parent
702ab469cd
commit
024f773a7c
@ -731,6 +731,10 @@ func (self *thread) HasOmittedImages() bool {
|
|||||||
return self.truncatedImageCount > 0
|
return self.truncatedImageCount > 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (self *thread) BumpLock() bool {
|
||||||
|
return len(self.Posts) >= BumpLimit
|
||||||
|
}
|
||||||
|
|
||||||
func (self *thread) Update(db Database) {
|
func (self *thread) Update(db Database) {
|
||||||
root := self.Posts[0].MessageID()
|
root := self.Posts[0].MessageID()
|
||||||
self.Posts = append([]PostModel{self.Posts[0]}, db.GetThreadReplyPostModels(self.prefix, root, 0, 0)...)
|
self.Posts = append([]PostModel{self.Posts[0]}, db.GetThreadReplyPostModels(self.prefix, root, 0, 0)...)
|
||||||
|
@ -528,3 +528,8 @@ background-repeat: repeat;
|
|||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin-left: none;
|
margin-left: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.bumplock {
|
||||||
|
background: red;
|
||||||
|
filter: saturate(0.5);
|
||||||
|
}
|
||||||
|
@ -41,8 +41,12 @@
|
|||||||
<br />
|
<br />
|
||||||
{{{form}}}
|
{{{form}}}
|
||||||
{{#board.Threads}}
|
{{#board.Threads}}
|
||||||
{{#Truncate}}
|
{{#BumpLock}}
|
||||||
|
<div class="thread bumplock" id="thread_{{OP.PostHash}}">
|
||||||
|
{{^BumpLock}}
|
||||||
<div class="thread" id="thread_{{OP.PostHash}}">
|
<div class="thread" id="thread_{{OP.PostHash}}">
|
||||||
|
{{/BumpLock}}
|
||||||
|
{{#Truncate}}
|
||||||
{{{OP.RenderPost}}}
|
{{{OP.RenderPost}}}
|
||||||
<div class="excluded">{{MissingPostCount}} posts excluded</div>
|
<div class="excluded">{{MissingPostCount}} posts excluded</div>
|
||||||
{{#Replies}}
|
{{#Replies}}
|
||||||
|
@ -39,8 +39,11 @@
|
|||||||
<center><b><a href="{{thread.BoardURL}}">{{thread.Board}}</a></b></center>
|
<center><b><a href="{{thread.BoardURL}}">{{thread.Board}}</a></b></center>
|
||||||
<br />
|
<br />
|
||||||
{{{form}}}
|
{{{form}}}
|
||||||
|
{{#thread.BumpLock}}
|
||||||
|
<div class="thread bumplock" id="thread_{{thread.OP.PostHash}}">
|
||||||
|
{{^thread.BumpLock}}
|
||||||
<div class="thread" id="thread_{{thread.OP.PostHash}}">
|
<div class="thread" id="thread_{{thread.OP.PostHash}}">
|
||||||
|
{{/thread.BumpLock}}
|
||||||
{{{thread.OP.RenderPost}}}
|
{{{thread.OP.RenderPost}}}
|
||||||
{{#thread.Replies}}
|
{{#thread.Replies}}
|
||||||
{{{RenderPost}}}
|
{{{RenderPost}}}
|
||||||
|
@ -45,8 +45,12 @@
|
|||||||
{{/next}}
|
{{/next}}
|
||||||
</div>
|
</div>
|
||||||
{{#threads}}
|
{{#threads}}
|
||||||
{{#Truncate}}
|
{{#BumpLock}}
|
||||||
|
<div class="thread bumplock" id="thread_{{OP.PostHash}}">
|
||||||
|
{{^BumpLock}}
|
||||||
<div class="thread" id="thread_{{OP.PostHash}}">
|
<div class="thread" id="thread_{{OP.PostHash}}">
|
||||||
|
{{/BumpLock}}
|
||||||
|
{{#Truncate}}
|
||||||
Posted on <a href="{{BoardURL}}">{{Board}}</a>
|
Posted on <a href="{{BoardURL}}">{{Board}}</a>
|
||||||
<br />
|
<br />
|
||||||
{{{OP.RenderTruncatedPost}}}
|
{{{OP.RenderTruncatedPost}}}
|
||||||
|
Reference in New Issue
Block a user