add back dist
This commit is contained in:
parent
69ee6e881f
commit
7a86c8029a
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,2 +1 @@
|
|||||||
node_modules/
|
node_modules/
|
||||||
dist/
|
|
0
dist/.nojekyll
vendored
Normal file
0
dist/.nojekyll
vendored
Normal file
BIN
dist/favicon.ico
vendored
Normal file
BIN
dist/favicon.ico
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 24 KiB |
BIN
dist/icon-192.png
vendored
Normal file
BIN
dist/icon-192.png
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 9.4 KiB |
BIN
dist/icon-512.png
vendored
Normal file
BIN
dist/icon-512.png
vendored
Normal file
Binary file not shown.
After Width: | Height: | Size: 26 KiB |
49
dist/index.html
vendored
Normal file
49
dist/index.html
vendored
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8" />
|
||||||
|
<link rel="icon" href="favicon.ico" />
|
||||||
|
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
|
<meta name="theme-color" content="#000000" />
|
||||||
|
|
||||||
|
<meta property="og:title" content="CAD Tool" />
|
||||||
|
<meta property="og:description" content="Three.js CAD tool" />
|
||||||
|
<meta property="og:url" content="" />
|
||||||
|
<meta property="og:image" content="" />
|
||||||
|
|
||||||
|
<link rel="apple-touch-icon" href="icon-192.png" />
|
||||||
|
<link rel="manifest" href="manifest.json" />
|
||||||
|
<title>CAD Tool</title>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
html,
|
||||||
|
body {
|
||||||
|
margin: 0;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
#c {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
#react {
|
||||||
|
position: absolute;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<div id="react"></div>
|
||||||
|
<canvas id="c"></canvas>
|
||||||
|
|
||||||
|
<script src="bundle.js" type="module"></script>
|
||||||
|
<script src="solver.js"></script>
|
||||||
|
<div id="stats"></div>
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
27
dist/manifest.json
vendored
Normal file
27
dist/manifest.json
vendored
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
{
|
||||||
|
"short_name": "CAD Tool",
|
||||||
|
"name": "CAD Tool using Three.js",
|
||||||
|
"icons": [
|
||||||
|
{
|
||||||
|
"src": "favicon.ico",
|
||||||
|
"sizes": "64x64 32x32 24x24 16x16",
|
||||||
|
"type": "image/x-icon"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"src": "icon-192.png",
|
||||||
|
"type": "image/png",
|
||||||
|
"sizes": "192x192",
|
||||||
|
"purpose": "maskable any"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"src": "icon-512.png",
|
||||||
|
"type": "image/png",
|
||||||
|
"sizes": "512x512",
|
||||||
|
"purpose": "maskable any"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"start_url": ".",
|
||||||
|
"display": "standalone",
|
||||||
|
"theme_color": "#000000",
|
||||||
|
"background_color": "#ffffff"
|
||||||
|
}
|
3
dist/robots.txt
vendored
Normal file
3
dist/robots.txt
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
# https://www.robotstxt.org/robotstxt.html
|
||||||
|
User-agent: *
|
||||||
|
Disallow:
|
2460
dist/solver.js
vendored
Normal file
2460
dist/solver.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
dist/solver.wasm
vendored
Executable file
BIN
dist/solver.wasm
vendored
Executable file
Binary file not shown.
7580
package-lock.json
generated
7580
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "webpack --watch --config webpack.dev.js",
|
"start": "webpack serve --config webpack.dev.js",
|
||||||
"build": "webpack --config webpack.prod.js",
|
"build": "webpack --config webpack.prod.js",
|
||||||
"get-bundle-size": "webpack --profile --json > stats.json --config webpack.prod.js && webpack-bundle-analyzer stats.json dist/",
|
"get-bundle-size": "webpack --profile --json > stats.json --config webpack.prod.js && webpack-bundle-analyzer stats.json dist/",
|
||||||
"deploy": "gh-pages -d dist -t true"
|
"deploy": "gh-pages -d dist -t true"
|
||||||
@ -22,6 +22,7 @@
|
|||||||
"webpack": "^5.26.3",
|
"webpack": "^5.26.3",
|
||||||
"webpack-bundle-analyzer": "^4.4.0",
|
"webpack-bundle-analyzer": "^4.4.0",
|
||||||
"webpack-cli": "^4.5.0",
|
"webpack-cli": "^4.5.0",
|
||||||
|
"webpack-dev-server": "^3.11.2",
|
||||||
"webpack-merge": "^5.7.3"
|
"webpack-merge": "^5.7.3"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
14
src/app.jsx
14
src/app.jsx
@ -2,10 +2,18 @@
|
|||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { Provider } from 'react-redux';
|
import { Provider } from 'react-redux';
|
||||||
|
import './app.scss'
|
||||||
|
|
||||||
|
export const Root = ({ store }) => (
|
||||||
export const App = ({ store }) => (
|
|
||||||
<Provider store={store}>
|
<Provider store={store}>
|
||||||
<div>hellodddddd</div>
|
<App></App>
|
||||||
</Provider>
|
</Provider>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
const App = () => {
|
||||||
|
|
||||||
|
return <>
|
||||||
|
<div>in the world where</div>
|
||||||
|
</>
|
||||||
|
}
|
5
src/app.scss
Normal file
5
src/app.scss
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
div {
|
||||||
|
color: red;
|
||||||
|
position: absolute;
|
||||||
|
right:0;
|
||||||
|
}
|
20
src/index.js
20
src/index.js
@ -10,10 +10,9 @@ import React from 'react';
|
|||||||
import ReactDOM from 'react-dom';
|
import ReactDOM from 'react-dom';
|
||||||
import { createStore, applyMiddleware } from 'redux'
|
import { createStore, applyMiddleware } from 'redux'
|
||||||
|
|
||||||
import { App } from './app.jsx'
|
import { Root } from './app.jsx'
|
||||||
|
|
||||||
function main(store) {
|
function main(store) {
|
||||||
|
|
||||||
var stats = new Stats();
|
var stats = new Stats();
|
||||||
stats.showPanel(0); // 0: fps, 1: ms, 2: mb, 3+: custom
|
stats.showPanel(0); // 0: fps, 1: ms, 2: mb, 3+: custom
|
||||||
document.getElementById('stats').appendChild(stats.dom);
|
document.getElementById('stats').appendChild(stats.dom);
|
||||||
@ -22,6 +21,7 @@ function main(store) {
|
|||||||
const renderer = new THREE.WebGLRenderer({ canvas });
|
const renderer = new THREE.WebGLRenderer({ canvas });
|
||||||
|
|
||||||
const scene = new THREE.Scene();
|
const scene = new THREE.Scene();
|
||||||
|
window.scene = scene;
|
||||||
scene.background = new THREE.Color(0xb0b0b0);
|
scene.background = new THREE.Color(0xb0b0b0);
|
||||||
|
|
||||||
const helpersGroup = new THREE.Group();
|
const helpersGroup = new THREE.Group();
|
||||||
@ -112,15 +112,15 @@ console.log(store.getState())
|
|||||||
|
|
||||||
|
|
||||||
// main(store);
|
// main(store);
|
||||||
main();
|
main(store);
|
||||||
|
|
||||||
|
|
||||||
// document.addEventListener('DOMContentLoaded', () => {
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
|
|
||||||
// const root = document.getElementById('react');
|
const root = document.getElementById('react');
|
||||||
// ReactDOM.render(
|
ReactDOM.render(
|
||||||
// React.createElement(App, { store: store }, null)
|
React.createElement(Root, { store: store }, null)
|
||||||
// , root
|
, root
|
||||||
// );
|
);
|
||||||
|
|
||||||
// });
|
});
|
@ -25,7 +25,8 @@ var TrackballControls = function ( object, domElement ) {
|
|||||||
|
|
||||||
this.rotateSpeed = 3.0;
|
this.rotateSpeed = 3.0;
|
||||||
this.zoomSpeed = 1.2;
|
this.zoomSpeed = 1.2;
|
||||||
this.panSpeed = 89.5;
|
// this.panSpeed = 89.5;
|
||||||
|
this.panSpeed = 70;
|
||||||
|
|
||||||
this.noRotate = false;
|
this.noRotate = false;
|
||||||
this.noZoom = false;
|
this.noZoom = false;
|
||||||
|
@ -1,12 +1,16 @@
|
|||||||
const { merge } = require('webpack-merge');
|
const { merge } = require('webpack-merge');
|
||||||
|
|
||||||
const common = require('./webpack.common.js');
|
const common = require('./webpack.common.js');
|
||||||
|
const path = require('path');
|
||||||
|
|
||||||
module.exports = merge(common, {
|
module.exports = merge(common, {
|
||||||
|
|
||||||
mode: 'development',
|
mode: 'development',
|
||||||
|
|
||||||
devtool: 'inline-source-map',
|
devtool: 'inline-source-map',
|
||||||
|
devServer: {
|
||||||
});
|
contentBase: path.join(__dirname, 'dist'),
|
||||||
|
compress: true,
|
||||||
|
port: 9000,
|
||||||
|
},
|
||||||
|
})
|
Loading…
Reference in New Issue
Block a user