@alfalab/core-components-file-upload-item 8.2.3-alfasans → 8.2.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 (49) 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/content/components/content-error/content-error.css +1 -1
  4. package/components/content/components/content-error/content-error.module.css.js +1 -1
  5. package/components/content/components/content-subtitle/content-subtitle.css +3 -3
  6. package/components/content/components/content-subtitle/content-subtitle.module.css.js +1 -1
  7. package/components/content/content.css +7 -7
  8. package/components/content/content.module.css.js +1 -1
  9. package/components/status-control/extension-icon/index.css +6 -6
  10. package/components/status-control/extension-icon/index.module.css.js +1 -1
  11. package/components/status-control/index.css +8 -8
  12. package/components/status-control/index.module.css.js +1 -1
  13. package/cssm/types/file-upload-item-props.d.ts +7 -2
  14. package/esm/components/actions-control/actions-control.css +8 -8
  15. package/esm/components/actions-control/actions-control.module.css.js +1 -1
  16. package/esm/components/content/components/content-error/content-error.css +1 -1
  17. package/esm/components/content/components/content-error/content-error.module.css.js +1 -1
  18. package/esm/components/content/components/content-subtitle/content-subtitle.css +3 -3
  19. package/esm/components/content/components/content-subtitle/content-subtitle.module.css.js +1 -1
  20. package/esm/components/content/content.css +7 -7
  21. package/esm/components/content/content.module.css.js +1 -1
  22. package/esm/components/status-control/extension-icon/index.css +6 -6
  23. package/esm/components/status-control/extension-icon/index.module.css.js +1 -1
  24. package/esm/components/status-control/index.css +8 -8
  25. package/esm/components/status-control/index.module.css.js +1 -1
  26. package/esm/index.css +2 -2
  27. package/esm/index.module.css.js +1 -1
  28. package/esm/types/file-upload-item-props.d.ts +7 -2
  29. package/index.css +2 -2
  30. package/index.module.css.js +1 -1
  31. package/modern/components/actions-control/actions-control.css +8 -8
  32. package/modern/components/actions-control/actions-control.module.css.js +1 -1
  33. package/modern/components/content/components/content-error/content-error.css +1 -1
  34. package/modern/components/content/components/content-error/content-error.module.css.js +1 -1
  35. package/modern/components/content/components/content-subtitle/content-subtitle.css +3 -3
  36. package/modern/components/content/components/content-subtitle/content-subtitle.module.css.js +1 -1
  37. package/modern/components/content/content.css +7 -7
  38. package/modern/components/content/content.module.css.js +1 -1
  39. package/modern/components/status-control/extension-icon/index.css +6 -6
  40. package/modern/components/status-control/extension-icon/index.module.css.js +1 -1
  41. package/modern/components/status-control/index.css +8 -8
  42. package/modern/components/status-control/index.module.css.js +1 -1
  43. package/modern/index.css +2 -2
  44. package/modern/index.module.css.js +1 -1
  45. package/modern/types/file-upload-item-props.d.ts +7 -2
  46. package/moderncssm/types/file-upload-item-props.d.ts +7 -2
  47. package/package.json +7 -7
  48. package/src/types/file-upload-item-props.ts +7 -2
  49. package/types/file-upload-item-props.d.ts +7 -2
@@ -2,29 +2,29 @@
2
2
  --color-light-text-tertiary: rgba(5, 8, 29, 0.38);
3
3
  --color-light-text-tertiary-hover: rgba(4, 4, 21, 0.47);
4
4
  }
5
- .file-upload-item__container_1bt7p {
5
+ .file-upload-item__container_5bu57 {
6
6
  display: flex;
7
7
  max-width: 144px;
8
8
  }
9
- .file-upload-item__container_1bt7p .file-upload-item__icon_1bt7p {
9
+ .file-upload-item__container_5bu57 .file-upload-item__icon_5bu57 {
10
10
  width: 48px;
11
11
  height: 48px;
12
12
  }
13
- .file-upload-item__deleteIconColor_1bt7p {
13
+ .file-upload-item__deleteIconColor_5bu57 {
14
14
  fill: var(--color-light-text-tertiary);
15
15
  }
16
- .file-upload-item__deleteIconColor_1bt7p:hover {
16
+ .file-upload-item__deleteIconColor_5bu57:hover {
17
17
  fill: var(--color-light-text-tertiary-hover);
18
18
  }
19
- .file-upload-item__downloadIconColor_1bt7p {
19
+ .file-upload-item__downloadIconColor_5bu57 {
20
20
  fill: var(--color-light-text-tertiary);
21
21
  }
22
- .file-upload-item__downloadIconColor_1bt7p:hover {
22
+ .file-upload-item__downloadIconColor_5bu57:hover {
23
23
  fill: var(--color-light-text-tertiary-hover);
24
24
  }
25
- .file-upload-item__restoreIconColor_1bt7p {
25
+ .file-upload-item__restoreIconColor_5bu57 {
26
26
  fill: var(--color-light-text-tertiary);
27
27
  }
28
- .file-upload-item__restoreIconColor_1bt7p:hover {
28
+ .file-upload-item__restoreIconColor_5bu57:hover {
29
29
  fill: var(--color-light-text-tertiary-hover);
30
30
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./actions-control.css');
4
4
 
5
- var styles = {"container":"file-upload-item__container_1bt7p","icon":"file-upload-item__icon_1bt7p","deleteIconColor":"file-upload-item__deleteIconColor_1bt7p","downloadIconColor":"file-upload-item__downloadIconColor_1bt7p","restoreIconColor":"file-upload-item__restoreIconColor_1bt7p"};
5
+ var styles = {"container":"file-upload-item__container_5bu57","icon":"file-upload-item__icon_5bu57","deleteIconColor":"file-upload-item__deleteIconColor_5bu57","downloadIconColor":"file-upload-item__downloadIconColor_5bu57","restoreIconColor":"file-upload-item__restoreIconColor_5bu57"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=actions-control.module.css.js.map
@@ -1,3 +1,3 @@
1
- .file-upload-item__errorItem_be3g5 {
1
+ .file-upload-item__errorItem_1naqo {
2
2
  display: block;
3
3
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./content-error.css');
4
4
 
5
- var styles = {"errorItem":"file-upload-item__errorItem_be3g5"};
5
+ var styles = {"errorItem":"file-upload-item__errorItem_1naqo"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=content-error.module.css.js.map
@@ -1,14 +1,14 @@
1
1
  :root {
2
2
  --gap-8: 8px;
3
3
  }
4
- .file-upload-item__subtitle_10fw3 {
4
+ .file-upload-item__subtitle_slym2 {
5
5
  display: block;
6
6
  }
7
- .file-upload-item__subtitle_10fw3.file-upload-item__truncate_10fw3 {
7
+ .file-upload-item__subtitle_slym2.file-upload-item__truncate_slym2 {
8
8
  white-space: nowrap;
9
9
  overflow: hidden;
10
10
  text-overflow: ellipsis;
11
11
  }
12
- .file-upload-item__size_10fw3 {
12
+ .file-upload-item__size_slym2 {
13
13
  margin-right: var(--gap-8);
14
14
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./content-subtitle.css');
4
4
 
5
- var styles = {"subtitle":"file-upload-item__subtitle_10fw3","truncate":"file-upload-item__truncate_10fw3","size":"file-upload-item__size_10fw3"};
5
+ var styles = {"subtitle":"file-upload-item__subtitle_slym2","truncate":"file-upload-item__truncate_slym2","size":"file-upload-item__size_slym2"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=content-subtitle.module.css.js.map
@@ -6,34 +6,34 @@
6
6
  --gap-4: 4px;
7
7
  --gap-16: 16px;
8
8
  }
9
- .file-upload-item__container_1ernq {
9
+ .file-upload-item__container_qrawo {
10
10
  padding: var(--gap-2) 0 0 var(--gap-16);
11
11
  flex-grow: 1;
12
12
  min-width: 0;
13
13
  }
14
- .file-upload-item__container_1ernq.file-upload-item__clickable_1ernq {
14
+ .file-upload-item__container_qrawo.file-upload-item__clickable_qrawo {
15
15
  cursor: pointer;
16
16
  }
17
- .file-upload-item__container_1ernq.file-upload-item__single_1ernq {
17
+ .file-upload-item__container_qrawo.file-upload-item__single_qrawo {
18
18
  display: flex;
19
19
  flex-direction: column;
20
20
  justify-content: center;
21
21
  padding-top: 0;
22
22
  min-height: 48px;
23
23
  }
24
- .file-upload-item__container_1ernq.file-upload-item__single_1ernq .file-upload-item__title_1ernq {
24
+ .file-upload-item__container_qrawo.file-upload-item__single_qrawo .file-upload-item__title_qrawo {
25
25
  margin-bottom: 0;
26
26
  }
27
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq {
27
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo {
28
28
  margin-bottom: var(--gap-4);
29
29
  display: block;
30
30
  overflow-wrap: break-word;
31
31
  }
32
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq.file-upload-item__truncate_1ernq {
32
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo.file-upload-item__truncate_qrawo {
33
33
  white-space: nowrap;
34
34
  overflow: hidden;
35
35
  text-overflow: ellipsis;
36
36
  }
37
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq.file-upload-item__restore_1ernq {
37
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo.file-upload-item__restore_qrawo {
38
38
  color: var(--color-light-text-tertiary);
39
39
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./content.css');
4
4
 
5
- var styles = {"container":"file-upload-item__container_1ernq","clickable":"file-upload-item__clickable_1ernq","single":"file-upload-item__single_1ernq","title":"file-upload-item__title_1ernq","truncate":"file-upload-item__truncate_1ernq","restore":"file-upload-item__restore_1ernq"};
5
+ var styles = {"container":"file-upload-item__container_qrawo","clickable":"file-upload-item__clickable_qrawo","single":"file-upload-item__single_qrawo","title":"file-upload-item__title_qrawo","truncate":"file-upload-item__truncate_qrawo","restore":"file-upload-item__restore_qrawo"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=content.module.css.js.map
@@ -8,21 +8,21 @@
8
8
  --color-light-decorative-orange: #fa9313;
9
9
  --color-light-decorative-red: #fe5e48;
10
10
  }
11
- .file-upload-item__iconPDFColored_g3v90 {
11
+ .file-upload-item__iconPDFColored_1cq84 {
12
12
  fill: var(--color-light-decorative-red);
13
13
  }
14
- .file-upload-item__iconDOCColored_g3v90 {
14
+ .file-upload-item__iconDOCColored_1cq84 {
15
15
  fill: var(--color-light-decorative-blue);
16
16
  }
17
- .file-upload-item__iconExcelColored_g3v90 {
17
+ .file-upload-item__iconExcelColored_1cq84 {
18
18
  fill: var(--color-light-decorative-green);
19
19
  }
20
- .file-upload-item__icon1CColored_g3v90 {
20
+ .file-upload-item__icon1CColored_1cq84 {
21
21
  fill: var(--color-light-decorative-orange);
22
22
  }
23
- .file-upload-item__iconDocumentColored_g3v90 {
23
+ .file-upload-item__iconDocumentColored_1cq84 {
24
24
  fill: var(--color-light-neutral-translucent-1300);
25
25
  }
26
- .file-upload-item__iconArchiveColored_g3v90 {
26
+ .file-upload-item__iconArchiveColored_1cq84 {
27
27
  fill: var(--color-light-status-attention);
28
28
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./index.css');
4
4
 
5
- var styles = {"iconPDFColored":"file-upload-item__iconPDFColored_g3v90","iconDOCColored":"file-upload-item__iconDOCColored_g3v90","iconExcelColored":"file-upload-item__iconExcelColored_g3v90","icon1CColored":"file-upload-item__icon1CColored_g3v90","iconDocumentColored":"file-upload-item__iconDocumentColored_g3v90","iconArchiveColored":"file-upload-item__iconArchiveColored_g3v90"};
5
+ var styles = {"iconPDFColored":"file-upload-item__iconPDFColored_1cq84","iconDOCColored":"file-upload-item__iconDOCColored_1cq84","iconExcelColored":"file-upload-item__iconExcelColored_1cq84","icon1CColored":"file-upload-item__icon1CColored_1cq84","iconDocumentColored":"file-upload-item__iconDocumentColored_1cq84","iconArchiveColored":"file-upload-item__iconArchiveColored_1cq84"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=index.module.css.js.map
@@ -6,30 +6,30 @@
6
6
  :root {
7
7
  --gap-4-neg: -4px;
8
8
  }
9
- .file-upload-item__container_1bh7t {
9
+ .file-upload-item__container_19efp {
10
10
  position: relative;
11
11
  }
12
- .file-upload-item__container_1bh7t.file-upload-item__clickable_1bh7t {
12
+ .file-upload-item__container_19efp.file-upload-item__clickable_19efp {
13
13
  cursor: pointer;
14
14
  }
15
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t {
15
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp {
16
16
  position: absolute;
17
17
  top: var(--gap-4-neg);
18
18
  left: var(--gap-4-neg);
19
19
  z-index: 1;
20
20
  will-change: opacity;
21
21
  }
22
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__success_1bh7t,
23
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__error_1bh7t {
22
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__success_19efp,
23
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__error_19efp {
24
24
  transition: opacity 400ms ease-in;
25
25
  opacity: 0;
26
26
  }
27
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__success_1bh7t path {
27
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__success_19efp path {
28
28
  stroke: var(--color-light-status-positive);
29
29
  }
30
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__loading_1bh7t {
30
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__loading_19efp {
31
31
  color: var(--color-light-neutral-500);
32
32
  }
33
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__error_1bh7t path {
33
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__error_19efp path {
34
34
  stroke: var(--color-light-status-negative);
35
35
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./index.css');
4
4
 
5
- var styles = {"container":"file-upload-item__container_1bh7t","clickable":"file-upload-item__clickable_1bh7t","progress":"file-upload-item__progress_1bh7t","success":"file-upload-item__success_1bh7t","error":"file-upload-item__error_1bh7t","loading":"file-upload-item__loading_1bh7t"};
5
+ var styles = {"container":"file-upload-item__container_19efp","clickable":"file-upload-item__clickable_19efp","progress":"file-upload-item__progress_19efp","success":"file-upload-item__success_19efp","error":"file-upload-item__error_19efp","loading":"file-upload-item__loading_19efp"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=index.module.css.js.map
@@ -32,7 +32,10 @@ export interface FileUploadItemProps {
32
32
  */
33
33
  uploadDate?: string;
34
34
  /**
35
- * Ссылка на файл. Если прокидывается этот параметр, то появляется кнопка скачивания
35
+ * Ссылка на файл.
36
+ * Если передан `downloadLink` или `onDownload`, отображается кнопка скачивания.
37
+ * По клику на кнопку браузер переходит по ссылке (или скачивает файл, если передан `download`).
38
+ * Если вместе с `downloadLink` передан `onDownload`, переход по ссылке отменяется и вызывается только `onDownload`.
36
39
  */
37
40
  downloadLink?: string;
38
41
  /**
@@ -68,7 +71,9 @@ export interface FileUploadItemProps {
68
71
  */
69
72
  children?: ReactNode;
70
73
  /**
71
- * Обработчик загрузки файла
74
+ * Обработчик клика по кнопке скачивания файла.
75
+ * Если передан `onDownload` или `downloadLink`, отображается кнопка скачивания.
76
+ * Если вместе с `onDownload` передан `downloadLink`, переход по ссылке отменяется и вызывается только `onDownload`.
72
77
  */
73
78
  onDownload?: (id: string) => void;
74
79
  /**
@@ -2,29 +2,29 @@
2
2
  --color-light-text-tertiary: rgba(5, 8, 29, 0.38);
3
3
  --color-light-text-tertiary-hover: rgba(4, 4, 21, 0.47);
4
4
  }
5
- .file-upload-item__container_1bt7p {
5
+ .file-upload-item__container_5bu57 {
6
6
  display: flex;
7
7
  max-width: 144px;
8
8
  }
9
- .file-upload-item__container_1bt7p .file-upload-item__icon_1bt7p {
9
+ .file-upload-item__container_5bu57 .file-upload-item__icon_5bu57 {
10
10
  width: 48px;
11
11
  height: 48px;
12
12
  }
13
- .file-upload-item__deleteIconColor_1bt7p {
13
+ .file-upload-item__deleteIconColor_5bu57 {
14
14
  fill: var(--color-light-text-tertiary);
15
15
  }
16
- .file-upload-item__deleteIconColor_1bt7p:hover {
16
+ .file-upload-item__deleteIconColor_5bu57:hover {
17
17
  fill: var(--color-light-text-tertiary-hover);
18
18
  }
19
- .file-upload-item__downloadIconColor_1bt7p {
19
+ .file-upload-item__downloadIconColor_5bu57 {
20
20
  fill: var(--color-light-text-tertiary);
21
21
  }
22
- .file-upload-item__downloadIconColor_1bt7p:hover {
22
+ .file-upload-item__downloadIconColor_5bu57:hover {
23
23
  fill: var(--color-light-text-tertiary-hover);
24
24
  }
25
- .file-upload-item__restoreIconColor_1bt7p {
25
+ .file-upload-item__restoreIconColor_5bu57 {
26
26
  fill: var(--color-light-text-tertiary);
27
27
  }
28
- .file-upload-item__restoreIconColor_1bt7p:hover {
28
+ .file-upload-item__restoreIconColor_5bu57:hover {
29
29
  fill: var(--color-light-text-tertiary-hover);
30
30
  }
@@ -1,6 +1,6 @@
1
1
  import './actions-control.css';
2
2
 
3
- var styles = {"container":"file-upload-item__container_1bt7p","icon":"file-upload-item__icon_1bt7p","deleteIconColor":"file-upload-item__deleteIconColor_1bt7p","downloadIconColor":"file-upload-item__downloadIconColor_1bt7p","restoreIconColor":"file-upload-item__restoreIconColor_1bt7p"};
3
+ var styles = {"container":"file-upload-item__container_5bu57","icon":"file-upload-item__icon_5bu57","deleteIconColor":"file-upload-item__deleteIconColor_5bu57","downloadIconColor":"file-upload-item__downloadIconColor_5bu57","restoreIconColor":"file-upload-item__restoreIconColor_5bu57"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=actions-control.module.css.js.map
@@ -1,3 +1,3 @@
1
- .file-upload-item__errorItem_be3g5 {
1
+ .file-upload-item__errorItem_1naqo {
2
2
  display: block;
3
3
  }
@@ -1,6 +1,6 @@
1
1
  import './content-error.css';
2
2
 
3
- var styles = {"errorItem":"file-upload-item__errorItem_be3g5"};
3
+ var styles = {"errorItem":"file-upload-item__errorItem_1naqo"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=content-error.module.css.js.map
@@ -1,14 +1,14 @@
1
1
  :root {
2
2
  --gap-8: 8px;
3
3
  }
4
- .file-upload-item__subtitle_10fw3 {
4
+ .file-upload-item__subtitle_slym2 {
5
5
  display: block;
6
6
  }
7
- .file-upload-item__subtitle_10fw3.file-upload-item__truncate_10fw3 {
7
+ .file-upload-item__subtitle_slym2.file-upload-item__truncate_slym2 {
8
8
  white-space: nowrap;
9
9
  overflow: hidden;
10
10
  text-overflow: ellipsis;
11
11
  }
12
- .file-upload-item__size_10fw3 {
12
+ .file-upload-item__size_slym2 {
13
13
  margin-right: var(--gap-8);
14
14
  }
@@ -1,6 +1,6 @@
1
1
  import './content-subtitle.css';
2
2
 
3
- var styles = {"subtitle":"file-upload-item__subtitle_10fw3","truncate":"file-upload-item__truncate_10fw3","size":"file-upload-item__size_10fw3"};
3
+ var styles = {"subtitle":"file-upload-item__subtitle_slym2","truncate":"file-upload-item__truncate_slym2","size":"file-upload-item__size_slym2"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=content-subtitle.module.css.js.map
@@ -6,34 +6,34 @@
6
6
  --gap-4: 4px;
7
7
  --gap-16: 16px;
8
8
  }
9
- .file-upload-item__container_1ernq {
9
+ .file-upload-item__container_qrawo {
10
10
  padding: var(--gap-2) 0 0 var(--gap-16);
11
11
  flex-grow: 1;
12
12
  min-width: 0;
13
13
  }
14
- .file-upload-item__container_1ernq.file-upload-item__clickable_1ernq {
14
+ .file-upload-item__container_qrawo.file-upload-item__clickable_qrawo {
15
15
  cursor: pointer;
16
16
  }
17
- .file-upload-item__container_1ernq.file-upload-item__single_1ernq {
17
+ .file-upload-item__container_qrawo.file-upload-item__single_qrawo {
18
18
  display: flex;
19
19
  flex-direction: column;
20
20
  justify-content: center;
21
21
  padding-top: 0;
22
22
  min-height: 48px;
23
23
  }
24
- .file-upload-item__container_1ernq.file-upload-item__single_1ernq .file-upload-item__title_1ernq {
24
+ .file-upload-item__container_qrawo.file-upload-item__single_qrawo .file-upload-item__title_qrawo {
25
25
  margin-bottom: 0;
26
26
  }
27
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq {
27
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo {
28
28
  margin-bottom: var(--gap-4);
29
29
  display: block;
30
30
  overflow-wrap: break-word;
31
31
  }
32
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq.file-upload-item__truncate_1ernq {
32
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo.file-upload-item__truncate_qrawo {
33
33
  white-space: nowrap;
34
34
  overflow: hidden;
35
35
  text-overflow: ellipsis;
36
36
  }
37
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq.file-upload-item__restore_1ernq {
37
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo.file-upload-item__restore_qrawo {
38
38
  color: var(--color-light-text-tertiary);
39
39
  }
@@ -1,6 +1,6 @@
1
1
  import './content.css';
2
2
 
3
- var styles = {"container":"file-upload-item__container_1ernq","clickable":"file-upload-item__clickable_1ernq","single":"file-upload-item__single_1ernq","title":"file-upload-item__title_1ernq","truncate":"file-upload-item__truncate_1ernq","restore":"file-upload-item__restore_1ernq"};
3
+ var styles = {"container":"file-upload-item__container_qrawo","clickable":"file-upload-item__clickable_qrawo","single":"file-upload-item__single_qrawo","title":"file-upload-item__title_qrawo","truncate":"file-upload-item__truncate_qrawo","restore":"file-upload-item__restore_qrawo"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=content.module.css.js.map
@@ -8,21 +8,21 @@
8
8
  --color-light-decorative-orange: #fa9313;
9
9
  --color-light-decorative-red: #fe5e48;
10
10
  }
11
- .file-upload-item__iconPDFColored_g3v90 {
11
+ .file-upload-item__iconPDFColored_1cq84 {
12
12
  fill: var(--color-light-decorative-red);
13
13
  }
14
- .file-upload-item__iconDOCColored_g3v90 {
14
+ .file-upload-item__iconDOCColored_1cq84 {
15
15
  fill: var(--color-light-decorative-blue);
16
16
  }
17
- .file-upload-item__iconExcelColored_g3v90 {
17
+ .file-upload-item__iconExcelColored_1cq84 {
18
18
  fill: var(--color-light-decorative-green);
19
19
  }
20
- .file-upload-item__icon1CColored_g3v90 {
20
+ .file-upload-item__icon1CColored_1cq84 {
21
21
  fill: var(--color-light-decorative-orange);
22
22
  }
23
- .file-upload-item__iconDocumentColored_g3v90 {
23
+ .file-upload-item__iconDocumentColored_1cq84 {
24
24
  fill: var(--color-light-neutral-translucent-1300);
25
25
  }
26
- .file-upload-item__iconArchiveColored_g3v90 {
26
+ .file-upload-item__iconArchiveColored_1cq84 {
27
27
  fill: var(--color-light-status-attention);
28
28
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- var styles = {"iconPDFColored":"file-upload-item__iconPDFColored_g3v90","iconDOCColored":"file-upload-item__iconDOCColored_g3v90","iconExcelColored":"file-upload-item__iconExcelColored_g3v90","icon1CColored":"file-upload-item__icon1CColored_g3v90","iconDocumentColored":"file-upload-item__iconDocumentColored_g3v90","iconArchiveColored":"file-upload-item__iconArchiveColored_g3v90"};
3
+ var styles = {"iconPDFColored":"file-upload-item__iconPDFColored_1cq84","iconDOCColored":"file-upload-item__iconDOCColored_1cq84","iconExcelColored":"file-upload-item__iconExcelColored_1cq84","icon1CColored":"file-upload-item__icon1CColored_1cq84","iconDocumentColored":"file-upload-item__iconDocumentColored_1cq84","iconArchiveColored":"file-upload-item__iconArchiveColored_1cq84"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -6,30 +6,30 @@
6
6
  :root {
7
7
  --gap-4-neg: -4px;
8
8
  }
9
- .file-upload-item__container_1bh7t {
9
+ .file-upload-item__container_19efp {
10
10
  position: relative;
11
11
  }
12
- .file-upload-item__container_1bh7t.file-upload-item__clickable_1bh7t {
12
+ .file-upload-item__container_19efp.file-upload-item__clickable_19efp {
13
13
  cursor: pointer;
14
14
  }
15
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t {
15
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp {
16
16
  position: absolute;
17
17
  top: var(--gap-4-neg);
18
18
  left: var(--gap-4-neg);
19
19
  z-index: 1;
20
20
  will-change: opacity;
21
21
  }
22
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__success_1bh7t,
23
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__error_1bh7t {
22
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__success_19efp,
23
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__error_19efp {
24
24
  transition: opacity 400ms ease-in;
25
25
  opacity: 0;
26
26
  }
27
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__success_1bh7t path {
27
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__success_19efp path {
28
28
  stroke: var(--color-light-status-positive);
29
29
  }
30
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__loading_1bh7t {
30
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__loading_19efp {
31
31
  color: var(--color-light-neutral-500);
32
32
  }
33
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__error_1bh7t path {
33
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__error_19efp path {
34
34
  stroke: var(--color-light-status-negative);
35
35
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- var styles = {"container":"file-upload-item__container_1bh7t","clickable":"file-upload-item__clickable_1bh7t","progress":"file-upload-item__progress_1bh7t","success":"file-upload-item__success_1bh7t","error":"file-upload-item__error_1bh7t","loading":"file-upload-item__loading_1bh7t"};
3
+ var styles = {"container":"file-upload-item__container_19efp","clickable":"file-upload-item__clickable_19efp","progress":"file-upload-item__progress_19efp","success":"file-upload-item__success_19efp","error":"file-upload-item__error_19efp","loading":"file-upload-item__loading_19efp"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
package/esm/index.css CHANGED
@@ -2,14 +2,14 @@
2
2
  --gap-2: 2px;
3
3
  --gap-12: 12px;
4
4
  }
5
- .file-upload-item__component_6rnhl {
5
+ .file-upload-item__component_13o9f {
6
6
  box-sizing: border-box;
7
7
  display: flex;
8
8
  align-items: flex-start;
9
9
  width: 100%;
10
10
  min-height: 48px;
11
11
  }
12
- .file-upload-item__restore_6rnhl {
12
+ .file-upload-item__restore_13o9f {
13
13
  margin-left: var(--gap-12);
14
14
  margin-top: var(--gap-2);
15
15
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- var styles = {"component":"file-upload-item__component_6rnhl","restore":"file-upload-item__restore_6rnhl"};
3
+ var styles = {"component":"file-upload-item__component_13o9f","restore":"file-upload-item__restore_13o9f"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -32,7 +32,10 @@ export interface FileUploadItemProps {
32
32
  */
33
33
  uploadDate?: string;
34
34
  /**
35
- * Ссылка на файл. Если прокидывается этот параметр, то появляется кнопка скачивания
35
+ * Ссылка на файл.
36
+ * Если передан `downloadLink` или `onDownload`, отображается кнопка скачивания.
37
+ * По клику на кнопку браузер переходит по ссылке (или скачивает файл, если передан `download`).
38
+ * Если вместе с `downloadLink` передан `onDownload`, переход по ссылке отменяется и вызывается только `onDownload`.
36
39
  */
37
40
  downloadLink?: string;
38
41
  /**
@@ -68,7 +71,9 @@ export interface FileUploadItemProps {
68
71
  */
69
72
  children?: ReactNode;
70
73
  /**
71
- * Обработчик загрузки файла
74
+ * Обработчик клика по кнопке скачивания файла.
75
+ * Если передан `onDownload` или `downloadLink`, отображается кнопка скачивания.
76
+ * Если вместе с `onDownload` передан `downloadLink`, переход по ссылке отменяется и вызывается только `onDownload`.
72
77
  */
73
78
  onDownload?: (id: string) => void;
74
79
  /**
package/index.css CHANGED
@@ -2,14 +2,14 @@
2
2
  --gap-2: 2px;
3
3
  --gap-12: 12px;
4
4
  }
5
- .file-upload-item__component_6rnhl {
5
+ .file-upload-item__component_13o9f {
6
6
  box-sizing: border-box;
7
7
  display: flex;
8
8
  align-items: flex-start;
9
9
  width: 100%;
10
10
  min-height: 48px;
11
11
  }
12
- .file-upload-item__restore_6rnhl {
12
+ .file-upload-item__restore_13o9f {
13
13
  margin-left: var(--gap-12);
14
14
  margin-top: var(--gap-2);
15
15
  }
@@ -2,7 +2,7 @@
2
2
 
3
3
  require('./index.css');
4
4
 
5
- var styles = {"component":"file-upload-item__component_6rnhl","restore":"file-upload-item__restore_6rnhl"};
5
+ var styles = {"component":"file-upload-item__component_13o9f","restore":"file-upload-item__restore_13o9f"};
6
6
 
7
7
  module.exports = styles;
8
8
  //# sourceMappingURL=index.module.css.js.map
@@ -2,29 +2,29 @@
2
2
  --color-light-text-tertiary: rgba(5, 8, 29, 0.38);
3
3
  --color-light-text-tertiary-hover: rgba(4, 4, 21, 0.47);
4
4
  }
5
- .file-upload-item__container_1bt7p {
5
+ .file-upload-item__container_5bu57 {
6
6
  display: flex;
7
7
  max-width: 144px;
8
8
  }
9
- .file-upload-item__container_1bt7p .file-upload-item__icon_1bt7p {
9
+ .file-upload-item__container_5bu57 .file-upload-item__icon_5bu57 {
10
10
  width: 48px;
11
11
  height: 48px;
12
12
  }
13
- .file-upload-item__deleteIconColor_1bt7p {
13
+ .file-upload-item__deleteIconColor_5bu57 {
14
14
  fill: var(--color-light-text-tertiary);
15
15
  }
16
- .file-upload-item__deleteIconColor_1bt7p:hover {
16
+ .file-upload-item__deleteIconColor_5bu57:hover {
17
17
  fill: var(--color-light-text-tertiary-hover);
18
18
  }
19
- .file-upload-item__downloadIconColor_1bt7p {
19
+ .file-upload-item__downloadIconColor_5bu57 {
20
20
  fill: var(--color-light-text-tertiary);
21
21
  }
22
- .file-upload-item__downloadIconColor_1bt7p:hover {
22
+ .file-upload-item__downloadIconColor_5bu57:hover {
23
23
  fill: var(--color-light-text-tertiary-hover);
24
24
  }
25
- .file-upload-item__restoreIconColor_1bt7p {
25
+ .file-upload-item__restoreIconColor_5bu57 {
26
26
  fill: var(--color-light-text-tertiary);
27
27
  }
28
- .file-upload-item__restoreIconColor_1bt7p:hover {
28
+ .file-upload-item__restoreIconColor_5bu57:hover {
29
29
  fill: var(--color-light-text-tertiary-hover);
30
30
  }
@@ -1,6 +1,6 @@
1
1
  import './actions-control.css';
2
2
 
3
- const styles = {"container":"file-upload-item__container_1bt7p","icon":"file-upload-item__icon_1bt7p","deleteIconColor":"file-upload-item__deleteIconColor_1bt7p","downloadIconColor":"file-upload-item__downloadIconColor_1bt7p","restoreIconColor":"file-upload-item__restoreIconColor_1bt7p"};
3
+ const styles = {"container":"file-upload-item__container_5bu57","icon":"file-upload-item__icon_5bu57","deleteIconColor":"file-upload-item__deleteIconColor_5bu57","downloadIconColor":"file-upload-item__downloadIconColor_5bu57","restoreIconColor":"file-upload-item__restoreIconColor_5bu57"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=actions-control.module.css.js.map
@@ -1,3 +1,3 @@
1
- .file-upload-item__errorItem_be3g5 {
1
+ .file-upload-item__errorItem_1naqo {
2
2
  display: block;
3
3
  }
@@ -1,6 +1,6 @@
1
1
  import './content-error.css';
2
2
 
3
- const styles = {"errorItem":"file-upload-item__errorItem_be3g5"};
3
+ const styles = {"errorItem":"file-upload-item__errorItem_1naqo"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=content-error.module.css.js.map
@@ -1,14 +1,14 @@
1
1
  :root {
2
2
  --gap-8: 8px;
3
3
  }
4
- .file-upload-item__subtitle_10fw3 {
4
+ .file-upload-item__subtitle_slym2 {
5
5
  display: block;
6
6
  }
7
- .file-upload-item__subtitle_10fw3.file-upload-item__truncate_10fw3 {
7
+ .file-upload-item__subtitle_slym2.file-upload-item__truncate_slym2 {
8
8
  white-space: nowrap;
9
9
  overflow: hidden;
10
10
  text-overflow: ellipsis;
11
11
  }
12
- .file-upload-item__size_10fw3 {
12
+ .file-upload-item__size_slym2 {
13
13
  margin-right: var(--gap-8);
14
14
  }
@@ -1,6 +1,6 @@
1
1
  import './content-subtitle.css';
2
2
 
3
- const styles = {"subtitle":"file-upload-item__subtitle_10fw3","truncate":"file-upload-item__truncate_10fw3","size":"file-upload-item__size_10fw3"};
3
+ const styles = {"subtitle":"file-upload-item__subtitle_slym2","truncate":"file-upload-item__truncate_slym2","size":"file-upload-item__size_slym2"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=content-subtitle.module.css.js.map
@@ -6,34 +6,34 @@
6
6
  --gap-4: 4px;
7
7
  --gap-16: 16px;
8
8
  }
9
- .file-upload-item__container_1ernq {
9
+ .file-upload-item__container_qrawo {
10
10
  padding: var(--gap-2) 0 0 var(--gap-16);
11
11
  flex-grow: 1;
12
12
  min-width: 0;
13
13
  }
14
- .file-upload-item__container_1ernq.file-upload-item__clickable_1ernq {
14
+ .file-upload-item__container_qrawo.file-upload-item__clickable_qrawo {
15
15
  cursor: pointer;
16
16
  }
17
- .file-upload-item__container_1ernq.file-upload-item__single_1ernq {
17
+ .file-upload-item__container_qrawo.file-upload-item__single_qrawo {
18
18
  display: flex;
19
19
  flex-direction: column;
20
20
  justify-content: center;
21
21
  padding-top: 0;
22
22
  min-height: 48px;
23
23
  }
24
- .file-upload-item__container_1ernq.file-upload-item__single_1ernq .file-upload-item__title_1ernq {
24
+ .file-upload-item__container_qrawo.file-upload-item__single_qrawo .file-upload-item__title_qrawo {
25
25
  margin-bottom: 0;
26
26
  }
27
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq {
27
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo {
28
28
  margin-bottom: var(--gap-4);
29
29
  display: block;
30
30
  overflow-wrap: break-word;
31
31
  }
32
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq.file-upload-item__truncate_1ernq {
32
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo.file-upload-item__truncate_qrawo {
33
33
  white-space: nowrap;
34
34
  overflow: hidden;
35
35
  text-overflow: ellipsis;
36
36
  }
37
- .file-upload-item__container_1ernq .file-upload-item__title_1ernq.file-upload-item__restore_1ernq {
37
+ .file-upload-item__container_qrawo .file-upload-item__title_qrawo.file-upload-item__restore_qrawo {
38
38
  color: var(--color-light-text-tertiary);
39
39
  }
@@ -1,6 +1,6 @@
1
1
  import './content.css';
2
2
 
3
- const styles = {"container":"file-upload-item__container_1ernq","clickable":"file-upload-item__clickable_1ernq","single":"file-upload-item__single_1ernq","title":"file-upload-item__title_1ernq","truncate":"file-upload-item__truncate_1ernq","restore":"file-upload-item__restore_1ernq"};
3
+ const styles = {"container":"file-upload-item__container_qrawo","clickable":"file-upload-item__clickable_qrawo","single":"file-upload-item__single_qrawo","title":"file-upload-item__title_qrawo","truncate":"file-upload-item__truncate_qrawo","restore":"file-upload-item__restore_qrawo"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=content.module.css.js.map
@@ -8,21 +8,21 @@
8
8
  --color-light-decorative-orange: #fa9313;
9
9
  --color-light-decorative-red: #fe5e48;
10
10
  }
11
- .file-upload-item__iconPDFColored_g3v90 {
11
+ .file-upload-item__iconPDFColored_1cq84 {
12
12
  fill: var(--color-light-decorative-red);
13
13
  }
14
- .file-upload-item__iconDOCColored_g3v90 {
14
+ .file-upload-item__iconDOCColored_1cq84 {
15
15
  fill: var(--color-light-decorative-blue);
16
16
  }
17
- .file-upload-item__iconExcelColored_g3v90 {
17
+ .file-upload-item__iconExcelColored_1cq84 {
18
18
  fill: var(--color-light-decorative-green);
19
19
  }
20
- .file-upload-item__icon1CColored_g3v90 {
20
+ .file-upload-item__icon1CColored_1cq84 {
21
21
  fill: var(--color-light-decorative-orange);
22
22
  }
23
- .file-upload-item__iconDocumentColored_g3v90 {
23
+ .file-upload-item__iconDocumentColored_1cq84 {
24
24
  fill: var(--color-light-neutral-translucent-1300);
25
25
  }
26
- .file-upload-item__iconArchiveColored_g3v90 {
26
+ .file-upload-item__iconArchiveColored_1cq84 {
27
27
  fill: var(--color-light-status-attention);
28
28
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- const styles = {"iconPDFColored":"file-upload-item__iconPDFColored_g3v90","iconDOCColored":"file-upload-item__iconDOCColored_g3v90","iconExcelColored":"file-upload-item__iconExcelColored_g3v90","icon1CColored":"file-upload-item__icon1CColored_g3v90","iconDocumentColored":"file-upload-item__iconDocumentColored_g3v90","iconArchiveColored":"file-upload-item__iconArchiveColored_g3v90"};
3
+ const styles = {"iconPDFColored":"file-upload-item__iconPDFColored_1cq84","iconDOCColored":"file-upload-item__iconDOCColored_1cq84","iconExcelColored":"file-upload-item__iconExcelColored_1cq84","icon1CColored":"file-upload-item__icon1CColored_1cq84","iconDocumentColored":"file-upload-item__iconDocumentColored_1cq84","iconArchiveColored":"file-upload-item__iconArchiveColored_1cq84"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -6,30 +6,30 @@
6
6
  :root {
7
7
  --gap-4-neg: -4px;
8
8
  }
9
- .file-upload-item__container_1bh7t {
9
+ .file-upload-item__container_19efp {
10
10
  position: relative;
11
11
  }
12
- .file-upload-item__container_1bh7t.file-upload-item__clickable_1bh7t {
12
+ .file-upload-item__container_19efp.file-upload-item__clickable_19efp {
13
13
  cursor: pointer;
14
14
  }
15
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t {
15
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp {
16
16
  position: absolute;
17
17
  top: var(--gap-4-neg);
18
18
  left: var(--gap-4-neg);
19
19
  z-index: 1;
20
20
  will-change: opacity;
21
21
  }
22
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__success_1bh7t,
23
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__error_1bh7t {
22
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__success_19efp,
23
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__error_19efp {
24
24
  transition: opacity 400ms ease-in;
25
25
  opacity: 0;
26
26
  }
27
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__success_1bh7t path {
27
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__success_19efp path {
28
28
  stroke: var(--color-light-status-positive);
29
29
  }
30
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__loading_1bh7t {
30
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__loading_19efp {
31
31
  color: var(--color-light-neutral-500);
32
32
  }
33
- .file-upload-item__container_1bh7t .file-upload-item__progress_1bh7t.file-upload-item__error_1bh7t path {
33
+ .file-upload-item__container_19efp .file-upload-item__progress_19efp.file-upload-item__error_19efp path {
34
34
  stroke: var(--color-light-status-negative);
35
35
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- const styles = {"container":"file-upload-item__container_1bh7t","clickable":"file-upload-item__clickable_1bh7t","progress":"file-upload-item__progress_1bh7t","success":"file-upload-item__success_1bh7t","error":"file-upload-item__error_1bh7t","loading":"file-upload-item__loading_1bh7t"};
3
+ const styles = {"container":"file-upload-item__container_19efp","clickable":"file-upload-item__clickable_19efp","progress":"file-upload-item__progress_19efp","success":"file-upload-item__success_19efp","error":"file-upload-item__error_19efp","loading":"file-upload-item__loading_19efp"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
package/modern/index.css CHANGED
@@ -2,14 +2,14 @@
2
2
  --gap-2: 2px;
3
3
  --gap-12: 12px;
4
4
  }
5
- .file-upload-item__component_6rnhl {
5
+ .file-upload-item__component_13o9f {
6
6
  box-sizing: border-box;
7
7
  display: flex;
8
8
  align-items: flex-start;
9
9
  width: 100%;
10
10
  min-height: 48px;
11
11
  }
12
- .file-upload-item__restore_6rnhl {
12
+ .file-upload-item__restore_13o9f {
13
13
  margin-left: var(--gap-12);
14
14
  margin-top: var(--gap-2);
15
15
  }
@@ -1,6 +1,6 @@
1
1
  import './index.css';
2
2
 
3
- const styles = {"component":"file-upload-item__component_6rnhl","restore":"file-upload-item__restore_6rnhl"};
3
+ const styles = {"component":"file-upload-item__component_13o9f","restore":"file-upload-item__restore_13o9f"};
4
4
 
5
5
  export { styles as default };
6
6
  //# sourceMappingURL=index.module.css.js.map
@@ -32,7 +32,10 @@ export interface FileUploadItemProps {
32
32
  */
33
33
  uploadDate?: string;
34
34
  /**
35
- * Ссылка на файл. Если прокидывается этот параметр, то появляется кнопка скачивания
35
+ * Ссылка на файл.
36
+ * Если передан `downloadLink` или `onDownload`, отображается кнопка скачивания.
37
+ * По клику на кнопку браузер переходит по ссылке (или скачивает файл, если передан `download`).
38
+ * Если вместе с `downloadLink` передан `onDownload`, переход по ссылке отменяется и вызывается только `onDownload`.
36
39
  */
37
40
  downloadLink?: string;
38
41
  /**
@@ -68,7 +71,9 @@ export interface FileUploadItemProps {
68
71
  */
69
72
  children?: ReactNode;
70
73
  /**
71
- * Обработчик загрузки файла
74
+ * Обработчик клика по кнопке скачивания файла.
75
+ * Если передан `onDownload` или `downloadLink`, отображается кнопка скачивания.
76
+ * Если вместе с `onDownload` передан `downloadLink`, переход по ссылке отменяется и вызывается только `onDownload`.
72
77
  */
73
78
  onDownload?: (id: string) => void;
74
79
  /**
@@ -32,7 +32,10 @@ export interface FileUploadItemProps {
32
32
  */
33
33
  uploadDate?: string;
34
34
  /**
35
- * Ссылка на файл. Если прокидывается этот параметр, то появляется кнопка скачивания
35
+ * Ссылка на файл.
36
+ * Если передан `downloadLink` или `onDownload`, отображается кнопка скачивания.
37
+ * По клику на кнопку браузер переходит по ссылке (или скачивает файл, если передан `download`).
38
+ * Если вместе с `downloadLink` передан `onDownload`, переход по ссылке отменяется и вызывается только `onDownload`.
36
39
  */
37
40
  downloadLink?: string;
38
41
  /**
@@ -68,7 +71,9 @@ export interface FileUploadItemProps {
68
71
  */
69
72
  children?: ReactNode;
70
73
  /**
71
- * Обработчик загрузки файла
74
+ * Обработчик клика по кнопке скачивания файла.
75
+ * Если передан `onDownload` или `downloadLink`, отображается кнопка скачивания.
76
+ * Если вместе с `onDownload` передан `downloadLink`, переход по ссылке отменяется и вызывается только `onDownload`.
72
77
  */
73
78
  onDownload?: (id: string) => void;
74
79
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfalab/core-components-file-upload-item",
3
- "version": "8.2.3-alfasans",
3
+ "version": "8.2.4",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "license": "MIT",
@@ -13,10 +13,10 @@
13
13
  "build": "rollup -c ../../tools/rollup/rollup.config.mjs --silent"
14
14
  },
15
15
  "dependencies": {
16
- "@alfalab/core-components-icon-button": "8.0.12-alfasans",
17
- "@alfalab/core-components-icon-view": "5.0.4-alfasans",
18
- "@alfalab/core-components-shared": "2.3.0-alfasans",
19
- "@alfalab/core-components-typography": "6.0.13-alfasans",
16
+ "@alfalab/core-components-icon-button": "^8.0.12",
17
+ "@alfalab/core-components-icon-view": "^5.0.4",
18
+ "@alfalab/core-components-shared": "^2.3.0",
19
+ "@alfalab/core-components-typography": "^6.0.13",
20
20
  "@alfalab/hooks": "^1.17.0",
21
21
  "@alfalab/icons-glyph": "^2.260.0",
22
22
  "classnames": "^2.5.1",
@@ -30,6 +30,6 @@
30
30
  "access": "public",
31
31
  "directory": "dist"
32
32
  },
33
- "themesVersion": "15.2.1-alfasans",
34
- "varsVersion": "11.4.0-alfasans"
33
+ "themesVersion": "15.2.1",
34
+ "varsVersion": "11.4.1"
35
35
  }
@@ -47,7 +47,10 @@ export interface FileUploadItemProps {
47
47
  uploadDate?: string;
48
48
 
49
49
  /**
50
- * Ссылка на файл. Если прокидывается этот параметр, то появляется кнопка скачивания
50
+ * Ссылка на файл.
51
+ * Если передан `downloadLink` или `onDownload`, отображается кнопка скачивания.
52
+ * По клику на кнопку браузер переходит по ссылке (или скачивает файл, если передан `download`).
53
+ * Если вместе с `downloadLink` передан `onDownload`, переход по ссылке отменяется и вызывается только `onDownload`.
51
54
  */
52
55
  downloadLink?: string;
53
56
 
@@ -93,7 +96,9 @@ export interface FileUploadItemProps {
93
96
  children?: ReactNode;
94
97
 
95
98
  /**
96
- * Обработчик загрузки файла
99
+ * Обработчик клика по кнопке скачивания файла.
100
+ * Если передан `onDownload` или `downloadLink`, отображается кнопка скачивания.
101
+ * Если вместе с `onDownload` передан `downloadLink`, переход по ссылке отменяется и вызывается только `onDownload`.
97
102
  */
98
103
  onDownload?: (id: string) => void;
99
104
 
@@ -32,7 +32,10 @@ export interface FileUploadItemProps {
32
32
  */
33
33
  uploadDate?: string;
34
34
  /**
35
- * Ссылка на файл. Если прокидывается этот параметр, то появляется кнопка скачивания
35
+ * Ссылка на файл.
36
+ * Если передан `downloadLink` или `onDownload`, отображается кнопка скачивания.
37
+ * По клику на кнопку браузер переходит по ссылке (или скачивает файл, если передан `download`).
38
+ * Если вместе с `downloadLink` передан `onDownload`, переход по ссылке отменяется и вызывается только `onDownload`.
36
39
  */
37
40
  downloadLink?: string;
38
41
  /**
@@ -68,7 +71,9 @@ export interface FileUploadItemProps {
68
71
  */
69
72
  children?: ReactNode;
70
73
  /**
71
- * Обработчик загрузки файла
74
+ * Обработчик клика по кнопке скачивания файла.
75
+ * Если передан `onDownload` или `downloadLink`, отображается кнопка скачивания.
76
+ * Если вместе с `onDownload` передан `downloadLink`, переход по ссылке отменяется и вызывается только `onDownload`.
72
77
  */
73
78
  onDownload?: (id: string) => void;
74
79
  /**