mirror of
				https://github.com/bra1n/townsquare.git
				synced 2025-10-21 16:55:12 +00:00 
			
		
		
		
	fixin bugs
Co-authored-by: Lianne Turnbull <lianne.turnbull@gmail.com>
This commit is contained in:
		
							parent
							
								
									626827bfea
								
							
						
					
					
						commit
						d34905d09b
					
				
					 3 changed files with 19 additions and 2 deletions
				
			
		|  | @ -265,9 +265,15 @@ export default { | |||
|       } | ||||
|     }, | ||||
|     copySessionUrl() { | ||||
|       const url = window.location.href.split("#")[0]; | ||||
|       try{ | ||||
|         const url = window.location.href.split("#")[0]; | ||||
|       const link = url + "#" + this.session.sessionId; | ||||
|       navigator.clipboard.writeText(link); | ||||
|       } | ||||
|       catch (error) | ||||
|       { | ||||
|       } | ||||
|        | ||||
|     }, | ||||
|     distributeRoles() { | ||||
|       if (this.session.isSpectator) return; | ||||
|  | @ -295,7 +301,9 @@ export default { | |||
|       let sessionId = prompt( | ||||
|         "Enter the channel number / name of the session you want to join" | ||||
|       ); | ||||
|       if (sessionId.match(/^https?:\/\//i)) { | ||||
|       if (sessionId) | ||||
|       { | ||||
|         if (sessionId.match(/^https?:\/\//i)) { | ||||
|         sessionId = sessionId.split("#").pop(); | ||||
|       } | ||||
|       if (sessionId) { | ||||
|  | @ -304,6 +312,8 @@ export default { | |||
|         this.$store.commit("toggleGrimoire", false); | ||||
|         this.$store.commit("session/setSessionId", sessionId); | ||||
|       } | ||||
|       } | ||||
|        | ||||
|     }, | ||||
|     leaveSession() { | ||||
|       if (confirm("Are you sure you want to leave the active live game?")) { | ||||
|  |  | |||
|  | @ -136,6 +136,7 @@ export default { | |||
|         }); | ||||
|       } | ||||
|       this.tab = "editionRoles"; | ||||
|       this.filter = ""; | ||||
|       this.$store.commit("toggleModal", "role"); | ||||
|     }, | ||||
|     close() { | ||||
|  |  | |||
|  | @ -267,6 +267,12 @@ export const store = Vuex.createStore({ | |||
|           ) | ||||
|           .map((role) => [role.id, role]) | ||||
|       ); | ||||
|       state.otherRoles = rolesJSON.filter( | ||||
|         (r) => | ||||
|           r.team !== "traveler" && | ||||
|           r.team !== "fabled" && | ||||
|           !roles.some((i) => i.id === r.id) | ||||
|       ); | ||||
|     }, | ||||
|     setEdition(state, edition) { | ||||
|       if (editionJSONbyId.has(edition.id)) { | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue