Live data from Hacker News

Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

chromestory.com

11–20 of 332 posts

Re: Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

#11
Great feature and a pretty straightforward polyfill, could even be implemented before Chrome releases it (the context menu to get the link being the hard part, but a select text + tooltip with "Copy link to this text" would work, or I'm pretty sure good designers will find great UIs for it, might even normalizes as a new pattern)

Re: Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

#13
post #9

Very significant limitation: it only links to the first instance of the target text. What is the expected behavior if you highlight a second instance of some target text and try to create a link to it? It’s bad that the spec doesn’t discuss it. I can see this happening with short selections, like linking to a single word. Seems like this could use more thought.

Doesn’t the spec specify, that the link points to the first instance of the selected text? Does that not accurately define what happens when you try to link to a latter instance: It links to the first one.

Re: Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

#15
post #4

Almost caught up to the capabilities of Ted Nelsons Xanadu Hypertext System from the mid 20th century.

I was just seeing a documentary about him (the Internet actually) by Werner Herzog. It was the first time I had heard about Xanadu or Ted Nelson. His ideas were quite radical from what I know as the Web. And I got to thinking how the web might have been had Xanadu become mainstream.

But then I opened the Wikipedia page on Project Xanadu, it's second paragraph is:

> Wired magazine published an article called "The Curse of Xanadu", calling Project Xanadu "the longest-running vaporware story in the history of the computer industry".[2] The first attempt at implementation began in 1960, but it was not until 1998 that an incomplete implementation was released. A version described as "a working deliverable", OpenXanadu, was made available in 2014.

So... I don't know what to make of it.

Re: Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

#17
post #14

It seems like more and more, Google is leveraging their near-monopoly on web browsing to just skip the proposal process and do whatever they want without discussion.

in this case it looked OK

> Though existing HTML support for id and name attributes specifies the target element directly in the fragment, most other mime types make use of this x=y pattern in the fragment, such as Media Fragments (e.g. #track=audio&t=10,20), PDF (e.g. #page=12) or CSV (e.g. #row=4).

fragments is already there but most pages do not have a clickable ID attribute. If Chrome could automatically provide one I think it's more convenient than F12 a devtool for links.

Re: Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

#18
post #9

Very significant limitation: it only links to the first instance of the target text. What is the expected behavior if you highlight a second instance of some target text and try to create a link to it? It’s bad that the spec doesn’t discuss it. I can see this happening with short selections, like linking to a single word. Seems like this could use more thought.

Although you are right, it's already how browsers work in relation to IDs - only the first element with that ID is selected. (Yes, IDs are supposed to be unique, but it's not like HTML "breaks" if you don't follow this rule).

Plus, you can always select more text.

Re: Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

#19
post #14

It seems like more and more, Google is leveraging their near-monopoly on web browsing to just skip the proposal process and do whatever they want without discussion.

It’s almost as if Google is the new Microsoft!

Re: Chrome will Soon Let You Share Links to a Specific Word or Sentence on a Page

#20
post #6

Is this going to lead to an api of # for different scrolling to behavior? Also, what happens if the page already has an anchor text that happens to be the exact match? i.e. #targetText=My%20Heading is already an existing anchor

Then the = should be encoded as %23 in the URL and should not be interpreted as #targetText=
Post reply on HN