mdts 0.5.1 → 0.7.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/dist/cli.js +5 -1
- package/dist/frontend/bundle.js +10202 -493
- package/dist/frontend/markdown.css +3 -3
- package/dist/frontend/node_modules_mermaid-js_parser_dist_chunks_mermaid-parser_core_architecture-O4VJ6CD3_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid-js_parser_dist_chunks_mermaid-parser_core_gitGraph-ZV4HHKMB_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid-js_parser_dist_chunks_mermaid-parser_core_info-63CPKGFF_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid-js_parser_dist_chunks_mermaid-parser_core_packet-HUATNLJX_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid-js_parser_dist_chunks_mermaid-parser_core_pie-WTHONI2E_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid-js_parser_dist_chunks_mermaid-parser_core_radar-NJJJXTRR_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid-js_parser_dist_chunks_mermaid-parser_core_treemap-75Q7IDZK_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid_dist_chunks_mermaid_core_classDiagram-M3E45YP4_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid_dist_chunks_mermaid_core_classDiagram-v2-YAWTLIQI_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid_dist_chunks_mermaid_core_diagram-5UYTHUR4_mjs.bundle.js +32 -0
- package/dist/frontend/node_modules_mermaid_dist_chunks_mermaid_core_infoDiagram-LHK5PUON_mjs.bundle.js +22 -0
- package/dist/frontend/node_modules_mermaid_dist_chunks_mermaid_core_pieDiagram-NIOCPIFQ_mjs.bundle.js +32 -0
- package/dist/frontend/node_modules_mermaid_dist_chunks_mermaid_core_stateDiagram-v2-5AN5P6BG_mjs.bundle.js +22 -0
- package/dist/frontend/vendors-node_modules_cytoscape_dist_cytoscape_esm_mjs.bundle.js +22 -0
- package/dist/frontend/vendors-node_modules_dagre-d3-es_src_dagre_index_js.bundle.js +682 -0
- package/dist/frontend/vendors-node_modules_dagre-d3-es_src_graphlib_index_js.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_katex_dist_katex_mjs.bundle.js +22 -0
- package/dist/frontend/vendors-node_modules_lodash-es__baseClone_js-node_modules_lodash-es__baseFlatten_js-node_modu-64f2a5.bundle.js +852 -0
- package/dist/frontend/vendors-node_modules_lodash-es__basePickBy_js-node_modules_lodash-es__hasUnicode_js-node_modu-b1bc3b.bundle.js +232 -0
- package/dist/frontend/vendors-node_modules_mermaid-js_parser_dist_mermaid-parser_core_mjs.bundle.js +1582 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_architectureDiagram-SUXI7LT5_mjs.bundle.js +74 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_blockDiagram-6J76NXCF_mjs.bundle.js +52 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_c4Diagram-6F6E4RAY_mjs.bundle.js +32 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_chunk-OW32GOEJ_mjs.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_chunk-SZ463SBG_mjs.bundle.js +52 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_dagre-JOIXM2OF_mjs.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_diagram-VMROVX33_mjs.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_diagram-ZTM2IBQH_mjs.bundle.js +32 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_erDiagram-3M52JZNH_mjs.bundle.js +52 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_flowDiagram-KYDEHFYC_mjs.bundle.js +62 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_ganttDiagram-EK5VF46D_mjs.bundle.js +52 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_gitGraphDiagram-GW3U2K7C_mjs.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_journeyDiagram-EWQZEKCU_mjs.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_kanban-definition-ZSS6B67P_mjs.bundle.js +32 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_mindmap-definition-6CBA2TL7_mjs.bundle.js +52 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_quadrantDiagram-2OG54O6I_mjs.bundle.js +22 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_requirementDiagram-QOLK2EJ7_mjs.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_sankeyDiagram-4UZDY2LN_mjs.bundle.js +162 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_sequenceDiagram-SKLFT4DO_mjs.bundle.js +42 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_stateDiagram-MI5ZYTHO_mjs.bundle.js +22 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_timeline-definition-MYPXXCX6_mjs.bundle.js +22 -0
- package/dist/frontend/vendors-node_modules_mermaid_dist_chunks_mermaid_core_xychartDiagram-H2YORKM3_mjs.bundle.js +22 -0
- package/dist/server/routes/filetree.js +8 -8
- package/dist/server/routes/outline.js +23 -22
- package/dist/server/server.js +8 -73
- package/dist/server/watcher.js +136 -0
- package/dist/utils/logger.js +12 -0
- package/package.json +4 -3
package/dist/cli.js
CHANGED
|
@@ -8,6 +8,7 @@ const commander_1 = require("commander");
|
|
|
8
8
|
const fs_1 = require("fs");
|
|
9
9
|
const path_1 = __importDefault(require("path"));
|
|
10
10
|
const server_1 = require("./server/server");
|
|
11
|
+
const logger_1 = require("./utils/logger");
|
|
11
12
|
const DEFAULT_PORT = 8521;
|
|
12
13
|
const DEFAULT_DIRECTORY = '.';
|
|
13
14
|
class CLI {
|
|
@@ -15,7 +16,10 @@ class CLI {
|
|
|
15
16
|
return this.requireOpen()
|
|
16
17
|
.then((open) => {
|
|
17
18
|
const program = new commander_1.Command();
|
|
19
|
+
const packageJsonPath = path_1.default.join(__dirname, '..', 'package.json');
|
|
20
|
+
const packageJson = JSON.parse((0, fs_1.readFileSync)(packageJsonPath, 'utf8'));
|
|
18
21
|
program
|
|
22
|
+
.version(packageJson.version)
|
|
19
23
|
.option('-p, --port <port>', 'Port to serve on', String(DEFAULT_PORT))
|
|
20
24
|
.argument('[directory]', 'Directory to serve', DEFAULT_DIRECTORY)
|
|
21
25
|
.action((directory, options) => {
|
|
@@ -24,7 +28,7 @@ class CLI {
|
|
|
24
28
|
(0, server_1.serve)(absoluteDirectory, port);
|
|
25
29
|
const readmePath = path_1.default.join(absoluteDirectory, 'README.md');
|
|
26
30
|
const initialPath = (0, fs_1.existsSync)(readmePath) ? '/README.md' : '';
|
|
27
|
-
|
|
31
|
+
logger_1.logger.log(`🌐 Opening browser at http://localhost:${port}${initialPath}...`);
|
|
28
32
|
open(`http://localhost:${port}${initialPath}`);
|
|
29
33
|
});
|
|
30
34
|
program.parse(process.argv);
|