fix an issue with position of activity items

in previous version, if the screen width is narrow, valign of date is misaligned.
This commit is contained in:
suihan
2020-08-01 18:15:14 +09:00
parent d5e7e456b8
commit cd8052c24e

View File

@@ -70,7 +70,7 @@ function monthly(year, month, posts) {
const monthPosts = posts.filter(post => post.date.getMonth() === month); const monthPosts = posts.filter(post => post.date.getMonth() === month);
let liHtml = ''; let liHtml = '';
for (const post of monthPosts) { for (const post of monthPosts) {
liHtml += `<li class="d-block mt-1 py-1"><span class="css-truncate css-truncate-target"> liHtml += `<li class="d-flex mt-1 py-1 flex-row flex-nowrap flex-justify-between"><span class="flex-auto css-truncate css-truncate-target">
<span class="profile-rollup-icon"> <span class="profile-rollup-icon">
<svg class="octicon octicon-repo v-align-middle text-gray-light mr-1" viewBox="0 0 12 16" version="1.1" <svg class="octicon octicon-repo v-align-middle text-gray-light mr-1" viewBox="0 0 12 16" version="1.1"
width="12" height="16" aria-hidden="true"> width="12" height="16" aria-hidden="true">
@@ -81,9 +81,7 @@ function monthly(year, month, posts) {
</span> </span>
<a class="mr-2 " data-hovercard-type="repository" href="${post.link}">${post.title}</a> <a class="mr-2 " data-hovercard-type="repository" href="${post.link}">${post.title}</a>
</span> </span>
<span class="f6 text-gray d-block mt-1 d-lg-inline mt-lg-0"> <time title="This post was made on ${months[post.date.getMonth()]} ${post.date.getDate()}" class="f6 text-gray-light pt-1">
</span>
<time title="This post was made on ${months[post.date.getMonth()]} ${post.date.getDate()}" class="float-right f6 text-gray-light pt-1">
${months[post.date.getMonth()]} ${post.date.getDate()} ${months[post.date.getMonth()]} ${post.date.getDate()}
</time></li>`; </time></li>`;
} }