mirror of
https://github.com/harvester/harvester-ui-extension.git
synced 2026-10-01 03:36:04 +08:00
feat: read addon displayname from label and add descheduler description (#644)
* refactor: display addon name from addon.harvesterhci.io/displayName label Signed-off-by: Andy Lee <andy.lee@suse.com> * refactor: add descheduler description Signed-off-by: Andy Lee <andy.lee@suse.com> --------- Signed-off-by: Andy Lee <andy.lee@suse.com>
This commit is contained in:
@@ -113,8 +113,9 @@ export default class HciAddonConfig extends HarvesterResource {
|
||||
|
||||
get displayName() {
|
||||
const isExperimental = this.metadata?.labels?.[HCI_ANNOTATIONS.ADDON_EXPERIMENTAL] === 'true';
|
||||
const name = this.metadata?.labels?.[HCI_ANNOTATIONS.ADDON_DISPLAYNAME] || this.metadata.name;
|
||||
|
||||
return isExperimental ? `${ this.metadata.name } (${ this.t('generic.experimental') })` : this.metadata.name;
|
||||
return isExperimental ? `${ name } (${ this.t('generic.experimental') })` : name;
|
||||
}
|
||||
|
||||
get customValidationRules() {
|
||||
|
||||
Reference in New Issue
Block a user