From 98a507b0309b936f76c9427c7179d5f3655397f8 Mon Sep 17 00:00:00 2001 From: michaelschal <35957947-michaelschal@users.noreply.replit.com> Date: Mon, 17 Nov 2025 15:09:53 +0000 Subject: [PATCH] Adjust minimum font size for adaptive text across the application Update the minimum font size from 24px to 12px in both client-side preview modal and server-side image processing to improve text adaptability. Replit-Commit-Author: Agent Replit-Commit-Session-Id: ae4037a0-2a6f-4530-9bac-79b543286bda Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Event-Id: 26883c03-a1a8-4dda-9695-f2319b42174c Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/397bca8c-984f-43ff-841a-10897aeb8140/ae4037a0-2a6f-4530-9bac-79b543286bda/5aomXd9 --- client/src/components/preview-modal.tsx | 2 +- server/services/imageProcessor.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/client/src/components/preview-modal.tsx b/client/src/components/preview-modal.tsx index ffd6278..0b5ed15 100644 --- a/client/src/components/preview-modal.tsx +++ b/client/src/components/preview-modal.tsx @@ -252,7 +252,7 @@ export function PreviewModal({ }; const calculateAdaptiveFontSize = (text: string, containerWidth: number, containerHeight: number): { fontSize: number; lines: string[]; isTruncated: boolean } => { - const MIN_FONT_SIZE = 24; + const MIN_FONT_SIZE = 12; const MAX_FONT_SIZE = 72; const LINE_HEIGHT_MULTIPLIER = 1.2; diff --git a/server/services/imageProcessor.ts b/server/services/imageProcessor.ts index 87e0de4..05301cc 100644 --- a/server/services/imageProcessor.ts +++ b/server/services/imageProcessor.ts @@ -103,7 +103,7 @@ export class ImageProcessor { const STORY_WIDTH = 1080; const STORY_HEIGHT = 1920; const TEXT_BOX_HEIGHT_RATIO = 0.25; - const MIN_FONT_SIZE = 24; + const MIN_FONT_SIZE = 12; const MAX_FONT_SIZE = 72; const PADDING = 40; const LINE_HEIGHT_MULTIPLIER = 1.3;