<!DOCTYPE html>
<html
  xmlns:th="https://www.thymeleaf.org"
  th:lang="${#locale.toLanguageTag}" 
  th:fragment="html (header, content, footer)">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <link rel="icon" type="image/x-icon" th:href="${theme.config.basic.favicon}">
    <title th:text="${title}"></title>
    <link rel="manifest" th:href="@{/assets/dist/manifest.json}" />
    <link rel="stylesheet" th:href="@{/assets/dist/main.css?version={version}(version=${theme.spec.version})}" href="./assets/dist/style.css" />
  </head>
  <!-- 根据情况判断是否添加开启像素化样式 -->
  <body class="main" th:classappend="${theme.config.basic.pixel_style} ? 'pixel_style' : '' ">
    <div class="center headings--one-size container">
      <th:block th:if="${header != null}">
        <th:block th:replace="${header}" />
      </th:block>
      <th:block th:if="${header == null}">
        <th:block th:replace="~{modules/header :: header(isHome = true)}" />
      </th:block>

      <th:block th:replace="${content}" />

      <th:block th:if="${footer == null}">
        <th:block th:replace="~{modules/footer}" />
      </th:block>
      <th:block th:if="${footer != null}">
        <th:block th:replace="${footer}" />
      </th:block>
    </div>
    <script th:src="@{/assets/dist/main.js?version={version}(version=${theme.spec.version})}"></script>
  </body>
</html>
