Skip to content

Commit

Permalink
Adding new icons
Browse files Browse the repository at this point in the history
  • Loading branch information
gjones committed Dec 12, 2024
1 parent 90368c3 commit e479542
Show file tree
Hide file tree
Showing 5 changed files with 112 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/CodeBlock/CodeBlock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ import { EmptyButton } from "../commonElement";
import sql from "react-syntax-highlighter/dist/cjs/languages/hljs/sql";
import bash from "react-syntax-highlighter/dist/cjs/languages/hljs/bash";
import json from "react-syntax-highlighter/dist/cjs/languages/hljs/json";
import tsx from "react-syntax-highlighter/dist/cjs/languages/prism/typescript";

SyntaxHighlighter.registerLanguage("sql", sql);
SyntaxHighlighter.registerLanguage("bash", bash);
SyntaxHighlighter.registerLanguage("json", json);
SyntaxHighlighter.registerLanguage("text", tsx);

export type CodeThemeType = "light" | "dark";
interface Props extends Omit<HTMLAttributes<HTMLDivElement>, "children" | "onCopy"> {
Expand Down
4 changes: 4 additions & 0 deletions src/components/Icon/IconCommon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,14 @@ import Http from "@/components/icons/Http";
import HttpMonitoring from "@/components/icons/HttpMonitoring";
import Integrations from "@/components/icons/Integrations";
import LightBulb from "@/components/icons/LightBulb";
import LightBulbOn from "@/components/icons/LightBulbOn";
import Lightening from "@/components/icons/Lightening";
import Loading from "@/components/icons/Loading";
import Lock from "@/components/icons/Lock";
import LoadingAnimated from "@/components/icons/LoadingAnimated";
import Metrics from "@/components/icons/Metrics";
import MetricsAlt from "@/components/icons/MetricsAlt";
import Moon from "@/components/icons/Moon";
import Pause from "@/components/icons/Pause";
import Payment from "@/components/icons/Payment";
import Pencil from "@/components/icons/Pencil";
Expand Down Expand Up @@ -225,6 +227,7 @@ export const ICONS_MAP = {
keys: Keys,
lifebuoy: Lifebuoy,
"light-bulb": LightBulb,
"light-bulb-on": LightBulbOn,
lightening: Lightening,
"line-in-circle": LineInCircle,
loading: Loading,
Expand All @@ -233,6 +236,7 @@ export const ICONS_MAP = {
metrics: Metrics,
"metrics-alt": MetricsAlt,
minus: Minus,
moon: Moon,
"no-cloud": NoCloud,
pause: Pause,
payment: Payment,
Expand Down
2 changes: 2 additions & 0 deletions src/components/Icon/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ export const ICON_NAMES = [
"keys",
"lifebuoy",
"light-bulb",
"light-bulb-on",
"lightening",
"line-in-circle",
"loading",
Expand All @@ -102,6 +103,7 @@ export const ICON_NAMES = [
"metrics",
"metrics-alt",
"minus",
"moon",
"no-cloud",
"pause",
"payment",
Expand Down
80 changes: 80 additions & 0 deletions src/components/icons/LightBulbOn.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
import { SVGAttributes } from "react";

const LightBulbOn = (props: SVGAttributes<SVGElement>) => (
<svg
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
xmlns="http://www.w3.org/2000/svg"
{...props}
>
<path
d="M15 15.1899H9"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
fillRule="evenodd"
clipRule="evenodd"
d="M8.54094 14.8962C6.76494 13.6412 5.69994 11.4502 6.07494 9.03819C6.48094 6.43119 8.65394 4.35019 11.2749 4.04319C14.9129 3.61619 17.9999 6.44819 17.9999 10.0002C17.9999 12.0252 16.9939 13.8122 15.4569 14.8982C15.1809 15.0932 14.9999 15.3952 14.9999 15.7332V18.5002C14.9999 19.8812 13.8809 21.0002 12.4999 21.0002H11.4999C10.1189 21.0002 8.99994 19.8812 8.99994 18.5002V15.7372C8.99994 15.3962 8.81794 15.0922 8.54094 14.8962Z"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M20 5.00006L21.19 3.81006"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M3.99957 15L2.80957 16.19"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M4.99957 4.00006L3.80957 2.81006"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M20 15L21.19 16.19"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M21 10H22.69"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M1.30957 10H2.99957"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
<path
d="M9 18H14.87"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
</svg>
);

export default LightBulbOn;
24 changes: 24 additions & 0 deletions src/components/icons/Moon.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import { SVGAttributes } from "react";

const Moon = (props: SVGAttributes<SVGElement>) => (
<svg
width="24"
height="24"
viewBox="0 0 24 24"
fill="none"
xmlns="http://www.w3.org/2000/svg"
{...props}
>
<path
fillRule="evenodd"
clipRule="evenodd"
d="M18.3945 13.0269C18.7245 12.8719 19.0765 13.1969 18.9845 13.5499C18.6705 14.7519 18.0535 15.8959 17.1035 16.8459C14.2825 19.6669 9.76953 19.7259 7.02153 16.9779C4.27353 14.2299 4.33353 9.71589 7.15453 6.89489C8.10453 5.94489 9.24753 5.32789 10.4505 5.01389C10.8035 4.92189 11.1275 5.27389 10.9735 5.60389C9.97153 7.74289 10.3005 10.3049 11.9975 12.0019C13.6935 13.6999 16.2555 14.0289 18.3945 13.0269V13.0269Z"
stroke="white"
strokeWidth="1.5"
strokeLinecap="round"
strokeLinejoin="round"
/>
</svg>
);

export default Moon;

0 comments on commit e479542

Please sign in to comment.