TBody, SpotlightIds 추가

This commit is contained in:
hyunwoo93.cha
2024-01-25 06:57:37 +09:00
parent 92cd4d0dac
commit 465afb64e5
4 changed files with 36 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
import classNames from "classnames";
import React from "react";
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator";
import css from "./TBody.module.less";
import { SpotlightIds } from "../../utils/SpotlightIds";
const Container = SpotlightContainerDecorator(
{ enterTo: "last-focused", preserveId: true },
"div"
);
export default function TBody({
children,
className,
spotlightId = SpotlightIds.TBODY,
...rest
}) {
return (
<Container
spotlightId={spotlightId}
{...rest}
className={classNames(css.tBody, className)}
>
{children}
</Container>
);
}

View File

@@ -0,0 +1,6 @@
{
"main": "TBody.jsx",
"styles": [
"TBody.module.less"
]
}

View File

@@ -0,0 +1,3 @@
export const SpotlightIds = {
TBODY: "tbody",
};