@box/item-icon 2.11.6 → 2.12.0
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.
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as e from "@box/blueprint-web-assets/icons/Content";
|
|
2
|
-
import { RelayAdvanced as
|
|
3
|
-
import {
|
|
4
|
-
|
|
2
|
+
import { RelayAdvanced as F, AgentCustomExtract as c } from "@box/blueprint-web-assets/icons/Logo";
|
|
3
|
+
import { Element as p } from "@box/blueprint-web-assets/icons/Medium";
|
|
4
|
+
import { jsx as h } from "react/jsx-runtime";
|
|
5
|
+
const m = {
|
|
5
6
|
archive: e.Archive,
|
|
6
7
|
audio: e.FileAudio,
|
|
7
8
|
bookmark: e.FileBookmark,
|
|
@@ -14,7 +15,7 @@ const c = {
|
|
|
14
15
|
"docuworks-file": e.FileXdw,
|
|
15
16
|
dwg: e.FileDwg,
|
|
16
17
|
"excel-spreadsheet": e.FileExcel,
|
|
17
|
-
extract_agent:
|
|
18
|
+
extract_agent: c,
|
|
18
19
|
"file-variable": e.FileVariable,
|
|
19
20
|
"folder-archive": e.FolderArchive,
|
|
20
21
|
"folder-collab": e.FolderShared,
|
|
@@ -40,28 +41,29 @@ const c = {
|
|
|
40
41
|
vector: e.FileVector,
|
|
41
42
|
video: e.FileVideo,
|
|
42
43
|
"word-document": e.FileWord,
|
|
43
|
-
workflow:
|
|
44
|
+
workflow: F,
|
|
44
45
|
zip: e.FileZip
|
|
45
|
-
},
|
|
46
|
+
}, b = ({
|
|
46
47
|
ariaHidden: l,
|
|
47
48
|
ariaLabel: i,
|
|
48
49
|
className: r,
|
|
49
50
|
dimension: o = 32,
|
|
50
51
|
iconType: t,
|
|
51
|
-
|
|
52
|
+
isAppItem: a,
|
|
53
|
+
title: d
|
|
52
54
|
}) => {
|
|
53
|
-
const
|
|
54
|
-
return /* @__PURE__ */
|
|
55
|
+
const n = a ? p : e.FileDefault, s = m[t] || n;
|
|
56
|
+
return /* @__PURE__ */ h(s, {
|
|
55
57
|
"aria-hidden": l,
|
|
56
58
|
"aria-label": i,
|
|
57
59
|
className: r,
|
|
58
60
|
height: o,
|
|
59
|
-
title:
|
|
61
|
+
title: d,
|
|
60
62
|
width: o
|
|
61
63
|
});
|
|
62
64
|
};
|
|
63
65
|
export {
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
66
|
+
b as ItemIcon,
|
|
67
|
+
b as default,
|
|
68
|
+
m as itemIconTable
|
|
67
69
|
};
|
|
@@ -52,8 +52,10 @@ export interface ItemIconProps {
|
|
|
52
52
|
dimension?: number | string;
|
|
53
53
|
/** Type of item icon, defaults to the default icon if icon type is not recognized */
|
|
54
54
|
iconType: keyof typeof itemIconTable | string;
|
|
55
|
+
/** A bool flag to handle default icons */
|
|
56
|
+
isAppItem?: boolean;
|
|
55
57
|
/** A text-only string describing the icon if it's not purely decorative for accessibility */
|
|
56
58
|
title?: string | React.ReactNode;
|
|
57
59
|
}
|
|
58
|
-
export declare const ItemIcon: ({ ariaHidden, ariaLabel, className, dimension, iconType, title }: ItemIconProps) => import("react/jsx-runtime").JSX.Element;
|
|
60
|
+
export declare const ItemIcon: ({ ariaHidden, ariaLabel, className, dimension, iconType, isAppItem, title, }: ItemIconProps) => import("react/jsx-runtime").JSX.Element;
|
|
59
61
|
export default ItemIcon;
|