1b3a8b493e
deploy / deploy (push) Failing after 1m21s
Full rewrite of the portfolio site from Next.js 14 to .NET 10: - ASP.NET Core 10 Razor Pages, no Node.js dependency - EF Core 10 + SQLite (same schema as before — data survives upgrade) - Cookie authentication (same single-password model) - Resend contact form via HttpClient - Bilingual FA/EN via locale cookie + BasePageModel - All UI ported to Razor Pages with Tailwind CDN + custom CSS - Vanilla JS: particles, typewriter, cursor, animations, portfolio modal - Dockerfile: SDK 10.0-alpine → aspnet 10.0-alpine (no npm/Node needed) - CI/CD: dropped NPM_TOKEN, ADMIN_SESSION_SECRET — pure dotnet publish Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
36 lines
1.6 KiB
Plaintext
36 lines
1.6 KiB
Plaintext
@page "/Admin/Posts/{slug}"
|
|
@model SoroushAsadi.Pages.Admin.Posts.PostEditModel
|
|
@{
|
|
Layout = "_AdminLayout";
|
|
ViewData["Title"] = "Edit post: " + Model.Slug;
|
|
}
|
|
|
|
<div class="mb-6 flex items-center gap-4">
|
|
<a href="/Admin/Posts" class="text-slate-400 hover:text-white transition-colors text-sm">← Posts</a>
|
|
<h1 class="font-display text-xl font-bold text-white">@Model.Slug</h1>
|
|
<a href="/blog/@Model.Slug" target="_blank" class="text-xs text-slate-400 hover:text-white transition-colors">View ↗</a>
|
|
</div>
|
|
|
|
@if (!string.IsNullOrEmpty(Model.Message))
|
|
{
|
|
<div class="mb-4 rounded-lg border border-emerald/30 bg-emerald/10 px-4 py-3 text-sm text-emerald">@Model.Message</div>
|
|
}
|
|
|
|
<form method="post" class="space-y-4">
|
|
<div>
|
|
<label class="label-mono mb-2 block">Body (Markdown)</label>
|
|
<p class="text-xs text-slate-500 mb-2">Supports: ## headings, **bold**, `code`, - list items, paragraphs</p>
|
|
<textarea name="body" rows="30"
|
|
class="w-full rounded-xl border border-white/10 bg-white/[.03] px-4 py-3 font-mono text-xs text-slate-200 outline-none focus:border-electric/60 transition-colors resize-y"
|
|
spellcheck="false">@Model.CurrentBody</textarea>
|
|
</div>
|
|
<div class="flex gap-3">
|
|
<button type="submit" class="btn-primary">Save</button>
|
|
@if (Model.HasOverride)
|
|
{
|
|
<button type="submit" name="reset" value="1" class="rounded-lg border border-red-500/30 bg-red-500/10 px-4 py-2 text-sm text-red-400 hover:bg-red-500/20 transition-colors">Reset to default</button>
|
|
}
|
|
<a href="/Admin/Posts" class="btn-ghost">Cancel</a>
|
|
</div>
|
|
</form>
|