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

feat(icons): add deprecationReason and alias deprecation feature #1960

Merged
merged 21 commits into from
May 22, 2024
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
f8995ac
feat(icons): add deprecationReason and alias deprecation feature
Mar 8, 2024
b9ea801
chore(tools): run prettier. again.
Mar 8, 2024
e98b58d
Merge branch 'main' into feat/icon-alias-deprecation-reasons
Mar 8, 2024
1fedcfe
Merge branch 'main' into feat/icon-alias-deprecation-reasons
Mar 8, 2024
79989d4
Merge branch 'main' into feat/icon-alias-deprecation-reasons
Mar 8, 2024
d51aa9b
fix(scripts): overall alias as object support
Mar 8, 2024
3032134
fix(icon.schema.json): add dependentRequired on deprecated properties
Mar 8, 2024
ef86b03
fix(icon.schema.json): remove unicode for now
Mar 8, 2024
90903ce
fix(icon.schema.json): use const true for deprecated
Mar 8, 2024
d939863
fix(build): convert deprecation reason to enum
Mar 9, 2024
855861a
fix(build): fix linting of icon.schema.json
Mar 9, 2024
8a9136b
fix(build): renamed gracePeriod => toBeRemovedInVersion
Mar 9, 2024
bab4eb1
fix(build): fix aliases map in related icons generation
Mar 11, 2024
353faf4
fix(build): deprecate aliases using numbers
Mar 11, 2024
5a025ad
feat(icon-schema): separate deprecation reason enumerations, extract …
May 13, 2024
1aab12d
fix(icon-schema): fix linting
May 13, 2024
3640c35
Update tools/build-icons/utils/deprecationReasonTemplate.mjs
karsa-mistmere May 13, 2024
3d073e1
Merge branch 'main' into feat/icon-alias-deprecation-reasons
jguddas May 17, 2024
d693064
Merge branch 'main' into feat/icon-alias-deprecation-reasons
May 22, 2024
589e141
fix(icons): add deprecation reason to some more icons
May 22, 2024
2a3d796
fix(docs): fix linting issue
May 22, 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
50 changes: 47 additions & 3 deletions icon.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,32 @@
"aliases": {
"type": "array",
"items": {
"type": "string"
"oneOf": [
{
"type": "string"
},
{
"type": "object",
"properties": {
"name": {
"type": "string"
},
"deprecated": {
"const": true
},
"deprecationReason": {
"$ref": "#/$defs/deprecationReasons"
},
"toBeRemovedInVersion": {
"$ref": "#/$defs/versionNumber",
"description": "The version this icon will be removed in."
}
},
"dependentRequired": {
"deprecated": ["deprecationReason", "toBeRemovedInVersion"]
}
}
]
},
"uniqueItems": true
},
Expand Down Expand Up @@ -49,8 +74,27 @@
"uniqueItems": true
},
"deprecated": {
"type": "boolean",
"default": false
"const": true
},
"deprecationReason": {
"$ref": "#/$defs/deprecationReasons"
},
"toBeRemovedInVersion": {
"$ref": "#/$defs/versionNumber",
"description": "The version this icon will be removed in."
}
},
"dependentRequired": {
"deprecated": ["deprecationReason", "toBeRemovedInVersion"]
},
"$defs": {
"deprecationReasons": {
"type": "string",
"enum": ["icon.brand", "alias.typo", "alias.name"]
jguddas marked this conversation as resolved.
Show resolved Hide resolved
},
"versionNumber": {
"type": "string",
"pattern": "v[0-9]+(\\.[0-9]+)+"
}
},
"description": "A JSON Schema for icons defined by Lucide Icons."
Expand Down
7 changes: 6 additions & 1 deletion icons/between-horizontal-end.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@
"account"
],
"aliases": [
"between-horizonal-end"
{
"name": "between-horizonal-end",
"deprecated": true,
"deprecationReason": "alias.typo",
"toBeRemovedInVersion": "v1.0"
}
]
}
7 changes: 6 additions & 1 deletion icons/between-horizontal-start.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@
"account"
],
"aliases": [
"between-horizonal-start"
{
"name": "between-horizonal-start",
"deprecated": true,
"deprecationReason": "alias.typo",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/chrome.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"ericfennis"
Expand Down
7 changes: 6 additions & 1 deletion icons/circle-user-round.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@
"shapes"
],
"aliases": [
"user-circle-2"
{
"name": "user-circle-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
7 changes: 6 additions & 1 deletion icons/code-xml.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@
"development"
],
"aliases": [
"code-2"
{
"name": "code-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/codepen.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"ericfennis"
Expand Down
2 changes: 2 additions & 0 deletions icons/codesandbox.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
7 changes: 6 additions & 1 deletion icons/contact-round.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@
"social"
],
"aliases": [
"contact-2"
{
"name": "contact-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/dribbble.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"ahtohbi4"
],
Expand Down
7 changes: 6 additions & 1 deletion icons/earth.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
"navigation"
],
"aliases": [
"globe-2"
{
"name": "globe-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/facebook.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
2 changes: 2 additions & 0 deletions icons/figma.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
7 changes: 6 additions & 1 deletion icons/file-cog.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@
"files"
],
"aliases": [
"file-cog-2"
{
"name": "file-cog-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
11 changes: 8 additions & 3 deletions icons/folder-cog.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
{
"$schema": "../icon.schema.json",
"aliases": [
"folder-cog-2"
],
"contributors": [
"karsa-mistmere"
],
Expand All @@ -17,5 +14,13 @@
],
"categories": [
"files"
],
"aliases": [
{
"name": "folder-cog-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/framer.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
2 changes: 2 additions & 0 deletions icons/github.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
2 changes: 2 additions & 0 deletions icons/gitlab.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
2 changes: 2 additions & 0 deletions icons/instagram.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
7 changes: 6 additions & 1 deletion icons/laptop-minimal.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@
"devices"
],
"aliases": [
"laptop-2"
{
"name": "laptop-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
7 changes: 6 additions & 1 deletion icons/pen-line.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@
"tools"
],
"aliases": [
"edit-3"
{
"name": "edit-3",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
7 changes: 6 additions & 1 deletion icons/pen.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@
"tools"
],
"aliases": [
"edit-2"
{
"name": "edit-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/pocket.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
7 changes: 6 additions & 1 deletion icons/send-horizontal.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
"connectivity"
],
"aliases": [
"send-horizonal"
{
"name": "send-horizonal",
"deprecated": true,
"deprecationReason": "alias.typo",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/slack.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"ashygee",
Expand Down
7 changes: 6 additions & 1 deletion icons/square-user-round.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@
"shapes"
],
"aliases": [
"user-square-2"
{
"name": "user-square-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
2 changes: 2 additions & 0 deletions icons/trello.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"bdbch",
"csandman",
Expand Down
2 changes: 2 additions & 0 deletions icons/twitch.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"ahtohbi4",
"johnletey"
Expand Down
2 changes: 2 additions & 0 deletions icons/twitter.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"$schema": "../icon.schema.json",
"deprecated": true,
"deprecationReason": "icon.brand",
"toBeRemovedInVersion": "v1.0",
"contributors": [
"colebemis",
"csandman",
Expand Down
7 changes: 6 additions & 1 deletion icons/university.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
"maps"
],
"aliases": [
"school-2"
{
"name": "school-2",
"deprecated": true,
"deprecationReason": "alias.name",
"toBeRemovedInVersion": "v1.0"
}
]
}
Loading
Loading