File size: 684 Bytes
ec3efd7
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import { writable } from 'svelte/store';
import type { Brush, Params, DrawingLayer } from '../types';
import { randomSeed } from '$lib/utils';
import { PRESETS } from '../data';

export const drawingLayers = writable<Map<string, DrawingLayer>>(new Map());
export const resultImage = writable<string>();
export const currentCanvas = writable<HTMLCanvasElement>();
export const selectedImage = writable<HTMLImageElement>();
export const selectedBrush = writable<Brush>();
export const selectedParams = writable<Params>({
	prompt: PRESETS[0][0],
	seed: randomSeed(),
	steps: 20
});

export const generateMap = writable<boolean>(false);
export const saveResult = writable<boolean>(false);