Skip to content

Commit

Permalink
down to 308 lines for #479
Browse files Browse the repository at this point in the history
  • Loading branch information
WolfgangFahl committed Aug 30, 2022
1 parent 09269c8 commit 1757a24
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 27 deletions.
8 changes: 3 additions & 5 deletions justpy/templates/main.html
Original file line number Diff line number Diff line change
Expand Up @@ -229,8 +229,7 @@
send_to_server(e);
});
}

{% if page_options.reload_interval %}
{%- if page_options.reload_interval %}
setInterval(function () {
$.ajax({
type: "POST",
Expand All @@ -245,7 +244,7 @@
dataType: 'json'
});
}, 1000 * {{ page_options.reload_interval }});
{% endif %}
{%- endif %}

var app1 = new Vue({
el: '#components',
Expand All @@ -266,5 +265,4 @@
return h('div', {}, comps);
}
});

</script>
</script>
27 changes: 5 additions & 22 deletions justpy/templates/tailwind.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,39 +3,31 @@
<!--This is a justpy application using the tailwind.html template-->
<head>
{% include 'favicon.html' %}

{% if options.tailwind %}
{% if not options.no_internet %}
{%- if not options.no_internet %}
<link rel="stylesheet" href="https://unpkg.com/tailwindcss@^2.0/dist/base.min.css">
<link rel="stylesheet" href="https://unpkg.com/tailwindcss@^2.0/dist/components.min.css">
<link rel="stylesheet" href="https://unpkg.com/@tailwindcss/typography@0.4.x/dist/typography.min.css">
<link rel="stylesheet" href="https://unpkg.com/tailwindcss@^2.0/dist/utilities.min.css">
{% else %}
{%- else %}
<link href="/templates/local/tailwind/base.css" rel="stylesheet">
<link href="/templates/local/tailwind/components.css" rel="stylesheet">
<link href="/templates/local/tailwind/typography.css" rel="stylesheet">
<link href="/templates/local/tailwind/utilities.css" rel="stylesheet">
{% endif %}
<style>
{% include 'css/form.css' %}
</style>
{%- endif %}
<link href="/template/css/form.css" rel="stylesheet">
{% endif %}


{% if not options.no_internet %}
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.9.0/css/all.css"/>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.7.0/animate.min.css"/>
{% else %}
<link rel="stylesheet" href="/templates/local/fontawesome/css/all.min.css"/>
<link rel="stylesheet" href="/templates/local/animate.css"/>
{% endif %}

<style>
{{ page_options.css }}
</style>

{{ page_options.head_html | safe }}

{% if not html %}
{% if not options.no_internet %}
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
Expand All @@ -45,23 +37,14 @@
<script src="/templates/local/vue.js"></script>
{% endif %}
{% endif %}

{% include 'optional_packages.html' %}

</head>


<body style="{{ page_options.body_style }}" class="{{ page_options.body_classes }}">
{{ page_options.body_html | safe }}
<div id="components">

</div>

{% include 'main.html' %}

</body>
</html>
{% else %}{{ html | safe }}
{% endif %}


{% endif %}

0 comments on commit 1757a24

Please sign in to comment.