@php
$regions = \App\Models\News::REGIONS;
$secondaryCategories = \App\Models\News::secondaryCategoryLabels();
$monitoredPrefill = $monitoredPrefill ?? null;
$monitoredArticleId = old('monitored_article_id', $monitoredPrefill?->id);
$rewritePresets = [
[
'key' => 'balanced',
'label' => 'Balanced newsroom tone',
'prompt' => 'Rewrite the following article in a balanced newsroom tone. Preserve factual accuracy, improve clarity, and ensure the structure flows logically with engaging yet objective language.',
],
[
'key' => 'concise',
'label' => 'Concise summary',
'prompt' => 'Rewrite the article into a concise summary that keeps essential facts, uses short paragraphs, and removes repetitive information while remaining accurate.',
],
[
'key' => 'engaging',
'label' => 'Engaging feature style',
'prompt' => 'Rewrite the article in an engaging feature style. Use active voice, compelling transitions, and vivid but factual language suitable for a digital audience.',
],
];
@endphp
@if($errors->has('monitored_article_id'))
@php $monitoredArticleId = null; @endphp
The linked monitored article is no longer available. Please re-import it from the monitor.
@endif
@if($monitoredPrefill && filled($monitoredPrefill->content))
View scraped body preview
{!! nl2br(e($monitoredPrefill->content)) !!}
@endif
@if($monitoredArticleId)
@endif
@push('styles')
@endpush
Adjust the prompt to fine-tune the rewrite before sending it to ChatGPT.
Choose how many text blocks to split the rewritten article into.
@php
$oldBlocks = old('content_blocks');
$initialBlocks = [];
if (is_array($oldBlocks)) {
$initialBlocks = array_values($oldBlocks);
} else {
$initialBlocks = $news->renderable_content_blocks ?? [];
}
if ($initialBlocks === [] && old('body')) {
$initialBlocks[] = ['type' => 'text', 'body' => old('body')];
}
if ($initialBlocks === [] && old('image_path')) {
$initialBlocks[] = ['type' => 'image', 'image_path' => old('image_path')];
}
@endphp
Add and reorder text, image, or social embed blocks. Captions are optional for images.
@if($errors->has('content_blocks.*') || $errors->has('body'))
Please resolve the highlighted content block issues.
@endif
@php $currentStatus = old('status', $news->status ?? \App\Models\News::STATUS_DRAFT); @endphp