diff --git a/src/components/dialogs/hacs-download-dialog.ts b/src/components/dialogs/hacs-download-dialog.ts index be1c333b..d2f4d579 100644 --- a/src/components/dialogs/hacs-download-dialog.ts +++ b/src/components/dialogs/hacs-download-dialog.ts @@ -61,7 +61,7 @@ export class HacsDonwloadDialog extends HacsDialogBase { private _getInstallPath = memoizeOne((repository: RepositoryBase) => { let path: string = repository.local_path; - if (repository.category === "theme") { + if (["template", "theme"].includes(repository.category)) { path = `${path}/${repository.file_name}`; } return path; diff --git a/src/data/repository.ts b/src/data/repository.ts index 8b816d81..3e76cc15 100644 --- a/src/data/repository.ts +++ b/src/data/repository.ts @@ -6,6 +6,7 @@ export type RepositoryCategory = | "netdaemon" | "plugin" | "python_script" + | "template" | "theme"; export interface RepositoryBase { diff --git a/src/localize/languages/en.json b/src/localize/languages/en.json index b6ca9b0a..81992a6c 100644 --- a/src/localize/languages/en.json +++ b/src/localize/languages/en.json @@ -20,6 +20,7 @@ "repository": "Repository", "show": "Show", "theme": "Theme", + "template": "Template", "update": "Update", "updates": "Updates", "yes": "Yes" diff --git a/src/tools/category-icon.ts b/src/tools/category-icon.ts index ca3c1cfb..2f028440 100644 --- a/src/tools/category-icon.ts +++ b/src/tools/category-icon.ts @@ -1,4 +1,5 @@ import { + mdiCodeBraces, mdiDotNet, mdiLanguagePython, mdiPackageVariant, @@ -14,6 +15,7 @@ const _IconMap = { netdaemon: mdiDotNet, plugin: mdiViewDashboard, python_script: mdiLanguagePython, + template: mdiCodeBraces, theme: mdiPalette, };