-
Notifications
You must be signed in to change notification settings - Fork 3.3k
fix: BROS-193: Follow up fixes #8057
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
Conversation
… anything changed
✅ Deploy Preview for label-studio-storybook ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for heartex-docs canceled.
|
✅ Deploy Preview for label-studio-docs-new-theme canceled.
|
✅ Deploy Preview for label-studio-playground ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #8057 +/- ##
===========================================
+ Coverage 70.49% 70.51% +0.01%
===========================================
Files 719 719
Lines 51356 51366 +10
Branches 8729 8733 +4
===========================================
+ Hits 36205 36219 +14
+ Misses 15148 15144 -4
Partials 3 3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
/git merge
|
|
/fmt |
This pull request introduces updates to the
StorageProviderFormand related components, focusing on improving edit mode handling, validation logic, and error display. Key changes include enhancements to provider configuration, the addition of debug logging, and adjustments to schema handling for optional fields.Improvements to edit mode handling:
web/libs/app-common/src/blocks/StorageProviderForm/hooks/useStorageForm.ts: Added logic to wait for provider registry initialization and debug logging for missing provider configurations in edit mode. Updated form data initialization to handle optional fields more robustly. [1] [2] [3]web/libs/app-common/src/blocks/StorageProviderForm/index.tsx: Updatedtypestate initialization to use storage type or provider in edit mode. Added synchronization offormData.providerwithtypein edit mode. [1] [2]Validation and schema enhancements:
web/libs/app-common/src/blocks/StorageProviderForm/types/provider.ts: Adjusted schema generation to make optional fields nullable and optional, improving handling of null values from the server.web/libs/app-common/src/blocks/StorageProviderForm/hooks/useStorageForm.ts: Simplified validation reset logic to trigger on any field change instead of specific connection fields.Error handling and display improvements:
web/libs/app-common/src/blocks/StorageProviderForm/index.tsx: Added anInlineErrorcomponent for better error visibility in the form UI.web/libs/app-common/src/blocks/StorageProviderForm/components/field-renderer.tsx: Updated error-related CSS class to use a more descriptive name (border-negative-content).Provider configuration updates:
web/libs/app-common/src/blocks/StorageProviderForm/providers.ts: Ensured provider names are stored in lowercase in the registry for consistency.web/libs/app-common/src/blocks/StorageProviderForm/hooks/useStorageForm.ts: Added support for theproviderRegistryto manage dynamic provider configurations.Removed redundant code:
web/libs/app-common/src/blocks/StorageProviderForm/Steps/preview-step.tsx,provider-details-step.tsx: Removed unusedInlineErrorimports and instances. [1] [2] [3] [4]web/libs/app-common/src/blocks/StorageProviderForm/components/provider-grid.stories.tsx: Removed outdated Storybook stories forProviderGrid.