Skip to content

Conversation

@waleedlatif1
Copy link
Collaborator

Description

add loading logic for document selector for kb block, all other dropdowns had the same loading logic except this one

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Tested manually

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added tests that prove my fix is effective or that my feature works
  • All tests pass locally and in CI (bun run test)
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules
  • I have updated version numbers as needed (if needed)
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

Security Considerations:

  • My changes do not introduce any new security vulnerabilities
  • I have considered the security implications of my changes

@vercel
Copy link

vercel bot commented Jul 18, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sim 🔄 Building (Inspect) Visit Preview 💬 Add feedback Jul 18, 2025 5:48pm
1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
docs ⬜️ Skipped (Inspect) Jul 18, 2025 5:48pm

@waleedlatif1 waleedlatif1 merged commit fb5d5d9 into staging Jul 18, 2025
3 of 5 checks passed
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Greptile Summary

This PR adds loading state management to the document selector component in the knowledge base block. The change addresses an inconsistency where other dropdowns had loading indicators but this one did not. The implementation adds:

  • Loading state management using setLoading state
  • Error handling cleanup
  • Visual feedback during document loading with a spinning RefreshCw icon
  • Proper state cleanup in the finally block

This change brings the document selector in line with other dropdown components in the application, improving UI consistency and user experience.

Confidence score: 5/5

  1. This PR is extremely safe to merge as it follows established patterns
  2. The changes are minimal, focused, and mirror existing implemented loading logic across other dropdowns
  3. No files need special attention - the changes are straightforward and well-implemented

1 file reviewed, no comments
Edit PR Review Bot Settings | Greptile

@delve-auditor
Copy link

delve-auditor bot commented Jul 18, 2025

No security or compliance issues detected. Reviewed everything up to cbf6160.

Security Overview
  • 🔎 Scanned files: 1 changed file(s)
Detected Code Changes
Change Type Relevant files
Enhancement ► Block loading logic added for knowledge base document selector

Reply to this PR with @delve-auditor followed by a description of what change you want and we'll auto-submit a change to this PR to implement it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants