24 Commits

Author SHA1 Message Date
Cedric
f01f33953b Use a sans-serif math font
Some checks failed
Test book and website for given image / test-book-website (push) Has been cancelled
pgfplots uses math fonts for graphs ticks... and it looks weird when
building sans serif.

Not sure Fira is necessarily a great choice with open-sans but we have
very little math so that should do...
2025-01-12 15:17:27 +00:00
Ced
92ff917d4d Merge remote-tracking branch 'upstream/main' into sans_serif_pics_website 2025-01-12 12:22:39 +00:00
Ced
c3904d2f14 Delete rogue draft file
Some checks failed
Release the book and website / build-and-push-image (push) Has been cancelled
Release the book and website / release-book-website (push) Has been cancelled
Release the book and website / invalidate-book-website-cache (push) Has been cancelled
2025-01-12 12:16:58 +00:00
Hendrik Kleinwaechter
3792dcc20a Fix website build 2025-01-12 12:36:27 +01:00
cedounet
e77e7e5260 Merge pull request #430 from hendricius/new_starter_flowchart
New starter flowchart
2025-01-12 11:35:38 +00:00
Ced
9ad48ea1a3 Fix more uppercase in flowcharts
Some checks failed
Test book and website for given image / test-book-website (push) Has been cancelled
2025-01-11 11:09:16 +00:00
Ced
fe667b82e8 Fix merge error in starter-process flowchart 2025-01-11 11:01:49 +00:00
Ced
19029daf8a Merge remote-tracking branch 'upstream/new_starter_flowchart' into new_starter_flowchart 2025-01-11 10:51:01 +00:00
Ced
fa157c350e Use uppercase in flowcharts conditions 2025-01-11 10:31:19 +00:00
Ced
3069b5ff7c Remove the MWE from git
was added for the debug branches but shall not go to main.
2025-01-11 10:31:19 +00:00
Ced
3a1b247bc4 Reworked flowchart as per discussions 2025-01-11 10:30:07 +00:00
cedounet
d7b2cb6be4 Merge pull request #425 from ramink/new_starter_flowchart
Some checks failed
Test book and website for given image / test-book-website (push) Has been cancelled
Update more arrows to match the flow arrows in flowcharts.
2025-01-10 09:49:24 +00:00
Ramin Kamal
ae7c7fda8f Change plots to use "Latex" arrows for the axes 2025-01-09 15:46:48 -08:00
Ramin Kamal
1ab7970708 Change "Repeat 3 times" elements to use "Latex" arrows 2025-01-09 15:45:54 -08:00
Cedric
221119e6d0 Merge branch 'main' into new_starter_flowchart 2025-01-09 22:31:07 +00:00
Cedric
bd1050d75d Merge remote-tracking branch 'hendiricus/main' 2025-01-09 22:30:57 +00:00
Ramin Kamal
2afe5cff49 Rearrange starter process flowchart
- Added an extra state for clarity
- Made it more compact
- Added details section
2025-01-09 22:19:51 +00:00
Ramin Kamal
1166f6d925 Update all flowchart arrows to LaTeX arrows
- Change tikzstyle definition for "line" so that all flowchart arrows
  have the "Latex" styling.
2025-01-09 21:48:38 +00:00
Ramin Kamal
bf6a319e8f Chang arrowheads to be cleaner LaTex style.
Update flowcharts_tikz.tex to use arrows.meta instead of arrows, which
is not nice and deprecated.
2025-01-09 21:28:52 +00:00
Cedric
a87cc723a6 Enable abbreviations in standalone flowcharts
Spun the file out for inclusion basically... we want to be able to use
\eg in flowcharts even when built standalone.

Fixed dependencies in makefile as well
2025-01-09 21:21:15 +00:00
Cedric
127ca9423e Enable standalone chemical figures generation 2025-01-09 21:04:40 +00:00
Cedric
54461ec45e Fix makefile standalone flowchart png generation 2025-01-09 21:02:36 +00:00
Cedric
99e96c768f Merge remote-tracking branch 'hendiricus/main' 2025-01-05 18:11:24 +00:00
Cedric
8efa4fb424 Move mixing seed from troubleshooting to mix-ins
This was written way before the mix-ins sections, made sense back then
but not so much anymore so moving it out.

formatted text and added centering, labels etc while at it.
2025-01-03 22:56:54 +00:00
21 changed files with 98 additions and 90 deletions

4
book/abbreviations.tex Normal file
View File

@@ -0,0 +1,4 @@
% Common abbreviations
\newcommand{\ie}{\emph{i.e.}\@ifnextchar.{\!\@gobble}{}}
\newcommand{\eg}{\emph{e.g.}\@ifnextchar.{\!\@gobble}{}}
\newcommand{\etc}{etc\@ifnextchar.{}{.\@}}

View File

@@ -20,10 +20,10 @@
% Same tricks not to get double lines and also we do _not_ want arrows
\path [draw, thick] (ph_value) -- node{} ++(2, 0);
\path [draw, thick] (smell) -| node{} ++(2, 4);
\path [line] (dough_ready) -- node{yes} (divide_preshape);
\path [line] (dough_ready) |- node[right=3pt]{no} (dough_flattened);
\path [line] (dough_flattened) |- node[right=3pt]{yes} (stretch_fold);
\path [line] (dough_flattened) -- node{no} (wait_60_minutes);
\path [line] (dough_ready) -- node{Yes} (divide_preshape);
\path [line] (dough_ready) |- node[right=3pt]{No} (dough_flattened);
\path [line] (dough_flattened) |- node[right=3pt]{Yes} (stretch_fold);
\path [line] (dough_flattened) -- node{No} (wait_60_minutes);
\path [line] (stretch_fold) -- (wait_60_minutes);
\path [line] (wait_60_minutes) -- (check_dough);
\end{tikzpicture}

View File

@@ -22,11 +22,11 @@
\path [line] (close) -- (back_oven);
\path [line] (back_oven) -- (bake);
\path [line] (bake.west) -- node{} ++(-2, 0) -| (is_ready_check.north);
\path [line] (is_ready_check) -- node{yes} (remove_do_lid);
\path [line] (is_ready_check) -- node{no} (wait_5_minutes);
\path [line] (is_ready_check) -- node{Yes} (remove_do_lid);
\path [line] (is_ready_check) -- node{No} (wait_5_minutes);
\path [line] (wait_5_minutes.west) -- node{} ++(-1.5, 0) |- (is_ready_check.west);
\path [line] (remove_do_lid) -- (dark_enough_decision);
\path [line] (dark_enough_decision) -- node{yes} (finish_baking);
\path [line] (dark_enough_decision) -- node{no} (bake_5_more_minutes);
\path [line] (dark_enough_decision) -- node{Yes} (finish_baking);
\path [line] (dark_enough_decision) -- node{No} (bake_5_more_minutes);
\path [line] (bake_5_more_minutes.east) -- node{} ++(1, 0) -- node{} ++(0, 2.3) -| (dark_enough_decision.north);
\end{tikzpicture}

View File

@@ -8,18 +8,18 @@
\path [line] (knead) -- (wait2);
\node [decision, below of=wait2, node distance=4cm] (windowpane_test) {Window-pane?};
\path [line] (wait2) -- (windowpane_test);
\path [line] (windowpane_test.east) -- node{no} ++(1, 0) -- node{} ++(0, 5.7) -| (knead.north);
\path [line] (windowpane_test.east) -- node{No} ++(1, 0) -- node{} ++(0, 5.7) -| (knead.north);
\node [decision] at (windowpane_test -| knead) (more_water) {Bassinage for more water?};
\path [line] (windowpane_test) -- node{yes} (more_water);
\path [line] (windowpane_test) -- node{Yes} (more_water);
\node [block] at (wait1 |- more_water) (add_water) {Add water};
\path [line] (more_water) -- node{yes} (add_water);
\path [line] (more_water) -- node{Yes} (add_water);
\path [line] (add_water.north east) -- (knead.south west);
\node [decision, below of=more_water, node distance=4.5cm] (dough_sample) {Aliquot sample?};
\path [line] (more_water) -- node{no} (dough_sample);
\path [line] (more_water) -- node{No} (dough_sample);
\node [block] at (dough_sample -| wait2) (dough_ball) {Make round dough ball};
\path [line] (dough_sample) -- node{no} (dough_ball);
\path [line] (dough_sample) -- node{No} (dough_ball);
\node [block, below of=dough_sample] (extract_sample) {Extract sample};
\path [line] (dough_sample) -- node{yes} (extract_sample);
\path [line] (dough_sample) -- node{Yes} (extract_sample);
\path [line] (extract_sample.north east) -- (dough_ball.south west);
\node [success, below of=dough_ball] (begin_bulk) {Begin bulk fermentation};
\path [line] (dough_ball) -- (begin_bulk);

View File

@@ -8,10 +8,10 @@
\path [line] (init) -- (feed_new_ratio);
\path [line] (feed_new_ratio) -- node{Wait \qty{24}{\hour}} (ready_signs);
\path [line] (feed_again) -- node[anchor=east] {} ++(2.2,0) |- (feed_new_ratio);
\path [line] (ready_signs) -- node{no} (feed_again);
\path [line] (ready_signs) -- node[above=2pt]{~yes} (last_feed);
\path [line] (ready_signs) -- node{No} (feed_again);
\path [line] (ready_signs) -- node[above=2pt]{~Yes} (last_feed);
\path [line] (last_feed) -- node{after \qtyrange{6}{12}{\hour}} (bread_dough);
\draw [thick, ->] ($ (feed_again.north) +(0.7cm, 1cm)$) arc (-45:220:1cm);
\node [anchor=north, text width=5em] at ($(feed_again.north west)+(1.8cm, 2.3cm)$) {Repeat 3~times};
% TODO: find a better way to position the Repeat 3 times text and arrow. Hard-coded values are finicky and don't work well across media.
\draw [line] ($ (feed_again.north) +(0.7cm, 1cm)$) arc (-45:220:1cm);
\node [anchor=north, text width=5em] at ($(feed_again.north west)+(1.55cm, 2.2cm)$) {Repeat 3~times};
\end{tikzpicture}

View File

@@ -7,14 +7,14 @@
\node [success, right of=dent_visible_decision, node distance=4cm] (bake) {Score and bake};
\node [block] at (retard_bake_decision |- poke) (wait_retard) {Wait\\ 15~minutes};
\node [block] at (wait_retard |- bake) (retard) {Proof in fridge at \qty{4}{\degreeCelsius} (\qty{40}{\degF})};
\path [line] (init) -- node{yes} (poke);
\path [line] (init) -- node{no} (retard_bake_decision);
\path [line] (init) -- node{Yes} (poke);
\path [line] (init) -- node{No} (retard_bake_decision);
\path [line] (poke) -- (dent_visible_decision);
\path [line] (dent_visible_decision) -- node{yes} (bake);
\path [line] (dent_visible_decision.west) -- node{no} ++(-1.4, 0) -- node{} (wait_poke.south);
\path [line] (dent_visible_decision) -- node{Yes} (bake);
\path [line] (dent_visible_decision.west) -- node{No} ++(-1.4, 0) -- node{} (wait_poke.south);
\path [line] (wait_poke) -- (poke);
\path [line] (retard_bake_decision) -- node{yes} (wait_retard);
\path [line] (retard_bake_decision.east) -- node{no} ++(1, 0) |- node{} (retard.east);
\path [line] (retard_bake_decision) -- node{Yes} (wait_retard);
\path [line] (retard_bake_decision.east) -- node{No} ++(1, 0) |- node{} (retard.east);
\path [line] (wait_retard) -- (retard);
\path [line] (retard) -- (bake);
\end{tikzpicture}

View File

@@ -8,8 +8,8 @@
\node [block, right of=flour] (banneton) {Place upside down in banneton};
\node [success, right of=banneton] (proof) {Begin proofing};
\path [line] (init) -- (overfermented_decision);
\path [line] (overfermented_decision) -- node{yes} (overfermented);
\path [line] (overfermented_decision) -- node{no} (shaping_technique);
\path [line] (overfermented_decision) -- node{Yes} (overfermented);
\path [line] (overfermented_decision) -- node{No} (shaping_technique);
\path [line] (shaping_technique) -- (flour);
\path [line] (flour) -- (banneton);
\path [line] (banneton) -- (proof);

View File

@@ -4,8 +4,8 @@
\path [line] (init) -- (all_starter_used);
\node [block, right of=init, node distance=3cm] (use_dough) {Take \qty{10}{\gram} of your bread dough};
\node [block, right of=all_starter_used, node distance=3cm] (use_starter) {Take all but not more than \qty{10}{\gram} of your starter};
\path [line] (all_starter_used) -- node{yes} (use_dough);
\path [line] (all_starter_used) -- node{no} (use_starter);
\path [line] (all_starter_used) -- node{Yes} (use_dough);
\path [line] (all_starter_used) -- node{No} (use_starter);
\node [block, right of=use_dough, node distance=3cm] (feed_starter) {Feed using 1:5:5 ratio};
\path [line] (use_dough) -- (feed_starter);
\path [line] (use_starter) -- (feed_starter);
@@ -13,20 +13,20 @@
\path [line] (feed_starter) -- (bake_next_day_check);
\node [success, right of=bake_next_day_check, node distance=3.5cm]
(make_bread_dough) {Make bread dough again after \qtyrange{8}{12}{\hour}};
\path [line] (bake_next_day_check) -- node{yes} (make_bread_dough);
\path [line] (bake_next_day_check) -- node{Yes} (make_bread_dough);
\node [decision, right of=use_starter, node distance=3cm] (bake_next_week_check) {Baking in next 2 weeks?};
\node [block, right of=bake_next_week_check, node distance=3.5cm] (store_fridge) {Store starter in fridge at \qty{4}{\degreeCelsius} (\qty{40}{\degF})};
\path [line] (bake_next_week_check) -- node{yes} (store_fridge);
\path [line] (bake_next_week_check) -- node{Yes} (store_fridge);
\node [success, right of=store_fridge, node distance=3cm] (feed_after_fridge) {Feed again using 1:5:5 ratio \qtyrange{8}{12}{\hour} before making dough};
\path [line] (store_fridge) -- (feed_after_fridge);
\path [line] (bake_next_day_check) -- node{no} (bake_next_week_check);
\path [line] (bake_next_day_check) -- node{No} (bake_next_week_check);
\node [decision, below of=use_starter, node distance=3cm] (freezer_check) {Have a freezer?};
\path [line] (bake_next_week_check) -- (store_fridge);
\path [line] (bake_next_week_check) -- node{no} (freezer_check);
\path [line] (bake_next_week_check) -- node{No} (freezer_check);
\node [block, right of=freezer_check, node distance=3cm] (dry_starter) {Dry your starter};
\node [block, below of=dry_starter, node distance=3cm] (freeze_starter) {Freeze your starter};
\path [line] (freezer_check) -- node{no} (dry_starter);
\path [line] (freezer_check) -- node{yes} (freeze_starter);
\path [line] (freezer_check) -- node{No} (dry_starter);
\path [line] (freezer_check) -- node{Yes} (freeze_starter);
\node [success, right of=dry_starter, node distance=3.5cm] (reactivate_freezer) {Reactivate starter for 3 days with daily 1:5:5 feedings};
\path [line] (dry_starter) -- (reactivate_freezer);
\path [line] (freeze_starter) -- (reactivate_freezer);

View File

@@ -1,19 +1,22 @@
\begin{tikzpicture}[node distance = 3.5cm, auto]
\node [start] (init) {Mix \qty{50}{\gram} flour + \qty{50}{\gram} water, stir};
\node [block, right of=init] (wait2) {Wait\\ \qty{24}{\hour}};
\path [line] (init) -- (wait2);
\node [block, below of=wait2, node distance=3.5cm] (feed) {\qty{10}{\gram} of previous day + \qty{50}{\gram} water + \qty{50}{\gram} flour, stir};
\path [line] (wait2) -- (feed);
\node [block, below of=feed] (discard) {Discard the rest};
\path [line] (feed) -- (discard);
\node [decision, right of=feed, node distance=3.5cm] (decide) {Is good?};
\node [decision, above of=decide, node distance=3.5cm] (timeout) {Less than 10 feeds?};
\node [fail, right of=timeout, node distance=3.5cm] (discard2) {Batch failed};
\path [line] (timeout) -- node{no} (discard2);
\path [line] (timeout) -- node{yes} (wait2);
\path [line] (feed) -- (decide);
\node [success, right of=decide, node distance=3.5cm] (use) {Ready to use};
\path [line] (decide) -- node{no} (timeout);
\path [line] (wait2) -- (feed);
\path [line] (decide) -- node{yes} (use);
\node [start] (start_n) {Mix \qty{50}{\gram} flour + \qty{50}{\gram} water, stir};
\node [block, right of=start_n, node distance = 3.5cm] (wait_n) {Wait\\ \qty{24}{\hour}};
\node [decision, right of=wait_n, node distance = 3.5cm] (readycheck_n) {Ready?};
\node [block, below of=wait_n, node distance = 3.2cm] (feed_n) {Feed the mixture };
\node [decision, right of=feed_n, node distance = 3.5cm] (limitcheck_n) {>10 feeds?};
\node [fail, right of=limitcheck_n, node distance = 3.5cm] (abort_n) {Discard all. Start over};
\node [success, right of=readycheck_n, node distance = 3.5cm] (final_n) {Ready to use};
\draw [line] (start_n) -- (wait_n);
\draw [line] (wait_n) -- (readycheck_n);
\draw [line] (feed_n) -- (wait_n);
\draw [line] (readycheck_n) -- node {No} (limitcheck_n);
\draw [line] (limitcheck_n) -- node (feedok_n) {No} (feed_n) ;
\draw [line] (limitcheck_n) -- node {Yes} (abort_n);
\draw [line] (readycheck_n) -- node {Yes} (final_n);
\node [below of=feedok_n, node distance=2cm, align=left] (details2) [shape=rectangle, draw, fill=maingray]{%
\textbf{Ready}: Mixture has \emph{grown}, has \emph{bubbles}, and \emph{smells} vinegary/yoghurty. \\
\textbf{Feed the mixture}: Discard all but \qty{10}{\gram}, mix in \qty{50}{\gram} flour and \qty{50}{\gram} water.
};
\end{tikzpicture}

View File

@@ -23,16 +23,16 @@
{Prepare dough};
\path [line] (init) -- (decision_start);
\path [line] (decision_start) -- node{no} (feed_no_branch);
\path [line] (decision_start) -- node[below=2pt]{yes} (feed_yes_branch.north west);
\path [line] (decision_start) -- node{No} (feed_no_branch);
\path [line] (decision_start) -- node[below=2pt]{Yes} (feed_yes_branch.north west);
\path [line] (feed_yes_branch) -- (low_ratio);
\path [line] (feed_no_branch) -- (high_ratio);
\path [line] (high_ratio) -- node[anchor=east, above=2pt] {} ++(2.2,0) |-(size_check);
\path [line] (low_ratio) -- (size_check);
\path [line] (size_check) -- node{no} (feed_yes_branch.south east);
\path [line] (size_check) -- node{yes} (smell_check);
\path [line] (smell_check) -- node{no} (feed_yes_branch.south west);
\path [line] (smell_check) -- node{yes} (make_dough);
\path [line] (size_check) -- node{No} (feed_yes_branch.south east);
\path [line] (size_check) -- node{Yes} (smell_check);
\path [line] (smell_check) -- node{No} (feed_yes_branch.south west);
\path [line] (smell_check) -- node{Yes} (make_dough);
% braces
\draw[BC] (size_check.south) --

View File

@@ -11,14 +11,15 @@
\path [line] (init) -- (feed_new_ratio);
\path [line] (feed_again) -- (feed_new_ratio);
\path [line] (next_day) -- (ready_signs);
\path [line] (ready_signs) -- node{no} (feed_again |- last_feed) |- (feed_again.south);
\path [line] (ready_signs) -- node{yes} (last_feed);
\path [line] (ready_signs) -- node{No} (feed_again |- last_feed) -| (feed_again.south);
\path [line] (ready_signs) -- node{Yes} (last_feed);
\path [line] (last_feed) -- node{after \qtyrange{6}{12}{\hour}} (bread_dough);
\path [line] (feed_new_ratio) -- (too_dry);
\path [line] (add_water.north) -- node{} ++(0, 1.3) -| (too_dry.north);
\path [line] (too_dry) -- node{no} (next_day);
\path [line] (too_dry) -- node{yes} (add_water);
\path [line] (ready_signs) -- node{yes} (last_feed);
\draw [thick, <-] ($ (feed_again.east) +(2.1cm, 0.7cm)$) arc (-45:220:1cm);
\node [anchor=north, text width=5em] at ($(feed_again.east)+(2cm, 2cm)$) {Repeat 3~times};
\path [line] (too_dry) -- node{No} (next_day);
\path [line] (too_dry) -- node{Yes} (add_water);
\path [line] (ready_signs) -- node{Yes} (last_feed);
% TODO: find a better way to position the Repeat 3 times text and arrow. Hard-coded values are finicky and don't work well across media.
\draw [line] ($ (feed_again.east) +(0.7cm, 0.9cm)$) arc (220:-45:1cm);
\node [anchor=north, text width=5em] at ($(feed_again.east)+(1.9cm, 2cm)$) {Repeat 3~times};
\end{tikzpicture}

View File

@@ -13,8 +13,8 @@
\path [line] (mix_ingredients) -- (dough_strength);
\path [line] (dough_strength) -- (bulk);
\path [line] (bulk) -- (divide_test);
\path [line] (divide_test) -- node{yes} (shape);
\path [line] (divide_test) -- node{no} (divide);
\path [line] (divide_test) -- node{Yes} (shape);
\path [line] (divide_test) -- node{No} (divide);
\path [line] (divide) -- (preshape);
\path [line] (preshape) -- (shape);
\path [line] (shape) -- (proof);

View File

@@ -1,5 +1,5 @@
\tikzstyle{every picture}+=[font=\footnotesize\sffamily]
\usetikzlibrary{calc, shapes, arrows, decorations.pathreplacing, calligraphy,
\usetikzlibrary{calc, shapes, arrows.meta, decorations.pathreplacing, calligraphy,
positioning}
\tikzstyle{decision} = [diamond, draw=codeblack, fill=codeblack, text=white,
text width=4.5em, text badly centered, node distance=3cm, inner sep=0pt,
@@ -19,7 +19,8 @@
\tikzstyle{fail} = [rectangle, draw=codeblack, fill=redpic, text=black,
text width=5em, text centered, rounded corners, minimum height=4em,
line width=0.4mm]
\tikzstyle{line} = [draw, -latex', thick, ->,>=to]
% The arrowed connector line between nodes
\tikzstyle{line} = [draw, thick, ->, >={Latex}]
\tikzstyle{BC} = [decorate, % Brace Calligraphic
decoration={calligraphic brace, amplitude=3mm, raise=1mm},

View File

@@ -1,6 +1,9 @@
\documentclass[tikz]{standalone}
\usepackage{tikz}
\usepackage{pgfplots}
\usepackage{chemfig}
\usepackage[mode=match, reset-text-family=false]{siunitx}
\DeclareSIUnit\degF{\text{°}F}
\input{flowcharts_tikz.tex}
\input{../colors.tex}
\input{../abbreviations.tex}

View File

@@ -35,13 +35,13 @@ chapters = baking basics bread-types cover flour-types history intro mix-ins\
src_tables := $(wildcard tables/table-*.tex)
src_figures := $(wildcard figures/fig-*.tex) figures/flowcharts_tikz.tex
src_figures += $(wildcard plots/fig-*.tex)
src_figures += $(wildcard plots/fig-*.tex) abbreviations.tex colors.tex
src_recipes := $(wildcard recipes/*.tex)
src_plots := $(wildcard plots/*.table)
src_tex := $(foreach directory, $(chapters), $(wildcard $(directory)/*.tex))
src_tex += book.tex book_sans_serif.tex references.bib figures/vars.tex
src_tex += supporters.csv sourdough.sty colors.tex
src_tex += supporters.csv sourdough.sty colors.tex abbreviations.tex
src_tex += $(src_recipes)
images := $(wildcard images/*/*.jpg)
@@ -90,11 +90,10 @@ tgt_figures := $(patsubst %.tex, %.png,$(src_figures))
# TODO: check if it works on github CI
%.png: %.tex
@echo "\input{./vars.tex}" > $@.in
# \b is backspace..
@echo "\\\begin{document}" >> $@.in
@printf '%s\n' "\input{./vars.tex}" > $@.in
@printf '%s\n' "\begin{document}" >> $@.in
@cat $< >> $@.in
@echo "\\\end{document}" >> $@.in
@printf '%s\n' "\end{document}" >> $@.in
$(LATEX) $@.in
figures/export_figures.sh $@.pdf

View File

@@ -6,6 +6,7 @@
major grid style={line width=.2pt,draw=gray!30},
axis x line=middle,
axis y line=middle,
axis line style={-Latex},
width=\textwidth,
height=0.5\textwidth,
xmax=35, xmin=-0.1,

View File

@@ -6,6 +6,7 @@
major grid style={line width=.2pt,draw=gray!30},
axis x line=middle,
axis y line=middle,
axis line style={-Latex},
width=\textwidth,
height=0.5\textwidth,
xmax=35, xmin=-0.1,

View File

@@ -7,6 +7,7 @@
\qty{60}{\percent}~hydration},
axis x line=middle,
axis y line=middle,
axis line style={-Latex},
width=\textwidth,
height=0.5\textwidth,
xmax=44, xmin=-0.1,

View File

@@ -34,9 +34,7 @@
\DeclareTOCStyleEntry[numwidth=3em]{tocline}{table}
% Common abbreviations
\newcommand{\ie}{\emph{i.e.}\@ifnextchar.{\!\@gobble}{}}
\newcommand{\eg}{\emph{e.g.}\@ifnextchar.{\!\@gobble}{}}
\newcommand{\etc}{etc\@ifnextchar.{}{.\@}}
\input{abbreviations.tex}
% Consistent pH values
\newcommand{\pHvalue}[1]{pH~\SI{#1}{}}
@@ -54,8 +52,9 @@
\DeclareRobustCommand\sbseries{\fontseries{sb}\selectfont}
% Fonts for accessibility
\ifdefined\isaccessible
\setmainfont{Open Sans}[
Scale=MatchLowercase]
\usepackage[mathrm=sym]{unicode-math}
\setmathfont{Fira Math}[Scale=MatchLowercase]
\setmainfont{Open Sans}[Scale=MatchLowercase]
\else
\setmainfont{TeX Gyre Pagella}[Scale=1.0] % Or Palatino Linotype, etc.
% TODO not available on github CI

View File

@@ -126,8 +126,8 @@ class ModifyBuild
def validate_file(text)
doc = build_doc(text)
stylesheets = doc.css("link[rel='stylesheet']").map{|attr| attr["href"] }
has_all_styles = %w(book.css style.css).all? { |required_stylesheet| stylesheets.include?(required_stylesheet) }
raise InvalidWebsiteFormat.new("No style tag style.css found in the website") unless has_all_styles
has_all_styles = %w(book_sans_serif.css style.css).all? { |required_stylesheet| stylesheets.include?(required_stylesheet) }
raise InvalidWebsiteFormat.new("No style tag style.css or book_sans_serif.css found in the website") unless has_all_styles
true
end
@@ -456,7 +456,7 @@ class ModifyBuild
doc.to_html
end
# Takes a name like "static_website_html/book.html" and returns "book.html"
# Takes a name like "static_website_html/book_sans_serif.html" and returns "book_sans_serif.html"
def extract_file_from_path(filename)
result = filename.split("/")
return filename if result.length == 1
@@ -483,6 +483,7 @@ class ModifyBuild
index_text = "The Sourdough Framework goes beyond just recipes and provides a solid knowledge foundation, covering the science of sourdough, the basics of bread making, and advanced techniques for achieving the perfect sourdough bread at home."
data = {
"book.html" => index_text,
"book_sans_serif.html" => index_text,
"index.html" => index_text
}
data[filename]
@@ -526,12 +527,6 @@ class ModifyBuild
el["href"] == ""
end
# Special case for index page
#if ["index.html", "book.html"].include?(filename)
# doc.css(".menu-items .chapterToc.home-link")[0].add_class("selected")
# return doc.to_html
#end
# Special case for the flowcharts page which is added by us to the menu.
# This needs to be done for future manually added pages too
if "listoflocname.html" == filename
@@ -561,7 +556,7 @@ class ModifyBuild
def add_canonical_for_duplicates(text, filename)
# Only applies to book.html which is a duplicate for index.html. The file
# is still needed though for proper display.
canonical_pages = ["book.html", "index.html"]
canonical_pages = ["book_sans_serif.html", "index.html"]
return text unless canonical_pages.include?(filename)
doc = build_doc(text)
head = doc.css("head")[0]