CI fix again

This commit is contained in:
Yummy-Yums 2024-05-14 20:54:17 +00:00 committed by Elijah
parent d932cb7db0
commit f17d245e0d
3 changed files with 12 additions and 11 deletions

View File

@ -1819,7 +1819,9 @@ class NoSSRComponent(Component):
library_import = f"const {self.alias if self.alias else self.tag} = dynamic(() => import('{import_name}')"
mod_import = (
# https://nextjs.org/docs/pages/building-your-application/optimizing/lazy-loading#with-named-exports
f".then((mod) => mod.{self.tag})" if not self.is_default else ""
f".then((mod) => mod.{self.tag})"
if not self.is_default
else ""
)
return "".join((library_import, mod_import, opts_fragment))

View File

@ -98,8 +98,8 @@ class Markdown(Component):
Returns:
The markdown component.
"""
assert (
len(children) == 1 and types._isinstance(children[0], Union[str, Var])
assert len(children) == 1 and types._isinstance(
children[0], Union[str, Var]
), "Markdown component must have exactly one child containing the markdown source."
# Update the base component map with the custom component map.
@ -243,7 +243,9 @@ class Markdown(Component):
}
# Separate out inline code and code blocks.
components["code"] = f"""{{({{node, inline, className, {_CHILDREN._var_name}, {_PROPS._var_name}}}) => {{
components[
"code"
] = f"""{{({{node, inline, className, {_CHILDREN._var_name}, {_PROPS._var_name}}}) => {{
const match = (className || '').match(/language-(?<lang>.*)/);
const language = match ? match[1] : '';
if (language) {{
@ -261,7 +263,9 @@ class Markdown(Component):
) : (
{self.format_component("codeblock", language=Var.create_safe("language", _var_is_local=False))}
);
}}}}""".replace("\n", " ")
}}}}""".replace(
"\n", " "
)
return components

View File

@ -528,12 +528,7 @@ def deploy(
hosting_cli.deploy(
app_name=app_name,
export_fn=lambda zip_dest_dir,
api_url,
deploy_url,
frontend,
backend,
zipping: export_utils.export(
export_fn=lambda zip_dest_dir, api_url, deploy_url, frontend, backend, zipping: export_utils.export(
zip_dest_dir=zip_dest_dir,
api_url=api_url,
deploy_url=deploy_url,