forked from MapComplete/MapComplete
Refactoring: port opening hours visualisation to svelte
This commit is contained in:
parent
3b2c2462c5
commit
cc96df94e9
12 changed files with 290 additions and 285 deletions
|
|
@ -1,22 +0,0 @@
|
|||
import Combine from "./Combine"
|
||||
import Translations from "../i18n/Translations"
|
||||
import BaseUIElement from "../BaseUIElement"
|
||||
import SvelteUIElement from "./SvelteUIElement"
|
||||
import { default as LoadingSvg } from "../../assets/svg/Loading.svelte"
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
export default class Loading extends Combine {
|
||||
constructor(msg?: BaseUIElement | string) {
|
||||
const t = Translations.W(msg) ?? Translations.t.general.loading
|
||||
t.SetClass("pl-2")
|
||||
super([
|
||||
new SvelteUIElement(LoadingSvg)
|
||||
.SetClass("animate-spin self-center")
|
||||
.SetStyle("width: 1.5rem; height: 1.5rem; min-width: 1.5rem;"),
|
||||
t,
|
||||
])
|
||||
this.SetClass("flex p-1")
|
||||
}
|
||||
}
|
||||
|
|
@ -2,8 +2,8 @@
|
|||
import { createEventDispatcher } from "svelte"
|
||||
import { twJoin } from "tailwind-merge"
|
||||
import { Translation } from "../i18n/Translation"
|
||||
import { ariaLabel, ariaLabelStore } from "../../Utils/ariaLabel"
|
||||
import { ImmutableStore, Store, UIEventSource } from "../../Logic/UIEventSource"
|
||||
import { ariaLabelStore } from "../../Utils/ariaLabel"
|
||||
import { ImmutableStore, Store } from "../../Logic/UIEventSource"
|
||||
|
||||
/**
|
||||
* A round button with an icon and possible a small text, which hovers above the map
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@
|
|||
import { Translation } from "../i18n/Translation"
|
||||
import WeblateLink from "./WeblateLink.svelte"
|
||||
import { Store } from "../../Logic/UIEventSource"
|
||||
import FromHtml from "./FromHtml.svelte"
|
||||
import { Utils } from "../../Utils"
|
||||
|
||||
export let t: Translation
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue