From 3d269df1a093ddb2444ba8f1cd2547fde486df5d Mon Sep 17 00:00:00 2001 From: Bob Develop Date: Wed, 22 Apr 2026 06:37:46 -0400 Subject: [PATCH] feat(signature): multi-font typed signature (11 fonts) --- Dockerfile | 17 ++++- .../submission_form/signature_step.vue | 64 ++++++++++++++++--- lib/submitters/generate_font_image.rb | 23 ++++++- 3 files changed, 93 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index f8c4398f..9607801a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,6 +8,16 @@ RUN apk --no-cache add wget && \ wget https://github.com/impallari/DancingScript/raw/master/fonts/DancingScript-Regular.otf && \ wget https://raw.githubusercontent.com/impallari/DancingScript/master/OFL.txt && \ wget https://raw.githubusercontent.com/notofonts/noto-fonts/refs/heads/main/LICENSE && \ + wget https://github.com/google/fonts/raw/main/ofl/greatvibes/GreatVibes-Regular.ttf && \ + wget https://github.com/google/fonts/raw/main/ofl/pacifico/Pacifico-Regular.ttf && \ + wget -O Caveat-Regular.ttf "https://github.com/google/fonts/raw/main/ofl/caveat/Caveat%5Bwght%5D.ttf" && \ + wget https://github.com/google/fonts/raw/main/apache/homemadeapple/HomemadeApple-Regular.ttf && \ + wget https://github.com/google/fonts/raw/main/ofl/mrssaintdelafield/MrsSaintDelafield-Regular.ttf && \ + wget https://github.com/google/fonts/raw/main/ofl/shadowsintolight/ShadowsIntoLight-Regular.ttf && \ + wget https://github.com/google/fonts/raw/main/ofl/alexbrush/AlexBrush-Regular.ttf && \ + wget https://github.com/google/fonts/raw/main/ofl/kalam/Kalam-Regular.ttf && \ + wget https://github.com/google/fonts/raw/main/ofl/sacramento/Sacramento-Regular.ttf && \ + wget https://github.com/google/fonts/raw/main/ofl/herrvonmuellerhoff/HerrVonMuellerhoff-Regular.ttf && \ wget -O /model.onnx "https://github.com/docusealco/fields-detection/releases/download/2.0.0/model_704_int8.onnx" && \ wget -O pdfium-linux.tgz "https://github.com/bblanchon/pdfium-binaries/releases/latest/download/pdfium-linux-musl-$(uname -m | sed 's/x86_64/x64/;s/aarch64/arm64/').tgz" && \ mkdir -p /pdfium-linux && \ @@ -79,13 +89,16 @@ COPY --chown=docuseal:docuseal ./tmp ./tmp COPY --chown=docuseal:docuseal LICENSE LICENSE_ADDITIONAL_TERMS README.md Rakefile config.ru .version ./ COPY --chown=docuseal:docuseal .version ./public/version -COPY --chown=docuseal:docuseal --from=download /fonts/GoNotoKurrent-Regular.ttf /fonts/GoNotoKurrent-Bold.ttf /fonts/DancingScript-Regular.otf /fonts/OFL.txt /fonts/LICENSE /fonts/ +COPY --chown=docuseal:docuseal --from=download /fonts/ /fonts/ COPY --from=download /pdfium-linux/lib/libpdfium.so /usr/lib/libpdfium.so COPY --from=download /pdfium-linux/licenses/pdfium.txt /usr/lib/libpdfium-LICENSE.txt COPY --chown=docuseal:docuseal --from=download /model.onnx /app/tmp/model.onnx COPY --chown=docuseal:docuseal --from=webpack /app/public/packs ./public/packs -RUN mkdir -p /app/public/fonts && ln -s /fonts/DancingScript-Regular.otf /app/public/fonts/ && \ +RUN mkdir -p /app/public/fonts && \ + for f in DancingScript-Regular.otf GreatVibes-Regular.ttf Pacifico-Regular.ttf Caveat-Regular.ttf HomemadeApple-Regular.ttf MrsSaintDelafield-Regular.ttf ShadowsIntoLight-Regular.ttf AlexBrush-Regular.ttf Kalam-Regular.ttf Sacramento-Regular.ttf HerrVonMuellerhoff-Regular.ttf; do \ + ln -s /fonts/$f /app/public/fonts/; \ + done && \ mkdir -p /usr/share/fonts/noto && ln -s /fonts/GoNotoKurrent-Regular.ttf /usr/share/fonts/noto/ && ln -s /fonts/GoNotoKurrent-Bold.ttf /usr/share/fonts/noto/ && fc-cache -f && \ bundle exec bootsnap precompile -j 1 --gemfile app/ lib/ && \ chown -R docuseal:docuseal /app/tmp/cache diff --git a/app/javascript/submission_form/signature_step.vue b/app/javascript/submission_form/signature_step.vue index c1f19be9..b0886baa 100644 --- a/app/javascript/submission_form/signature_step.vue +++ b/app/javascript/submission_form/signature_step.vue @@ -246,6 +246,27 @@ type="text" @input="updateWrittenSignature" > + +