@@ -362,8 +362,8 @@ def add_bookmark_via_toolbar_other_bookmark_context_menu(
362
362
) -> BasePage :
363
363
"""
364
364
Add a bookmark via the toolbar's Other Bookmarks context menu.
365
- Arguments
366
- ----------
365
+
366
+ Arguments:
367
367
bookmark_data : A Bookmark object containing the bookmark details to be added (name, url, tags, keyword)
368
368
ba : BrowserActions utility
369
369
"""
@@ -386,8 +386,9 @@ def add_bookmark_via_toolbar_other_bookmark_context_menu(
386
386
387
387
@BasePage .context_chrome
388
388
def toggle_bookmarks_toolbar_with_key_combo (self ) -> BasePage :
389
- """Use Cmd/Ctrl + B to open the Print Preview, wait for load"""
390
-
389
+ """
390
+ Use Cmd/Ctrl + B to open the Print Preview, wait for load
391
+ """
391
392
if self .sys_platform () == "Darwin" :
392
393
mod_key = Keys .COMMAND
393
394
else :
@@ -433,8 +434,8 @@ def delete_bookmark_from_other_bookmarks_via_context_menu(
433
434
) -> BasePage :
434
435
"""
435
436
Deletes a bookmark from Other Bookmarks via context menu.
437
+
436
438
Argument:
437
- ----------
438
439
bookmark_name: The display name of the bookmark to delete
439
440
"""
440
441
self .click_on ("other-bookmarks-toolbar" )
@@ -446,8 +447,8 @@ def delete_bookmark_from_other_bookmarks_via_context_menu(
446
447
def delete_bookmark_from_bookmarks_toolbar (self , bookmark_name : str ) -> BasePage :
447
448
"""
448
449
Delete bookmark from bookmarks toolbar via context menu
450
+
449
451
Argument:
450
- ----------
451
452
bookmark_name: The display name of the bookmark to delete
452
453
"""
453
454
self .panel_ui .context_click ("bookmark-by-title" , labels = [bookmark_name ])
@@ -460,8 +461,8 @@ def verify_bookmark_exists_in_toolbar_other_bookmarks_folder(
460
461
) -> BasePage :
461
462
"""
462
463
Verify bookmark exists in Other Bookmarks folder from toolbar
463
- Arguments
464
- ----------
464
+
465
+ Argument:
465
466
bookmark_name : The exact name/title of the bookmark to search for in the Other Bookmarks folder.
466
467
"""
467
468
self .click_on ("other-bookmarks-toolbar" ) # Navigation selector
@@ -486,8 +487,8 @@ def verify_bookmark_does_not_exist_in_toolbar_other_bookmarks_folder(
486
487
) -> BasePage :
487
488
"""
488
489
Verify bookmark does not exist in Other Bookmarks folder from toolbar
489
- Arguments
490
- ----------
490
+
491
+ Argument:
491
492
bookmark_name : The exact name/title of the bookmark to search for in the Other Bookmarks folder.
492
493
"""
493
494
self .click_on ("other-bookmarks-toolbar" )
@@ -508,12 +509,10 @@ def verify_bookmark_does_not_exist_in_bookmarks_toolbar(
508
509
def edit_bookmark_via_star_button (self , new_name : str , location : str ) -> BasePage :
509
510
"""
510
511
Edit bookmark details by opening the edit bookmark panel via the star button
511
- Arguments
512
- ----------
513
- new_name : str
514
- The new name/title to assign to the bookmark
515
- location : str
516
- The folder location where the bookmark should be saved
512
+
513
+ Arguments:
514
+ new_name : The new name/title to assign to the bookmark
515
+ location : The folder location where the bookmark should be saved
517
516
"""
518
517
self .click_on ("star-button" )
519
518
self .panel_ui .get_element ("edit-bookmark-panel" ).send_keys (new_name )
@@ -523,6 +522,7 @@ def edit_bookmark_via_star_button(self, new_name: str, location: str) -> BasePag
523
522
elif location == "Bookmarks Toolbar" :
524
523
self .panel_ui .click_on ("bookmark-location" )
525
524
self .panel_ui .click_on ("bookmarks-toolbar" )
525
+ # for else add Bookmark Menu option if needed in the future
526
526
self .panel_ui .click_on ("save-bookmark-button" )
527
527
return self
528
528
@@ -549,7 +549,8 @@ def verify_edit_bookmark_panel_not_visible_after_navigation(self) -> BasePage:
549
549
def open_bookmark_from_toolbar (self , bookmark_title : str ) -> BasePage :
550
550
"""
551
551
Right-clicks bookmark and opens it in a new private window via context menu
552
- Arguments:
552
+
553
+ Argument:
553
554
bookmark_title: The title of the bookmark to open
554
555
"""
555
556
self .panel_ui .element_clickable ("bookmark-by-title" , labels = [bookmark_title ])
@@ -562,7 +563,8 @@ def open_bookmark_in_new_window_via_context_menu(
562
563
) -> BasePage :
563
564
"""
564
565
Right-click bookmark and opens it in a new window via context menu
565
- Arguments:
566
+
567
+ Argument:
566
568
bookmark_title: The title of the bookmark to open
567
569
"""
568
570
self .panel_ui .element_clickable ("bookmark-by-title" , labels = [bookmark_title ])
@@ -576,7 +578,8 @@ def open_bookmark_in_new_private_window_via_context_menu(
576
578
) -> BasePage :
577
579
"""
578
580
Right-clicks bookmark and opens it in a new private window via context menu
579
- Arguments:
581
+
582
+ Argument:
580
583
bookmark_title: The title of the bookmark to open
581
584
"""
582
585
self .panel_ui .element_clickable ("bookmark-by-title" , labels = [bookmark_title ])
@@ -598,8 +601,7 @@ def expect_bookmarks_toolbar_visibility(self, expected: bool) -> None:
598
601
"""
599
602
Assert the visibility state of the Bookmarks Toolbar.
600
603
601
- Arguments:
602
- ----------
604
+ Argument:
603
605
expected (bool):
604
606
If True, asserts that the toolbar is visible (collapsed="false").
605
607
If False, asserts that the toolbar is hidden (collapsed="true")
0 commit comments