Skip to content

Commit 6e77e1b

Browse files
committed
updated graph layout
1 parent 144b39a commit 6e77e1b

File tree

2 files changed

+11
-12
lines changed

2 files changed

+11
-12
lines changed

app/api/repo/route.ts

+2-3
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ function processPythonSource(source_file) {
5252
function processClassDeclaration(source_file, match) {
5353
let class_node = match.captures[0].node;
5454
let class_name = match.captures[1].node.text;
55-
//console.log("Class node: " + class_node);
55+
console.log("Class node: " + class_node);
5656
console.log("Class name: " + class_name);
5757

5858
// Match all function definition within the current class
@@ -95,8 +95,7 @@ export async function POST(request: NextRequest) {
9595
// Tree-Sitter AST queries
9696
//-------------------------------------------------------------------------
9797

98-
function_call_query = Python.query(`((call function: (identifier) @function-name))`);
99-
//function_call_query = Python.query(`(call_expression function: (identifier) @function-name)`);
98+
function_call_query = Python.query(`((call function: (identifier) @function-name))`);
10099
class_definition_query = Python.query(`(class_definition name: (identifier) @class-name) @class-definition`);
101100
function_definition_query = Python.query(`(function_definition name: (identifier) @function-name) @function-definition`);
102101

app/page.tsx

+9-9
Original file line numberDiff line numberDiff line change
@@ -58,17 +58,17 @@ export default function Home() {
5858
gravity: 0.2
5959
},
6060
edges: graph.edges,
61-
emphasis: {
62-
focus: 'adjacency',
63-
label: {
64-
position: 'right',
65-
show: true
66-
}
67-
},
61+
//emphasis: {
62+
// focus: 'adjacency',
63+
// label: {
64+
// position: 'right',
65+
// show: true
66+
// }
67+
//},
6868
roam: true,
6969
lineStyle: {
70-
color: 'source',
71-
width: 3.0,
70+
//color: 'source',
71+
width: 1.5,
7272
curveness: 0.1,
7373
opacity: 0.7
7474
},

0 commit comments

Comments
 (0)