Use "Page" labels instead of "Post" when editing pages

- Edit: placeholder "Page title..." vs "Post title..."
- Settings: slug placeholder, featured checkbox, custom template
  all say "page" when is_page is true

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
giles
2026-02-21 22:13:50 +00:00
parent 1832c53980
commit 9a1a4996bc
2 changed files with 6 additions and 5 deletions

View File

@@ -77,7 +77,7 @@
type="text"
name="title"
value="{{ ghost_post.title if ghost_post else '' }}"
placeholder="Post title..."
placeholder="{{ 'Page title...' if post and post.is_page else 'Post title...' }}"
class="w-full text-[36px] font-bold bg-transparent border-none outline-none
placeholder:text-stone-300 mb-[8px] leading-tight"
>

View File

@@ -1,5 +1,6 @@
{# ── Post Settings Form ── #}
{# ── Post/Page Settings Form ── #}
{% set gp = ghost_post or {} %}
{% set _is_page = post.is_page if post else False %}
{% macro field_label(text, field_for=None) %}
<label {% if field_for %}for="{{ field_for }}"{% endif %}
@@ -68,7 +69,7 @@
{% call section('General', open=True) %}
<div>
{{ field_label('Slug', 'settings-slug') }}
{{ text_input('slug', gp.slug or '', 'post-slug') }}
{{ text_input('slug', gp.slug or '', 'page-slug' if _is_page else 'post-slug') }}
</div>
<div>
{{ field_label('Published at', 'settings-published_at') }}
@@ -83,7 +84,7 @@
>
</div>
<div>
{{ checkbox_input('featured', gp.featured, 'Featured post') }}
{{ checkbox_input('featured', gp.featured, 'Featured page' if _is_page else 'Featured post') }}
</div>
<div>
{{ field_label('Visibility', 'settings-visibility') }}
@@ -176,7 +177,7 @@
{% call section('Advanced') %}
<div>
{{ field_label('Custom template', 'settings-custom_template') }}
{{ text_input('custom_template', gp.custom_template or '', 'custom-post.hbs') }}
{{ text_input('custom_template', gp.custom_template or '', 'custom-page.hbs' if _is_page else 'custom-post.hbs') }}
</div>
{% endcall %}