Skip to content

Commit

Permalink
SDK - add plain yaml editor
Browse files Browse the repository at this point in the history
  • Loading branch information
upalatucci committed Jul 15, 2022
1 parent b3d0c05 commit 2442324
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
Expand Up @@ -20,6 +20,7 @@ import {
UseUserSettings,
QuickStartsLoaderProps,
UseURLPoll,
YAMLEditorProps,
} from './internal-types';

export const ActivityItem: React.FC<ActivityItemProps> = require('@console/shared/src/components/dashboard/activity-card/ActivityItem')
Expand Down Expand Up @@ -66,3 +67,6 @@ export const useUserSettings: UseUserSettings = require('@console/shared/src/hoo
.useUserSettings;
export const useURLPoll: UseURLPoll = require('@console/internal/components/utils/url-poll-hook')
.useURLPoll;

export const YAMLEditor: YAMLEditorProps = require('@console/shared/src/components/editor/YAMLEditor')
.default
Expand Up @@ -283,3 +283,13 @@ export type UseURLPoll = <R>(
delay?: number,
...dependencies: any[]
) => [R, any, boolean];

export type YAMLEditorProps = {
value?: string;
options?: object;
minHeight?: string | number;
showShortcuts?: boolean;
toolbarLinks?: React.ReactNodeArray;
onChange?: (newValue, event) => {};
onSave?: () => {};
};

0 comments on commit 2442324

Please sign in to comment.