@techdocs/cli 1.0.0 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +51 -0
- package/dist/cjs/PublisherConfig-162efac5.cjs.js.map +1 -1
- package/dist/cjs/{generate-143a6de3.cjs.js → generate-67f1ab98.cjs.js} +3 -1
- package/dist/cjs/generate-67f1ab98.cjs.js.map +1 -0
- package/dist/cjs/migrate-181e95f5.cjs.js.map +1 -1
- package/dist/cjs/{mkdocs-30f530ff.cjs.js → mkdocs-7c045a2a.cjs.js} +3 -2
- package/dist/cjs/{mkdocs-30f530ff.cjs.js.map → mkdocs-7c045a2a.cjs.js.map} +1 -1
- package/dist/cjs/{mkdocsServer-758a3ae9.cjs.js → mkdocsServer-0af6527d.cjs.js} +2 -1
- package/dist/cjs/mkdocsServer-0af6527d.cjs.js.map +1 -0
- package/dist/cjs/publish-7bf1e5f7.cjs.js.map +1 -1
- package/dist/cjs/{serve-21d1e885.cjs.js → serve-66a37894.cjs.js} +3 -2
- package/dist/cjs/{serve-21d1e885.cjs.js.map → serve-66a37894.cjs.js.map} +1 -1
- package/dist/cjs/utility-51f4a306.cjs.js.map +1 -1
- package/dist/embedded-app/.config-schema.json +9 -0
- package/dist/embedded-app/index.html +1 -1
- package/dist/embedded-app/static/{1553.925835b9.chunk.js → 1553.a26067ce.chunk.js} +1 -1
- package/dist/embedded-app/static/1553.a26067ce.chunk.js.map +1 -0
- package/dist/embedded-app/static/{1959.2eb957a4.chunk.js → 1959.38a96998.chunk.js} +1 -1
- package/dist/embedded-app/static/1959.38a96998.chunk.js.map +1 -0
- package/dist/embedded-app/static/{2426.f9952783.chunk.js → 2426.56947b7f.chunk.js} +1 -1
- package/dist/embedded-app/static/{8061.fd1f45d1.chunk.js.map → 2426.56947b7f.chunk.js.map} +1 -1
- package/dist/embedded-app/static/3860.da7e5f63.chunk.js.map +1 -1
- package/dist/embedded-app/static/{390.cd301478.chunk.js → 390.a67c5759.chunk.js} +1 -1
- package/dist/embedded-app/static/390.a67c5759.chunk.js.map +1 -0
- package/dist/embedded-app/static/{4022.313be9b5.chunk.js → 4022.fa355d30.chunk.js} +1 -1
- package/dist/embedded-app/static/4022.fa355d30.chunk.js.map +1 -0
- package/dist/embedded-app/static/{6235.b3634d50.chunk.js → 6235.ec27c62a.chunk.js} +1 -1
- package/dist/embedded-app/static/6235.ec27c62a.chunk.js.map +1 -0
- package/dist/embedded-app/static/{6583.c98b5125.chunk.js → 6583.9071ac96.chunk.js} +1 -1
- package/dist/embedded-app/static/6583.9071ac96.chunk.js.map +1 -0
- package/dist/embedded-app/static/{7110.527cc68b.chunk.js → 7110.7d2c1934.chunk.js} +2 -2
- package/dist/embedded-app/static/7110.7d2c1934.chunk.js.map +1 -0
- package/dist/embedded-app/static/7758.f316879f.chunk.js +3 -0
- package/dist/embedded-app/static/7758.f316879f.chunk.js.map +1 -0
- package/dist/embedded-app/static/{8061.fd1f45d1.chunk.js → 8061.ec7736bc.chunk.js} +1 -1
- package/dist/embedded-app/static/{4022.313be9b5.chunk.js.map → 8061.ec7736bc.chunk.js.map} +1 -1
- package/dist/embedded-app/static/{8718.cd7bb850.chunk.js → 8718.8f60efd2.chunk.js} +2 -2
- package/dist/embedded-app/static/8718.8f60efd2.chunk.js.map +1 -0
- package/dist/embedded-app/static/{8792.867bf73e.chunk.js → 8792.8a74fd9c.chunk.js} +1 -1
- package/dist/embedded-app/static/8792.8a74fd9c.chunk.js.map +1 -0
- package/dist/embedded-app/static/{9028.200536ea.chunk.js → 9028.77f3e990.chunk.js} +1 -1
- package/dist/embedded-app/static/9028.77f3e990.chunk.js.map +1 -0
- package/dist/embedded-app/static/main.3efd9679.js +476 -0
- package/dist/embedded-app/static/main.3efd9679.js.map +1 -0
- package/dist/embedded-app/static/module-ajv.d6f6d109.js +10 -0
- package/dist/embedded-app/static/module-ajv.d6f6d109.js.map +1 -0
- package/dist/embedded-app/static/module-aria-query.f720b73c.js +9 -0
- package/dist/embedded-app/static/module-aria-query.f720b73c.js.map +1 -0
- package/dist/embedded-app/static/module-date-fns.a08d117e.js.map +1 -1
- package/dist/embedded-app/static/module-hot-loader.7955a91c.js +32 -0
- package/dist/embedded-app/static/module-hot-loader.7955a91c.js.map +1 -0
- package/dist/embedded-app/static/module-jss.cb0efade.js +38 -0
- package/dist/embedded-app/static/module-jss.cb0efade.js.map +1 -0
- package/dist/embedded-app/static/{module-lodash.f158b49a.js → module-lodash.055be129.js} +1 -1
- package/dist/embedded-app/static/module-lodash.055be129.js.map +1 -0
- package/dist/embedded-app/static/module-material-table.cbad0c40.js.map +1 -1
- package/dist/embedded-app/static/{module-material-ui.3c0e2d92.js → module-material-ui.84a6ac87.js} +11 -11
- package/dist/embedded-app/static/module-material-ui.84a6ac87.js.map +1 -0
- package/dist/embedded-app/static/module-react-beautiful-dnd.a9014a2e.js +3 -3
- package/dist/embedded-app/static/module-react-beautiful-dnd.a9014a2e.js.map +1 -1
- package/dist/embedded-app/static/module-testing-library.633b23c6.js +57 -0
- package/dist/embedded-app/static/module-testing-library.633b23c6.js.map +1 -0
- package/dist/embedded-app/static/{module-yaml.574c3290.js → module-yaml.57b26e04.js} +1 -1
- package/dist/embedded-app/static/module-yaml.57b26e04.js.map +1 -0
- package/dist/embedded-app/static/react-syntax-highlighter/lowlight-import.c14d776e.chunk.js +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter/lowlight-import.c14d776e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_abnf.e6a0eba8.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_accesslog.4beaa91a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_actionscript.292b574b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ada.17b0c1e9.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_angelscript.2fa22084.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_apache.a966b924.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_applescript.398efb2d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_arcade.efd9310b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_arduino.f5b09530.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_armasm.07c7365e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_asciidoc.e71b2b97.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_aspectj.d4578a11.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_autohotkey.fbaa0237.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_autoit.6d4c5214.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_avrasm.18f58e18.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_awk.c27dd539.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_axapta.590ecb33.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_bash.6dadcb4e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_basic.6316c507.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_bnf.3c2aef44.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_brainfuck.5c72cafc.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_c.e9772f0f.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_cLike.df1dc03b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_cal.ab9f187a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_capnproto.a5523056.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ceylon.3365c59e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_clean.41d80232.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_clojure.1f816fc6.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_clojureRepl.df5f7b77.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_cmake.1d3ebd62.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_coffeescript.7d35d62c.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_coq.18dba36b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_cos.2a2085d6.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_cpp.bd92fb21.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_crmsh.f9f13b4d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_crystal.92c08c0a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_csharp.8b48e8b8.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_csp.a08eda06.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_css.04989873.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_d.daf9e0eb.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_dart.2047310e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_delphi.2e20b712.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_diff.b50d2d6c.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_django.d53e0f58.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_dns.8313f2da.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_dockerfile.4059e474.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_dos.6e4bdd05.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_dsconfig.cbf005ae.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_dts.25d6bc4a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_dust.9a1225a3.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ebnf.14f00049.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_elixir.f723f0f4.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_elm.b6871fdc.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_erb.f0b33cfd.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_erlang.269e6936.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_erlangRepl.5b8fbb4b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_excel.76415c4c.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_fix.f3d3d961.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_flix.4bab53eb.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_fortran.4d94061b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_fsharp.38ba8914.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_gams.e8178c8d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_gauss.d8121ec2.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_gcode.683bb963.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_gherkin.a89ed74e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_glsl.ad325f79.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_gml.8b729794.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_go.86cc8880.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_golo.df21ae57.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_gradle.ccdf8a11.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_groovy.2f3d05a7.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_haml.3282d98e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_handlebars.d75a2b1d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_haskell.fe9946b0.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_haxe.de3c0102.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_hsp.79b4f6a1.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_htmlbars.f3762ac8.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_http.3471f585.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_hy.90970bfa.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_inform7.3a00f6f3.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ini.41e881fe.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_irpf90.f7dcd64c.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_isbl.0ef17f5f.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_java.28b8c66f.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_javascript.6b1cd365.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_jbossCli.3e9aa8ff.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_json.64a72c69.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_julia.7beb73b2.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_juliaRepl.3b16b540.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_kotlin.72e6c744.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_lasso.206ae0f8.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_latex.c8014dd5.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ldif.a987362a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_leaf.24aff4d8.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_less.fde51777.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_lisp.3b0bfd87.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_livecodeserver.28bd16e8.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_livescript.dfedba67.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_llvm.359b16e6.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_lsl.f12ea89d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_lua.d5869324.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_makefile.6b78bb75.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_markdown.4f56f83c.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_mathematica.d2775785.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_matlab.14a1484d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_maxima.d0446e84.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_mel.02270ff9.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_mercury.6f3d5a69.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_mipsasm.aab1a206.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_mizar.568906a3.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_mojolicious.c84fcc34.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_monkey.feab688a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_moonscript.19af75b8.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_n1ql.b2ee87fb.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_nginx.4a16400b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_nim.9fcf8db5.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_nix.1f574423.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_nodeRepl.f2587359.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_nsis.3077a1bf.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_objectivec.9d926142.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ocaml.04b343a0.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_oneC.37768899.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_openscad.8491cf45.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_oxygene.643eb07c.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_parser3.75ed358d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_perl.2efba989.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_pf.2186e4a7.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_pgsql.843ed847.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_php.7ea88954.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_phpTemplate.fd6719b2.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_plaintext.f1d2959a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_pony.f0b88195.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_powershell.dce833ca.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_processing.36916075.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_profile.db33af61.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_prolog.2a05e187.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_properties.0df57f0a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_protobuf.3e3b4e57.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_puppet.2fb0bb40.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_purebasic.a63201c1.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_python.770df37e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_pythonRepl.3ca17ff5.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_q.d9b193e3.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_qml.616441e2.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_r.07dc3712.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_reasonml.85183415.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_rib.2ea1e5aa.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_roboconf.5075ae03.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_routeros.d33242ea.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_rsl.9c1785fc.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ruby.b7a2f7ab.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_ruleslanguage.011d4ccd.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_rust.a6f6a618.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_sas.110925b5.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_scala.0dddfa51.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_scheme.38da3457.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_scilab.4554b692.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_scss.a291bfd5.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_shell.c8637fd3.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_smali.095fbc33.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_smalltalk.82bb2ca1.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_sml.db637ab9.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_sqf.c168c06c.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_sql.ace85109.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_sqlMore.beecb919.chunk.js +3 -0
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_sqlMore.beecb919.chunk.js.map +1 -0
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_stan.a5cae90b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_stata.ded20240.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_step21.42386ad1.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_stylus.28930f5e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_subunit.09d14bb0.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_swift.0bfd8f65.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_taggerscript.08018f04.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_tap.38941f9b.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_tcl.5c4648da.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_thrift.65eb278d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_tp.ebc107f2.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_twig.f2a0927f.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_typescript.6c5bb667.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_vala.1d0d5f49.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_vbnet.26dbf652.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_vbscript.918c902a.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_vbscriptHtml.0448aba7.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_verilog.90bb7652.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_vhdl.1cfbc65e.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_vim.044bbd92.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_x86asm.e453b717.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_xl.be21301d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_xml.1ff2db9d.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_xquery.6691a2a9.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_yaml.ecaddbf6.chunk.js.map +1 -1
- package/dist/embedded-app/static/react-syntax-highlighter_languages_highlight_zephir.6f6db474.chunk.js.map +1 -1
- package/dist/embedded-app/static/runtime.3efd9679.js +4 -0
- package/dist/embedded-app/static/runtime.3efd9679.js.map +1 -0
- package/dist/embedded-app/static/vendor.3efd9679.js +117 -0
- package/dist/embedded-app/static/vendor.3efd9679.js.map +1 -0
- package/dist/index.cjs.js +4 -4
- package/dist/index.cjs.js.map +1 -1
- package/package.json +8 -8
- package/dist/cjs/generate-143a6de3.cjs.js.map +0 -1
- package/dist/cjs/mkdocsServer-758a3ae9.cjs.js.map +0 -1
- package/dist/embedded-app/static/1553.925835b9.chunk.js.map +0 -1
- package/dist/embedded-app/static/1959.2eb957a4.chunk.js.map +0 -1
- package/dist/embedded-app/static/2426.f9952783.chunk.js.map +0 -1
- package/dist/embedded-app/static/3825.b0488503.chunk.js +0 -3
- package/dist/embedded-app/static/3825.b0488503.chunk.js.map +0 -1
- package/dist/embedded-app/static/390.cd301478.chunk.js.map +0 -1
- package/dist/embedded-app/static/6105.6eda23ad.chunk.js +0 -3
- package/dist/embedded-app/static/6105.6eda23ad.chunk.js.map +0 -1
- package/dist/embedded-app/static/6235.b3634d50.chunk.js.map +0 -1
- package/dist/embedded-app/static/6583.c98b5125.chunk.js.map +0 -1
- package/dist/embedded-app/static/7110.527cc68b.chunk.js.map +0 -1
- package/dist/embedded-app/static/7758.a6ab2713.chunk.js +0 -3
- package/dist/embedded-app/static/7758.a6ab2713.chunk.js.map +0 -1
- package/dist/embedded-app/static/8718.cd7bb850.chunk.js.map +0 -1
- package/dist/embedded-app/static/8792.867bf73e.chunk.js.map +0 -1
- package/dist/embedded-app/static/9028.200536ea.chunk.js.map +0 -1
- package/dist/embedded-app/static/main.0b0e8219.js +0 -476
- package/dist/embedded-app/static/main.0b0e8219.js.map +0 -1
- package/dist/embedded-app/static/module-ajv.ed51f4b8.js +0 -10
- package/dist/embedded-app/static/module-ajv.ed51f4b8.js.map +0 -1
- package/dist/embedded-app/static/module-hot-loader.7c7a4226.js +0 -25
- package/dist/embedded-app/static/module-hot-loader.7c7a4226.js.map +0 -1
- package/dist/embedded-app/static/module-lodash.f158b49a.js.map +0 -1
- package/dist/embedded-app/static/module-material-ui.3c0e2d92.js.map +0 -1
- package/dist/embedded-app/static/module-yaml.574c3290.js.map +0 -1
- package/dist/embedded-app/static/runtime.0b0e8219.js +0 -4
- package/dist/embedded-app/static/runtime.0b0e8219.js.map +0 -1
- package/dist/embedded-app/static/vendor.0b0e8219.js +0 -140
- package/dist/embedded-app/static/vendor.0b0e8219.js.map +0 -1
package/dist/index.cjs.js
CHANGED
|
@@ -9,11 +9,11 @@ var program__default = /*#__PURE__*/_interopDefaultLegacy(program);
|
|
|
9
9
|
|
|
10
10
|
const defaultDockerImage = pluginTechdocsNode.TechdocsGenerator.defaultDockerImage;
|
|
11
11
|
function registerCommands(program) {
|
|
12
|
-
program.command("generate").description("Generate TechDocs documentation site using MkDocs.").option("--source-dir <PATH>", "Source directory containing mkdocs.yml and docs/ directory.", ".").option("--output-dir <PATH>", "Output directory containing generated TechDocs site.", "./site/").option("--docker-image <DOCKER_IMAGE>", "The mkdocs docker container to use", defaultDockerImage).option("--no-pull", "Do not pull the latest docker image", false).option("--no-docker", "Do not use Docker, use MkDocs executable and plugins in current user environment.").option("--techdocs-ref <HOST_TYPE:URL>", "The repository hosting documentation source files e.g. url:https://ghe.mycompany.net.com/org/repo.\nThis value is same as the backstage.io/techdocs-ref annotation of the corresponding Backstage entity.\nIt is completely fine to skip this as it is only being used to set repo_url in mkdocs.yml if not found.\n").option("--etag <ETAG>", "A unique identifier for the prepared tree e.g. commit SHA. If provided it will be stored in techdocs_metadata.json.").option("-v --verbose", "Enable verbose output.", false).option("--omitTechdocsCoreMkdocsPlugin", "Don't patch MkDocs file automatically with techdocs-core plugin.", false).alias("build").action(lazy(() => Promise.resolve().then(function () { return require('./cjs/generate-
|
|
12
|
+
program.command("generate").description("Generate TechDocs documentation site using MkDocs.").option("--source-dir <PATH>", "Source directory containing mkdocs.yml and docs/ directory.", ".").option("--output-dir <PATH>", "Output directory containing generated TechDocs site.", "./site/").option("--docker-image <DOCKER_IMAGE>", "The mkdocs docker container to use", defaultDockerImage).option("--no-pull", "Do not pull the latest docker image", false).option("--no-docker", "Do not use Docker, use MkDocs executable and plugins in current user environment.").option("--techdocs-ref <HOST_TYPE:URL>", "The repository hosting documentation source files e.g. url:https://ghe.mycompany.net.com/org/repo.\nThis value is same as the backstage.io/techdocs-ref annotation of the corresponding Backstage entity.\nIt is completely fine to skip this as it is only being used to set repo_url in mkdocs.yml if not found.\n").option("--etag <ETAG>", "A unique identifier for the prepared tree e.g. commit SHA. If provided it will be stored in techdocs_metadata.json.").option("-v --verbose", "Enable verbose output.", false).option("--omitTechdocsCoreMkdocsPlugin", "Don't patch MkDocs file automatically with techdocs-core plugin.", false).option("--legacyCopyReadmeMdToIndexMd", "Attempt to ensure an index.md exists falling back to using <docs-dir>/README.md or README.md in case a default <docs-dir>/index.md is not provided.", false).alias("build").action(lazy(() => Promise.resolve().then(function () { return require('./cjs/generate-67f1ab98.cjs.js'); }).then((m) => m.default)));
|
|
13
13
|
program.command("migrate").description("Migrate objects with case-sensitive entity triplets to lower-case versions.").requiredOption("--publisher-type <TYPE>", "(Required always) awsS3 | googleGcs | azureBlobStorage | openStackSwift - same as techdocs.publisher.type in Backstage app-config.yaml").requiredOption("--storage-name <BUCKET/CONTAINER NAME>", "(Required always) In case of AWS/GCS, use the bucket name. In case of Azure, use container name. Same as techdocs.publisher.[TYPE].bucketName").option("--azureAccountName <AZURE ACCOUNT NAME>", "(Required for Azure) specify when --publisher-type azureBlobStorage").option("--azureAccountKey <AZURE ACCOUNT KEY>", "Azure Storage Account key to use for authentication. If not specified, you must set AZURE_TENANT_ID, AZURE_CLIENT_ID & AZURE_CLIENT_SECRET as environment variables.").option("--awsRoleArn <AWS ROLE ARN>", "Optional AWS ARN of role to be assumed.").option("--awsEndpoint <AWS ENDPOINT>", "Optional AWS endpoint to send requests to.").option("--awsS3ForcePathStyle", "Optional AWS S3 option to force path style.").option("--awsBucketRootPath", "Optional sub-directory to store files in Amazon S3").option("--osCredentialId <OPENSTACK SWIFT APPLICATION CREDENTIAL ID>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--osSecret <OPENSTACK SWIFT APPLICATION CREDENTIAL SECRET>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--osAuthUrl <OPENSTACK SWIFT AUTHURL>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--osSwiftUrl <OPENSTACK SWIFT SWIFTURL>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--removeOriginal", "Optional Files are copied by default. If flag is set, files are renamed/moved instead.", false).option("--concurrency <MAX CONCURRENT REQS>", "Optional Controls the number of API requests allowed to be performed simultaneously.", "25").option("-v --verbose", "Enable verbose output.", false).action(lazy(() => Promise.resolve().then(function () { return require('./cjs/migrate-181e95f5.cjs.js'); }).then((m) => m.default)));
|
|
14
14
|
program.command("publish").description("Publish generated TechDocs site to an external storage AWS S3, Google GCS, etc.").requiredOption("--publisher-type <TYPE>", "(Required always) awsS3 | googleGcs | azureBlobStorage | openStackSwift - same as techdocs.publisher.type in Backstage app-config.yaml").requiredOption("--storage-name <BUCKET/CONTAINER NAME>", "(Required always) In case of AWS/GCS, use the bucket name. In case of Azure, use container name. Same as techdocs.publisher.[TYPE].bucketName").requiredOption("--entity <NAMESPACE/KIND/NAME>", "(Required always) Entity uid separated by / in namespace/kind/name order (case-sensitive). Example: default/Component/myEntity ").option("--legacyUseCaseSensitiveTripletPaths", "Publishes objects with cased entity triplet prefix when set (e.g. namespace/Kind/name). Only use if your TechDocs backend is configured the same way.", false).option("--azureAccountName <AZURE ACCOUNT NAME>", "(Required for Azure) specify when --publisher-type azureBlobStorage").option("--azureAccountKey <AZURE ACCOUNT KEY>", "Azure Storage Account key to use for authentication. If not specified, you must set AZURE_TENANT_ID, AZURE_CLIENT_ID & AZURE_CLIENT_SECRET as environment variables.").option("--awsRoleArn <AWS ROLE ARN>", "Optional AWS ARN of role to be assumed.").option("--awsEndpoint <AWS ENDPOINT>", "Optional AWS endpoint to send requests to.").option("--awsS3sse <AWS SSE>", "Optional AWS S3 Server Side Encryption.").option("--awsS3ForcePathStyle", "Optional AWS S3 option to force path style.").option("--osCredentialId <OPENSTACK SWIFT APPLICATION CREDENTIAL ID>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--osSecret <OPENSTACK SWIFT APPLICATION CREDENTIAL SECRET>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--osAuthUrl <OPENSTACK SWIFT AUTHURL>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--osSwiftUrl <OPENSTACK SWIFT SWIFTURL>", "(Required for OpenStack) specify when --publisher-type openStackSwift").option("--gcsBucketRootPath", "Optional sub-directory to store files in Google cloud storage").option("--directory <PATH>", "Path of the directory containing generated files to publish", "./site/").action(lazy(() => Promise.resolve().then(function () { return require('./cjs/publish-7bf1e5f7.cjs.js'); }).then((m) => m.default)));
|
|
15
|
-
program.command("serve:mkdocs").description("Serve a documentation project locally using MkDocs serve.").option("-i, --docker-image <DOCKER_IMAGE>", "The mkdocs docker container to use", defaultDockerImage).option("--no-docker", "Do not use Docker, run `mkdocs serve` in current user environment.").option("-p, --port <PORT>", "Port to serve documentation locally", "8000").option("-v --verbose", "Enable verbose output.", false).action(lazy(() => Promise.resolve().then(function () { return require('./cjs/mkdocs-
|
|
16
|
-
program.command("serve").description("Serve a documentation project locally in a Backstage app-like environment").option("-i, --docker-image <DOCKER_IMAGE>", "The mkdocs docker container to use", defaultDockerImage).option("--no-docker", "Do not use Docker, use MkDocs executable in current user environment.").option("--mkdocs-port <PORT>", "Port for MkDocs server to use", "8000").option("-v --verbose", "Enable verbose output.", false).action(lazy(() => Promise.resolve().then(function () { return require('./cjs/serve-
|
|
15
|
+
program.command("serve:mkdocs").description("Serve a documentation project locally using MkDocs serve.").option("-i, --docker-image <DOCKER_IMAGE>", "The mkdocs docker container to use", defaultDockerImage).option("--docker-entrypoint <DOCKER_ENTRYPOINT>", "Override the image entrypoint").option("--no-docker", "Do not use Docker, run `mkdocs serve` in current user environment.").option("-p, --port <PORT>", "Port to serve documentation locally", "8000").option("-v --verbose", "Enable verbose output.", false).action(lazy(() => Promise.resolve().then(function () { return require('./cjs/mkdocs-7c045a2a.cjs.js'); }).then((m) => m.default)));
|
|
16
|
+
program.command("serve").description("Serve a documentation project locally in a Backstage app-like environment").option("-i, --docker-image <DOCKER_IMAGE>", "The mkdocs docker container to use", defaultDockerImage).option("--docker-entrypoint <DOCKER_ENTRYPOINT>", "Override the image entrypoint").option("--no-docker", "Do not use Docker, use MkDocs executable in current user environment.").option("--mkdocs-port <PORT>", "Port for MkDocs server to use", "8000").option("-v --verbose", "Enable verbose output.", false).action(lazy(() => Promise.resolve().then(function () { return require('./cjs/serve-66a37894.cjs.js'); }).then((m) => m.default)));
|
|
17
17
|
}
|
|
18
18
|
function lazy(getActionFunc) {
|
|
19
19
|
return async (...args) => {
|
|
@@ -28,7 +28,7 @@ function lazy(getActionFunc) {
|
|
|
28
28
|
};
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
-
var version = "1.
|
|
31
|
+
var version = "1.1.0";
|
|
32
32
|
|
|
33
33
|
const main = (argv) => {
|
|
34
34
|
program__default["default"].name("techdocs-cli").version(version);
|
package/dist/index.cjs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs.js","sources":["../src/commands/index.ts","../src/index.ts"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { CommanderStatic } from 'commander';\nimport { TechdocsGenerator } from '@backstage/plugin-techdocs-node';\n\nconst defaultDockerImage = TechdocsGenerator.defaultDockerImage;\n\nexport function registerCommands(program: CommanderStatic) {\n program\n .command('generate')\n .description('Generate TechDocs documentation site using MkDocs.')\n .option(\n '--source-dir <PATH>',\n 'Source directory containing mkdocs.yml and docs/ directory.',\n '.',\n )\n .option(\n '--output-dir <PATH>',\n 'Output directory containing generated TechDocs site.',\n './site/',\n )\n .option(\n '--docker-image <DOCKER_IMAGE>',\n 'The mkdocs docker container to use',\n defaultDockerImage,\n )\n .option('--no-pull', 'Do not pull the latest docker image', false)\n .option(\n '--no-docker',\n 'Do not use Docker, use MkDocs executable and plugins in current user environment.',\n )\n .option(\n '--techdocs-ref <HOST_TYPE:URL>',\n 'The repository hosting documentation source files e.g. url:https://ghe.mycompany.net.com/org/repo.' +\n '\\nThis value is same as the backstage.io/techdocs-ref annotation of the corresponding Backstage entity.' +\n '\\nIt is completely fine to skip this as it is only being used to set repo_url in mkdocs.yml if not found.\\n',\n )\n .option(\n '--etag <ETAG>',\n 'A unique identifier for the prepared tree e.g. commit SHA. If provided it will be stored in techdocs_metadata.json.',\n )\n .option('-v --verbose', 'Enable verbose output.', false)\n .option(\n '--omitTechdocsCoreMkdocsPlugin',\n \"Don't patch MkDocs file automatically with techdocs-core plugin.\",\n false,\n )\n .alias('build')\n .action(lazy(() => import('./generate/generate').then(m => m.default)));\n\n program\n .command('migrate')\n .description(\n 'Migrate objects with case-sensitive entity triplets to lower-case versions.',\n )\n .requiredOption(\n '--publisher-type <TYPE>',\n '(Required always) awsS3 | googleGcs | azureBlobStorage | openStackSwift - same as techdocs.publisher.type in Backstage app-config.yaml',\n )\n .requiredOption(\n '--storage-name <BUCKET/CONTAINER NAME>',\n '(Required always) In case of AWS/GCS, use the bucket name. In case of Azure, use container name. Same as techdocs.publisher.[TYPE].bucketName',\n )\n .option(\n '--azureAccountName <AZURE ACCOUNT NAME>',\n '(Required for Azure) specify when --publisher-type azureBlobStorage',\n )\n .option(\n '--azureAccountKey <AZURE ACCOUNT KEY>',\n 'Azure Storage Account key to use for authentication. If not specified, you must set AZURE_TENANT_ID, AZURE_CLIENT_ID & AZURE_CLIENT_SECRET as environment variables.',\n )\n .option(\n '--awsRoleArn <AWS ROLE ARN>',\n 'Optional AWS ARN of role to be assumed.',\n )\n .option(\n '--awsEndpoint <AWS ENDPOINT>',\n 'Optional AWS endpoint to send requests to.',\n )\n .option(\n '--awsS3ForcePathStyle',\n 'Optional AWS S3 option to force path style.',\n )\n .option(\n '--awsBucketRootPath',\n 'Optional sub-directory to store files in Amazon S3',\n )\n .option(\n '--osCredentialId <OPENSTACK SWIFT APPLICATION CREDENTIAL ID>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSecret <OPENSTACK SWIFT APPLICATION CREDENTIAL SECRET>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osAuthUrl <OPENSTACK SWIFT AUTHURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSwiftUrl <OPENSTACK SWIFT SWIFTURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--removeOriginal',\n 'Optional Files are copied by default. If flag is set, files are renamed/moved instead.',\n false,\n )\n .option(\n '--concurrency <MAX CONCURRENT REQS>',\n 'Optional Controls the number of API requests allowed to be performed simultaneously.',\n '25',\n )\n .option('-v --verbose', 'Enable verbose output.', false)\n .action(lazy(() => import('./migrate/migrate').then(m => m.default)));\n\n program\n .command('publish')\n .description(\n 'Publish generated TechDocs site to an external storage AWS S3, Google GCS, etc.',\n )\n .requiredOption(\n '--publisher-type <TYPE>',\n '(Required always) awsS3 | googleGcs | azureBlobStorage | openStackSwift - same as techdocs.publisher.type in Backstage app-config.yaml',\n )\n .requiredOption(\n '--storage-name <BUCKET/CONTAINER NAME>',\n '(Required always) In case of AWS/GCS, use the bucket name. In case of Azure, use container name. Same as techdocs.publisher.[TYPE].bucketName',\n )\n .requiredOption(\n '--entity <NAMESPACE/KIND/NAME>',\n '(Required always) Entity uid separated by / in namespace/kind/name order (case-sensitive). Example: default/Component/myEntity ',\n )\n .option(\n '--legacyUseCaseSensitiveTripletPaths',\n 'Publishes objects with cased entity triplet prefix when set (e.g. namespace/Kind/name). Only use if your TechDocs backend is configured the same way.',\n false,\n )\n .option(\n '--azureAccountName <AZURE ACCOUNT NAME>',\n '(Required for Azure) specify when --publisher-type azureBlobStorage',\n )\n .option(\n '--azureAccountKey <AZURE ACCOUNT KEY>',\n 'Azure Storage Account key to use for authentication. If not specified, you must set AZURE_TENANT_ID, AZURE_CLIENT_ID & AZURE_CLIENT_SECRET as environment variables.',\n )\n .option(\n '--awsRoleArn <AWS ROLE ARN>',\n 'Optional AWS ARN of role to be assumed.',\n )\n .option(\n '--awsEndpoint <AWS ENDPOINT>',\n 'Optional AWS endpoint to send requests to.',\n )\n .option('--awsS3sse <AWS SSE>', 'Optional AWS S3 Server Side Encryption.')\n .option(\n '--awsS3ForcePathStyle',\n 'Optional AWS S3 option to force path style.',\n )\n .option(\n '--osCredentialId <OPENSTACK SWIFT APPLICATION CREDENTIAL ID>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSecret <OPENSTACK SWIFT APPLICATION CREDENTIAL SECRET>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osAuthUrl <OPENSTACK SWIFT AUTHURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSwiftUrl <OPENSTACK SWIFT SWIFTURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--gcsBucketRootPath',\n 'Optional sub-directory to store files in Google cloud storage',\n )\n .option(\n '--directory <PATH>',\n 'Path of the directory containing generated files to publish',\n './site/',\n )\n .action(lazy(() => import('./publish/publish').then(m => m.default)));\n\n program\n .command('serve:mkdocs')\n .description('Serve a documentation project locally using MkDocs serve.')\n .option(\n '-i, --docker-image <DOCKER_IMAGE>',\n 'The mkdocs docker container to use',\n defaultDockerImage,\n )\n .option(\n '--no-docker',\n 'Do not use Docker, run `mkdocs serve` in current user environment.',\n )\n .option('-p, --port <PORT>', 'Port to serve documentation locally', '8000')\n .option('-v --verbose', 'Enable verbose output.', false)\n .action(lazy(() => import('./serve/mkdocs').then(m => m.default)));\n\n program\n .command('serve')\n .description(\n 'Serve a documentation project locally in a Backstage app-like environment',\n )\n .option(\n '-i, --docker-image <DOCKER_IMAGE>',\n 'The mkdocs docker container to use',\n defaultDockerImage,\n )\n .option(\n '--no-docker',\n 'Do not use Docker, use MkDocs executable in current user environment.',\n )\n .option('--mkdocs-port <PORT>', 'Port for MkDocs server to use', '8000')\n .option('-v --verbose', 'Enable verbose output.', false)\n .action(lazy(() => import('./serve/serve').then(m => m.default)));\n}\n\n// Wraps an action function so that it always exits and handles errors\n// Humbly taken from backstage-cli's registerCommands\nfunction lazy(\n getActionFunc: () => Promise<(...args: any[]) => Promise<void>>,\n): (...args: any[]) => Promise<never> {\n return async (...args: any[]) => {\n try {\n const actionFunc = await getActionFunc();\n await actionFunc(...args);\n process.exit(0);\n } catch (error) {\n // eslint-disable-next-line no-console\n console.error(error.message);\n process.exit(1);\n }\n };\n}\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport program from 'commander';\nimport { registerCommands } from './commands';\nimport { version } from '../package.json';\n\nconst main = (argv: string[]) => {\n program.name('techdocs-cli').version(version);\n\n registerCommands(program);\n\n program.parse(argv);\n};\n\nmain(process.argv);\n"],"names":["TechdocsGenerator","program"],"mappings":";;;;;;;;;AAmBA,MAAM,qBAAqBA,oCAAkB,CAAA,kBAAA,CAAA;AAEtC,SAAA,gBAAA,CAA0B,OAA0B,EAAA;AACzD,EACG,OAAA,CAAA,OAAA,CAAQ,YACR,WAAY,CAAA,oDAAA,CAAA,CACZ,OACC,qBACA,EAAA,6DAAA,EACA,KAED,MACC,CAAA,qBAAA,EACA,wDACA,SAED,CAAA,CAAA,MAAA,CACC,iCACA,oCACA,EAAA,kBAAA,CAAA,CAED,OAAO,WAAa,EAAA,qCAAA,EAAuC,KAC3D,CAAA,CAAA,MAAA,CACC,aACA,EAAA,mFAAA,CAAA,CAED,OACC,gCACA,EAAA,sTAAA,CAAA,CAID,OACC,eACA,EAAA,qHAAA,CAAA,CAED,OAAO,cAAgB,EAAA,wBAAA,EAA0B,OACjD,MACC,CAAA,gCAAA,EACA,oEACA,KAED,CAAA,CAAA,KAAA,CAAM,SACN,MAAO,CAAA,IAAA,CAAK,MAAM,oDAAO,gCAAA,KAAA,CAAuB,IAAK,CAAA,CAAA,CAAA,KAAK,CAAE,CAAA,OAAA,CAAA,CAAA,CAAA,CAAA;AAE/D,EACG,OAAA,CAAA,OAAA,CAAQ,SACR,CAAA,CAAA,WAAA,CACC,6EAED,CAAA,CAAA,cAAA,CACC,yBACA,EAAA,wIAAA,CAAA,CAED,cACC,CAAA,wCAAA,EACA,+IAED,CAAA,CAAA,MAAA,CACC,yCACA,EAAA,qEAAA,CAAA,CAED,MACC,CAAA,uCAAA,EACA,sKAED,CAAA,CAAA,MAAA,CACC,6BACA,EAAA,yCAAA,CAAA,CAED,MACC,CAAA,8BAAA,EACA,4CAED,CAAA,CAAA,MAAA,CACC,uBACA,EAAA,6CAAA,CAAA,CAED,MACC,CAAA,qBAAA,EACA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,OACN,KAAP,EAAA;AAEA,MAAA,OAAA,CAAQ,MAAM,KAAM,CAAA,OAAA,CAAA,CAAA;AACpB,MAAA,OAAA,CAAQ,IAAK,CAAA,CAAA,CAAA,CAAA;AAAA,KAAA;AAAA,GAAA,CAAA;AAAA;;;;ACpOnB,MAAM,IAAA,GAAO,CAAC,IAAmB,KAAA;AAC/B,EAAQC,2BAAA,CAAA,IAAA,CAAK,gBAAgB,OAAQ,CAAA,OAAA,CAAA,CAAA;AAErC,EAAiB,gBAAA,CAAAA,2BAAA,CAAA,CAAA;AAEjB,EAAAA,2BAAA,CAAQ,KAAM,CAAA,IAAA,CAAA,CAAA;AAAA,CAAA,CAAA;AAGhB,IAAA,CAAK,OAAQ,CAAA,IAAA,CAAA;;"}
|
|
1
|
+
{"version":3,"file":"index.cjs.js","sources":["../src/commands/index.ts","../src/index.ts"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { CommanderStatic } from 'commander';\nimport { TechdocsGenerator } from '@backstage/plugin-techdocs-node';\n\nconst defaultDockerImage = TechdocsGenerator.defaultDockerImage;\n\nexport function registerCommands(program: CommanderStatic) {\n program\n .command('generate')\n .description('Generate TechDocs documentation site using MkDocs.')\n .option(\n '--source-dir <PATH>',\n 'Source directory containing mkdocs.yml and docs/ directory.',\n '.',\n )\n .option(\n '--output-dir <PATH>',\n 'Output directory containing generated TechDocs site.',\n './site/',\n )\n .option(\n '--docker-image <DOCKER_IMAGE>',\n 'The mkdocs docker container to use',\n defaultDockerImage,\n )\n .option('--no-pull', 'Do not pull the latest docker image', false)\n .option(\n '--no-docker',\n 'Do not use Docker, use MkDocs executable and plugins in current user environment.',\n )\n .option(\n '--techdocs-ref <HOST_TYPE:URL>',\n 'The repository hosting documentation source files e.g. url:https://ghe.mycompany.net.com/org/repo.' +\n '\\nThis value is same as the backstage.io/techdocs-ref annotation of the corresponding Backstage entity.' +\n '\\nIt is completely fine to skip this as it is only being used to set repo_url in mkdocs.yml if not found.\\n',\n )\n .option(\n '--etag <ETAG>',\n 'A unique identifier for the prepared tree e.g. commit SHA. If provided it will be stored in techdocs_metadata.json.',\n )\n .option('-v --verbose', 'Enable verbose output.', false)\n .option(\n '--omitTechdocsCoreMkdocsPlugin',\n \"Don't patch MkDocs file automatically with techdocs-core plugin.\",\n false,\n )\n .option(\n '--legacyCopyReadmeMdToIndexMd',\n 'Attempt to ensure an index.md exists falling back to using <docs-dir>/README.md or README.md in case a default <docs-dir>/index.md is not provided.',\n false,\n )\n .alias('build')\n .action(lazy(() => import('./generate/generate').then(m => m.default)));\n\n program\n .command('migrate')\n .description(\n 'Migrate objects with case-sensitive entity triplets to lower-case versions.',\n )\n .requiredOption(\n '--publisher-type <TYPE>',\n '(Required always) awsS3 | googleGcs | azureBlobStorage | openStackSwift - same as techdocs.publisher.type in Backstage app-config.yaml',\n )\n .requiredOption(\n '--storage-name <BUCKET/CONTAINER NAME>',\n '(Required always) In case of AWS/GCS, use the bucket name. In case of Azure, use container name. Same as techdocs.publisher.[TYPE].bucketName',\n )\n .option(\n '--azureAccountName <AZURE ACCOUNT NAME>',\n '(Required for Azure) specify when --publisher-type azureBlobStorage',\n )\n .option(\n '--azureAccountKey <AZURE ACCOUNT KEY>',\n 'Azure Storage Account key to use for authentication. If not specified, you must set AZURE_TENANT_ID, AZURE_CLIENT_ID & AZURE_CLIENT_SECRET as environment variables.',\n )\n .option(\n '--awsRoleArn <AWS ROLE ARN>',\n 'Optional AWS ARN of role to be assumed.',\n )\n .option(\n '--awsEndpoint <AWS ENDPOINT>',\n 'Optional AWS endpoint to send requests to.',\n )\n .option(\n '--awsS3ForcePathStyle',\n 'Optional AWS S3 option to force path style.',\n )\n .option(\n '--awsBucketRootPath',\n 'Optional sub-directory to store files in Amazon S3',\n )\n .option(\n '--osCredentialId <OPENSTACK SWIFT APPLICATION CREDENTIAL ID>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSecret <OPENSTACK SWIFT APPLICATION CREDENTIAL SECRET>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osAuthUrl <OPENSTACK SWIFT AUTHURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSwiftUrl <OPENSTACK SWIFT SWIFTURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--removeOriginal',\n 'Optional Files are copied by default. If flag is set, files are renamed/moved instead.',\n false,\n )\n .option(\n '--concurrency <MAX CONCURRENT REQS>',\n 'Optional Controls the number of API requests allowed to be performed simultaneously.',\n '25',\n )\n .option('-v --verbose', 'Enable verbose output.', false)\n .action(lazy(() => import('./migrate/migrate').then(m => m.default)));\n\n program\n .command('publish')\n .description(\n 'Publish generated TechDocs site to an external storage AWS S3, Google GCS, etc.',\n )\n .requiredOption(\n '--publisher-type <TYPE>',\n '(Required always) awsS3 | googleGcs | azureBlobStorage | openStackSwift - same as techdocs.publisher.type in Backstage app-config.yaml',\n )\n .requiredOption(\n '--storage-name <BUCKET/CONTAINER NAME>',\n '(Required always) In case of AWS/GCS, use the bucket name. In case of Azure, use container name. Same as techdocs.publisher.[TYPE].bucketName',\n )\n .requiredOption(\n '--entity <NAMESPACE/KIND/NAME>',\n '(Required always) Entity uid separated by / in namespace/kind/name order (case-sensitive). Example: default/Component/myEntity ',\n )\n .option(\n '--legacyUseCaseSensitiveTripletPaths',\n 'Publishes objects with cased entity triplet prefix when set (e.g. namespace/Kind/name). Only use if your TechDocs backend is configured the same way.',\n false,\n )\n .option(\n '--azureAccountName <AZURE ACCOUNT NAME>',\n '(Required for Azure) specify when --publisher-type azureBlobStorage',\n )\n .option(\n '--azureAccountKey <AZURE ACCOUNT KEY>',\n 'Azure Storage Account key to use for authentication. If not specified, you must set AZURE_TENANT_ID, AZURE_CLIENT_ID & AZURE_CLIENT_SECRET as environment variables.',\n )\n .option(\n '--awsRoleArn <AWS ROLE ARN>',\n 'Optional AWS ARN of role to be assumed.',\n )\n .option(\n '--awsEndpoint <AWS ENDPOINT>',\n 'Optional AWS endpoint to send requests to.',\n )\n .option('--awsS3sse <AWS SSE>', 'Optional AWS S3 Server Side Encryption.')\n .option(\n '--awsS3ForcePathStyle',\n 'Optional AWS S3 option to force path style.',\n )\n .option(\n '--osCredentialId <OPENSTACK SWIFT APPLICATION CREDENTIAL ID>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSecret <OPENSTACK SWIFT APPLICATION CREDENTIAL SECRET>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osAuthUrl <OPENSTACK SWIFT AUTHURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--osSwiftUrl <OPENSTACK SWIFT SWIFTURL>',\n '(Required for OpenStack) specify when --publisher-type openStackSwift',\n )\n .option(\n '--gcsBucketRootPath',\n 'Optional sub-directory to store files in Google cloud storage',\n )\n .option(\n '--directory <PATH>',\n 'Path of the directory containing generated files to publish',\n './site/',\n )\n .action(lazy(() => import('./publish/publish').then(m => m.default)));\n\n program\n .command('serve:mkdocs')\n .description('Serve a documentation project locally using MkDocs serve.')\n .option(\n '-i, --docker-image <DOCKER_IMAGE>',\n 'The mkdocs docker container to use',\n defaultDockerImage,\n )\n .option(\n '--docker-entrypoint <DOCKER_ENTRYPOINT>',\n 'Override the image entrypoint',\n )\n .option(\n '--no-docker',\n 'Do not use Docker, run `mkdocs serve` in current user environment.',\n )\n .option('-p, --port <PORT>', 'Port to serve documentation locally', '8000')\n .option('-v --verbose', 'Enable verbose output.', false)\n .action(lazy(() => import('./serve/mkdocs').then(m => m.default)));\n\n program\n .command('serve')\n .description(\n 'Serve a documentation project locally in a Backstage app-like environment',\n )\n .option(\n '-i, --docker-image <DOCKER_IMAGE>',\n 'The mkdocs docker container to use',\n defaultDockerImage,\n )\n .option(\n '--docker-entrypoint <DOCKER_ENTRYPOINT>',\n 'Override the image entrypoint',\n )\n .option(\n '--no-docker',\n 'Do not use Docker, use MkDocs executable in current user environment.',\n )\n .option('--mkdocs-port <PORT>', 'Port for MkDocs server to use', '8000')\n .option('-v --verbose', 'Enable verbose output.', false)\n .action(lazy(() => import('./serve/serve').then(m => m.default)));\n}\n\n// Wraps an action function so that it always exits and handles errors\n// Humbly taken from backstage-cli's registerCommands\nfunction lazy(\n getActionFunc: () => Promise<(...args: any[]) => Promise<void>>,\n): (...args: any[]) => Promise<never> {\n return async (...args: any[]) => {\n try {\n const actionFunc = await getActionFunc();\n await actionFunc(...args);\n process.exit(0);\n } catch (error) {\n // eslint-disable-next-line no-console\n console.error(error.message);\n process.exit(1);\n }\n };\n}\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport program from 'commander';\nimport { registerCommands } from './commands';\nimport { version } from '../package.json';\n\nconst main = (argv: string[]) => {\n program.name('techdocs-cli').version(version);\n\n registerCommands(program);\n\n program.parse(argv);\n};\n\nmain(process.argv);\n"],"names":["TechdocsGenerator","program"],"mappings":";;;;;;;;;AACA,MAAM,kBAAkB,GAAGA,oCAAiB,CAAC,kBAAkB,CAAC;AACzD,SAAS,gBAAgB,CAAC,OAAO,EAAE;AAC1C,EAAE,OAAO,C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AAC/kB,CAAC;AACD,SAAS,IAAI,CAAC,aAAa,EAAE;AAC7B,EAAE,OAAO,OAAO,GAAG,IAAI,KAAK;AAC5B,IAAI,IAAI;AACR,MAAM,MAAM,UAAU,GAAG,MAAM,aAAa,EAAE,CAAC;AAC/C,MAAM,MAAM,UAAU,CAAC,GAAG,IAAI,CAAC,CAAC;AAChC,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AACtB,KAAK,CAAC,OAAO,KAAK,EAAE;AACpB,MAAM,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;AACnC,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AACtB,KAAK;AACL,GAAG,CAAC;AACJ;;;;ACjBA,MAAM,IAAI,GAAG,CAAC,IAAI,KAAK;AACvB,EAAEC,2BAAO,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;AAChD,EAAE,gBAAgB,CAACA,2BAAO,CAAC,CAAC;AAC5B,EAAEA,2BAAO,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;AACtB,CAAC,CAAC;AACF,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC;;"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@techdocs/cli",
|
|
3
3
|
"description": "Utility CLI for managing TechDocs sites in Backstage.",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.1.0",
|
|
5
5
|
"private": false,
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -37,19 +37,19 @@
|
|
|
37
37
|
"techdocs-cli": "bin/techdocs-cli"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
|
-
"@backstage/cli": "^0.
|
|
40
|
+
"@backstage/cli": "^0.17.0",
|
|
41
41
|
"@types/commander": "^2.12.2",
|
|
42
42
|
"@types/fs-extra": "^9.0.6",
|
|
43
43
|
"@types/http-proxy": "^1.17.4",
|
|
44
44
|
"@types/jest": "^26.0.7",
|
|
45
|
-
"@types/node": "^
|
|
45
|
+
"@types/node": "^16.11.26",
|
|
46
46
|
"@types/serve-handler": "^6.1.0",
|
|
47
47
|
"@types/webpack-env": "^1.15.3",
|
|
48
48
|
"cypress": "^9.5.0",
|
|
49
49
|
"cypress-plugin-snapshots": "^1.4.4",
|
|
50
50
|
"find-process": "^1.4.5",
|
|
51
51
|
"nodemon": "^2.0.2",
|
|
52
|
-
"techdocs-cli-embedded-app": "^0.2.
|
|
52
|
+
"techdocs-cli-embedded-app": "^0.2.69",
|
|
53
53
|
"ts-node": "^10.0.0"
|
|
54
54
|
},
|
|
55
55
|
"files": [
|
|
@@ -62,11 +62,11 @@
|
|
|
62
62
|
"ext": "ts"
|
|
63
63
|
},
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@backstage/backend-common": "^0.13.
|
|
66
|
-
"@backstage/catalog-model": "^1.0.
|
|
65
|
+
"@backstage/backend-common": "^0.13.2",
|
|
66
|
+
"@backstage/catalog-model": "^1.0.1",
|
|
67
67
|
"@backstage/cli-common": "^0.1.8",
|
|
68
68
|
"@backstage/config": "^1.0.0",
|
|
69
|
-
"@backstage/plugin-techdocs-node": "^1.
|
|
69
|
+
"@backstage/plugin-techdocs-node": "^1.1.0",
|
|
70
70
|
"@types/dockerode": "^3.3.0",
|
|
71
71
|
"commander": "^6.1.0",
|
|
72
72
|
"dockerode": "^3.3.1",
|
|
@@ -76,5 +76,5 @@
|
|
|
76
76
|
"serve-handler": "^6.1.3",
|
|
77
77
|
"winston": "^3.2.1"
|
|
78
78
|
},
|
|
79
|
-
"gitHead": "
|
|
79
|
+
"gitHead": "e0e44c433319711c2fb8b175db411a621f7aaec2"
|
|
80
80
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generate-143a6de3.cjs.js","sources":["../../src/commands/generate/generate.ts"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { resolve } from 'path';\nimport { Command } from 'commander';\nimport fs from 'fs-extra';\nimport Docker from 'dockerode';\nimport {\n TechdocsGenerator,\n ParsedLocationAnnotation,\n} from '@backstage/plugin-techdocs-node';\nimport { DockerContainerRunner } from '@backstage/backend-common';\nimport { ConfigReader } from '@backstage/config';\nimport {\n convertTechDocsRefToLocationAnnotation,\n createLogger,\n} from '../../lib/utility';\nimport { stdout } from 'process';\n\nexport default async function generate(cmd: Command) {\n // Use techdocs-node package to generate docs. Keep consistency between Backstage and CI generating docs.\n // Docs can be prepared using actions/checkout or git clone, or similar paradigms on CI. The TechDocs CI workflow\n // will run on the CI pipeline containing the documentation files.\n\n const logger = createLogger({ verbose: cmd.verbose });\n\n const sourceDir = resolve(cmd.sourceDir);\n const outputDir = resolve(cmd.outputDir);\n const omitTechdocsCorePlugin = cmd.omitTechdocsCoreMkdocsPlugin;\n const dockerImage = cmd.dockerImage;\n const pullImage = cmd.pull;\n\n logger.info(`Using source dir ${sourceDir}`);\n logger.info(`Will output generated files in ${outputDir}`);\n\n logger.verbose('Creating output directory if it does not exist.');\n\n await fs.ensureDir(outputDir);\n\n const config = new ConfigReader({\n techdocs: {\n generator: {\n runIn: cmd.docker ? 'docker' : 'local',\n dockerImage,\n pullImage,\n mkdocs: {\n omitTechdocsCorePlugin,\n },\n },\n },\n });\n\n // Docker client (conditionally) used by the generators, based on techdocs.generators config.\n const dockerClient = new Docker();\n const containerRunner = new DockerContainerRunner({ dockerClient });\n\n let parsedLocationAnnotation = {} as ParsedLocationAnnotation;\n if (cmd.techdocsRef) {\n try {\n parsedLocationAnnotation = convertTechDocsRefToLocationAnnotation(\n cmd.techdocsRef,\n );\n } catch (err) {\n logger.error(err.message);\n }\n }\n\n // Generate docs using @backstage/plugin-techdocs-node\n const techdocsGenerator = await TechdocsGenerator.fromConfig(config, {\n logger,\n containerRunner,\n });\n\n logger.info('Generating documentation...');\n\n await techdocsGenerator.run({\n inputDir: sourceDir,\n outputDir,\n ...(cmd.techdocsRef\n ? {\n parsedLocationAnnotation,\n }\n : {}),\n logger,\n etag: cmd.etag,\n ...(process.env.LOG_LEVEL === 'debug' ? { logStream: stdout } : {}),\n });\n\n logger.info('Done!');\n}\n"],"names":["createLogger","resolve","fs","config","ConfigReader","Docker","DockerContainerRunner","convertTechDocsRefToLocationAnnotation","TechdocsGenerator","stdout"],"mappings":";;;;;;;;;;;;;;;;;AAgCA,eAAA,QAAA,CAAuC,GAAc,EAAA;AAKnD,EAAA,MAAM,MAAS,GAAAA,oBAAA,CAAa,EAAE,OAAA,EAAS,GAAI,CAAA,OAAA,EAAA,CAAA,CAAA;AAE3C,EAAM,MAAA,SAAA,GAAYC,aAAQ,GAAI,CAAA,SAAA,CAAA,CAAA;AAC9B,EAAM,MAAA,SAAA,GAAYA,aAAQ,GAAI,CAAA,SAAA,CAAA,CAAA;AAC9B,EAAA,MAAM,yBAAyB,GAAI,CAAA,4BAAA,CAAA;AACnC,EAAA,MAAM,cAAc,GAAI,CAAA,WAAA,CAAA;AACxB,EAAA,MAAM,YAAY,GAAI,CAAA,IAAA,CAAA;AAEtB,EAAA,MAAA,CAAO,KAAK,CAAoB,iBAAA,EAAA,SAAA,CAAA,CAAA,CAAA,CAAA;AAChC,EAAA,MAAA,CAAO,KAAK,CAAkC,+BAAA,EAAA,SAAA,CAAA,CAAA,CAAA,CAAA;AAE9C,EAAA,MAAA,CAAO,OAAQ,CAAA,iDAAA,CAAA,CAAA;AAEf,EAAA,MAAMC,uBAAG,SAAU,CAAA,SAAA,CAAA,CAAA;A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;AAAA,GAAA,CAAA,CAAA;AAGlE,EAAA,MAAA,CAAO,IAAK,CAAA,OAAA,CAAA,CAAA;AAAA;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"mkdocsServer-758a3ae9.cjs.js","sources":["../../src/lib/run.ts","../../src/lib/mkdocsServer.ts"],"sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { spawn, SpawnOptions, ChildProcess } from 'child_process';\n\nexport type LogFunc = (data: Buffer | string) => void;\ntype SpawnOptionsPartialEnv = Omit<SpawnOptions, 'env'> & {\n env?: Partial<NodeJS.ProcessEnv>;\n // Pipe stdout to this log function\n stdoutLogFunc?: LogFunc;\n // Pipe stderr to this log function\n stderrLogFunc?: LogFunc;\n};\n\n// TODO: Accept log functions to pipe logs with.\n// Runs a child command, returning the child process instance.\n// Use it along with waitForSignal to run a long running process e.g. mkdocs serve\nexport const run = async (\n name: string,\n args: string[] = [],\n options: SpawnOptionsPartialEnv = {},\n): Promise<ChildProcess> => {\n const { stdoutLogFunc, stderrLogFunc } = options;\n\n const env: NodeJS.ProcessEnv = {\n ...process.env,\n FORCE_COLOR: 'true',\n ...(options.env ?? {}),\n };\n\n // Refer: https://nodejs.org/api/child_process.html#child_process_subprocess_stdio\n const stdio = [\n 'inherit',\n stdoutLogFunc ? 'pipe' : 'inherit',\n stderrLogFunc ? 'pipe' : 'inherit',\n ] as ('inherit' | 'pipe')[];\n\n const childProcess = spawn(name, args, {\n stdio: stdio,\n ...options,\n env,\n });\n\n if (stdoutLogFunc && childProcess.stdout) {\n childProcess.stdout.on('data', stdoutLogFunc);\n }\n if (stderrLogFunc && childProcess.stderr) {\n childProcess.stderr.on('data', stderrLogFunc);\n }\n\n return childProcess;\n};\n\n// Block indefinitely and wait for a signal to kill the child process(es)\n// Throw error if any child process errors\n// Resolves only when all processes exit with status code 0\nexport async function waitForSignal(\n childProcesses: Array<ChildProcess>,\n): Promise<void> {\n const promises: Array<Promise<void>> = [];\n\n for (const signal of ['SIGINT', 'SIGTERM'] as const) {\n process.on(signal, () => {\n childProcesses.forEach(childProcess => {\n childProcess.kill();\n });\n });\n }\n\n childProcesses.forEach(childProcess => {\n if (typeof childProcess.exitCode === 'number') {\n if (childProcess.exitCode) {\n throw new Error(`Non zero exit code from child process`);\n }\n return;\n }\n\n promises.push(\n new Promise<void>((resolve, reject) => {\n childProcess.once('error', reject);\n childProcess.once('exit', resolve);\n }),\n );\n });\n\n await Promise.all(promises);\n}\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { ChildProcess } from 'child_process';\nimport { run, LogFunc } from './run';\n\nexport const runMkdocsServer = async (options: {\n port?: string;\n useDocker?: boolean;\n dockerImage?: string;\n stdoutLogFunc?: LogFunc;\n stderrLogFunc?: LogFunc;\n}): Promise<ChildProcess> => {\n const port = options.port ?? '8000';\n const useDocker = options.useDocker ?? true;\n const dockerImage = options.dockerImage ?? 'spotify/techdocs';\n\n if (useDocker) {\n return await run(\n 'docker',\n [\n 'run',\n '--rm',\n '-w',\n '/content',\n '-v',\n `${process.cwd()}:/content`,\n '-p',\n `${port}:${port}`,\n '-it',\n dockerImage,\n 'serve',\n '--dev-addr',\n `0.0.0.0:${port}`,\n ],\n {\n stdoutLogFunc: options.stdoutLogFunc,\n stderrLogFunc: options.stderrLogFunc,\n },\n );\n }\n\n return await run('mkdocs', ['serve', '--dev-addr', `127.0.0.1:${port}`], {\n stdoutLogFunc: options.stdoutLogFunc,\n stderrLogFunc: options.stderrLogFunc,\n });\n};\n"],"names":["spawn"],"mappings":";;;;AA6BO,MAAM,MAAM,OACjB,IAAA,EACA,IAAiB,GAAA,EAAA,EACjB,UAAkC,EACR,KAAA;AAjC5B,EAAA,IAAA,EAAA,CAAA;AAkCE,EAAM,MAAA,EAAE,eAAe,aAAkB,EAAA,GAAA,OAAA,CAAA;AAEzC,EAAA,MAAM,GAAyB,GAAA;AAAA,IAAA,GAC1B,OAAQ,CAAA,GAAA;AAAA,IACX,WAAa,EAAA,MAAA;AAAA,IACT,GAAA,CAAA,EAAA,GAAA,OAAA,CAAQ,QAAR,IAAe,GAAA,EAAA,GAAA,EAAA;AAAA,GAAA,CAAA;AAIrB,EAAA,MAAM,KAAQ,GAAA;AAAA,IACZ,SAAA;AAAA,IACA,gBAAgB,MAAS,GAAA,SAAA;AAAA,IACzB,gBAAgB,MAAS,GAAA,SAAA;AAAA,GAAA,CAAA;AAG3B,EAAM,MAAA,YAAA,GAAeA,mBAAM,CAAA,IAAA,EAAM,IAAM,EAAA;AAAA,IACrC,KAAA;AAAA,IACG,GAAA,OAAA;AAAA,IACH,GAAA;AAAA,GAAA,CAAA,CAAA;AAGF,EAAI,IAAA,aAAA,IAAiB,aAAa,MAAQ,EAAA;AACxC,IAAa,YAAA,CAAA,MAAA,CAAO,GAAG,MAAQ,EAAA,aAAA,CAAA,CAAA;AAAA,GAAA;AAEjC,EAAI,IAAA,aAAA,IAAiB,aAAa,MAAQ,EAAA;AACxC,IAAa,YAAA,CAAA,MAAA,CAAO,GAAG,MAAQ,EAAA,aAAA,CAAA,CAAA;AAAA,GAAA;AAGjC,EAAO,OAAA,YAAA,CAAA;AAAA,CAA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,GAAA,EAAA,GAAA,IAAA,CAAA;AACvC,EAAM,MAAA,WAAA,GAAc,CAAQ,EAAA,GAAA,OAAA,CAAA,WAAA,KAAR,IAAuB,GAAA,EAAA,GAAA,kBAAA,CAAA;AAE3C,EAAA,IAAI,SAAW,EAAA;AACb,IAAO,OAAA,MAAM,IACX,QACA,EAAA;AAAA,MACE,KAAA;AAAA,MACA,MAAA;AAAA,MACA,IAAA;AAAA,MACA,UAAA;AAAA,MACA,IAAA;AAAA,MACA,GAAG,OAAQ,CAAA,GAAA,EAAA,CAAA,SAAA,CAAA;AAAA,MACX,IAAA;AAAA,MACA,GAAG,IAAQ,CAAA,CAAA,EAAA,IAAA,CAAA,CAAA;AAAA,MACX,KAAA;AAAA,MACA,WAAA;AAAA,MACA,OAAA;AAAA,MACA,YAAA;AAAA,MACA,CAAW,QAAA,EAAA,IAAA,CAAA,CAAA;AAAA,KAEb,EAAA;AAAA,MACE,eAAe,OAAQ,CAAA,aAAA;AAAA,MACvB,eAAe,OAAQ,CAAA,aAAA;AAAA,KAAA,CAAA,CAAA;AAAA,GAAA;AAK7B,EAAA,OAAO,MAAM,GAAI,CAAA,QAAA,EAAU,CAAC,OAAS,EAAA,YAAA,EAAc,aAAa,IAAS,CAAA,CAAA,CAAA,EAAA;AAAA,IACvE,eAAe,OAAQ,CAAA,aAAA;AAAA,IACvB,eAAe,OAAQ,CAAA,aAAA;AAAA,GAAA,CAAA,CAAA;AAAA;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/HasResourcesCard/HasResourcesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/presets.ts"],"names":[],"mappings":"kPA8BO,WAA0B,EAAO,CACtC,KAAM,CAAE,UAAU,YAAe,EACjC,MACE,iBAAoB,sBAAqB,CACvC,QAAS,EACT,MAAO,gBACP,WAAY,WACZ,aAAc,KACd,QAAS,wBACT,qBAAsB,qBACtB,aAAc,qCACd,cAAe,6B,ufCed,WACL,EACA,CACA,KAAM,CACJ,UAAU,WACV,QACA,UACA,aACA,eACA,eACA,gBACA,wBACE,EAEE,CAAE,UAAW,kBACb,CAAE,WAAU,UAAS,SAAU,yBAAmB,EAAQ,CAC9D,KAAM,EACN,KAAM,IAGR,MAAI,GAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,WAAU,OAKlC,EAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,qBAAoB,CAAE,MAAO,KAMvD,gBAAoB,cAAa,CAC/B,MAAO,EACP,QAAS,EACT,aACE,gBAAoB,MAAO,CAAE,MAAO,CAAE,UAAW,WAC7C,gBAAoB,IAAY,CAAE,QAAS,SAAW,GACtD,gBAAoB,IAAY,CAAE,QAAS,SACzC,gBAAoB,OAAM,CAAE,GAAI,GAAiB,+BAIzD,QAAS,EACT,SAAU,EAAqB,GAAY,MCjF1C,KAAM,GAAyB,CACpC,4CAA0C,CAAE,YAAa,cACzD,0CACA,6CACA,kDACA,yDAEW,EACX,uFACW,EAAuB,GAClC,EAEW,EAAwB,CACnC,4CAA0C,CAAE,YAAa,aACzD,0CACA,6CACA,kDACA,yDAEW,EACX,sFACW,EAAsB,GACjC,EAEW,EAAsB,CACjC,4CAA0C,CAAE,YAAa,WACzD,0CACA,yDAEW,EACX,oFACW,EAAoB,GAC/B","file":"static/1553.925835b9.chunk.js","sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { RELATION_HAS_PART } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asResourceEntities,\n RelatedEntitiesCard,\n resourceEntityColumns,\n resourceEntityHelpLink,\n} from '../RelatedEntitiesCard';\n\n/** @public */\n\n\n\n\nexport function HasResourcesCard(props) {\n const { variant = 'gridItem' } = props;\n return (\n React.createElement(RelatedEntitiesCard, {\n variant: variant,\n title: \"Has resources\" ,\n entityKind: \"Resource\",\n relationType: RELATION_HAS_PART,\n columns: resourceEntityColumns,\n asRenderableEntities: asResourceEntities,\n emptyMessage: \"No resource is part of this system\" ,\n emptyHelpLink: resourceEntityHelpLink,}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Typography } from '@material-ui/core';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n Link,\n Progress,\n ResponseErrorPanel,\n\n} from '@backstage/core-components';\n\n/** @public */\n\n\n\n\n\n\n\n\n\n\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport function RelatedEntitiesCard(\n props,\n) {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n } = props;\n\n const { entity } = useEntity();\n const { entities, loading, error } = useRelatedEntities(entity, {\n type: relationType,\n kind: entityKind,\n });\n\n if (loading) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(Progress, null )\n )\n );\n }\n\n if (error) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(ResponseErrorPanel, { error: error,} )\n )\n );\n }\n\n return (\n React.createElement(EntityTable, {\n title: title,\n variant: variant,\n emptyContent: \n React.createElement('div', { style: { textAlign: 'center' },}\n , React.createElement(Typography, { variant: \"body1\",}, emptyMessage)\n , React.createElement(Typography, { variant: \"body2\",}\n , React.createElement(Link, { to: emptyHelpLink,}, \"Learn how to change this.\" )\n )\n )\n ,\n columns: columns,\n entities: asRenderableEntities(entities || []),}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { EntityTable } from '@backstage/plugin-catalog-react';\n\n\nexport const componentEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'component' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const componentEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component';\nexport const asComponentEntities = (entities) =>\n entities ;\n\nexport const resourceEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'resource' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const resourceEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-resource';\nexport const asResourceEntities = (entities) =>\n entities ;\n\nexport const systemEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'system' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const systemEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system';\nexport const asSystemEntities = (entities) =>\n entities ;\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@material-ui/icons/Language.js","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/EntityLinksCard/EntityLinksEmptyState.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/EntityLinksCard/IconLink.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/EntityLinksCard/useDynamicColumns.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/EntityLinksCard/LinksGridList.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/EntityLinksCard/EntityLinksCard.tsx"],"names":[],"mappings":"yJAEI,EAAyB,EAAQ,OAEjC,EAA0B,EAAQ,OAEtC,EAA6C,CAC3C,MAAO,IAET,EAAQ,EAAU,OAElB,GAAI,GAAQ,EAAwB,EAAQ,OAExC,EAAiB,EAAuB,EAAQ,QAEhD,EAAY,GAAG,EAAe,SAAuB,EAAM,cAAc,OAAQ,CACnF,EAAG,8yBACD,YAEJ,EAAQ,EAAU,G,0JCElB,KAAM,GAAc;AAAA;AAAA;AAAA;AAAA;AAAA,uBAUd,EAAY,QAChB,GAAU,EACR,KAAM,CACJ,aAAc,EACd,OAAQ,GAAG,EAAM,QAAQ,WACzB,WAAY,EAAM,QAAQ,OAAS,OAAS,OAAS,UAGzD,CAAE,KAAM,uCAGH,YAAiC,CACtC,KAAM,GAAU,IAEhB,MACE,iBAAoB,WAAgB,KAChC,gBAAoB,IAAY,CAAE,QAAS,SAAW,sHAItD,gBAAoB,MAAO,CAAE,UAAW,EAAQ,MAC9C,gBAAoB,cAAa,CACjC,KAAM,EACN,SAAU,OACV,gBAAiB,GACjB,mBAAoB,CAAC,EAAG,EAAG,EAAG,GAC9B,YAAa,CAAE,WAAY,UAAW,SAAU,WAGlD,gBAAoB,IAAQ,CAC5B,QAAS,YACT,MAAO,UACP,OAAQ,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AAM,KAAM,UAAQ,EAAM,KAAM,O,eCX3E,WAAyB,EAAO,C,MACrC,KAAM,CAAE,OAAO,OAAW,WAAY,EAChC,CAAE,UAAW,kBACb,EAAM,eAEN,EAAgB,GAAK,C,MACzB,UAAM,KAAI,cAAc,KAAlB,OAAyC,KAE3C,EAAQ,oBAAQ,WAAR,cAAkB,MAEhC,MACE,iBAAoB,WAAU,CAAE,MAAO,QAAS,QAAS,GACrD,CAAC,GAAS,EAAM,SAAW,EAC3B,gBAAoB,EAAuB,MAE3C,gBAAoB,EAAe,CACjC,KAAM,EACN,MAAO,EAAM,IAAI,CAAC,CAAE,MAAK,QAAO,UAAY,EAC1C,KAAM,UAAS,EACf,KAAM,EACN,KAAM,EAAa","file":"static/1959.2eb957a4.chunk.js","sourcesContent":["\"use strict\";\n\nvar _interopRequireDefault = require(\"@babel/runtime/helpers/interopRequireDefault\");\n\nvar _interopRequireWildcard = require(\"@babel/runtime/helpers/interopRequireWildcard\");\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = void 0;\n\nvar React = _interopRequireWildcard(require(\"react\"));\n\nvar _createSvgIcon = _interopRequireDefault(require(\"./utils/createSvgIcon\"));\n\nvar _default = (0, _createSvgIcon.default)( /*#__PURE__*/React.createElement(\"path\", {\n d: \"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm6.93 6h-2.95c-.32-1.25-.78-2.45-1.38-3.56 1.84.63 3.37 1.91 4.33 3.56zM12 4.04c.83 1.2 1.48 2.53 1.91 3.96h-3.82c.43-1.43 1.08-2.76 1.91-3.96zM4.26 14C4.1 13.36 4 12.69 4 12s.1-1.36.26-2h3.38c-.08.66-.14 1.32-.14 2 0 .68.06 1.34.14 2H4.26zm.82 2h2.95c.32 1.25.78 2.45 1.38 3.56-1.84-.63-3.37-1.9-4.33-3.56zm2.95-8H5.08c.96-1.66 2.49-2.93 4.33-3.56C8.81 5.55 8.35 6.75 8.03 8zM12 19.96c-.83-1.2-1.48-2.53-1.91-3.96h3.82c-.43 1.43-1.08 2.76-1.91 3.96zM14.34 14H9.66c-.09-.66-.16-1.32-.16-2 0-.68.07-1.35.16-2h4.68c.09.65.16 1.32.16 2 0 .68-.07 1.34-.16 2zm.25 5.56c.6-1.11 1.06-2.31 1.38-3.56h2.95c-.96 1.65-2.49 2.93-4.33 3.56zM16.36 14c.08-.66.14-1.32.14-2 0-.68-.06-1.34-.14-2h3.38c.16.64.26 1.31.26 2s-.1 1.36-.26 2h-3.38z\"\n}), 'Language');\n\nexports.default = _default;","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Button, makeStyles, Typography } from '@material-ui/core';\nimport React from 'react';\nimport { CodeSnippet } from '@backstage/core-components';\n\nconst ENTITY_YAML = `metadata:\n name: example\n links:\n - url: https://dashboard.example.com\n title: My Dashboard\n icon: dashboard`;\n\n/** @public */\n\n\nconst useStyles = makeStyles(\n theme => ({\n code: {\n borderRadius: 6,\n margin: `${theme.spacing(2)}px 0px`,\n background: theme.palette.type === 'dark' ? '#444' : '#fff',\n },\n }),\n { name: 'PluginCatalogEntityLinksEmptyState' },\n);\n\nexport function EntityLinksEmptyState() {\n const classes = useStyles();\n\n return (\n React.createElement(React.Fragment, null\n , React.createElement(Typography, { variant: \"body1\",}, \"No links defined for this entity. You can add links to your entity YAML as shown in the highlighted example below:\"\n\n\n )\n , React.createElement('div', { className: classes.code,}\n , React.createElement(CodeSnippet, {\n text: ENTITY_YAML,\n language: \"yaml\",\n showLineNumbers: true,\n highlightedNumbers: [3, 4, 5, 6],\n customStyle: { background: 'inherit', fontSize: '115%' },}\n )\n )\n , React.createElement(Button, {\n variant: \"contained\",\n color: \"primary\",\n target: \"_blank\",\n href: \"https://backstage.io/docs/features/software-catalog/descriptor-format#links-optional\",}\n , \"Read more\"\n\n )\n )\n );\n}\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { makeStyles, Box, Typography } from '@material-ui/core';\nimport LanguageIcon from '@material-ui/icons/Language';\nimport React from 'react';\nimport { Link } from '@backstage/core-components';\n\n\nconst useStyles = makeStyles({\n svgIcon: {\n display: 'inline-block',\n '& svg': {\n display: 'inline-block',\n fontSize: 'inherit',\n verticalAlign: 'baseline',\n },\n },\n});\n\nexport function IconLink(props\n\n\n\n) {\n const { href, text, Icon } = props;\n const classes = useStyles();\n\n return (\n React.createElement(Box, { display: \"flex\",}\n , React.createElement(Box, { mr: 1, className: classes.svgIcon,}\n , React.createElement(Typography, { component: \"div\",}\n , Icon ? React.createElement(Icon, null ) : React.createElement(LanguageIcon, null )\n )\n )\n , React.createElement(Box, { flexGrow: \"1\",}\n , React.createElement(Link, { to: href, target: \"_blank\", rel: \"noopener\",}\n , text || href\n )\n )\n )\n );\n}\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useMediaQuery } from '@material-ui/core';\n\n\nconst colDefaults = {\n xs: 1,\n sm: 1,\n md: 1,\n lg: 2,\n xl: 3,\n};\n\nexport function useDynamicColumns(\n cols,\n) {\n const matches = [\n useMediaQuery((theme) => theme.breakpoints.up('xl')) ? 'xl' : null,\n useMediaQuery((theme) => theme.breakpoints.up('lg')) ? 'lg' : null,\n useMediaQuery((theme) => theme.breakpoints.up('md')) ? 'md' : null,\n useMediaQuery((theme) => theme.breakpoints.up('sm')) ? 'sm' : null,\n useMediaQuery((theme) => theme.breakpoints.up('xs')) ? 'xs' : null,\n ];\n\n let numOfCols = 1;\n\n if (typeof cols === 'number') {\n numOfCols = cols;\n } else {\n const breakpoint = matches.find(k => k !== null) ?? 'xs';\n numOfCols = cols?.[breakpoint] ?? colDefaults[breakpoint];\n }\n\n return numOfCols;\n}\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { ImageList, ImageListItem } from '@material-ui/core';\nimport React from 'react';\nimport { IconLink } from './IconLink';\n\nimport { useDynamicColumns } from './useDynamicColumns';\n\n\n\n\n\n\n\n\n\n\n\n\n\nexport function LinksGridList(props) {\n const { items, cols = undefined } = props;\n const numOfCols = useDynamicColumns(cols);\n\n return (\n React.createElement(ImageList, { rowHeight: \"auto\", cols: numOfCols,}\n , items.map(({ text, href, Icon }, i) => (\n React.createElement(ImageListItem, { key: i,}\n , React.createElement(IconLink, { href: href, text: text ?? href, Icon: Icon,} )\n )\n ))\n )\n );\n}\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useEntity } from '@backstage/plugin-catalog-react';\nimport LanguageIcon from '@material-ui/icons/Language';\nimport React from 'react';\nimport { EntityLinksEmptyState } from './EntityLinksEmptyState';\nimport { LinksGridList } from './LinksGridList';\n\nimport { useApp } from '@backstage/core-plugin-api';\nimport { InfoCard } from '@backstage/core-components';\n\n/** @public */\n\n\n\n\n\nexport function EntityLinksCard(props) {\n const { cols = undefined, variant } = props;\n const { entity } = useEntity();\n const app = useApp();\n\n const iconResolver = (key) =>\n key ? app.getSystemIcon(key) ?? LanguageIcon : LanguageIcon;\n\n const links = entity?.metadata?.links;\n\n return (\n React.createElement(InfoCard, { title: \"Links\", variant: variant,}\n , !links || links.length === 0 ? (\n React.createElement(EntityLinksEmptyState, null )\n ) : (\n React.createElement(LinksGridList, {\n cols: cols,\n items: links.map(({ url, title, icon }) => ({\n text: title ?? url,\n href: url,\n Icon: iconResolver(icon),\n })),}\n )\n )\n )\n );\n}\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/presets.ts"],"names":[],"mappings":"onBAwDO,WACL,EACA,CACA,KAAM,CACJ,UAAU,WACV,QACA,UACA,aACA,eACA,eACA,gBACA,wBACE,EAEE,CAAE,UAAW,kBACb,CAAE,WAAU,UAAS,SAAU,yBAAmB,EAAQ,CAC9D,KAAM,EACN,KAAM,IAGR,MAAI,GAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,WAAU,OAKlC,EAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,qBAAoB,CAAE,MAAO,KAMvD,gBAAoB,cAAa,CAC/B,MAAO,EACP,QAAS,EACT,aACE,gBAAoB,MAAO,CAAE,MAAO,CAAE,UAAW,WAC7C,gBAAoB,IAAY,CAAE,QAAS,SAAW,GACtD,gBAAoB,IAAY,CAAE,QAAS,SACzC,gBAAoB,OAAM,CAAE,GAAI,GAAiB,+BAIzD,QAAS,EACT,SAAU,EAAqB,GAAY,MCjF1C,KAAM,GAAyB,CACpC,4CAA0C,CAAE,YAAa,cACzD,0CACA,6CACA,kDACA,yDAEW,EACX,uFACW,EAAuB,GAClC,EAEW,EAAwB,CACnC,4CAA0C,CAAE,YAAa,aACzD,0CACA,6CACA,kDACA,yDAEW,EACX,sFACW,EAAsB,GACjC,EAEW,EAAsB,CACjC,4CAA0C,CAAE,YAAa,WACzD,0CACA,yDAEW,EACX,oFACW,EAAoB,GAC/B","file":"static/2426.f9952783.chunk.js","sourcesContent":["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Typography } from '@material-ui/core';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n Link,\n Progress,\n ResponseErrorPanel,\n\n} from '@backstage/core-components';\n\n/** @public */\n\n\n\n\n\n\n\n\n\n\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport function RelatedEntitiesCard(\n props,\n) {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n } = props;\n\n const { entity } = useEntity();\n const { entities, loading, error } = useRelatedEntities(entity, {\n type: relationType,\n kind: entityKind,\n });\n\n if (loading) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(Progress, null )\n )\n );\n }\n\n if (error) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(ResponseErrorPanel, { error: error,} )\n )\n );\n }\n\n return (\n React.createElement(EntityTable, {\n title: title,\n variant: variant,\n emptyContent: \n React.createElement('div', { style: { textAlign: 'center' },}\n , React.createElement(Typography, { variant: \"body1\",}, emptyMessage)\n , React.createElement(Typography, { variant: \"body2\",}\n , React.createElement(Link, { to: emptyHelpLink,}, \"Learn how to change this.\" )\n )\n )\n ,\n columns: columns,\n entities: asRenderableEntities(entities || []),}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { EntityTable } from '@backstage/plugin-catalog-react';\n\n\nexport const componentEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'component' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const componentEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component';\nexport const asComponentEntities = (entities) =>\n entities ;\n\nexport const resourceEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'resource' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const resourceEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-resource';\nexport const asResourceEntities = (entities) =>\n entities ;\n\nexport const systemEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'system' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const systemEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system';\nexport const asSystemEntities = (entities) =>\n entities ;\n"],"sourceRoot":""}
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
"use strict";(()=>{(self.webpackChunktechdocs_cli_embedded_app=self.webpackChunktechdocs_cli_embedded_app||[]).push([[3825],{43825:function(m,a,e){e.r(a),e.d(a,{SidebarSearchModal:function(){return s}});var c=e(2784),l=e(21853),o=e(9118),t=e(73032);const s=n=>{const{state:r,toggleModal:d}=(0,t.O)(),h=n.icon?n.icon:l.Z;return c.createElement(c.Fragment,null,c.createElement(o.SidebarItem,{className:"search-icon",icon:h,text:"Search",onClick:d}),c.createElement(t.s,{...r,toggleModal:d}))}}}]);})();
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=3825.b0488503.chunk.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/search/src/components/SidebarSearchModal/SidebarSearchModal.tsx"],"names":[],"mappings":"yPAyBO,KAAM,GAAsB,GAAU,CAC3C,KAAM,CAAE,QAAO,eAAgB,UACzB,EAAO,EAAM,KAAO,EAAM,KAAO,IAEvC,MACE,iBAAoB,WAAgB,KAChC,gBAAoB,cAAa,CACjC,UAAW,cACX,KAAM,EACN,KAAM,SACN,QAAS,IAET,gBAAoB,IAAa,IAAK,EAAO,YAAa","file":"static/3825.b0488503.chunk.js","sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport React from 'react';\nimport SearchIcon from '@material-ui/icons/Search';\nimport { SidebarItem } from '@backstage/core-components';\n\nimport { SearchModal, useSearchModal } from '../SearchModal';\n\n\n\n\n\nexport const SidebarSearchModal = (props) => {\n const { state, toggleModal } = useSearchModal();\n const Icon = props.icon ? props.icon : SearchIcon;\n\n return (\n React.createElement(React.Fragment, null\n , React.createElement(SidebarItem, {\n className: \"search-icon\",\n icon: Icon,\n text: \"Search\",\n onClick: toggleModal,}\n )\n , React.createElement(SearchModal, { ...state, toggleModal: toggleModal,} )\n )\n );\n};\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/HasSystemsCard/HasSystemsCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/presets.ts"],"names":[],"mappings":"+OA8BO,WAAwB,EAAO,CACpC,KAAM,CAAE,UAAU,YAAe,EACjC,MACE,iBAAoB,sBAAqB,CACvC,QAAS,EACT,MAAO,cACP,WAAY,SACZ,aAAc,KACd,QAAS,sBACT,qBAAsB,mBACtB,aAAc,mCACd,cAAe,2B,ufCed,WACL,EACA,CACA,KAAM,CACJ,UAAU,WACV,QACA,UACA,aACA,eACA,eACA,gBACA,wBACE,EAEE,CAAE,UAAW,kBACb,CAAE,WAAU,UAAS,SAAU,yBAAmB,EAAQ,CAC9D,KAAM,EACN,KAAM,IAGR,MAAI,GAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,WAAU,OAKlC,EAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,qBAAoB,CAAE,MAAO,KAMvD,gBAAoB,cAAa,CAC/B,MAAO,EACP,QAAS,EACT,aACE,gBAAoB,MAAO,CAAE,MAAO,CAAE,UAAW,WAC7C,gBAAoB,IAAY,CAAE,QAAS,SAAW,GACtD,gBAAoB,IAAY,CAAE,QAAS,SACzC,gBAAoB,OAAM,CAAE,GAAI,GAAiB,+BAIzD,QAAS,EACT,SAAU,EAAqB,GAAY,MCjF1C,KAAM,GAAyB,CACpC,4CAA0C,CAAE,YAAa,cACzD,0CACA,6CACA,kDACA,yDAEW,EACX,uFACW,EAAuB,GAClC,EAEW,EAAwB,CACnC,4CAA0C,CAAE,YAAa,aACzD,0CACA,6CACA,kDACA,yDAEW,EACX,sFACW,EAAsB,GACjC,EAEW,EAAsB,CACjC,4CAA0C,CAAE,YAAa,WACzD,0CACA,yDAEW,EACX,oFACW,EAAoB,GAC/B","file":"static/390.cd301478.chunk.js","sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { RELATION_HAS_PART } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asSystemEntities,\n RelatedEntitiesCard,\n systemEntityColumns,\n systemEntityHelpLink,\n} from '../RelatedEntitiesCard';\n\n/** @public */\n\n\n\n\nexport function HasSystemsCard(props) {\n const { variant = 'gridItem' } = props;\n return (\n React.createElement(RelatedEntitiesCard, {\n variant: variant,\n title: \"Has systems\" ,\n entityKind: \"System\",\n relationType: RELATION_HAS_PART,\n columns: systemEntityColumns,\n asRenderableEntities: asSystemEntities,\n emptyMessage: \"No system is part of this domain\" ,\n emptyHelpLink: systemEntityHelpLink,}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Typography } from '@material-ui/core';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n Link,\n Progress,\n ResponseErrorPanel,\n\n} from '@backstage/core-components';\n\n/** @public */\n\n\n\n\n\n\n\n\n\n\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport function RelatedEntitiesCard(\n props,\n) {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n } = props;\n\n const { entity } = useEntity();\n const { entities, loading, error } = useRelatedEntities(entity, {\n type: relationType,\n kind: entityKind,\n });\n\n if (loading) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(Progress, null )\n )\n );\n }\n\n if (error) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(ResponseErrorPanel, { error: error,} )\n )\n );\n }\n\n return (\n React.createElement(EntityTable, {\n title: title,\n variant: variant,\n emptyContent: \n React.createElement('div', { style: { textAlign: 'center' },}\n , React.createElement(Typography, { variant: \"body1\",}, emptyMessage)\n , React.createElement(Typography, { variant: \"body2\",}\n , React.createElement(Link, { to: emptyHelpLink,}, \"Learn how to change this.\" )\n )\n )\n ,\n columns: columns,\n entities: asRenderableEntities(entities || []),}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { EntityTable } from '@backstage/plugin-catalog-react';\n\n\nexport const componentEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'component' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const componentEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component';\nexport const asComponentEntities = (entities) =>\n entities ;\n\nexport const resourceEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'resource' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const resourceEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-resource';\nexport const asResourceEntities = (entities) =>\n entities ;\n\nexport const systemEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'system' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const systemEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system';\nexport const asSystemEntities = (entities) =>\n entities ;\n"],"sourceRoot":""}
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
"use strict";(()=>{(self.webpackChunktechdocs_cli_embedded_app=self.webpackChunktechdocs_cli_embedded_app||[]).push([[6105],{46105:function(R,r,e){e.r(r),e.d(r,{HomePageSearchBar:function(){return f}});var a=e(2784),c=e(79692),u=e(1795),l=e(19126),d=e.n(l),h=e(10289),S=e(20863),v=e(36964);const i=()=>{const t=(0,v.useRouteRef)(S._Z),s=(0,h.s0)();return(0,a.useCallback)(({query:n})=>{const o=d().stringify({query:n},{addQueryPrefix:!0});s(`${t()}${o}`)},[s,t])},m=(0,c.Z)({root:{border:"1px solid #555",borderRadius:"6px",fontSize:"1.5em"}}),f=({...t})=>{const s=m(t),[n,o]=(0,a.useState)(""),g=i(),y=()=>{g({query:n})},C=(0,a.useCallback)(B=>{o(B)},[o]);return a.createElement(u.SearchBarBase,{classes:{root:s.root},value:n,onSubmit:y,onChange:C,...t})}}}]);})();
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=6105.6eda23ad.chunk.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/search/src/components/util.ts","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/search/src/components/HomePageComponent/HomePageSearchBar.tsx"],"names":[],"mappings":"kSAsBO,KAAM,GAAqB,IAAM,CACtC,KAAM,GAAc,kBAAY,MAC1B,EAAW,WACjB,MAAO,kBACL,CAAC,CAAE,WAAY,CACb,KAAM,GAAc,cAAa,CAAE,SAAS,CAAE,eAAgB,KAE9D,EAAS,GAAG,MAAgB,MAE9B,CAAC,EAAU,KCTT,EAAY,QAAW,CAC3B,KAAM,CACJ,OAAQ,iBACR,aAAc,MACd,SAAU,WAkBD,EAAoB,CAAC,IAAK,KAAY,CACjD,KAAM,GAAU,EAAU,GACpB,CAAC,EAAO,GAAY,eAAS,IAC7B,EAAe,IAEf,EAAe,IAAM,CACzB,EAAa,CAAE,WAGX,EAAe,kBACnB,GAAS,CACP,EAAS,IAEX,CAAC,IAGH,MACE,iBAAoB,gBAAe,CACjC,QAAS,CAAE,KAAM,EAAQ,MACzB,MAAO,EACP,SAAU,EACV,SAAU,KACP","file":"static/6105.6eda23ad.chunk.js","sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport qs from 'qs';\nimport { useCallback } from 'react';\nimport { useNavigate } from 'react-router-dom';\nimport { rootRouteRef } from '../plugin';\n\nimport { useRouteRef } from '@backstage/core-plugin-api';\n\nexport const useNavigateToQuery = () => {\n const searchRoute = useRouteRef(rootRouteRef);\n const navigate = useNavigate();\n return useCallback(\n ({ query }) => {\n const queryString = qs.stringify({ query }, { addQueryPrefix: true });\n\n navigate(`${searchRoute()}${queryString}`);\n },\n [navigate, searchRoute],\n );\n};\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { useCallback, useState } from 'react';\nimport { makeStyles } from '@material-ui/core/styles';\n\nimport { SearchBarBase, } from '../SearchBar';\nimport { useNavigateToQuery } from '../util';\n\nconst useStyles = makeStyles({\n root: {\n border: '1px solid #555',\n borderRadius: '6px',\n fontSize: '1.5em',\n },\n});\n\n/**\n * Props for {@link HomePageSearchBar}.\n *\n * @public\n */\n\n\n\n\n/**\n * The search bar created specifically for the composable home page\n *\n * @public\n */\nexport const HomePageSearchBar = ({ ...props }) => {\n const classes = useStyles(props);\n const [query, setQuery] = useState('');\n const handleSearch = useNavigateToQuery();\n\n const handleSubmit = () => {\n handleSearch({ query });\n };\n\n const handleChange = useCallback(\n value => {\n setQuery(value);\n },\n [setQuery],\n );\n\n return (\n React.createElement(SearchBarBase, {\n classes: { root: classes.root },\n value: query,\n onSubmit: handleSubmit,\n onChange: handleChange,\n ...props,}\n )\n );\n};\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/DependencyOfComponentsCard/DependencyOfComponentsCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/presets.ts"],"names":[],"mappings":"4PA+BO,WACL,EACA,CACA,KAAM,CAAE,UAAU,WAAY,QAAQ,4BAA+B,EACrE,MACE,iBAAoB,sBAAqB,CACvC,QAAS,EACT,MAAO,EACP,WAAY,YACZ,aAAc,KACd,QAAS,yBACT,aAAc,yCACd,cAAe,0BACf,qBAAsB,0B,ufCYrB,WACL,EACA,CACA,KAAM,CACJ,UAAU,WACV,QACA,UACA,aACA,eACA,eACA,gBACA,wBACE,EAEE,CAAE,UAAW,kBACb,CAAE,WAAU,UAAS,SAAU,yBAAmB,EAAQ,CAC9D,KAAM,EACN,KAAM,IAGR,MAAI,GAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,WAAU,OAKlC,EAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,qBAAoB,CAAE,MAAO,KAMvD,gBAAoB,cAAa,CAC/B,MAAO,EACP,QAAS,EACT,aACE,gBAAoB,MAAO,CAAE,MAAO,CAAE,UAAW,WAC7C,gBAAoB,IAAY,CAAE,QAAS,SAAW,GACtD,gBAAoB,IAAY,CAAE,QAAS,SACzC,gBAAoB,OAAM,CAAE,GAAI,GAAiB,+BAIzD,QAAS,EACT,SAAU,EAAqB,GAAY,MCjF1C,KAAM,GAAyB,CACpC,4CAA0C,CAAE,YAAa,cACzD,0CACA,6CACA,kDACA,yDAEW,EACX,uFACW,EAAuB,GAClC,EAEW,EAAwB,CACnC,4CAA0C,CAAE,YAAa,aACzD,0CACA,6CACA,kDACA,yDAEW,EACX,sFACW,EAAsB,GACjC,EAEW,EAAsB,CACjC,4CAA0C,CAAE,YAAa,WACzD,0CACA,yDAEW,EACX,oFACW,EAAoB,GAC/B","file":"static/6235.b3634d50.chunk.js","sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { RELATION_DEPENDENCY_OF } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asComponentEntities,\n componentEntityColumns,\n componentEntityHelpLink,\n RelatedEntitiesCard,\n} from '../RelatedEntitiesCard';\n\n/** @public */\n\n\n\n\n\nexport function DependencyOfComponentsCard(\n props,\n) {\n const { variant = 'gridItem', title = 'Dependency of components' } = props;\n return (\n React.createElement(RelatedEntitiesCard, {\n variant: variant,\n title: title,\n entityKind: \"Component\",\n relationType: RELATION_DEPENDENCY_OF,\n columns: componentEntityColumns,\n emptyMessage: \"No component depends on this component\" ,\n emptyHelpLink: componentEntityHelpLink,\n asRenderableEntities: asComponentEntities,}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Typography } from '@material-ui/core';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n Link,\n Progress,\n ResponseErrorPanel,\n\n} from '@backstage/core-components';\n\n/** @public */\n\n\n\n\n\n\n\n\n\n\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport function RelatedEntitiesCard(\n props,\n) {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n } = props;\n\n const { entity } = useEntity();\n const { entities, loading, error } = useRelatedEntities(entity, {\n type: relationType,\n kind: entityKind,\n });\n\n if (loading) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(Progress, null )\n )\n );\n }\n\n if (error) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(ResponseErrorPanel, { error: error,} )\n )\n );\n }\n\n return (\n React.createElement(EntityTable, {\n title: title,\n variant: variant,\n emptyContent: \n React.createElement('div', { style: { textAlign: 'center' },}\n , React.createElement(Typography, { variant: \"body1\",}, emptyMessage)\n , React.createElement(Typography, { variant: \"body2\",}\n , React.createElement(Link, { to: emptyHelpLink,}, \"Learn how to change this.\" )\n )\n )\n ,\n columns: columns,\n entities: asRenderableEntities(entities || []),}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { EntityTable } from '@backstage/plugin-catalog-react';\n\n\nexport const componentEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'component' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const componentEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component';\nexport const asComponentEntities = (entities) =>\n entities ;\n\nexport const resourceEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'resource' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const resourceEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-resource';\nexport const asResourceEntities = (entities) =>\n entities ;\n\nexport const systemEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'system' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const systemEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system';\nexport const asSystemEntities = (entities) =>\n entities ;\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/CatalogEntityPage/useEntityFromUrl.ts","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/CatalogEntityPage/CatalogEntityPage.tsx"],"names":[],"mappings":"oQA8BO,KAAM,GAAmB,IAAM,CACpC,KAAM,CAAE,OAAM,YAAW,QAAS,wBAAkB,kBAC9C,EAAW,WACX,EAAW,aAAO,eAClB,EAAa,aAAO,iBAEpB,CACJ,MAAO,EACP,QACA,UACA,MAAO,GACL,QACF,IAAM,EAAW,eAAe,CAAE,OAAM,YAAW,SACnD,CAAC,EAAY,EAAM,EAAW,IAGhC,sBAAU,IAAM,CACT,GACH,GAAS,KAAK,GAAI,OAAM,sBACxB,EAAS,OAEV,CAAC,EAAU,EAAU,EAAO,EAAS,EAAQ,IAEzC,CAAE,SAAQ,UAAS,QAAO,YC/B5B,YAA6B,CAClC,MACE,iBAAoB,sBAAqB,IAAK,KAC1C,gBAAoB,KAAQ","file":"static/6583.c98b5125.chunk.js","sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n errorApiRef,\n useApi,\n useRouteRefParams,\n} from '@backstage/core-plugin-api';\nimport {\n catalogApiRef,\n\n entityRouteRef,\n} from '@backstage/plugin-catalog-react';\nimport { useEffect } from 'react';\nimport { useNavigate } from 'react-router';\nimport useAsyncRetry from 'react-use/lib/useAsyncRetry';\n\nexport const useEntityFromUrl = () => {\n const { kind, namespace, name } = useRouteRefParams(entityRouteRef);\n const navigate = useNavigate();\n const errorApi = useApi(errorApiRef);\n const catalogApi = useApi(catalogApiRef);\n\n const {\n value: entity,\n error,\n loading,\n retry: refresh,\n } = useAsyncRetry(\n () => catalogApi.getEntityByRef({ kind, namespace, name }),\n [catalogApi, kind, namespace, name],\n );\n\n useEffect(() => {\n if (!name) {\n errorApi.post(new Error('No name provided!'));\n navigate('/');\n }\n }, [errorApi, navigate, error, loading, entity, name]);\n\n return { entity, loading, error, refresh };\n};\n","/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from 'react';\nimport { Outlet } from 'react-router';\nimport { AsyncEntityProvider } from '@backstage/plugin-catalog-react';\nimport { useEntityFromUrl } from './useEntityFromUrl';\n\n/** @public */\nexport function CatalogEntityPage() {\n return (\n React.createElement(AsyncEntityProvider, { ...useEntityFromUrl(),}\n , React.createElement(Outlet, null )\n )\n );\n}\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/techdocs/src/home/components/TechDocsCustomHome.tsx"],"names":[],"mappings":"+SA0CA,KAAM,GAAS,CACb,UAAW,YACX,aAAc,KAwCV,EAAc,CAAC,CACnB,SACA,WACA,WAKG,CAOH,KAAM,GAAU,GANE,KAAW,CAC3B,eAAgB,CACd,aAAc,UACV,EAAO,SAAW,EAAO,SAAW,QAItC,CAAE,QAAS,EAAkB,iBAAkB,2BAE/C,EAAQ,EAAO,EAAO,WAEtB,EAAgB,EAAS,OAAO,GAChC,EAAO,kBAAoB,cACzB,EACK,GAEF,EAAc,GAIrB,MAAO,GAAO,iBAAoB,YAClC,EAAO,gBAAgB,IAI3B,MACE,iBAAoB,WAAgB,KAChC,gBAAoB,gBAAe,CAAE,MAAO,EAAO,MAAO,YAAa,EAAO,aAC5E,IAAU,EACV,gBAAoB,gBAAe,KAAM,6CAGvC,MAEJ,gBAAoB,MAAO,CAAE,UAAW,EAAQ,gBAC9C,gBAAoB,EAAO,CAAE,cAAe,wBAAyB,SAAU,OAe5E,EAAsB,GAAU,CAC3C,KAAM,CAAE,cAAe,EACjB,CAAC,EAAa,GAAkB,eAAS,GACzC,EAAa,aAAO,iBAEpB,CACJ,MAAO,EACP,UACA,SACE,cAAS,SAcJ,MAbgB,GAAW,YAAY,CAC5C,OAAQ,CACN,iDAAkD,yBAEpD,OAAQ,CACN,aACA,OACA,WACA,YACA,aACA,gBAGY,MAAM,OAAQ,GAAW,C,MACvC,MAAO,CAAC,CAAC,MAAO,SAAS,cAAhB,cAA8B,iCAIrC,EAAmB,EAAW,GAEpC,MAAI,GAEA,gBAAoB,IAAqB,KACrC,gBAAoB,UAAS,KAC3B,gBAAoB,WAAU,QAMpC,EAEA,gBAAoB,IAAqB,KACrC,gBAAoB,UAAS,KAC3B,gBAAoB,eAAc,CAClC,SAAU,QACV,MAAO,2CAEL,gBAAoB,cAAa,CAAE,SAAU,OAAQ,KAAM,EAAM,gBAQ3E,gBAAoB,IAAqB,KACrC,gBAAoB,aAAY,CAChC,cAAe,EACf,SAAU,GAAS,EAAe,GAClC,KAAM,EAAW,IAAI,CAAC,CAAE,SAAS,IAAW,EAC1C,GAAI,EAAM,WACV,aAGF,gBAAoB,UAAS,CAAE,cAAe,oBAC5C,EAAiB,OAAO,IAAI,CAAC,EAAQ,IACrC,gBAAoB,EAAa,CAC/B,IAAK,EACL,OAAQ,EACR,SAAY,GAAsB,GAClC,MAAO","file":"static/7110.527cc68b.chunk.js","sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { useState } from 'react';\nimport useAsync from 'react-use/lib/useAsync';\nimport { makeStyles } from '@material-ui/core';\n\nimport {\n CATALOG_FILTER_EXISTS,\n catalogApiRef,\n\n useEntityOwnership,\n} from '@backstage/plugin-catalog-react';\n\nimport { DocsTable } from './Tables';\nimport { DocsCardGrid } from './Grids';\nimport { TechDocsPageWrapper } from './TechDocsPageWrapper';\n\nimport {\n CodeSnippet,\n Content,\n HeaderTabs,\n Progress,\n WarningPanel,\n SupportButton,\n ContentHeader,\n} from '@backstage/core-components';\nimport { useApi } from '@backstage/core-plugin-api';\n\nconst panels = {\n DocsTable: DocsTable,\n DocsCardGrid: DocsCardGrid,\n};\n\n/**\n * Available panel types\n *\n * @public\n */\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nconst CustomPanel = ({\n config,\n entities,\n index,\n}\n\n\n\n) => {\n const useStyles = makeStyles({\n panelContainer: {\n marginBottom: '2rem',\n ...(config.panelCSS ? config.panelCSS : {}),\n },\n });\n const classes = useStyles();\n const { loading: loadingOwnership, isOwnedEntity } = useEntityOwnership();\n\n const Panel = panels[config.panelType];\n\n const shownEntities = entities.filter(entity => {\n if (config.filterPredicate === 'ownedByUser') {\n if (loadingOwnership) {\n return false;\n }\n return isOwnedEntity(entity);\n }\n\n return (\n typeof config.filterPredicate === 'function' &&\n config.filterPredicate(entity)\n );\n });\n\n return (\n React.createElement(React.Fragment, null\n , React.createElement(ContentHeader, { title: config.title, description: config.description,}\n , index === 0 ? (\n React.createElement(SupportButton, null, \"Discover documentation in your ecosystem.\"\n\n )\n ) : null\n )\n , React.createElement('div', { className: classes.panelContainer,}\n , React.createElement(Panel, { 'data-testid': \"techdocs-custom-panel\", entities: shownEntities,} )\n )\n )\n );\n};\n\n/**\n * Props for {@link TechDocsCustomHome}\n *\n * @public\n */\n\n\n\n\nexport const TechDocsCustomHome = (props) => {\n const { tabsConfig } = props;\n const [selectedTab, setSelectedTab] = useState(0);\n const catalogApi = useApi(catalogApiRef);\n\n const {\n value: entities,\n loading,\n error,\n } = useAsync(async () => {\n const response = await catalogApi.getEntities({\n filter: {\n 'metadata.annotations.backstage.io/techdocs-ref': CATALOG_FILTER_EXISTS,\n },\n fields: [\n 'apiVersion',\n 'kind',\n 'metadata',\n 'relations',\n 'spec.owner',\n 'spec.type',\n ],\n });\n return response.items.filter((entity) => {\n return !!entity.metadata.annotations?.['backstage.io/techdocs-ref'];\n });\n });\n\n const currentTabConfig = tabsConfig[selectedTab];\n\n if (loading) {\n return (\n React.createElement(TechDocsPageWrapper, null\n , React.createElement(Content, null\n , React.createElement(Progress, null )\n )\n )\n );\n }\n\n if (error) {\n return (\n React.createElement(TechDocsPageWrapper, null\n , React.createElement(Content, null\n , React.createElement(WarningPanel, {\n severity: \"error\",\n title: \"Could not load available documentation.\" ,}\n \n , React.createElement(CodeSnippet, { language: \"text\", text: error.toString(),} )\n )\n )\n )\n );\n }\n\n return (\n React.createElement(TechDocsPageWrapper, null\n , React.createElement(HeaderTabs, {\n selectedIndex: selectedTab,\n onChange: index => setSelectedTab(index),\n tabs: tabsConfig.map(({ label }, index) => ({\n id: index.toString(),\n label,\n })),}\n )\n , React.createElement(Content, { 'data-testid': \"techdocs-content\",}\n , currentTabConfig.panels.map((config, index) => (\n React.createElement(CustomPanel, {\n key: index,\n config: config,\n entities: !!entities ? entities : [],\n index: index,}\n )\n ))\n )\n )\n );\n};\n"],"sourceRoot":""}
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
"use strict";(()=>{(self.webpackChunktechdocs_cli_embedded_app=self.webpackChunktechdocs_cli_embedded_app||[]).push([[7758],{7758:function(p,r,e){e.r(r),e.d(r,{CatalogPage:function(){return d},DefaultCatalogPage:function(){return c}});var t=e(2784),s=e(10289),l=e(9118),a=e(36964),n=e(53479),g=e(47851),E=e(30097),C=e(49782);function c(o){var m;const{columns:i,actions:f,initiallySelectedFilter:y="owned"}=o,P=(m=(0,a.useApi)(a.configApiRef).getOptionalString("organization.name"))!=null?m:"Backstage",u=(0,a.useRouteRef)(g.yw);return t.createElement(l.PageWithHeader,{title:`${P} Catalog`,themeId:"home"},t.createElement(n.EntityListProvider,null,t.createElement(l.Content,null,t.createElement(l.ContentHeader,{titleComponent:t.createElement(C.K,null)},t.createElement(l.CreateButton,{title:"Create Component",to:u&&u()}),t.createElement(l.SupportButton,null,"All your software catalog entities")),t.createElement(n.CatalogFilterLayout,null,t.createElement(n.CatalogFilterLayout.Filters,null,t.createElement(n.EntityTypePicker,null),t.createElement(n.UserListPicker,{initialFilter:y}),t.createElement(n.EntityOwnerPicker,null),t.createElement(n.EntityLifecyclePicker,null),t.createElement(n.EntityTagPicker,null)),t.createElement(n.CatalogFilterLayout.Content,null,t.createElement(E.E,{columns:i,actions:f}))))))}function d(o){return(0,s.pC)()||t.createElement(c,{...o})}}}]);})();
|
|
2
|
-
|
|
3
|
-
//# sourceMappingURL=7758.a6ab2713.chunk.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/CatalogPage/DefaultCatalogPage.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/CatalogPage/CatalogPage.tsx"],"names":[],"mappings":"qUAoDO,WAA4B,EAAO,C,MACxC,KAAM,CAAE,UAAS,UAAS,0BAA0B,SAAY,EAC1D,EACJ,G,GAAA,UAAO,gBAAc,kBAAkB,uBAAvC,OAA+D,YAC3D,EAAsB,kBAAY,MAExC,MACE,iBAAoB,iBAAgB,CAAE,MAAO,GAAG,YAAmB,QAAS,QACxE,gBAAoB,qBAAoB,KACtC,gBAAoB,UAAS,KAC3B,gBAAoB,gBAAe,CAAE,eAAgB,gBAAoB,IAAmB,OAC1F,gBAAoB,eAAc,CAClC,MAAO,mBACP,GAAI,GAAuB,MAE3B,gBAAoB,gBAAe,KAAM,uCAE3C,gBAAoB,sBAAqB,KACvC,gBAAoB,8BAA6B,KAC/C,gBAAoB,mBAAkB,MACtC,gBAAoB,iBAAgB,CAAE,cAAe,IACrD,gBAAoB,oBAAmB,MACvC,gBAAoB,wBAAuB,MAC3C,gBAAoB,kBAAiB,OAEvC,gBAAoB,8BAA6B,KAC/C,gBAAoB,IAAc,CAAE,QAAS,EAAS,QAAS,SCvDxE,WAAqB,EAAO,CAGjC,MAAO,GAFQ,SAEE,gBAAoB,EAAoB,IAAK","file":"static/7758.a6ab2713.chunk.js","sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n Content,\n ContentHeader,\n CreateButton,\n PageWithHeader,\n SupportButton,\n\n\n} from '@backstage/core-components';\nimport { configApiRef, useApi, useRouteRef } from '@backstage/core-plugin-api';\nimport {\n CatalogFilterLayout,\n EntityLifecyclePicker,\n EntityListProvider,\n EntityOwnerPicker,\n EntityTagPicker,\n EntityTypePicker,\n\n UserListPicker,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport { createComponentRouteRef } from '../../routes';\nimport { CatalogTable, } from '../CatalogTable';\nimport { CatalogKindHeader } from '../CatalogKindHeader';\n\n/**\n * Props for root catalog pages.\n *\n * @public\n */\n\n\n\n\n\n\nexport function DefaultCatalogPage(props) {\n const { columns, actions, initiallySelectedFilter = 'owned' } = props;\n const orgName =\n useApi(configApiRef).getOptionalString('organization.name') ?? 'Backstage';\n const createComponentLink = useRouteRef(createComponentRouteRef);\n\n return (\n React.createElement(PageWithHeader, { title: `${orgName} Catalog`, themeId: \"home\",}\n , React.createElement(EntityListProvider, null\n , React.createElement(Content, null\n , React.createElement(ContentHeader, { titleComponent: React.createElement(CatalogKindHeader, null ),}\n , React.createElement(CreateButton, {\n title: \"Create Component\" ,\n to: createComponentLink && createComponentLink(),}\n )\n , React.createElement(SupportButton, null, \"All your software catalog entities\" )\n )\n , React.createElement(CatalogFilterLayout, null\n , React.createElement(CatalogFilterLayout.Filters, null\n , React.createElement(EntityTypePicker, null )\n , React.createElement(UserListPicker, { initialFilter: initiallySelectedFilter,} )\n , React.createElement(EntityOwnerPicker, null )\n , React.createElement(EntityLifecyclePicker, null )\n , React.createElement(EntityTagPicker, null )\n )\n , React.createElement(CatalogFilterLayout.Content, null\n , React.createElement(CatalogTable, { columns: columns, actions: actions,} )\n )\n )\n )\n )\n )\n );\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from 'react';\nimport { useOutlet } from 'react-router';\nimport {\n DefaultCatalogPage,\n\n} from './DefaultCatalogPage';\n\nexport function CatalogPage(props) {\n const outlet = useOutlet();\n\n return outlet || React.createElement(DefaultCatalogPage, { ...props,} );\n}\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/AnsiProcessor.ts","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/styles.ts","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/LogLine.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/LogViewerControls.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/useLogViewerSearch.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/useLogViewerSelection.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/RealLogViewer.tsx"],"names":[],"mappings":"icAkBA,KAAM,GAAY,UACZ,EAAe,SAGf,EAAgB,OAAO,YAC3B,OAAO,QAAQ,CACb,EAAG,GAAM,KAAK,EAAG,KAAM,KACvB,EAAG,GAAM,KAAK,EAAG,OAAQ,KACzB,EAAG,GAAM,KAAK,EAAG,UAAW,KAC5B,GAAI,CAAC,CAAE,KAAM,KAAM,KAAQ,EAC3B,GAAI,CAAC,CAAE,OAAQ,KAAM,KAAQ,EAC7B,GAAI,CAAC,CAAE,UAAW,KAAM,KAAQ,EAChC,GAAI,GAAM,KAAK,EAAG,WAAY,UAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,QAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,UAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,WAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,SAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,YAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,SAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,UAC9B,GAAI,CAAC,CAAE,WAAY,KAAM,KAAQ,EACjC,GAAI,GAAM,KAAK,EAAG,WAAY,SAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,UAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,QAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,UAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,WAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,SAC9B,GAAI,GAAM,KAAK,EAAG,WAAY,YAC9B,GAA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,MACE,iBAAoB,MAAO,CACzB,MAAO,IAAK,GACZ,UAAW,IAAW,EAAQ,KAAM,EACjC,EAAQ,cAAe,EAAU,WAAW,MAG7C,EAAU,iBAAiB,IAC3B,gBAAoB,IAAY,CAC9B,cAAe,cACf,KAAM,QACN,UAAW,EAAQ,eACnB,QAAS,IAAM,EAAU,iBAEvB,gBAAoB,IAAU,CAAE,SAAU,aAG9C,gBAAoB,IAAK,CACzB,KAAM,MACN,OAAQ,QACR,KAAM,SAAS,IACf,UAAW,EAAQ,WACnB,QAAS,GAAS,EAAiB,EAAY,GAC/C,WAAY,GAAS,EAAiB,EAAY,IAEhD,GAEF,gBAAoB,GAAS,CAC7B,KAAM,EACN,QAAS,EACT,WAAY,EAAO,WACnB,qBACE,EAAO,aAAe,EAClB,EAAO,gBACP","file":"static/8718.cd7bb850.chunk.js","sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport ansiRegexMaker from 'ansi-regex';\n\nconst ansiRegex = ansiRegexMaker();\nconst newlineRegex = /\\n\\r?/g;\n\n// A mapping of how each escape code changes the modifiers\nconst codeModifiers = Object.fromEntries(\n Object.entries({\n 1: m => ({ ...m, bold: true }),\n 3: m => ({ ...m, italic: true }),\n 4: m => ({ ...m, underline: true }),\n 22: ({ bold: _, ...m }) => m,\n 23: ({ italic: _, ...m }) => m,\n 24: ({ underline: _, ...m }) => m,\n 30: m => ({ ...m, foreground: 'black' }),\n 31: m => ({ ...m, foreground: 'red' }),\n 32: m => ({ ...m, foreground: 'green' }),\n 33: m => ({ ...m, foreground: 'yellow' }),\n 34: m => ({ ...m, foreground: 'blue' }),\n 35: m => ({ ...m, foreground: 'magenta' }),\n 36: m => ({ ...m, foreground: 'cyan' }),\n 37: m => ({ ...m, foreground: 'white' }),\n 39: ({ foreground: _, ...m }) => m,\n 90: m => ({ ...m, foreground: 'grey' }),\n 40: m => ({ ...m, background: 'black' }),\n 41: m => ({ ...m, background: 'red' }),\n 42: m => ({ ...m, background: 'green' }),\n 43: m => ({ ...m, background: 'yellow' }),\n 44: m => ({ ...m, background: 'blue' }),\n 45: m => ({ ...m, background: 'magenta' }),\n 46: m => ({ ...m, background: 'cyan' }),\n 47: m => ({ ...m, background: 'white' }),\n 49: ({ background: _, ...m }) => m,\n } ).map(\n ([code, modifier]) => [`\\x1b[${code}m`, modifier],\n ),\n);\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nexport class AnsiLine {\n text;\n\n constructor(\n lineNumber = 1,\n chunks = [],\n ) {;this.lineNumber = lineNumber;this.chunks = chunks;\n this.text = chunks\n .map(c => c.text)\n .join('')\n .toLocaleLowerCase('en-US');\n }\n\n lastChunk() {\n return this.chunks[this.chunks.length - 1];\n }\n\n replaceLastChunk(newChunks) {\n if (newChunks) {\n this.chunks.splice(this.chunks.length - 1, 1, ...newChunks);\n this.text = this.chunks\n .map(c => c.text)\n .join('')\n .toLocaleLowerCase('en-US');\n }\n }\n}\n\nexport class AnsiProcessor {\n text = '';\n lines = [];\n\n /**\n * Processes a chunk of text while keeping internal state that optimizes\n * subsequent processing that appends to the text.\n */\n process(text) {\n if (this.text === text) {\n return this.lines;\n }\n\n if (text.startsWith(this.text)) {\n const lastLineIndex = this.lines.length > 0 ? this.lines.length - 1 : 0;\n const lastLine = this.lines[lastLineIndex] ?? new AnsiLine();\n const lastChunk = lastLine.lastChunk();\n\n const newLines = this.processLines(\n (lastChunk?.text ?? '') + text.slice(this.text.length),\n lastChunk?.modifiers,\n lastLine?.lineNumber,\n );\n lastLine.replaceLastChunk(newLines[0]?.chunks);\n\n this.lines[lastLineIndex] = lastLine;\n this.lines.push(...newLines.slice(1));\n } else {\n this.lines = this.processLines(text);\n }\n this.text = text;\n\n return this.lines;\n }\n\n // Split a chunk of text up into lines and process each line individually\n processLines = (\n text,\n modifiers = {},\n startingLineNumber = 1,\n ) => {\n const lines = [];\n\n let currentModifiers = modifiers;\n let currentLineNumber = startingLineNumber;\n\n let prevIndex = 0;\n newlineRegex.lastIndex = 0;\n for (;;) {\n const match = newlineRegex.exec(text);\n if (!match) {\n const chunks = this.processText(\n text.slice(prevIndex),\n currentModifiers,\n );\n lines.push(new AnsiLine(currentLineNumber, chunks));\n return lines;\n }\n\n const line = text.slice(prevIndex, match.index);\n prevIndex = match.index + match[0].length;\n\n const chunks = this.processText(line, currentModifiers);\n lines.push(new AnsiLine(currentLineNumber, chunks));\n\n // Modifiers that are active in the last chunk are carried over to the next line\n currentModifiers =\n chunks[chunks.length - 1].modifiers ?? currentModifiers;\n currentLineNumber += 1;\n }\n };\n\n // Processing of a one individual text chunk\n processText = (\n fullText,\n modifiers,\n ) => {\n const chunks = [];\n\n let currentModifiers = modifiers;\n\n let prevIndex = 0;\n ansiRegex.lastIndex = 0;\n for (;;) {\n const match = ansiRegex.exec(fullText);\n if (!match) {\n chunks.push({\n text: fullText.slice(prevIndex),\n modifiers: currentModifiers,\n });\n return chunks;\n }\n\n const text = fullText.slice(prevIndex, match.index);\n chunks.push({ text, modifiers: currentModifiers });\n\n // For every escape code that we encounter we keep track of where the\n // next chunk of text starts, and what modifiers it has\n prevIndex = match.index + match[0].length;\n currentModifiers = this.processCode(match[0], currentModifiers);\n }\n };\n\n processCode = (\n code,\n modifiers,\n ) => {\n return codeModifiers[code]?.(modifiers) ?? modifiers;\n };\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { alpha, makeStyles } from '@material-ui/core/styles';\nimport * as colors from '@material-ui/core/colors';\n\nexport const HEADER_SIZE = 40;\n\n/** @public Class keys for overriding LogViewer styles */\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nexport const useStyles = makeStyles(\n theme => ({\n root: {\n background: theme.palette.background.paper,\n },\n header: {\n height: HEADER_SIZE,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n log: {\n fontFamily: '\"Monaco\", monospace',\n fontSize: theme.typography.pxToRem(12),\n },\n line: {\n position: 'relative',\n whiteSpace: 'pre',\n\n '&:hover': {\n background: theme.palette.action.hover,\n },\n },\n lineSelected: {\n background: theme.palette.action.selected,\n\n '&:hover': {\n background: theme.palette.action.selected,\n },\n },\n lineCopyButton: {\n position: 'absolute',\n paddingTop: 0,\n paddingBottom: 0,\n },\n lineNumber: {\n display: 'inline-block',\n textAlign: 'end',\n width: 60,\n marginRight: theme.spacing(1),\n cursor: 'pointer',\n },\n textHighlight: {\n background: alpha(theme.palette.info.main, 0.15),\n },\n textSelectedHighlight: {\n background: alpha(theme.palette.info.main, 0.4),\n },\n modifierBold: {\n fontWeight: theme.typography.fontWeightBold,\n },\n modifierItalic: {\n fontStyle: 'italic',\n },\n modifierUnderline: {\n textDecoration: 'underline',\n },\n modifierForegroundBlack: {\n color: colors.common.black,\n },\n modifierForegroundRed: {\n color: colors.red[500],\n },\n modifierForegroundGreen: {\n color: colors.green[500],\n },\n modifierForegroundYellow: {\n color: colors.yellow[500],\n },\n modifierForegroundBlue: {\n color: colors.blue[500],\n },\n modifierForegroundMagenta: {\n color: colors.purple[500],\n },\n modifierForegroundCyan: {\n color: colors.cyan[500],\n },\n modifierForegroundWhite: {\n color: colors.common.white,\n },\n modifierForegroundGrey: {\n color: colors.grey[500],\n },\n modifierBackgroundBlack: {\n background: colors.common.black,\n },\n modifierBackgroundRed: {\n background: colors.red[500],\n },\n modifierBackgroundGreen: {\n background: colors.green[500],\n },\n modifierBackgroundYellow: {\n background: colors.yellow[500],\n },\n modifierBackgroundBlue: {\n background: colors.blue[500],\n },\n modifierBackgroundMagenta: {\n background: colors.purple[500],\n },\n modifierBackgroundCyan: {\n background: colors.cyan[500],\n },\n modifierBackgroundWhite: {\n background: colors.common.white,\n },\n modifierBackgroundGrey: {\n background: colors.grey[500],\n },\n }),\n { name: 'BackstageLogViewer' },\n);\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { useMemo } from 'react';\n\nimport startCase from 'lodash/startCase';\nimport classnames from 'classnames';\n\n\nexport function getModifierClasses(\n classes,\n modifiers,\n) {\n const classNames = new Array();\n if (modifiers.bold) {\n classNames.push(classes.modifierBold);\n }\n if (modifiers.italic) {\n classNames.push(classes.modifierItalic);\n }\n if (modifiers.underline) {\n classNames.push(classes.modifierUnderline);\n }\n if (modifiers.foreground) {\n const key = `modifierForeground${startCase(\n modifiers.foreground,\n )}` ;\n classNames.push(classes[key]);\n }\n if (modifiers.background) {\n const key = `modifierBackground${startCase(\n modifiers.background,\n )}` ;\n classNames.push(classes[key]);\n }\n return classNames.length > 0 ? classNames.join(' ') : undefined;\n}\n\nexport function findSearchResults(text, searchText) {\n if (!searchText || !text.includes(searchText)) {\n return undefined;\n }\n const searchResults = new Array();\n let offset = 0;\n for (;;) {\n const start = text.indexOf(searchText, offset);\n if (start === -1) {\n break;\n }\n const end = start + searchText.length;\n searchResults.push({ start, end });\n offset = end;\n }\n return searchResults;\n}\n\n\n\n\n\nexport function calculateHighlightedChunks(\n line,\n searchText,\n) {\n const results = findSearchResults(line.text, searchText);\n if (!results) {\n return line.chunks;\n }\n\n const chunks = new Array();\n\n let lineOffset = 0;\n let resultIndex = 0;\n let result = results[resultIndex];\n for (const chunk of line.chunks) {\n const { text, modifiers } = chunk;\n if (!result || lineOffset + text.length < result.start) {\n chunks.push(chunk);\n lineOffset += text.length;\n continue;\n }\n\n let localOffset = 0;\n while (result) {\n const localStart = Math.max(result.start - lineOffset, 0);\n if (localStart > text.length) {\n break; // The next result is not in this chunk\n }\n\n const localEnd = Math.min(result.end - lineOffset, text.length);\n\n const hasTextBeforeResult = localStart > localOffset;\n if (hasTextBeforeResult) {\n chunks.push({ text: text.slice(localOffset, localStart), modifiers });\n }\n const hasResultText = localEnd > localStart;\n if (hasResultText) {\n chunks.push({\n modifiers,\n highlight: resultIndex,\n text: text.slice(localStart, localEnd),\n });\n }\n\n localOffset = localEnd;\n\n const foundCompleteResult = result.end - lineOffset === localEnd;\n if (foundCompleteResult) {\n resultIndex += 1;\n result = results[resultIndex];\n } else {\n break; // The rest of the result is in the following chunks\n }\n }\n\n const hasTextAfterResult = localOffset < text.length;\n if (hasTextAfterResult) {\n chunks.push({ text: text.slice(localOffset), modifiers });\n }\n\n lineOffset += text.length;\n }\n\n return chunks;\n}\n\n\n\n\n\n\n\n\nexport function LogLine({\n line,\n classes,\n searchText,\n highlightResultIndex,\n}) {\n const chunks = useMemo(\n () => calculateHighlightedChunks(line, searchText),\n [line, searchText],\n );\n\n const elements = useMemo(\n () =>\n chunks.map(({ text, modifiers, highlight }, index) => (\n React.createElement('span', {\n key: index,\n className: classnames(\n getModifierClasses(classes, modifiers),\n highlight !== undefined &&\n (highlight === highlightResultIndex\n ? classes.textSelectedHighlight\n : classes.textHighlight),\n ),}\n \n , text\n )\n )),\n [chunks, highlightResultIndex, classes],\n );\n\n return React.createElement(React.Fragment, null, elements);\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React from 'react';\nimport IconButton from '@material-ui/core/IconButton';\nimport TextField from '@material-ui/core/TextField';\nimport Typography from '@material-ui/core/Typography';\nimport ChevronLeftIcon from '@material-ui/icons/ChevronLeft';\nimport ChevronRightIcon from '@material-ui/icons/ChevronRight';\nimport FilterListIcon from '@material-ui/icons/FilterList';\n\n\n\n\nexport function LogViewerControls(props) {\n const { resultCount, resultIndexStep, toggleShouldFilter } = props;\n const resultIndex = props.resultIndex ?? 0;\n\n const handleKeyPress = (event) => {\n if (event.key === 'Enter') {\n if (event.metaKey || event.ctrlKey || event.altKey) {\n toggleShouldFilter();\n } else {\n resultIndexStep(event.shiftKey);\n }\n }\n };\n\n return (\n React.createElement(React.Fragment, null\n , resultCount !== undefined && (\n React.createElement(React.Fragment, null\n , React.createElement(IconButton, { size: \"small\", onClick: () => resultIndexStep(true),}\n , React.createElement(ChevronLeftIcon, null )\n )\n , React.createElement(Typography, null\n , Math.min(resultIndex + 1, resultCount), \"/\", resultCount\n )\n , React.createElement(IconButton, { size: \"small\", onClick: () => resultIndexStep(),}\n , React.createElement(ChevronRightIcon, null )\n )\n )\n )\n , React.createElement(TextField, {\n size: \"small\",\n variant: \"standard\",\n placeholder: \"Search\",\n value: props.searchInput,\n onKeyPress: handleKeyPress,\n onChange: e => props.setSearchInput(e.target.value),}\n )\n , React.createElement(IconButton, { size: \"small\", onClick: toggleShouldFilter,}\n , props.shouldFilter ? (\n React.createElement(FilterListIcon, { color: \"primary\",} )\n ) : (\n React.createElement(FilterListIcon, { color: \"disabled\",} )\n )\n )\n )\n );\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useMemo, useState } from 'react';\nimport { useToggle } from '@react-hookz/web';\n\n\nexport function applySearchFilter(lines, searchText) {\n if (!searchText) {\n return { lines };\n }\n\n const matchingLines = [];\n const searchResults = [];\n for (const line of lines) {\n if (line.text.includes(searchText)) {\n matchingLines.push(line);\n\n let offset = 0;\n let lineResultIndex = 0;\n for (;;) {\n const start = line.text.indexOf(searchText, offset);\n if (start === -1) {\n break;\n }\n searchResults.push({\n lineNumber: line.lineNumber,\n lineIndex: lineResultIndex++,\n });\n offset = start + searchText.length;\n }\n }\n }\n\n return {\n lines: matchingLines,\n results: searchResults,\n };\n}\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nexport function useLogViewerSearch(lines) {\n const [searchInput, setSearchInput] = useState('');\n const searchText = searchInput.toLocaleLowerCase('en-US');\n\n const [resultIndex, setResultIndex] = useState(0);\n\n const [shouldFilter, toggleShouldFilter] = useToggle(false);\n\n const filter = useMemo(\n () => applySearchFilter(lines, searchText),\n [lines, searchText],\n );\n\n const searchResult = filter.results\n ? filter.results[Math.min(resultIndex, filter.results.length - 1)]\n : undefined;\n const resultCount = filter.results?.length;\n\n const resultIndexStep = (decrement) => {\n if (decrement) {\n if (resultCount !== undefined) {\n const next = Math.min(resultIndex - 1, resultCount - 2);\n setResultIndex(next < 0 ? resultCount - 1 : next);\n }\n } else {\n if (resultCount !== undefined) {\n const next = resultIndex + 1;\n setResultIndex(next >= resultCount ? 0 : next);\n }\n }\n };\n\n return {\n lines: shouldFilter ? filter.lines : lines,\n searchText,\n searchInput,\n setSearchInput,\n shouldFilter,\n toggleShouldFilter,\n resultCount,\n resultIndex,\n resultIndexStep,\n resultLine: searchResult?.lineNumber,\n resultLineIndex: searchResult?.lineIndex,\n };\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { errorApiRef, useApi } from '@backstage/core-plugin-api';\nimport { useEffect, useState } from 'react';\nimport useCopyToClipboard from 'react-use/lib/useCopyToClipboard';\n\n\nexport function useLogViewerSelection(lines) {\n const errorApi = useApi(errorApiRef);\n const [sel, setSelection] = useState();\n const start = sel ? Math.min(sel.start, sel.end) : undefined;\n const end = sel ? Math.max(sel.start, sel.end) : undefined;\n\n const [{ error }, copyToClipboard] = useCopyToClipboard();\n\n useEffect(() => {\n if (error) {\n errorApi.post(error);\n }\n }, [error, errorApi]);\n\n return {\n shouldShowButton(line) {\n return start === line || end === line;\n },\n isSelected(line) {\n if (!sel) {\n return false;\n }\n return start <= line && line <= end;\n },\n setSelection(line, add) {\n if (add) {\n setSelection(s =>\n s ? { start: s.start, end: line } : { start: line, end: line },\n );\n } else {\n setSelection(s =>\n s?.start === line && s?.end === line\n ? undefined\n : { start: line, end: line },\n );\n }\n },\n copySelection() {\n if (sel) {\n const copyText = lines\n .slice(Math.min(sel.start, sel.end) - 1, Math.max(sel.start, sel.end))\n .map(l => l.chunks.map(c => c.text).join(''))\n .join('\\n');\n copyToClipboard(copyText);\n setSelection(undefined);\n }\n },\n };\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport React, { useEffect, useMemo, useRef } from 'react';\nimport { useLocation } from 'react-router-dom';\nimport IconButton from '@material-ui/core/IconButton';\nimport CopyIcon from '@material-ui/icons/FileCopy';\nimport AutoSizer from 'react-virtualized-auto-sizer';\nimport { FixedSizeList } from 'react-window';\nimport { AnsiProcessor } from './AnsiProcessor';\nimport { HEADER_SIZE, useStyles } from './styles';\nimport classnames from 'classnames';\nimport { LogLine } from './LogLine';\nimport { LogViewerControls } from './LogViewerControls';\nimport { useLogViewerSearch } from './useLogViewerSearch';\nimport { useLogViewerSelection } from './useLogViewerSelection';\n\n\n\n\n\n\nexport function RealLogViewer(props) {\n const classes = useStyles({ classes: props.classes });\n const listRef = useRef(null);\n\n // The processor keeps state that optimizes appending to the text\n const processor = useMemo(() => new AnsiProcessor(), []);\n const lines = processor.process(props.text);\n\n const search = useLogViewerSearch(lines);\n const selection = useLogViewerSelection(lines);\n const location = useLocation();\n\n useEffect(() => {\n if (search.resultLine !== undefined && listRef.current) {\n listRef.current.scrollToItem(search.resultLine - 1, 'center');\n }\n }, [search.resultLine]);\n\n useEffect(() => {\n if (location.hash) {\n // #line-6 -> 6\n const line = parseInt(location.hash.replace(/\\D/g, ''), 10);\n selection.setSelection(line, false);\n }\n }, []); // eslint-disable-line react-hooks/exhaustive-deps\n\n const handleSelectLine = (\n line,\n event,\n ) => {\n selection.setSelection(line, event.shiftKey);\n };\n\n return (\n React.createElement(AutoSizer, null\n , ({ height, width }) => (\n React.createElement('div', { style: { width, height }, className: classes.root,}\n , React.createElement('div', { className: classes.header,}\n , React.createElement(LogViewerControls, { ...search,} )\n )\n , React.createElement(FixedSizeList, {\n ref: listRef,\n className: classes.log,\n height: height - HEADER_SIZE,\n width: width,\n itemData: search.lines,\n itemSize: 20,\n itemCount: search.lines.length,}\n \n , ({ index, style, data }) => {\n const line = data[index];\n const { lineNumber } = line;\n return (\n React.createElement('div', {\n style: { ...style },\n className: classnames(classes.line, {\n [classes.lineSelected]: selection.isSelected(lineNumber),\n }),}\n \n , selection.shouldShowButton(lineNumber) && (\n React.createElement(IconButton, {\n 'data-testid': \"copy-button\",\n size: \"small\",\n className: classes.lineCopyButton,\n onClick: () => selection.copySelection(),}\n \n , React.createElement(CopyIcon, { fontSize: \"inherit\",} )\n )\n )\n , React.createElement('a', {\n role: \"row\",\n target: \"_self\",\n href: `#line-${lineNumber}`,\n className: classes.lineNumber,\n onClick: event => handleSelectLine(lineNumber, event),\n onKeyPress: event => handleSelectLine(lineNumber, event),}\n \n , lineNumber\n )\n , React.createElement(LogLine, {\n line: line,\n classes: classes,\n searchText: search.searchText,\n highlightResultIndex: \n search.resultLine === lineNumber\n ? search.resultLineIndex\n : undefined\n ,}\n )\n )\n );\n }\n )\n )\n )\n )\n );\n}\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/HasSubcomponentsCard/HasSubcomponentsCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/presets.ts"],"names":[],"mappings":"sPA6BO,WAA8B,EAAO,CAC1C,KAAM,CAAE,UAAU,YAAe,EACjC,MACE,iBAAoB,sBAAqB,CACvC,QAAS,EACT,MAAO,oBACP,WAAY,YACZ,aAAc,KACd,QAAS,yBACT,qBAAsB,sBACtB,aAAc,4CACd,cAAe,wG,ufCgBd,WACL,EACA,CACA,KAAM,CACJ,UAAU,WACV,QACA,UACA,aACA,eACA,eACA,gBACA,wBACE,EAEE,CAAE,UAAW,kBACb,CAAE,WAAU,UAAS,SAAU,yBAAmB,EAAQ,CAC9D,KAAM,EACN,KAAM,IAGR,MAAI,GAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,WAAU,OAKlC,EAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,qBAAoB,CAAE,MAAO,KAMvD,gBAAoB,cAAa,CAC/B,MAAO,EACP,QAAS,EACT,aACE,gBAAoB,MAAO,CAAE,MAAO,CAAE,UAAW,WAC7C,gBAAoB,IAAY,CAAE,QAAS,SAAW,GACtD,gBAAoB,IAAY,CAAE,QAAS,SACzC,gBAAoB,OAAM,CAAE,GAAI,GAAiB,+BAIzD,QAAS,EACT,SAAU,EAAqB,GAAY,MCjF1C,KAAM,GAAyB,CACpC,4CAA0C,CAAE,YAAa,cACzD,0CACA,6CACA,kDACA,yDAEW,EACX,uFACW,EAAuB,GAClC,EAEW,EAAwB,CACnC,4CAA0C,CAAE,YAAa,aACzD,0CACA,6CACA,kDACA,yDAEW,EACX,sFACW,EAAsB,GACjC,EAEW,EAAsB,CACjC,4CAA0C,CAAE,YAAa,WACzD,0CACA,yDAEW,EACX,oFACW,EAAoB,GAC/B","file":"static/8792.867bf73e.chunk.js","sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { RELATION_HAS_PART } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asComponentEntities,\n componentEntityColumns,\n RelatedEntitiesCard,\n} from '../RelatedEntitiesCard';\n\n/** @public */\n\n\n\n\nexport function HasSubcomponentsCard(props) {\n const { variant = 'gridItem' } = props;\n return (\n React.createElement(RelatedEntitiesCard, {\n variant: variant,\n title: \"Has subcomponents\" ,\n entityKind: \"Component\",\n relationType: RELATION_HAS_PART,\n columns: componentEntityColumns,\n asRenderableEntities: asComponentEntities,\n emptyMessage: \"No subcomponent is part of this component\" ,\n emptyHelpLink: \"https://backstage.io/docs/features/software-catalog/descriptor-format#specsubcomponentof-optional\",}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Typography } from '@material-ui/core';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n Link,\n Progress,\n ResponseErrorPanel,\n\n} from '@backstage/core-components';\n\n/** @public */\n\n\n\n\n\n\n\n\n\n\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport function RelatedEntitiesCard(\n props,\n) {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n } = props;\n\n const { entity } = useEntity();\n const { entities, loading, error } = useRelatedEntities(entity, {\n type: relationType,\n kind: entityKind,\n });\n\n if (loading) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(Progress, null )\n )\n );\n }\n\n if (error) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(ResponseErrorPanel, { error: error,} )\n )\n );\n }\n\n return (\n React.createElement(EntityTable, {\n title: title,\n variant: variant,\n emptyContent: \n React.createElement('div', { style: { textAlign: 'center' },}\n , React.createElement(Typography, { variant: \"body1\",}, emptyMessage)\n , React.createElement(Typography, { variant: \"body2\",}\n , React.createElement(Link, { to: emptyHelpLink,}, \"Learn how to change this.\" )\n )\n )\n ,\n columns: columns,\n entities: asRenderableEntities(entities || []),}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { EntityTable } from '@backstage/plugin-catalog-react';\n\n\nexport const componentEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'component' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const componentEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component';\nexport const asComponentEntities = (entities) =>\n entities ;\n\nexport const resourceEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'resource' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const resourceEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-resource';\nexport const asResourceEntities = (entities) =>\n entities ;\n\nexport const systemEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'system' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const systemEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system';\nexport const asSystemEntities = (entities) =>\n entities ;\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/DependsOnResourcesCard/DependsOnResourcesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/RelatedEntitiesCard.tsx","webpack://techdocs-cli-embedded-app/../node_modules/@sucrase/webpack-loader/dist/plugins/catalog/src/components/RelatedEntitiesCard/presets.ts"],"names":[],"mappings":"wPA8BO,WAAgC,EAAO,CAC5C,KAAM,CAAE,UAAU,YAAe,EACjC,MACE,iBAAoB,sBAAqB,CACvC,QAAS,EACT,MAAO,uBACP,WAAY,WACZ,aAAc,KACd,QAAS,wBACT,aAAc,gDACd,cAAe,0BACf,qBAAsB,yB,ufCerB,WACL,EACA,CACA,KAAM,CACJ,UAAU,WACV,QACA,UACA,aACA,eACA,eACA,gBACA,wBACE,EAEE,CAAE,UAAW,kBACb,CAAE,WAAU,UAAS,SAAU,yBAAmB,EAAQ,CAC9D,KAAM,EACN,KAAM,IAGR,MAAI,GAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,WAAU,OAKlC,EAEA,gBAAoB,WAAU,CAAE,QAAS,EAAS,MAAO,GACrD,gBAAoB,qBAAoB,CAAE,MAAO,KAMvD,gBAAoB,cAAa,CAC/B,MAAO,EACP,QAAS,EACT,aACE,gBAAoB,MAAO,CAAE,MAAO,CAAE,UAAW,WAC7C,gBAAoB,IAAY,CAAE,QAAS,SAAW,GACtD,gBAAoB,IAAY,CAAE,QAAS,SACzC,gBAAoB,OAAM,CAAE,GAAI,GAAiB,+BAIzD,QAAS,EACT,SAAU,EAAqB,GAAY,MCjF1C,KAAM,GAAyB,CACpC,4CAA0C,CAAE,YAAa,cACzD,0CACA,6CACA,kDACA,yDAEW,EACX,uFACW,EAAuB,GAClC,EAEW,EAAwB,CACnC,4CAA0C,CAAE,YAAa,aACzD,0CACA,6CACA,kDACA,yDAEW,EACX,sFACW,EAAsB,GACjC,EAEW,EAAsB,CACjC,4CAA0C,CAAE,YAAa,WACzD,0CACA,yDAEW,EACX,oFACW,EAAoB,GAC/B","file":"static/9028.200536ea.chunk.js","sourcesContent":["/*\n * Copyright 2020 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { RELATION_DEPENDS_ON } from '@backstage/catalog-model';\nimport React from 'react';\nimport {\n asResourceEntities,\n componentEntityHelpLink,\n RelatedEntitiesCard,\n resourceEntityColumns,\n} from '../RelatedEntitiesCard';\n\n/** @public */\n\n\n\n\nexport function DependsOnResourcesCard(props) {\n const { variant = 'gridItem' } = props;\n return (\n React.createElement(RelatedEntitiesCard, {\n variant: variant,\n title: \"Depends on resources\" ,\n entityKind: \"Resource\",\n relationType: RELATION_DEPENDS_ON,\n columns: resourceEntityColumns,\n emptyMessage: \"No resource is a dependency of this component\" ,\n emptyHelpLink: componentEntityHelpLink,\n asRenderableEntities: asResourceEntities,}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Typography } from '@material-ui/core';\nimport {\n EntityTable,\n useEntity,\n useRelatedEntities,\n} from '@backstage/plugin-catalog-react';\nimport React from 'react';\nimport {\n InfoCard,\n Link,\n Progress,\n ResponseErrorPanel,\n\n} from '@backstage/core-components';\n\n/** @public */\n\n\n\n\n\n\n\n\n\n\n\n/**\n * A low level card component that can be used as a building block for more\n * specific cards.\n *\n * @remarks\n *\n * You probably want to make a dedicated component for your needs, which renders\n * this card as its implementation with some of the props set to the appropriate\n * values.\n *\n * @public\n */\nexport function RelatedEntitiesCard(\n props,\n) {\n const {\n variant = 'gridItem',\n title,\n columns,\n entityKind,\n relationType,\n emptyMessage,\n emptyHelpLink,\n asRenderableEntities,\n } = props;\n\n const { entity } = useEntity();\n const { entities, loading, error } = useRelatedEntities(entity, {\n type: relationType,\n kind: entityKind,\n });\n\n if (loading) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(Progress, null )\n )\n );\n }\n\n if (error) {\n return (\n React.createElement(InfoCard, { variant: variant, title: title,}\n , React.createElement(ResponseErrorPanel, { error: error,} )\n )\n );\n }\n\n return (\n React.createElement(EntityTable, {\n title: title,\n variant: variant,\n emptyContent: \n React.createElement('div', { style: { textAlign: 'center' },}\n , React.createElement(Typography, { variant: \"body1\",}, emptyMessage)\n , React.createElement(Typography, { variant: \"body2\",}\n , React.createElement(Link, { to: emptyHelpLink,}, \"Learn how to change this.\" )\n )\n )\n ,\n columns: columns,\n entities: asRenderableEntities(entities || []),}\n )\n );\n}\n","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { EntityTable } from '@backstage/plugin-catalog-react';\n\n\nexport const componentEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'component' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const componentEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component';\nexport const asComponentEntities = (entities) =>\n entities ;\n\nexport const resourceEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'resource' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createSpecTypeColumn(),\n EntityTable.columns.createSpecLifecycleColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const resourceEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-resource';\nexport const asResourceEntities = (entities) =>\n entities ;\n\nexport const systemEntityColumns = [\n EntityTable.columns.createEntityRefColumn({ defaultKind: 'system' }),\n EntityTable.columns.createOwnerColumn(),\n EntityTable.columns.createMetadataDescriptionColumn(),\n];\nexport const systemEntityHelpLink =\n 'https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system';\nexport const asSystemEntities = (entities) =>\n entities ;\n"],"sourceRoot":""}
|