feat: integrate AI-driven selection panel with context-aware text summarization and quiz generation features.
This commit is contained in:
@@ -6,13 +6,17 @@ public sealed class KnowledgeGraphService : IKnowledgeGraphService
|
||||
{
|
||||
public GraphDataDto? CurrentGraphData { get; private set; }
|
||||
public string? ActiveNodeId { get; private set; }
|
||||
public bool IsLoading { get; private set; }
|
||||
|
||||
public event Action? OnGraphUpdated;
|
||||
public event Action<string>? OnActiveNodeChanged;
|
||||
public event Action<bool>? OnLoadingChanged;
|
||||
|
||||
public void UpdateGraph(GraphDataDto newData)
|
||||
{
|
||||
CurrentGraphData = newData;
|
||||
IsLoading = false;
|
||||
OnLoadingChanged?.Invoke(false);
|
||||
OnGraphUpdated?.Invoke();
|
||||
}
|
||||
|
||||
@@ -22,4 +26,18 @@ public sealed class KnowledgeGraphService : IKnowledgeGraphService
|
||||
ActiveNodeId = nodeId;
|
||||
OnActiveNodeChanged?.Invoke(nodeId);
|
||||
}
|
||||
|
||||
public void SetLoading(bool isLoading)
|
||||
{
|
||||
IsLoading = isLoading;
|
||||
OnLoadingChanged?.Invoke(isLoading);
|
||||
}
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
CurrentGraphData = null;
|
||||
ActiveNodeId = null;
|
||||
IsLoading = false;
|
||||
OnGraphUpdated?.Invoke();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user