feat: V1 prototype — Vite/React/TS tileset generator

- Scaffold: package.json, tsconfig.json, vite.config.ts, index.html
- src/lib/imageProcessor.ts: full pipeline (normalize, offset, seam repair, export, validation)
- src/components/UploadPanel.tsx: drag-and-drop, file picker, clipboard paste
- src/components/SettingsPanel.tsx: all controls per spec
- src/components/PreviewPanel.tsx: Original / Tileable / Repeated tabs
- src/components/ErrorBanner.tsx: dismissible error/warning banners
- src/App.tsx: root component wiring everything together
- src/index.css: dark premium glassmorphism theme w/ Inter font
This commit is contained in:
Ben
2026-05-15 01:18:26 -07:00
parent 68d1ee21b4
commit 31d0464a60
2439 changed files with 933708 additions and 0 deletions
+68
View File
@@ -0,0 +1,68 @@
import Container, { ContainerProps } from './container.js'
import { ProcessOptions } from './postcss.js'
import Result from './result.js'
import Root from './root.js'
declare namespace Document {
export interface DocumentProps extends ContainerProps {
nodes?: readonly Root[]
/**
* Information to generate byte-to-byte equal node string as it was
* in the origin input.
*
* Every parser saves its own properties.
*/
raws?: Record<string, any>
}
export { Document_ as default }
}
/**
* Represents a file and contains all its parsed nodes.
*
* **Experimental:** some aspects of this node could change within minor
* or patch version releases.
*
* ```js
* const document = htmlParser(
* '<html><style>a{color:black}</style><style>b{z-index:2}</style>'
* )
* document.type //=> 'document'
* document.nodes.length //=> 2
* ```
*/
declare class Document_ extends Container<Root> {
nodes: Root[]
parent: undefined
type: 'document'
constructor(defaults?: Document.DocumentProps)
assign(overrides: Document.DocumentProps | object): this
clone(overrides?: Partial<Document.DocumentProps>): this
cloneAfter(overrides?: Partial<Document.DocumentProps>): this
cloneBefore(overrides?: Partial<Document.DocumentProps>): this
/**
* Returns a `Result` instance representing the documents CSS roots.
*
* ```js
* const root1 = postcss.parse(css1, { from: 'a.css' })
* const root2 = postcss.parse(css2, { from: 'b.css' })
* const document = postcss.document()
* document.append(root1)
* document.append(root2)
* const result = document.toResult({ to: 'all.css', map: true })
* ```
*
* @param opts Options.
* @return Result with current documents CSS.
*/
toResult(options?: ProcessOptions): Result
}
declare class Document extends Document_ {}
export = Document