Files
stash/ui/v2.5/src/components/Scenes/SceneDetails/SceneGroupPanel.tsx
2024-07-03 14:17:02 +10:00

28 lines
648 B
TypeScript

import React from "react";
import * as GQL from "src/core/generated-graphql";
import { GroupCard } from "src/components/Groups/GroupCard";
interface ISceneGroupPanelProps {
scene: GQL.SceneDataFragment;
}
export const SceneGroupPanel: React.FC<ISceneGroupPanelProps> = (
props: ISceneGroupPanelProps
) => {
const cards = props.scene.groups.map((sceneGroup) => (
<GroupCard
key={sceneGroup.group.id}
group={sceneGroup.group}
sceneIndex={sceneGroup.scene_index ?? undefined}
/>
));
return (
<>
<div className="row justify-content-center">{cards}</div>
</>
);
};
export default SceneGroupPanel;