Comments (3)
While the spec does recommend to prefer exact searches over context-based searches, it also recommends that "[a]bove this limit [of 300 characters], the UA should encode the string as a range-based match". In the extension, currently, for the sake of shorter URLs, we experiment with 100 characters, and it seems to work well enough.
The majority of use cases, unlike yours, aims at being resistant to minor text changes. Adding a second context menu entry is not desirable, since it would confuse most users.
My suggestion would be to clone the code from the GitHub repository, make the change to bump the limit to >=300 characters, and install the extension locally:
- Open the Extension Management page by navigating to
chrome://extensions
. - Enable Developer Mode by clicking the toggle switch next to Developer mode.
- Click the LOAD UNPACKED button and select the cloned extension directory.
from link-to-text-fragment.
Before I go create a new extension I had an idea:
What about setting up an extension option to set the number of characters threshold to transition from exact searched to context-based ones?
It could default to 100 and could be set to as low as 0 to basically disable exact searches (assuming that's applicable here) and could have no real max value but if someone sets it to something greater than or equal to 300 then they get a warning message explaining the situation.
For my use case I think I wouldn't need more than 300 characters so maybe the option is limited to that but I'm not sure it's really necessary to limit it to less than 300 either.
Thank you.
from link-to-text-fragment.
I understand the desire to have such a setting, but since it's a power user feature that makes providing help to regular users harder (since you never know what they changed), I am very reluctant to add this.
Instead, I encourage you to just clone the extension and make your adjustments, it's all Apache 2.0 licensed and therefore completely OK to even release your clone on the Chrome Web Store.
from link-to-text-fragment.
Related Issues (20)
- Fragment + directive-delimited URIs don't function. HOT 3
- Duplicates selected text into clipboard (instead of URI) at specific URI. HOT 4
- Broken formatting of `<ul>` in `Reddit.com` comments. HOT 1
- Doesn't work on large pages. HOT 1
- Issues.
- Dashes in selected text to create link from HOT 1
- Selection Error -- 'Couldn't create a unique link, please select a longer sequence of words' HOT 1
- Provide a method for generating a method from a range instead of a selection HOT 2
- Unable to link to text inside table HOT 2
- Incompatible encoding (`-`, `&`, `,`) HOT 1
- Provide progress indicator. HOT 6
- [feature-request] add to mobile/android HOT 4
- Doesn't work for Safari Version 16.6 (18615.3.12.11.2) HOT 1
- Do not remove pre-existent `#.*:` section of URI. HOT 3
- Copied Link to Selected Text Appearing as a Link Rather Than the Text HOT 1
- Text fragment link converts upper-case to lower-case in Firefox HOT 1
- Does not work on Firefox anymore HOT 5
- Always timeouts on certain websites HOT 1
- Does not work on the United Nations Code for Trade and Transport Locations location list. HOT 2
- Doesn't work on `https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry`. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from link-to-text-fragment.