Skip to content

Commit

Permalink
fix: hide gui view in external apps
Browse files Browse the repository at this point in the history
  • Loading branch information
AbhishekA1509 committed Nov 6, 2024
1 parent 28589df commit edb0463
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/components/v2/appDetails/appDetails.type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,7 @@ export enum ManifestCodeEditorMode {
CANCEL = 'cancel',
}

export interface ManifestActionPropsType extends ResourceInfoActionPropsType {
export interface ManifestActionPropsType extends ResourceInfoActionPropsType, Pick<NodeDetailPropsType, 'isExternalApp'> {
hideManagedFields: boolean
toggleManagedFields: (managedFieldsExist: boolean) => void
manifestViewRef: MutableRefObject<ManifestViewRefType>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ const NodeDetailComponent = ({
<div className="ml-4 mr-12 tab-cell-border" />
{manifestCodeEditorMode === ManifestCodeEditorMode.EDIT ? (
<div className="flex dc__gap-12">
{ToggleManifestConfigurationMode && (
{ToggleManifestConfigurationMode && !isExternalApp && (
<ToggleManifestConfigurationMode
mode={manifestFormConfigurationType}
handleToggle={handleToggleManifestConfigurationMode}
Expand Down Expand Up @@ -599,6 +599,7 @@ const NodeDetailComponent = ({
handleUpdateUnableToParseManifest={handleUpdateUnableToParseManifest}
handleManifestGUIErrors={handleManifestGUIError}
manifestGUIFormRef={manifestGUIFormRef}
isExternalApp={isExternalApp}
/>
</Route>
<Route path={`${path}/${NodeDetailTab.EVENTS}`}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ const ManifestComponent = ({
handleUpdateUnableToParseManifest,
handleManifestGUIErrors,
manifestGUIFormRef,
isExternalApp,
}: ManifestActionPropsType) => {
const location = useLocation()
const history = useHistory()
Expand Down Expand Up @@ -163,7 +164,7 @@ const ManifestComponent = ({
}, [error, secretViewAccess, desiredManifest, activeManifestEditorData, manifest, modifiedManifest, id, guiSchema])

const handleInitializeGUISchema = async (abortSignal: AbortSignal) => {
if (!getManifestGUISchema) {
if (!getManifestGUISchema || !isExternalApp) {
return
}

Expand Down

0 comments on commit edb0463

Please sign in to comment.