React component library that exposes the ImageToolsWorkspace UI for embedding inside other apps. The Vite app in this repo is only a demo shell around the exported component.
Prerequisites: Vite+ (vp). On Windows install it with irm https://vite.plus/ps1 | iex, then restart your terminal or VS Code so vp is on PATH.
Vite+ manages the Node.js runtime from .node-version and the pnpm version from packageManager in package.json.
- Install dependencies:
vp install - Run the dev demo:
vp dev - Build the npm package:
vp run build:lib - Build the demo bundle (optional):
vp build
pnpm add bloom-ai-image-toolsimport { ImageToolsWorkspace } from "bloom-ai-image-tools";
function Example() {
return <ImageToolsWorkspace persistence={...} envApiKey={...} />;
}See App.tsx for a concrete integration example.
Art-style preview thumbnails rely on bundlers that support
import.meta.glob(Vite/Rollup). Other bundlers fall back to text-only style selection.
We use Changesets for semver management. Typical workflow:
- Create a changeset describing your change:
vp run changeset - Merge the generated PR. The
ReleaseGitHub Action will bump versions and publish to npm. - Manual publishing (rare):
vp run release
Ensure NPM_TOKEN is configured in the repo secrets for the workflow to succeed.
- Unit tests:
vp test - E2E (Playwright): set
BLOOM_OPENROUTER_KEY_FOR_PLAYWRIGHT_TESTSto your OpenRouter API key, then runvp run e2e.