mirror of
https://github.com/discourse/discourse.git
synced 2025-05-28 13:51:18 +08:00
UX: multiple drafts menu improvements (#31195)
This change includes the following updates: - Rename view all to view all drafts - Remove view all link from drop-down when all drafts are displayed in the menu - Different icon for draft topics and PMs (adds envelope for PMs) - Disable drop-down when New Topic button is disabled (private categories etc) - Improve drafts drop-down loading (no longer disables the trigger btn on click)
This commit is contained in:
@ -13,6 +13,10 @@ module PageObjects
|
||||
has_no_css?(MENU_SELECTOR + "-trigger")
|
||||
end
|
||||
|
||||
def disabled?
|
||||
find(MENU_SELECTOR + "-trigger")["disabled"]
|
||||
end
|
||||
|
||||
def open?
|
||||
has_css?(MENU_SELECTOR + "-content")
|
||||
end
|
||||
@ -21,6 +25,14 @@ module PageObjects
|
||||
has_no_css?(MENU_SELECTOR + "-content")
|
||||
end
|
||||
|
||||
def has_view_all_link?
|
||||
has_css?(MENU_SELECTOR + "-content .view-all-drafts")
|
||||
end
|
||||
|
||||
def has_no_view_all_link?
|
||||
has_no_css?(MENU_SELECTOR + "-content .view-all-drafts")
|
||||
end
|
||||
|
||||
def open
|
||||
find(MENU_SELECTOR + "-trigger").click
|
||||
end
|
||||
|
Reference in New Issue
Block a user