[251115] fix: DetailPanel
🕐 커밋 시간: 2025. 11. 15. 23:03:44 📊 변경 통계: • 총 파일: 1개 • 추가: +20줄 📝 수정된 파일: ~ com.twin.app.shoptime/src/components/VideoPlayer/MediaPlayer.v2.jsx 🔧 함수 변경 내용: 📄 com.twin.app.shoptime/src/components/VideoPlayer/MediaPlayer.v2.jsx (javascript): 🔄 Modified: getDurFmt() 🔧 주요 변경 내용: • UI 컴포넌트 아키텍처 개선
This commit is contained in:
@@ -28,6 +28,7 @@ import Spotlight from '@enact/spotlight';
|
||||
import { SpotlightContainerDecorator } from '@enact/spotlight/SpotlightContainerDecorator';
|
||||
import { Spottable } from '@enact/spotlight/Spottable';
|
||||
import Touchable from '@enact/ui/Touchable';
|
||||
import { is } from '@enact/core/keymap';
|
||||
|
||||
import Loader from '../Loader/Loader';
|
||||
import { MediaSlider, Times, secondsToTime } from '../MediaPlayer';
|
||||
@@ -595,6 +596,24 @@ const MediaPlayerV2 = forwardRef((props, ref) => {
|
||||
const shouldDisableControls = disabled || isModal;
|
||||
const shouldDisableSpotlight = spotlightDisabled || isModal;
|
||||
|
||||
const handleModalArrowDown = useCallback(
|
||||
(ev) => {
|
||||
if (!isModal) {
|
||||
return;
|
||||
}
|
||||
if (
|
||||
is('down', ev.keyCode) ||
|
||||
is('up', ev.keyCode) ||
|
||||
is('left', ev.keyCode) ||
|
||||
is('right', ev.keyCode)
|
||||
) {
|
||||
ev.preventDefault();
|
||||
ev.stopPropagation();
|
||||
}
|
||||
},
|
||||
[isModal]
|
||||
);
|
||||
|
||||
return (
|
||||
<RootContainer
|
||||
className={classNames(
|
||||
@@ -608,6 +627,7 @@ const MediaPlayerV2 = forwardRef((props, ref) => {
|
||||
spotlightDisabled={shouldDisableSpotlight}
|
||||
spotlightId={spotlightId}
|
||||
style={containerStyle}
|
||||
onKeyDownCapture={handleModalArrowDown}
|
||||
>
|
||||
{/* Video Element */}
|
||||
{ActualVideoComponent === Media ? (
|
||||
|
||||
Reference in New Issue
Block a user