Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] main from lucide-icons:main #13

Merged
merged 33 commits into from
Sep 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
10c3662
fix(icons): changed `folder-search` icon (#2354)
jguddas Aug 14, 2024
6e65118
feat(icons): added `tickets-plane` icon (#2196)
jguddas Aug 16, 2024
5a2e3a2
fix(icons): changed `message-square-dashed` icon (#2374)
jguddas Aug 16, 2024
e391973
feat(docs): add standalone example for angular (#2383)
hiepxanh Aug 21, 2024
e3f78d7
fix(icons): fix stethoscope guideline violations (#2379)
karsa-mistmere Aug 21, 2024
79c2333
Add the sustainability catagory to some existing icons (#2384)
VIKTORVAV99 Aug 21, 2024
d7d1074
changed the value of major grid lines from 5 to 6 (#2382)
poswalsameer Aug 23, 2024
cbb4ed9
feat(icons): added `chart-gantt` icon (#2392)
jguddas Aug 23, 2024
25707c7
fix(icons): changed `contact-*` icon (#2391)
jguddas Aug 23, 2024
379df75
style: added text-wrap balance to TeamMemberCard.vue (#2381)
jguddas Aug 23, 2024
fd8d69a
chore(site): Update vitepress to `1.3.1` (#2377)
ericfennis Aug 23, 2024
b1087d3
fix(icons): Remove duplicated alias from chart-gantt
ericfennis Aug 23, 2024
aa4b1f0
fix(lucide-solid): compilation issues when starting up Vite Dev serve…
ericfennis Aug 23, 2024
944e428
feat(icons): added `trending-up-down` icon (#2372)
Alportan Aug 23, 2024
7837a04
fix(icons): fix volume icons, add volume-off (#2378)
karsa-mistmere Aug 23, 2024
0160bbe
fix(icons): changed `milestone` icon (#2281)
jguddas Aug 23, 2024
3c3f548
fix(icons): changed `backpack` icon (#2406)
jguddas Aug 25, 2024
efcede6
fix(icons): lucide-ize send icons (#2346)
karsa-mistmere Aug 31, 2024
e166880
Updated icons/battery-warning.svg (#2422)
jguddas Sep 1, 2024
cd0d4e1
build(deps-dev): bump svelte from 4.1.2 to 4.2.19 (#2419)
dependabot[bot] Sep 1, 2024
9c99fd8
feat(pr-comment): moved diff into separate section (#2421)
jguddas Sep 1, 2024
0ca2099
feat(icons): added `octagon-minus` icon (#2408)
jguddas Sep 1, 2024
65e49e2
fix(docs): fixes yarn workspace guide link (#2435)
karsa-mistmere Sep 6, 2024
ef090c7
fix(icons): changed `combine` icon (#2424)
jguddas Sep 6, 2024
e8ab1bc
chore: Update PNPM (#2376)
ericfennis Sep 6, 2024
e20e7a4
feat(icons): added `grid-2x2-plus` icon (#2362)
jguddas Sep 6, 2024
36a5a8b
fix(icons): arcified `book-open-*` icon (#2358)
jguddas Sep 6, 2024
30e0d55
fix(pr-comment): changed diff path url (#2426)
jguddas Sep 6, 2024
f70d5f5
fix(pr-comment): added missing details open tag (#2425)
jguddas Sep 6, 2024
19dd912
fix(icons): arcified `caravan` icon (#2423)
jguddas Sep 6, 2024
38e7431
add headphone-off svg & json in icon folder (#2445)
Need-an-AwP Sep 12, 2024
f0afdd4
feat(icons): added `clock-alert` icon (#2401)
jguddas Sep 12, 2024
478a624
Updated icons/messages-square.svg (#2429)
jguddas Sep 13, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/lucide-angular.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand All @@ -31,8 +29,6 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/[email protected]
with:
node-version: 18
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/lucide-font.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/lucide-preact.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/lucide-react-native.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/lucide-react.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand All @@ -33,8 +31,6 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/[email protected]
with:
node-version: 18
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/lucide-solid.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand All @@ -32,8 +30,6 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/[email protected]
with:
node-version: 18
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/lucide-static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/lucide-svelte.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand All @@ -32,8 +30,6 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/[email protected]
with:
node-version: 18
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/lucide-vue-next.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand All @@ -32,8 +30,6 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/[email protected]
with:
node-version: 18
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/lucide-vue.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand All @@ -32,8 +30,6 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/[email protected]
with:
node-version: 18
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/lucide.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand All @@ -32,8 +30,6 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/[email protected]
with:
node-version: 18
Expand Down
6 changes: 0 additions & 6 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down Expand Up @@ -89,8 +87,6 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v3
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down Expand Up @@ -121,8 +117,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ pnpm install # Install dependencies, including the workspace packages

### Packages -> PNPM Workspaces

To distribute different packages we use PNPM workspaces. Before you start make sure you are familiar with this concept. The concept of working in workspaces is created by Yarn, they have a well written introduction: [yarn workspaces](https://classic.yarnpkg.com/lang/enhttps://lucide.dev/docs/workspaces).
To distribute different packages we use [PNPM workspaces](https://pnpm.io/workspaces). Before you start make sure you are familiar with this concept. The concept of working in workspaces is created by Yarn, they have a well written introduction: [yarn workspaces](https://classic.yarnpkg.com/en/docs/workspaces).

The configured directory for workspaces is the [packages](https://github.com/lucide-icons/lucide/tree/main/packages) directory, located in the root directory. There you will find all the current packages from lucide.
There are more workspaces defined, see [`pnpm-workspace.yaml`](https://github.com/lucide-icons/lucide/blob/main/pnpm-workspace.yaml).
Expand Down
13 changes: 2 additions & 11 deletions docs/.vitepress/api/gh-icon/[...data].get.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export default eventHandler((event) => {
.map((_, idx, arr) => arr.slice(0, idx + 1).join('-'))
.reverse()
.find((groupName) => groupName in iconNodes);
if (backdropName) {
if (!(name in iconNodes) && backdropName) {
const iconNode = iconNodes[backdropName];

const LucideIcon = createLucideIcon(backdropName, iconNode);
Expand All @@ -39,18 +39,9 @@ export default eventHandler((event) => {
createElement(Backdrop, {
backdropString,
src,
color: name in iconNodes ? 'red' : '#777',
color: '#777',
}),
);
if (name in iconNodes) {
children.push(
createElement(Backdrop, {
backdropString: src,
src: backdropString,
color: 'lime',
}),
);
}
}

const svg = Buffer.from(
Expand Down
37 changes: 37 additions & 0 deletions docs/.vitepress/api/gh-icon/diff/[...data].get.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
import { eventHandler, setResponseHeader, defaultContentType } from 'h3';
import { renderToString, renderToStaticMarkup } from 'react-dom/server';
import { createElement } from 'react';
import Diff from '../../../lib/SvgPreview/Diff.tsx';
import iconNodes from '../../../data/iconNodes';
import createLucideIcon from 'lucide-react/src/createLucideIcon';

export default eventHandler((event) => {
const { params } = event.context;

const pathData = params.data.split('/');
const data = pathData.at(-1).slice(0, -4);
const [name] = pathData;

const newSrc = Buffer.from(data, 'base64')
.toString('utf8')
.replaceAll('\n', '')
.replace(/<svg[^>]*>|<\/svg>/g, '');

const children = [];

const oldSrc = iconNodes[name]
? renderToStaticMarkup(createElement(createLucideIcon(name, iconNodes[name])))
.replaceAll('\n', '')
.replace(/<svg[^>]*>|<\/svg>/g, '')
: '';

const svg = Buffer.from(
// We can't use jsx here, is not supported here by nitro.
renderToString(createElement(Diff, { oldSrc, newSrc, showGrid: true }, children)),
).toString('utf8');

defaultContentType(event, 'image/svg+xml');
setResponseHeader(event, 'Cache-Control', 'public,max-age=31536000');

return svg;
});
24 changes: 16 additions & 8 deletions docs/.vitepress/lib/SvgPreview/Backdrop.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,16 @@ import React from 'react';
interface BackdropProps {
src: string;
color?: string;
outline?: boolean;
backdropString: string;
}

const Backdrop = ({ src, color = 'red', backdropString }: BackdropProps): JSX.Element => {
const Backdrop = ({
src,
color = 'red',
outline = true,
backdropString,
}: BackdropProps): JSX.Element => {
const id = React.useId();
return (
<>
Expand Down Expand Up @@ -73,13 +79,15 @@ const Backdrop = ({ src, color = 'red', backdropString }: BackdropProps): JSX.El
opacity={0.75}
dangerouslySetInnerHTML={{ __html: src }}
/>
<g
stroke={color}
strokeWidth={2.25}
opacity={0.75}
mask={`url(#svg-preview-backdrop-mask-outline-${id})`}
dangerouslySetInnerHTML={{ __html: backdropString }}
/>
{outline && (
<g
stroke={color}
strokeWidth={2.25}
opacity={0.75}
mask={`url(#svg-preview-backdrop-mask-outline-${id})`}
dangerouslySetInnerHTML={{ __html: backdropString }}
/>
)}
</g>
</>
);
Expand Down
71 changes: 71 additions & 0 deletions docs/.vitepress/lib/SvgPreview/Diff.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
import React from 'react';
import Backdrop from './Backdrop.tsx';
import { darkModeCss, Grid } from './index.tsx';

const SvgPreview = React.forwardRef<
SVGSVGElement,
{
oldSrc: string;
newSrc: string;
} & React.SVGProps<SVGSVGElement>
>(({ oldSrc, newSrc, children, ...props }, ref) => {
return (
<svg
ref={ref}
xmlns="http://www.w3.org/2000/svg"
width={24}
height={24}
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
strokeWidth={2}
strokeLinecap="round"
strokeLinejoin="round"
{...props}
>
<style>{darkModeCss}</style>
<Grid
strokeWidth={0.1}
stroke="#777"
strokeOpacity={0.3}
radius={1}
/>
<mask
id="gray"
maskUnits="userSpaceOnUse"
>
<rect
x="0"
y="0"
width="24"
height="24"
fill="#000"
stroke="none"
/>
<g
stroke="#fff"
dangerouslySetInnerHTML={{ __html: oldSrc }}
/>
</mask>
<Backdrop
src=""
outline={false}
backdropString={`<g mask="url('#gray')">${newSrc}</g>`}
color="#777"
/>
<Backdrop
src={oldSrc}
backdropString={newSrc}
color="lime"
/>
<Backdrop
src={newSrc}
backdropString={oldSrc}
color="red"
/>
{children}
</svg>
);
});

export default SvgPreview;
Loading
Loading