diff --git a/icon.schema.json b/icon.schema.json index 4bf4a0714..38ea133f7 100644 --- a/icon.schema.json +++ b/icon.schema.json @@ -141,7 +141,7 @@ "$defs": { "iconDeprecationReasons": { "type": "string", - "enum": ["icon.renamed"] + "enum": ["icon.design", "icon.use-case"] }, "aliasDeprecationReasons": { "type": "string", diff --git a/icons/badge-swiss-franc.json b/icons/badge-swiss-franc.json index e3df7c78f..8cae15f70 100644 --- a/icons/badge-swiss-franc.json +++ b/icons/badge-swiss-franc.json @@ -3,6 +3,8 @@ "contributors": [ "danielbayley" ], + "deprecated": true, + "deprecationReason": "icon.use-case", "use-cases": [], "tags": [ "discount", diff --git a/icons/receipt-swiss-franc.json b/icons/receipt-swiss-franc.json index fc4aaf7cc..3cb6a0305 100644 --- a/icons/receipt-swiss-franc.json +++ b/icons/receipt-swiss-franc.json @@ -4,6 +4,8 @@ "danielbayley", "karsa-mistmere" ], + "deprecated": true, + "deprecationReason": "icon.use-case", "use-cases": [], "tags": [ "bill", diff --git a/icons/swiss-franc.json b/icons/swiss-franc.json index caf59cb32..1313f7936 100644 --- a/icons/swiss-franc.json +++ b/icons/swiss-franc.json @@ -4,6 +4,8 @@ "ericfennis", "mittalyashu" ], + "deprecated": true, + "deprecationReason": "icon.use-case", "use-cases": [], "tags": [ "currency", diff --git a/lab/swiss-franc-circle.json b/lab/swiss-franc-circle.json index ea7e5e0a0..24383c81d 100644 --- a/lab/swiss-franc-circle.json +++ b/lab/swiss-franc-circle.json @@ -3,6 +3,8 @@ "contributors": [ "danielbayley" ], + "deprecated": true, + "deprecationReason": "icon.use-case", "tags": [ "monetization", "marketing", diff --git a/lab/swiss-franc-square.json b/lab/swiss-franc-square.json index 43d553d29..7c6b21fde 100644 --- a/lab/swiss-franc-square.json +++ b/lab/swiss-franc-square.json @@ -3,6 +3,8 @@ "contributors": [ "danielbayley" ], + "deprecated": true, + "deprecationReason": "icon.use-case", "tags": [ "monetization", "marketing", diff --git a/tools/build-icons/types.ts b/tools/build-icons/types.ts index a305e7a39..4ba3eee5b 100644 --- a/tools/build-icons/types.ts +++ b/tools/build-icons/types.ts @@ -32,7 +32,7 @@ export type AliasDeprecation = { deprecationReason: AliasDeprecationReason; }; -export type IconDeprecationReason = 'icon.renamed' | ''; +export type IconDeprecationReason = 'icon.design' | 'icon.use-case' | ''; export type IconMetadataBase = { categories: string[]; diff --git a/tools/build-icons/utils/deprecationReasonTemplate.ts b/tools/build-icons/utils/deprecationReasonTemplate.ts index 9386570a9..06f6fd729 100644 --- a/tools/build-icons/utils/deprecationReasonTemplate.ts +++ b/tools/build-icons/utils/deprecationReasonTemplate.ts @@ -16,6 +16,10 @@ export default function deprecationReasonTemplate( return `The icon was combined with another icon that shares the same use case, use {@link ${componentName}} instead.`; case 'alias.name': return `The name of this icon was changed because it didn't meet our guidelines anymore, use {@link ${componentName}} instead.`; + case 'icon.design': + return `Removed because the icon didn't meet our design guidelines.`; + case 'icon.use-case': + return `Removed because the depicted concept became obsolete and no longer had relevant use cases.`; default: throw new Error(`Unknown deprecation reason: ${deprecationReason}`); }