Fix missing getEventURL function in connection banner (#2557)
After a previous PR replaced `getEventURL` with `getBackendURL`, the banner code was not updated, leading to problems rendering the connection banner.
This commit is contained in:
parent
601dd34792
commit
7fb9747fa7
@ -34,7 +34,8 @@ class WebsocketTargetURL(Bare):
|
|||||||
|
|
||||||
def _get_imports(self) -> imports.ImportDict:
|
def _get_imports(self) -> imports.ImportDict:
|
||||||
return {
|
return {
|
||||||
"/utils/state.js": [imports.ImportVar(tag="getEventURL")],
|
"/utils/state.js": [imports.ImportVar(tag="getBackendURL")],
|
||||||
|
"/env.json": [imports.ImportVar(tag="env", is_default=True)],
|
||||||
}
|
}
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
@ -44,7 +45,7 @@ class WebsocketTargetURL(Bare):
|
|||||||
Returns:
|
Returns:
|
||||||
The websocket target URL component.
|
The websocket target URL component.
|
||||||
"""
|
"""
|
||||||
return super().create(contents="{getEventURL().href}")
|
return super().create(contents="{getBackendURL(env.EVENT).href}")
|
||||||
|
|
||||||
|
|
||||||
def default_connection_error() -> list[str | Var | Component]:
|
def default_connection_error() -> list[str | Var | Component]:
|
||||||
|
Loading…
Reference in New Issue
Block a user