The OG renderer resolves glyphs through the font cmap alone: satori emits an
SVG <font> and plain <text>, so no shaping engine and no bidi implementation
run. Persian titles were painted in logical order with every letter in its
isolated shape, which made them look scattered and mirrored.
Shaping is now derived from the shipped Vazirmatn font rather than guessed
from the Unicode block, and the presentation forms are joined per position.
Lines are broken here as well, in logical order, and each line is reordered
through the bidi algorithm before it is handed over, so a wrapped title keeps
its reading order instead of being filled from the wrong end.
- PostStats: optimistic like toggle (localStorage per post) and one view per
browser session (sessionStorage) against the new public endpoints
- CommentSection: lists approved reader comments, submits new ones into
moderation with a pending-confirmation state
- Both wired into the single-post page sidebar and after the prev/next cards;
new en/fa dictionary labels
- Single post: sticky table of contents from h2 headings (anchored ids),
estimated reading time badge, working share buttons (X/LinkedIn/Telegram/
copy link), and same-language previous/next navigation cards
- Home: featured hero gains tag chips, reading time and a read CTA; new
newsletter subscribe band linking to the site's contact address
- Both en/fa dictionaries updated for the new UI labels
- Every blog list fetch (homepage, new/popular/search, categories, posts, tags) sends the active locale as lang to the API, so only that language's content renders
- Post, category and tag detail pages redirect to the mirrored twin slug when the URL language does not match the selected locale, so shared links always open in the viewer's language
- Fix home card links that used category.name as the URL slug instead of category.slug
- Add slugForLocale/isFaSlug helpers in lib/functions/utils
The mobile menu overlays were only 20% opaque and sat below the fixed
header, so after scrolling, page text bled through and made menu items
unreadable. Make the backdrop a dark blurred veil and raise the drawer
above the header on both the website and blog menus.
Replace the mailto-only contact form (which contained a placeholder
caveat) with a form that POSTs to the new /api/contact endpoint, keeps
client-side validation, and shows success/error states.
Add an admin messages inbox at /admin/contact-messages with read/unread
toggling and delete, plus a nav link and a dashboard card.
Swap the lorem ipsum testimonials for real client feedback in both
dictionaries.
Typing a URL into the featured-image box meant the panel could only ever
reference images uploaded by hand, so every content change needed an SFTP
round trip. Image fields now get a uploader that posts straight to the
media endpoint, while the plain URL box stays: plenty of images still live
on another host, and pasting a URL should keep working.
The upload is a Server Action rather than a client fetch because the admin
token lives in an httpOnly cookie. adminUpload cannot reuse adminFetch —
that helper always JSON-stringifies the body and pins a JSON Content-Type,
and a hand-written Content-Type on multipart drops the boundary, which
leaves $_FILES empty and turns every upload into a 422.
The value reaches the existing saveResourceAction through the named text
input, which the uploader writes to; the file input itself is left unnamed
so a 4 MB image is never re-sent inside the save request. Removing an
image only clears the field, because the old URL may already be in use by
another row — deleteMediaAction is the separate, deliberate path.
Server Actions default to a 1 MB body, so next.config.mjs now allows 8 MB.
That is the Next-side half only: PHP's upload_max_filesize and post_max_size
have to be at least as large on the API host or it discards the file before
validation ever runs.
Also adds /feed.xml. The blog had a sitemap but no feed, so it was not
readable in any reader.