From a2cd95f89d0ad6448dd6508f9515ce9026b37d23 Mon Sep 17 00:00:00 2001 From: Thomas Weber Date: Sat, 11 Dec 2021 22:14:48 -0600 Subject: [PATCH] Android support --- src/locales/en.json | 5 +- src/p4/P4.svelte | 2 +- src/p4/PackagerOptions.svelte | 133 +++++++++++++++++++++++++++++++++- src/p4/template.ejs | 2 +- src/packager/packager.js | 17 +++++ 5 files changed, 153 insertions(+), 6 deletions(-) diff --git a/src/locales/en.json b/src/locales/en.json index 49cf8a3a..7eae9d55 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -1,7 +1,7 @@ { "p4": { "description1": { - "string": "Converts Scratch projects into HTML files, zip archives, or executable programs for Windows, macOS, and Linux." + "string": "Converts Scratch projects into HTML files, zip archives, or executable programs for Windows, macOS, Linux, and Android." }, "description2": { "string": "If you just want an easy way to embed a project into your website, you may be interested in {embedding}." @@ -363,6 +363,9 @@ "string": "{type} Linux application (64-bit only)", "context": "type will become something like 'NW.js' or 'Electron'. Do not translate 'Linux'." }, + "application-android": { + "string": "Android app (Highly experimental)" + }, "otherEnvironments": { "string": "Other environments (Click to open)", "context": "Text that can be clicked to expand list of environments to include some unrecommended ones." diff --git a/src/p4/P4.svelte b/src/p4/P4.svelte index c57483a0..dba55ed2 100644 --- a/src/p4/P4.svelte +++ b/src/p4/P4.svelte @@ -83,7 +83,7 @@ :global([theme="dark"] .is-not-safari select:hover) { border-color: #bbb; } - :global(p), :global(h1), :global(h2), :global(h3) { + :global(p), :global(pre), :global(h1), :global(h2), :global(h3) { margin: 12px 0; } :global(summary) { diff --git a/src/p4/PackagerOptions.svelte b/src/p4/PackagerOptions.svelte index efbc73cc..68a13d4b 100644 --- a/src/p4/PackagerOptions.svelte +++ b/src/p4/PackagerOptions.svelte @@ -180,8 +180,9 @@ font-weight: bold; background: yellow; color: black; - padding: 10px; - border-radius: 10px; + padding: 12px; + border-radius: 12px; + margin: 12px 0; } @@ -609,6 +610,13 @@ +
+ +
+
{$_('options.otherEnvironments')}

{$_('options.otherEnvironmentsHelp')}

@@ -660,7 +668,8 @@ {#if $options.target.startsWith('zip')}

Zip

The zip environment is intended to be used for publishing to a website. Other uses such as sending your project to a friend over a chat app or email should use "Plain HTML" instead as zip will not work.

- {:else} + {/if} + {#if !$options.target.startsWith('zip')}

{$_('options.applicationSettings')}