Class LinkSelectorModal


  • public class LinkSelectorModal
    extends BaseElement
    Page object for the CKEditor link selection modal.
    Since:
    15.0RC1, 14.10.3
    Version:
    $Id: 93d7ecb532cbe8fac3c572871ca0e7a2cb8db188 $
    • Constructor Detail

      • LinkSelectorModal

        public LinkSelectorModal()
    • Method Detail

      • setResourceValue

        public LinkSelectorModal setResourceValue​(String value)
        Set the given value on the resource value search field.
        Parameters:
        value - the value to use to search for a resource (i.e., page or attachment)
        Returns:
        the current page object
      • selectPageItem

        public LinkSelectorModal selectPageItem​(String hint,
                                                String label)
        Click on one of the choices proposed in the dropdown after using setResourceValue(String), based on its hint and label.
        Parameters:
        hint - the hint of the resource (e.g, "ParentSpace / ChildSpace" for a page)
        label - the label of the resource (e.g., "PageName" for a page, or the attachment name for an attachment)
        Returns:
        the current page object
        Throws:
        NoSuchElementException - in case of issue when looking for the item by its hint and label
      • clickOK

        public void clickOK()
        Click on the "OK" button of the modal.
      • setResourceType

        public LinkSelectorModal setResourceType​(String resourceType)
        Select a resource type for the resource picker (e.g., "doc", or "attachment").
        Parameters:
        resourceType - the resource type to select
        Returns:
        the current page object