43 lines
2.1 KiB
HTML
43 lines
2.1 KiB
HTML
<!DOCTYPE html>
|
|
<html
|
|
xmlns:th="http://www.thymeleaf.org"
|
|
xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
|
|
xmlns:sec="http://www.thymeleaf.org/extras/spring-security"
|
|
layout:decorate="~{layout/default_layout}"
|
|
>
|
|
<head>
|
|
<th:block layout:fragment="head">
|
|
</th:block>
|
|
</head>
|
|
<body>
|
|
<th:block layout:fragment="content" id="content">
|
|
<section class="wrapper style1">
|
|
<div class="container">
|
|
<div class="row justify-content-center">
|
|
<div class="col-8 col-12-narrower">
|
|
<div id="content">
|
|
<article>
|
|
<section th:each="post : ${Posts}">
|
|
<div class="box post" th:id="${post.id}">
|
|
<a href="javascript:void(0);" th:onclick="'goToViewer(this.parentNode)'" class="image left">
|
|
<img th:src="${post.thumb != null and not #strings.isEmpty(post.thumb)} ? @{${post.thumb}} : @{/images/pic01.jpg}" alt="Post Thumbnail" />
|
|
</a>
|
|
<div class="inner">
|
|
<h3 th:text="${post.title != null and not #strings.isEmpty(post.title)} ? ${post.title} : 'untitled[' + ${#temporals.format(T(java.time.Instant).ofEpochMilli(post.writeTime).atZone(T(java.time.ZoneId).systemDefault()).toLocalDateTime(), 'yyyy-MM-dd HH:mm')} + ']'"></h3>
|
|
<p th:text="${#strings.abbreviate(post.html, 80)}" class="ellipsis"></p>
|
|
</div>
|
|
|
|
<footer sec:authorize="isAuthenticated()" style="text-align: right; margin-top: 1em;">
|
|
<a th:href="@{/blog/edit/{postId}(postId=${post.id})}" class="button small alt">수정</a>
|
|
</footer>
|
|
</div>
|
|
</section>
|
|
</article>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</section>
|
|
</th:block>
|
|
</body>
|
|
</html> |