Compare commits

..

No commits in common. "e48a6818bbdc78dafee59f818c2f7731dd970e2d" and "281752e25bebd23c4b3ebe917c7cb1434d1110a6" have entirely different histories.

11 changed files with 17 additions and 61 deletions

View file

@ -1,10 +1,5 @@
{ pkgs }: { pkgs }:
let
stylesheetHash = builtins.substring 0 12 (builtins.hashFile "sha256" ../site/styles.css);
stylesheetFileName = "styles-${stylesheetHash}.css";
in
pkgs.stdenvNoCC.mkDerivation { pkgs.stdenvNoCC.mkDerivation {
pname = "tide-landing-page"; pname = "tide-landing-page";
version = "1.0.0"; version = "1.0.0";
@ -17,11 +12,6 @@ pkgs.stdenvNoCC.mkDerivation {
mkdir -p "$out" mkdir -p "$out"
cp -R . "$out" cp -R . "$out"
mv "$out/styles.css" "$out/${stylesheetFileName}"
substituteInPlace "$out/index.html" \
--replace-fail \
'href="/styles.css"' \
'href="/${stylesheetFileName}"'
runHook postInstall runHook postInstall
''; '';

View file

@ -25,8 +25,6 @@ let
}; };
evaluatedConfig = evaluatedSystem.config; evaluatedConfig = evaluatedSystem.config;
landingPage = self.packages.${system}.landing-page; landingPage = self.packages.${system}.landing-page;
stylesheetHash = builtins.substring 0 12 (builtins.hashFile "sha256" ../../site/styles.css);
stylesheetFileName = "styles-${stylesheetHash}.css";
landingVirtualHost = evaluatedConfig.services.nginx.virtualHosts."torahimderecheretz.com"; landingVirtualHost = evaluatedConfig.services.nginx.virtualHosts."torahimderecheretz.com";
discourseConfig = evaluatedConfig.services.discourse; discourseConfig = evaluatedConfig.services.discourse;
backupConfig = evaluatedConfig.services.borgbackup.jobs.discourse; backupConfig = evaluatedConfig.services.borgbackup.jobs.discourse;
@ -64,41 +62,10 @@ assert !(evaluatedConfig.services.nginx.virtualHosts ? "tide.yisroelbaum.com");
assert !(evaluatedConfig.services.nginx.virtualHosts ? "apitide.yisroelbaum.com"); assert !(evaluatedConfig.services.nginx.virtualHosts ? "apitide.yisroelbaum.com");
pkgs.runCommand "tide-module-test" { } '' pkgs.runCommand "tide-module-test" { } ''
test -f ${landingPage}/index.html test -f ${landingPage}/index.html
test -f ${landingPage}/${stylesheetFileName} test -f ${landingPage}/styles.css
test ! -e ${landingPage}/styles.css
test -f ${landingPage}/robots.txt test -f ${landingPage}/robots.txt
test -f ${landingPage}/assets/rav-hirsch-later-life.jpg test -f ${landingPage}/assets/rav-hirsch-1847.jpg
test -f ${landingPage}/assets/rav-hirsch-later-life.webp test -f ${landingPage}/assets/rav-hirsch-1847.webp
test -f ${landingPage}/assets/social-preview-hirsch-later-life.png
test ! -e ${landingPage}/assets/rav-hirsch-1847.jpg
test ! -e ${landingPage}/assets/rav-hirsch-1847.webp
${pkgs.diffutils}/bin/cmp \
${../../site/styles.css} \
${landingPage}/${stylesheetFileName}
${pkgs.gnugrep}/bin/grep -F \
'aspect-ratio: 5 / 6;' \
${landingPage}/${stylesheetFileName}
${pkgs.gnugrep}/bin/grep -F \
'href="/${stylesheetFileName}"' \
${landingPage}/index.html
${pkgs.gnugrep}/bin/grep -F \
'href="/assets/rav-hirsch-later-life.webp"' \
${landingPage}/index.html
${pkgs.gnugrep}/bin/grep -F \
'src="/assets/rav-hirsch-later-life.jpg"' \
${landingPage}/index.html
${pkgs.gnugrep}/bin/grep -F \
'height="600"' \
${landingPage}/index.html
${pkgs.gnugrep}/bin/grep -F \
'assets/social-preview-hirsch-later-life.png' \
${landingPage}/index.html
if ${pkgs.gnugrep}/bin/grep -F \
'href="/styles.css"' \
${landingPage}/index.html; then
echo "unexpected unversioned stylesheet reference" >&2
exit 1
fi
${pkgs.gnugrep}/bin/grep -F \ ${pkgs.gnugrep}/bin/grep -F \
"A Torah vision for the whole of life." \ "A Torah vision for the whole of life." \
${landingPage}/index.html ${landingPage}/index.html

Binary file not shown.

After

Width:  |  Height:  |  Size: 292 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 336 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 429 KiB

View file

@ -19,12 +19,12 @@
<rect width="18" height="630" fill="#743d36"/> <rect width="18" height="630" fill="#743d36"/>
<rect x="55" y="52" width="1090" height="526" fill="none" stroke="#ad8950"/> <rect x="55" y="52" width="1090" height="526" fill="none" stroke="#ad8950"/>
<image <image
x="650" x="790"
y="0" y="0"
width="600" width="600"
height="630" height="630"
preserveAspectRatio="xMidYMid slice" preserveAspectRatio="xMidYMid slice"
xlink:href="rav-hirsch-later-life.jpg" xlink:href="rav-hirsch-1847.jpg"
clip-path="url(#portrait-clip)" clip-path="url(#portrait-clip)"
/> />
<rect x="790" width="180" height="630" fill="url(#portrait-fade)"/> <rect x="790" width="180" height="630" fill="url(#portrait-fade)"/>

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

Before After
Before After

View file

@ -21,11 +21,11 @@
<meta property="og:url" content="https://torahimderecheretz.com/"> <meta property="og:url" content="https://torahimderecheretz.com/">
<meta <meta
property="og:image" property="og:image"
content="https://torahimderecheretz.com/assets/social-preview-hirsch-later-life.png" content="https://torahimderecheretz.com/assets/social-preview.png"
> >
<meta <meta
property="og:image:alt" property="og:image:alt"
content="Torah Im Derech Eretz with a later-life portrait of Rav Samson Raphael Hirsch" content="Torah Im Derech Eretz: A Torah vision for the whole of life"
> >
<meta name="twitter:card" content="summary_large_image"> <meta name="twitter:card" content="summary_large_image">
@ -46,7 +46,7 @@
> >
<link <link
rel="preload" rel="preload"
href="/assets/rav-hirsch-later-life.webp" href="/assets/rav-hirsch-1847.webp"
as="image" as="image"
type="image/webp" type="image/webp"
> >
@ -112,14 +112,14 @@
<div class="portrait__frame"> <div class="portrait__frame">
<picture> <picture>
<source <source
srcset="/assets/rav-hirsch-later-life.webp" srcset="/assets/rav-hirsch-1847.webp"
type="image/webp" type="image/webp"
> >
<img <img
src="/assets/rav-hirsch-later-life.jpg" src="/assets/rav-hirsch-1847.jpg"
width="500" width="960"
height="600" height="1005"
alt="Later-life portrait of Rav Samson Raphael Hirsch wearing glasses and a dark cap" alt="Lithographic portrait of Rav Samson Raphael Hirsch as a young man"
> >
</picture> </picture>
<span class="portrait__dates">1808 · 1888</span> <span class="portrait__dates">1808 · 1888</span>
@ -311,11 +311,10 @@
<div class="container site-footer__legal"> <div class="container site-footer__legal">
<p>© Torah Im Derech Eretz</p> <p>© Torah Im Derech Eretz</p>
<p> <p>
Portrait: Rav Samson Raphael Hirsch, before 1889, creator unknown. Portrait: 1847 lithograph by Druck von Schier,
National Library of Israel via
<a <a
href="https://commons.wikimedia.org/wiki/File:Samson_Raphael_Hirsch_(FL12173324).crop.jpg" href="https://commons.wikimedia.org/wiki/File:Druck_von_Schier._Samson_Raphael_Hirsch.1847.jpg"
>Wikimedia Commons</a>, public domain. >public domain</a>.
</p> </p>
</div> </div>
</footer> </footer>

View file

@ -398,7 +398,7 @@ cite {
.portrait img { .portrait img {
width: 100%; width: 100%;
aspect-ratio: 5 / 6; aspect-ratio: 0.955;
background: #d7cec1; background: #d7cec1;
filter: sepia(0.12) contrast(1.04); filter: sepia(0.12) contrast(1.04);
object-fit: cover; object-fit: cover;