-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #79 from rszwajko/restructure
Maintain dynamic plugin metadata inside module
- Loading branch information
Showing
14 changed files
with
156 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
4 changes: 2 additions & 2 deletions
4
src/extensions/HostsPageWrapper.tsx → src/modules/Hosts/HostsPageWrapper.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { EncodedExtension } from '@openshift/dynamic-plugin-sdk'; | ||
import { RoutePage } from '@openshift-console/dynamic-plugin-sdk'; | ||
import type { ConsolePluginMetadata } from '@openshift-console/dynamic-plugin-sdk-webpack/lib/schema/plugin-package'; | ||
|
||
export const exposedModules: ConsolePluginMetadata['exposedModules'] = { | ||
HostsPage: './modules/Hosts/HostsPageWrapper', | ||
}; | ||
|
||
export const extensions: EncodedExtension[] = [ | ||
{ | ||
type: 'console.page/route', | ||
properties: { | ||
component: { | ||
$codeRef: 'HostsPage', | ||
}, | ||
path: '/mtv/providers/vsphere/:providerName', | ||
exact: false, | ||
}, | ||
} as EncodedExtension<RoutePage>, | ||
]; |
4 changes: 2 additions & 2 deletions
4
src/extensions/MappingsWrapper.tsx → src/modules/Mappings/MappingsWrapper.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { EncodedExtension } from '@openshift/dynamic-plugin-sdk'; | ||
import { RoutePage } from '@openshift-console/dynamic-plugin-sdk'; | ||
import type { ConsolePluginMetadata } from '@openshift-console/dynamic-plugin-sdk-webpack/lib/schema/plugin-package'; | ||
|
||
export const exposedModules: ConsolePluginMetadata['exposedModules'] = { | ||
MappingsPage: './modules/Mappings/MappingsWrapper', | ||
}; | ||
|
||
export const extensions: EncodedExtension[] = [ | ||
{ | ||
type: 'console.page/route', | ||
properties: { | ||
component: { | ||
$codeRef: 'MappingsPage', | ||
}, | ||
path: '/mtv/mappings', | ||
exact: true, | ||
}, | ||
} as EncodedExtension<RoutePage>, | ||
]; |
4 changes: 2 additions & 2 deletions
4
src/extensions/PlanWizardWrapper.tsx → src/modules/Plans/PlanWizardWrapper.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
src/extensions/PlansWrapper.tsx → src/modules/Plans/PlansWrapper.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import { EncodedExtension } from '@openshift/dynamic-plugin-sdk'; | ||
import { RoutePage } from '@openshift-console/dynamic-plugin-sdk'; | ||
import type { ConsolePluginMetadata } from '@openshift-console/dynamic-plugin-sdk-webpack/lib/schema/plugin-package'; | ||
|
||
export const exposedModules: ConsolePluginMetadata['exposedModules'] = { | ||
PlansPage: './modules/Plans/PlansWrapper', | ||
PlanWizard: './modules/Plans/PlanWizardWrapper', | ||
}; | ||
|
||
export const extensions: EncodedExtension[] = [ | ||
{ | ||
type: 'console.page/route', | ||
properties: { | ||
component: { | ||
$codeRef: 'PlansPage', | ||
}, | ||
path: '/mtv/plans', | ||
exact: true, | ||
}, | ||
} as EncodedExtension<RoutePage>, | ||
|
||
{ | ||
type: 'console.page/route', | ||
properties: { | ||
component: { | ||
$codeRef: 'PlanWizard', | ||
}, | ||
path: '/mtv/plans/create', | ||
exact: true, | ||
}, | ||
} as EncodedExtension<RoutePage>, | ||
|
||
{ | ||
type: 'console.page/route', | ||
properties: { | ||
component: { | ||
$codeRef: 'PlanWizard', | ||
}, | ||
path: ['/mtv/plans/:planName/edit', '/mtv/plans/:planName/duplicate'], | ||
exact: false, | ||
}, | ||
} as EncodedExtension<RoutePage>, | ||
]; |
4 changes: 2 additions & 2 deletions
4
src/extensions/ProvidersWrapper.tsx → src/modules/Providers/ProvidersWrapper.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { EncodedExtension } from '@openshift/dynamic-plugin-sdk'; | ||
import { RoutePage } from '@openshift-console/dynamic-plugin-sdk'; | ||
import type { ConsolePluginMetadata } from '@openshift-console/dynamic-plugin-sdk-webpack/lib/schema/plugin-package'; | ||
|
||
export const exposedModules: ConsolePluginMetadata['exposedModules'] = { | ||
ProvidersPage: './modules/Providers/ProvidersWrapper', | ||
}; | ||
|
||
export const extensions: EncodedExtension[] = [ | ||
{ | ||
type: 'console.page/route', | ||
properties: { | ||
component: { | ||
$codeRef: 'ProvidersPage', | ||
}, | ||
path: ['/mtv/providers', '/mtv/providers/:providerType'], | ||
exact: true, | ||
}, | ||
} as EncodedExtension<RoutePage>, | ||
]; |
3 changes: 1 addition & 2 deletions
3
src/extensions/VMMigrationDetailsWrapper.tsx → ...tionDetails/VMMigrationDetailsWrapper.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { EncodedExtension } from '@openshift/dynamic-plugin-sdk'; | ||
import { RoutePage } from '@openshift-console/dynamic-plugin-sdk'; | ||
import type { ConsolePluginMetadata } from '@openshift-console/dynamic-plugin-sdk-webpack/lib/schema/plugin-package'; | ||
|
||
export const exposedModules: ConsolePluginMetadata['exposedModules'] = { | ||
VMMigrationDetails: './modules/VmMigrationDetails/VMMigrationDetailsWrapper', | ||
}; | ||
|
||
export const extensions: EncodedExtension[] = [ | ||
{ | ||
type: 'console.page/route', | ||
properties: { | ||
component: { | ||
$codeRef: 'VMMigrationDetails', | ||
}, | ||
path: '/mtv/plans/:planName', | ||
exact: false, | ||
}, | ||
} as EncodedExtension<RoutePage>, | ||
]; |