| 
									
										
										
										
											2021-12-21 18:35:15 +01:00
										 |  |  | import {Utils} from "./Utils"; | 
					
						
							|  |  |  | import AllThemesGui from "./UI/AllThemesGui"; | 
					
						
							| 
									
										
										
										
											2021-12-21 19:09:24 +01:00
										 |  |  | import {QueryParameters} from "./Logic/Web/QueryParameters"; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | const layout = QueryParameters.GetQueryParameter("layout", undefined).data ?? "" | 
					
						
							|  |  |  | const customLayout = QueryParameters.GetQueryParameter("userlayout", undefined).data ?? "" | 
					
						
							|  |  |  | const l = window.location; | 
					
						
							| 
									
										
										
										
											2022-01-26 21:40:38 +01:00
										 |  |  | if (layout !== "") { | 
					
						
							|  |  |  |     if (window.location.host.startsWith("127.0.0.1")) { | 
					
						
							|  |  |  |         window.location.replace(l.protocol + "//" + window.location.host + "/theme.html" + l.search + "&layout=" + layout + l.hash); | 
					
						
							|  |  |  |     } else { | 
					
						
							|  |  |  |         window.location.replace(l.protocol + "//" + window.location.host + "/" + layout + ".html" + l.search + l.hash); | 
					
						
							| 
									
										
										
										
											2022-01-14 01:41:19 +01:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2022-01-26 21:40:38 +01:00
										 |  |  | } else if (customLayout !== "") { | 
					
						
							|  |  |  |     window.location.replace(l.protocol + "//" + window.location.host + "/theme.html" + l.search + l.hash); | 
					
						
							| 
									
										
										
										
											2021-12-21 19:09:24 +01:00
										 |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-12-21 18:35:15 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | Utils.DisableLongPresses() | 
					
						
							|  |  |  | document.getElementById("decoration-desktop").remove(); | 
					
						
							| 
									
										
										
										
											2021-12-21 18:35:31 +01:00
										 |  |  | new AllThemesGui(); |