Update documentation.

This commit is contained in:
Viktor Kovacs 2023-01-11 08:53:46 +01:00
parent 7ee990fb3c
commit 9fd7354317
22 changed files with 67 additions and 33 deletions

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -6,7 +6,7 @@
<meta name="viewport" content="width=device-width, user-scalable=no">
<link rel="icon" type="image/png" href="static/3dviewer_net_favicon.ico">
<title>Online 3D Viewer - Set Up Environment</title>
<title>Online 3D Viewer - Development Environment</title>
<link rel="stylesheet" href="static/highlightjs/styles/github.min.css"/>
<script src="static/highlightjs/highlight.min.js"></script>
@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>
@ -57,7 +57,7 @@
</div>
<div id="main" class="main">
<div class="page">
<h1>Set Up the Development Environment</h1>
<h1>Development Environment</h1>
<p>This document helps you setting up the developer environment. It is useful if you would like to contribute to the codebase of the engine or the website.</p>
@ -70,6 +70,15 @@ npm start</code></pre>
<p>This will compile the development version of the code and start a web server. Now you can open <code class="inline">http://localhost:8080</code> to check the result.</p>
<h2>Environments</h2>
<p>The solution is implemented as ES6 modules. It means that it must be bundled together to one file to make it usable on the website. The development and production environment is separated, see the Scripts section for more details.</p>
<ul>
<li><b>Development: </b> The development bundle will be created in the <code class="inline">build</code> folder. The code of the website references this directly during development, so you can just open the <code class="inline">website</code> folder and try it out.</li>
<li><b>Production: </b> The entire self-containing package will be created in the <code class="inline">build</code> folder. In this case all the required files are copied to this folder so you can just upload it to any web server to make it work.</li>
</ul>
<h2>Source Structure</h2>
<p>The source contains the following folders.</p>
@ -118,9 +127,17 @@ npm start</code></pre>
<li><code class="inline">npm run create_dist</code>: Generates the production version of the engine and the website, and runs all the possible checks.</li>
</ul>
<p><b>Tools</b></p>
<ul>
<li><code class="inline">npm run generate_docs</code>: Generates this documentation.</li>
<li><code class="inline">npm run generate_icon_font</code>: Generates the icon font used on the website.</li>
<li><code class="inline">npm run update_libs</code>: Updates the used external libraries.</li>
</ul>
</div>
</div>
<script type="text/javascript">Init ('Set Up Environment')</script>
<script type="text/javascript">Init ('Development Environment')</script>
</body>
</html>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>

View File

@ -30,7 +30,7 @@
</div>
<div class="navigation_section">
<div class="navigation_title">Contribution</div>
<div id="nav-Set Up Environment" class="navigation_item"><a href="SetUpEnvironment.html" target="_self">Set Up Environment</a></div>
<div id="nav-Development Environment" class="navigation_item"><a href="DevelopmentEnvironment.html" target="_self">Development Environment</a></div>
</div>
<div class="navigation_section">
<div class="navigation_title">Classes</div>
@ -80,7 +80,7 @@
<p>If you would like to contribute to the codebase, these documents help you to start.</p>
<ul>
<li><a href="SetUpEnvironment.html">Set Up Environment</a> - Helps you understanding how the environment works.</li>
<li><a href="DevelopmentEnvironment.html">Development Environment</a> - Helps you understanding how the developer environment works.</li>
</ul>
</div>

View File

@ -1,4 +1,4 @@
<h1>Set Up the Development Environment</h1>
<h1>Development Environment</h1>
<p>This document helps you setting up the developer environment. It is useful if you would like to contribute to the codebase of the engine or the website.</p>
@ -11,6 +11,15 @@ npm start</code></pre>
<p>This will compile the development version of the code and start a web server. Now you can open <code class="inline">http://localhost:8080</code> to check the result.</p>
<h2>Environments</h2>
<p>The solution is implemented as ES6 modules. It means that it must be bundled together to one file to make it usable on the website. The development and production environment is separated, see the Scripts section for more details.</p>
<ul>
<li><b>Development: </b> The development bundle will be created in the <code class="inline">build</code> folder. The code of the website references this directly during development, so you can just open the <code class="inline">website</code> folder and try it out.</li>
<li><b>Production: </b> The entire self-containing package will be created in the <code class="inline">build</code> folder. In this case all the required files are copied to this folder so you can just upload it to any web server to make it work.</li>
</ul>
<h2>Source Structure</h2>
<p>The source contains the following folders.</p>
@ -58,3 +67,11 @@ npm start</code></pre>
<li><code class="inline">npm run create_package</code>: Generates the production version of the engine and the website.</li>
<li><code class="inline">npm run create_dist</code>: Generates the production version of the engine and the website, and runs all the possible checks.</li>
</ul>
<p><b>Tools</b></p>
<ul>
<li><code class="inline">npm run generate_docs</code>: Generates this documentation.</li>
<li><code class="inline">npm run generate_icon_font</code>: Generates the icon font used on the website.</li>
<li><code class="inline">npm run update_libs</code>: Updates the used external libraries.</li>
</ul>

View File

@ -30,8 +30,8 @@
"name" : "Contribution",
"pages" : [
{
"name" : "Set Up Environment",
"url" : "SetUpEnvironment.html"
"name" : "Development Environment",
"url" : "DevelopmentEnvironment.html"
}
]
}

View File

@ -21,5 +21,5 @@
<p>If you would like to contribute to the codebase, these documents help you to start.</p>
<ul>
<li><a href="SetUpEnvironment.html">Set Up Environment</a> - Helps you understanding how the environment works.</li>
<li><a href="DevelopmentEnvironment.html">Development Environment</a> - Helps you understanding how the developer environment works.</li>
</ul>

View File

@ -12,8 +12,10 @@ function Resize ()
navToggleDiv.style.display = 'block';
navDiv.style.display = 'none';
} else {
navDiv.style.width = '250px';
mainDiv.style.marginLeft = '250px';
let navWidth = '280px';
navDiv.style.width = navWidth;
mainDiv.style.marginLeft = navWidth;
navToggleDiv.style.display = 'none';
navDiv.style.display = 'block';

View File

@ -96,7 +96,6 @@ li
.navigation
{
background: #ffffff;
width: 250px;
height: 100%;
padding: 20px;
position: absolute;
@ -153,7 +152,6 @@ li
{
height: 100%;
padding: 20px;
margin-left: 300px;
box-sizing: border-box;
overflow: auto;
}

View File

@ -41,21 +41,21 @@
"test": "mocha test",
"lint": "eslint source",
"lint_fix": "eslint source --fix",
"docs": "run-python3 tools/generate_docs.py",
"update_libs": "npm install && run-python3 tools/update_libs.py",
"generate_icon_font": "run-python3 tools/generate_icon_font.py",
"update_engine_exports": "run-python3 tools/update_engine_exports.py",
"create_dist": "npm run create_package && npm run lint && npm run test",
"create_dist_test": "npm run create_package_test && npm run lint && npm run test",
"create_package": "npm run docs && npm run build_engine_prod && npm run build_engine_module && npm run build_website_prod && npm run build_css_prod && run-python3 tools/create_package.py",
"create_package_test": "npm run docs && npm run build_engine_prod && npm run build_engine_module && npm run build_website_prod && npm run build_css_prod && run-python3 tools/create_package.py test",
"create_package": "npm run generate_docs && npm run build_engine_prod && npm run build_engine_module && npm run build_website_prod && npm run build_css_prod && run-python3 tools/create_package.py",
"create_package_test": "npm run generate_docs && npm run build_engine_prod && npm run build_engine_module && npm run build_website_prod && npm run build_css_prod && run-python3 tools/create_package.py test",
"generate_docs": "run-python3 tools/generate_docs.py",
"build_css_prod": "cleancss -o build/o3dv.website.min.css website/css/*",
"build_dev": "npm run build_engine_dev && npm run build_website_dev",
"build_engine_dev": "npm run update_engine_exports && esbuild source/engine/main.js --bundle --minify --global-name=OV --sourcemap --outfile=build/o3dv.min-dev.js",
"build_engine_prod": "npm run update_engine_exports && esbuild source/engine/main.js --bundle --minify --global-name=OV --outfile=build/o3dv.min.js",
"build_engine_module": "npm run update_engine_exports && rollup --config tools/rollup.js",
"build_website_dev": "esbuild source/website/index.js --bundle --minify --global-name=OV --sourcemap --outfile=build/o3dv.website.min-dev.js",
"build_website_prod": "esbuild source/website/index.js --bundle --minify --global-name=OV --outfile=build/o3dv.website.min.js"
"build_website_prod": "esbuild source/website/index.js --bundle --minify --global-name=OV --outfile=build/o3dv.website.min.js",
"update_engine_exports": "run-python3 tools/update_engine_exports.py"
},
"devDependencies": {
"clean-css-cli": "^5.6.1",