[HomeBanner] modify focus policy on spotlight
Detail Notes : 1. HomeTodayDeal: modify the div that is the wrapper into a Container 2. HomeBannerTemplate1: modify the div that wraps the banner to ContainerBasic
This commit is contained in:
@@ -29,6 +29,7 @@ const Container = SpotlightContainerDecorator(
|
||||
},
|
||||
"div"
|
||||
);
|
||||
const ContainerBasic = SpotlightContainerDecorator({}, "div");
|
||||
|
||||
export default function HomeBannerTemplate1() {
|
||||
const dispatch = useDispatch();
|
||||
@@ -73,7 +74,7 @@ export default function HomeBannerTemplate1() {
|
||||
<Container className={css.container} spotlightId={"top"}>
|
||||
<div className={css.homeTemplateBox}>
|
||||
<div className={css.mainBox}>
|
||||
<div className={css.dualBox}>
|
||||
<ContainerBasic className={css.dualBox}>
|
||||
{/* 배너1 */}
|
||||
<div className={css.smallBox}>
|
||||
{bannerInfos &&
|
||||
@@ -131,7 +132,7 @@ export default function HomeBannerTemplate1() {
|
||||
);
|
||||
})}
|
||||
</div>
|
||||
</div>
|
||||
</ContainerBasic>
|
||||
|
||||
{/* 배너3 */}
|
||||
<div className={css.imgBox}>
|
||||
|
||||
@@ -10,6 +10,12 @@ import Spotlight from '@enact/spotlight';
|
||||
import Spottable from '@enact/spotlight/Spottable';
|
||||
|
||||
import css from './HomeTodayDeal.module.less';
|
||||
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator";
|
||||
|
||||
const Container = SpotlightContainerDecorator(
|
||||
{ enterTo: "default-element" },
|
||||
"div"
|
||||
);
|
||||
|
||||
const SpottableComponent = Spottable("div");
|
||||
|
||||
@@ -101,7 +107,7 @@ export default function HomeTodayDeal({
|
||||
}, [startFocus]);
|
||||
|
||||
return (
|
||||
<div
|
||||
<Container
|
||||
className={classNames(
|
||||
css.rollingWrap,
|
||||
isHorizontal && css.isHorizontalWrap
|
||||
@@ -141,6 +147,6 @@ export default function HomeTodayDeal({
|
||||
onClick={handleNext}
|
||||
></SpottableComponent>
|
||||
)}
|
||||
</div>
|
||||
</Container>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user