messages-page.html 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. <div class="messages-page">
  2. <div class="messages-page-wrapper">
  3. <div class="select-dialog">
  4. <div class="item" ng-class="{'item-active': key == selectedUser}" ng-click="selectUser(key)" ng-repeat="(key, user) in users" ng-if="key != 'uRkqD9GmNxUsdgF1XtmPicDJwAz1'">
  5. <div class="item-img">
  6. <img ng-src="{{userImages[key]}}">
  7. <img ng-if="!userImages[key]" ng-src="content\images\user-page\male-user-silhouette_318-35708.jpg">
  8. </div>
  9. <div class="item-name">
  10. {{user.userObject.name || 'user' + $index}} {{user.userObject.surname || ''}}
  11. </div>
  12. </div>
  13. </div>
  14. <div class="dialog">
  15. <div class="chat">
  16. <div ng-class="message.uid == 'uRkqD9GmNxUsdgF1XtmPicDJwAz1'?'admin-message':'user-message'" ng-repeat="message in users[selectedUser].chat">
  17. <div class="message-info">
  18. <div class="message-img">
  19. <img ng-if="(message.uid != 'uRkqD9GmNxUsdgF1XtmPicDJwAz1') && userImages[selectedUser]" ng-src="{{userImages[selectedUser]}}">
  20. <img ng-if="(message.uid != 'uRkqD9GmNxUsdgF1XtmPicDJwAz1') && !userImages[selectedUser]" src="content\images\user-page\male-user-silhouette_318-35708.jpg">
  21. <img ng-if="message.uid == 'uRkqD9GmNxUsdgF1XtmPicDJwAz1'" src="content\images\user-page\admin.png">
  22. </div>
  23. <div class="message-date">
  24. {{message.date}}
  25. </div>
  26. </div>
  27. <div class="message-text-wrapper">
  28. <div class="message-name">
  29. <div ng-if="message.uid != 'uRkqD9GmNxUsdgF1XtmPicDJwAz1'">
  30. {{users[selectedUser].userObject.name}} {{users[selectedUser].userObject.surname}}
  31. </div>
  32. <div ng-if="message.uid == 'uRkqD9GmNxUsdgF1XtmPicDJwAz1'">
  33. Admin
  34. </div>
  35. </div>
  36. <div class="message-text">
  37. {{message.userMessage}}
  38. </div>
  39. </div>
  40. </div>
  41. </div>
  42. <div class="write-message">
  43. <div class="write-input">
  44. <input type="text" placeholder="Type your message..." ng-model="messageObject.userMessage">
  45. </div>
  46. <div class="write-btn">
  47. <div class="write-btn-wrapper" ng-click="sendMessage()">
  48. <span class="fa fa-paper-plane"></span>
  49. </div>
  50. </div>
  51. </div>
  52. </div>
  53. </div>
  54. </div>