fonts for preview

This commit is contained in:
Gavin McDonald
2025-05-20 08:23:35 -04:00
parent 097b254740
commit 161e2a5476
2 changed files with 51 additions and 0 deletions

View File

@@ -79,6 +79,15 @@ RUN sed -i 's/main/main contrib non-free/g' /etc/apt/sources.list && \
apt-get clean && \
rm -f /var/lib/apt/lists/*_*
# fonts for preview
RUN mkdir -p /app/_build/prod/lib/labelmaker/priv/static/fonts
RUN ln -s /usr/share/fonts/truetype/msttcorefonts/Comic_Sans_MS.ttf /app/_build/prod/lib/labelmaker/priv/static/fonts
RUN ln -s /usr/share/fonts/truetype/msttcorefonts/Georgia.ttf /app/_build/prod/lib/labelmaker/priv/static/fonts
RUN ln -s /usr/share/fonts/truetype/msttcorefonts/Impact.ttf /app/_build/prod/lib/labelmaker/priv/static/fonts
RUN ln -s /usr/share/fonts/truetype/msttcorefonts/Verdana.ttf /app/_build/prod/lib/labelmaker/priv/static/fonts
RUN ln -s /usr/share/fonts/opentype/urw-base35/NimbusMonoPS-Regular.otf /app/_build/prod/lib/labelmaker/priv/static/fonts/Courier.otf
RUN ln -s /usr/share/fonts/opentype/urw-base35/NimbusSans-Regular.otf /app/_build/prod/lib/labelmaker/priv/static/fonts/Helvetica.otf
# Debian version still uses 'convert'
RUN ln -s $(which convert) /usr/local/bin/magick

View File

@@ -3,3 +3,45 @@
@import 'tailwindcss/utilities';
/* This file is for your main application CSS */
@font-face {
font-family: 'Comic-Sans-MS';
src: url('/fonts/Comic_Sans_MS.ttf') format('truetype');
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: 'Georgia';
src: url('/fonts/Georgia.ttf') format('truetype');
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: 'Impact';
src: url('/fonts/Impact.ttf') format('truetype');
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: 'Verdana';
src: url('/fonts/Verdana.ttf') format('truetype');
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: 'Courier';
src: url('/fonts/Courier.otf') format('opentype');
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: 'Helvetica';
src: url('/fonts/Helvetica.otf') format('opentype');
font-weight: normal;
font-style: normal;
}