ant-design/ant-design

View on GitHub
components/upload/style/picture.ts

Summary

Maintainability
C
1 day
Test Coverage

Function genPictureCardStyle has 142 lines of code (exceeds 25 allowed). Consider refactoring.
Open

const genPictureCardStyle: GenerateStyle<UploadToken> = (token) => {
  const { componentCls, iconCls, fontSizeLG, colorTextLightSolid, calc } = token;

  const listCls = `${componentCls}-list`;
  const itemCls = `${listCls}-item`;
Severity: Major
Found in components/upload/style/picture.ts - About 5 hrs to fix

    Function genPictureStyle has 72 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    const genPictureStyle: GenerateStyle<UploadToken> = (token) => {
      const { componentCls, iconCls, uploadThumbnailSize, uploadProgressOffset, calc } = token;
      const listCls = `${componentCls}-list`;
      const itemCls = `${listCls}-item`;
    
    
    Severity: Major
    Found in components/upload/style/picture.ts - About 2 hrs to fix

      There are no issues that match your filters.

      Category
      Status