@@ -3,25 +3,34 @@ import S from 's-js';
33
44import I from 'minimap/js/util/i18n.mjs' ;
55import systemTheme from 'minimap/js/util/s-theme.mjs' ;
6- import { signal as configSignal } from 'minimap/js/util/tauri-config-signal.mjs' ;
6+ import * as configSignal from 'minimap/js/util/tauri-config-signal.mjs' ;
77
88import Root from 'minimap/js/module/Root.mjs' ;
99import ErrorView from 'minimap/js/module/ErrorView.mjs' ;
10+ import WorkspaceSelect from 'minimap/js/module/WorkspaceSelect.mjs' ;
1011
1112import './reset.css' ;
1213import './global.css' ;
1314import './theme.css' ;
1415
15- const XFormString = {
16- stringify : v => v ?? '' ,
17- parse : v => v ?? ''
18- } ;
19-
2016S . root ( ( ) => {
2117 const Minimap = {
2218 errorMessage : S . value ( ) ,
23- theme : configSignal ( 'theme' , 'system' ) ,
24- langOverride : configSignal ( 'lang' )
19+ theme : configSignal . value ( 'theme' , 'system' ) ,
20+ langOverride : configSignal . value ( 'lang' ) ,
21+ savedWorkspaces : configSignal . array ( 'workspaces' , [
22+ {
23+ type : 'git' ,
24+ remote :
25+ 'file:///C:/Users/Anonymous/AppData/Roaming/minimap/test-repo'
26+ } ,
27+ { type : 'mem' , author : 'Max Mustermann' , email : 'max@example.com' } ,
28+ {
29+ type : 'git' ,
30+ remote :
31+ 'file:///C:/Users/Anonymous/AppData/Roaming/minimap/test-repo'
32+ }
33+ ] )
2534 } ;
2635
2736 if ( typeof window !== 'undefined' ) window . Minimap = Minimap ;
@@ -42,10 +51,9 @@ S.root(() => {
4251
4352 // Calculate the current main view
4453 const currentView = S ( ( ) => {
45- if ( Minimap . errorMessage ( ) ) return < ErrorView { ...{ Minimap } } /> ;
54+ if ( Minimap . errorMessage ( ) ) return < ErrorView { ...Minimap } /> ;
4655
47- // TODO Add your default view here.
48- return ( ) => < div > Hello, world!</ div > ;
56+ return ( ) => < WorkspaceSelect { ...Minimap } /> ;
4957 } ) ;
5058
5159 // Attach!
0 commit comments