Skip to content

Commit

Permalink
Feat:Add feedback button
Browse files Browse the repository at this point in the history
  • Loading branch information
littlestar642 committed Feb 24, 2018
1 parent 042458e commit db7c092
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 1 deletion.
7 changes: 7 additions & 0 deletions public/css/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
margin-bottom: 2.5px;
margin-top: 2.5px;
}
.feed{
font-size: 2em;
}

.white-text {
color: white;
Expand Down Expand Up @@ -72,8 +75,12 @@

.ui.mini.modal {
margin-top: -5%;
text-align: center;
}

#feedBtn{
margin-left:10px;
}
#msgs .one .right,
#msgs .one .left {
position: relative;
Expand Down
11 changes: 10 additions & 1 deletion public/js/chat.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
let newbtn = document.querySelector('#newbtn');
let close = document.querySelector('#close');
let cancel = document.querySelector('#cancel');
let cancelFeed = document.querySelector('#cancelFeed');
socket.emit('privateRoom', {
"room": "private room"
});
Expand Down Expand Up @@ -85,12 +86,20 @@
let confirm = document.querySelector('#confirm');
confirm.classList.add('visible');
});
feedBtn.addEventListener('click', () => {
let feedback = document.querySelector('#feedback');
feedback.classList.add('visible');
});

cancel.addEventListener('click', () => {
let confirm = document.querySelector('#confirm');
confirm.classList.remove('visible');
});

cancelFeed.addEventListener('click', () => {
let confirmFeedback = document.querySelector('#feedback')
confirmFeedback.classList.remove('visible');
});

close.addEventListener('click', () => {
let confirm = document.querySelector('#confirm');
message.classList.add('hide');
Expand Down
18 changes: 18 additions & 0 deletions views/chat.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@
<i class="fitted send icon"></i>
<span class="txt">Send</span>
</button>
<button class="ui teal labeled icon button" id="feedBtn">
<i class="user icon"></i>
<span class="txt">Feedback</span>
</button>
<a href="/">
<button class="ui red icon button right-float hide" id="homebtn">
<span>Home</span>
Expand All @@ -70,6 +74,20 @@
</div>
</div>
</div>
<div class="ui mini modal transition tada" id="feedback">
<div class="header sty">
Did Something Happened?
</div>
<div class="content sty">
<p> &#128562; Trouble Encountered &#128562;</p>
<p><a target="_blank" href="https://github.com/wdlsvnit/omeclone/issues">Click Here</a> &#10165; Submit your issue &#10165; We will take care</p>
</div>
<div class="actions">
<div class="ui teal button" id="cancelFeed">
Return To Chat
</div>
</div>
</div>
</body>
<script src="/bower_components/Autolinker.js/dist/Autolinker.min.js"></script>
<script src="/bower_components/jquery/dist/jquery.min.js"></script>
Expand Down

0 comments on commit db7c092

Please sign in to comment.