Skip to content

Commit 889e484

Browse files
committed
chore: fix lint issues
1 parent 243fd8d commit 889e484

File tree

6 files changed

+26
-16
lines changed

6 files changed

+26
-16
lines changed

packages/mos-gateway/src/mosStatus/diff.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import type { MosDeviceStatusesConfig } from '@sofie-automation/shared-lib/dist/
33
import {
44
IngestPartNotifyItemReady,
55
IngestPartPlaybackStatus,
6+
IngestRundownActiveStatus,
67
type IngestPartStatus,
78
type IngestRundownStatus,
89
} from '@sofie-automation/shared-lib/dist/ingest/rundownStatus'
@@ -153,8 +154,8 @@ function buildMosStatus(
153154
isReady: boolean | null | undefined,
154155
active: IngestRundownStatus['active'] | undefined
155156
): IMOSObjectStatus | null {
156-
if (active === 'inactive') return MOS_STATUS_UNKNOWN
157-
if (active === 'rehearsal' && !config.sendInRehearsal) return null
157+
if (active === IngestRundownActiveStatus.INACTIVE) return MOS_STATUS_UNKNOWN
158+
if (active === IngestRundownActiveStatus.REHEARSAL && !config.sendInRehearsal) return null
158159

159160
switch (playbackStatus) {
160161
case IngestPartPlaybackStatus.PLAY:

packages/mos-gateway/src/mosStatus/handler.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import {
1818
} from '@sofie-automation/server-core-integration'
1919
import type { IngestRundownStatus } from '@sofie-automation/shared-lib/dist/ingest/rundownStatus'
2020
import type { RundownId } from '@sofie-automation/shared-lib/dist/core/model/Ids'
21-
import type winston = require('winston')
21+
import * as winston from 'winston'
2222
import { Queue } from '@sofie-automation/server-core-integration/dist/lib/queue'
2323
import { diffStatuses } from './diff.js'
2424

packages/shared-lib/src/pubsub/peripheralDevice.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ export interface PeripheralDevicePubSubTypes {
125125

126126
[PeripheralDevicePubSub.ingestDeviceRundownStatus]: (
127127
deviceId: PeripheralDeviceId,
128-
token?: string | undefined
128+
token?: string
129129
) => PeripheralDevicePubSubCollectionsNames.ingestRundownStatus
130130
}
131131

packages/webui/src/client/lib/viewPort.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ export function maintainFocusOnPartInstance(
3232
partInstanceId: PartInstanceId,
3333
timeWindow: number,
3434
forceScroll?: boolean,
35-
noAnimation?: boolean,
35+
noAnimation?: boolean
3636
): void {
3737
focusState.startTime = Date.now()
3838

@@ -43,7 +43,7 @@ export function maintainFocusOnPartInstance(
4343

4444
try {
4545
await scrollToPartInstance(partInstanceId, forceScroll, noAnimation)
46-
} catch (error) {
46+
} catch (_error) {
4747
// Handle error if needed
4848
} finally {
4949
focusState.isScrolling = false
@@ -95,7 +95,7 @@ function quitFocusOnPart() {
9595
export async function scrollToPartInstance(
9696
partInstanceId: PartInstanceId,
9797
forceScroll?: boolean,
98-
noAnimation?: boolean,
98+
noAnimation?: boolean
9999
): Promise<boolean> {
100100
quitFocusOnPart()
101101
const partInstance = UIPartInstances.findOne(partInstanceId)
@@ -109,7 +109,7 @@ export async function scrollToPart(
109109
partId: PartId,
110110
forceScroll?: boolean,
111111
noAnimation?: boolean,
112-
zoomInToFit?: boolean,
112+
zoomInToFit?: boolean
113113
): Promise<boolean> {
114114
quitFocusOnPart()
115115
const part = UIParts.findOne(partId)
@@ -132,7 +132,7 @@ let HEADER_HEIGHT: number | undefined = undefined
132132
export function getHeaderHeight(): number {
133133
if (HEADER_HEIGHT === undefined) {
134134
const root = document.querySelector(
135-
'#render-target > .container-fluid-custom > .rundown-view > .rundown-header',
135+
'#render-target > .container-fluid-custom > .rundown-view > .rundown-header'
136136
)
137137
if (!root) {
138138
return FALLBACK_HEADER_HEIGHT
@@ -149,7 +149,7 @@ let currentScrollingElement: HTMLElement | undefined
149149
export async function scrollToSegment(
150150
elementToScrollToOrSegmentId: HTMLElement | SegmentId,
151151
forceScroll?: boolean,
152-
noAnimation?: boolean,
152+
noAnimation?: boolean
153153
): Promise<boolean> {
154154
const elementToScrollTo: HTMLElement | null = getElementToScrollTo(elementToScrollToOrSegmentId, false)
155155
const historyTarget: HTMLElement | null = getElementToScrollTo(elementToScrollToOrSegmentId, true)
@@ -163,18 +163,18 @@ export async function scrollToSegment(
163163
historyTarget,
164164
forceScroll || !regionInViewport(historyTarget, elementToScrollTo),
165165
noAnimation,
166-
false,
166+
false
167167
)
168168
}
169169

170170
function getElementToScrollTo(
171171
elementToScrollToOrSegmentId: HTMLElement | SegmentId,
172-
showHistory: boolean,
172+
showHistory: boolean
173173
): HTMLElement | null {
174174
if (isProtectedString(elementToScrollToOrSegmentId)) {
175175
// Get the current segment element
176176
let targetElement = document.querySelector<HTMLElement>(
177-
`#${SEGMENT_TIMELINE_ELEMENT_ID}${elementToScrollToOrSegmentId}`,
177+
`#${SEGMENT_TIMELINE_ELEMENT_ID}${elementToScrollToOrSegmentId}`
178178
)
179179
if (showHistory && Settings.followOnAirSegmentsHistory && targetElement) {
180180
let i = Settings.followOnAirSegmentsHistory
@@ -210,7 +210,7 @@ async function innerScrollToSegment(
210210
elementToScrollTo: HTMLElement,
211211
forceScroll?: boolean,
212212
noAnimation?: boolean,
213-
secondStage?: boolean,
213+
secondStage?: boolean
214214
): Promise<boolean> {
215215
if (!secondStage) {
216216
if (pendingFirstStageTimeout) {
@@ -264,7 +264,7 @@ async function innerScrollToSegment(
264264
(error) => {
265265
if (!error.toString().match(/another scroll/)) logger.error(error)
266266
return false
267-
},
267+
}
268268
)
269269
}
270270

packages/webui/src/client/ui/App.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ import { catchError, firstIfArray, isRunningInPWA } from '../lib/lib.js'
4040
import { protectString } from '@sofie-automation/shared-lib/dist/lib/protectedString'
4141
import { useUserPermissions, UserPermissionsContext } from './UserPermissions.js'
4242
import { relativeToSiteRootUrl, ROOT_URL_PATH_PREFIX } from '../url.js'
43-
import Container from 'react-bootstrap/Container'
4443

4544
const NullComponent = () => null
4645

packages/yarn.lock

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22809,6 +22809,16 @@ asn1@evs-broadcast/node-asn1:
2280922809
languageName: node
2281022810
linkType: hard
2281122811

22812+
"path-case@npm:^3.0.4":
22813+
version: 3.0.4
22814+
resolution: "path-case@npm:3.0.4"
22815+
dependencies:
22816+
dot-case: "npm:^3.0.4"
22817+
tslib: "npm:^2.0.3"
22818+
checksum: 10/61de0526222629f65038a66f63330dd22d5b54014ded6636283e1d15364da38b3cf29e4433aa3f9d8b0dba407ae2b059c23b0104a34ee789944b1bc1c5c7e06d
22819+
languageName: node
22820+
linkType: hard
22821+
2281222822
"path-data-parser@npm:0.1.0, path-data-parser@npm:^0.1.0":
2281322823
version: 0.1.0
2281422824
resolution: "path-data-parser@npm:0.1.0"

0 commit comments

Comments
 (0)