aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Sebastiaan Zeeff <[email protected]>2019-08-23 15:55:34 +0200
committerGravatar Sebastiaan Zeeff <[email protected]>2019-08-23 15:55:34 +0200
commit92656a208825527fa1bd6ecb5a2294db9e96c9b0 (patch)
treec689c7c0f17366760b0a9779cb10cf634d93b708
parentAdding tests for deleted message view (diff)
Fixing inconsistent indentation style in logs template and logs css
-rw-r--r--pydis_site/static/css/staff/logs.css148
-rw-r--r--pydis_site/templates/staff/logs.html133
2 files changed, 143 insertions, 138 deletions
diff --git a/pydis_site/static/css/staff/logs.css b/pydis_site/static/css/staff/logs.css
index a09d33ac..d7bb04cf 100644
--- a/pydis_site/static/css/staff/logs.css
+++ b/pydis_site/static/css/staff/logs.css
@@ -7,7 +7,7 @@ main.site-content {
letter-spacing: 0;
text-rendering: optimizeLegibility;
padding: 1rem;
- font-family: Whitney,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif;
+ font-family: Whitney, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;
}
.has-small-margin {
@@ -39,7 +39,7 @@ main.site-content {
}
.discord-message-metadata {
- color: hsla(0,0%,100%,.2);
+ color: hsla(0, 0%, 100%, .2);
font-size: 0.75rem;
font-weight: 400;
margin: 0 .3rem;
@@ -59,10 +59,10 @@ main.site-content {
.discord-embed {
- position: relative;
- margin-top: 5px;
- max-width: 520px;
- display: flex;
+ position: relative;
+ margin-top: 5px;
+ max-width: 520px;
+ display: flex;
}
.discord-embed a {
@@ -76,24 +76,24 @@ main.site-content {
}
.discord-embed-color {
- width: 4px;
- border-radius: 3px 0 0 3px;
- flex-shrink: 0;
+ width: 4px;
+ border-radius: 3px 0 0 3px;
+ flex-shrink: 0;
}
.discord-embed-inner {
background-color: #34363b;
- padding: 8px 10px;
+ padding: 8px 10px;
border-radius: 0 3px 3px 0;
- box-sizing: border-box;
- border: 1px solid hsla(225, 8%, 20%, 0.6);
- display: flex;
- flex-direction: column;
+ box-sizing: border-box;
+ border: 1px solid hsla(225, 8%, 20%, 0.6);
+ display: flex;
+ flex-direction: column;
}
.discord-embed-content {
- width: 100%;
- display: flex;
+ width: 100%;
+ display: flex;
}
.discord-embed-main {
@@ -121,11 +121,11 @@ main.site-content {
}
.discord-embed-author-icon {
- margin-right: 9px;
- width: 20px;
- height: 20px;
- object-fit: contain;
- border-radius: 50%;
+ margin-right: 9px;
+ width: 20px;
+ height: 20px;
+ object-fit: contain;
+ border-radius: 50%;
}
.discord-embed-author a {
@@ -148,33 +148,33 @@ main.site-content {
}
.discord-embed-fields {
- display: flex;
- flex-direction: row;
- flex-wrap: wrap;
- margin-top: -10px;
- margin-bottom: 10px;
+ display: flex;
+ flex-direction: row;
+ flex-wrap: wrap;
+ margin-top: -10px;
+ margin-bottom: 10px;
}
.discord-embed-field {
- flex: 0;
- padding-top: 5px;
- min-width: 100%;
- max-width: 506px;
+ flex: 0;
+ padding-top: 5px;
+ min-width: 100%;
+ max-width: 506px;
}
.discord-embed-field-name {
- margin-bottom: 4px;
- font-weight: 600;
+ margin-bottom: 4px;
+ font-weight: 600;
}
.discord-embed-field-value {
- font-weight: 500;
+ font-weight: 500;
}
.discord-embed-field-inline {
- flex: 1;
- min-width: 150px;
- flex-basis: auto;
+ flex: 1;
+ min-width: 150px;
+ flex-basis: auto;
}
.discord-embed-main > :last-child {
@@ -182,33 +182,33 @@ main.site-content {
}
.discord-embed-image {
- position: relative;
- display: inline-block;
+ position: relative;
+ display: inline-block;
margin-bottom: 10px;
}
.discord-embed-image > img {
margin: 0;
- vertical-align: bottom;
- max-width: 300px;
- display: flex;
- overflow: hidden;
- border-radius: 2px;
+ vertical-align: bottom;
+ max-width: 300px;
+ display: flex;
+ overflow: hidden;
+ border-radius: 2px;
}
.discord-embed-footer-text {
- font-size: .70rem !important;
- letter-spacing: 0;
+ font-size: .70rem !important;
+ letter-spacing: 0;
display: inline-block;
}
.discord-embed-footer-icon {
- margin-right: 10px;
- height: 18px;
- width: 18px;
- object-fit: contain;
- float: left;
- border-radius: 50%;
+ margin-right: 10px;
+ height: 18px;
+ width: 18px;
+ object-fit: contain;
+ float: left;
+ border-radius: 50%;
}
.discord-embed-content {
@@ -221,32 +221,36 @@ main.site-content {
/* Discord Font definitions */
@font-face {
- font-family: Whitney;
- font-style: light;
- font-weight:300;
- src:url(https://discordapp.com/assets/6c6374bad0b0b6d204d8d6dc4a18d820.woff) format("woff")
+ font-family: Whitney;
+ font-style: light;
+ font-weight: 300;
+ src: url(https://discordapp.com/assets/6c6374bad0b0b6d204d8d6dc4a18d820.woff) format("woff")
}
+
@font-face {
- font-family: Whitney;
- font-style: normal;
- font-weight:500;
- src:url(https://discordapp.com/assets/e8acd7d9bf6207f99350ca9f9e23b168.woff) format("woff")
+ font-family: Whitney;
+ font-style: normal;
+ font-weight: 500;
+ src: url(https://discordapp.com/assets/e8acd7d9bf6207f99350ca9f9e23b168.woff) format("woff")
}
+
@font-face {
- font-family:Whitney;
- font-style: medium;
- font-weight:600;
- src:url(https://discordapp.com/assets/3bdef1251a424500c1b3a78dea9b7e57.woff) format("woff")
+ font-family: Whitney;
+ font-style: medium;
+ font-weight: 600;
+ src: url(https://discordapp.com/assets/3bdef1251a424500c1b3a78dea9b7e57.woff) format("woff")
}
+
@font-face {
- font-family: WhitneyMedium;
- font-style: medium;
- font-weight: 600;
- src:url(https://discordapp.com/assets/be0060dafb7a0e31d2a1ca17c0708636.woff) format("woff")
+ font-family: WhitneyMedium;
+ font-style: medium;
+ font-weight: 600;
+ src: url(https://discordapp.com/assets/be0060dafb7a0e31d2a1ca17c0708636.woff) format("woff")
}
+
@font-face {
- font-family: Whitney;
- font-style: bold;
- font-weight: 700;
- src:url(https://discordapp.com/assets/8e12fb4f14d9c4592eb8ec9f22337b04.woff) format("woff")
-} \ No newline at end of file
+ font-family: Whitney;
+ font-style: bold;
+ font-weight: 700;
+ src: url(https://discordapp.com/assets/8e12fb4f14d9c4592eb8ec9f22337b04.woff) format("woff")
+}
diff --git a/pydis_site/templates/staff/logs.html b/pydis_site/templates/staff/logs.html
index 49d9c368..e5b3627d 100644
--- a/pydis_site/templates/staff/logs.html
+++ b/pydis_site/templates/staff/logs.html
@@ -13,84 +13,85 @@
<li>Deleted by: <span style="color: {{ actor_colour | hex_colour }}">{{ actor }}</span></li>
<li>Date: {{ creation }}</li>
</ul>
-
<div class="is-divider has-small-margin"></div>
- {% for message in messages %}
+ {% for message in messages %}
<div class="discord-message">
<div class="discord-message-header">
- <span class="discord-username" style="color: {{ message.author.top_role.colour | hex_colour }}">{{ message.author }}</span><span class="discord-message-metadata">{{ message.timestamp }} | User ID: {{ message.author.id }}</span>
+ <span class="discord-username"
+ style="color: {{ message.author.top_role.colour | hex_colour }}">{{ message.author }}</span><span
+ class="discord-message-metadata">{{ message.timestamp }} | User ID: {{ message.author.id }}</span>
</div>
<div class="discord-message-content">
{{ message.content|linebreaks }}
</div>
-
- {% for embed in message.embeds %}
- <div class="discord-embed is-size-7">
- <div class="discord-embed-color" style="background-color: {% if embed.color %}{{ embed.color | hex_colour }}{% else %}#cacbce{% endif %}">
- </div>
- <div class="discord-embed-inner">
- <div class="discord-embed-content">
- <div class="discord-embed-main">
-
- {% if embed.author %}
- <div class="discord-embed-author">
- {% if embed.author.icon_url %}<img alt="Author Icon" class="discord-embed-author-icon" src="{{ embed.author.icon_url }}">{% endif %}
- {% if embed.author.url %}<a class="discord-embed-author-url" href="{{ embed.author.url }}">{% endif %}
- <span class="discord-embed-author-name">{{ embed.author.name }}</span>
- {% if embed.author.url %}</a>{% endif %}
- </div>
- {% endif %}
-
- {% if embed.title %}
- <div class="discord-embed-title">
- {% if embed.url %}<a href="{{ embed.url }}">{% endif %}
- {{ embed.title }}
- {% if embed.url %}</a>{% endif %}
- </div>
- {% endif %}
-
- {% if embed.description %}
- <div class="discord-embed-description">
- {{ embed.description | linebreaksbr }}
- </div>
- {% endif %}
-
- {% if embed.fields %}
- <div class="discord-embed-fields">
- {% for field in embed.fields %}
- <div class="discord-embed-field{% if field.inline %} discord-embed-field-inline{% endif %}">
- <div class="discord-embed-field-name">{{ field.name }}</div>
- <div class="discord-embed-field-value">{{ field.value }}</div>
+ {% for embed in message.embeds %}
+ <div class="discord-embed is-size-7">
+ <div class="discord-embed-color" style="background-color: {% if embed.color %}{{ embed.color | hex_colour }}{% else %}#cacbce{% endif %}"></div>
+ <div class="discord-embed-inner">
+ <div class="discord-embed-content">
+ <div class="discord-embed-main">
+ {% if embed.author %}
+ <div class="discord-embed-author">
+ {% if embed.author.icon_url %}
+ <img alt="Author Icon" class="discord-embed-author-icon"
+ src="{{ embed.author.icon_url }}">{% endif %}
+ {% if embed.author.url %}<a class="discord-embed-author-url"
+ href="{{ embed.author.url }}">{% endif %}
+ <span class="discord-embed-author-name">{{ embed.author.name }}</span>
+ {% if embed.author.url %}</a>{% endif %}
</div>
- {% endfor %}
- </div>
- {% endif %}
- {% if embed.image %}
- <div class="discord-embed-image">
- <img alt="Discord Embed Image" src="{{ embed.image.url }}">
+ {% endif %}
+ {% if embed.title %}
+ <div class="discord-embed-title">
+ {% if embed.url %}<a href="{{ embed.url }}">{% endif %}
+ {{ embed.title }}
+ {% if embed.url %}</a>{% endif %}
+ </div>
+ {% endif %}
+ {% if embed.description %}
+ <div class="discord-embed-description">
+ {{ embed.description | linebreaksbr }}
+ </div>
+ {% endif %}
+ {% if embed.fields %}
+ <div class="discord-embed-fields">
+ {% for field in embed.fields %}
+ <div class="discord-embed-field{% if field.inline %} discord-embed-field-inline{% endif %}">
+ <div class="discord-embed-field-name">{{ field.name }}</div>
+ <div class="discord-embed-field-value">{{ field.value }}</div>
+ </div>
+ {% endfor %}
+ </div>
+ {% endif %}
+ {% if embed.image %}
+ <div class="discord-embed-image">
+ <img alt="Discord Embed Image" src="{{ embed.image.url }}">
+ </div>
+ {% endif %}
</div>
+ {% if embed.thumbnail %}
+ <div class="discord-embed-thumbnail">
+ <img alt="Embed thumbnail" src="{{ embed.thumbnail.url }}">
+ </div>
{% endif %}
</div>
- {% if embed.thumbnail %}
- <div class="discord-embed-thumbnail">
- <img alt="Embed thumbnail" src="{{ embed.thumbnail.url }}">
- </div>
- {% endif %}
+ {% if embed.footer or embed.timestamp %}
+ <div class="discord-embed-footer">
+ {% if embed.footer.icon_url %}
+ <img class="discord-embed-footer-icon" alt="Footer Icon"
+ src="{{ embed.footer.icon_url }}">
+ {% endif %}
+ {% if embed.footer.text or embed.timestamp %}
+ <span class="discord-embed-footer-text">{% endif %}
+ {% if embed.footer.text %}{{ embed.footer.text }}{% endif %}
+ {% if embed.footer.text and embed.timestamp %} • {% endif %}
+ {% if embed.timestamp %}{{ embed.timestamp | footer_datetime }}{% endif %}
+ {% if embed.footer.text or embed.timestamp %}</span>{% endif %}
+ </div>
+ {% endif %}
</div>
- {% if embed.footer or embed.timestamp %}
- <div class="discord-embed-footer">
- {% if embed.footer.icon_url %}
- <img class="discord-embed-footer-icon" alt="Footer Icon" src="{{ embed.footer.icon_url }}">
- {% endif %}
-
- {% if embed.footer.text or embed.timestamp %}<span class="discord-embed-footer-text">{% endif %}
- {% if embed.footer.text %}{{ embed.footer.text }}{% endif %}{% if embed.footer.text and embed.timestamp %} • {% endif %}{% if embed.timestamp %}{{ embed.timestamp | footer_datetime }}{% endif %}
- {% if embed.footer.text or embed.timestamp %}</span>{% endif %}
</div>
- {% endif %}
- </div>
- </div>
- {% endfor %}
+ {% endfor %}
</div>
{% endfor %}
-{% endblock %} \ No newline at end of file
+{% endblock %}