Commit Graph
132 Commits
Author SHA1 Message Date
Eric f8dfcec367 Merge branch 'main' of https://github.com/lucide-icons/lucide into icon-usage-context 2026-10-19 15:01:32 +02:00
Copilotericfenniscopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>Eric Fennis
55e223a3a1 feat(ci): auto-generate PR titles from added file paths (#4790)
* feat(ci): auto-generate PR titles from added file paths

* refactor(ci): single source of truth for conventional commit types

* ci: skip PR title generation when "Keep PR title" label is present

Co-authored-by: ericfennis <11825403+ericfennis@users.noreply.github.com>

* refactor(ci): align package path scopes with package.json names

* Apply changes to generated pr titles

* Add .github/conventional-commit-types.json to gitignore

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ericfennis <11825403+ericfennis@users.noreply.github.com>
Co-authored-by: Eric Fennis <eric.fennis@gmail.com>
2026-10-15 17:17:01 +02:00
Eric 1ef648145b adjust model 2026-10-09 12:05:24 +02:00
Claude 6983a6a175 feat(scripts): follow metadata instructions for described use-cases
Load the Use Cases section of .github/instructions/metadata.instructions.md
into the --describe prompt so generated use-cases match the repository
style, and make useCase an array of phrases per usage group.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Q2D9GYbnSV56MAVVhHPRhH
2026-10-09 09:46:01 +00:00
Claude fba5e3f3cc feat(scripts): retry timeouts and save icon usage progress
Retry 408 responses (and other transient errors) with backoff, only waiting
for the rate-limit reset on 403/429. Requests that still fail are skipped
with a warning instead of aborting the run, and the OpenAI client retries
too. Each icon is now described as soon as its searches finish and
--output is rewritten after every icon, so an interrupted run keeps its
results.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Q2D9GYbnSV56MAVVhHPRhH
2026-10-09 09:38:14 +00:00
55b9969b82 ci(lint): split lint jobs and annotate Prettier and JSON schema errors in PRs (#4982)
* ci: split lint-code into ESLint, Prettier and JSON Schema jobs with PR annotations

- ESLint: annotations via setup-node's built-in eslint-stylish problem matcher.
- Prettier: new scripts/lintFormat.mts formats unformatted files in memory, diffs
  them and emits line-level `::error` annotations with the expected code.
- JSON Schema: replace ajv-cli with a local ESLint rule (Ajv draft 2020-12) that
  validates icons/categories JSON against their `$schema` and reports at the
  offending property. eslint-plugin-json-schema-validator was not used because it
  runs Ajv in draft-07 mode and ignores `dependentRequired`.

All annotations use workflow commands, so they work on fork PRs with a read-only token.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FVxEtqNswEDq1N23taZYh8

* Improve root value check and property error handling

Enhance error reporting for JSON schema validation.

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* style(lint): format jsonSchemaPlugin with Prettier

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FVxEtqNswEDq1N23taZYh8

* test commit

* fix(lint): annotate syntax errors from Prettier and ESLint in PRs

- ESLint/JSON Schema jobs use a small GitHub formatter that prints `::error`
  workflow commands. setup-node's eslint-stylish matcher skipped parsing errors
  because they have no rule id.
- lintFormat.mts annotates Prettier syntax errors (exit code 2) at their line and
  column instead of only printing stderr, and still checks the other files.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FVxEtqNswEDq1N23taZYh8

* ci(lint): spell check icon and category metadata with cspell annotations

- New "Spelling" job runs scripts/lintSpelling.mts, which turns cspell findings
  into `::error` annotations (with cspell's suggested fix when it has one).
- cspell accepts both US and British English, ignores contributor usernames and
  deprecated `alias.typo` aliases.
- Add existing search tags and domain terms to .cspell/custom-words.txt so the
  current metadata passes.
- Add `lint:spelling` to `pnpm lint` and lint-staged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FVxEtqNswEDq1N23taZYh8

* fix(lint): pin JSON schemas per file set and drop typo tags

- json-schema/no-invalid now takes the schema from config (icon.schema.json for
  icons, category.schema.json for categories) and reports a `$schema` that
  points elsewhere, so metadata can't opt out of validation.
- Remove the misspelled `frigerator` and `sterisk` tags and their allowlist entries.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FVxEtqNswEDq1N23taZYh8

* fix(icons): split joined-word tags into separate words

Tags like `groupchat` and `timemachine` become `group chat` and `time machine`
so they read naturally and pass the spell check without allowlisting. Where the
spaced tag already existed (`smart home`) the joined one is dropped.

cspell now skips all alias names, since they are icon names that can't change
(e.g. the deprecated `palmtree` alias).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FVxEtqNswEDq1N23taZYh8

* Revert

* Try another error

* Revert error

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-10-09 11:30:00 +02:00
Claude 58db0a0b0b Merge remote-tracking branch 'origin/icon-usage-context' into icon-usage-context 2026-10-09 07:00:29 +00:00
Claude 77ac5c4685 feat(scripts): add --output to write icon usage as JSON
Writes { [icon]: [...usage] } to a file: grouped use cases with --describe,
otherwise every individual usage context. Implies --context.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Q2D9GYbnSV56MAVVhHPRhH
2026-10-09 07:00:21 +00:00
Eric 15c128336f Merge branch 'main' of https://github.com/lucide-icons/lucide into icon-usage-context 2026-10-09 08:50:01 +02:00
Claude 924b5fda27 feat(scripts): describe icon usage in context
Add --context and --describe to the icon usage script. --context extracts
how each matched icon is used (parent elements, labels, handlers, links,
snippet) and summarizes it per icon. --describe groups those usages into
use-case descriptions with an OpenAI model. Also adds --max-contexts and
--icons-file, accepts export names like Trash2, and allows a single icon.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Q2D9GYbnSV56MAVVhHPRhH
2026-10-09 06:41:45 +00:00
Karsa aace268b9b fix(github/actions): use canonical metadata instructions for PR suggestions (#4910) 2026-10-02 10:51:33 +02:00
Karsa ec3c3906f7 feat(scripts): added icon usage script 2026-08-31 17:54:23 +02:00
Eric FennisandCopilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> 15804aa9eb Potential fix for code scanning alert no. 31: Inefficient regular expression (#4723)
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
2026-08-19 09:36:16 +02:00
Copilotcopilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>Eric Fennis
75b55160aa chore(dev): upgrade ESLint to latest compatible stack (v10) (#4378)
* chore: upgrade eslint to v9 latest with compatible lint deps

Agent-Logs-Url: https://github.com/lucide-icons/lucide/sessions/f7c1f1b5-d213-4afa-91a8-b799a16397ec

* Fix eslint config

* Fix a lot of eslint errors

* Fix eslint

* Fix eslint errors

* Fix eslint errors

* Fix types

* Fix eslint warning

* Format code

* Add eslint 10

* Remove unused vars

* Update pnpm

* Update deps

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Eric Fennis <eric.fennis@gmail.com>
2026-08-18 13:09:22 +02:00
Karsa 0f7ac1f988 fix(scripts): removed toBeRemovedInVersion from all scripts and tools (#4674)
* fix(scripts): remove toBeRemovedInVersion from all scripts and tools

* fix(scripts): fixed linting
2026-08-06 14:28:58 +02:00
Jakob Guddas 74c46711c7 feat(analytics): add utm source and medium (#4596) 2026-07-25 12:26:26 +02:00
9ecaafbc4d feat(lab): Migrate lab to main repo. (#4521)
* Add directory

* Add lab check script

* Delete duplicated icons

* Fix the lab page

* Adjust paths

* update lockfile

* update lockfile

* fix(lab/planet): replace with guideline-compliant design

* Add install step

* Add second install step

* Adjust lab in site

* try this

* Fix workflow

* Add cspell

* Format code

* Temporary delete icons for copilot review

* Place back lab icons

* Apply suggestions from code review

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Update lock file

* Revert svg changes

* Fix list

* Rename filenames

* Format tsconfig

---------

Co-authored-by: Karsa <contact@karsa.org>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-07-24 15:05:40 +02:00
Karsa 8930dfa827 fix(scripts): fix typo in renameIcon.function.mts (#4514) 2026-07-02 11:41:51 +02:00
Eric FennisandCopilot Autofix powered by AI 283e4b2805 chore(suggest-tags): Update metadata suggestion script (#4462)
* feat(metadata): implement pull request metadata suggestions workflow and replace suggestTags script

* Switch to GPT 5

* Update comment description

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-06-13 12:28:04 +02:00
Karsa 7623e23f78 feat(docs): add Zephyr Cloud to Hero Backers tier & rework updateSponsors script to also handle, well, sponsors (#4226) 2026-03-28 07:48:26 +01:00
Jeremy VenegasandClaude Opus 4.6 ffff78a02f fix(scripts): correct import extension in optimizeStagedSvgs.mts (#4185)
The import references `processSvg.mjs` but the file is
`processSvg.mts`. This was missed in 4dda4324 when the
lint-staged config was updated to call `.mts` files directly.

The broken import causes the pre-commit hook to fail for any
commit that includes SVG changes, blocking external contributors
from committing locally.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-24 09:08:14 +01:00
Karsa 67c0485457 feat(scripts): added helper script to automatically update OpenCollective backers in all readmes (#4014)
feat(docs): upgraded backers as per the recurring contributions in the last 3 months
2026-01-22 11:27:39 +01:00
Jakob Guddas f183c3ba20 feat(preview-comment): add symmetry preview (#3823) 2025-12-05 09:11:17 +01:00
Jakob Guddas 341be34b1f feat(preview-comment): put x-ray at top if there are more than 7 changed icons to prevent them from being cut of (#3589) 2025-08-29 09:48:45 +02:00
Jakob Guddas 1c5a9dafc1 feat(dpi-preview): add previous version for easier comparison (#3532)
* feat(dpi-preview): add previous version for easier comparison

* feat(preview comment): add link to lucide studio to x-ray images (#3552)
2025-08-22 10:26:16 +02:00
Jakob GuddasandEric Fennis e71198d9b3 chore: icon alias improvements (#2861)
Co-authored-by: Eric Fennis <eric.fennis@gmail.com>
2025-07-30 16:52:50 +02:00
Eric Fennis 667bb8034d fix(icons): Rename location-edit to map-pin-pencil (#3462)
* Rename `location-edit` to `map-pin-pencil`

* Updated "aliases" object
2025-07-28 14:51:16 +02:00
Eric Fennis 69e99093b8 ci(suggest-tags): Fix types import 2025-07-04 17:32:32 +02:00
Eric Fennis 6f384680b4 ci(suggest-tags): Fix failing job 2025-07-04 17:27:07 +02:00
Eric Fennis 37135af384 ci(suggest-tags): Switch to pull_request_target with suggest tags 2025-06-30 21:49:06 +02:00
Eric Fennis d565b951d7 ci(suggest-tags): Fix tags suggestions 2025-06-30 20:25:12 +02:00
Eric Fennis 0e54626bdb ci(icons): Add ChatGPT tags suggestions on icon PRs (#3372)
* Add gpt tags

* Add github actions flow

* Add link so people can use the chat

* Fix workflow

* Add openai dep

* Add actions core

* Try gh pr review in actions

* Try with octokit

* Remove changed files part

* Try with createReview function

* Try this

* fix broken json file

* Turn on review by gh action

* Try this

* Update icons/trash.json

* Update the runner

* Remove added tags

* Add more checks
2025-06-27 17:11:00 +02:00
Eric Fennis 3e644fda2d chore(scripts): Refactor scripts to typescript (#3316)
* Adjust typescript types

* adjust types

* fix types in all helper files

* Fix types

* Migrate js files to ts files

* Refactor to TS files

* Rename extentions

* Adjust imports

* Fix builds

* Update lockfile

* Fix last typescript migration

* Fix entry path @lucide/outline-svg

* Fix types

* add checkout step

* format files

* Format files
2025-06-18 15:47:24 +02:00
Jakob Guddas 6c865ccd9a feat(ci): adds dpi preview for 16, 32 and 48px (#3048)
* feat(ci): adds dpi preview for 18, 32 and 48px

* Update DPI preview from 18px to 16px

* Consolidate DPI preview sections in markup
2025-04-18 15:02:00 +02:00
Eric Fennis 07f9d3ea79 ci(node): Use correct node version (#2877)
* ci(node): Use correct node version

* Remove overrides

* update lock file

* Change assert to with

* Remove duplicated version
2025-03-14 11:29:59 +01:00
Eric FennisandAurélien Richard aefb710e5c feat(@lucide/svelte): Lucide svelte 5 package (#2753)
* Lucide svelte (#1)

* Update peerDependencies to support Svelte 5

* Bump svelte version

* Bump @testing-library/svelte version

* Remove alias in vitest.config.ts that causes tests to fail due to deprecated svelte/internal API

* Convert to svelte 5 syntax

* Bump vite & @sveltejs/vite-plugin-svelte version

* Fix error during render when children prop is missing & fix components being mounted on the server during tests

* Update test snapshots to reflect the differences in the html generated by svelte 5

* Convert class attribute to new array syntax with built-in clsx

* Convert export template to svelte 5 syntax

* Move svelte 5 to separate directory

* Update snapshots

* Update docs

* fix(icon): change variable declaration from let to const in Icon.svelte

* Lucide svelte (#1) (#2727)

* Update peerDependencies to support Svelte 5

* Bump svelte version

* Bump @testing-library/svelte version

* Remove alias in vitest.config.ts that causes tests to fail due to deprecated svelte/internal API

* Convert to svelte 5 syntax

* Bump vite & @sveltejs/vite-plugin-svelte version

* Fix error during render when children prop is missing & fix components being mounted on the server during tests

* Update test snapshots to reflect the differences in the html generated by svelte 5

* Convert class attribute to new array syntax with built-in clsx

* Convert export template to svelte 5 syntax

* Revert changes in lucide-svelte library

* Update package lock

* Update test files

* Formatting

* Update clean command

* Fix build

* Update packages

* update deps

* Fix export script

* Format code

* Revert version number change in package json

* Update workflows

---------

Co-authored-by: Aurélien Richard <56389380+aurelienrichard@users.noreply.github.com>
2025-03-07 13:44:09 +01:00
Eric Fennis c96260d82a style(scripts): Fix formatting 2025-02-28 15:06:39 +01:00
Jakob Guddas 6ae047557e docs: updated guideline icons (#2676)
* docs: updated guideline icons

* Update docs/images/1px-border-radius.svg

* Update docs/images/1px-border-radius.svg

* Update docs/images/1px-padding.svg

* Update docs/images/24px-24px.svg

* Update docs/images/2px-element-spacing.svg

* Update docs/images/2px-stroke.svg
2025-02-28 11:11:48 +01:00
Eric Fennis a59c5de61a fix(scripts): Add extra const for path mapping 2025-02-24 10:28:54 +01:00
Eric Fennis 2bd0ae55fd fix(scripts): Add await to readSvgDirectory 2025-02-24 10:18:58 +01:00
Eric Fennis 1828a392c8 fix: Add await to checkIconsAndCategories script 2025-02-19 11:19:53 +01:00
Eric Fennis 50630b3aaf ci: Improve build speeds (#2778)
* Revert sync to async functions

* Replace more sync fs functions

* Format files

* Fix build svelte package
2025-02-10 14:13:52 +01:00
Eric Fennis 419d47019c fix(scripts): Fix auto formatting script (#2712)
* Fix ./scripts/generateNextJSAliases.mjs

* Fix generateChangeIconsMarkup scripts
2025-01-06 10:42:53 +01:00
Eric Fennis d30698cb38 ci(pull-request): Fix generate comments for empty changes (#2593) 2024-11-08 16:00:23 +01:00
Jakob Guddas f70d5f5169 fix(pr-comment): added missing details open tag (#2425) 2024-09-06 12:45:07 +02:00
Jakob Guddas 30e0d55b4a fix(pr-comment): changed diff path url (#2426) 2024-09-06 12:44:38 +02:00
Jakob Guddas 9c99fd809c feat(pr-comment): moved diff into separate section (#2421)
* feat(pr-comment): moved diff into separate section

* Update docs/.vitepress/lib/SvgPreview/Diff.tsx
2024-09-01 21:04:36 +02:00
Eric Fennis 0d2c6c457e refactor(scripts): Fix linting errors 2024-07-07 21:32:32 +02:00
Eric Fennis c761ec7b5e ci(pull-request): Fix workflows attempt #7 2024-07-01 21:28:11 +02:00
Eric Fennis bbd877a3ba ci(pull-request): Fix workflows attempt #6 2024-07-01 18:04:31 +02:00