diff --git a/public/assets/Ark@1x.svg b/public/assets/Ark@1x.svg
index 95e26baf552..2173ac158ae 100644
--- a/public/assets/Ark@1x.svg
+++ b/public/assets/Ark@1x.svg
@@ -1,3 +1,3 @@
diff --git a/public/assets/CSGO2.svg b/public/assets/CSGO2.svg
index 7157526a6f0..a138aa57549 100644
--- a/public/assets/CSGO2.svg
+++ b/public/assets/CSGO2.svg
@@ -1,3 +1,3 @@
diff --git a/public/assets/Rust.svg b/public/assets/Rust.svg
index 66707193cb3..afffc09fbc1 100644
--- a/public/assets/Rust.svg
+++ b/public/assets/Rust.svg
@@ -1,3 +1,3 @@
diff --git a/public/assets/Terraria.svg b/public/assets/Terraria.svg
index 71f0f922c8c..f81c05ee2cb 100644
--- a/public/assets/Terraria.svg
+++ b/public/assets/Terraria.svg
@@ -1,3 +1,3 @@
diff --git a/src/features/linodes/LinodesCreate/LinodeCreateContainer.tsx b/src/features/linodes/LinodesCreate/LinodeCreateContainer.tsx
index 8d5180b23cb..ac75745dba1 100644
--- a/src/features/linodes/LinodesCreate/LinodeCreateContainer.tsx
+++ b/src/features/linodes/LinodesCreate/LinodeCreateContainer.tsx
@@ -149,7 +149,7 @@ class LinodeCreateContainer extends React.PureComponent {
.then(response => {
this.setState({
appInstancesLoading: false,
- appInstances: response.data
+ appInstances: response
});
})
.catch(e => {
diff --git a/src/features/linodes/LinodesCreate/SelectAppPanel.tsx b/src/features/linodes/LinodesCreate/SelectAppPanel.tsx
index 5d95a19899b..d1bcf0d3e1f 100644
--- a/src/features/linodes/LinodesCreate/SelectAppPanel.tsx
+++ b/src/features/linodes/LinodesCreate/SelectAppPanel.tsx
@@ -10,8 +10,9 @@ import ErrorState from 'src/components/ErrorState';
import Grid from 'src/components/Grid';
import LinearProgress from 'src/components/LinearProgress';
import SelectionCard from 'src/components/SelectionCard';
+import { APP_ROOT } from 'src/constants';
import Panel from './Panel';
-
+import { iconMap } from './TabbedContent/formUtilities';
import { AppsData } from './types';
type ClassNames = 'flatImagePanelSelections' | 'panel' | 'loading';
@@ -98,6 +99,7 @@ const SelectAppPanel: React.SFC = props => {
handleClick={handleClick}
disabled={disabled}
id={eachApp.id}
+ iconUrl={iconMap[eachApp.id]}
/>
))}
@@ -120,6 +122,7 @@ interface SelectionProps {
stackScriptImages: string[],
userDefinedFields: Linode.StackScript.UserDefinedField[]
) => void;
+ iconUrl: string;
id: number;
label: string;
username: string;
@@ -149,14 +152,14 @@ class SelectionCardWrapper extends React.PureComponent {
};
render() {
- const { id, checked, label, disabled } = this.props;
+ const { iconUrl, id, checked, label, disabled } = this.props;
return (
{
- return ;
+ return ;
}}
heading={label}
subheadings={['']}
diff --git a/src/features/linodes/LinodesCreate/TabbedContent/formUtilities.ts b/src/features/linodes/LinodesCreate/TabbedContent/formUtilities.ts
index a9488bcd589..e166bfb7392 100644
--- a/src/features/linodes/LinodesCreate/TabbedContent/formUtilities.ts
+++ b/src/features/linodes/LinodesCreate/TabbedContent/formUtilities.ts
@@ -40,5 +40,32 @@ export const filterUDFErrors = (
export const getCloudApps = (params?: any, filter?: any) =>
getStackscripts(params, {
...filter,
- username: 'capuk'
+ username: 'linode'
+ }).then(response => {
+ return response.data
+ .filter(script => {
+ return Object.keys(iconMap).includes(String(script.id));
+ })
+ .map(script => ({
+ // so sorry about this
+ ...script,
+ label: script.label.replace('One-Click', '').replace('- OneClick', '')
+ }));
});
+
+export const iconMap = {
+ 401705: '/assets/Terraria.svg',
+ 401699: '/assets/Ark@1x.svg',
+ 401704: '/assets/TF2.svg',
+ 401703: '/assets/Rust.svg',
+ 401707: '/assets/GitLab.svg',
+ 401709: '/assets/Minecraft.svg',
+ 401698: '/assets/Drupal.svg',
+ 401706: '/assets/Wireguard.svg',
+ 401708: '/assets/WooCommerce.svg',
+ 401697: '/assets/WordPress.svg',
+ 401700: '/assets/CSGO2.svg',
+ 401701: '/assets/LAMP.svg',
+ 401702: '/assets/MERN.svg',
+ 401719: '/assets/OpenVPN.svg'
+};