Revamp reglog UI to handle spambots better.
Shorten some reglog phrase names. Shorten some modlog phrase names. Add account_privacy phrase. Tweak account_blocked phrase. Add account_menu_privacy phrase. Add account_privacy_head phrase. Add account_privacy_profile_comments phrase. Add account_privacy_button phrase.
This commit is contained in:
parent
f0a0e1acb3
commit
0fa9a3fca1
|
@ -140,11 +140,12 @@
|
|||
"profile": "%s's Profile",
|
||||
"account":"My Account",
|
||||
"account_password":"Edit Password",
|
||||
"account_privacy":"Privacy",
|
||||
"account_mfa":"Manage 2FA",
|
||||
"account_mfa_setup":"Setup 2FA",
|
||||
"account_email":"Email Manager",
|
||||
"account_logins":"Logins",
|
||||
"account_blocked":"Blocked",
|
||||
"account_blocked":"Blocks",
|
||||
"account_penalties":"Penalties",
|
||||
"account_level_list":"Level Progress",
|
||||
"convos":"Conversations",
|
||||
|
@ -503,6 +504,7 @@
|
|||
"account_menu_security":"Security",
|
||||
"account_menu_notifications":"Notifications",
|
||||
"account_menu_logins":"Logins",
|
||||
"account_menu_privacy":"Privacy",
|
||||
"account_menu_blocked":"Blocked",
|
||||
"account_menu_penalties":"Penalties",
|
||||
"account_menu_messages":"Messages",
|
||||
|
@ -533,6 +535,10 @@
|
|||
"account_password_confirm_password":"Confirm Password",
|
||||
"account_password_update_button":"Update",
|
||||
|
||||
"account_privacy_head":"Privacy",
|
||||
"account_privacy_profile_comments":"Enable Profile Comments",
|
||||
"account_privacy_button":"Update",
|
||||
|
||||
"account_mfa_head":"Manage 2FA",
|
||||
"account_mfa_disable_explanation":"You can disable two-factor authentication on your account and go back to logging in normal with just your password by clicking on the following button.",
|
||||
"account_mfa_disable_button":"Disable 2FA",
|
||||
|
@ -1001,27 +1007,27 @@
|
|||
"panel_statistics_memory_no_memory":"No memory chunks could be found in the selected time range",
|
||||
|
||||
"panel_logs_menu_head":"Logs",
|
||||
"panel_logs_registration_head":"Registrations",
|
||||
"panel_logs_registration_attempt":"Attempt",
|
||||
"panel_logs_registration_email":"email",
|
||||
"panel_logs_registration_reason":"reason",
|
||||
"panel_logs_registration_no_logs":"There aren't any registrations logged.",
|
||||
"panel_logs_reg_head":"Registrations",
|
||||
"panel_logs_reg_attempt":"Attempt: ",
|
||||
"panel_logs_reg_email":"email: ",
|
||||
"panel_logs_reg_reason":"reason: ",
|
||||
"panel_logs_reg_no_logs":"There aren't any registrations logged.",
|
||||
|
||||
"panel_logs_moderation_head":"Mod Action Logs",
|
||||
"panel_logs_moderation_action_topic_stick":"<a href='%s'>%s</a> was pinned by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_topic_unstick":"<a href='%s'>%s</a> was unpinned by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_topic_lock":"<a href='%s'>%s</a> was locked by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_topic_unlock":"<a href='%s'>%s</a> was reopened by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_topic_delete":"Topic #%d was deleted by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_topic_move":"<a href='%s'>%s</a> was moved by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_topic_move_dest":"<a href='%s'>%s</a> was moved to <a href='%s'>%s</a> by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_topic_unknown":"Unknown action '%s' on elementType '%s' by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_reply_delete":"A reply in <a href='%s'>%s</a> was deleted by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_user_ban":"<a href='%s'>%s</a> was banned by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_user_unban":"<a href='%s'>%s</a> was unbanned by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_user_activate":"<a href='%s'>%s</a> was activated by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_action_unknown":"Unknown action '%s' on elementType '%s' by <a href='%s'>%s</a>",
|
||||
"panel_logs_moderation_no_logs":"There aren't any events logged.",
|
||||
"panel_logs_mod_head":"Mod Action Logs",
|
||||
"panel_logs_mod_action_topic_stick":"<a href='%s'>%s</a> was pinned by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_topic_unstick":"<a href='%s'>%s</a> was unpinned by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_topic_lock":"<a href='%s'>%s</a> was locked by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_topic_unlock":"<a href='%s'>%s</a> was reopened by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_topic_delete":"Topic #%d was deleted by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_topic_move":"<a href='%s'>%s</a> was moved by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_topic_move_dest":"<a href='%s'>%s</a> was moved to <a href='%s'>%s</a> by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_topic_unknown":"Unknown action '%s' on elementType '%s' by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_reply_delete":"A reply in <a href='%s'>%s</a> was deleted by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_user_ban":"<a href='%s'>%s</a> was banned by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_user_unban":"<a href='%s'>%s</a> was unbanned by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_user_activate":"<a href='%s'>%s</a> was activated by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_action_unknown":"Unknown action '%s' on elementType '%s' by <a href='%s'>%s</a>",
|
||||
"panel_logs_mod_no_logs":"There aren't any events logged.",
|
||||
|
||||
"user_unknown":"Unknown",
|
||||
"topic_unknown":"Unknown",
|
||||
|
|
|
@ -55,7 +55,7 @@ func handleUnknownTopic(topic *c.Topic, err error) *c.Topic {
|
|||
// TODO: Move the log building logic into /common/ and it's own abstraction
|
||||
func topicElementTypeAction(action string, elementType string, elementID int, actor *c.User, topic *c.Topic) (out string) {
|
||||
if action == "delete" {
|
||||
return p.GetTmplPhrasef("panel_logs_moderation_action_topic_delete", elementID, actor.Link, actor.Name)
|
||||
return p.GetTmplPhrasef("panel_logs_mod_action_topic_delete", elementID, actor.Link, actor.Name)
|
||||
}
|
||||
var tbit string
|
||||
aarr := strings.Split(action, "-")
|
||||
|
@ -67,15 +67,15 @@ func topicElementTypeAction(action string, elementType string, elementID int, ac
|
|||
fid, _ := strconv.Atoi(aarr[1])
|
||||
forum, err := c.Forums.Get(fid)
|
||||
if err == nil {
|
||||
return p.GetTmplPhrasef("panel_logs_moderation_action_topic_move_dest", topic.Link, topic.Title, forum.Link, forum.Name, actor.Link, actor.Name)
|
||||
return p.GetTmplPhrasef("panel_logs_mod_action_topic_move_dest", topic.Link, topic.Title, forum.Link, forum.Name, actor.Link, actor.Name)
|
||||
}
|
||||
}
|
||||
tbit = "move"
|
||||
default:
|
||||
return p.GetTmplPhrasef("panel_logs_moderation_action_topic_unknown", action, elementType, actor.Link, actor.Name)
|
||||
return p.GetTmplPhrasef("panel_logs_mod_action_topic_unknown", action, elementType, actor.Link, actor.Name)
|
||||
}
|
||||
if tbit != "" {
|
||||
return p.GetTmplPhrasef("panel_logs_moderation_action_topic_"+tbit, topic.Link, topic.Title, actor.Link, actor.Name)
|
||||
return p.GetTmplPhrasef("panel_logs_mod_action_topic_"+tbit, topic.Link, topic.Title, actor.Link, actor.Name)
|
||||
}
|
||||
return fmt.Sprintf(out, topic.Link, topic.Title, actor.Link, actor.Name)
|
||||
}
|
||||
|
@ -87,15 +87,15 @@ func modlogsElementType(action string, elementType string, elementID int, actor
|
|||
out = topicElementTypeAction(action, elementType, elementID, actor, topic)
|
||||
case "user":
|
||||
targetUser := handleUnknownUser(c.Users.Get(elementID))
|
||||
out = p.GetTmplPhrasef("panel_logs_moderation_action_user_"+action, targetUser.Link, targetUser.Name, actor.Link, actor.Name)
|
||||
out = p.GetTmplPhrasef("panel_logs_mod_action_user_"+action, targetUser.Link, targetUser.Name, actor.Link, actor.Name)
|
||||
case "reply":
|
||||
if action == "delete" {
|
||||
topic := handleUnknownTopic(c.TopicByReplyID(elementID))
|
||||
out = p.GetTmplPhrasef("panel_logs_moderation_action_reply_delete", topic.Link, topic.Title, actor.Link, actor.Name)
|
||||
out = p.GetTmplPhrasef("panel_logs_mod_action_reply_delete", topic.Link, topic.Title, actor.Link, actor.Name)
|
||||
}
|
||||
}
|
||||
if out == "" {
|
||||
out = p.GetTmplPhrasef("panel_logs_moderation_action_unknown", action, elementType, actor.Link, actor.Name)
|
||||
out = p.GetTmplPhrasef("panel_logs_mod_action_unknown", action, elementType, actor.Link, actor.Name)
|
||||
}
|
||||
return out
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<div class="colstack_item colstack_head">
|
||||
<div class="rowitem"><h1>{{lang "panel_logs_moderation_head"}}</h1></div>
|
||||
<div class="rowitem"><h1>{{lang "panel_logs_mod_head"}}</h1></div>
|
||||
</div>
|
||||
<div id="panel_modlogs" class="colstack_item rowlist loglist">
|
||||
{{range .Logs}}
|
||||
|
@ -13,10 +13,6 @@
|
|||
</span>
|
||||
<div style="clear:both;"></div>
|
||||
</div>
|
||||
{{else}}
|
||||
<div class="rowitem rowmsg">
|
||||
<a>{{lang "panel_logs_moderation_no_logs"}}</a>
|
||||
</div>
|
||||
{{end}}
|
||||
{{else}}<div class="rowitem rowmsg"><a>{{lang "panel_logs_mod_no_logs"}}</a></div>{{end}}
|
||||
</div>
|
||||
{{template "paginator.html" . }}
|
|
@ -1,22 +1,16 @@
|
|||
<div class="colstack_item colstack_head">
|
||||
<div class="rowitem"><h1>{{lang "panel_logs_registration_head"}}</h1></div>
|
||||
<div class="rowitem"><h1>{{lang "panel_logs_reg_head"}}</h1></div>
|
||||
</div>
|
||||
<div id="panel_modlogs" class="colstack_item rowlist loglist">
|
||||
<div id="panel_reglogs" class="colstack_item rowlist loglist">
|
||||
{{range .Logs}}
|
||||
<div class="rowitem panel_compactrow{{if not .Success}} bg_red{{end}}">
|
||||
<span class="to_left{{if not .Success}} panel_registration_attempt{{end}}">
|
||||
<span>{{if not .Success}}{{lang "panel_logs_registration_attempt"}}: {{end}}{{.Username}}{{if .Email}} ({{lang "panel_logs_registration_email"}}: {{.Email}}){{end}}{{if .ParsedReason}} ({{lang "panel_logs_registration_reason"}}: {{.ParsedReason}}){{end}}</span>
|
||||
{{if $.CurrentUser.Perms.ViewIPs}}<br /><small title="{{.IP}}">{{.IP}}</small>{{end}}
|
||||
</span>
|
||||
<span class="to_right">
|
||||
<span title="{{.DoneAt}}">{{.DoneAt}}</span>
|
||||
</span>
|
||||
<div style="clear:both;"></div>
|
||||
<span>{{if not .Success}}{{lang "panel_logs_reg_attempt"}}{{end}}{{.Username}}{{if .Email}} ({{lang "panel_logs_reg_email"}}{{.Email}}){{end}}{{if .ParsedReason}} ({{lang "panel_logs_reg_reason"}}{{.ParsedReason}}){{end}}</span>
|
||||
<div class="logdetail">
|
||||
{{if $.CurrentUser.Perms.ViewIPs}}<small class="to_left" title="{{.IP}}">{{.IP}}</small>{{end}}
|
||||
<span class="to_right"><small title="{{.DoneAt}}">{{.DoneAt}}</small></span>
|
||||
<div style="clear:both;"></div>
|
||||
</div>
|
||||
</div>
|
||||
{{else}}
|
||||
<div class="rowitem rowmsg">
|
||||
<a>{{lang "panel_logs_registration_no_logs"}}</a>
|
||||
</div>
|
||||
{{end}}
|
||||
{{else}}<div class="rowitem rowmsg"><a>{{lang "panel_logs_reg_no_logs"}}</a></div>{{end}}
|
||||
</div>
|
||||
{{template "paginator.html" . }}
|
|
@ -395,6 +395,18 @@ select + .timeRangeSelector {
|
|||
margin-bottom: 18px;
|
||||
}
|
||||
|
||||
#panel_reglogs .panel_compactrow {
|
||||
flex-direction: column;
|
||||
}
|
||||
.logdetail {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
margin-top: 4px;
|
||||
}
|
||||
#panel_reglogs .logdetail small, #panel_reglogs .logdetails span {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.pageset {
|
||||
margin-left: 16px;
|
||||
}
|
||||
|
|
|
@ -26,9 +26,6 @@
|
|||
.menu_stats {
|
||||
margin-left: 4px;
|
||||
}
|
||||
/*.back_to_site {
|
||||
font-size: 18px;
|
||||
}*/
|
||||
.above_right {
|
||||
background-color: rgb(62, 62, 62);
|
||||
margin-top: -12px;
|
||||
|
@ -397,10 +394,7 @@ span.grip::after {
|
|||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
}
|
||||
#widgetTmpl {
|
||||
display: none;
|
||||
}
|
||||
.widget_disabled {
|
||||
#widgetTmpl, .widget_disabled {
|
||||
display: none;
|
||||
}
|
||||
.bg_red .widget_disabled {
|
||||
|
@ -417,6 +411,18 @@ span.grip::after {
|
|||
height: 80px;
|
||||
}
|
||||
|
||||
#panel_reglogs .panel_compactrow {
|
||||
flex-direction: column;
|
||||
}
|
||||
.logdetail {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
margin-top: 3px;
|
||||
}
|
||||
#panel_reglogs .logdetail small, #panel_reglogs .logdetails span {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
#panel_debug .grid_stat:not(.grid_stat_head) {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"Name": "nox",
|
||||
"FriendlyName": "Nox (Incomplete)",
|
||||
"FriendlyName": "Nox",
|
||||
"Version": "0.0.1",
|
||||
"Creator": "Azareal",
|
||||
"URL": "github.com/Azareal/Gosora",
|
||||
|
|
|
@ -152,6 +152,13 @@ select + .timeRangeSelector {
|
|||
display: block;
|
||||
}
|
||||
|
||||
.logdetail {
|
||||
margin-top: 4px;
|
||||
}
|
||||
#panel_reglogs .logdetail small, #panel_reglogs .logdetails span {
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.pageset {
|
||||
margin-left: 0px;
|
||||
margin-bottom: 0px;
|
||||
|
|
|
@ -198,4 +198,11 @@ select + .timeRangeSelector {
|
|||
content: "";
|
||||
display: block;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.logdetail {
|
||||
margin-top: 5px;
|
||||
}
|
||||
#panel_reglogs .logdetail small, #panel_reglogs .logdetails span {
|
||||
font-size: 14px;
|
||||
}
|
Loading…
Reference in New Issue