Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .changeset/remove-preload-intent-proximity.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
'@tanstack/router-core': patch
'@tanstack/react-router': patch
'@tanstack/solid-router': patch
'@tanstack/vue-router': patch
---

Remove the `preloadIntentProximity` link option and the `defaultPreloadIntentProximity` router option, which were never implemented.
1 change: 0 additions & 1 deletion packages/react-router/src/link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,6 @@ const ROUTER_OPTION_KEYS = /* @__PURE__ */ new Set([
'reloadDocument',
'preload',
'preloadDelay',
'preloadIntentProximity',
'hashScrollIntoView',
'replace',
'startTransition',
Expand Down
2 changes: 0 additions & 2 deletions packages/react-router/tests/link.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,6 @@ describe('Link', () => {
'from',
'preload',
'preloadDelay',
'preloadIntentProximity',
'hashScrollIntoView',
'replace',
'startTransition',
Expand Down Expand Up @@ -298,7 +297,6 @@ describe('Link', () => {
}}
preload="intent"
preloadDelay={50}
preloadIntentProximity={123}
hashScrollIntoView={true}
replace={true}
startTransition={true}
Expand Down
5 changes: 0 additions & 5 deletions packages/router-core/src/link.ts
Original file line number Diff line number Diff line change
Expand Up @@ -688,11 +688,6 @@ export interface LinkOptionsProps {
* @default false
*/
disabled?: boolean
/**
* When the preload strategy is set to `intent`, this controls the proximity of the link to the cursor before it is preloaded.
* If the user exits this proximity before this delay, the preload will be cancelled.
*/
preloadIntentProximity?: number
}

export type LinkOptions<
Expand Down
8 changes: 0 additions & 8 deletions packages/router-core/src/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -240,14 +240,6 @@ export interface RouterOptions<
* @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading#preload-delay)
*/
defaultPreloadDelay?: number
/**
* The default `preloadIntentProximity` a route should use if no preloadIntentProximity is provided.
*
* @default 0
* @link [API Docs](https://tanstack.com/router/latest/docs/framework/react/api/router/RouterOptionsType#defaultpreloadintentproximity-property)
* @link [Guide](https://tanstack.com/router/latest/docs/framework/react/guide/preloading#preload-intent-proximity)
*/
defaultPreloadIntentProximity?: number
/**
* The default `pendingMs` a route should use if no pendingMs is provided.
*
Expand Down
1 change: 0 additions & 1 deletion packages/solid-router/src/link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,6 @@ const LINK_OPTION_KEYS = [
'activeOptions',
'preload',
'preloadDelay',
'preloadIntentProximity',
'target',
'disabled',
'style',
Expand Down
2 changes: 0 additions & 2 deletions packages/solid-router/tests/link.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,6 @@ describe('Link', () => {
'from',
'preload',
'preloadDelay',
'preloadIntentProximity',
'hashScrollIntoView',
'replace',
'startTransition',
Expand Down Expand Up @@ -511,7 +510,6 @@ describe('Link', () => {
}}
preload="intent"
preloadDelay={50}
preloadIntentProximity={123}
hashScrollIntoView={true}
replace={true}
startTransition={true}
Expand Down
2 changes: 0 additions & 2 deletions packages/vue-router/src/link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,6 @@ const LINK_OPTION_KEYS = new Set<string>([
'activeOptions',
'preload',
'preloadDelay',
'preloadIntentProximity',
'children',
'target',
'disabled',
Expand Down Expand Up @@ -889,7 +888,6 @@ const LinkImpl = Vue.defineComponent({
'to',
'preload',
'preloadDelay',
'preloadIntentProximity',
'activeProps',
'inactiveProps',
'activeOptions',
Expand Down
2 changes: 0 additions & 2 deletions packages/vue-router/tests/link.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,6 @@ describe('Link', () => {
'from',
'preload',
'preloadDelay',
'preloadIntentProximity',
'hashScrollIntoView',
'replace',
'startTransition',
Expand Down Expand Up @@ -385,7 +384,6 @@ describe('Link', () => {
}}
preload="intent"
preloadDelay={50}
preloadIntentProximity={123}
hashScrollIntoView={true}
replace={true}
startTransition={true}
Expand Down
Loading