@alfalab/core-components-file-upload-item 8.0.3 → 8.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (127) hide show
  1. package/components/actions-control/actions-control.css +8 -8
  2. package/components/actions-control/actions-control.module.css.js +1 -1
  3. package/components/actions-control/actions-control.module.css.js.map +1 -1
  4. package/components/actions-control/actions.js.map +1 -1
  5. package/components/actions-control/components/delete-button/delete-button.js.map +1 -1
  6. package/components/actions-control/components/download-button/download-button.js.map +1 -1
  7. package/components/actions-control/components/restore-button/restore-button.js.map +1 -1
  8. package/components/content/components/content-error/content-error.css +1 -1
  9. package/components/content/components/content-error/content-error.js.map +1 -1
  10. package/components/content/components/content-error/content-error.module.css.js +1 -1
  11. package/components/content/components/content-subtitle/content-subtitle.css +3 -3
  12. package/components/content/components/content-subtitle/content-subtitle.js.map +1 -1
  13. package/components/content/components/content-subtitle/content-subtitle.module.css.js +1 -1
  14. package/components/content/components/content-subtitle/content-subtitle.module.css.js.map +1 -1
  15. package/components/content/content.css +7 -7
  16. package/components/content/content.js.map +1 -1
  17. package/components/content/content.module.css.js +1 -1
  18. package/components/content/content.module.css.js.map +1 -1
  19. package/components/content/utils/isError.js.map +1 -1
  20. package/components/status-control/extension-icon/index.css +5 -5
  21. package/components/status-control/extension-icon/index.js.map +1 -1
  22. package/components/status-control/extension-icon/index.module.css.js +1 -1
  23. package/components/status-control/extension-icon/index.module.css.js.map +1 -1
  24. package/components/status-control/index.css +8 -8
  25. package/components/status-control/index.module.css.js +1 -1
  26. package/components/status-control/index.module.css.js.map +1 -1
  27. package/context/file-upload-item-context.d.ts +1 -1
  28. package/cssm/components/actions-control/actions.js.map +1 -1
  29. package/cssm/components/actions-control/components/delete-button/delete-button.js.map +1 -1
  30. package/cssm/components/actions-control/components/download-button/download-button.js.map +1 -1
  31. package/cssm/components/actions-control/components/restore-button/restore-button.js.map +1 -1
  32. package/cssm/components/content/components/content-error/content-error.js.map +1 -1
  33. package/cssm/components/content/components/content-subtitle/content-subtitle.js.map +1 -1
  34. package/cssm/components/content/content.js.map +1 -1
  35. package/cssm/components/content/utils/isError.js.map +1 -1
  36. package/cssm/components/status-control/extension-icon/index.js.map +1 -1
  37. package/cssm/context/file-upload-item-context.d.ts +1 -1
  38. package/cssm/types/status.d.ts +1 -1
  39. package/cssm/utils.d.ts +6 -6
  40. package/esm/components/actions-control/actions-control.css +8 -8
  41. package/esm/components/actions-control/actions-control.module.css.js +1 -1
  42. package/esm/components/actions-control/actions-control.module.css.js.map +1 -1
  43. package/esm/components/actions-control/actions.js.map +1 -1
  44. package/esm/components/actions-control/components/delete-button/delete-button.js.map +1 -1
  45. package/esm/components/actions-control/components/download-button/download-button.js.map +1 -1
  46. package/esm/components/actions-control/components/restore-button/restore-button.js.map +1 -1
  47. package/esm/components/content/components/content-error/content-error.css +1 -1
  48. package/esm/components/content/components/content-error/content-error.js.map +1 -1
  49. package/esm/components/content/components/content-error/content-error.module.css.js +1 -1
  50. package/esm/components/content/components/content-subtitle/content-subtitle.css +3 -3
  51. package/esm/components/content/components/content-subtitle/content-subtitle.js.map +1 -1
  52. package/esm/components/content/components/content-subtitle/content-subtitle.module.css.js +1 -1
  53. package/esm/components/content/components/content-subtitle/content-subtitle.module.css.js.map +1 -1
  54. package/esm/components/content/content.css +7 -7
  55. package/esm/components/content/content.js.map +1 -1
  56. package/esm/components/content/content.module.css.js +1 -1
  57. package/esm/components/content/content.module.css.js.map +1 -1
  58. package/esm/components/content/utils/isError.js.map +1 -1
  59. package/esm/components/status-control/extension-icon/index.css +5 -5
  60. package/esm/components/status-control/extension-icon/index.js.map +1 -1
  61. package/esm/components/status-control/extension-icon/index.module.css.js +1 -1
  62. package/esm/components/status-control/extension-icon/index.module.css.js.map +1 -1
  63. package/esm/components/status-control/index.css +8 -8
  64. package/esm/components/status-control/index.module.css.js +1 -1
  65. package/esm/components/status-control/index.module.css.js.map +1 -1
  66. package/esm/context/file-upload-item-context.d.ts +1 -1
  67. package/esm/index.css +2 -2
  68. package/esm/index.module.css.js +1 -1
  69. package/esm/index.module.css.js.map +1 -1
  70. package/esm/types/status.d.ts +1 -1
  71. package/esm/utils.d.ts +6 -6
  72. package/index.css +2 -2
  73. package/index.module.css.js +1 -1
  74. package/index.module.css.js.map +1 -1
  75. package/modern/components/actions-control/actions-control.css +8 -8
  76. package/modern/components/actions-control/actions-control.module.css.js +1 -1
  77. package/modern/components/actions-control/actions-control.module.css.js.map +1 -1
  78. package/modern/components/actions-control/actions.js.map +1 -1
  79. package/modern/components/actions-control/components/delete-button/delete-button.js.map +1 -1
  80. package/modern/components/actions-control/components/download-button/download-button.js.map +1 -1
  81. package/modern/components/actions-control/components/restore-button/restore-button.js.map +1 -1
  82. package/modern/components/content/components/content-error/content-error.css +1 -1
  83. package/modern/components/content/components/content-error/content-error.js.map +1 -1
  84. package/modern/components/content/components/content-error/content-error.module.css.js +1 -1
  85. package/modern/components/content/components/content-subtitle/content-subtitle.css +3 -3
  86. package/modern/components/content/components/content-subtitle/content-subtitle.js.map +1 -1
  87. package/modern/components/content/components/content-subtitle/content-subtitle.module.css.js +1 -1
  88. package/modern/components/content/components/content-subtitle/content-subtitle.module.css.js.map +1 -1
  89. package/modern/components/content/content.css +7 -7
  90. package/modern/components/content/content.js.map +1 -1
  91. package/modern/components/content/content.module.css.js +1 -1
  92. package/modern/components/content/content.module.css.js.map +1 -1
  93. package/modern/components/content/utils/isError.js.map +1 -1
  94. package/modern/components/status-control/extension-icon/index.css +5 -5
  95. package/modern/components/status-control/extension-icon/index.js.map +1 -1
  96. package/modern/components/status-control/extension-icon/index.module.css.js +1 -1
  97. package/modern/components/status-control/extension-icon/index.module.css.js.map +1 -1
  98. package/modern/components/status-control/index.css +8 -8
  99. package/modern/components/status-control/index.module.css.js +1 -1
  100. package/modern/components/status-control/index.module.css.js.map +1 -1
  101. package/modern/context/file-upload-item-context.d.ts +1 -1
  102. package/modern/index.css +2 -2
  103. package/modern/index.module.css.js +1 -1
  104. package/modern/index.module.css.js.map +1 -1
  105. package/modern/types/status.d.ts +1 -1
  106. package/modern/utils.d.ts +6 -6
  107. package/moderncssm/components/actions-control/actions.js.map +1 -1
  108. package/moderncssm/components/actions-control/components/delete-button/delete-button.js.map +1 -1
  109. package/moderncssm/components/actions-control/components/download-button/download-button.js.map +1 -1
  110. package/moderncssm/components/actions-control/components/restore-button/restore-button.js.map +1 -1
  111. package/moderncssm/components/content/components/content-error/content-error.js.map +1 -1
  112. package/moderncssm/components/content/components/content-subtitle/content-subtitle.js.map +1 -1
  113. package/moderncssm/components/content/content.js.map +1 -1
  114. package/moderncssm/components/content/utils/isError.js.map +1 -1
  115. package/moderncssm/components/status-control/extension-icon/index.js.map +1 -1
  116. package/moderncssm/context/file-upload-item-context.d.ts +1 -1
  117. package/moderncssm/types/status.d.ts +1 -1
  118. package/moderncssm/utils.d.ts +6 -6
  119. package/package.json +6 -6
  120. package/src/components/actions-control/actions-control.module.css +1 -1
  121. package/src/components/content/components/content-subtitle/content-subtitle.module.css +1 -1
  122. package/src/components/content/content.module.css +1 -1
  123. package/src/components/status-control/extension-icon/index.module.css +1 -1
  124. package/src/components/status-control/index.module.css +1 -1
  125. package/src/index.module.css +1 -1
  126. package/types/status.d.ts +1 -1
  127. package/utils.d.ts +6 -6
@@ -1 +1 @@
1
- {"version":3,"file":"isError.js","sources":["../../../../src/components/content/utils/isError.ts"],"sourcesContent":["export const isError = (error?: string | string[]) => {\n if (typeof error === 'string' && error.length > 0) {\n return true;\n }\n\n if (Array.isArray(error) && error.length > 0) {\n return true;\n }\n\n return false;\n};\n"],"names":[],"mappings":"AAAa,MAAA,OAAO,GAAG,CAAC,KAAyB,KAAI;IACjD,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE;AAC/C,QAAA,OAAO,IAAI;AACd;AAED,IAAA,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE;AAC1C,QAAA,OAAO,IAAI;AACd;AAED,IAAA,OAAO,KAAK;AAChB;;;;"}
1
+ {"version":3,"file":"isError.js","sources":["../../../../src/components/content/utils/isError.ts"],"sourcesContent":["export const isError = (error?: string | string[]) => {\n if (typeof error === 'string' && error.length > 0) {\n return true;\n }\n\n if (Array.isArray(error) && error.length > 0) {\n return true;\n }\n\n return false;\n};\n"],"names":[],"mappings":"AAAa,MAAA,OAAO,GAAG,CAAC,KAAyB,KAAI;IACjD,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE;AAC/C,QAAA,OAAO,IAAI;;AAGf,IAAA,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE;AAC1C,QAAA,OAAO,IAAI;;AAGf,IAAA,OAAO,KAAK;AAChB;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/components/status-control/extension-icon/index.tsx"],"sourcesContent":["import React, { useContext } from 'react';\nimport cn from 'classnames';\n\nimport { Document1CMIcon } from '@alfalab/icons-glyph/Document1CMIcon';\nimport { DocumentDocMIcon } from '@alfalab/icons-glyph/DocumentDocMIcon';\nimport { DocumentExcelMIcon } from '@alfalab/icons-glyph/DocumentExcelMIcon';\nimport { DocumentImageMIcon } from '@alfalab/icons-glyph/DocumentImageMIcon';\nimport { DocumentMIcon } from '@alfalab/icons-glyph/DocumentMIcon';\nimport { DocumentOffMIcon } from '@alfalab/icons-glyph/DocumentOffMIcon';\nimport { DocumentPdfMIcon } from '@alfalab/icons-glyph/DocumentPdfMIcon';\nimport { PaperclipMIcon } from '@alfalab/icons-glyph/PaperclipMIcon';\n\nimport { FileUploadItemContext } from '../../../context/file-upload-item-context';\nimport { getExtension, isInitialStatus } from '../../../utils';\n\nimport styles from './index.module.css';\n\nexport const ExtensionIcon = () => {\n const {\n title = '',\n uploadStatus,\n iconStyle,\n customIcon: CustomIcon,\n imageUrl,\n showRestore,\n } = useContext(FileUploadItemContext);\n\n if (imageUrl) {\n return null;\n }\n\n if (CustomIcon) {\n return <CustomIcon />;\n }\n\n if (isInitialStatus(uploadStatus)) {\n return <PaperclipMIcon />;\n }\n\n if (showRestore) {\n return <DocumentOffMIcon />;\n }\n\n const isColoredIcon = iconStyle === 'colored';\n const fileType = getExtension(title);\n\n switch (fileType) {\n case 'pdf':\n case 'ppt':\n case 'pptx':\n return <DocumentPdfMIcon className={cn({ [styles.iconPDFColored]: isColoredIcon })} />;\n case 'doc':\n case 'docx':\n return <DocumentDocMIcon className={cn({ [styles.iconDOCColored]: isColoredIcon })} />;\n case 'xls':\n case 'xlsx':\n return (\n <DocumentExcelMIcon className={cn({ [styles.iconExcelColored]: isColoredIcon })} />\n );\n case '1c':\n return <Document1CMIcon className={cn({ [styles.icon1CColored]: isColoredIcon })} />;\n case 'png':\n case 'jpg':\n case 'jpeg':\n case 'svg':\n case 'tif':\n case 'tiff':\n return <DocumentImageMIcon />;\n default:\n return (\n <DocumentMIcon className={cn({ [styles.iconDocumentColored]: isColoredIcon })} />\n );\n }\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAiBO,MAAM,aAAa,GAAG,MAAK;IAC9B,MAAM,EACF,KAAK,GAAG,EAAE,EACV,YAAY,EACZ,SAAS,EACT,UAAU,EAAE,UAAU,EACtB,QAAQ,EACR,WAAW,GACd,GAAG,UAAU,CAAC,qBAAqB,CAAC;AAErC,IAAA,IAAI,QAAQ,EAAE;AACV,QAAA,OAAO,IAAI;AACd;AAED,IAAA,IAAI,UAAU,EAAE;QACZ,OAAO,KAAA,CAAA,aAAA,CAAC,UAAU,EAAA,IAAA,CAAG;AACxB;AAED,IAAA,IAAI,eAAe,CAAC,YAAY,CAAC,EAAE;QAC/B,OAAO,KAAA,CAAA,aAAA,CAAC,cAAc,EAAA,IAAA,CAAG;AAC5B;AAED,IAAA,IAAI,WAAW,EAAE;QACb,OAAO,KAAA,CAAA,aAAA,CAAC,gBAAgB,EAAA,IAAA,CAAG;AAC9B;AAED,IAAA,MAAM,aAAa,GAAG,SAAS,KAAK,SAAS;AAC7C,IAAA,MAAM,QAAQ,GAAG,YAAY,CAAC,KAAK,CAAC;AAEpC,IAAA,QAAQ,QAAQ;AACZ,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;AACP,YAAA,OAAO,oBAAC,gBAAgB,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,cAAc,GAAG,aAAa,EAAE,CAAC,GAAI;AAC1F,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;AACP,YAAA,OAAO,oBAAC,gBAAgB,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,cAAc,GAAG,aAAa,EAAE,CAAC,GAAI;AAC1F,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;YACP,QACI,oBAAC,kBAAkB,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,gBAAgB,GAAG,aAAa,EAAE,CAAC,EAAA,CAAI;AAE3F,QAAA,KAAK,IAAI;AACL,YAAA,OAAO,oBAAC,eAAe,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,aAAa,GAAG,aAAa,EAAE,CAAC,GAAI;AACxF,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;AACX,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;YACP,OAAO,KAAA,CAAA,aAAA,CAAC,kBAAkB,EAAA,IAAA,CAAG;AACjC,QAAA;YACI,QACI,oBAAC,aAAa,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,mBAAmB,GAAG,aAAa,EAAE,CAAC,EAAA,CAAI;AAE5F;AACL;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/components/status-control/extension-icon/index.tsx"],"sourcesContent":["import React, { useContext } from 'react';\nimport cn from 'classnames';\n\nimport { Document1CMIcon } from '@alfalab/icons-glyph/Document1CMIcon';\nimport { DocumentDocMIcon } from '@alfalab/icons-glyph/DocumentDocMIcon';\nimport { DocumentExcelMIcon } from '@alfalab/icons-glyph/DocumentExcelMIcon';\nimport { DocumentImageMIcon } from '@alfalab/icons-glyph/DocumentImageMIcon';\nimport { DocumentMIcon } from '@alfalab/icons-glyph/DocumentMIcon';\nimport { DocumentOffMIcon } from '@alfalab/icons-glyph/DocumentOffMIcon';\nimport { DocumentPdfMIcon } from '@alfalab/icons-glyph/DocumentPdfMIcon';\nimport { PaperclipMIcon } from '@alfalab/icons-glyph/PaperclipMIcon';\n\nimport { FileUploadItemContext } from '../../../context/file-upload-item-context';\nimport { getExtension, isInitialStatus } from '../../../utils';\n\nimport styles from './index.module.css';\n\nexport const ExtensionIcon = () => {\n const {\n title = '',\n uploadStatus,\n iconStyle,\n customIcon: CustomIcon,\n imageUrl,\n showRestore,\n } = useContext(FileUploadItemContext);\n\n if (imageUrl) {\n return null;\n }\n\n if (CustomIcon) {\n return <CustomIcon />;\n }\n\n if (isInitialStatus(uploadStatus)) {\n return <PaperclipMIcon />;\n }\n\n if (showRestore) {\n return <DocumentOffMIcon />;\n }\n\n const isColoredIcon = iconStyle === 'colored';\n const fileType = getExtension(title);\n\n switch (fileType) {\n case 'pdf':\n case 'ppt':\n case 'pptx':\n return <DocumentPdfMIcon className={cn({ [styles.iconPDFColored]: isColoredIcon })} />;\n case 'doc':\n case 'docx':\n return <DocumentDocMIcon className={cn({ [styles.iconDOCColored]: isColoredIcon })} />;\n case 'xls':\n case 'xlsx':\n return (\n <DocumentExcelMIcon className={cn({ [styles.iconExcelColored]: isColoredIcon })} />\n );\n case '1c':\n return <Document1CMIcon className={cn({ [styles.icon1CColored]: isColoredIcon })} />;\n case 'png':\n case 'jpg':\n case 'jpeg':\n case 'svg':\n case 'tif':\n case 'tiff':\n return <DocumentImageMIcon />;\n default:\n return (\n <DocumentMIcon className={cn({ [styles.iconDocumentColored]: isColoredIcon })} />\n );\n }\n};\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAiBO,MAAM,aAAa,GAAG,MAAK;IAC9B,MAAM,EACF,KAAK,GAAG,EAAE,EACV,YAAY,EACZ,SAAS,EACT,UAAU,EAAE,UAAU,EACtB,QAAQ,EACR,WAAW,GACd,GAAG,UAAU,CAAC,qBAAqB,CAAC;IAErC,IAAI,QAAQ,EAAE;AACV,QAAA,OAAO,IAAI;;IAGf,IAAI,UAAU,EAAE;QACZ,OAAO,KAAA,CAAA,aAAA,CAAC,UAAU,EAAA,IAAA,CAAG;;AAGzB,IAAA,IAAI,eAAe,CAAC,YAAY,CAAC,EAAE;QAC/B,OAAO,KAAA,CAAA,aAAA,CAAC,cAAc,EAAA,IAAA,CAAG;;IAG7B,IAAI,WAAW,EAAE;QACb,OAAO,KAAA,CAAA,aAAA,CAAC,gBAAgB,EAAA,IAAA,CAAG;;AAG/B,IAAA,MAAM,aAAa,GAAG,SAAS,KAAK,SAAS;AAC7C,IAAA,MAAM,QAAQ,GAAG,YAAY,CAAC,KAAK,CAAC;IAEpC,QAAQ,QAAQ;AACZ,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;AACP,YAAA,OAAO,oBAAC,gBAAgB,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,cAAc,GAAG,aAAa,EAAE,CAAC,GAAI;AAC1F,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;AACP,YAAA,OAAO,oBAAC,gBAAgB,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,cAAc,GAAG,aAAa,EAAE,CAAC,GAAI;AAC1F,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;YACP,QACI,oBAAC,kBAAkB,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,gBAAgB,GAAG,aAAa,EAAE,CAAC,EAAA,CAAI;AAE3F,QAAA,KAAK,IAAI;AACL,YAAA,OAAO,oBAAC,eAAe,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,aAAa,GAAG,aAAa,EAAE,CAAC,GAAI;AACxF,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;AACX,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,KAAK;AACV,QAAA,KAAK,MAAM;YACP,OAAO,KAAA,CAAA,aAAA,CAAC,kBAAkB,EAAA,IAAA,CAAG;AACjC,QAAA;YACI,QACI,oBAAC,aAAa,EAAA,EAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC,MAAM,CAAC,mBAAmB,GAAG,aAAa,EAAE,CAAC,EAAA,CAAI;;AAGjG;;;;"}
@@ -1,7 +1,7 @@
1
1
  import { type ElementType, type HTMLAttributeAnchorTarget, type MouseEvent } from 'react';
2
2
  import { type SuperEllipseProps } from '@alfalab/core-components-icon-view/moderncssm/super-ellipse';
3
3
  import { type FileUploadItemStatus } from '../types/status';
4
- declare type TFileUploadItemContext = {
4
+ type TFileUploadItemContext = {
5
5
  showRestore?: boolean;
6
6
  uploadStatus?: FileUploadItemStatus;
7
7
  error?: string | string[];
@@ -1 +1 @@
1
- export declare type FileUploadItemStatus = 'INITIAL' | 'SUCCESS' | 'ERROR' | 'UPLOADING' | 'UPLOADED' | 'LOADING' | 'DELETED';
1
+ export type FileUploadItemStatus = 'INITIAL' | 'SUCCESS' | 'ERROR' | 'UPLOADING' | 'UPLOADED' | 'LOADING' | 'DELETED';
@@ -1,8 +1,8 @@
1
1
  import { type FileUploadItemStatus } from './types/status';
2
2
  export declare const getExtension: (filename: string) => string | undefined;
3
- export declare const isInitialStatus: (status?: FileUploadItemStatus) => boolean;
4
- export declare const isSuccessStatus: (status?: FileUploadItemStatus) => boolean;
5
- export declare const isErrorStatus: (status?: FileUploadItemStatus) => boolean;
6
- export declare const isUploadingStatus: (status?: FileUploadItemStatus) => boolean;
7
- export declare const isUploadedStatus: (status?: FileUploadItemStatus) => boolean;
8
- export declare const isLoadingStatus: (status?: FileUploadItemStatus) => boolean;
3
+ export declare const isInitialStatus: (status?: FileUploadItemStatus) => status is "INITIAL";
4
+ export declare const isSuccessStatus: (status?: FileUploadItemStatus) => status is "SUCCESS";
5
+ export declare const isErrorStatus: (status?: FileUploadItemStatus) => status is "ERROR";
6
+ export declare const isUploadingStatus: (status?: FileUploadItemStatus) => status is "UPLOADING";
7
+ export declare const isUploadedStatus: (status?: FileUploadItemStatus) => status is "UPLOADED";
8
+ export declare const isLoadingStatus: (status?: FileUploadItemStatus) => status is "LOADING";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfalab/core-components-file-upload-item",
3
- "version": "8.0.3",
3
+ "version": "8.0.4",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "license": "MIT",
@@ -10,10 +10,10 @@
10
10
  "main": "index.js",
11
11
  "module": "./esm/index.js",
12
12
  "dependencies": {
13
- "@alfalab/core-components-icon-button": "^8.0.3",
14
- "@alfalab/core-components-icon-view": "^5.0.1",
15
- "@alfalab/core-components-shared": "^2.1.0",
16
- "@alfalab/core-components-typography": "^6.0.2",
13
+ "@alfalab/core-components-icon-button": "^8.0.4",
14
+ "@alfalab/core-components-icon-view": "^5.0.2",
15
+ "@alfalab/core-components-shared": "^2.1.1",
16
+ "@alfalab/core-components-typography": "^6.0.3",
17
17
  "@alfalab/hooks": "^1.13.1",
18
18
  "@alfalab/icons-glyph": "^2.260.0",
19
19
  "classnames": "^2.5.1",
@@ -28,5 +28,5 @@
28
28
  "directory": "dist"
29
29
  },
30
30
  "themesVersion": "15.0.2",
31
- "varsVersion": "11.0.1"
31
+ "varsVersion": "11.0.2"
32
32
  }
@@ -1,4 +1,4 @@
1
- @import '@alfalab/core-components-vars/src/no-typography-index.css';
1
+ @import '@alfalab/core-components-vars/src/index.css';
2
2
 
3
3
  .container {
4
4
  display: flex;
@@ -1,4 +1,4 @@
1
- @import '@alfalab/core-components-vars/src/no-typography-index.css';
1
+ @import '@alfalab/core-components-vars/src/index.css';
2
2
 
3
3
  .subtitle {
4
4
  display: block;
@@ -1,4 +1,4 @@
1
- @import '@alfalab/core-components-vars/src/no-typography-index.css';
1
+ @import '@alfalab/core-components-vars/src/index.css';
2
2
 
3
3
  .container {
4
4
  padding: var(--gap-2) 0 0 var(--gap-16);
@@ -1,4 +1,4 @@
1
- @import '@alfalab/core-components-vars/src/no-typography-index.css';
1
+ @import '@alfalab/core-components-vars/src/index.css';
2
2
  @import '@alfalab/core-components-vars/src/colors-decorative.css';
3
3
 
4
4
  .iconPDFColored {
@@ -1,4 +1,4 @@
1
- @import '@alfalab/core-components-vars/src/no-typography-index.css';
1
+ @import '@alfalab/core-components-vars/src/index.css';
2
2
 
3
3
  .container {
4
4
  position: relative;
@@ -1,4 +1,4 @@
1
- @import '@alfalab/core-components-vars/src/no-typography-index.css';
1
+ @import '@alfalab/core-components-vars/src/index.css';
2
2
 
3
3
  .component {
4
4
  box-sizing: border-box;
package/types/status.d.ts CHANGED
@@ -1 +1 @@
1
- export declare type FileUploadItemStatus = 'INITIAL' | 'SUCCESS' | 'ERROR' | 'UPLOADING' | 'UPLOADED' | 'LOADING' | 'DELETED';
1
+ export type FileUploadItemStatus = 'INITIAL' | 'SUCCESS' | 'ERROR' | 'UPLOADING' | 'UPLOADED' | 'LOADING' | 'DELETED';
package/utils.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { type FileUploadItemStatus } from './types/status';
2
2
  export declare const getExtension: (filename: string) => string | undefined;
3
- export declare const isInitialStatus: (status?: FileUploadItemStatus) => boolean;
4
- export declare const isSuccessStatus: (status?: FileUploadItemStatus) => boolean;
5
- export declare const isErrorStatus: (status?: FileUploadItemStatus) => boolean;
6
- export declare const isUploadingStatus: (status?: FileUploadItemStatus) => boolean;
7
- export declare const isUploadedStatus: (status?: FileUploadItemStatus) => boolean;
8
- export declare const isLoadingStatus: (status?: FileUploadItemStatus) => boolean;
3
+ export declare const isInitialStatus: (status?: FileUploadItemStatus) => status is "INITIAL";
4
+ export declare const isSuccessStatus: (status?: FileUploadItemStatus) => status is "SUCCESS";
5
+ export declare const isErrorStatus: (status?: FileUploadItemStatus) => status is "ERROR";
6
+ export declare const isUploadingStatus: (status?: FileUploadItemStatus) => status is "UPLOADING";
7
+ export declare const isUploadedStatus: (status?: FileUploadItemStatus) => status is "UPLOADED";
8
+ export declare const isLoadingStatus: (status?: FileUploadItemStatus) => status is "LOADING";