MCPcopy Index your code
hub / github.com/dataease/SQLBot / SwaggerUI

Function SwaggerUI

frontend/public/swagger-ui-bundle.js:75547–75588  ·  view source on GitHub ↗
(s)

Source from the content-addressed store, hash-verified

75545 type_cast(_)
75546 )
75547 }
75548 function SwaggerUI(s) {
75549 const o = sources_query()(s),
75550 i = runtime()(),
75551 a = SwaggerUI.config.merge({}, SwaggerUI.config.defaults, i, s, o),
75552 u = factorization_system(a),
75553 _ = inline_plugin(a),
75554 w = new Store(u)
75555 w.register([a.plugins, _])
75556 const x = w.getSystem(),
75557 persistConfigs = (s) => {
75558 ;(w.setConfigs(s), x.configsActions.loaded())
75559 },
75560 updateSpec = (s) => {
75561 !o.url && 'object' == typeof s.spec && Object.keys(s.spec).length > 0
75562 ? (x.specActions.updateUrl(''),
75563 x.specActions.updateLoadingStatus('success'),
75564 x.specActions.updateSpec(JSON.stringify(s.spec)))
75565 : 'function' == typeof x.specActions.download &&
75566 s.url &&
75567 !s.urls &&
75568 (x.specActions.updateUrl(s.url), x.specActions.download(s.url))
75569 },
75570 render = (s) => {
75571 if (s.domNode) x.render(s.domNode, 'App')
75572 else if (s.dom_id) {
75573 const o = document.querySelector(s.dom_id)
75574 x.render(o, 'App')
75575 } else
75576 null === s.dom_id ||
75577 null === s.domNode ||
75578 console.error('Skipped rendering: no `dom_id` or `domNode` was specified')
75579 }
75580 return a.configUrl
75581 ? ((async () => {
75582 const { configUrl: s } = a,
75583 i = await sources_url({ url: s, system: x })(a),
75584 u = SwaggerUI.config.merge({}, a, i, o)
75585 ;(persistConfigs(u), null !== i && updateSpec(u), render(u))
75586 })(),
75587 x)
75588 : (persistConfigs(a), updateSpec(a), render(a), x)
75589 }
75590 ;((SwaggerUI.System = Store),
75591 (SwaggerUI.config = {

Callers

nothing calls this directly

Calls 10

registerMethod · 0.95
sources_queryFunction · 0.85
runtimeFunction · 0.85
factorization_systemFunction · 0.85
inline_pluginFunction · 0.85
sources_urlFunction · 0.85
persistConfigsFunction · 0.85
updateSpecFunction · 0.85
mergeMethod · 0.80
renderFunction · 0.70

Tested by

no test coverage detected