Skip to content

בדיקת אתר מקיפה: נייד, תרגום מלא ל-EN/ES/FR, סליידר אמיתי, SEO ואבטחה - #3

Merged
Amlaach merged 3 commits into
TypesetOK:mainfrom
tsoolgee:fix/site-audit
Oct 6, 2026
Merged

Amlaach merged 3 commits into
TypesetOK:mainfrom
tsoolgee:fix/site-audit

Conversation

@tsoolgee

@tsoolgee tsoolgee commented Oct 6, 2026

Copy link
Copy Markdown
Member

עברתי על האתר מקצה לקצה ובדקתי אותו בפועל: Electron ודפדפן, ברוחב 1440 וברוחב 390, בעברית, באנגלית ובמצב כהה. ה-PR מתקן את מה שנמצא.

השינויים מחולקים לשלושה commits לפי נושא: עיצוב/JS, תרגום ותוכן, SEO. מומלץ לעבור עליהם אחד אחד. לפצל אותם ל-PR-ים נפרדים לא היה מעשי, כי שלושתם נוגעים באותן שורות ב-index.html.

באגים משמעותיים

  • הנייד היה שבור:
    • מתחת ל-600px כל .btn קיבל width:100%, גם כפתור ה-GitHub שבכותרת;
    • בגלל זה כפתור התפריט נדחק אל מחוץ למסך, והעמוד היה ברוחב 474px בטלפון של 390px;
    • עכשיו אין גלישה אופקית.
  • אנגלית, ספרדית וצרפתית היו שבורות:
    • 161 מתוך 257 קטעי טקסט נשארו בעברית;
    • בנוסף, reset.css קבע direction: rtl על <html>, וזה גבר על המאפיין dir. כל העמוד נשאר מימין לשמאל, עם נקודות בתחילת משפט ותפריט וטבלה הפוכים.
  • סליידר לפני/אחרי: השכבה "אחרי" שינתה רוחב, אז הטקסט שלה נשבר לעמודה צרה, ובנייד זה היה פס לא קריא. מתחת ל-768px שתי השכבות בכלל נערמו זו מעל זו. עכשיו שתי הגרסאות פרוסות ברוחב מלא באותו תא grid, ו"אחרי" נחשפת עם clip-path. ההשוואה אמיתית, והגובה מותאם לתוכן.
  • הכפתור הצף להורדה: לא היה מעוצב בכלל, כי המחלקות שלו לא קיימות ב-CSS. בנוסף הוא הופיע עוד לפני שהמשתמש הגיע לכרטיס ההורדה.
  • קישורי הורדה: כשה-API של GitHub לא זמין (60 בקשות לשעה ל-IP), הקישורים נפלו ל-v0.6.0. בכפתור הצף, בתפריט הנייד וב-CTA זה היה קבוע תמיד. קישורי Linux ו-macOS הובילו ל-latest, שלא כוללת קבצים כאלה.
  • תוכן שמסתתר בגלילה: אם JS לא רץ, התוכן נשאר בלתי נראה.
  • ערכת נושא:
    • משתמשים במצב כהה ראו הבזק בהיר בכל טעינה;
    • גישה ל-localStorage בלי try/catch שברה את כל סקריפט הנגישות במצבי פרטיות.

אבטחה

  • נוספו Content-Security-Policy ו-Referrer-Policy בתגיות meta. GitHub Pages לא מאפשר לקבוע headers.
  • ב-CSP:
    • הסקריפטים מוגבלים ל-'self';
    • חיבורים מותרים רק ל-api.github.com;
    • גופנים מותרים רק מ-Google Fonts.
    • אין בעמוד סקריפטים או handlers מוטמעים, אז שום דבר לא נשבר.
  • כתובות הורדה שמגיעות מה-API מתקבלות רק אם הן מתחילות ב-github.com/TypesetOK/typesetok/releases/download/.
  • HSTS ו-X-Content-Type-Options נקבעים כבר על ידי github.io, ואי אפשר להגדיר אותם מתוך האתר.

עיצוב ו-UX

  • עברית בגופן מונו: JetBrains Mono לא כולל עברית, אז כל התוויות הקטנות (38 רכיבים) נפלו ל-Courier New. עכשיו העברית נופלת ל-Heebo, והריווח הרחב הוסר מתוויות בעברית.
  • מדדי ה-hero: בגופן אחיד, עם ספרות טבלאיות.
  • רשת התכונות: הכותרת אמרה "שבעת עמודי התווך" ויש 6 כרטיסים, והכרטיס השישי נשאר לבד בשורה. עכשיו הכותרת אומרת "ששת", והכרטיס האחרון מקבל שורה מלאה. התגיות בכרטיסים כבר לא נמתחות לכל הרוחב.
  • טבלאות בנייד: גוללות לצד, ועמודת התווית קבועה. קודם כל עמודה נדחסה למילה אחת בשורה.
  • ציטוטים: בוטל נטוי מזויף על עברית (ל-Frank Ruhl Libre אין גרסת italic). הציטוט באנגלית היה עטוף בגרשיים עבריים, ולכן הוצג מימין לשמאל.
  • פוטר: שני הקישורים שפותחים חלונות היו בגובה 42px ולא מיושרים. הלוגו בפוטר היה מעוות.
  • ניגודיות: תוקנה ניגודיות נמוכה בתגי PASSED ו"וורד" במצב בהיר.
  • סדר התפריט: עכשיו תואם לסדר הסעיפים בעמוד.
  • חלונות קופצים: הפוקוס חוזר לכפתור שפתח אותם, ו-Tab נשאר בתוך החלון.

ביצועים

  • לוגו: בכותרת ובפוטר logo-96.webp במשקל 1.7KB, במקום JPEG של 44KB ברוחב 1376px.
  • גופנים: ירדו מבקשת Google Fonts משקלים שלא בשימוש (Frank Ruhl 500, ‏JetBrains 500).
  • קוד מת: הוסר קוד ה-pipeline. אין סעיף כזה בעמוד.

תוכן ועובדות

  • מספר הבדיקות: עודכן מ-58/58 ל-174/174. הרצתי את main ב-1837e84, ו-clippy נקי.
  • מבחן העומס: "1,000 עמודים" מחזיר בפועל 1,001 עמודים ו-49,001 שורות ב-3.1 שניות.
  • הוסרו: $O(1)$ שהופיע כטקסט גולמי, וגודל הקובץ "113 מ״ב" שהתיישן (היום 104MB).
  • גרסה: הטקסט הקבוע עודכן ל-v0.9.8, וה-JS ממשיך לעדכן אותו מה-API.

SEO

  • robots.txt וה-sitemap הפנו ל-typesetok.org, דומיין שלא קיים. ה-sitemap גם כלל anchors לסעיפים שלא קיימים. עכשיו יש כתובת אחת לכל שפה, עם hreflang.
  • ?lang= עובד עכשיו. ה-hreflang כבר הבטיח את הכתובות האלה, אבל הקוד לא קרא את הפרמטר. ה-canonical וה-og:locale מתעדכנים לפי השפה.
  • og:image: כתובת מלאה, כי סורקים לא טוענים כתובת יחסית, עם המידות האמיתיות (1376×768).
  • Twitter: התגיות כתובות עכשיו כ-name=.
  • <title>: קוצר.
  • נתונים מובנים: הוסר FAQPage שלא מופיע בעמוד, וזו הפרה של ההנחיות של Google. הוסרו גם breadcrumb בן פריט אחד ו-softwareVersion ישן.
  • Manifest: start_url היה /, כלומר השורש של github.io. גם האייקונים היו JPEG לא ריבועי שהוצהר כ-512×512.
  • 404.html: ב-Pages הוא נטען לכל כתובת חסרה, כולל כתובות עמוקות, ושם הנתיבים היחסיים נשברו. נוספו <base href="/website/"> ו-noindex.

מה לא שיניתי, ולמה

  • "קוד פתוח": האתר אומר "100% קוד פתוח", אבל הרישיון הוא TOK-NCCL, שאינו מתיר שימוש מסחרי. זו לא הגדרת open source של OSI. כדאי לשקול ניסוח כמו "קוד מקור פתוח לעיון". זו החלטה שלך, ולא נגעתי.
  • "קולות מהשטח": הציטוטים מיוחסים לפורומים בלי קישור למקור. אם הם מנוסחים ולא מצוטטים, כדאי להבהיר את זה.
  • נגישות: תפריט הנגישות לא לוכד פוקוס כמו החלונות הקופצים. לא שיניתי את המבנה שלו.

בדיקות

  • python scripts/validate.py: עובר.
  • תחביר JS: כל הקבצים עוברים.
  • JSON-LD, manifest ו-sitemap: נפרשים תקין.
  • Electron ודפדפן:
    • בלי שגיאות קונסול ובלי הפרות CSP;
    • בלי גלישה אופקית ברוחב 390;
    • הסליידר עובד בעברית ובאנגלית;
    • הכפתור הצף מופיע רק אחרי שגוללים מעבר לכרטיס ההורדה;
    • ה-API מעדכן את הגרסה והקישורים;
    • כל הגופנים נטענים.

…layout and JS bugs

Layout and design
- Mobile header: every .btn became width:100% under 600px, pushing the menu toggle
  off-screen and the page 474px wide on a 390px phone. Header buttons keep their size;
  the GitHub button moves to the drawer under 980px; header height comes from one token.
- Before/after slider: the "after" layer was resized, so its text reflowed into a strip
  (unreadable on phones, and on <768px both layers were stacked). Both versions now share
  one grid cell at full width and the "after" layer is revealed with clip-path; height
  follows the content (no empty half). Labels no longer overlap the heading or each other.
- Hebrew in "mono" labels fell back to Courier New (JetBrains Mono has no Hebrew):
  Heebo is now the Hebrew fallback; RTL section labels drop the wide tracking.
- Features grid: the sixth card sat alone on its row; tags stretched across the card.
- Tables on phones scroll sideways with the row label pinned instead of one word per line.
- Floating download widget was unstyled (its classes did not exist in the CSS) and showed
  before the user reached the download card; it now appears only after scrolling past it.
- Footer modal links were 42px tall (global button min-height) and misaligned.
- Quotes: no fake italic on Hebrew; mixed-direction quotes and the footer line keep their
  own direction. Low-contrast PASSED / "Word" badges fixed for light mode.
- Removed the dead "pipeline" section CSS/JS (no such markup on the page).

Behaviour
- Scroll-reveal content is hidden only after main.js runs (was invisible without JS).
- Theme: applied before first paint (theme-init.js, no light flash for dark users);
  localStorage access guarded.
- Release links: one cached API call; Windows assets from the latest release, Linux/macOS
  CLI from the newest release that ships them; version also updated on the floating button.
- Modals return focus to the opener and keep Tab inside; drawer label resets on close.
- New square logo/icon sizes (logo-96.webp 1.7 KB instead of the 44 KB JPEG in the header).
…ate facts

Languages
- English/Spanish/French showed a half-Hebrew page (161 of 257 visible text nodes were
  untranslated) and stayed laid out right-to-left because reset.css forced
  `direction: rtl` on <html>, overriding the dir attribute. Every UI string is now
  translated (257 keys per language; Hebrew demo content stays Hebrew on purpose),
  attributes via data-i18n-attr, and <title>/description follow the language.
- ?lang=en|es|fr is honoured (the hreflang links already promised these URLs);
  switching updates the URL, canonical and og:locale; storage access is guarded.

Content
- Download links no longer point at v0.6.0 assets: the static fallback is
  releases/latest (always valid) and JS upgrades it to the current assets.
- Test figures were stale (58/58): now 174/174 Rust tests (main @ 1837e84, clippy clean)
  and the 1,000-page stress test reports 1,001 pages / 49,001 lines in 3.1 s.
- "Seven pillars" heading over six cards; literal "$O(1)$"; stale "113 MB" size;
  an English quote wrapped in Hebrew gershayim so it rendered RTL.
- Navigation order now matches the page order.

SEO / head
- Absolute og:image (relative URLs are not fetched by crawlers) with real dimensions;
  twitter:* as name= meta; shorter Hebrew <title>.
- Removed FAQPage structured data that is not visible on the page (against Google's
  guidelines), a one-item breadcrumb, a stale softwareVersion and a meta
  google-site-verification that held the HTML-file token (file verification remains).
- Hebrew hreflang points at the canonical root; CSP and referrer policy as meta tags
  (GitHub Pages cannot set response headers).
- 404.html: <base href="/website/"> so nested missing URLs still load styles, noindex,
  square logo, trimmed font request.
…to /website/

- robots.txt and sitemap.xml referenced https://typesetok.org, which does not resolve;
  the sitemap also listed #fragments (ignored by crawlers) for sections that do not
  exist. Now one URL per language with hreflang alternates on typesetok.github.io/website.
- Manifest start_url "/" left the project site; icons were a non-square JPEG declared
  as 512x512. Now ./ scope with proper 192/512 PNG icons.
- validate.py skips site-absolute hrefs (404.html's <base>), which are server paths.
@Amlaach
Amlaach merged commit 2cc1b7c into TypesetOK:main Oct 6, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants