Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Core: Add JSDoc comments to manager-api APIs #22968

Merged
merged 16 commits into from
Jun 8, 2023
Prev Previous commit
Next Next commit
modules/layout
ndelangen committed Jun 7, 2023
commit 4f216c2b233c2fe4b99a251739226b118a293d1b
24 changes: 24 additions & 0 deletions code/lib/manager-api/src/modules/layout.ts
Original file line number Diff line number Diff line change
@@ -25,11 +25,35 @@ export interface SubState {
}

export interface SubAPI {
/**
* Toggles the fullscreen mode of the Storybook UI.
* @param toggled - Optional boolean value to set the fullscreen mode to. If not provided, it will toggle the current state.
*/
toggleFullscreen: (toggled?: boolean) => void;
/**
* Toggles the visibility of the panel in the Storybook UI.
* @param toggled - Optional boolean value to set the panel visibility to. If not provided, it will toggle the current state.
*/
togglePanel: (toggled?: boolean) => void;
/**
* Toggles the position of the panel in the Storybook UI.
* @param position - Optional string value to set the panel position to. If not provided, it will toggle between 'bottom' and 'right'.
*/
togglePanelPosition: (position?: API_PanelPositions) => void;
/**
* Toggles the visibility of the navigation bar in the Storybook UI.
* @param toggled - Optional boolean value to set the navigation bar visibility to. If not provided, it will toggle the current state.
*/
toggleNav: (toggled?: boolean) => void;
/**
* Toggles the visibility of the toolbar in the Storybook UI.
* @param toggled - Optional boolean value to set the toolbar visibility to. If not provided, it will toggle the current state.
*/
toggleToolbar: (toggled?: boolean) => void;
/**
* Sets the options for the Storybook UI.
* @param options - An object containing the options to set.
*/
setOptions: (options: any) => void;
}