fix volume actually not getting animated
This commit is contained in:
		
							parent
							
								
									336a637b9f
								
							
						
					
					
						commit
						e5b5ba12e0
					
				
					 2 changed files with 3 additions and 2 deletions
				
			
		|  | @ -2,7 +2,7 @@ | ||||||
|     <div :class="['channel', `channel-${loadingState}`]"> |     <div :class="['channel', `channel-${loadingState}`]"> | ||||||
|         <div class="name">{{name}}</div> |         <div class="name">{{name}}</div> | ||||||
|         <VolumeSlider :value="volume" :disabled="loadingState === 'unloaded'" |         <VolumeSlider :value="volume" :disabled="loadingState === 'unloaded'" | ||||||
|                       @maxValueChange="(actualValue) => {actualVolume = actualValue}"/> |                       @valueChange="(actualValue) => {actualVolume = actualValue}"/> | ||||||
|         <div class="title">{{loadingState === "loading" ? "Loading..." : title}}</div> |         <div class="title">{{loadingState === "loading" ? "Loading..." : title}}</div> | ||||||
|         <div class="youtube-player" ref="ytpl"/> |         <div class="youtube-player" ref="ytpl"/> | ||||||
|     </div> |     </div> | ||||||
|  |  | ||||||
|  | @ -22,9 +22,10 @@ export default class Channel extends Vue { | ||||||
|     this.onMaxValueChange(); |     this.onMaxValueChange(); | ||||||
|   } |   } | ||||||
| 
 | 
 | ||||||
|  |   @Watch("value") | ||||||
|   @Watch("maxValue") |   @Watch("maxValue") | ||||||
|   private onMaxValueChange() { |   private onMaxValueChange() { | ||||||
|     this.$emit("maxValueChange", this.value * (this.maxValue / 100), this.maxValue); |     this.$emit("valueChange", this.value * (this.maxValue / 100), this.maxValue); | ||||||
|   } |   } | ||||||
| }; | }; | ||||||
| </script> | </script> | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue