Skip to content

Commit b026acb

Browse files
committed
Merge branch 'develop' into css-more-cleanup
2 parents 1209b20 + cc5289b commit b026acb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+695
-435
lines changed

src/components/configuration/partials/ThemesActionsCell.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ const ThemesActionsCell = ({
4949
onClick={() => showThemeDetails()}
5050
className={"action-cell-button"}
5151
editAccessRole={"ROLE_UI_THEMES_EDIT"}
52-
tooltipText={"CONFIGURATION.THEMES.TABLE.TOOLTIP.DETAILS"}
52+
// tooltipText={"CONFIGURATION.THEMES.TABLE.TOOLTIP.DETAILS"} // Disabled due to performance concerns
5353
>
5454
<LuFileText />
5555
</ButtonLikeAnchor>
@@ -67,7 +67,7 @@ const ThemesActionsCell = ({
6767
{/* delete themes */}
6868
<ActionCellDelete
6969
editAccessRole={"ROLE_UI_THEMES_DELETE"}
70-
tooltipText={"CONFIGURATION.THEMES.TABLE.TOOLTIP.DELETE"}
70+
// tooltipText={"CONFIGURATION.THEMES.TABLE.TOOLTIP.DELETE"} // Disabled due to performance concerns
7171
resourceId={row.id}
7272
resourceName={row.name}
7373
resourceType={"THEME"}

src/components/events/Events.tsx

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ import {
2626
setShowActions,
2727
} from "../../slices/eventSlice";
2828
import EventDetailsModal from "./partials/modals/EventDetailsModal";
29-
import { showModal } from "../../selectors/eventDetailsSelectors";
3029
import { eventsLinks } from "./partials/EventsNavigation";
3130
import { Modal, ModalHandle } from "../shared/modals/Modal";
3231
import TableActionDropdown from "../shared/TableActionDropdown";
3332
import TablePage from "../shared/TablePage";
33+
import SeriesDetailsModal from "./partials/modals/SeriesDetailsModal";
3434

3535
/**
3636
* This component renders the table view of events
@@ -39,8 +39,6 @@ const Events = () => {
3939
const { t } = useTranslation();
4040
const dispatch = useAppDispatch();
4141

42-
const displayEventDetailsModal = useAppSelector(state => showModal(state));
43-
4442
const newEventModalRef = useRef<ModalHandle>(null);
4543
const startTaskModalRef = useRef<ModalHandle>(null);
4644
const deleteModalRef = useRef<ModalHandle>(null);
@@ -156,9 +154,8 @@ const Events = () => {
156154
</Modal>
157155

158156
{/* Include table modal */}
159-
{displayEventDetailsModal &&
160-
<EventDetailsModal />
161-
}
157+
<EventDetailsModal />
158+
<SeriesDetailsModal />
162159
</>
163160
);
164161
};

src/components/events/Series.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,15 @@ import { Modal, ModalHandle } from "../shared/modals/Modal";
2020
import { availableHotkeys } from "../../configs/hotkeysConfig";
2121
import TableActionDropdown from "../shared/TableActionDropdown";
2222
import TablePage from "../shared/TablePage";
23+
import SeriesDetailsModal from "./partials/modals/SeriesDetailsModal";
2324

2425
/**
2526
* This component renders the table view of series
2627
*/
2728
const Series = () => {
2829
const { t } = useTranslation();
2930
const dispatch = useAppDispatch();
31+
3032
const newSeriesModalRef = useRef<ModalHandle>(null);
3133
const deleteModalRef = useRef<ModalHandle>(null);
3234

@@ -90,6 +92,9 @@ const Series = () => {
9092
>
9193
<DeleteSeriesModal close={() => deleteModalRef.current?.close?.()} />
9294
</Modal>
95+
96+
{/* Include table modal */}
97+
<SeriesDetailsModal />
9398
</>
9499
);
95100
};

src/components/events/partials/EventActionCell.tsx

Lines changed: 21 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,22 @@ import { useTranslation } from "react-i18next";
33
import EmbeddingCodeModal from "./modals/EmbeddingCodeModal";
44
import { getUserInformation } from "../../../selectors/userInfoSelectors";
55
import { hasAccess } from "../../../utils/utils";
6-
import SeriesDetailsModal from "./modals/SeriesDetailsModal";
76
import { EventDetailsPage } from "./modals/EventDetails";
87
import { useAppDispatch, useAppSelector } from "../../../store";
98
import {
109
fetchSeriesDetailsAcls,
1110
fetchSeriesDetailsMetadata,
1211
fetchSeriesDetailsTheme,
1312
fetchSeriesDetailsThemeNames,
13+
openModal as openSeriesModal,
1414
} from "../../../slices/seriesDetailsSlice";
1515
import { Event, deleteEvent } from "../../../slices/eventSlice";
16-
import { Tooltip } from "../../shared/Tooltip";
1716
import { openModal } from "../../../slices/eventDetailsSlice";
1817
import { ActionCellDelete } from "../../shared/ActionCellDelete";
1918
import { Modal, ModalHandle } from "../../shared/modals/Modal";
2019
import ButtonLikeAnchor from "../../shared/ButtonLikeAnchor";
2120
import { LuFileSymlink, LuFileText, LuFolderOpen, LuLink, LuMessageCircle, LuScissors, LuTriangleAlert } from "react-icons/lu";
21+
import { SeriesDetailsPage } from "./modals/SeriesDetails";
2222

2323
/**
2424
* This component renders the action cells of events in the table view
@@ -31,7 +31,6 @@ const EventActionCell = ({
3131
const { t } = useTranslation();
3232
const dispatch = useAppDispatch();
3333

34-
const seriesDetailsModalRef = useRef<ModalHandle>(null);
3534
const embeddingCodeModalRef = useRef<ModalHandle>(null);
3635

3736
const user = useAppSelector(state => getUserInformation(state));
@@ -45,7 +44,7 @@ const EventActionCell = ({
4544
};
4645

4746
const showSeriesDetailsModal = () => {
48-
seriesDetailsModalRef.current?.open();
47+
dispatch(openSeriesModal(SeriesDetailsPage.Metadata, row.series ? row.series : null));
4948
};
5049

5150
const onClickSeriesDetails = async () => {
@@ -79,20 +78,12 @@ const EventActionCell = ({
7978

8079
return (
8180
<>
82-
{!!row.series && (
83-
<SeriesDetailsModal
84-
seriesId={row.series.id}
85-
seriesTitle={row.series.title}
86-
modalRef={seriesDetailsModalRef}
87-
/>
88-
)}
89-
9081
{/* Open event details */}
9182
<ButtonLikeAnchor
9283
onClick={onClickEventDetails}
9384
className={"action-cell-button"}
9485
editAccessRole={"ROLE_UI_EVENTS_DETAILS_VIEW"}
95-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.DETAILS"}
86+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.DETAILS"} // Disabled due to performance concerns
9687
>
9788
<LuFileText />
9889
</ButtonLikeAnchor>
@@ -103,7 +94,7 @@ const EventActionCell = ({
10394
onClick={onClickSeriesDetails}
10495
className={"action-cell-button more-series"}
10596
editAccessRole={"ROLE_UI_SERIES_DETAILS_VIEW"}
106-
tooltipText={"EVENTS.SERIES.TABLE.TOOLTIP.DETAILS"}
97+
// tooltipText={"EVENTS.SERIES.TABLE.TOOLTIP.DETAILS"} // Disabled due to performance concerns
10798
>
10899
<LuFileSymlink />
109100
</ButtonLikeAnchor>
@@ -112,7 +103,7 @@ const EventActionCell = ({
112103
{/* Delete an event */}
113104
<ActionCellDelete
114105
editAccessRole={"ROLE_UI_EVENTS_DELETE"}
115-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.DELETE"}
106+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.DELETE"} // Disabled due to performance concerns
116107
resourceId={row.id}
117108
resourceName={row.title}
118109
resourceType={"EVENT"}
@@ -121,13 +112,13 @@ const EventActionCell = ({
121112

122113
{/* If the event has an preview then the editor can be opened and status if it needs to be cut is shown */}
123114
{!!row.has_preview && hasAccess("ROLE_UI_EVENTS_EDITOR_VIEW", user) && (
124-
<Tooltip
125-
title={
126-
row.needs_cutting
127-
? t("EVENTS.EVENTS.TABLE.TOOLTIP.EDITOR_NEEDS_CUTTING")
128-
: t("EVENTS.EVENTS.TABLE.TOOLTIP.EDITOR")
129-
}
130-
>
115+
// <Tooltip // Disabled due to performance concerns
116+
// title={
117+
// row.needs_cutting
118+
// ? t("EVENTS.EVENTS.TABLE.TOOLTIP.EDITOR_NEEDS_CUTTING")
119+
// : t("EVENTS.EVENTS.TABLE.TOOLTIP.EDITOR")
120+
// }
121+
// >
131122
<a
132123
href={`/editor-ui/index.html?id=${row.id}`}
133124
className="action-cell-button cut"
@@ -136,15 +127,15 @@ const EventActionCell = ({
136127
<LuScissors />
137128
{row.needs_cutting && <span id="badge" className="badge" />}
138129
</a>
139-
</Tooltip>
130+
// </Tooltip>
140131
)}
141132

142133
{/* If the event has comments and no open comments then the comment tab of event details can be opened directly */}
143134
{row.has_comments && !row.has_open_comments && (
144135
<ButtonLikeAnchor
145136
onClick={() => onClickComments()}
146-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.COMMENTS"}
147-
className={"action-cell-button"}
137+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.COMMENTS"} // Disabled due to performance concerns
138+
className={"action-cell-button comments"}
148139
>
149140
<LuMessageCircle className="blue"/>
150141
</ButtonLikeAnchor>
@@ -154,8 +145,8 @@ const EventActionCell = ({
154145
{row.has_comments && row.has_open_comments && (
155146
<ButtonLikeAnchor
156147
onClick={() => onClickComments()}
157-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.COMMENTS"}
158-
className={"action-cell-button"}
148+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.COMMENTS"} // Disabled due to performance concerns
149+
className={"action-cell-button comments-open"}
159150
>
160151
<LuMessageCircle className="blue"/>
161152
</ButtonLikeAnchor>
@@ -167,7 +158,7 @@ const EventActionCell = ({
167158
<ButtonLikeAnchor
168159
onClick={() => onClickWorkflow()}
169160
editAccessRole={"ROLE_UI_EVENTS_DETAILS_WORKFLOWS_EDIT"}
170-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.PAUSED_WORKFLOW"}
161+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.PAUSED_WORKFLOW"} // Disabled due to performance concerns
171162
className={"action-cell-button"}
172163
>
173164
<LuTriangleAlert className="darkgrey"/>
@@ -178,7 +169,7 @@ const EventActionCell = ({
178169
<ButtonLikeAnchor
179170
onClick={() => onClickAssets()}
180171
editAccessRole={"ROLE_UI_EVENTS_DETAILS_ASSETS_VIEW"}
181-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.ASSETS"}
172+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.ASSETS"} // Disabled due to performance concerns
182173
className={"action-cell-button"}
183174
>
184175
<LuFolderOpen className="darkgrey"/>
@@ -188,7 +179,7 @@ const EventActionCell = ({
188179
<ButtonLikeAnchor
189180
onClick={() => showEmbeddingCodeModal()}
190181
editAccessRole={"ROLE_UI_EVENTS_EMBEDDING_CODE_VIEW"}
191-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.EMBEDDING_CODE"}
182+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.EMBEDDING_CODE"} // Disabled due to performance concerns
192183
className={"action-cell-button"}
193184
>
194185
<LuLink className="darkgrey"/>

src/components/events/partials/EventsDateCell.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const EventsDateCell = ({
1818
filterName="startDate"
1919
fetchResource={fetchEvents}
2020
loadResourceIntoTable={loadEventsIntoTable}
21-
tooltipText="EVENTS.EVENTS.TABLE.TOOLTIP.START"
21+
// tooltipText="EVENTS.EVENTS.TABLE.TOOLTIP.START" // Disabled due to performance concerns
2222
/>
2323
);
2424
};

src/components/events/partials/EventsLocationCell.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const EventsLocationCell = ({
3333
<ButtonLikeAnchor
3434
onClick={() => addFilter(row.location)}
3535
className={"crosslink"}
36-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.LOCATION"}
36+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.LOCATION"} // Disabled due to performance concerns
3737
>
3838
{row.location}
3939
</ButtonLikeAnchor>

src/components/events/partials/EventsPresentersCell.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const EventsPresentersCell = ({
1818
filterName="presentersBibliographic"
1919
fetchResource={fetchEvents}
2020
loadResourceIntoTable={loadEventsIntoTable}
21-
tooltipText="EVENTS.EVENTS.TABLE.TOOLTIP.PRESENTER"
21+
// tooltipText="EVENTS.EVENTS.TABLE.TOOLTIP.PRESENTER" // Disabled due to performance concerns
2222
/>
2323
);
2424
};

src/components/events/partials/EventsSeriesCell.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ const EventsSeriesCell = ({
3737
: console.error("Tried to sort by a series, but the series did not exist.")
3838
}
3939
className={"crosslink"}
40-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.SERIES"}
40+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.SERIES"} // Disabled due to performance concerns
4141
>
4242
{row.series.title}
4343
</ButtonLikeAnchor>

src/components/events/partials/EventsStatusCell.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const EventsStatusCell = ({
4444
<ButtonLikeAnchor
4545
onClick={() => openStatusModal()}
4646
className={"crosslink"}
47-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.STATUS"}
47+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.STATUS"} // Disabled due to performance concerns
4848
>
4949
{t(row.displayable_status as ParseKeys)}
5050
</ButtonLikeAnchor>

src/components/events/partials/EventsTechnicalDateCell.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ const EventsTechnicalDateCell = ({
3636
<ButtonLikeAnchor
3737
onClick={() => addFilter(row.date)}
3838
className={"crosslink"}
39-
tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.START"}
39+
// tooltipText={"EVENTS.EVENTS.TABLE.TOOLTIP.START"} // Disabled due to performance concerns
4040
>
4141
{t("dateFormats.date.short", { date: renderValidDate(row.technical_start) })}
4242
</ButtonLikeAnchor>

0 commit comments

Comments
 (0)