notifications.pug 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. if hasFeature('v2-banner')
  2. .userNotifications
  3. ul.list-unstyled.notifications-list(ng-controller="OverleafV2NotificationController", ng-show="visible")
  4. li.notification_entry
  5. .row
  6. .col-xs-12
  7. .alert.alert-info
  8. .notification_inner
  9. .notification_body(event-tracking="sees_v2_banner" event-tracking-mb="true" event-segmentation="{location: 'welcome', v2_onboard: true}" event-tracking-trigger="load" event-tracking-send-once="true")
  10. a.btn.btn-info.btn-sm.pull-right(event-tracking="go_to_v2" event-tracking-mb="true" event-segmentation="{location: 'welcome', v2_onboard: true}" event-tracking-trigger="click" href="/user/login_to_ol_v2") Try Overleaf v2
  11. | ShareLaTeX is joining Overleaf and will become <em>Overleaf v2</em> in late 2018 (<a event-tracking="click_v2_read_more" event-tracking-mb="true" event-segmentation="{location: 'welcome', v2_onboard: true}" event-tracking-trigger="click" href="https://www.overleaf.com/help/342-overleaf-v2-faq">read more</a>).
  12. <br/>
  13. | We’re beta testing Overleaf v2 now and you can try it out with your ShareLaTeX account.
  14. .notification_close
  15. button(ng-click="dismiss()" event-tracking="closes_v2_banner" event-tracking-mb="true" event-segmentation="{location: 'welcome', v2_onboard: true}" event-tracking-trigger="click").close.pull-right
  16. span(aria-hidden="true") &times;
  17. span.sr-only #{translate("close")}
  18. span(ng-controller="NotificationsController").userNotifications
  19. ul.list-unstyled.notifications-list(
  20. ng-if="notifications.length > 0",
  21. ng-cloak
  22. )
  23. li.notification_entry(
  24. ng-repeat="notification in notifications",
  25. )
  26. .row(ng-hide="notification.hide")
  27. .col-xs-12
  28. div(ng-switch="notification.templateKey")
  29. .alert.alert-info(ng-switch-when="notification_project_invite", ng-controller="ProjectInviteNotificationController")
  30. div.notification_inner
  31. .notification_body(ng-show="!notification.accepted")
  32. | !{translate("notification_project_invite_message")}
  33. a.pull-right.btn.btn-sm.btn-info(href, ng-click="accept()", ng-disabled="notification.inflight")
  34. span(ng-show="!notification.inflight") #{translate("join_project")}
  35. span(ng-show="notification.inflight")
  36. i.fa.fa-fw.fa-spinner.fa-spin
  37. | &nbsp;
  38. | #{translate("joining")}...
  39. .notification_body(ng-show="notification.accepted")
  40. | !{translate("notification_project_invite_accepted_message")}
  41. a.pull-right.btn.btn-sm.btn-info(href="/project/{{ notification.messageOpts.projectId }}") #{translate("open_project")}
  42. span().notification_close
  43. button(ng-click="dismiss(notification)").close.pull-right
  44. span(aria-hidden="true") &times;
  45. span.sr-only #{translate("close")}
  46. .alert.alert-info(ng-switch-when="notification_group_invite")
  47. div.notification_inner
  48. .notification_body
  49. | #{translate("invited_to_join_team")}: {{ notification.messageOpts.groupName }}
  50. a.pull-right.btn.btn-sm.btn-info(href="/user/subscription/domain/join")
  51. | #{translate("join_team")}
  52. span().notification_close
  53. button(ng-click="dismiss(notification)").close.pull-right
  54. span(aria-hidden="true") &times;
  55. span.sr-only #{translate("close")}
  56. .alert.alert-info(ng-switch-default)
  57. div.notification_inner
  58. span(ng-bind-html="notification.html").notification_body
  59. span().notification_close
  60. button(ng-click="dismiss(notification)").close.pull-right
  61. span(aria-hidden="true") &times;
  62. span.sr-only #{translate("close")}