diff --git a/src/_data/colors.js b/src/_data/colors.js deleted file mode 100644 index 334a6fd..0000000 --- a/src/_data/colors.js +++ /dev/null @@ -1,62 +0,0 @@ -/** - * Color namer https://colornamer.robertcooper.me/ - */ - -const colors = { - aqua: { - 50: "#aae9d2", - 100: "#99e5ce", - 200: "#79ddcc", - 300: "#58d4d0", - 400: "#38bdcc", - 500: "#2c8daa", - 600: "#226186", - 700: "#193d61", - 800: "#10203d", - 900: "#060a18", - 950: "#020206", - }, - carotte: { - 400: "#ed5215", - }, - neutral: { - 50: "#fafafa", - 100: "#f5f5f5", - 200: "#e5e5e5", - 300: "#d4d4d4", - 400: "#a3a3a3", - 500: "#737373", - 600: "#525252", - 700: "#404040", - 800: "#262626", - 900: "#171717", - 950: "#0a0a0a", - white: "#ffffff", - black: "#000000", - }, -}; - -const colorSchemes = { - light: { - primary: "188deg 84% 35%", - secondary: "8 84% 50%", - background: "0 0% 98%", - surface: "188 27% 94%", - border: "188 48% 80%", - text: "0 0% 4%", - fadeText: "188 12% 32%", - shadow: "188deg 100% 18%", - }, - dark: { - primary: "188deg 84% 28%", - secondary: "8 84% 43%", - background: "0 0% 4%", - surface: "202 10% 10%", - border: "208 27% 15%", - text: "0 0% 98%", - fadeText: "188 12% 70%", - shadow: "188deg 100% 18%", - }, -}; - -module.exports = { colors, colorSchemes }; diff --git a/src/_data/fonts.js b/src/_data/fonts.js deleted file mode 100644 index 1bde92d..0000000 --- a/src/_data/fonts.js +++ /dev/null @@ -1,102 +0,0 @@ -/** - * This approach for managing Web Fonts was derived from - * Aleksandr Hovhannisyan. - * See more here: https://www.aleksandrhovhannisyan.com/blog/configuring-web-fonts-in-11ty-with-global-data/ - */ - -const path = require("path").posix; - -const FONT_STYLE = { - NORMAL: "normal", - ITALIC: "italic", -}; - -const FONT_DISPLAY = { - SWAP: "swap", -}; - -const FONT_VARIANT = { - BOLD: "Bold", - EXTRA_BOLD: "ExtraBold", - ITALIC: "Italic", - BOLD_ITALIC: "BoldItalic", - REGULAR: "Regular", -}; - -const getFontUrl = (src) => path.join("/assets/fonts", src); - -const fallbacks = [ - "-apple-system", - "BlinkMacSystemFont", - "Segoe UI", - "Roboto", - "Ubuntu", - "Open Sans", - "Helvetica Neue", - "sans-serif", -]; - -const fonts = { - display: { - family: "Anek Latin", - fallbacks, - weights: { - extraBold: { - display: FONT_DISPLAY.SWAP, - format: "truetype", - style: FONT_STYLE.NORMAL, - url: getFontUrl("/aneklatin/AnekLatin-ExtraBold.ttf"), - variant: FONT_VARIANT.EXTRA_BOLD, - weight: 800, - }, - bold: { - display: FONT_DISPLAY.SWAP, - format: "truetype", - style: FONT_STYLE.NORMAL, - url: getFontUrl("/aneklatin/AnekLatin-Bold.ttf"), - variant: FONT_VARIANT.BOLD, - weight: 700, - }, - }, - }, - body: { - family: "iA Writer Quattro V", - fallbacks, - weights: { - regular: { - display: FONT_DISPLAY.SWAP, - format: "woff2", - style: FONT_STYLE.NORMAL, - url: getFontUrl("/quattro/iAWriterQuattroS-Regular.woff2"), - variant: FONT_VARIANT.REGULAR, - weight: 400, - }, - italtic: { - display: FONT_DISPLAY.SWAP, - format: "woff2", - style: FONT_STYLE.ITALIC, - url: getFontUrl("/quattro/iAWriterQuattroS-Italic.woff2"), - variant: FONT_VARIANT.ITALIC, - weight: 400, - }, - bold: { - display: FONT_DISPLAY.SWAP, - format: "woff2", - style: FONT_STYLE.NORMAL, - url: getFontUrl("/quattro/iAWriterQuattroS-Bold.woff2"), - variant: FONT_VARIANT.BOLD, - weight: 650, - }, - boldItalic: { - display: FONT_DISPLAY.SWAP, - format: "woff2", - style: FONT_STYLE.ITALIC, - url: getFontUrl("/quattro/iAWriterQuattroS-BoldItalic.woff2"), - variant: FONT_VARIANT.BOLD_ITALIC, - weight: 650, - }, - }, - }, -}; - -module.exports = fonts; diff --git a/src/_data/spacing.js b/src/_data/spacing.js deleted file mode 100644 index b5ca970..0000000 --- a/src/_data/spacing.js +++ /dev/null @@ -1,15 +0,0 @@ -const BASE_SPACING = 16; - -const spacing = { - 0: 0, - 0.25: BASE_SPACING / 4, - 0.5: BASE_SPACING / 2, - 1: BASE_SPACING, - 1.5: BASE_SPACING * 1.5, - 2: BASE_SPACING * 2, - 3: BASE_SPACING * 3, - 4: BASE_SPACING * 4, - 5: BASE_SPACING * 5, -}; - -module.exports = spacing; diff --git a/src/_includes/css/colorVariables.njk b/src/_includes/css/colorVariables.njk deleted file mode 100644 index 8c628c3..0000000 --- a/src/_includes/css/colorVariables.njk +++ /dev/null @@ -1,29 +0,0 @@ -{% set colorSchemes = colors.colorSchemes %} -{% set lightScheme = colorSchemes.light %} -{% set darkScheme = colorSchemes.dark %} - -:root { -{% for colorName, value in lightScheme %} - --{{ colorName }}: {{ value }}; - --color-{{ colorName }}: hsl({{ value }}); -{% endfor %} -} - -{% for colorName, value in lightScheme %} -.bg-{{ colorName }} { - background-color: var(--color-{{ colorName }}); -} - -.text-{{ colorName }} { - color: var(--color-{{ colorName }}); -} -{% endfor %} - -@media (prefers-color-scheme: dark) { - :root { -{% for colorName, value in darkScheme %} - --{{ colorName }}: {{ value }}; - --color-{{ colorName }}: hsl({{ value }}); -{% endfor %} - } -} diff --git a/src/_includes/css/fontFace.njk b/src/_includes/css/fontFace.njk deleted file mode 100644 index d88bb36..0000000 --- a/src/_includes/css/fontFace.njk +++ /dev/null @@ -1,19 +0,0 @@ -{% set allFonts = fonts | values %} -{% for font in allFonts %} - {% set weights = font.weights | values %} - {% for fontEntry in weights %} - {% if fontEntry.url %} - {% set family = font.family %} - {% set localName = font.family %} - {% set postScriptName = [font.family, fontEntry.variant] | join("-") | replace(" ", "") %} - @font-face { - font-family: {{ family }}; - font-style: {{ fontEntry.style }}; - font-weight: {{ fontEntry.weight }}; - {% if fontEntry.display %}font-display: {{ fontEntry.display }};{% endif %} - src: local("{{ localName }}"), local("{{ postScriptName }}"), url("{{ fontEntry.url }}") format("{{ fontEntry.format }}") - } - {% endif %} - {% endfor %} -{% endfor %} - diff --git a/src/_includes/css/fontVariables.njk b/src/_includes/css/fontVariables.njk deleted file mode 100644 index 9ed6652..0000000 --- a/src/_includes/css/fontVariables.njk +++ /dev/null @@ -1,14 +0,0 @@ -{% set allFonts = fonts | entries %} - -html { -{% for fontType, fontConfig in fonts %} - {% set fallbackFonts = fontConfig.fallbacks | join(", ") %} - --font-family-{{ fontType }}: {{ fontConfig.family }}, {{ fallbackFonts }}; - {% for weightName, weightConfig in fontConfig.weights %} - {% if weightConfig.style != "italic" %} - --font-weight-{{ fontType }}-{{ weightName | lower }}: {{ weightConfig.weight }}; - {% endif %} - {% endfor %} -{% endfor %} -} - diff --git a/src/_includes/css/spacing.njk b/src/_includes/css/spacing.njk deleted file mode 100644 index c4bb800..0000000 --- a/src/_includes/css/spacing.njk +++ /dev/null @@ -1,94 +0,0 @@ -{% for keyRaw, value in spacing %} - {% set key = keyRaw | replace(".", "\\\.") | safe %} - .gap-{{ key }} { - gap: {{ value }}px; - } - - .row-gap-{{ key }} { - row-gap: {{ value }}px; - } - - .column-gap-{{ key }} { - column-gap: {{ value }}px; - } - - .p-{{ key }} { - padding: {{ value }}px; - } - - .px-{{ key }} { - padding-inline: {{ value }}px; - } - - .py-{{ key }} { - padding-block: {{ value }}px; - } - - .pl-{{ key }} { - padding-inline-start: {{ value }}px; - } - - .pr-{{ key }} { - padding-inline-end: {{ value }}px; - } - - .pt-{{ key }} { - padding-block-start: {{ value }}px; - } - - .pb-{{ key }} { - padding-block-end: {{ value }}px; - } - - .m-{{ key }} { - margin: {{ value }}px; - } - - .mx-{{ key }} { - margin-inline: {{ value }}px; - } - - .my-{{ key }} { - margin-block: {{ value }}px; - } - - .ml-{{ key }} { - margin-inline-start: {{ value }}px; - } - - .mr-{{ key }} { - margin-inline-end: {{ value }}px; - } - - .mt-{{ key }} { - margin-block-start: {{ value }}px; - } - - .mb-{{ key }} { - margin-block-end: {{ value }}px; - } - - .w-{{ key }} { - width: {{ value }}px; - } - - .h-{{ key }} { - height: {{ value }}px; - } - - .size-{{ key }} { - width: {{ value }}px; - height: {{ value }}px; - } - - .radius-{{ key }} { - border-radius: {{ value }}px; - } -{% endfor %} - -:root { -{% for keyRaw, value in spacing %} - {% set key = keyRaw | replace(".", "-") %} - --spacing-{{ key }}: {{ value }}px; -{% endfor %} -}