All Downloads are FREE. Search and download functionalities are using the official Maven repository.

components.widgets.Table.cells.ImageCell.ImageStatuses.jsx Maven / Gradle / Ivy

The newest version!
import React from 'react'
import map from 'lodash/map'
import classNames from 'classnames'
import get from 'lodash/get'
import PropTypes from 'prop-types'

// eslint-disable-next-line import/no-named-as-default
import Factory from '../../../../../core/factory/Factory'
import { SNIPPETS } from '../../../../../core/factory/factoryLevels'
import propsResolver from '../../../../../utils/propsResolver'

export default function ImageStatuses({ statuses, className, model, onClick }) {
    return (
        
{map(statuses, (status, index) => { const { src, fieldId, place } = status const text = get(model, fieldId) const props = { text, ...propsResolver(status, model), } return ( ) })}
) } ImageStatuses.propTypes = { statuses: PropTypes.array, className: PropTypes.string, model: PropTypes.object, onClick: PropTypes.bool, }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy