| 
									
										
										
										
											2021-12-21 18:35:31 +01:00
										 |  |  | import UserRelatedState from "../Logic/State/UserRelatedState" | 
					
						
							| 
									
										
										
										
											2021-10-15 05:20:02 +02:00
										 |  |  | import { FixedUiElement } from "./Base/FixedUiElement" | 
					
						
							|  |  |  | import Combine from "./Base/Combine" | 
					
						
							|  |  |  | import MoreScreen from "./BigComponents/MoreScreen" | 
					
						
							|  |  |  | import Translations from "./i18n/Translations" | 
					
						
							|  |  |  | import Constants from "../Models/Constants" | 
					
						
							| 
									
										
										
										
											2021-10-16 18:30:24 +02:00
										 |  |  | import { Utils } from "../Utils" | 
					
						
							| 
									
										
										
										
											2022-07-03 00:30:11 +02:00
										 |  |  | import LanguagePicker1 from "./LanguagePicker" | 
					
						
							| 
									
										
										
										
											2021-10-17 03:35:13 +02:00
										 |  |  | import IndexText from "./BigComponents/IndexText" | 
					
						
							|  |  |  | import FeaturedMessage from "./BigComponents/FeaturedMessage" | 
					
						
							| 
									
										
										
										
											2022-12-16 13:44:25 +01:00
										 |  |  | import { ImportViewerLinks } from "./BigComponents/UserInformation" | 
					
						
							| 
									
										
										
										
											2023-01-06 04:21:34 +01:00
										 |  |  | import { LoginToggle } from "./Popup/LoginButton" | 
					
						
							| 
									
										
										
										
											2021-10-15 05:20:02 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  | export default class AllThemesGui { | 
					
						
							| 
									
										
										
										
											2022-04-08 04:36:00 +02:00
										 |  |  |     setup() { | 
					
						
							| 
									
										
										
										
											2021-11-07 16:34:51 +01:00
										 |  |  |         try { | 
					
						
							|  |  |  |             new FixedUiElement("").AttachTo("centermessage") | 
					
						
							| 
									
										
										
										
											2021-11-22 00:50:29 +01:00
										 |  |  |             const state = new UserRelatedState(undefined) | 
					
						
							| 
									
										
										
										
											2021-11-07 16:34:51 +01:00
										 |  |  |             const intro = new Combine([ | 
					
						
							| 
									
										
										
										
											2022-07-03 00:30:11 +02:00
										 |  |  |                 new LanguagePicker1(Translations.t.index.title.SupportedLanguages(), "").SetClass( | 
					
						
							| 
									
										
										
										
											2021-11-22 00:50:29 +01:00
										 |  |  |                     "flex absolute top-2 right-3" | 
					
						
							|  |  |  |                 ), | 
					
						
							| 
									
										
										
										
											2021-11-07 16:34:51 +01:00
										 |  |  |                 new IndexText(), | 
					
						
							|  |  |  |             ]) | 
					
						
							|  |  |  |             new Combine([ | 
					
						
							|  |  |  |                 intro, | 
					
						
							| 
									
										
										
										
											2022-01-25 21:55:51 +01:00
										 |  |  |                 new FeaturedMessage().SetClass("mb-4 block"), | 
					
						
							| 
									
										
										
										
											2021-11-07 16:34:51 +01:00
										 |  |  |                 new MoreScreen(state, true), | 
					
						
							| 
									
										
										
										
											2023-01-06 04:21:34 +01:00
										 |  |  |                 new LoginToggle(undefined, Translations.t.index.logIn, state), | 
					
						
							| 
									
										
										
										
											2022-12-16 15:50:53 +01:00
										 |  |  |                 new ImportViewerLinks(state.osmConnection), | 
					
						
							| 
									
										
										
										
											2021-11-07 16:34:51 +01:00
										 |  |  |                 Translations.t.general.aboutMapcomplete | 
					
						
							|  |  |  |                     .Subs({ osmcha_link: Utils.OsmChaLinkFor(7) }) | 
					
						
							|  |  |  |                     .SetClass("link-underline"), | 
					
						
							|  |  |  |                 new FixedUiElement("v" + Constants.vNumber), | 
					
						
							|  |  |  |             ]) | 
					
						
							|  |  |  |                 .SetClass("block m-5 lg:w-3/4 lg:ml-40") | 
					
						
							|  |  |  |                 .SetStyle("pointer-events: all;") | 
					
						
							| 
									
										
										
										
											2023-03-02 05:20:53 +01:00
										 |  |  |                 .AttachTo("top-left") | 
					
						
							| 
									
										
										
										
											2021-11-07 16:34:51 +01:00
										 |  |  |         } catch (e) { | 
					
						
							| 
									
										
										
										
											2021-12-21 18:35:31 +01:00
										 |  |  |             console.error(">>>> CRITICAL", e) | 
					
						
							| 
									
										
										
										
											2021-11-05 01:19:27 +01:00
										 |  |  |             new FixedUiElement( | 
					
						
							|  |  |  |                 "Seems like no layers are compiled - check the output of `npm run generate:layeroverview`. Is this visible online? Contact pietervdvn immediately!" | 
					
						
							| 
									
										
										
										
											2022-09-08 21:40:48 +02:00
										 |  |  |             ) | 
					
						
							| 
									
										
										
										
											2021-11-05 01:19:27 +01:00
										 |  |  |                 .SetClass("alert") | 
					
						
							|  |  |  |                 .AttachTo("centermessage") | 
					
						
							|  |  |  |         } | 
					
						
							| 
									
										
										
										
											2021-10-15 05:20:02 +02:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2021-11-05 01:19:27 +01:00
										 |  |  | } |