[dw-free] Add a CSS class 'entry-author' to comments when made by the entry's author
[commit: http://hg.dwscoalition.org/dw-free/rev/99c48a83486a]
http://bugs.dwscoalition.org/show_bug.cgi?id=1439
Additional CSS styling option for comments made by the post's author.
Patch by
foxfirefey.
Files modified:
http://bugs.dwscoalition.org/show_bug.cgi?id=1439
Additional CSS styling option for comments made by the post's author.
Patch by
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Files modified:
- bin/upgrading/s2layers/core2.s2
-------------------------------------------------------------------------------- diff -r 215c981ac1f0 -r 99c48a83486a bin/upgrading/s2layers/core2.s2 --- a/bin/upgrading/s2layers/core2.s2 Tue Jul 21 23:08:22 2009 -0500 +++ b/bin/upgrading/s2layers/core2.s2 Wed Jul 22 12:31:14 2009 -0500 @@ -3757,6 +3757,7 @@ function Entry::print_wrapper_start() { """<div class="inner">\n"""; } function Comment::print_wrapper_start() { + var EntryPage ep = get_page() as EntryPage; var string alternate = alternate ("comment-wrapper-odd", "comment-wrapper-even"); var string screened = $this.screened ? "screened" : "visible"; var string deletedstate = $this.deleted ? "deleted" : ""; @@ -3764,7 +3765,11 @@ function Comment::print_wrapper_start() var string poster = defined $this.poster ? "poster-" + $this.poster.username : "poster-anonymous"; var string full = $this.full ? "full" : "partial"; var string userpic = $this.userpic ? "has-userpic" : "no-userpic"; - """<div class="comment-wrapper $alternate $screened $frozen $deletedstate $poster $full $userpic" id="$this.anchor">\n"""; + var string entryauthor = ""; + if (not isnull $ep and defined $this.poster and $this.poster.username == $ep.entry.poster.username) { + $entryauthor = "entry-author"; + } + """<div class="comment-wrapper $alternate $screened $frozen $deletedstate $poster $entryauthor $full $userpic" id="$this.anchor">\n"""; """<div class="separator separator-before"><div class="inner"></div></div>\n"""; """<div class="comment" id="comment-$this.dom_id">\n"""; """<div class="inner">\n"""; --------------------------------------------------------------------------------