mirror of
https://github.com/FJurmanovic/wallet-web.git
synced 2026-02-06 06:08:10 +00:00
Merge branch 'feature/WW-3-advanced-routing'
This commit is contained in:
@@ -36,7 +36,8 @@ class AppLinkElement extends HTMLElement {
|
||||
}
|
||||
}
|
||||
|
||||
goTo = () => {
|
||||
goTo = (e: Event) => {
|
||||
e.preventDefault();
|
||||
if (!isTrue(this.goBack) && this.to) {
|
||||
this.routerService.goTo(this.to);
|
||||
} else {
|
||||
@@ -51,18 +52,19 @@ class AppLinkElement extends HTMLElement {
|
||||
|
||||
render = () => {
|
||||
return html`${this.disabled
|
||||
? html`<span
|
||||
? html`<a
|
||||
class="btn btn-link btn-disabled"
|
||||
data-target="app-link.main"
|
||||
style="color:grey"
|
||||
>${this.title}</span
|
||||
>${this.title}</a
|
||||
>`
|
||||
: html`<span
|
||||
: html`<a
|
||||
class="btn btn-link btn-disabled"
|
||||
data-target="app-link.main"
|
||||
data-action="click:app-link#goTo"
|
||||
href="${this.to}"
|
||||
style="text-decoration: underline; cursor: pointer;"
|
||||
>${this.title}</span
|
||||
>${this.title}</a
|
||||
>`}`;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user