adds fonts and tailwind generation
This commit is contained in:
1 parent
1a7f4521f5
commit
935b4cd0e7
27 files changed
+171
-36
No files matched your search
@@ -0,0 +1,79 @@
|
|||||||
|
@font-face {
|
||||||
|
font-family: 'EB Garamond 12';
|
||||||
|
src: local('EB Garamond 12 Italic'), local('EBGaramond12-Italic'),
|
||||||
|
url('EBGaramond12-Italic.woff2') format('woff2'),
|
||||||
|
url('EBGaramond12-Italic.woff') format('woff');
|
||||||
|
font-weight: normal;
|
||||||
|
font-style: italic;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'EB Garamond 12';
|
||||||
|
src: local('EB Garamond 12 Regular'), local('EBGaramond12-Regular'),
|
||||||
|
url('EBGaramond12-Regular.woff2') format('woff2'),
|
||||||
|
url('EBGaramond12-Regular.woff') format('woff');
|
||||||
|
font-weight: normal;
|
||||||
|
font-style: normal;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'Iosevka';
|
||||||
|
src: local('Iosevka'),
|
||||||
|
url('Iosevka.woff2') format('woff2'),
|
||||||
|
url('Iosevka.woff') format('woff');
|
||||||
|
font-weight: normal;
|
||||||
|
font-style: normal;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'Iosevka';
|
||||||
|
src: local('Iosevka Bold'), local('Iosevka-Bold'),
|
||||||
|
url('Iosevka-Bold.woff2') format('woff2'),
|
||||||
|
url('Iosevka-Bold.woff') format('woff');
|
||||||
|
font-weight: bold;
|
||||||
|
font-style: normal;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'Iosevka';
|
||||||
|
src: local('Iosevka Bold Italic'), local('Iosevka-Bold-Italic'),
|
||||||
|
url('Iosevka-Bold-Italic.woff2') format('woff2'),
|
||||||
|
url('Iosevka-Bold-Italic.woff') format('woff');
|
||||||
|
font-weight: bold;
|
||||||
|
font-style: italic;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'Iosevka';
|
||||||
|
src: local('Iosevka Light'), local('Iosevka-Light'),
|
||||||
|
url('Iosevka-Light.woff2') format('woff2'),
|
||||||
|
url('Iosevka-Light.woff') format('woff');
|
||||||
|
font-weight: 300;
|
||||||
|
font-style: normal;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'Iosevka';
|
||||||
|
src: local('Iosevka Light Italic'), local('Iosevka-Light-Italic'),
|
||||||
|
url('Iosevka-Light-Italic.woff2') format('woff2'),
|
||||||
|
url('Iosevka-Light-Italic.woff') format('woff');
|
||||||
|
font-weight: 300;
|
||||||
|
font-style: italic;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: 'Iosevka';
|
||||||
|
src: local('Iosevka Oblique'), local('Iosevka-Oblique'),
|
||||||
|
url('Iosevka-Oblique.woff2') format('woff2'),
|
||||||
|
url('Iosevka-Oblique.woff') format('woff');
|
||||||
|
font-weight: normal;
|
||||||
|
font-style: italic;
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
$font-garamond: 'EB Garamond 12', serif;
|
||||||
|
$font-iosevka: 'Iosevka', monospace;
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
.wompum {
|
||||||
|
&-container {
|
||||||
|
width: 100%;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-grid {
|
||||||
|
display: grid;
|
||||||
|
gap: 0;
|
||||||
|
padding: 0;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
&-cell {
|
||||||
|
width: 100%;
|
||||||
|
min-height: 30px;
|
||||||
|
background-color: var(--sand-500);
|
||||||
|
|
||||||
|
// Create pseudo-random pattern using prime numbers
|
||||||
|
&:nth-child(7n+1) {
|
||||||
|
background-color: var(--sand-100);
|
||||||
|
}
|
||||||
|
|
||||||
|
&:nth-child(5n+2) {
|
||||||
|
background-color: var(--sand-900);
|
||||||
|
}
|
||||||
|
|
||||||
|
&:nth-child(11n+3) {
|
||||||
|
background-color: var(--sand-500);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
// Tailwind
|
||||||
|
@tailwind base;
|
||||||
|
@tailwind components;
|
||||||
|
@tailwind utilities;
|
||||||
|
|
||||||
|
// Variables
|
||||||
|
@import "variables";
|
||||||
|
|
||||||
|
// Fonts
|
||||||
|
@import "fonts";
|
||||||
|
|
||||||
|
// Components
|
||||||
|
@import "components/wompum";
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: $font-garamond;
|
||||||
|
font-size: 16px;
|
||||||
|
line-height: 1.5;
|
||||||
|
}
|
||||||
@@ -5,3 +5,6 @@ theme = "hugo-starter-tailwind-basic"
|
|||||||
|
|
||||||
[taxonomies]
|
[taxonomies]
|
||||||
tag = "tags"
|
tag = "tags"
|
||||||
|
|
||||||
|
[params]
|
||||||
|
customCSS = ["css/tailwind.css"]
|
||||||
@@ -7,15 +7,17 @@
|
|||||||
</title>
|
</title>
|
||||||
<meta name="description" content="{{ .Description }}" />
|
<meta name="description" content="{{ .Description }}" />
|
||||||
{{ partial "css-variables.html" . }}
|
{{ partial "css-variables.html" . }}
|
||||||
{{/* styles */}}
|
|
||||||
{{ $options := dict "inlineImports" true }}
|
{{/* Main Styles */}}
|
||||||
{{ $styles := resources.Get "css/styles.css" }}
|
{{ $styles := resources.Get "scss/main.scss" }}
|
||||||
{{ $styles = $styles | resources.PostCSS $options }}
|
{{ $styles = $styles | resources.ToCSS (dict "targetPath" "css/styles.css" "enableSourceMap" true) }}
|
||||||
|
{{ $styles = $styles | resources.PostCSS }}
|
||||||
|
|
||||||
{{ if hugo.IsProduction }}
|
{{ if hugo.IsProduction }}
|
||||||
{{ $styles = $styles | minify | fingerprint | resources.PostProcess }}
|
{{ $styles = $styles | minify | fingerprint | resources.PostProcess }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<link href="{{ $styles.RelPermalink }}" rel="stylesheet" />
|
<link href="{{ $styles.RelPermalink }}" rel="stylesheet" />
|
||||||
<link href="/css/wompum.css" rel="stylesheet" />
|
|
||||||
</head>
|
</head>
|
||||||
<body class="">
|
<body class="">
|
||||||
{{ partial "header.html" . }}
|
{{ partial "header.html" . }}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{{ define "main" }}
|
{{ define "main" }}
|
||||||
|
|
||||||
<article class="flex flex-col lg:flex-row-reverse">
|
<article class="flex flex-col lg:flex-row-reverse">
|
||||||
<header class="lg:sticky lg:top-0 lg:h-screen lg:overflow-y-auto lg:w-1/3 p-4">
|
<header class="lg:sticky lg:top-0 lg:h-screen lg:overflow-y-auto lg:w-1/3 p-4 font-iosevka">
|
||||||
<h1 class="font-bold">{{ .Title }}</h1>
|
<h1 class="font-bold">{{ .Title }}</h1>
|
||||||
<p><strong>Date:</strong> <time datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 2, 2006" }}</time></p>
|
<p><strong>Date:</strong> <time datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 2, 2006" }}</time></p>
|
||||||
<p><strong>Narrator:</strong> {{ .Params.narrator }}</p>
|
<p><strong>Narrator:</strong> {{ .Params.narrator }}</p>
|
||||||
|
|||||||
@@ -19,6 +19,10 @@
|
|||||||
"postcss-purgecss": "^2.0.3",
|
"postcss-purgecss": "^2.0.3",
|
||||||
"tailwindcss": "^2.2.7"
|
"tailwindcss": "^2.2.7"
|
||||||
},
|
},
|
||||||
|
"scripts": {
|
||||||
|
"build:css": "postcss assets/css/tailwind.css -o static/css/tailwind.css",
|
||||||
|
"watch:css": "postcss assets/css/tailwind.css -o static/css/tailwind.css --watch"
|
||||||
|
},
|
||||||
"name": "protocol-oral-history-project",
|
"name": "protocol-oral-history-project",
|
||||||
"version": "0.1.0"
|
"version": "0.1.0"
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
module.exports = {
|
||||||
|
plugins: {
|
||||||
|
tailwindcss: {},
|
||||||
|
autoprefixer: {},
|
||||||
|
},
|
||||||
|
};
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
.wompum-container {
|
|
||||||
width: 100%;
|
|
||||||
margin: 0 auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.wompum-grid {
|
|
||||||
display: grid;
|
|
||||||
gap: 0;
|
|
||||||
padding: 0;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.wompum-cell {
|
|
||||||
width: 100%;
|
|
||||||
min-height: 30px; /* Minimum height for cells */
|
|
||||||
background-color: var(--sand-500);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Create pseudo-random pattern using prime numbers */
|
|
||||||
.wompum-cell:nth-child(7n+1) {
|
|
||||||
background-color: var(--sand-100);
|
|
||||||
}
|
|
||||||
|
|
||||||
.wompum-cell:nth-child(5n+2) {
|
|
||||||
background-color: var(--sand-900);
|
|
||||||
}
|
|
||||||
|
|
||||||
.wompum-cell:nth-child(11n+3) {
|
|
||||||
background-color: var(--sand-500);
|
|
||||||
}
|
|
||||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,18 @@
|
|||||||
|
module.exports = {
|
||||||
|
content: [
|
||||||
|
'./layouts/**/*.html',
|
||||||
|
'./content/**/*.md',
|
||||||
|
'./assets/scss/**/*.scss',
|
||||||
|
],
|
||||||
|
theme: {
|
||||||
|
extend: {
|
||||||
|
fontFamily: {
|
||||||
|
'garamond': ['EB Garamond 12', 'serif'],
|
||||||
|
'iosevka': ['Iosevka', 'monospace'],
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
plugins: [
|
||||||
|
require('@tailwindcss/typography'),
|
||||||
|
],
|
||||||
|
};
|
||||||
Reference in new issue
Block a user