Skip to content

Implement "the rules for choosing a browsing context" #20673

Closed

Description

@gterzian

Take 'target' into account when following the hyperlink (and perhaps also other small changes, it seems the labeling of some steps needs updating and others seems to be missing).

Loading the url in a target in a different browsing context seems to be blocked by #13241(but I'm wondering if that should only be if it's in a new 'top level browsing context'? Can we still follow the hyperlink in a iframe of the current page, like is necessary for the test below?).

Spec: https://html.spec.whatwg.org/multipage/links.html#following-hyperlinks-2

Code:

pub fn follow_hyperlink(subject: &Element, hyperlink_suffix: Option<String>, referrer_policy: Option<ReferrerPolicy>) {

test: https://github.com/servo/servo/blob/05fe8fa08d507836ce5659ff56f83022a90b241a/tests/wpt/web-platform-tests/html/browsers/browsing-the-web/navigating-across-documents/007.html

Activity

  1. changed the title [-]Improve Spec compliance of "follow hyperlink"[/-] [+]Improve spec compliance of "follow hyperlink"[/+] on Apr 21, 2018
  2. changed the title [-]Improve spec compliance of "follow hyperlink"[/-] [+]Implement "the rules for choosing a browsing context"[/+] on Apr 22, 2018
  3. gterzian commented on Apr 22, 2018

    @gterzian
    MemberAuthor

    On second thoughts, I think this issue is more about implementing https://html.spec.whatwg.org/multipage/browsers.html#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name, which is useful in other places besides the anchorelement, such as forms, see

    let _target = submitter.target();

    so I propose to do that, and then plug it both into forms and anchors.

  4. gterzian commented on Apr 22, 2018

    @gterzian
    MemberAuthor

    Would such a choose_browsing_context method belong perhaps on WindowProxy?

  5. added 5 commits that reference this issue on Apr 27, 2018
    ad4c78e
    c6d4d56
    ff5130d
    0c3045c
    14d3e40
  6. added 4 commits that reference this issue on Jun 6, 2018
    412148e
    ccaedd6
    31779c0
    c3c9490
  7. added a commit that references this issue on Jul 19, 2018
    6730bf6
  8. added 3 commits that reference this issue on Aug 10, 2018
    2c09e0d
    7d04e61
    9c24c16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions