Skip to content

Commit 801c989

Browse files
✨ feat: Add ComfyUI, Hailuo, Replit and TII
1 parent 8f9c602 commit 801c989

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+3066
-1712
lines changed

README.md

Lines changed: 20 additions & 19 deletions
Large diffs are not rendered by default.

docs/features/cdn-utils.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
nav: Components
3+
group:
4+
title: Utils
5+
order: 999
6+
title: getLobeIconCDN
7+
apiHeader:
8+
docUrl: 'https://github.com/lobehub/lobe-icons/tree/master/docs/features/cdn-utils.md'
9+
sourceUrl: 'https://github.com/lobehub/lobe-icons/tree/master/src/features/getLobeIconCDN/index.tsx'
10+
---
11+
12+
## Default
13+
14+
```tsx
15+
import { getLobeIconCDN } from '@lobehub/icons';
16+
import { Grid } from '@lobehub/ui';
17+
import { useThemeMode } from 'antd-style';
18+
19+
export default () => {
20+
const { isDarkMode } = useThemeMode();
21+
const color = getLobeIconCDN('Claude');
22+
const mono = getLobeIconCDN('Claude', { type: 'mono', isDarkMode });
23+
const text = getLobeIconCDN('Claude', { type: 'text', isDarkMode });
24+
return (
25+
<Grid>
26+
<img height={48} src={color} alt="Claude" />
27+
<img height={48} src={mono} alt="Claude" />
28+
<img height={48} src={text} alt="Claude" />
29+
</Grid>
30+
);
31+
};
32+
```
33+
34+
## Options
35+
36+
```ts
37+
export interface LobeIconCdnConfig {
38+
cdn?: 'aliyun' | 'unpkg';
39+
format?: 'svg' | 'png' | 'webp';
40+
isDarkMode?: boolean;
41+
type?: 'mono' | 'color' | 'text' | 'text-cn' | 'brand' | 'brand-color';
42+
}
43+
```

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@
9191
"consola": "^3.2.3",
9292
"cross-env": "^7.0.3",
9393
"dumi": "^2.4.14",
94-
"dumi-theme-lobehub": "^1.10.4",
94+
"dumi-theme-lobehub": "^1.10.9",
9595
"eslint": "^8.57.1",
9696
"father": "^4.5.1",
9797
"glob": "^11.0.0",
@@ -104,7 +104,7 @@
104104
"multi-semantic-release": "^3.0.2",
105105
"p-map": "^7.0.2",
106106
"polished": "^4.3.1",
107-
"prettier": "^3.3.3",
107+
"prettier": "^3.4.1",
108108
"react": "^18.3.1",
109109
"react-dom": "^18.3.1",
110110
"remark": "^14.0.3",

src/ComfyUI/components/Avatar.tsx

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
'use client';
2+
3+
import { memo } from 'react';
4+
5+
import IconAvatar, { type IconAvatarProps } from '@/features/IconAvatar';
6+
7+
import { COLOR_PRIMARY, TITLE } from '../style';
8+
import Color from './Color';
9+
10+
export type AvatarProps = Omit<IconAvatarProps, 'Icon'>;
11+
12+
const Avatar = memo<AvatarProps>(({ background, size, ...rest }) => {
13+
return (
14+
<IconAvatar
15+
Icon={Color}
16+
aria-label={TITLE}
17+
background={background || COLOR_PRIMARY}
18+
size={size}
19+
{...rest}
20+
/>
21+
);
22+
});
23+
24+
export default Avatar;

src/ComfyUI/components/Color.tsx

Lines changed: 210 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,210 @@
1+
'use client';
2+
3+
import { forwardRef } from 'react';
4+
5+
import { useFillIds } from '@/hooks/useFillId';
6+
import type { IconType } from '@/types';
7+
8+
import { TITLE } from '../style';
9+
10+
const Icon: IconType = forwardRef(({ size = '1em', style, ...rest }, ref) => {
11+
const [a, b, c, d, e, f, g, h, i, j, k, l, m] = useFillIds(TITLE, 13);
12+
return (
13+
<svg
14+
height={size}
15+
ref={ref}
16+
style={{ flex: 'none', lineHeight: 1, ...style }}
17+
viewBox="0 0 24 24"
18+
width={size}
19+
xmlns="http://www.w3.org/2000/svg"
20+
{...rest}
21+
>
22+
<title>{TITLE}</title>
23+
<path
24+
d="M10.311 16.46L8.495 8.078a.398.398 0 01.575-.437l7.29 3.843a.375.375 0 01-.064.69l-3.346 1.033a.493.493 0 00-.29.24l-1.65 3.11a.375.375 0 01-.699-.097z"
25+
fill="#fff"
26+
></path>
27+
<path
28+
d="M17.087 1.153C13.825-.336 10.665-.148 8.72.414c1.008.13 2.602.375 3.692.868.905.408 4.102 2.12 4.876 2.484.773.363 3.035 1.196 3.867 1.64.666.357 1.442 1.173 1.746 1.536-.613-1.238-2.191-4.137-5.813-5.79z"
29+
fill={a.fill}
30+
></path>
31+
<circle cx="8.438" cy="2.578" fill={b.fill} r="1.57"></circle>
32+
<circle cx="21.939" cy="13.384" fill={c.fill} r=".633"></circle>
33+
<circle cx="20.275" cy="11.532" fill={d.fill} r=".492"></circle>
34+
<circle cx="18.47" cy="16.619" fill={e.fill} r="1.219"></circle>
35+
<circle cx="14.579" cy="18.447" fill={f.fill} r=".797"></circle>
36+
<circle cx="15.341" cy="21.506" fill={g.fill} r="1.113"></circle>
37+
<circle cx="4.278" cy="14.966" fill={h.fill} r="1.254"></circle>
38+
<circle cx="4.981" cy="8.895" fill={i.fill} r="1.629"></circle>
39+
<path
40+
d="M16.795 16.82l-.974.604-.175.108-.18.112a1.195 1.195 0 11-1.996 1.247c-.268.17-.498.319-.672.435-1.389.93-2.817 1.858-4.676 1.945-2.42.114-5.91-2.203-6.446-7.676-.41-4.196 2.836-8.122 5.098-9.587l.112-.07a2.055 2.055 0 01-.51-1.36c0-.478.162-.918.435-1.267-.567.098-.952.362-1.615.843C3.239 3.572 2.126 4.45.613 8.27c-1.512 3.82.047 8.392 1.7 10.9 1.652 2.508 5.485 4.078 6.375 4.313.891.234 3.505.796 4.583.117.352-.222.641-.536.894-.901a1.676 1.676 0 011.443-2.849c.315-.589.672-1.09 1.155-1.372.247-.144.517-.291.797-.439a1.687 1.687 0 01-.765-1.22z"
41+
fill={j.fill}
42+
></path>
43+
<path
44+
d="M10.468 2.56c0 .338-.081.657-.225.938.998.246 2.006.598 3.612 1.606.414.26 1.346.727 2.195 1.153.449.225.874.438 1.186.603.898.386 1.854.797 2.596 1.15 2.14 1.02 2.693 2.605 2.442 4.448a.985.985 0 11-.718 1.833c-.488.498-1.212.836-1.926 1.116a1.683 1.683 0 01.487 1.359l.118-.055.026-.012a29.518 29.518 0 001.08-.514l.015-.008c.21-.11.533-.281.882-.548-.14.354-.6 1.222-1.312 1.86-.89.796-1.57.972-2.485 1.16-.715.147-1.728 1.016-2.174 1.46a1.674 1.674 0 01.47 2.323c-.029.113-.064.22-.1.327a5.074 5.074 0 00-.094.308l.136-.04c.601-.177 1.772-.52 4.247-3.089 2.678-2.78 2.945-6.016 3.059-7.723.199-2.743-1.588-4.48-2.444-5.101-.445-.323-1.685-.866-2.905-1.4l-.2-.089-.775-.335c-.773-.332-1.473-.633-1.88-.869l-.041-.024c-1.197-.692-3.07-1.775-4.63-2.264a3.4 3.4 0 00-.376-.073 3.005 3.005 0 01-.345-.068c.051.18.079.371.079.569z"
45+
fill={k.fill}
46+
></path>
47+
<path
48+
clipRule="evenodd"
49+
d="M13.886 6.476c-1.426-.827-3.247-1.882-5.075-1.882-1.334 0-2.826.919-4.033 2.213a2.095 2.095 0 011.914.875c.23-.375.496-.762.773-1.025.554-.525 1.329-.75 1.594-.75 1.149 0 2.591.75 4.692 2.086.636.404 1.26.735 1.83 1.038 1.482.787 2.6 1.38 2.6 2.548 0 1.324-.473 1.711-1.105 2.074-.123.07-.336.199-.615.366-.887.533-2.433 1.461-3.78 2.166a17.9 17.9 0 00-1.076.628c-1.353.833-2.638 1.625-4.089.602-1.828-1.289-1.621-3.574-1.176-4.781.13-.35.274-.678.408-.981.328-.743.59-1.335.39-1.727a1.475 1.475 0 00-.197-.281 2.1 2.1 0 01-1.628 1.322c-.162.635-.299 1.252-.34 1.667-.023.23-.052.465-.084.696a1.747 1.747 0 11-1.643 3.045c.587 1.302 1.401 2.36 2.236 2.892 1.897 1.21 3.818.56 4.415.358h.001a8.28 8.28 0 01.087-.03c.404-.131 2.473-1.508 4.235-2.681l.814-.542c1.468-.974 3.315-1.747 4.156-2.099.22-.092.372-.156.429-.186l.014-.007c.399-.213 1.496-.798 1.612-2.466.102-1.467-1.478-2.244-2.325-2.66-.127-.063-.238-.117-.323-.164-.27-.15-.744-.363-1.326-.626-.653-.296-1.444-.653-2.237-1.05-.342-.171-.728-.395-1.148-.638zm6.39 5.783a.727.727 0 100-1.453.727.727 0 000 1.453z"
50+
fill={l.fill}
51+
fillRule="evenodd"
52+
></path>
53+
<path
54+
d="M4.082 11.684a6.337 6.337 0 00-.046 1.552 1.748 1.748 0 00-1.431 1.228c-.316-1.383-.345-2.869.088-4.221.078-.245.172-.491.28-.736a2.103 2.103 0 001.314 1.368c-.09.248-.161.518-.205.81z"
55+
fill={m.fill}
56+
></path>
57+
<defs>
58+
<radialGradient
59+
cx="0"
60+
cy="0"
61+
gradientTransform="rotate(90 3.246 5.192) scale(2.20332)"
62+
gradientUnits="userSpaceOnUse"
63+
id={b.id}
64+
r="1"
65+
>
66+
<stop offset=".592" stopColor="#fff"></stop>
67+
<stop offset=".62" stopColor="#8BEBFF"></stop>
68+
</radialGradient>
69+
<radialGradient
70+
cx="0"
71+
cy="0"
72+
gradientTransform="matrix(0 .8879 -.8879 0 21.94 13.129)"
73+
gradientUnits="userSpaceOnUse"
74+
id={c.id}
75+
r="1"
76+
>
77+
<stop offset=".592" stopColor="#fff"></stop>
78+
<stop offset=".62" stopColor="#8BEBFF"></stop>
79+
</radialGradient>
80+
<radialGradient
81+
cx="0"
82+
cy="0"
83+
gradientTransform="rotate(90 4.47 15.805) scale(.69059)"
84+
gradientUnits="userSpaceOnUse"
85+
id={d.id}
86+
r="1"
87+
>
88+
<stop offset=".592" stopColor="#fff"></stop>
89+
<stop offset=".62" stopColor="#8BEBFF"></stop>
90+
</radialGradient>
91+
<radialGradient
92+
cx="0"
93+
cy="0"
94+
gradientTransform="rotate(90 1.171 17.299) scale(1.71004)"
95+
gradientUnits="userSpaceOnUse"
96+
id={e.id}
97+
r="1"
98+
>
99+
<stop offset=".592" stopColor="#fff"></stop>
100+
<stop offset=".62" stopColor="#8BEBFF"></stop>
101+
</radialGradient>
102+
<radialGradient
103+
cx="0"
104+
cy="0"
105+
gradientTransform="rotate(90 -1.773 16.353) scale(1.1181)"
106+
gradientUnits="userSpaceOnUse"
107+
id={f.id}
108+
r="1"
109+
>
110+
<stop offset=".592" stopColor="#fff"></stop>
111+
<stop offset=".62" stopColor="#8BEBFF"></stop>
112+
</radialGradient>
113+
<radialGradient
114+
cx="0"
115+
cy="0"
116+
gradientTransform="rotate(90 -2.858 18.2) scale(1.56205)"
117+
gradientUnits="userSpaceOnUse"
118+
id={g.id}
119+
r="1"
120+
>
121+
<stop offset=".592" stopColor="#fff"></stop>
122+
<stop offset=".62" stopColor="#8BEBFF"></stop>
123+
</radialGradient>
124+
<radialGradient
125+
cx="0"
126+
cy="0"
127+
gradientTransform="rotate(90 -5.091 9.37) scale(1.75937)"
128+
gradientUnits="userSpaceOnUse"
129+
id={h.id}
130+
r="1"
131+
>
132+
<stop offset=".592" stopColor="#fff"></stop>
133+
<stop offset=".62" stopColor="#8BEBFF"></stop>
134+
</radialGradient>
135+
<radialGradient
136+
cx="0"
137+
cy="0"
138+
gradientTransform="rotate(90 -1.629 6.61) scale(2.28553)"
139+
gradientUnits="userSpaceOnUse"
140+
id={i.id}
141+
r="1"
142+
>
143+
<stop offset=".592" stopColor="#fff"></stop>
144+
<stop offset=".62" stopColor="#8BEBFF"></stop>
145+
</radialGradient>
146+
<linearGradient
147+
gradientUnits="userSpaceOnUse"
148+
id={a.id}
149+
x1="12.388"
150+
x2="22.49"
151+
y1="0"
152+
y2="6.469"
153+
>
154+
<stop stopColor="#83FFFF"></stop>
155+
<stop offset="1" stopColor="#01F9FD"></stop>
156+
</linearGradient>
157+
<linearGradient
158+
gradientUnits="userSpaceOnUse"
159+
id={j.id}
160+
x1="6.926"
161+
x2="15.165"
162+
y1="1.313"
163+
y2="23.111"
164+
>
165+
<stop stopColor="#0CD7FE"></stop>
166+
<stop offset=".5" stopColor="#03ACFF"></stop>
167+
<stop offset="1" stopColor="#0272E1"></stop>
168+
</linearGradient>
169+
<linearGradient
170+
gradientUnits="userSpaceOnUse"
171+
id={k.id}
172+
x1="6.926"
173+
x2="15.165"
174+
y1="1.313"
175+
y2="23.111"
176+
>
177+
<stop stopColor="#0CD7FE"></stop>
178+
<stop offset=".5" stopColor="#03ACFF"></stop>
179+
<stop offset="1" stopColor="#0272E1"></stop>
180+
</linearGradient>
181+
<linearGradient
182+
gradientUnits="userSpaceOnUse"
183+
id={l.id}
184+
x1="21.26"
185+
x2="2.367"
186+
y1="10.747"
187+
y2="13.595"
188+
>
189+
<stop stopColor="#1BE8F9"></stop>
190+
<stop offset=".5" stopColor="#05C3FD"></stop>
191+
<stop offset="1" stopColor="#0047CB"></stop>
192+
</linearGradient>
193+
<linearGradient
194+
gradientUnits="userSpaceOnUse"
195+
id={m.id}
196+
x1="21.26"
197+
x2="2.367"
198+
y1="10.747"
199+
y2="13.595"
200+
>
201+
<stop stopColor="#1BE8F9"></stop>
202+
<stop offset=".5" stopColor="#05C3FD"></stop>
203+
<stop offset="1" stopColor="#0047CB"></stop>
204+
</linearGradient>
205+
</defs>
206+
</svg>
207+
);
208+
});
209+
210+
export default Icon;

src/ComfyUI/components/Combine.tsx

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
'use client';
2+
3+
import { memo } from 'react';
4+
5+
import IconCombine, { type IconCombineProps } from '@/features/IconCombine';
6+
7+
import { SPACE_MULTIPLE, TEXT_MULTIPLE, TITLE } from '../style';
8+
import Color from './Color';
9+
import Mono from './Mono';
10+
import Text from './Text';
11+
12+
export interface CombineProps extends Omit<IconCombineProps, 'Icon' | 'Text'> {
13+
type?: 'color' | 'mono';
14+
}
15+
const Combine = memo<CombineProps>(({ type = 'mono', ...rest }) => {
16+
const Icon = type === 'color' ? Color : Mono;
17+
18+
return (
19+
<IconCombine
20+
Icon={Icon}
21+
Text={Text}
22+
aria-label={TITLE}
23+
spaceMultiple={SPACE_MULTIPLE}
24+
textMultiple={TEXT_MULTIPLE}
25+
{...rest}
26+
/>
27+
);
28+
});
29+
30+
export default Combine;

src/ComfyUI/components/Mono.tsx

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
'use client';
2+
3+
import { forwardRef } from 'react';
4+
5+
import type { IconType } from '@/types';
6+
7+
import { TITLE } from '../style';
8+
9+
const Icon: IconType = forwardRef(({ size = '1em', style, ...rest }, ref) => {
10+
return (
11+
<svg
12+
fill="currentColor"
13+
fillRule="evenodd"
14+
height={size}
15+
ref={ref}
16+
style={{ flex: 'none', lineHeight: 1, ...style }}
17+
viewBox="0 0 24 24"
18+
width={size}
19+
xmlns="http://www.w3.org/2000/svg"
20+
{...rest}
21+
>
22+
<title>{TITLE}</title>
23+
24+
<path d="M10.311 16.46L8.495 8.078a.398.398 0 01.575-.437l7.29 3.843a.375.375 0 01-.064.69l-3.346 1.033a.493.493 0 00-.29.24l-1.65 3.11a.375.375 0 01-.699-.097z"></path>
25+
<path d="M17.087 1.153C13.825-.336 10.665-.148 8.72.414c1.008.13 2.602.375 3.692.868.905.408 4.102 2.12 4.876 2.484.773.363 3.035 1.196 3.867 1.64.666.357 1.442 1.173 1.746 1.536-.613-1.238-2.191-4.137-5.813-5.79z"></path>
26+
<circle cx="8.438" cy="2.578" r="1.57"></circle>
27+
<circle cx="21.939" cy="13.384" r=".633"></circle>
28+
<circle cx="20.275" cy="11.532" r=".492"></circle>
29+
<circle cx="18.47" cy="16.619" r="1.219"></circle>
30+
<circle cx="14.579" cy="18.447" r=".797"></circle>
31+
<circle cx="15.341" cy="21.506" r="1.113"></circle>
32+
<circle cx="4.278" cy="14.966" r="1.254"></circle>
33+
<circle cx="4.981" cy="8.895" r="1.629"></circle>
34+
<path d="M16.795 16.82l-.974.604-.175.108-.18.112a1.195 1.195 0 11-1.996 1.247c-.268.17-.498.319-.672.435-1.389.93-2.817 1.858-4.676 1.945-2.42.114-5.91-2.203-6.446-7.676-.41-4.196 2.836-8.122 5.098-9.587l.112-.07a2.055 2.055 0 01-.51-1.36c0-.478.162-.918.435-1.267-.567.098-.952.362-1.615.843C3.239 3.572 2.126 4.45.613 8.27c-1.512 3.82.047 8.392 1.7 10.9 1.652 2.508 5.485 4.078 6.375 4.313.891.234 3.505.796 4.583.117.352-.222.641-.536.894-.901a1.676 1.676 0 011.443-2.849c.315-.589.672-1.09 1.155-1.372.247-.144.517-.291.797-.439a1.687 1.687 0 01-.765-1.22z"></path>
35+
<path d="M10.468 2.56c0 .338-.081.657-.225.938.998.246 2.006.598 3.612 1.606.414.26 1.346.727 2.195 1.153.449.225.874.438 1.186.603.898.386 1.854.797 2.596 1.15 2.14 1.02 2.693 2.605 2.442 4.448a.985.985 0 11-.718 1.833c-.488.498-1.212.836-1.926 1.116a1.683 1.683 0 01.487 1.359l.118-.055.026-.012a29.518 29.518 0 001.08-.514l.015-.008c.21-.11.533-.281.882-.548-.14.354-.6 1.222-1.312 1.86-.89.796-1.57.972-2.485 1.16-.715.147-1.728 1.016-2.174 1.46a1.674 1.674 0 01.47 2.323c-.029.113-.064.22-.1.327a5.074 5.074 0 00-.094.308l.136-.04c.601-.177 1.772-.52 4.247-3.089 2.678-2.78 2.945-6.016 3.059-7.723.199-2.743-1.588-4.48-2.444-5.101-.445-.323-1.685-.866-2.905-1.4l-.2-.089-.775-.335c-.773-.332-1.473-.633-1.88-.869l-.041-.024c-1.197-.692-3.07-1.775-4.63-2.264a3.4 3.4 0 00-.376-.073 3.005 3.005 0 01-.345-.068c.051.18.079.371.079.569z"></path>
36+
<path
37+
clipRule="evenodd"
38+
d="M13.886 6.476c-1.426-.827-3.247-1.882-5.075-1.882-1.334 0-2.826.919-4.033 2.213a2.095 2.095 0 011.914.875c.23-.375.496-.762.773-1.025.554-.525 1.329-.75 1.594-.75 1.149 0 2.591.75 4.692 2.086.636.404 1.26.735 1.83 1.038 1.482.787 2.6 1.38 2.6 2.548 0 1.324-.473 1.711-1.105 2.074-.123.07-.336.199-.615.366-.887.533-2.433 1.461-3.78 2.166a17.9 17.9 0 00-1.076.628c-1.353.833-2.638 1.625-4.089.602-1.828-1.289-1.621-3.574-1.176-4.781.13-.35.274-.678.408-.981.328-.743.59-1.335.39-1.727a1.475 1.475 0 00-.197-.281 2.1 2.1 0 01-1.628 1.322c-.162.635-.299 1.252-.34 1.667-.023.23-.052.465-.084.696a1.747 1.747 0 11-1.643 3.045c.587 1.302 1.401 2.36 2.236 2.892 1.897 1.21 3.818.56 4.415.358h.001a8.28 8.28 0 01.087-.03c.404-.131 2.473-1.508 4.235-2.681l.814-.542c1.468-.974 3.315-1.747 4.156-2.099.22-.092.372-.156.429-.186l.014-.007c.399-.213 1.496-.798 1.612-2.466.102-1.467-1.478-2.244-2.325-2.66-.127-.063-.238-.117-.323-.164-.27-.15-.744-.363-1.326-.626-.653-.296-1.444-.653-2.237-1.05-.342-.171-.728-.395-1.148-.638zm6.39 5.783a.727.727 0 100-1.453.727.727 0 000 1.453z"
39+
></path>
40+
<path d="M4.082 11.684a6.337 6.337 0 00-.046 1.552 1.748 1.748 0 00-1.431 1.228c-.316-1.383-.345-2.869.088-4.221.078-.245.172-.491.28-.736a2.103 2.103 0 001.314 1.368c-.09.248-.161.518-.205.81z"></path>
41+
</svg>
42+
);
43+
});
44+
45+
export default Icon;

0 commit comments

Comments
 (0)