Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added client/web/icons/loading-animation.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 0 additions & 5 deletions client/web/icons/loading-animation.svg

This file was deleted.

8 changes: 4 additions & 4 deletions client/web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -72,27 +72,27 @@

@keyframes breathe {
from {
transform: scale(1);
transform: scale(0.4);
opacity: 1.0;
}

to {
transform: scale(0.95);
transform: scale(0.35);
opacity: .7;
}
}

@keyframes zooooom {
from {
transform: scale(1)
transform: scale(0.4)
}

to {
transform: scale(10)
}
}
</style>
<img src="icons/loading-animation.svg" alt="Loading indicator..." />
<img src="icons/loading-animation.png" alt="Loading..." />
</div>
<script>
window.addEventListener('load', function () {
Expand Down
17 changes: 12 additions & 5 deletions sdk/python/packages/flet/src/flet/cli/commands/publish.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,13 +206,20 @@ def filter_tar(tarinfo: tarfile.TarInfo):
),
)
if options.app_title:
index = index.replace(
'content="Flet"', 'content="{}"'.format(options.app_title)
index = re.sub(
r"\<meta name=\"apple-mobile-web-app-title\" content=\"(.+)\">",
r'<meta name="apple-mobile-web-app-title" content="{}">'.format(
options.app_title
),
index,
)
if options.app_description:
index = index.replace(
'content="Flet application."',
'content="{}"'.format(options.app_description),
index = re.sub(
r"\<meta name=\"description\" content=\"(.+)\">",
r'<meta name="description" content="{}">'.format(
options.app_description
),
index,
)

with open(index_path, "w") as f:
Expand Down
4 changes: 1 addition & 3 deletions sdk/python/packages/flet/src/flet/flet.py
Original file line number Diff line number Diff line change
Expand Up @@ -443,9 +443,7 @@ def __start_flet_server(
logging.info(f"Route URL strategy configured: {route_url_strategy}")
fletd_env["FLET_ROUTE_URL_STRATEGY"] = route_url_strategy

web_root_dir = os.environ.get("FLET_WEB_PATH")
if not web_root_dir:
web_root_dir = get_package_web_dir()
web_root_dir = get_package_web_dir()

if not os.path.exists(web_root_dir):
raise Exception("Web root path not found: {}".format(web_root_dir))
Expand Down
3 changes: 2 additions & 1 deletion sdk/python/packages/flet/src/flet/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@ def get_package_bin_dir():


def get_package_web_dir():
return os.path.join(get_package_root_dir(), "web")
web_root_dir = os.environ.get("FLET_WEB_PATH")
return web_root_dir if web_root_dir else os.path.join(get_package_root_dir(), "web")


def get_free_tcp_port():
Expand Down