From 7034bceb5748849b16cf944388826ab772dfb864 Mon Sep 17 00:00:00 2001 From: Xananax Date: Fri, 10 Jun 2022 18:07:54 +0400 Subject: [PATCH 1/4] improvement: change text to not imply mobile --- html_export/index_template.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/html_export/index_template.html b/html_export/index_template.html index 8f70d795..78ed4314 100644 --- a/html_export/index_template.html +++ b/html_export/index_template.html @@ -46,7 +46,7 @@

- You appear to be using a mobile browser. This application is not + Your browser window seems to be too narrow. This application is not suitable for small screens and portrait orientation. If you want to continue, it's at your own risk!

From 6861c1722cd4611d2e54be61f3203aebe33e14fc Mon Sep 17 00:00:00 2001 From: Xananax Date: Fri, 10 Jun 2022 18:08:31 +0400 Subject: [PATCH 2/4] fix: download custom templates locally --- .gitignore | 4 ++++ run | 21 ++++++++++++++++++++- 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 5cb1dc87..409338bd 100644 --- a/.gitignore +++ b/.gitignore @@ -17,5 +17,9 @@ addons/godot-plugin-refresher # Exports build/**/ +#custom downloaded templates +templates/* +???custom-templates.zip + # Local user overrides override.cfg \ No newline at end of file diff --git a/run b/run index 9d4380c4..6d0e9d74 100755 --- a/run +++ b/run @@ -3,6 +3,9 @@ APP_NAME="learn_to_code" +# This is used while developing to supply the `GODOT_VERSION` variable that is +# normally provided by the CI +local_godot_version=${GODOT_VERSION:-"3.4.4"} ######################################## HELP @@ -363,6 +366,11 @@ push_all(){ prepare_ci_copytemplates(){ if [ "$1" == "help" ]; then + echo "-- DEPRECATED --" + echo "Do not use this, use gettemplates instead" + echo "We need to download custom templates to enable offline GDScript error reporting" + echo "Once/if this is merged in master, we can use copytemplates again" + echo "----------------" echo "Prepares the CI by copying the template from the docker" echo "You should not run this on your local computer" echo "cannot run in dry mode" @@ -385,7 +393,6 @@ prepare_ci_copytemplates(){ prepare_ci_gettemplates(){ if [ "$1" == "help" ]; then echo "Prepares the CI by getting the custom templates online" - echo "You should not run this on your local computer" echo "cannot run in dry mode" exit 0 fi @@ -499,6 +506,18 @@ prepare_htmltemplate(){ } +prepare_local(){ + # TODO: remove this if/when prepare_ci_gettemplates becomes unecessary + if [ "$1" == "help" ]; then + echo "Downloads the custom templates locally" + echo "Necessary before any export" + echo "cannot run in dry mode" + exit 0 + fi + GODOT_VERSION="$local_godot_version" prepare_ci_gettemplates +} + + ######################################## BOOTSTRAP From 1a7a935c2454338a2300f60b0061669cebaea0e3 Mon Sep 17 00:00:00 2001 From: Xananax Date: Fri, 10 Jun 2022 18:09:01 +0400 Subject: [PATCH 3/4] fix: do not set a specific size for notices --- html_export/static/style.css | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/html_export/static/style.css b/html_export/static/style.css index 21439447..cb2789b3 100644 --- a/html_export/static/style.css +++ b/html_export/static/style.css @@ -138,8 +138,9 @@ body { .notices { font-family: "Noto Sans", "Droid Sans", Arial, sans-serif; color: #3b3943; - width: 640px; + max-width: 640px; padding: 3em; + margin: 1em; background: #fdfdfd; box-shadow: 0 19px 38px rgba(0, 0, 0, 0.3), 0 15px 12px rgba(0, 0, 0, 0.22); } @@ -180,7 +181,7 @@ body { display: none; } -@media (orientation: portrait), (max-aspect-ratio: 4/3), (max-width: 750px) { +@media (orientation: portrait), (max-width: 700px) { .mobile-only { display: flex; } From 814bb60b1d63a533ffd12debca5dc05e2abb9023 Mon Sep 17 00:00:00 2001 From: Xananax Date: Fri, 10 Jun 2022 18:17:18 +0400 Subject: [PATCH 4/4] fix: check for height too --- html_export/static/style.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/html_export/static/style.css b/html_export/static/style.css index cb2789b3..76bdbd35 100644 --- a/html_export/static/style.css +++ b/html_export/static/style.css @@ -181,7 +181,7 @@ body { display: none; } -@media (orientation: portrait), (max-width: 700px) { +@media (orientation: portrait), (max-width: 700px), (max-height: 400px) { .mobile-only { display: flex; }