head.swig 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. <meta charset="UTF-8">
  2. <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=2">
  3. <meta name="theme-color" content="{{ theme.android_chrome_color }}">
  4. <meta name="generator" content="Hexo {{ hexo_version }}">
  5. {%- if theme.favicon.apple_touch_icon %}
  6. <link rel="apple-touch-icon" sizes="180x180" href="{{ url_for(theme.favicon.apple_touch_icon) }}">
  7. {%- endif %}
  8. {%- if theme.favicon.medium %}
  9. <link rel="icon" type="image/png" sizes="32x32" href="{{ url_for(theme.favicon.medium) }}">
  10. {%- endif %}
  11. {%- if theme.favicon.small %}
  12. <link rel="icon" type="image/png" sizes="16x16" href="{{ url_for(theme.favicon.small) }}">
  13. {%- endif %}
  14. {%- if theme.favicon.safari_pinned_tab %}
  15. <link rel="mask-icon" href="{{ url_for(theme.favicon.safari_pinned_tab) }}" color="{{ theme.android_chrome_color }}">
  16. {%- endif %}
  17. {%- if theme.favicon.android_manifest %}
  18. <link rel="manifest" href="{{ url_for(theme.favicon.android_manifest) }}">
  19. {%- endif %}
  20. {%- if theme.favicon.ms_browserconfig %}
  21. <meta name="msapplication-config" content="{{ url_for(theme.favicon.ms_browserconfig) }}">
  22. {%- endif %}
  23. {%- if theme.disable_baidu_transformation %}
  24. <meta http-equiv="Cache-Control" content="no-transform">
  25. <meta http-equiv="Cache-Control" content="no-siteapp">
  26. {%- endif %}
  27. {%- if theme.google_site_verification %}
  28. <meta name="google-site-verification" content="{{ theme.google_site_verification }}">
  29. {%- endif %}
  30. {%- if theme.bing_site_verification %}
  31. <meta name="msvalidate.01" content="{{ theme.bing_site_verification }}">
  32. {%- endif %}
  33. {%- if theme.yandex_site_verification %}
  34. <meta name="yandex-verification" content="{{ theme.yandex_site_verification }}">
  35. {%- endif %}
  36. {%- if theme.baidu_site_verification %}
  37. <meta name="baidu-site-verification" content="{{ theme.baidu_site_verification }}">
  38. {%- endif %}
  39. <link rel="stylesheet" href="{{ url_for(theme.css) }}/main.css">
  40. {{ next_font() }}
  41. {%- set font_awesome_uri = theme.vendors.fontawesome or next_vendors('font-awesome/css/all.min.css') %}
  42. <link rel="stylesheet" href="{{ font_awesome_uri }}">
  43. {%- if theme.fancybox %}
  44. {%- set fancybox_css_uri = theme.vendors.fancybox_css or next_vendors('//cdn.jsdelivr.net/gh/fancyapps/fancybox@3/dist/jquery.fancybox.min.css') %}
  45. <link rel="stylesheet" href="{{ fancybox_css_uri }}">
  46. {%- endif %}
  47. {%- if theme.pace.enable %}
  48. {%- set pace_css_uri = theme.vendors.pace_css or next_vendors('pace/pace-theme-' + theme.pace.theme + '.min.css') %}
  49. {%- set pace_js_uri = theme.vendors.pace or next_vendors('pace/pace.min.js') %}
  50. <link rel="stylesheet" href="{{ pace_css_uri }}">
  51. <script src="{{ pace_js_uri }}"></script>
  52. {%- endif %}
  53. {{ next_config() }}