fix notification remove overflow bug
This commit is contained in:
parent
b0ac1ddc1e
commit
087e83940f
1 changed files with 6 additions and 8 deletions
|
@ -113,9 +113,7 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
processData: true
|
processData: true
|
||||||
)
|
)
|
||||||
|
|
||||||
onShow: =>
|
updateHeight: =>
|
||||||
@updateContent()
|
|
||||||
|
|
||||||
# set height of notification popover
|
# set height of notification popover
|
||||||
notificationsContainer = $('.js-notificationsContainer')
|
notificationsContainer = $('.js-notificationsContainer')
|
||||||
heightApp = $('#app').height()
|
heightApp = $('#app').height()
|
||||||
|
@ -131,6 +129,10 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
|
|
||||||
notificationsContainer.find('.popover-content').css('height', "#{heightPopoverContentNew}px")
|
notificationsContainer.find('.popover-content').css('height', "#{heightPopoverContentNew}px")
|
||||||
|
|
||||||
|
onShow: =>
|
||||||
|
@updateContent()
|
||||||
|
@updateHeight()
|
||||||
|
|
||||||
# mark all notifications as read
|
# mark all notifications as read
|
||||||
notificationsContainer.find('.js-markAllAsRead').on('click', (e) =>
|
notificationsContainer.find('.js-markAllAsRead').on('click', (e) =>
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
|
@ -221,7 +223,7 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
row = $(e.target).closest('.activity-entry')
|
row = $(e.target).closest('.activity-entry')
|
||||||
id = row.data('id')
|
id = row.data('id')
|
||||||
App.OnlineNotification.destroy(id)
|
App.OnlineNotification.destroy(id)
|
||||||
@resetHeight()
|
@updateHeight()
|
||||||
)
|
)
|
||||||
|
|
||||||
createContainer: =>
|
createContainer: =>
|
||||||
|
@ -254,7 +256,3 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
@counterUpdate(0)
|
@counterUpdate(0)
|
||||||
@toggle.popover('destroy')
|
@toggle.popover('destroy')
|
||||||
|
|
||||||
resetHeight: ->
|
|
||||||
notificationsContainer = $('.js-notificationsContainer')
|
|
||||||
notificationsContainer.find('.popover-content').css('height', 'auto')
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue