visualifyjs 2.5.3-2.dev → 2.5.3-9-dev

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of visualifyjs might be problematic. Click here for more details.

Files changed (139) hide show
  1. package/.github/workflows/{static.yml.bak → build.yaml} +51 -51
  2. package/LICENSE +674 -674
  3. package/README.md +40 -58
  4. package/config-overrides.js +31 -31
  5. package/dist/visualify.js +3 -3
  6. package/docs/CLI.md +15 -0
  7. package/docs/{docs/README.md → README.md} +41 -65
  8. package/docs/{docs/Rechart → Rechart}/bar.md +190 -190
  9. package/docs/{docs/Rechart → Rechart}/funnel.md +193 -241
  10. package/docs/{docs/Rechart → Rechart}/line.md +355 -355
  11. package/docs/{docs/Rechart → Rechart}/pie.md +225 -225
  12. package/docs/{docs/Rechart → Rechart}/radar.md +253 -253
  13. package/docs/{docs/_404.md → _404.md} +51 -51
  14. package/docs/{docs/_coverpage.md → _coverpage.md} +11 -11
  15. package/docs/{docs/_sidebar.md → _sidebar.md} +42 -44
  16. package/docs/{docs/components → components}/dotBio.md +34 -34
  17. package/docs/{docs/components → components}/echart.md +82 -82
  18. package/docs/{docs/components → components}/html.md +34 -34
  19. package/docs/{docs/components → components}/macaron.md +145 -145
  20. package/docs/components/markdown.md +0 -0
  21. package/docs/{docs/components → components}/more.md +142 -142
  22. package/docs/{docs/components → components}/plotly.md +62 -62
  23. package/docs/{docs/components → components}/scatterL.md +70 -70
  24. package/docs/{docs/components → components}/visium.md +56 -56
  25. package/docs/{docs/configuration.md → configuration.md} +123 -121
  26. package/docs/{docs/deploy.md → deploy.md} +23 -31
  27. package/docs/index.html +70 -70
  28. package/docs/log.md +1 -0
  29. package/docs/manifest.json +23 -23
  30. package/docs/{docs/more-pages.md → more-pages.md} +23 -23
  31. package/docs/{docs/quickstart.md → quickstart.md} +115 -124
  32. package/docs/{docs/rechart-attributes.md → rechart-attributes.md} +74 -74
  33. package/docs/{docs/rechart-basic-usage.md → rechart-basic-usage.md} +162 -162
  34. package/docs/static/css/fluff-stuff.css +169 -169
  35. package/docs/static/css/font-awesome.min.css +4 -4
  36. package/docs/static/css/visualify.css +25 -25
  37. package/docs/static/js/configuration.js +448 -448
  38. package/docs/static/js/visualify.js +24 -23
  39. package/docs/theme.md +3 -0
  40. package/package.json +74 -83
  41. package/rollup.config.mjs +75 -75
  42. package/src/_css/404.css +115 -115
  43. package/src/_css/App.css +37 -37
  44. package/src/_css/autoSuggestion.css +26 -26
  45. package/src/_css/circular-progress.css +32 -32
  46. package/src/_css/index.css +36 -36
  47. package/src/_css/modern.css +24 -24
  48. package/src/_media/corner.svg +8 -8
  49. package/src/_media/download.svg +3 -3
  50. package/src/_media/logo.svg +14 -14
  51. package/src/_test/App.test.js +15 -15
  52. package/src/_utils/reportWebVitals.js +13 -13
  53. package/src/core/appContext.js +27 -27
  54. package/src/core/components/Scatter.js +188 -188
  55. package/src/core/components/ScatterBio.js +572 -572
  56. package/src/core/components/VisiumPlot.js +165 -165
  57. package/src/core/components/browser.js +42 -42
  58. package/src/core/components/dotplot.js +413 -413
  59. package/src/core/components/html.js +29 -29
  60. package/src/core/components/list.js +178 -178
  61. package/src/core/components/macaron.js +201 -201
  62. package/src/core/components/markdown.js +56 -56
  63. package/src/core/components/parser.scatterBio.js +579 -587
  64. package/src/core/components/ratio.js +80 -80
  65. package/src/core/components/scatterL.js +173 -173
  66. package/src/core/components/searchbar.js +131 -131
  67. package/src/core/components/selection.js +193 -193
  68. package/src/core/components/timeline.js +281 -281
  69. package/src/core/components/visium.js +97 -97
  70. package/src/core/fetch/condfetch.js +82 -82
  71. package/src/core/fetch/fetch.js +92 -92
  72. package/src/core/fetch/json.js +29 -29
  73. package/src/core/fetch/vfetch.js +42 -42
  74. package/src/core/liveEditor.js +44 -44
  75. package/src/core/modules/codeEditorWithPreview.js +104 -104
  76. package/src/core/modules/echarts/common.js +20 -20
  77. package/src/core/modules/echarts/presetHandler.js +41 -41
  78. package/src/core/modules/echarts/presets/esodev.chromium.js +172 -172
  79. package/src/core/modules/echarts/presets/esodev.codex.js +130 -130
  80. package/src/core/modules/echarts/presets/esodev.visium.js +123 -123
  81. package/src/core/modules/echarts/presets/mmtrbc.js +186 -186
  82. package/src/core/modules/echarts.js +71 -71
  83. package/src/core/modules/echartsUtils.js +43 -43
  84. package/src/core/modules/echartswitcher.js +152 -152
  85. package/src/core/modules/replotly/presetHandler.js +24 -24
  86. package/src/core/modules/replotly/presets/minimum.js +18 -18
  87. package/src/core/modules/replotly/presets/mmtrbc.dot.js +114 -114
  88. package/src/core/modules/replotly/presets/mmtrbc.violin.js +100 -100
  89. package/src/core/modules/replotly.js +71 -71
  90. package/src/core/pages/404.js +50 -50
  91. package/src/core/pages/error.js +27 -27
  92. package/src/core/pages/jsonPage.js +62 -62
  93. package/src/core/pages/loading.js +44 -44
  94. package/src/core/parser/echart.data.js +183 -183
  95. package/src/core/parser/echart.features.js +125 -125
  96. package/src/core/parser/echart.general.js +143 -147
  97. package/src/core/parser/echart.hilbert.js +57 -57
  98. package/src/core/parser/echart.parser.js +210 -210
  99. package/src/core/parser/echart.series.js +67 -67
  100. package/src/core/parser/echart.types.js +76 -76
  101. package/src/core/parser/plotly.config.js +10 -10
  102. package/src/core/parser/plotly.data.js +132 -132
  103. package/src/core/parser/plotly.layout.js +9 -9
  104. package/src/core/parser/plotly.violin.js +18 -18
  105. package/src/core/recharts.js +62 -62
  106. package/src/core/router/alias.js +49 -49
  107. package/src/core/router/jsonRouter.js +31 -31
  108. package/src/core/themes/modern.js +32 -32
  109. package/src/core/themes/themeSelector.js +33 -33
  110. package/src/core/visualify.js +47 -47
  111. package/src/core/widgets/circularProgress.js +23 -23
  112. package/src/core/widgets/controller.js +83 -83
  113. package/src/core/widgets/errorBoundary.js +36 -36
  114. package/src/core/widgets/footer.js +177 -177
  115. package/src/core/widgets/header.js +234 -234
  116. package/src/core/widgets/layout/Grid.js +31 -31
  117. package/src/core/widgets/layout.js +36 -36
  118. package/src/core/widgets/mapping.js +42 -42
  119. package/src/index.js +62 -62
  120. package/src/setupTests.js +5 -5
  121. package/docs/docs/CLI.md +0 -34
  122. package/docs/docs/Rechart/scatter.md +0 -298
  123. package/docs/docs/log.md +0 -9
  124. package/docs/docs/static/logo/favicon.ico +0 -0
  125. package/docs/docs/static/logo/logo_128x128.png +0 -0
  126. package/docs/docs/static/logo/logo_192x192.png +0 -0
  127. package/docs/docs/static/logo/logo_256x256.png +0 -0
  128. package/docs/docs/static/logo/logo_512x512.png +0 -0
  129. package/docs/docs/static/logo/logo_64x64.png +0 -0
  130. package/docs/docs/theme.md +0 -5
  131. /package/docs/{docs/Rechart → Rechart}/geo.md +0 -0
  132. /package/docs/{docs/Rechart → Rechart}/liquidfill.md +0 -0
  133. /package/docs/{docs/Rechart → Rechart}/polar.md +0 -0
  134. /package/docs/{docs/Rechart → Rechart}/sankey.md +0 -0
  135. /package/docs/{docs/Rechart/sunburst.md → Rechart/scatter.md} +0 -0
  136. /package/docs/{docs/Rechart/tree.md → Rechart/sunburst.md} +0 -0
  137. /package/docs/{docs/Rechart/wordcloud.md → Rechart/tree.md} +0 -0
  138. /package/docs/{docs/components/markdown.md → Rechart/wordcloud.md} +0 -0
  139. /package/docs/{docs/static → static}/_images/deploy-github-pages.png +0 -0
@@ -1,31 +1,23 @@
1
- # Deploy
2
-
3
- ## On Your Local Machine
4
-
5
- You can deploy Visualify on your local machine by running a simple HTTP server.
6
- For example, you can use the `http-server` package from npm:
7
-
8
- ```bash
9
- npm install -g http-server
10
- http-server ./docs
11
- ```
12
-
13
- Then open your browser and navigate to `http://localhost:8080`.
14
-
15
- ## On GitHub Pages
16
-
17
- There are three places to populate your docs for your GitHub repository:
18
-
19
- - `docs/` folder
20
- - main branch
21
- - gh-pages branch
22
-
23
- It is recommended that you save your files to the `./docs` subfolder of the
24
- `main` branch of your repository. Then select `main branch /docs folder` as your
25
- GitHub Pages source in your repository's settings page.
26
-
27
- ![GitHub Pages](./static/_images/deploy-github-pages.png)
28
-
29
- !> You can also save files in the root directory and select `main branch`.
30
- You'll need to place a `.nojekyll` file in the deploy location (such as `/docs`
31
- or the gh-pages branch)
1
+ # Deploy
2
+
3
+ ## On Your Local Machine
4
+
5
+
6
+
7
+ ## GitHub Pages
8
+
9
+ There are three places to populate your docs for your GitHub repository:
10
+
11
+ - `docs/` folder
12
+ - main branch
13
+ - gh-pages branch
14
+
15
+ It is recommended that you save your files to the `./docs` subfolder of the
16
+ `main` branch of your repository. Then select `main branch /docs folder` as your
17
+ GitHub Pages source in your repository's settings page.
18
+
19
+ ![GitHub Pages](./static/_images/deploy-github-pages.png)
20
+
21
+ !> You can also save files in the root directory and select `main branch`.
22
+ You'll need to place a `.nojekyll` file in the deploy location (such as `/docs`
23
+ or the gh-pages branch)
package/docs/index.html CHANGED
@@ -1,71 +1,71 @@
1
- <!DOCTYPE html>
2
- <html lang="en">
3
-
4
- <head>
5
- <meta charset="UTF-8" />
6
- <title>visualify.js official site</title>
7
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
8
- <meta name="description" content="Description" />
9
- <meta name="viewport" content="width=device-width, initial-scale=1.0" />
10
- <link rel="shortcut icon" type="image/x-icon" href="static/logo/favicon.ico" />
11
- <script src="https://code.jquery.com/jquery-3.6.4.min.js" integrity="sha256-oP6HI9z1XaZNBrJURtCoUT5SUnxFr8s3BzRl+cbzUq8=" crossorigin="anonymous"></script>
12
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.0/css/all.css" />
13
- <link rel="stylesheet" href="./static/css/font-awesome.min.css" />
14
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/docsify/lib/themes/vue.css" />
15
- <link rel="stylesheet" href="./static/css/fluff-stuff.css" />
16
- <script src="./static/js/configuration.js"></script>
17
- <script async src="https://cpwebassets.codepen.io/assets/embed/ei.js"></script>
18
- <!-- Docsify siderbarbar -->
19
- <script src="https://cdn.jsdelivr.net/npm/marked@latest/marked.min.js"></script>
20
- </head>
21
-
22
- <body>
23
- <div id="docsify"></div>
24
- <script>
25
- // Set html "lang" attribute based on URL
26
- var lang = location.hash.match(/#\/(zh-cn)\//);
27
- if (lang) {
28
- document.documentElement.setAttribute("lang", lang[1]);
29
- }
30
-
31
- window.$docsify = config;
32
- $visualify = {
33
- mode: 'charts',
34
- }
35
-
36
- /*
37
- const custom_buttons = [
38
- ["MmTrBC", "./MmTrBC/", 1],
39
- ["Esodev", "./EsoDev/", 3],
40
- ];
41
- */
42
- </script>
43
- <!-- Docsify v4 -->
44
- <script src="https://cdn.jsdelivr.net/npm/docsify@4"></script>
45
- <script src="https://cdn.jsdelivr.net/npm/vue@3/dist/vue.global.prod.js"></script>
46
- <script src="./static/js/fluff.js" defer></script>
47
- <!-- Plugins -->
48
- <script src="https://polyfill.io/v3/polyfill.min.js?features=String.prototype.normalize"></script>
49
- <script src="https://cdn.jsdelivr.net/npm/docsify/lib/plugins/external-script.js"></script>
50
- <!-- Copy to Clipboard -->
51
- <script src="https://unpkg.com/docsify-copy-code@2/dist/docsify-copy-code.min.js"></script>
52
- <!-- docsify-tabs (latest v1.x.x) -->
53
- <script src="https://cdn.jsdelivr.net/npm/docsify-tabs@1/dist/docsify-tabs.min.js"></script>
54
- <!-- LaTeX display engine script Here -->
55
- <script src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
56
- <script src="https://cdn.jsdelivr.net/npm/katex@latest/dist/katex.min.js"></script>
57
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@latest/dist/katex.min.css" />
58
- <script src="https://unpkg.com/docsify-latex@0.5.2/dist/docsify-latex.min.js"></script>
59
- <!-- flexible-alerts -->
60
- <script src="https://unpkg.com/docsify-plugin-flexible-alerts@1.1.1/dist/docsify-plugin-flexible-alerts.min.js"></script>
61
- <!-- Mermaid -->
62
- <script type="module">
63
- import mermaid from "https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.esm.min.mjs"; mermaid.initialize({ startOnLoad: true }); window.mermaid = mermaid;
64
- </script>
65
- <!-- Prism -->
66
- <script src="https://cdn.jsdelivr.net/npm/prismjs@1.29.0/components/prism-python.min.js"></script>
67
- <!-- Visualify -->
68
- <script src="./static/js/visualify.js"></script>
69
- </body>
70
-
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+
4
+ <head>
5
+ <meta charset="UTF-8" />
6
+ <title>visualify.js official site</title>
7
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
8
+ <meta name="description" content="Description" />
9
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
10
+ <link rel="shortcut icon" type="image/x-icon" href="static/logo/favicon.ico" />
11
+ <script src="https://code.jquery.com/jquery-3.6.4.min.js" integrity="sha256-oP6HI9z1XaZNBrJURtCoUT5SUnxFr8s3BzRl+cbzUq8=" crossorigin="anonymous"></script>
12
+ <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.0/css/all.css" />
13
+ <link rel="stylesheet" href="./static/css/font-awesome.min.css" />
14
+ <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/docsify/lib/themes/vue.css" />
15
+ <link rel="stylesheet" href="./static/css/fluff-stuff.css" />
16
+ <script src="./static/js/configuration.js"></script>
17
+ <script async src="https://cpwebassets.codepen.io/assets/embed/ei.js"></script>
18
+ <!-- Docsify siderbarbar -->
19
+ <script src="https://cdn.jsdelivr.net/npm/marked@latest/marked.min.js"></script>
20
+ </head>
21
+
22
+ <body>
23
+ <div id="docsify"></div>
24
+ <script>
25
+ // Set html "lang" attribute based on URL
26
+ var lang = location.hash.match(/#\/(zh-cn)\//);
27
+ if (lang) {
28
+ document.documentElement.setAttribute("lang", lang[1]);
29
+ }
30
+
31
+ window.$docsify = config;
32
+ $visualify = {
33
+ mode: 'charts',
34
+ }
35
+
36
+ /*
37
+ const custom_buttons = [
38
+ ["MmTrBC", "./MmTrBC/", 1],
39
+ ["Esodev", "./EsoDev/", 3],
40
+ ];
41
+ */
42
+ </script>
43
+ <!-- Docsify v4 -->
44
+ <script src="https://cdn.jsdelivr.net/npm/docsify@4"></script>
45
+ <script src="https://cdn.jsdelivr.net/npm/vue@3/dist/vue.global.prod.js"></script>
46
+ <script src="./static/js/fluff.js" defer></script>
47
+ <!-- Plugins -->
48
+ <script src="https://polyfill.io/v3/polyfill.min.js?features=String.prototype.normalize"></script>
49
+ <script src="https://cdn.jsdelivr.net/npm/docsify/lib/plugins/external-script.js"></script>
50
+ <!-- Copy to Clipboard -->
51
+ <script src="https://unpkg.com/docsify-copy-code@2/dist/docsify-copy-code.min.js"></script>
52
+ <!-- docsify-tabs (latest v1.x.x) -->
53
+ <script src="https://cdn.jsdelivr.net/npm/docsify-tabs@1/dist/docsify-tabs.min.js"></script>
54
+ <!-- LaTeX display engine script Here -->
55
+ <script src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
56
+ <script src="https://cdn.jsdelivr.net/npm/katex@latest/dist/katex.min.js"></script>
57
+ <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@latest/dist/katex.min.css" />
58
+ <script src="https://unpkg.com/docsify-latex@0.5.2/dist/docsify-latex.min.js"></script>
59
+ <!-- flexible-alerts -->
60
+ <script src="https://unpkg.com/docsify-plugin-flexible-alerts@1.1.1/dist/docsify-plugin-flexible-alerts.min.js"></script>
61
+ <!-- Mermaid -->
62
+ <script type="module">
63
+ import mermaid from "https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.esm.min.mjs"; mermaid.initialize({ startOnLoad: true }); window.mermaid = mermaid;
64
+ </script>
65
+ <!-- Prism -->
66
+ <script src="https://cdn.jsdelivr.net/npm/prismjs@1.29.0/components/prism-python.min.js"></script>
67
+ <!-- Visualify -->
68
+ <script src="./static/js/visualify.js"></script>
69
+ </body>
70
+
71
71
  </html>
package/docs/log.md ADDED
@@ -0,0 +1 @@
1
+ # log
@@ -1,24 +1,24 @@
1
- {
2
- "short_name": "visualifyjs",
3
- "name": "Create Your Data Portal Simple",
4
- "icons": [{
5
- "src": "https://lgcyaxi.net/visualify/static/logo/favicon.ico",
6
- "sizes": "64x64 32x32 24x24 16x16",
7
- "type": "image/x-icon"
8
- },
9
- {
10
- "src": "https://lgcyaxi.net/visualify/static/logo/logo192.png",
11
- "type": "image/png",
12
- "sizes": "192x192"
13
- },
14
- {
15
- "src": "https://lgcyaxi.net/visualify/static/logo/logo512.png",
16
- "type": "image/png",
17
- "sizes": "512x512"
18
- }
19
- ],
20
- "start_url": ".",
21
- "display": "standalone",
22
- "theme_color": "#000000",
23
- "background_color": "#ffffff"
1
+ {
2
+ "short_name": "visualifyjs",
3
+ "name": "Create Your Data Portal Simple",
4
+ "icons": [{
5
+ "src": "https://lgcyaxi.net/visualify/static/logo/favicon.ico",
6
+ "sizes": "64x64 32x32 24x24 16x16",
7
+ "type": "image/x-icon"
8
+ },
9
+ {
10
+ "src": "https://lgcyaxi.net/visualify/static/logo/logo192.png",
11
+ "type": "image/png",
12
+ "sizes": "192x192"
13
+ },
14
+ {
15
+ "src": "https://lgcyaxi.net/visualify/static/logo/logo512.png",
16
+ "type": "image/png",
17
+ "sizes": "512x512"
18
+ }
19
+ ],
20
+ "start_url": ".",
21
+ "display": "standalone",
22
+ "theme_color": "#000000",
23
+ "background_color": "#ffffff"
24
24
  }
@@ -1,23 +1,23 @@
1
- # More pages
2
-
3
- If you need more pages, you can simply create more `json` configuration files in
4
- your visualify directory. If you create a file named `scatter`, then it is
5
- accessible via `/scatter`.
6
-
7
- For example, the directory structure is as follows:
8
-
9
- ```text
10
- .
11
- └── docs
12
- ├── index.html
13
- ├── scatter.json
14
- └── honme.json
15
- ```
16
-
17
- Matching routes
18
-
19
- ```text
20
- docs/home.json => http://domain.com
21
- => http://domain.com/home
22
- docs/scatter.json => http://domain.com/scatter
23
- ```
1
+ # More pages
2
+
3
+ If you need more pages, you can simply create more `json` configuration files in
4
+ your visualify directory. If you create a file named `scatter`, then it is
5
+ accessible via `/scatter`.
6
+
7
+ For example, the directory structure is as follows:
8
+
9
+ ```text
10
+ .
11
+ └── docs
12
+ ├── index.html
13
+ ├── scatter.json
14
+ └── honme.json
15
+ ```
16
+
17
+ Matching routes
18
+
19
+ ```text
20
+ docs/home.json => http://domain.com
21
+ => http://domain.com/home
22
+ docs/scatter.json => http://domain.com/scatter
23
+ ```
@@ -1,124 +1,115 @@
1
- # Quick start
2
-
3
- It is highly recommended to use `Docisfy` as a document framework and imports
4
- `visualify` to quickly present various diagrams.
5
-
6
- Insert the `visualify` script in your `index.html` file.
7
-
8
- ```html
9
- <head>
10
- ...
11
- <script src="https://cdn.jsdelivr.net/npm/visualifyjs"></script>
12
-
13
- <!-- or -->
14
- <!-- <script src="https://visualify.pharmacy.arizona.edu/dist/visualify.js"></script -->
15
- <!-- or -->
16
- <!-- script src="https://cdn.jsdelivr.net/gh/visualify/visualify.js@release/dist/visualify.js"></script> -->
17
- </head>
18
- ```
19
-
20
- Or install `visualify.cli` globally, which helps initializing and previewing the
21
- website locally.
22
-
23
- ```bash
24
- npm i visualify.cli -g
25
- ```
26
-
27
- ## Initialize
28
-
29
- If you want to write the documentation in the `./docs` subdirectory, you can use
30
- the `init` command.
31
-
32
- ```bash
33
- visualify init ./docs
34
- ```
35
-
36
- or simply run `visualify init`
37
-
38
- ```bash
39
- visualify init
40
- ```
41
-
42
- or anywhere you like.
43
-
44
- ```bash
45
- visualify init <path>
46
- ```
47
-
48
- ## Writing content
49
-
50
- After the `init` is complete, you can see the file list in the `./docs`
51
- subdirectory.
52
-
53
- - `index.html` as the entry file
54
- - `home.jsom` as the home page
55
- - `.nojekyll` prevents GitHub Pages from ignoring files that begin with an
56
- underscore
57
-
58
- You can easily update the documentation in `./docs/home.json`, of course you can
59
- add [more pages](more-pages.md).
60
-
61
- ## Preview your site
62
-
63
- Run the local server with `visualify serve <docs-path>`. You can preview your
64
- site in your browser on `http://localhost:3000`.
65
-
66
- ```bash
67
- visualify serve docs
68
- ```
69
-
70
- ?> For more use cases of `visualify.cli`, head over to the
71
- [CLI documentation](CLI.md).
72
-
73
- ## Manual initialization
74
-
75
- If you don't like `npm` or have trouble installing the tool, you can manually
76
- create `index.html`:
77
-
78
- ```html
79
- <!-- index.html -->
80
-
81
- <!DOCTYPE html>
82
- <html>
83
- <head>
84
- <meta name="viewport" content="width=device-width,initial-scale=1" />
85
- <meta charset="UTF-8" />
86
- </head>
87
- <body>
88
- <div id="root"></div>
89
- <script>
90
- $visualify = {
91
- //...
92
- };
93
- </script>
94
- <script src="https://cdn.jsdelivr.net/npm/visualifyjs"></script>
95
- <!-- or -->
96
- <!-- <script src="https://visualify.pharmacy.arizona.edu/dist/visualify.js"></script> -->
97
- <!-- or -->
98
- <!-- script src="https://cdn.jsdelivr.net/gh/visualify/visualify.js@release/dist/visualify.js"></script> -->
99
- </body>
100
- </html>
101
-
102
- ```
103
-
104
- ### Manually preview your site
105
-
106
- If you have `Node.js` installed on your system, you can easily use it to run a
107
- static server to preview your site.
108
-
109
- ```bash
110
- # install corresponding dependencies
111
- npm install -g serve
112
- serve -s ./docs
113
- ```
114
-
115
- If you have Python installed on your system, you can easily use it to run a
116
- static server to preview your site.
117
-
118
- ```python2
119
- cd docs && python -m SimpleHTTPServer 3000
120
- ```
121
-
122
- ```python3
123
- cd docs && python -m http.server 3000
124
- ```
1
+ # Quick start
2
+
3
+ It is highly recommended to use `Docisfy` as a document framework and imports
4
+ `visualify` to quickly present various diagrams.
5
+
6
+ Insert the `visualify` script in your `index.html` file.
7
+
8
+ ```html
9
+ <head>
10
+ ...
11
+ <script src="https://visualify.pharmacy.arizona.edu/dist/visualify.js"></script>
12
+ </head>
13
+ ```
14
+
15
+ Or install `visualify.cli` globally, which helps initializing and previewing the
16
+ website locally.
17
+
18
+ ```bash
19
+ npm i visualify.cli -g
20
+ ```
21
+
22
+ ## Initialize
23
+
24
+ If you want to write the documentation in the `./docs` subdirectory, you can use
25
+ the `init` command.
26
+
27
+ ```bash
28
+ visualify init ./docs
29
+ ```
30
+
31
+ or simply run `visualify init`
32
+
33
+ ```bash
34
+ visualify init
35
+ ```
36
+
37
+ or anywhere you like.
38
+
39
+ ```bash
40
+ visualify init <path>
41
+ ```
42
+
43
+ ## Writing content
44
+
45
+ After the `init` is complete, you can see the file list in the `./docs`
46
+ subdirectory.
47
+
48
+ - `index.html` as the entry file
49
+ - `home.jsom` as the home page
50
+ - `.nojekyll` prevents GitHub Pages from ignoring files that begin with an
51
+ underscore
52
+
53
+ You can easily update the documentation in `./docs/home.json`, of course you can
54
+ add [more pages](more-pages.md).
55
+
56
+ ## Preview your site
57
+
58
+ Run the local server with `visualify serve <docs-path>`. You can preview your
59
+ site in your browser on `http://localhost:3000`.
60
+
61
+ ```bash
62
+ visualify serve docs
63
+ ```
64
+
65
+ ?> For more use cases of `visualify.cli`, head over to the
66
+ [CLI documentation](CLI.md).
67
+
68
+ ## Manual initialization
69
+
70
+ If you don't like `npm` or have trouble installing the tool, you can manually
71
+ create `index.html`:
72
+
73
+ ```html
74
+ <!-- index.html -->
75
+
76
+ <!DOCTYPE html>
77
+ <html>
78
+ <head>
79
+ <meta name="viewport" content="width=device-width,initial-scale=1" />
80
+ <meta charset="UTF-8" />
81
+ </head>
82
+ <body>
83
+ <div id="root"></div>
84
+ <script>
85
+ $visualify = {
86
+ //...
87
+ };
88
+ </script>
89
+ <script src="https://visualify.pharmacy.arizona.edu/dist/visualify.js"></script>
90
+ </body>
91
+ </html>
92
+
93
+ ```
94
+
95
+ ### Manually preview your site
96
+
97
+ If you have `Node.js` installed on your system, you can easily use it to run a
98
+ static server to preview your site.
99
+
100
+ ```bash
101
+ # install corresponding dependencies
102
+ npm install -g serve
103
+ serve -s ./docs
104
+ ```
105
+
106
+ If you have Python installed on your system, you can easily use it to run a
107
+ static server to preview your site.
108
+
109
+ ```python2
110
+ cd docs && python -m SimpleHTTPServer 3000
111
+ ```
112
+
113
+ ```python3
114
+ cd docs && python -m http.server 3000
115
+ ```