Enable Gitea JS checks

This commit is contained in:
2026-08-12 14:32:28 -07:00
parent a1579eebad
commit ba3dea885d
2 changed files with 41 additions and 9 deletions

View File

@@ -0,0 +1,32 @@
name: Check JS
on:
pull_request:
push:
branches:
- railbird-v6
jobs:
typescript:
name: Check TS (tsc)
runs-on: nixos-x86_64-linux
steps:
- uses: actions/checkout@v4
- name: Install node_modules
uses: ./.github/actions/setup-node
- name: Check TypeScript
run: yarn tsc
- name: Test web HLS
run: yarn test:web
lint:
name: Lint JS (eslint, prettier)
runs-on: nixos-x86_64-linux
steps:
- uses: actions/checkout@v4
- name: Install node_modules
uses: ./.github/actions/setup-node
- name: Run ESLint
run: yarn lint
- name: Verify auto-fix produces no changes
run: yarn lint --fix && git diff --exit-code HEAD

View File

@@ -475,7 +475,7 @@ const Video = forwardRef<VideoRef, ReactVideoProps>(
(e: NativeSyntheticEvent<OnSeekCompleteData>) => { (e: NativeSyntheticEvent<OnSeekCompleteData>) => {
onSeekComplete?.(e.nativeEvent); onSeekComplete?.(e.nativeEvent);
}, },
[onSeekComplete] [onSeekComplete],
); );
const onVideoPlaybackStateChanged = useCallback( const onVideoPlaybackStateChanged = useCallback(
@@ -733,10 +733,10 @@ const Video = forwardRef<VideoRef, ReactVideoProps>(
} }
// poster style // poster style
const baseStyle: StyleProp<ImageStyle> = { const baseStyle: StyleProp<ImageStyle> = [
...StyleSheet.absoluteFill, StyleSheet.absoluteFill,
resizeMode: _posterResizeMode, {resizeMode: _posterResizeMode},
}; ];
let posterStyle: StyleProp<ImageStyle> = baseStyle; let posterStyle: StyleProp<ImageStyle> = baseStyle;
@@ -786,10 +786,10 @@ const Video = forwardRef<VideoRef, ReactVideoProps>(
]); ]);
const _style: StyleProp<ViewStyle> = useMemo( const _style: StyleProp<ViewStyle> = useMemo(
() => ({ () => [
...StyleSheet.absoluteFill, StyleSheet.absoluteFill,
...(showPoster ? {display: 'none'} : {}), showPoster ? {display: 'none'} : undefined,
}), ],
[showPoster], [showPoster],
); );