diff --git a/app.go b/app.go
index 9cefcbc..e90a10f 100644
--- a/app.go
+++ b/app.go
@@ -6,7 +6,8 @@ import (
"fmt"
"os"
"path/filepath"
- "spriteStackist/pkg/data"
+
+ "github.com/kettek/staxie/pkg/data"
"github.com/wailsapp/wails/v2/pkg/runtime"
)
@@ -27,16 +28,11 @@ func (a *App) startup(ctx context.Context) {
a.ctx = ctx
}
-// Greet returns a greeting for the given name
-func (a *App) Greet(name string) string {
- return fmt.Sprintf("Hello %s, It's show time!", name)
+func (a *App) Load(name string) *data.StaxieFileV1 {
+ return &data.StaxieFileV1{}
}
-func (a *App) Load(name string) *data.StackistFileV1 {
- return &data.StackistFileV1{}
-}
-
-func (a *App) Save(name string, file *data.StackistFileV1) error {
+func (a *App) Save(name string, file *data.StaxieFileV1) error {
b, err := json.Marshal(file)
if err != nil {
return err
diff --git a/frontend/index.html b/frontend/index.html
index 164008f..418014e 100644
--- a/frontend/index.html
+++ b/frontend/index.html
@@ -3,7 +3,7 @@
- spriteStackist
+ Staxie
diff --git a/frontend/package.json.md5 b/frontend/package.json.md5
index 1386cbf..17bb156 100644
--- a/frontend/package.json.md5
+++ b/frontend/package.json.md5
@@ -1 +1 @@
-f001f3ad84549a4a16ef6303845139bd
\ No newline at end of file
+6370e69c73297099c048eead390477f3
\ No newline at end of file
diff --git a/frontend/src/App.svelte b/frontend/src/App.svelte
index 4dc5c14..42784e3 100644
--- a/frontend/src/App.svelte
+++ b/frontend/src/App.svelte
@@ -87,7 +87,7 @@
let showExport: boolean = false
let showNew: boolean = false
let importValid: boolean = false
- let importFile: data.StackistFileV1 = null
+ let importFile: data.StaxieFileV1 = null
let importFilepath: string = ''
let importCanvas: Canvas = null
diff --git a/frontend/src/sections/Importer.svelte b/frontend/src/sections/Importer.svelte
index 2728bd3..37a3dd1 100644
--- a/frontend/src/sections/Importer.svelte
+++ b/frontend/src/sections/Importer.svelte
@@ -36,7 +36,7 @@
let width: number = 16
let height: number = 16
let rowBasedFrames: boolean = true
- export let file: data.StackistFileV1
+ export let file: data.StaxieFileV1
export let filepath: string = ''
export let canvas: Canvas
let img: HTMLImageElement
@@ -132,7 +132,7 @@
}
function remakeFile() {
- file = data.StackistFileV1.createFrom({
+ file = data.StaxieFileV1.createFrom({
width: width,
height: height,
groups: {}
diff --git a/frontend/src/sections/New.svelte b/frontend/src/sections/New.svelte
index 73b7b18..693a625 100644
--- a/frontend/src/sections/New.svelte
+++ b/frontend/src/sections/New.svelte
@@ -19,7 +19,7 @@
let width: number = 64
let height: number = 64
let indexed: boolean = true
- export let file: data.StackistFileV1
+ export let file: data.StaxieFileV1
export let canvas: Canvas
export let open: boolean = false
@@ -28,7 +28,7 @@
canvas = new Canvas(width, height)
canvas.addNewPaletteColor(0, 0, 0, 0)
canvas.isIndexed = indexed
- file = data.StackistFileV1.createFrom({
+ file = data.StaxieFileV1.createFrom({
width: width,
height: height,
groups: {}
@@ -40,7 +40,7 @@
canvas = new Canvas(width, height)
canvas.addNewPaletteColor(0, 0, 0, 0)
canvas.isIndexed = indexed
- file = data.StackistFileV1.createFrom({
+ file = data.StaxieFileV1.createFrom({
width: width,
height: height,
groups: {}
diff --git a/frontend/src/types/file.ts b/frontend/src/types/file.ts
index 2683213..24c10b3 100644
--- a/frontend/src/types/file.ts
+++ b/frontend/src/types/file.ts
@@ -8,7 +8,7 @@ export interface LoadedFileOptions {
filepath: string
title: string
canvas: Canvas
- data: data.StackistFileV1
+ data: data.StaxieFileV1
}
export class LoadedFile extends UndoableStack {
@@ -17,7 +17,7 @@ export class LoadedFile extends UndoableStack {
canvas: Canvas
selection: SelectionArea
preview: Preview
- data: data.StackistFileV1
+ data: data.StaxieFileV1
constructor(options: LoadedFileOptions) {
super()
diff --git a/frontend/wailsjs/go/main/App.d.ts b/frontend/wailsjs/go/main/App.d.ts
index 11cd951..aa574f0 100644
--- a/frontend/wailsjs/go/main/App.d.ts
+++ b/frontend/wailsjs/go/main/App.d.ts
@@ -4,15 +4,13 @@ import {data} from '../models';
export function GetFilePath():Promise;
-export function Greet(arg1:string):Promise;
-
-export function Load(arg1:string):Promise;
+export function Load(arg1:string):Promise;
export function OpenFileBytes(arg1:string):Promise>;
export function ReadBytes(arg1:string):Promise>;
-export function Save(arg1:string,arg2:data.StackistFileV1):Promise;
+export function Save(arg1:string,arg2:data.StaxieFileV1):Promise;
export function SaveFileBytes(arg1:string,arg2:Array):Promise;
diff --git a/frontend/wailsjs/go/main/App.js b/frontend/wailsjs/go/main/App.js
index 4b49cc5..dedfe75 100644
--- a/frontend/wailsjs/go/main/App.js
+++ b/frontend/wailsjs/go/main/App.js
@@ -6,10 +6,6 @@ export function GetFilePath() {
return window['go']['main']['App']['GetFilePath']();
}
-export function Greet(arg1) {
- return window['go']['main']['App']['Greet'](arg1);
-}
-
export function Load(arg1) {
return window['go']['main']['App']['Load'](arg1);
}
diff --git a/frontend/wailsjs/go/models.ts b/frontend/wailsjs/go/models.ts
index f94e83c..33f72fc 100644
--- a/frontend/wailsjs/go/models.ts
+++ b/frontend/wailsjs/go/models.ts
@@ -110,14 +110,14 @@ export namespace data {
}
}
- export class StackistFileV1 {
+ export class StaxieFileV1 {
version: string;
groups: {[key: string]: Group};
width: number;
height: number;
static createFrom(source: any = {}) {
- return new StackistFileV1(source);
+ return new StaxieFileV1(source);
}
constructor(source: any = {}) {
diff --git a/go.mod b/go.mod
index 70c4dc5..9f926ab 100644
--- a/go.mod
+++ b/go.mod
@@ -1,4 +1,4 @@
-module spriteStackist
+module github.com/kettek/staxie
go 1.21
diff --git a/main.go b/main.go
index 7310abd..7da5b36 100644
--- a/main.go
+++ b/main.go
@@ -17,7 +17,7 @@ func main() {
// Create application with options
err := wails.Run(&options.App{
- Title: "spriteStackist",
+ Title: "Staxie",
Width: 1024,
Height: 768,
AssetServer: &assetserver.Options{
diff --git a/pkg/data/file.go b/pkg/data/file.go
index 881beaf..6cca891 100644
--- a/pkg/data/file.go
+++ b/pkg/data/file.go
@@ -1,6 +1,6 @@
package data
-type StackistFileV1 struct {
+type StaxieFileV1 struct {
Version string `json:"version"` // The version of the file format.
Groups map[string]Group `json:"groups"`
Width int `json:"width"`
diff --git a/wails.json b/wails.json
index 30818bd..f340c67 100644
--- a/wails.json
+++ b/wails.json
@@ -1,7 +1,7 @@
{
"$schema": "https://wails.io/schemas/config.v2.json",
- "name": "spriteStackist",
- "outputfilename": "spriteStackist",
+ "name": "Staxie",
+ "outputfilename": "Staxie",
"frontend:install": "npm install",
"frontend:build": "npm run build",
"frontend:dev:watcher": "npm run dev",