css fixes
authorPhiTux <redacted>
Sun, 12 Oct 2025 08:50:47 +0000 (10:50 +0200)
committerPhiTux <redacted>
Sun, 12 Oct 2025 08:50:47 +0000 (10:50 +0200)
build.sh
frontend/src/lib/ImageViewer.svelte
frontend/src/lib/Sidenav.svelte
frontend/src/routes/(authed)/+layout.svelte
frontend/src/routes/(authed)/write/+page.svelte

index 8b7b44d92f1a48550d31a5c537475517cda07008..3a5b941e8af6b5b4de43d16fed89d8eabec2d2fe 100755 (executable)
--- a/build.sh
+++ b/build.sh
@@ -8,17 +8,18 @@ set -euo pipefail
 # - Docker installed
 #
 # Usage:
-#   TOLGEE_API_KEY=... ./build.sh [IMAGE_TAG]
+#   TOLGEE_API_KEY=... ./build.sh IMAGE_TAG [--push]
 #
 # Example:
 #   export TOLGEE_API_KEY=xxxxx
-#   ./build.sh phitux/dailytxt:2.x.x-testing.1
+#   ./build.sh phitux/dailytxt:2.x.x-testing.1 [--push]
 
 if [[ $# -lt 1 ]]; then
-       echo "Usage: ./build.sh <IMAGE_TAG>"
+       echo "Usage: ./build.sh <IMAGE_TAG> [--push]"
        exit 1
 fi
 IMAGE_TAG="$1"
+PUSH_FLAG="${2:-}"
 
 if [[ -z "${TOLGEE_API_KEY:-}" ]]; then
        echo "Error: TOLGEE_API_KEY is not set."
@@ -30,10 +31,29 @@ fi
 echo "[1/3] Writing IMAGE_TAG (=version) into backend/version ..."
 echo "$IMAGE_TAG" > ./backend/version
 
-echo "[2/3] Pulling translations from Tolgee into frontend/src/i18n ..."
+echo -e "\n[2/3] Pulling translations from Tolgee into frontend/src/i18n ..."
 tolgee pull --path ./frontend/src/i18n --api-key $TOLGEE_API_KEY
 
-echo "[3/3] Building Docker image: $IMAGE_TAG"
-docker build -t phitux/dailytxt:$IMAGE_TAG .
+echo -e "\n[3/3] Building Docker image: $IMAGE_TAG"
+if [[ -z "$PUSH_FLAG" ]]; then
+       # Default: local docker build (no push)
+       docker build -t phitux/dailytxt:$IMAGE_TAG .
+else
+       case "$PUSH_FLAG" in
+               --push)
+                       echo "Pushing image to Docker registry..."
+                       # Build for multiple platforms and push to registry
+                       #docker buildx build \
+                       #       --platform linux/amd64,linux/arm64 \
+                       #       -t phitux/dailytxt:$IMAGE_TAG \
+                       #       --push .
+                       ;;
+               *)
+                       echo "Unknown second argument: '$PUSH_FLAG'"
+                       echo "Usage: ./build.sh <IMAGE_TAG> [--push]"
+                       exit 1
+                       ;;
+       esac
+fi
 
-echo "Done. Image built: $IMAGE_TAG"
+echo -e "\nDone. Image built: $IMAGE_TAG"
index 49fd5834b34649463285e71b56bc446fff4f0ad7..0fffd919fe8e3c1ad5fde3f1750a2297ddb7f9be 100644 (file)
 
        .image-container:hover .image {
                transform: scale(1.1);
-               box-shadow: 0 0 12px 3px rgba(0, 0, 0, 0.2);
        }
 
        .image {
index a965a5b7071d75d0fab624ee8b6b65f06815dfc0..816c2c07f752842453662edc93755915632c3fce 100644 (file)
                display: flex;
                flex-direction: column;
                border-radius: 10px;
+               min-height: 0;
        }
 
        .list-group {
index 7095a84fd44c1b6234b973a2bc2521b7f61fddc0..cb509a0edde51778c28fa8d3f190d4def1dba390 100644 (file)
        $effect(() => {
                if (window.matchMedia('(display-mode: standalone)').matches) {
                        showInstallationHelp = false;
-                       console.log("We're installed");
+                       console.log('DailyTxT is installed');
                } else {
                        showInstallationHelp = true;
-                       console.log("We're not installed");
+                       console.log('DailyTxT is not installed');
                }
        });
 </script>
index c665cf4e19b73145b472a0cfec72bdff8c0d294d..9d3f1ecfdeb167b6f008c07f7a11f795169d0634 100644 (file)
 
        const imageExtensions = ['jpeg', 'jpg', 'gif', 'png', 'webp', 'bmp'];
 
+       let autoLoadImages = $derived(
+               ($settings.setAutoloadImagesPerDevice && $autoLoadImagesThisDevice) ||
+                       (!$settings.setAutoloadImagesPerDevice && $settings.autoloadImagesByDefault)
+       );
+
        $effect(() => {
                if (filesOfDay && autoLoadImages !== undefined) {
                        // add all files to images if correct extension
                                ) {
                                        images = [...images, file];
 
-                                       console.log(autoLoadImages);
                                        if (autoLoadImages) {
                                                loadImage(file);
                                        }
                }
        });
 
-       let autoLoadImages = $derived(
-               ($settings.setAutoloadImagesPerDevice && $autoLoadImagesThisDevice) ||
-                       (!$settings.setAutoloadImagesPerDevice && $settings.autoloadImagesByDefault)
-       );
-
        function loadImage(file) {
                images.map((image) => {
                        if (image.uuid_filename === file.uuid_filename) {
git clone https://git.99rst.org/PROJECT