MCPcopy
hub / github.com/GitbookIO/gitbook / OpenAPITabsPanels

Function OpenAPITabsPanels

packages/react-openapi/src/OpenAPITabs.tsx:130–147  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

128 * It renders the content of the selected tab.
129 */
130export function OpenAPITabsPanels() {
131 const { selectedTab } = useOpenAPITabsContext();
132
133 if (!selectedTab) {
134 return null;
135 }
136
137 const key = selectedTab.key.toString();
138
139 return (
140 <TabPanel id={key} className="openapi-tabs-panel">
141 <div className="openapi-panel-body">{selectedTab.body}</div>
142 {selectedTab.footer ? (
143 <div className="openapi-panel-footer">{selectedTab.footer}</div>
144 ) : null}
145 </TabPanel>
146 );
147}

Callers

nothing calls this directly

Calls 2

useOpenAPITabsContextFunction · 0.85
toStringMethod · 0.80

Tested by

no test coverage detected