forked from stakwork/sphinx-nav-fiber
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request stakwork#2490 from stakwork/feature/scrapper
feat: add scrapper
- Loading branch information
Showing
7 changed files
with
57 additions
and
139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,6 @@ | ||
import { GraphStyle } from '~/stores/useDataStore' | ||
import { generateEarthGraphPositions } from '~/transformers/earthGraph' | ||
import { generateForceGraphPositions } from '~/transformers/forceGraph' | ||
import { generateSphereGraphPositions } from '~/transformers/sphereGraph' | ||
import { generateSplitGraphPositions } from '~/transformers/splitGraph' | ||
import { GraphData, Link, NodeExtended } from '~/types' | ||
|
||
export const shouldIncludeTopics = true | ||
export const maxScale = 26 | ||
import { GraphData } from '~/types' | ||
|
||
export const defaultData: GraphData = { | ||
links: [], | ||
nodes: [], | ||
} | ||
|
||
export const getGraphDataPositions = (graphStyle: GraphStyle, nodes: NodeExtended[], links: Link[]) => { | ||
// give nodes and links positions based on graphStyle | ||
if (graphStyle === 'split') { | ||
return generateSplitGraphPositions(nodes, links) | ||
} | ||
|
||
if (graphStyle === 'sphere') { | ||
return generateSphereGraphPositions(nodes) | ||
} | ||
|
||
if (graphStyle === 'earth') { | ||
return generateEarthGraphPositions(nodes) | ||
} | ||
|
||
return generateForceGraphPositions(nodes, links) | ||
} |
This file was deleted.
Oops, something went wrong.