From b932ce8c572faff226d557d87d4972fe6a5d3938 Mon Sep 17 00:00:00 2001 From: blackwood821 <36967614+blackwood821@users.noreply.github.com> Date: Wed, 28 Aug 2024 04:33:54 -0500 Subject: [PATCH] Allow extensions to override node provider icons for cloud credentials (#11724) --- shell/edit/cloudcredential.vue | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/shell/edit/cloudcredential.vue b/shell/edit/cloudcredential.vue index 76ccd0250e2..09236d5afa0 100644 --- a/shell/edit/cloudcredential.vue +++ b/shell/edit/cloudcredential.vue @@ -152,13 +152,17 @@ export default { } for ( const id of types ) { - let bannerImage, bannerAbbrv; + let bannerAbbrv; - try { - bannerImage = require(`~shell/assets/images/providers/${ id }.svg`); - } catch (e) { - bannerImage = null; - bannerAbbrv = this.initialDisplayFor(id); + let bannerImage = this.$store.app.$plugin.getDynamic('image', `providers/${ id }.svg`); + + if (!bannerImage) { + try { + bannerImage = require(`~shell/assets/images/providers/${ id }.svg`); + } catch (e) { + bannerImage = null; + bannerAbbrv = this.initialDisplayFor(id); + } } out.push({