= [
+ {
+ title: 'Дата',
+ dataIndex: 'date',
+ key: 'date',
+ width: '20%',
+ render: (value, record) => (
+
+ {getDateFormatted(record)}
+
+ ),
+ },
+ {
+ title: 'Назва',
+ dataIndex: 'title',
+ key: 'title',
+ width: '25%',
+ render: (value, record) => (
+
+ ),
+ },
+ {
+ title: 'Опис',
+ dataIndex: 'description',
+ key: 'description',
+ width: '35%',
+ render: (value, record) => (
+
+ ),
+ },
+ {
+ title: 'Контекст',
+ dataIndex: 'historicalContexts',
+ key: 'historicalContexts',
+ width: '15%',
+ render: (contexts, record) => (
+
+ {contexts?.map((ctx: HistoricalContext) => ctx.title).join(', ') || '-'}
+
+ ),
+ },
+ {
+ title: 'Дії',
+ dataIndex: 'action',
+ key: 'action',
+ width: '5%',
+ render: (value, timeline, index) => (
+
+ {
+ setChronologyToEdit(timeline);
+ setModalEditOpened(true);
+ }}
+ />
+ {
+ modalStore.setConfirmationModal(
+ 'confirmation',
+ () => {
+ timelineItemStore.deleteTimelineItem(timeline.id)
+ .then(() => {
+ fetchTimelines();
+ })
+ .catch((e: Error) => {
+ console.error('Delete error:', e);
+ });
+ modalStore.setConfirmationModal('confirmation');
+ },
+ 'Ви впевнені, що хочете видалити цю подію?',
+ );
+ }}
+ />
+
+ ),
+ },
+ ];
+
+ return (
+
+
+
+
+
Хронологія
+
+
+
+
+
fetchTimelines()}
+ />
+ fetchTimelines()}
+ />
+
+ );
+};
+
+export default observer(ChronologyPage);
diff --git a/src/features/AdminPage/ChronologyPage/ChronologyPage.styles.scss b/src/features/AdminPage/ChronologyPage/ChronologyPage.styles.scss
new file mode 100644
index 0000000..1a0627f
--- /dev/null
+++ b/src/features/AdminPage/ChronologyPage/ChronologyPage.styles.scss
@@ -0,0 +1,68 @@
+.chronology-page-container {
+ display: flex;
+ flex-direction: column;
+ width: 100%;
+ min-height: 100vh;
+ background-color: #f5f5f5;
+
+ .chronology-page-content {
+ padding: 24px;
+ padding-top: 100px;
+ margin: 0 auto;
+ max-width: 1400px;
+ width: 100%;
+
+ .chronology-page-header {
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ margin-bottom: 24px;
+
+ h1 {
+ font-size: 24px;
+ font-weight: 600;
+ margin: 0;
+ }
+
+ .add-button {
+ height: 40px;
+ padding: 0 20px;
+ }
+ }
+
+ .chronology-table {
+ background: white;
+ border-radius: 8px;
+ box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
+
+ .chronology-table-item-title,
+ .chronology-table-item-description {
+ p {
+ margin: 0;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ display: -webkit-box;
+ -webkit-line-clamp: 2;
+ line-clamp: 2;
+ -webkit-box-orient: vertical;
+ }
+ }
+
+ .chronology-page-actions {
+ display: flex;
+ gap: 12px;
+
+ .actionButton {
+ cursor: pointer;
+ font-size: 18px;
+ color: #1890ff;
+ transition: color 0.3s;
+
+ &:hover {
+ color: #40a9ff;
+ }
+ }
+ }
+ }
+ }
+}