header rekated fixes

This commit is contained in:
IGNY8 VPS (Salman)
2025-12-27 05:33:05 +00:00
parent fd6e7eb2dd
commit 726d945bda
15 changed files with 414 additions and 232 deletions

View File

@@ -4,7 +4,7 @@
*/
import { useState, useEffect, useMemo, useCallback } from 'react';
import { useNavigate, Link } from 'react-router-dom';
import { useNavigate } from 'react-router-dom';
import TablePageTemplate from '../../templates/TablePageTemplate';
import {
fetchContent,
@@ -348,20 +348,8 @@ export default function Review() {
<>
<PageHeader
title="Review"
description="Review and approve content before publishing"
badge={{ icon: <ClipboardDocumentCheckIcon />, color: 'emerald' }}
breadcrumb="Writer"
actions={
<Link
to="/writer/published"
className="inline-flex items-center gap-2 px-3 py-1.5 text-sm font-medium text-white bg-brand-500 hover:bg-brand-600 rounded-lg transition-colors"
>
View Published
<svg className="w-4 h-4" fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M9 5l7 7-7 7" />
</svg>
</Link>
}
parent="Writer"
/>
<TablePageTemplate
columns={pageConfig.columns}
@@ -372,6 +360,15 @@ export default function Review() {
filterValues={{
search: searchTerm,
}}
nextAction={selectedIds.length > 0 ? {
label: 'Publish Selected',
message: `${selectedIds.length} selected`,
onClick: () => handleBulkAction('publish', selectedIds),
} : content.filter(c => c.status === 'review').length > 0 ? {
label: 'View Published',
href: '/writer/published',
message: `${content.filter(c => c.status === 'review').length} in review`,
} : undefined}
onFilterChange={(key, value) => {
const stringValue = value === null || value === undefined ? '' : String(value);
if (key === 'search') {