refactor: small fixes and style tweaks

fix: prevent reflow on editing images

fix: schedule overview

fix: report on all events

refactor: over-under time colours

fix: prevent edit on delete
This commit is contained in:
Carlos Valente
2025-07-14 11:45:41 +02:00
committed by Carlos Valente
parent 1e1f547ce1
commit ad2ef3b53f
22 changed files with 135 additions and 141 deletions
@@ -8,6 +8,7 @@ import NullableTimeInput from '../../../common/components/input/time-input/Nulla
import AppLink from '../../../common/components/link/app-link/AppLink';
import { useEntryActions } from '../../../common/hooks/useEntryAction';
import useCustomFields from '../../../common/hooks-query/useCustomFields';
import { getOffsetState } from '../../../common/utils/offset';
import { enDash, timerPlaceholder } from '../../../common/utils/styleUtils';
import TextLikeInput from '../../../views/cuesheet/cuesheet-table/cuesheet-table-elements/TextLikeInput';
@@ -54,7 +55,7 @@ export default function BlockEditor({ block }: BlockEditorProps) {
const isEditor = window.location.pathname.includes('editor');
const planOffset = typeof block.targetDuration !== 'number' ? null : block.duration - block.targetDuration;
const planOffsetLabel = planOffset !== null && planOffset > 0 ? 'behind' : 'ahead';
const planOffsetLabel = planOffset !== null ? getOffsetState(planOffset * -1) : null;
return (
<div className={style.content}>
@@ -1,6 +1,6 @@
.imageContainer {
width: 100%;
height: 100%;
width: 75px;
height: 75px;
background-color: $gray-1250;
display: grid;
place-content: center;
@@ -6,11 +6,11 @@
justify-self: end;
&.over {
color: $ontime-delay-text;
color: $playback-over;
}
&.under {
color: $playback-ahead;
color: $playback-under;
}
&.due {
@@ -59,7 +59,8 @@ export default function RundownMilestone({ colour, cue, entryId, hasCursor, titl
updateEntry({ id: entryId, [field]: value });
};
const handleDelete = () => {
const handleDelete = (event: MouseEvent) => {
event.stopPropagation();
deleteEntry([entryId]);
};