Skip to content
This repository has been archived by the owner on Jan 19, 2023. It is now read-only.

Commit

Permalink
Merge pull request #21 from fehnkera/develop
Browse files Browse the repository at this point in the history
Add simple point up mechanics Issue #18
  • Loading branch information
holtwick committed Mar 21, 2020
2 parents 4101608 + aaa8e14 commit f1d5aa1
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
24 changes: 23 additions & 1 deletion src/components/app-chat.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
<!-- <button type="submit">Send message</button>-->
</div>
</form>
<form>
<button @click="pointOut" type ="submit"><img src="./img/aufzeigen.png" ref="pointPic" style=""></button>
</form>
</div>
</template>

Expand All @@ -21,13 +24,32 @@ import { sendChatMessage } from '../state'
export default {
name: 'app-chat',
data() {
return {}
return {pointsOut : false}
},
methods: {
doSend() {
sendChatMessage(this.message)
this.message = ''
},
pointOut() {
this.message = this.message //wtf, warning prevention...
let pic = this.$refs.pointPic
if(!this.pointsOut)
{
pic.style.backgroundColor = "orange"
sendChatMessage("*Zeigt auf!*")
this.pointsOut = true
}
else
{
pic.style.backgroundColor = ""
sendChatMessage("*Zeigt nicht mehr auf!*")
this.pointsOut = false
}
},
},
async mounted() {
Expand Down
Binary file added src/components/img/aufzeigen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/components/img/nicht_aufzeigen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit f1d5aa1

Please sign in to comment.