Full code cleanup

This commit is contained in:
Pieter Vander Vennet 2022-01-26 21:40:38 +01:00
parent 3a4a2a2016
commit fa971ffbbf
300 changed files with 16352 additions and 19284 deletions

View file

@ -298,16 +298,16 @@ export class OH {
}
}
public static simplify(str: string): string{
public static simplify(str: string): string {
return OH.ToString(OH.MergeTimes(OH.Parse(str)))
}
public static Parse(rules: string) : OpeningHour[] {
public static Parse(rules: string): OpeningHour[] {
if (rules === undefined || rules === "") {
return []
}
const ohs : OpeningHour[] = []
const ohs: OpeningHour[] = []
const split = rules.split(";");

View file

@ -23,7 +23,7 @@ export default class OpeningHoursVisualization extends Toggle {
Translations.t.general.weekdays.abbreviations.sunday,
]
constructor(tags: UIEventSource<any>, state:{osmConnection?: OsmConnection}, key: string, prefix = "", postfix = "") {
constructor(tags: UIEventSource<any>, state: { osmConnection?: OsmConnection }, key: string, prefix = "", postfix = "") {
const tagsDirect = tags.data;
const ohTable = new VariableUiElement(tags
.map(tags => {