Add filter to package server and fix templates for devstudio

This commit is contained in:
2025-09-04 04:48:40 -05:00
parent 8bb45eae15
commit 55a15c9d98
17 changed files with 69 additions and 67 deletions

View File

@@ -11,6 +11,7 @@
"template_info": {
"type": "compile_tool"
},
"template_name_pretty": "Compile Tool",
"template_ignored_files": ["bin","obj"],
"description": "A tool that can be a dependency to a project (including libraries) that runs at compile time"
}

View File

@@ -11,6 +11,7 @@
"template_info": {
"type": "console"
},
"template_name_pretty": "Console Application",
"template_ignored_files": ["bin","obj"],
"description": "A console application"
}

View File

@@ -12,6 +12,7 @@
"template_info": {
"type": "console"
},
"template_name_pretty": "Empty Website",
"template_extra_text_ftles": [],
"template_ignored_files": ["bin","obj"]
}

View File

@@ -1,33 +0,0 @@
{
"Child": {
"Type": "AbsoluteView",
"Items": [
{
"Bounds": {
"X": 42,
"Y": 42,
"Width": 200,
"Height": 50
},
"Type": "ButtonView",
"Text": "Click Me",
"Id": "btn1",
"Active": true
}
]
},
"Palette": {
"IsDarkMode": true,
"Accent": "#DB0",
"Border": "#040",
"BorderActive":"#A00",
"BorderHover": "#00A",
"BorderHoverActive": "#A0A",
"FontSize": 20
},
"Size": {
"Width": 640,
"Height": 480
},
"Text": "%PROJECT_NAME%"
}

View File

@@ -1,18 +0,0 @@
func btn1_Click(sender,e)
{
Console.WriteLine("Button Clicked");
}
func main(args)
{
if(TypeOf(GUI) != "Dictionary")
{
Console.WriteLine("The GUI is not supported, please build tessesframework with TESSESFRAMEWORK_ENABLE_SDL2.");
return 1;
}
var window = GUI.Window.FromJSON(embed("layout.json"), SDL2.Window.Resizable);
var btn1 = window.FindViewById("btn1");
btn1.Click += btn1_Click;
VM.RunEventLoop();
btn.Click -= btn1_Click;
window.Dispose(); //we need to destroy it or it will leak
}

View File

@@ -12,6 +12,7 @@
"type": "lib"
},
"template_ignored_files": ["bin","obj"],
"description": "A crosslang library"
"description": "A crosslang library",
"template_name_pretty": "Library"
}
}

View File

@@ -21,6 +21,7 @@
},
"template_project_dependencies": [],
"template_extra_text_ftles": [],
"template_ignored_files": ["bin","obj"]
"template_ignored_files": ["bin","obj"],
"template_name_pretty": "Template"
}
}

View File

@@ -21,5 +21,6 @@
"license": "MIT"
},
"version": "1.0.0.0-prod",
"name": "Tesses.CrossLang.Template.Tool"
"name": "Tesses.CrossLang.Template.Tool",
"template_name_pretty": "Tool"
}

View File

@@ -13,5 +13,6 @@
"type": "console"
},
"template_ignored_files": ["bin","obj"]
}
},
"template_name_pretty": "WebSite"
}

View File

@@ -2,25 +2,24 @@
"dependencies": [
],
"info": {
"template_extra_text_ftles": [
"res/layout.json"
],
"template_ignored_files": [
"bin",
"obj"
],
"template_info": {
"type": "app",
"type": "webapp",
"license": "MIT"
},
"template_name": "gui",
"template_name": "webapp",
"template_name_pretty": "Web Application",
"template_project_dependencies": [
],
"repo": "https://onedev.site.tesses.net/CrossLang/CrossLangExtras",
"homepage": "https://crosslang.tesseslanguage.com/",
"type": "template",
"description": "A crosslang gui, using tesses-framework's gui library"
"description": "A web app (for webview or eventual cloud OS)"
},
"name": "Tesses.CrossLang.Template.GUI",
"name": "Tesses.CrossLang.Template.WebApp",
"version": "1.0.0.0-prod"
}

View File

@@ -0,0 +1,12 @@
func WebAppMain(args)
{
return (ctx)=>{
if(ctx.Path == "/")
{
ctx.WithMimeType("text/html").SendText(<h1>Hello, world</h1>);
return true;
}
return false;
};
}