@hive-ui/icons 0.1.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.
@@ -0,0 +1,18 @@
1
+ import { IconWrapperProps } from "./helpers/IconWrapper.mjs";
2
+ import * as _$react from "react";
3
+ import * as _$_hive_ui_box0 from "@hive-ui/box";
4
+ import * as _$_hive_ui_style_props0 from "@hive-ui/style-props";
5
+
6
+ //#region src/ArrowForwardIcon.d.ts
7
+ type ArrowForwardIconProps = IconWrapperProps & {
8
+ title?: string;
9
+ decorative: boolean;
10
+ };
11
+ declare const ArrowForwardIcon: _$react.ForwardRefExoticComponent<Pick<_$_hive_ui_box0.BoxProps<"span">, "as" | "children" | "color" | "display" | "element"> & {
12
+ size?: _$_hive_ui_style_props0.IconSize;
13
+ } & {
14
+ title?: string;
15
+ decorative: boolean;
16
+ } & _$react.RefAttributes<HTMLElement>>;
17
+ //#endregion
18
+ export { ArrowForwardIcon, ArrowForwardIconProps };
@@ -0,0 +1,36 @@
1
+ import { IconWrapper } from "./helpers/IconWrapper.mjs";
2
+ import { forwardRef, useId } from "react";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
+ //#region src/ArrowForwardIcon.tsx
5
+ const ArrowForwardIcon = forwardRef(({ as, display, element = "ICON", size, color, title, decorative }, ref) => {
6
+ const titleId = `ArrowForwardIcon-${useId()}`;
7
+ if (!decorative && title == null) throw new Error("[ArrowForwardIcon]: Missing a title for non-decorative icon.");
8
+ return /* @__PURE__ */ jsx(IconWrapper, {
9
+ as,
10
+ display,
11
+ element,
12
+ size,
13
+ color,
14
+ ref,
15
+ children: /* @__PURE__ */ jsxs("svg", {
16
+ role: "img",
17
+ "aria-hidden": decorative,
18
+ xmlns: "http://www.w3.org/2000/svg",
19
+ width: "100%",
20
+ height: "100%",
21
+ viewBox: "0 0 20 20",
22
+ "aria-labelledby": titleId,
23
+ children: [title ? /* @__PURE__ */ jsx("title", {
24
+ id: titleId,
25
+ children: title
26
+ }) : null, /* @__PURE__ */ jsx("path", {
27
+ fill: "currentColor",
28
+ fillRule: "evenodd",
29
+ d: "M14.991 9.91l.007.05v.08l-.01.07-.01.029a.489.489 0 01-.205.272l-3.832 3.444a.596.596 0 01-.78 0 .459.459 0 01-.063-.632l.063-.069 2.957-2.659H5.513A.504.504 0 015 10a.5.5 0 01.42-.488l.093-.008h7.604l-2.956-2.658a.459.459 0 01-.063-.632l.063-.069a.598.598 0 01.704-.057l.076.057 3.832 3.444c.098.064.172.16.206.272l.012.049z"
30
+ })]
31
+ })
32
+ });
33
+ });
34
+ ArrowForwardIcon.displayName = "ArrowForwardIcon";
35
+ //#endregion
36
+ export { ArrowForwardIcon };
@@ -0,0 +1,18 @@
1
+ import { IconWrapperProps } from "./helpers/IconWrapper.mjs";
2
+ import * as _$react from "react";
3
+ import * as _$_hive_ui_box0 from "@hive-ui/box";
4
+ import * as _$_hive_ui_style_props0 from "@hive-ui/style-props";
5
+
6
+ //#region src/ChevronDisclosureIcon.d.ts
7
+ type ChevronDisclosureIconProps = IconWrapperProps & {
8
+ title?: string;
9
+ decorative: boolean;
10
+ };
11
+ declare const ChevronDisclosureIcon: _$react.ForwardRefExoticComponent<Pick<_$_hive_ui_box0.BoxProps<"span">, "as" | "children" | "color" | "display" | "element"> & {
12
+ size?: _$_hive_ui_style_props0.IconSize;
13
+ } & {
14
+ title?: string;
15
+ decorative: boolean;
16
+ } & _$react.RefAttributes<HTMLElement>>;
17
+ //#endregion
18
+ export { ChevronDisclosureIcon, ChevronDisclosureIconProps };
@@ -0,0 +1,37 @@
1
+ import { IconWrapper } from "./helpers/IconWrapper.mjs";
2
+ import { forwardRef, useId } from "react";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
+ //#region src/ChevronDisclosureIcon.tsx
5
+ const ChevronDisclosureIcon = forwardRef(({ as, display, element = "ICON", size, color, title, decorative }, ref) => {
6
+ const titleId = `ChevronDisclosureIcon-${useId()}`;
7
+ if (!decorative && title == null) throw new Error("[ChevronDisclosureIcon]: Missing a title for non-decorative icon.");
8
+ return /* @__PURE__ */ jsx(IconWrapper, {
9
+ as,
10
+ display,
11
+ element,
12
+ size,
13
+ color,
14
+ ref,
15
+ children: /* @__PURE__ */ jsxs("svg", {
16
+ role: "img",
17
+ "aria-hidden": decorative,
18
+ width: "100%",
19
+ height: "100%",
20
+ viewBox: "0 0 20 20",
21
+ fill: "none",
22
+ "aria-labelledby": titleId,
23
+ children: [title ? /* @__PURE__ */ jsx("title", {
24
+ id: titleId,
25
+ children: title
26
+ }) : null, /* @__PURE__ */ jsx("path", {
27
+ fill: "currentColor",
28
+ fillRule: "evenodd",
29
+ clipRule: "evenodd",
30
+ d: "M9.707 6.293a1 1 0 00-1.497 1.32l.083.094L10.585 10l-2.292 2.293a1 1 0 00-.083 1.32l.083.094a1 1 0 001.32.083l.094-.083 3-3a1 1 0 00.083-1.32l-.083-.094-3-3z"
31
+ })]
32
+ })
33
+ });
34
+ });
35
+ ChevronDisclosureIcon.displayName = "ChevronDisclosureIcon";
36
+ //#endregion
37
+ export { ChevronDisclosureIcon };
@@ -0,0 +1,18 @@
1
+ import { IconWrapperProps } from "./helpers/IconWrapper.mjs";
2
+ import * as _$react from "react";
3
+ import * as _$_hive_ui_box0 from "@hive-ui/box";
4
+ import * as _$_hive_ui_style_props0 from "@hive-ui/style-props";
5
+
6
+ //#region src/LinkExternalIcon.d.ts
7
+ type LinkExternalIconProps = IconWrapperProps & {
8
+ title?: string;
9
+ decorative: boolean;
10
+ };
11
+ declare const LinkExternalIcon: _$react.ForwardRefExoticComponent<Pick<_$_hive_ui_box0.BoxProps<"span">, "as" | "children" | "color" | "display" | "element"> & {
12
+ size?: _$_hive_ui_style_props0.IconSize;
13
+ } & {
14
+ title?: string;
15
+ decorative: boolean;
16
+ } & _$react.RefAttributes<HTMLElement>>;
17
+ //#endregion
18
+ export { LinkExternalIcon, LinkExternalIconProps };
@@ -0,0 +1,36 @@
1
+ import { IconWrapper } from "./helpers/IconWrapper.mjs";
2
+ import { forwardRef, useId } from "react";
3
+ import { jsx, jsxs } from "react/jsx-runtime";
4
+ //#region src/LinkExternalIcon.tsx
5
+ const LinkExternalIcon = forwardRef(({ as, display, element = "ICON", size, color, title, decorative }, ref) => {
6
+ const titleId = `LinkExternalIcon-${useId()}`;
7
+ if (!decorative && title == null) throw new Error("[LinkExternalIcon]: Missing a title for non-decorative icon.");
8
+ return /* @__PURE__ */ jsx(IconWrapper, {
9
+ as,
10
+ display,
11
+ element,
12
+ size,
13
+ color,
14
+ ref,
15
+ children: /* @__PURE__ */ jsxs("svg", {
16
+ role: "img",
17
+ "aria-hidden": decorative,
18
+ xmlns: "http://www.w3.org/2000/svg",
19
+ width: "100%",
20
+ height: "100%",
21
+ viewBox: "0 0 20 20",
22
+ "aria-labelledby": titleId,
23
+ children: [title ? /* @__PURE__ */ jsx("title", {
24
+ id: titleId,
25
+ children: title
26
+ }) : null, /* @__PURE__ */ jsx("path", {
27
+ fill: "currentColor",
28
+ fillRule: "evenodd",
29
+ d: "M8.4 4.5a.5.5 0 01.5.5v.1a.5.5 0 01-.5.5H5.6v8.8h8.8v-2.8a.5.5 0 01.41-.492l.09-.008h.1a.5.5 0 01.492.41l.008.09V15a.5.5 0 01-.41.492L15 15.5H5a.5.5 0 01-.492-.41L4.5 15V5a.5.5 0 01.41-.492L5 4.5h3.4zm6.6 0a.5.5 0 01.5.5v.1l-.001.01.001 3.29a.5.5 0 01-.5.5h-.1a.5.5 0 01-.5-.5l-.001-1.935-3.967 3.967a.611.611 0 01-.78.07l-.084-.07a.611.611 0 01-.07-.78l.07-.084L13.534 5.6H11.6a.5.5 0 01-.5-.5V5a.5.5 0 01.5-.5H15z"
30
+ })]
31
+ })
32
+ });
33
+ });
34
+ LinkExternalIcon.displayName = "LinkExternalIcon";
35
+ //#endregion
36
+ export { LinkExternalIcon };
@@ -0,0 +1,16 @@
1
+ import { BoxProps } from "@hive-ui/box";
2
+ import { IconSize } from "@hive-ui/style-props";
3
+
4
+ //#region src/helpers/IconWrapper.d.ts
5
+ type IconWrapperProps = Pick<BoxProps<"span">, "as" | "element" | "color" | "display" | "children"> & {
6
+ /**
7
+ * Sets the size of the icon.
8
+ *
9
+ * @default "sizeIcon30"
10
+ * @type {IconSize}
11
+ * @memberof IconWrapperProps
12
+ */
13
+ size?: IconSize;
14
+ };
15
+ //#endregion
16
+ export { IconWrapperProps };
@@ -0,0 +1,18 @@
1
+ import { forwardRef } from "react";
2
+ import { Box } from "@hive-ui/box";
3
+ import { jsx } from "react/jsx-runtime";
4
+ //#region src/helpers/IconWrapper.tsx
5
+ const IconWrapper = forwardRef(({ as = "span", color = "currentColor", display = "block", element = "ICON", size = "sizeIcon30", ...props }, ref) => /* @__PURE__ */ jsx(Box, {
6
+ ...props,
7
+ as,
8
+ element,
9
+ lineHeight: "lineHeight0",
10
+ display,
11
+ color,
12
+ size,
13
+ ref,
14
+ flexShrink: 0
15
+ }));
16
+ IconWrapper.displayName = "IconWrapper";
17
+ //#endregion
18
+ export { IconWrapper };
@@ -0,0 +1,4 @@
1
+ import { ArrowForwardIcon, ArrowForwardIconProps } from "./ArrowForwardIcon.mjs";
2
+ import { ChevronDisclosureIcon, ChevronDisclosureIconProps } from "./ChevronDisclosureIcon.mjs";
3
+ import { LinkExternalIcon, LinkExternalIconProps } from "./LinkExternalIcon.mjs";
4
+ export { ArrowForwardIcon, ArrowForwardIconProps, ChevronDisclosureIcon, ChevronDisclosureIconProps, LinkExternalIcon, LinkExternalIconProps };
package/dist/index.mjs ADDED
@@ -0,0 +1,4 @@
1
+ import { ArrowForwardIcon } from "./ArrowForwardIcon.mjs";
2
+ import { ChevronDisclosureIcon } from "./ChevronDisclosureIcon.mjs";
3
+ import { LinkExternalIcon } from "./LinkExternalIcon.mjs";
4
+ export { ArrowForwardIcon, ChevronDisclosureIcon, LinkExternalIcon };
package/package.json ADDED
@@ -0,0 +1,41 @@
1
+ {
2
+ "name": "@hive-ui/icons",
3
+ "version": "0.1.0",
4
+ "description": "Hive UI Icons",
5
+ "files": [
6
+ "dist"
7
+ ],
8
+ "type": "module",
9
+ "exports": {
10
+ ".": "./dist/index.mjs",
11
+ "./ArrowForwardIcon": "./dist/ArrowForwardIcon.mjs",
12
+ "./ChevronDisclosureIcon": "./dist/ChevronDisclosureIcon.mjs",
13
+ "./LinkExternalIcon": "./dist/LinkExternalIcon.mjs",
14
+ "./package.json": "./package.json"
15
+ },
16
+ "publishConfig": {
17
+ "access": "public"
18
+ },
19
+ "scripts": {
20
+ "build": "vp pack",
21
+ "dev": "vp pack --watch",
22
+ "test": "vp test",
23
+ "check": "vp check",
24
+ "prepublishOnly": "vp run build"
25
+ },
26
+ "dependencies": {
27
+ "@hive-ui/box": "^0.1.0",
28
+ "@hive-ui/style-props": "^0.1.0"
29
+ },
30
+ "devDependencies": {
31
+ "@types/node": "^25.6.2",
32
+ "@typescript/native-preview": "7.0.0-dev.20260509.2",
33
+ "bumpp": "^11.1.0",
34
+ "typescript": "^6.0.3",
35
+ "vite-plus": "^0.1.20",
36
+ "vitest": "npm:@voidzero-dev/vite-plus-test@^0.1.20"
37
+ },
38
+ "peerDependencies": {
39
+ "react": "19.2.6"
40
+ }
41
+ }