import React from "react"; import { Box, Text } from "grommet"; import { StatusGoodSmall } from "grommet-icons"; import { stateToColor } from "../../utils/indi"; import LightVector from "./light"; import NumberVector from "./number"; import SwitchVector from "./switch"; import TextVector from "./text"; const Property = ({ property }) => { return ( {property.vector.label || property.name} {property.vector.__typename === "NumberVector" && ( )} {property.vector.__typename === "SwitchVector" && ( )} {property.vector.__typename === "TextVector" && ( )} {property.vector.__typename === "LightVector" && ( )} ); }; export default Property;