All files / src/list/ListStencils ListStencils.js

100% Statements 4/4
62.5% Branches 5/8
100% Functions 1/1
100% Lines 4/4

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47                        2x 2x                                               1x 1x                
/*** Libraries ***/
import React, { Component } from 'react';
import { defaultProps } from './props/defaultProps';
import { propTypes } from './props/propTypes';
 
/*** Components ***/
import Stencils from '@zohodesk/components/lib/Stencils/Stencils';
/*** CSS ***/
import style from './ListStencils.module.css';
 
export default class ListStencils extends Component {
  render() {
    let { listType, testId, customId } = this.props;
    return (
      <div className={`${style.container} ${style[listType]}`} data-test-id={testId ? testId + '_listStencils' : null} data-id={customId ? customId + '_listStencils' : null} aria-hidden='true'>
        <div className={style.innerContainer}>
          <div className={style.avatar}>
            <Stencils
              shape='circle'
              size={listType === 'classic' ? 'large' : listType === 'compact' ? 'medium' : 'small'}
            />
          </div>
          <div className={style.detailsColumn}>
            <div className={`${style.detailsInnerColumn}`}>
              <div className={style.primaryRow}>
                <Stencils size='default' />
              </div>
              <div className={style.secondaryRow}>
                <Stencils size='medium' />
              </div>
            </div>
          </div>
        </div>
      </div>
    );
  }
}
ListStencils.propTypes = propTypes;
ListStencils.defaultProps = defaultProps;
 
// if (__DOCS__) {
//   ListStencils.docs = {
//     folderName: 'List',
//     componentGroup: 'ListStencils'
//   };
// }