github.com/thanos-io/thanos@v0.32.5/pkg/ui/react-app/src/thanos/pages/stores/StoreLabels.tsx (about)

     1  import React, { FC } from 'react';
     2  import { Badge, ListGroup, ListGroupItem } from 'reactstrap';
     3  import { Labels } from './store';
     4  
     5  export type StoreLabelsProps = { labelSets: Labels[] };
     6  
     7  export const StoreLabels: FC<StoreLabelsProps> = ({ labelSets }) => {
     8    return (
     9      <ListGroup>
    10        {labelSets.map((labels, idx) => (
    11          <ListGroupItem key={idx}>
    12            {Object.entries(labels).map(([name, value]) => (
    13              <Badge key={name} color="primary" style={{ margin: '0px 5px' }}>{`${name}="${value}"`}</Badge>
    14            ))}
    15          </ListGroupItem>
    16        ))}
    17      </ListGroup>
    18    );
    19  };
    20  
    21  export default StoreLabels;