@lobehub/icons 1.9.0 → 1.10.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.
Files changed (116) hide show
  1. package/README.md +9 -2
  2. package/es/Bing/components/Avatar.d.ts +5 -0
  3. package/es/Bing/components/Avatar.js +25 -0
  4. package/es/Bing/components/Color.d.ts +3 -0
  5. package/es/Bing/components/Color.js +95 -0
  6. package/es/Bing/components/Combine.d.ts +7 -0
  7. package/es/Bing/components/Combine.js +25 -0
  8. package/es/Bing/components/Mono.d.ts +3 -0
  9. package/es/Bing/components/Mono.js +31 -0
  10. package/es/Bing/components/Text.d.ts +3 -0
  11. package/es/Bing/components/Text.js +31 -0
  12. package/es/Bing/index.d.ts +15 -0
  13. package/es/Bing/index.js +14 -0
  14. package/es/Bing/style.d.ts +4 -0
  15. package/es/Bing/style.js +4 -0
  16. package/es/Copilot/components/Avatar.d.ts +5 -0
  17. package/es/Copilot/components/Avatar.js +19 -0
  18. package/es/Copilot/components/Color.d.ts +3 -0
  19. package/es/Copilot/components/Color.js +169 -0
  20. package/es/Copilot/components/Combine.d.ts +7 -0
  21. package/es/Copilot/components/Combine.js +25 -0
  22. package/es/Copilot/components/Mono.d.ts +3 -0
  23. package/es/Copilot/components/Mono.js +31 -0
  24. package/es/Copilot/components/Text.d.ts +3 -0
  25. package/es/Copilot/components/Text.js +31 -0
  26. package/es/Copilot/index.d.ts +14 -0
  27. package/es/Copilot/index.js +13 -0
  28. package/es/Copilot/style.d.ts +3 -0
  29. package/es/Copilot/style.js +3 -0
  30. package/es/DeepMind/components/Avatar.d.ts +5 -0
  31. package/es/DeepMind/components/Avatar.js +19 -0
  32. package/es/DeepMind/components/Color.d.ts +3 -0
  33. package/es/DeepMind/components/Color.js +31 -0
  34. package/es/DeepMind/components/Combine.d.ts +7 -0
  35. package/es/DeepMind/components/Combine.js +25 -0
  36. package/es/DeepMind/components/Mono.d.ts +3 -0
  37. package/es/DeepMind/components/Mono.js +31 -0
  38. package/es/DeepMind/components/Text.d.ts +3 -0
  39. package/es/DeepMind/components/Text.js +31 -0
  40. package/es/DeepMind/index.d.ts +14 -0
  41. package/es/DeepMind/index.js +13 -0
  42. package/es/DeepMind/style.d.ts +3 -0
  43. package/es/DeepMind/style.js +3 -0
  44. package/es/Github/components/Avatar.d.ts +5 -0
  45. package/es/Github/components/Avatar.js +20 -0
  46. package/es/Github/components/Combine.d.ts +5 -0
  47. package/es/Github/components/Combine.js +20 -0
  48. package/es/Github/components/Mono.d.ts +3 -0
  49. package/es/Github/components/Mono.js +31 -0
  50. package/es/Github/components/Text.d.ts +3 -0
  51. package/es/Github/components/Text.js +31 -0
  52. package/es/Github/index.d.ts +12 -0
  53. package/es/Github/index.js +11 -0
  54. package/es/Github/style.d.ts +3 -0
  55. package/es/Github/style.js +3 -0
  56. package/es/GithubCopilot/components/Avatar.d.ts +5 -0
  57. package/es/GithubCopilot/components/Avatar.js +20 -0
  58. package/es/GithubCopilot/components/Combine.d.ts +5 -0
  59. package/es/GithubCopilot/components/Combine.js +20 -0
  60. package/es/GithubCopilot/components/Mono.d.ts +3 -0
  61. package/es/GithubCopilot/components/Mono.js +31 -0
  62. package/es/GithubCopilot/components/Text.d.ts +3 -0
  63. package/es/GithubCopilot/components/Text.js +31 -0
  64. package/es/GithubCopilot/index.d.ts +12 -0
  65. package/es/GithubCopilot/index.js +11 -0
  66. package/es/GithubCopilot/style.d.ts +3 -0
  67. package/es/GithubCopilot/style.js +3 -0
  68. package/es/Google/components/Avatar.d.ts +5 -0
  69. package/es/Google/components/Avatar.js +19 -0
  70. package/es/Google/components/BrandColor.d.ts +3 -0
  71. package/es/Google/components/BrandColor.js +50 -0
  72. package/es/Google/components/BrandMono.d.ts +3 -0
  73. package/es/Google/components/BrandMono.js +31 -0
  74. package/es/Google/components/Color.d.ts +3 -0
  75. package/es/Google/components/Color.js +44 -0
  76. package/es/Google/components/Mono.d.ts +3 -0
  77. package/es/Google/components/Mono.js +31 -0
  78. package/es/Google/index.d.ts +14 -0
  79. package/es/Google/index.js +13 -0
  80. package/es/Google/style.d.ts +1 -0
  81. package/es/Google/style.js +1 -0
  82. package/es/Moonshot/components/Avatar.d.ts +5 -0
  83. package/es/Moonshot/components/Avatar.js +20 -0
  84. package/es/Moonshot/components/Combine.d.ts +5 -0
  85. package/es/Moonshot/components/Combine.js +20 -0
  86. package/es/Moonshot/components/Mono.d.ts +3 -0
  87. package/es/Moonshot/components/Mono.js +31 -0
  88. package/es/Moonshot/components/Text.d.ts +3 -0
  89. package/es/Moonshot/components/Text.js +31 -0
  90. package/es/Moonshot/index.d.ts +12 -0
  91. package/es/Moonshot/index.js +11 -0
  92. package/es/Moonshot/style.d.ts +3 -0
  93. package/es/Moonshot/style.js +3 -0
  94. package/es/Pollinations/components/Avatar.d.ts +5 -0
  95. package/es/Pollinations/components/Avatar.js +20 -0
  96. package/es/Pollinations/components/Combine.d.ts +5 -0
  97. package/es/Pollinations/components/Combine.js +20 -0
  98. package/es/Pollinations/components/Mono.d.ts +3 -0
  99. package/es/Pollinations/components/Mono.js +31 -0
  100. package/es/Pollinations/components/Text.d.ts +3 -0
  101. package/es/Pollinations/components/Text.js +31 -0
  102. package/es/Pollinations/index.d.ts +12 -0
  103. package/es/Pollinations/index.js +11 -0
  104. package/es/Pollinations/style.d.ts +3 -0
  105. package/es/Pollinations/style.js +3 -0
  106. package/es/components/Dashboard/Text.d.ts +5 -0
  107. package/es/components/Dashboard/Text.js +66 -0
  108. package/es/components/Dashboard/index.d.ts +5 -0
  109. package/es/components/Dashboard/index.js +67 -0
  110. package/es/components/DownloadButton/index.d.ts +10 -0
  111. package/es/components/DownloadButton/index.js +28 -0
  112. package/es/components/IconPreview/index.d.ts +2 -1
  113. package/es/components/IconPreview/index.js +31 -9
  114. package/es/index.d.ts +8 -0
  115. package/es/index.js +8 -0
  116. package/package.json +3 -1
@@ -0,0 +1,31 @@
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
3
+ var _excluded = ["size", "style"];
4
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
+ import { forwardRef } from 'react';
7
+ import { jsx as _jsx } from "react/jsx-runtime";
8
+ var Icon = /*#__PURE__*/forwardRef(function (_ref, ref) {
9
+ var _ref$size = _ref.size,
10
+ size = _ref$size === void 0 ? '1em' : _ref$size,
11
+ style = _ref.style,
12
+ rest = _objectWithoutProperties(_ref, _excluded);
13
+ return /*#__PURE__*/_jsx("svg", _objectSpread(_objectSpread({
14
+ fill: "currentColor",
15
+ fillRule: "evenodd",
16
+ height: size,
17
+ ref: ref,
18
+ style: _objectSpread({
19
+ flex: 'none',
20
+ lineHeight: 1,
21
+ width: 'fit-content'
22
+ }, style),
23
+ viewBox: "0 0 133 24",
24
+ xmlns: "http://www.w3.org/2000/svg"
25
+ }, rest), {}, {
26
+ children: /*#__PURE__*/_jsx("path", {
27
+ d: "M2 6.707c3.097.142 2.245-.736 2.436 2.32 1.43-3.952 7.777-3.033 8.545.905.917 3.007-.18 7.226-3.797 7.58-2.02.318-3.79-.454-4.683-2.307V24H2V6.707zm2.494 5.315c-.008 2.296.983 4.81 3.632 4.596 2.565-.276 2.542-3.61 2.43-5.582l-.004-.115c-.1-1.88-.957-3.85-3.124-3.48-2.14.288-2.968 2.69-2.934 4.58zm70.24 5.264H72.36V15.17l-.041-.01c-.886 2.413-3.668 2.852-5.862 2.078-2.29-.882-2.24-3.611-1.13-4.723 1.833-1.687 4.534-1.361 6.847-1.562l-.001-.171c0-1.341.149-3.36-1.586-3.494l-.125-.015c-1.76-.178-2.58.546-2.629 2.393h-2.62c.105-3.476 4.89-3.608 7.388-2.78 1.544.453 2.195 1.909 2.138 3.434l.007 1.99c.006 1.658.009 3.316-.01 4.975l-.002.001zm-2.61-5.557l-.214.002c-1.642.009-3.996-.072-4.621 1.755-.34 1.174-.052 2.813 1.362 3.04 2.913.454 3.687-2.48 3.473-4.797zm36.282 5.554V6.733h2.308v2.685l.046.011c.482-1.45 1.403-2.54 2.967-2.83 1.17-.226 2.334-.202 3.403.395l.074.042c1.292.711 1.546 2.194 1.501 3.546.005 2.234.002 4.465.004 6.7h-2.5c0-2.337.011-4.674-.008-7.012l.001-.095c.008-1.197-.37-2.59-1.807-2.63-4.718-.049-3.254 6.645-3.506 9.736h-2.481l-.002.002zm-54.865-7.87c.818-2.607 3.383-3.458 5.851-2.664 1.957.692 2.181 2.506 2.108 4.321.006 2.072.002 4.14.002 6.215h-2.493l.001-3.525c0-1.175 0-2.35-.005-3.526.073-1.183-.409-2.649-1.794-2.68-4.74-.138-3.28 6.67-3.523 9.734h-2.485V6.737h2.303v2.681c.01 0 .023-.003.034-.005h.001zm51.454 2.658c-.04 1.483-.435 2.824-1.438 3.945-1.853 1.826-4.914 2.05-7.247 1.089-4.368-1.784-3.879-9.328.773-10.41 4.103-1.12 7.89.842 7.912 5.376zm-2.706-.245h.002l-.005-.22c-.055-1.788-.387-4.275-2.895-4.384-2.414-.22-3.294 1.943-3.372 3.968l-.013.445c-.048 2.075.1 4.867 2.71 5.186 2.945.355 3.662-2.433 3.573-4.995zm-74.674.233c-.016 2.199-1.131 4.483-3.35 5.154-1.71.58-3.427.624-5.12-.02-4.517-1.578-4.211-9.244.42-10.458 4.091-1.189 7.932.68 8.048 5.187l.002.137zm-2.695.007h-.002l.001-.121c.01-2-.464-4.716-2.955-4.722-2.24-.212-3.234 1.8-3.31 3.804l-.016.264c-.11 2.153.031 5.26 2.723 5.534 2.892.328 3.6-2.375 3.56-4.759zm96.846 2.033h2.383c.047 2.322 1.505 3.091 3.645 2.482 1.281-.419 1.663-2.186.443-2.835-1.855-1.072-4.672-.709-5.884-2.74-1.112-2.372 1.059-4.492 3.611-4.51 2.139-.217 4.604.717 4.707 3.168h-2.33l-.017-.238c-.07-.88-.226-1.82-1.24-2.039-.686-.187-1.368-.185-2.023.118-.77.358-1.128 1.126-.88 1.865.368.998 1.573 1.17 2.47 1.427l.223.06c1.633.422 3.757.828 4.077 2.77.247 1.507-.455 2.792-1.856 3.439-2.564 1.106-7.201.6-7.326-2.863l-.003-.104zm-88.275 3.19h-2.483c0-5.674 0-11.347-.005-17.018 0-.204.05-.27.244-.271h.027c.743.016 1.475.004 2.217.006v17.282zm6.758 0h-2.472V.015c.753-.032 1.503 0 2.256-.016.166 0 .232.03.232.218-.018 5.689.02 11.38-.018 17.068l.002.002zm44.466-1.043c-.045.258.12.79-.121.909l-.235.056c-.977.23-1.96.409-2.975.3-1.756-.135-2.561-1.764-2.445-3.376-.005-2.18-.002-4.351-.004-6.53H77c.048-.257-.147-.868.185-.884.59-.009 1.152-.004 1.744-.005V3.749l1.66-.393.837-.198v3.556h3.317v.871h-3.29c.027 2.637-.152 5.308.096 7.93.313 1.531 2.067.918 3.165.73l.002.001zM46.95 17.29h-2.466V6.737h2.466V17.29zM87.398 6.73h2.466v10.56h-2.466V6.73zm2.88-4.756c.02 2.133-3.83 1.791-3.205-.445.405-1.554 3.34-1.326 3.205.445zm-46.166-.02c-.091-1.973 3.462-1.959 3.252.126-.041 1.797-3.37 1.746-3.252-.127z"
28
+ })
29
+ }));
30
+ });
31
+ export default Icon;
@@ -0,0 +1,12 @@
1
+ import Avatar from './components/Avatar';
2
+ import Combine from './components/Combine';
3
+ import Mono from './components/Mono';
4
+ import Text from './components/Text';
5
+ export type CompoundedIcon = typeof Mono & {
6
+ Avatar: typeof Avatar;
7
+ Combine: typeof Combine;
8
+ Text: typeof Text;
9
+ colorPrimary: string;
10
+ };
11
+ declare const Icons: CompoundedIcon;
12
+ export default Icons;
@@ -0,0 +1,11 @@
1
+ import Avatar from "./components/Avatar";
2
+ import Combine from "./components/Combine";
3
+ import Mono from "./components/Mono";
4
+ import Text from "./components/Text";
5
+ import { COLOR_PRIMARY } from "./style";
6
+ var Icons = Mono;
7
+ Icons.Text = Text;
8
+ Icons.Combine = Combine;
9
+ Icons.Avatar = Avatar;
10
+ Icons.colorPrimary = COLOR_PRIMARY;
11
+ export default Icons;
@@ -0,0 +1,3 @@
1
+ export declare const TEXT_MULTIPLE = 0.6;
2
+ export declare const SPACE_MULTIPLE = 0.3;
3
+ export declare const COLOR_PRIMARY = "#000";
@@ -0,0 +1,3 @@
1
+ export var TEXT_MULTIPLE = 0.6;
2
+ export var SPACE_MULTIPLE = 0.3;
3
+ export var COLOR_PRIMARY = '#000';
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ declare const Dashboard: import("react").NamedExoticComponent<{
3
+ className: string;
4
+ }>;
5
+ export default Dashboard;
@@ -0,0 +1,66 @@
1
+ import _taggedTemplateLiteral from "@babel/runtime/helpers/esm/taggedTemplateLiteral";
2
+ var _templateObject;
3
+ import * as Icons from "../..";
4
+ import { StoryBook, useControls, useCreateStore } from '@lobehub/ui';
5
+ import { createStyles } from 'antd-style';
6
+ import { memo } from 'react';
7
+ import { Flexbox } from 'react-layout-kit';
8
+ import IconPreview from "../IconPreview";
9
+ import { jsx as _jsx } from "react/jsx-runtime";
10
+ var data = Object.values(Icons).filter(function (icon) {
11
+ return icon === null || icon === void 0 ? void 0 : icon.colorPrimary;
12
+ });
13
+ var useStyles = createStyles(function (_ref) {
14
+ var css = _ref.css,
15
+ token = _ref.token;
16
+ return {
17
+ item: css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n height: 96px;\n padding: 16px;\n background: ", ";\n border: none;\n "])), token.colorBgContainer)
18
+ };
19
+ });
20
+ var Dashboard = /*#__PURE__*/memo(function (_ref2) {
21
+ var className = _ref2.className;
22
+ var _useStyles = useStyles(),
23
+ styles = _useStyles.styles;
24
+ var store = useCreateStore();
25
+ var _useControls = useControls({
26
+ color: {
27
+ color: true,
28
+ value: '#fff'
29
+ },
30
+ size: {
31
+ max: 96,
32
+ min: 16,
33
+ step: 1,
34
+ value: 24
35
+ }
36
+ }, {
37
+ store: store
38
+ }),
39
+ size = _useControls.size,
40
+ color = _useControls.color;
41
+ return /*#__PURE__*/_jsx(StoryBook, {
42
+ className: className,
43
+ levaStore: store,
44
+ children: /*#__PURE__*/_jsx(Flexbox, {
45
+ align: 'center',
46
+ gap: 4,
47
+ horizontal: true,
48
+ justify: 'center',
49
+ style: {
50
+ flexWrap: 'wrap'
51
+ },
52
+ children: data.map(function (Icon, index) {
53
+ var IconRender = Icon.Text || Icon.Brand;
54
+ if (!IconRender) return null;
55
+ return /*#__PURE__*/_jsx(IconPreview, {
56
+ className: styles.item,
57
+ children: /*#__PURE__*/_jsx(IconRender, {
58
+ color: color === '#fff' ? undefined : color,
59
+ size: size
60
+ })
61
+ }, index);
62
+ })
63
+ })
64
+ });
65
+ });
66
+ export default Dashboard;
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ declare const Dashboard: import("react").NamedExoticComponent<{
3
+ className: string;
4
+ }>;
5
+ export default Dashboard;
@@ -0,0 +1,67 @@
1
+ import _taggedTemplateLiteral from "@babel/runtime/helpers/esm/taggedTemplateLiteral";
2
+ var _templateObject;
3
+ import * as Icons from "../..";
4
+ import { StoryBook, useControls, useCreateStore } from '@lobehub/ui';
5
+ import { createStyles } from 'antd-style';
6
+ import { memo } from 'react';
7
+ import { Flexbox } from 'react-layout-kit';
8
+ import IconPreview from "../IconPreview";
9
+ import { jsx as _jsx } from "react/jsx-runtime";
10
+ var data = Object.values(Icons).filter(function (icon) {
11
+ return icon === null || icon === void 0 ? void 0 : icon.colorPrimary;
12
+ });
13
+ var useStyles = createStyles(function (_ref) {
14
+ var css = _ref.css,
15
+ token = _ref.token;
16
+ return {
17
+ item: css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n width: 96px;\n height: 96px;\n background: ", ";\n border: none;\n "])), token.colorBgContainer)
18
+ };
19
+ });
20
+ var Dashboard = /*#__PURE__*/memo(function (_ref2) {
21
+ var className = _ref2.className;
22
+ var _useStyles = useStyles(),
23
+ styles = _useStyles.styles;
24
+ var store = useCreateStore();
25
+ var _useControls = useControls({
26
+ color: {
27
+ color: true,
28
+ value: '#fff'
29
+ },
30
+ monochrome: false,
31
+ size: {
32
+ max: 96,
33
+ min: 16,
34
+ step: 1,
35
+ value: 48
36
+ }
37
+ }, {
38
+ store: store
39
+ }),
40
+ size = _useControls.size,
41
+ color = _useControls.color,
42
+ monochrome = _useControls.monochrome;
43
+ return /*#__PURE__*/_jsx(StoryBook, {
44
+ className: className,
45
+ levaStore: store,
46
+ children: /*#__PURE__*/_jsx(Flexbox, {
47
+ align: 'center',
48
+ gap: 4,
49
+ horizontal: true,
50
+ justify: 'center',
51
+ style: {
52
+ flexWrap: 'wrap'
53
+ },
54
+ children: data.map(function (Icon, index) {
55
+ var IconRender = !monochrome && Icon.Color ? Icon.Color : Icon;
56
+ return /*#__PURE__*/_jsx(IconPreview, {
57
+ className: styles.item,
58
+ children: /*#__PURE__*/_jsx(IconRender, {
59
+ color: color === '#fff' ? undefined : color,
60
+ size: size
61
+ })
62
+ }, index);
63
+ })
64
+ })
65
+ });
66
+ });
67
+ export default Dashboard;
@@ -0,0 +1,10 @@
1
+ /// <reference types="react" />
2
+ import { ActionIconSize, DivProps, TooltipProps } from '@lobehub/ui';
3
+ export interface DownloadButtonProps extends DivProps {
4
+ className?: string;
5
+ onClick?: () => void;
6
+ placement?: TooltipProps['placement'];
7
+ size?: ActionIconSize;
8
+ }
9
+ declare const DownloadButton: import("react").NamedExoticComponent<DownloadButtonProps>;
10
+ export default DownloadButton;
@@ -0,0 +1,28 @@
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
3
+ var _excluded = ["className", "placement", "size", "onClick"];
4
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
+ import { ActionIcon } from '@lobehub/ui';
7
+ import { Download } from 'lucide-react';
8
+ import { memo } from 'react';
9
+ import { jsx as _jsx } from "react/jsx-runtime";
10
+ var DownloadButton = /*#__PURE__*/memo(function (_ref) {
11
+ var className = _ref.className,
12
+ _ref$placement = _ref.placement,
13
+ placement = _ref$placement === void 0 ? 'right' : _ref$placement,
14
+ _ref$size = _ref.size,
15
+ size = _ref$size === void 0 ? 'site' : _ref$size,
16
+ onClick = _ref.onClick,
17
+ rest = _objectWithoutProperties(_ref, _excluded);
18
+ return /*#__PURE__*/_jsx(ActionIcon, _objectSpread(_objectSpread({}, rest), {}, {
19
+ className: className,
20
+ glass: true,
21
+ icon: Download,
22
+ onClick: onClick,
23
+ placement: placement,
24
+ size: size,
25
+ title: 'Download'
26
+ }));
27
+ });
28
+ export default DownloadButton;
@@ -1,5 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
- export interface IconPreviewProps {
2
+ import { FlexboxProps } from 'react-layout-kit';
3
+ export interface IconPreviewProps extends FlexboxProps {
3
4
  children: string | ReactNode;
4
5
  }
5
6
  declare const IconPreview: import("react").NamedExoticComponent<IconPreviewProps>;
@@ -1,9 +1,14 @@
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
1
3
  import _taggedTemplateLiteral from "@babel/runtime/helpers/esm/taggedTemplateLiteral";
4
+ var _excluded = ["className", "children"];
2
5
  var _templateObject, _templateObject2, _templateObject3;
3
- import { CopyButton } from '@lobehub/ui';
6
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
7
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
4
8
  import { createStyles } from 'antd-style';
5
9
  import { memo, useRef } from 'react';
6
10
  import { Flexbox } from 'react-layout-kit';
11
+ import DownloadButton from "../DownloadButton";
7
12
  import { jsx as _jsx } from "react/jsx-runtime";
8
13
  import { jsxs as _jsxs } from "react/jsx-runtime";
9
14
  var useStyles = createStyles(function (_ref) {
@@ -17,17 +22,20 @@ var useStyles = createStyles(function (_ref) {
17
22
  };
18
23
  });
19
24
  var IconPreview = /*#__PURE__*/memo(function (_ref2) {
20
- var _ref$current;
21
- var children = _ref2.children;
25
+ var className = _ref2.className,
26
+ children = _ref2.children,
27
+ rest = _objectWithoutProperties(_ref2, _excluded);
22
28
  var _useStyles = useStyles(),
29
+ cx = _useStyles.cx,
23
30
  styles = _useStyles.styles;
24
31
  var ref = useRef(null);
25
32
  var isString = typeof children === 'string';
26
- return /*#__PURE__*/_jsxs(Flexbox, {
33
+ return /*#__PURE__*/_jsxs(Flexbox, _objectSpread(_objectSpread({
27
34
  align: 'center',
28
- className: styles.container,
35
+ className: cx(styles.container, className),
29
36
  flex: 'none',
30
- justify: 'center',
37
+ justify: 'center'
38
+ }, rest), {}, {
31
39
  children: [isString ? /*#__PURE__*/_jsx("div", {
32
40
  className: styles.inner,
33
41
  dangerouslySetInnerHTML: {
@@ -38,10 +46,24 @@ var IconPreview = /*#__PURE__*/memo(function (_ref2) {
38
46
  className: styles.inner,
39
47
  ref: ref,
40
48
  children: children
41
- }), /*#__PURE__*/_jsx(CopyButton, {
49
+ }), /*#__PURE__*/_jsx(DownloadButton, {
42
50
  className: styles.btn,
43
- content: String(ref === null || ref === void 0 || (_ref$current = ref.current) === null || _ref$current === void 0 || (_ref$current = _ref$current.querySelector('svg')) === null || _ref$current === void 0 ? void 0 : _ref$current.outerHTML)
51
+ onClick: function onClick() {
52
+ var _ref$current;
53
+ var svgString = String(ref === null || ref === void 0 || (_ref$current = ref.current) === null || _ref$current === void 0 || (_ref$current = _ref$current.querySelector('svg')) === null || _ref$current === void 0 ? void 0 : _ref$current.outerHTML);
54
+ var blob = new Blob([svgString], {
55
+ type: 'image/svg+xml;charset=utf-8'
56
+ });
57
+ var url = URL.createObjectURL(blob);
58
+ var downloadLink = document.createElement('a');
59
+ downloadLink.href = url;
60
+ downloadLink.download = 'icon.svg';
61
+ document.body.append(downloadLink);
62
+ downloadLink.click();
63
+ downloadLink.remove();
64
+ URL.revokeObjectURL(url);
65
+ }
44
66
  })]
45
- });
67
+ }));
46
68
  });
47
69
  export default IconPreview;
package/es/index.d.ts CHANGED
@@ -4,12 +4,18 @@ export { default as Aws, type CompoundedIcon as AwsProps } from './Aws';
4
4
  export { default as Azure, type CompoundedIcon as AzureProps } from './Azure';
5
5
  export { default as Baichuan, type CompoundedIcon as BaichuanProps } from './Baichuan';
6
6
  export { default as Bedrock, type CompoundedIcon as BedrockProps } from './Bedrock';
7
+ export { default as Bing, type CompoundedIcon as BingProps } from './Bing';
7
8
  export { default as ChatGLM, type CompoundedIcon as ChatGLMProps } from './ChatGLM';
8
9
  export { default as Cloudflare, type CompoundedIcon as CloudflareProps } from './Cloudflare';
9
10
  export { default as Cohere, type CompoundedIcon as CohereProps } from './Cohere';
11
+ export { default as Copilot, type CompoundedIcon as CopilotProps } from './Copilot';
10
12
  export { default as Dalle, type CompoundedIcon as DalleProps } from './Dalle';
13
+ export { default as DeepMind, type CompoundedIcon as DeepMindProps } from './DeepMind';
11
14
  export { default as Fireworks, type CompoundedIcon as FireworksProps } from './Fireworks';
12
15
  export { default as Gemini, type CompoundedIcon as GeminiProps } from './Gemini';
16
+ export { default as Github, type CompoundedIcon as GithubProps } from './Github';
17
+ export { default as GithubCopilot, type CompoundedIcon as GithubCopilotProps, } from './GithubCopilot';
18
+ export { default as Google, type CompoundedIcon as GoogleProps } from './Google';
13
19
  export { default as HuggingFace, type CompoundedIcon as HuggingFaceProps } from './HuggingFace';
14
20
  export { default as Hunyuan, type CompoundedIcon as HunyuanProps } from './Hunyuan';
15
21
  export { default as IconAvatar, type IconAvatarProps } from './IconAvatar';
@@ -18,9 +24,11 @@ export { default as Meta, type CompoundedIcon as MetaProps } from './Meta';
18
24
  export { default as Midjourney, type CompoundedIcon as MidjourneyProps } from './Midjourney';
19
25
  export { default as Minimax, type CompoundedIcon as MinimaxProps } from './Minimax';
20
26
  export { default as Mistral, type CompoundedIcon as MistralProps } from './Mistral';
27
+ export { default as Moonshot, type CompoundedIcon as MoonshotProps } from './Moonshot';
21
28
  export { default as Ollama, type CompoundedIcon as OllamaProps } from './Ollama';
22
29
  export { default as OpenAI, type CompoundedIcon as OpenAIProps } from './OpenAI';
23
30
  export { default as Perplexity, type CompoundedIcon as PerplexityProps } from './Perplexity';
31
+ export { default as Pollinations, type CompoundedIcon as PollinationsProps } from './Pollinations';
24
32
  export { default as Qingyan, type CompoundedIcon as QingyanProps } from './Qingyan';
25
33
  export { default as Replicate, type CompoundedIcon as ReplicateProps } from './Replicate';
26
34
  export { default as Spark, type CompoundedIcon as SparkProps } from './Spark';
package/es/index.js CHANGED
@@ -4,12 +4,18 @@ export { default as Aws } from "./Aws";
4
4
  export { default as Azure } from "./Azure";
5
5
  export { default as Baichuan } from "./Baichuan";
6
6
  export { default as Bedrock } from "./Bedrock";
7
+ export { default as Bing } from "./Bing";
7
8
  export { default as ChatGLM } from "./ChatGLM";
8
9
  export { default as Cloudflare } from "./Cloudflare";
9
10
  export { default as Cohere } from "./Cohere";
11
+ export { default as Copilot } from "./Copilot";
10
12
  export { default as Dalle } from "./Dalle";
13
+ export { default as DeepMind } from "./DeepMind";
11
14
  export { default as Fireworks } from "./Fireworks";
12
15
  export { default as Gemini } from "./Gemini";
16
+ export { default as Github } from "./Github";
17
+ export { default as GithubCopilot } from "./GithubCopilot";
18
+ export { default as Google } from "./Google";
13
19
  export { default as HuggingFace } from "./HuggingFace";
14
20
  export { default as Hunyuan } from "./Hunyuan";
15
21
  export { default as IconAvatar } from "./IconAvatar";
@@ -18,9 +24,11 @@ export { default as Meta } from "./Meta";
18
24
  export { default as Midjourney } from "./Midjourney";
19
25
  export { default as Minimax } from "./Minimax";
20
26
  export { default as Mistral } from "./Mistral";
27
+ export { default as Moonshot } from "./Moonshot";
21
28
  export { default as Ollama } from "./Ollama";
22
29
  export { default as OpenAI } from "./OpenAI";
23
30
  export { default as Perplexity } from "./Perplexity";
31
+ export { default as Pollinations } from "./Pollinations";
24
32
  export { default as Qingyan } from "./Qingyan";
25
33
  export { default as Replicate } from "./Replicate";
26
34
  export { default as Spark } from "./Spark";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/icons",
3
- "version": "1.9.0",
3
+ "version": "1.10.0",
4
4
  "description": "Popular AI / LLM Model Brand SVG Logo and Icon Collection",
5
5
  "keywords": [
6
6
  "lobehub",
@@ -83,6 +83,7 @@
83
83
  "@types/react": "18.2.40",
84
84
  "@types/react-dom": "^18",
85
85
  "@vitest/coverage-v8": "latest",
86
+ "antd": "^5.13.3",
86
87
  "antd-style": "^3",
87
88
  "babel-plugin-antd-style": "latest",
88
89
  "commitlint": "^18",
@@ -95,6 +96,7 @@
95
96
  "husky": "^8",
96
97
  "jsdom": "^23",
97
98
  "lint-staged": "^15",
99
+ "lucide-react": "latest",
98
100
  "prettier": "^3",
99
101
  "react": "^18",
100
102
  "react-dom": "^18",