added prod sourcemaps.
This commit is contained in:
parent
724cd79ab3
commit
cb2675bf27
@ -109,6 +109,7 @@ export class Button {
|
|||||||
this._textures.set(states.HOVER, this.drawText(this._mesh.name, this._hoverColor, this._hoverBackground));
|
this._textures.set(states.HOVER, this.drawText(this._mesh.name, this._hoverColor, this._hoverBackground));
|
||||||
this._textures.set(states.CLICK, this.drawText(this._mesh.name, this._clickColor, this._clickBackground));
|
this._textures.set(states.CLICK, this.drawText(this._mesh.name, this._clickColor, this._clickBackground));
|
||||||
mat.emissiveTexture = this._textures.get(states.NORMAL);
|
mat.emissiveTexture = this._textures.get(states.NORMAL);
|
||||||
|
mat.opacityTexture = mat.emissiveTexture;
|
||||||
mat.disableLighting = true;
|
mat.disableLighting = true;
|
||||||
return mat;
|
return mat;
|
||||||
}
|
}
|
||||||
@ -123,8 +124,9 @@ export class Button {
|
|||||||
ctx2d.font = font;
|
ctx2d.font = font;
|
||||||
ctx2d.textBaseline = 'middle';
|
ctx2d.textBaseline = 'middle';
|
||||||
ctx2d.textAlign = 'center';
|
ctx2d.textAlign = 'center';
|
||||||
|
ctx2d.roundRect(0, 0, this._width * this._density, this._height * this._density, 32);
|
||||||
ctx2d.fillStyle = background.toHexString();
|
ctx2d.fillStyle = background.toHexString();
|
||||||
ctx2d.fillRect(0, 0, this._width * this._density, this._height * this._density);
|
ctx2d.fill();
|
||||||
ctx2d.fillStyle = foreground.toHexString();
|
ctx2d.fillStyle = foreground.toHexString();
|
||||||
const lines = split(ctx2d, name, font, this._width * this._density, true);
|
const lines = split(ctx2d, name, font, this._width * this._density, true);
|
||||||
const x = this._width * this._density / 2;
|
const x = this._width * this._density / 2;
|
||||||
|
|||||||
@ -46,6 +46,7 @@ export class Handle {
|
|||||||
const texture = this.drawText(this._label, Color3.White(), Color3.Black());
|
const texture = this.drawText(this._label, Color3.White(), Color3.Black());
|
||||||
const material = new StandardMaterial('handleMaterial', scene);
|
const material = new StandardMaterial('handleMaterial', scene);
|
||||||
material.emissiveTexture = texture;
|
material.emissiveTexture = texture;
|
||||||
|
material.opacityTexture = texture;
|
||||||
material.disableLighting = true;
|
material.disableLighting = true;
|
||||||
handle.material = material;
|
handle.material = material;
|
||||||
//handle.rotate(Vector3.Up(), Math.PI);
|
//handle.rotate(Vector3.Up(), Math.PI);
|
||||||
@ -86,8 +87,9 @@ export class Handle {
|
|||||||
ctx2d.font = font;
|
ctx2d.font = font;
|
||||||
ctx2d.textBaseline = 'middle';
|
ctx2d.textBaseline = 'middle';
|
||||||
ctx2d.textAlign = 'center';
|
ctx2d.textAlign = 'center';
|
||||||
|
ctx2d.roundRect(0, 0, 512, 64, 32);
|
||||||
ctx2d.fillStyle = background.toHexString();
|
ctx2d.fillStyle = background.toHexString();
|
||||||
ctx2d.fillRect(0, 0, 512, 64);
|
ctx2d.fill();
|
||||||
ctx2d.fillStyle = foreground.toHexString();
|
ctx2d.fillStyle = foreground.toHexString();
|
||||||
const lines = split(ctx2d, name, font, 512, true);
|
const lines = split(ctx2d, name, font, 512, true);
|
||||||
const x = 256;
|
const x = 256;
|
||||||
|
|||||||
@ -5,6 +5,9 @@ import {defineConfig} from "vite";
|
|||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
test: {},
|
test: {},
|
||||||
define: {},
|
define: {},
|
||||||
|
build: {
|
||||||
|
sourcemap: "inline"
|
||||||
|
},
|
||||||
optimizeDeps: {
|
optimizeDeps: {
|
||||||
esbuildOptions: {
|
esbuildOptions: {
|
||||||
define: {
|
define: {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user