-
Notifications
You must be signed in to change notification settings - Fork 537
Initial API Explorer Feature Implementation PR #837
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
BalaSubramaniam12007
wants to merge
26
commits into
foss42:main
Choose a base branch
from
BalaSubramaniam12007:api_explorer
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Initial API Explorer Feature Implementation PR #837
BalaSubramaniam12007
wants to merge
26
commits into
foss42:main
from
BalaSubramaniam12007:api_explorer
Conversation
This file contains hidden or 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
… functionality - Added ExplorerPage with structured layout - Implemented ExplorerHeader with title and import button - Created ExplorerBody containing a responsive ApiSearchBar and placeholder content - Built reusable ApiSearchBar widget with clear and change handlers - Set up modular file structure for future API Explorer development Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
-Introduced ApiTemplate, Info, and Request model classes to represent structured API template data. -Added TemplateCard, CardTitle, and CardDescription UI components for rendering API templates. -Implemented TemplatesService to dynamically load .json templates from asset directory. -Updated ExplorerBody to fetch and display API templates using a responsive grid layout. Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
- Refactored ExplorerPage to a StatefulWidget to support navigation - Introduced _showDescription state to conditionally switch between explorer and description views - Implemented DescriptionPage as a new UI component for viewing API details - Added DescriptionHeader with back navigation functionality - Created DescriptionBody which includes MethodPane and DescriptionPane - Modified ExplorerBody to accept onCardTap callback and pass it to TemplateCard tap action Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
…Template to TemplateCard, enhance DescriptionHeader with info.description and tags, fix overflow error - Updated explorer_model.dart to replace custom Request with RequestModel from apidash_core, ensuring mock data compatibility. - Modified ExplorerBody and TemplateCard to pass ApiTemplate, preserving card UI (title, description, icon). - Enhanced DescriptionPage and DescriptionHeader to display info.title, description, and tags with smaller font, maintaining theme consistency. - Fixed 50-pixel overflow in DescriptionHeader by removing fixed height in DescriptionPage. Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
…nBody to display scrollable request list - Created requests_card.dart with RequestCard widget to display request title. - Renamed method_pane.dart to request_pane.dart and MethodPane to RequestsPane, implementing scrollable ListView of RequestCard. Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
…d button placeholder feat: integrate UrlCard into DescriptionPane with request selection support fix: adjust MethodWidget to show HTTPVerb as GET, PUT instead of enum names
- Extracted HTTP method display into a reusable MethodChip widget - Styled MethodChip with method-specific colors and rounded borders - Updated UrlCard to use MethodChip instead of inline MethodWidget Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
- Created chip.dart with CustomChip to replace MethodChip and unify styling - Updated UrlCard and RequestBodyCard to use new chip implementations Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
…isplay - Added CustomChip.tag factory method in chip.dart to centralize tag styling. - Updated TemplateCard to use CustomChip.tag for displaying tags in a single line. Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
…ormance - Created import.dart to extract HttpRequestModel from RequestModel for importing requests. - Modified description_pane.dart to pass RequestModel to UrlCard for integration. - Updated url_card.dart to include an Import button supporting request addition via CollectionStateNotifier. - Optimized the import process for better performance and null safety. Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
Ensured consistent width across cards with SizedBox Maintained 3:5:2 height ratio and responsiveness Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
…e left in RequestsCard Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
@ashitaprasad @animator I have submitted my initial pull request (PR). Some parts of the proof of concept (POC) are still pending, and I am actively working on them. I plan to complete and submit the remaining work by around May 1. |
…ement - Implemented TemplatesService to load mock templates and fetch from GitHub. - Added templatesProvider for reactive state management in ExplorerBody. - Created FetchTemplatesButton with SnackBar feedback for fetch status Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
- Added kTemplatesBox in hive_service.dart to store templates separately. - Updated TemplatesService to append fetched templates to mocks in Hive. - Enhanced templatesProvider to track cached state for UI updates. Signed-off-by: Balasubramaniam12007 <balasubramaniam12007@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is the initial PR for the API Explorer feature in APIDash. It establishes the foundation for browsing and using API templates within the application. As described in
explorerreadme.md
, this PR implements:apidash_core
package for consistencyThe implementation uses mock JSON data stored in
lib/screens/explorer/api_templates/mock
and themulti_split_view
package for the resizable split view layout.Related Issues
Checklist
main
branch before making this PRflutter upgrade
and verify)flutter test
) and all tests are passingAdded/updated tests?
OS on which you have developed and tested the feature?
Implementation Overview
As detailed in
explorerreadme.md
, this PR introduces:Key Components
Models:
lib/models/explorer_model.dart
: DefinesApiTemplate
andInfo
classes with JSON serialization/deserializationRequestModel
,HttpRequestModel
, andHttpResponseModel
fromapidash_core
Services:
lib/services/templates_service.dart
: Handles loading templates from mock JSON files with methods likeloadTemplates()
Data Flow
ExplorerPage
watches thetemplateListProvider
for template dataTemplatesService
loads JSON templates from mock filesApiTemplate
objectsNext Steps
As outlined in the
explorerreadme.md
future checklist, follow-up PRs will address:ApiSearchBar
Screenshots