Fixes a few last points
This commit is contained in:
parent
9e8e99cb6f
commit
c35f82bdcf
7 changed files with 22 additions and 2142 deletions
|
@ -5,6 +5,10 @@ const esbuild = require('esbuild')
|
|||
const name = process.env.npm_package_name || ''
|
||||
|
||||
async function main() {
|
||||
if (!fs.existsSync('./dist')) {
|
||||
fs.mkdirSync('./dist')
|
||||
}
|
||||
|
||||
try {
|
||||
esbuild.buildSync({
|
||||
entryPoints: ['./src/index.ts'],
|
||||
|
|
|
@ -1,17 +1,21 @@
|
|||
/* eslint-disable */
|
||||
|
||||
const fs = require('fs')
|
||||
const esbuild = require('esbuild')
|
||||
|
||||
const name = process.env.npm_package_name || ''
|
||||
|
||||
async function main() {
|
||||
if (!fs.existsSync('./dist')) {
|
||||
fs.mkdirSync('./dist')
|
||||
}
|
||||
|
||||
esbuild.build({
|
||||
entryPoints: ['./src/index.ts'],
|
||||
outdir: 'dist/cjs',
|
||||
minify: false,
|
||||
bundle: true,
|
||||
format: 'cjs',
|
||||
target: 'esnext',
|
||||
target: 'es6',
|
||||
jsxFactory: 'React.createElement',
|
||||
jsxFragment: 'React.Fragment',
|
||||
tsconfig: './tsconfig.json',
|
||||
|
|
|
@ -61,4 +61,4 @@
|
|||
"rko": "^0.5.18"
|
||||
},
|
||||
"gitHead": "4a7439ddf81b615ee49fddbe00802699975f9375"
|
||||
}
|
||||
}
|
|
@ -5,6 +5,10 @@ const esbuild = require('esbuild')
|
|||
const name = process.env.npm_package_name || ''
|
||||
|
||||
async function main() {
|
||||
if (!fs.existsSync('./dist')) {
|
||||
fs.mkdirSync('./dist')
|
||||
}
|
||||
|
||||
try {
|
||||
esbuild.buildSync({
|
||||
entryPoints: ['./src/index.ts'],
|
||||
|
|
|
@ -1,17 +1,21 @@
|
|||
/* eslint-disable */
|
||||
|
||||
const fs = require('fs')
|
||||
const esbuild = require('esbuild')
|
||||
|
||||
const name = process.env.npm_package_name || ''
|
||||
|
||||
async function main() {
|
||||
if (!fs.existsSync('./dist')) {
|
||||
fs.mkdirSync('./dist')
|
||||
}
|
||||
|
||||
esbuild.build({
|
||||
entryPoints: ['./src/index.ts'],
|
||||
outdir: 'dist/cjs',
|
||||
minify: false,
|
||||
bundle: true,
|
||||
format: 'cjs',
|
||||
target: 'esnext',
|
||||
target: 'es6',
|
||||
jsxFactory: 'React.createElement',
|
||||
jsxFragment: 'React.Fragment',
|
||||
tsconfig: './tsconfig.build.json',
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -103,12 +103,10 @@ export class TLDrawState extends StateManager<Data> {
|
|||
/* -------------------- Internal -------------------- */
|
||||
|
||||
protected onStateWillChange = (state: Data, id: string): void => {
|
||||
|
||||
if (id === "reset" || id.startsWith("command")) {
|
||||
if (!id.startsWith('patch')) {
|
||||
this.selectHistory.stack = [[]]
|
||||
this.selectHistory.pointer = 0
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
protected onStateDidChange = (state: Data, id: string): void => {
|
||||
|
|
Loading…
Reference in a new issue