Skip to content

Commit 33673b8

Browse files
Rename hash component
1 parent 73fa84f commit 33673b8

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

packages/cursorless-org-docs/src/docs/components/ScrollToHash.tsx renamed to packages/cursorless-org-docs/src/docs/components/ScrollToHashId.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { useLocation } from "@docusaurus/router";
55
* Scrolls to the element with the ID matching the current hash in the URL.
66
* This is needed when a hash ID is provided in the initial load to scroll to a heading rendered by a react component.
77
*/
8-
export function ScrollToHash() {
8+
export function ScrollToHashId() {
99
const location = useLocation();
1010

1111
useEffect(() => {

packages/cursorless-org-docs/src/docs/contributing/scopes/components/Scopes.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import type { ScopeTypeType } from "@cursorless/common";
22
import React from "react";
33
import { DynamicTOC } from "../../../components/DynamicTOC";
44
import { ScopeVisualizer } from "../../../components/ScopeVisualizer";
5-
import { ScrollToHash } from "../../../components/ScrollToHash";
5+
import { ScrollToHashId } from "../../../components/ScrollToHashId";
66

77
interface Props {
88
scopeTypeType: ScopeTypeType;
@@ -12,7 +12,7 @@ export function Scopes({ scopeTypeType }: Props) {
1212
return (
1313
<>
1414
<DynamicTOC />
15-
<ScrollToHash />
15+
<ScrollToHashId />
1616

1717
<ScopeVisualizer scopeTypeType={scopeTypeType} />
1818
</>

packages/cursorless-org-docs/src/docs/user/languages/components/Language.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React from "react";
22
import { DynamicTOC } from "../../../components/DynamicTOC";
33
import { ScopeVisualizer } from "../../../components/ScopeVisualizer";
4-
import { ScrollToHash } from "../../../components/ScrollToHash";
4+
import { ScrollToHashId } from "../../../components/ScrollToHashId";
55

66
interface Props {
77
languageId: string;
@@ -11,7 +11,7 @@ export function Language({ languageId }: Props) {
1111
return (
1212
<>
1313
<DynamicTOC />
14-
<ScrollToHash />
14+
<ScrollToHashId />
1515

1616
<ScopeVisualizer languageId={languageId} />
1717
</>

0 commit comments

Comments
 (0)