Skip to content
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

[1.3.1 Bug fixes] Field visibility improvements #3154

Merged
merged 15 commits into from
Jun 10, 2023
Merged

Conversation

manivoxel51
Copy link
Contributor

@manivoxel51 manivoxel51 commented Jun 1, 2023

What changes are proposed in this pull request?

  • Field visibility selection mode is the default
  • schema search help text removing stray #s
  • use selectFields(metadata="foo") when in filter rule mode (continue using exclude_fields() in selection mode)
  • remove line number from search help text
  • Refactored schema controls
  • Add documentation icon/link to custom colors and field visibility modals
  • uncheck subpaths when parent path is unchecked even if the subpaths are disabled
Screen Shot 2023-06-06 at 1 22 08 PM Screen Shot 2023-06-06 at 1 21 32 PM

How is this patch tested? If it is not, please explain why.

(Details)

Release Notes

Is this a user-facing change that should be mentioned in the release notes?

  • No. You can skip the rest of this section.
  • Yes. Give a description of this change to be included in the release
    notes for FiftyOne users.

(Details in 1-2 sentences. You can just refer to another PR with a description
if this PR is part of a larger change.)

What areas of FiftyOne does this PR affect?

  • App: FiftyOne application changes
  • Build: Build and test infrastructure changes
  • Core: Core fiftyone Python library changes
  • Documentation: FiftyOne documentation changes
  • Other

manivoxel51 added 2 commits June 1, 2023 12:20
@codecov
Copy link

codecov bot commented Jun 1, 2023

Codecov Report

Patch coverage: 9.96% and project coverage change: -34.14 ⚠️

Comparison is base (7d769e4) 49.25% compared to head (423c01b) 15.12%.

Additional details and impacted files
@@             Coverage Diff              @@
##           develop    #3154       +/-   ##
============================================
- Coverage    49.25%   15.12%   -34.14%     
============================================
  Files          230      560      +330     
  Lines        34424    68959    +34535     
  Branches       325      597      +272     
============================================
- Hits         16956    10428     -6528     
- Misses       17468    58531    +41063     
Flag Coverage Δ
app 15.12% <9.96%> (-34.14%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...ages/core/src/components/ColorModal/ColorModal.tsx 0.00% <0.00%> (ø)
...s/core/src/components/ColorModal/ShareStyledDiv.ts 0.00% <0.00%> (ø)
...es/core/src/components/Schema/SchemaSearchHelp.tsx 0.00% <0.00%> (ø)
...ore/src/components/Schema/SchemaSelectControls.tsx 0.00% <0.00%> (ø)
...ges/core/src/components/Schema/SchemaSelection.tsx 0.00% <0.00%> (ø)
.../core/src/components/Schema/SchemaSelectionRow.tsx 0.00% <0.00%> (ø)
...ages/core/src/components/Schema/SchemaSettings.tsx 0.00% <0.00%> (ø)
...ore/src/components/Sidebar/Entries/FilterEntry.tsx 0.00% <0.00%> (ø)
app/packages/state/src/hooks/useSchemaSettings.ts 15.91% <11.26%> (-60.41%) ⬇️
...ackages/state/src/hooks/useSchemaSettings.utils.ts 43.58% <43.58%> (ø)

... and 473 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@manivoxel51 manivoxel51 changed the title [WIP] Refactor schemaControls, use selectField in filter mode, more Refactor schemaControls, use selectField in filter mode, more Jun 5, 2023
@manivoxel51 manivoxel51 changed the title Refactor schemaControls, use selectField in filter mode, more [1.3.1 Bug fixes] Field visibility improvements Jun 5, 2023
Copy link
Contributor

@benjaminpkane benjaminpkane left a comment

Choose a reason for hiding this comment

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

Looks good! Left some high level comments and suggestions. The one case statement that does not return is the only critical thing from what I saw. I recommend adding eslint to your editor, and looking at some of the dependency warnings in useSchemaSettings. It looks like some dependencies may be missing.

It would be interesting see how the useSchemaSettings hook could be broken out, and perhaps (in part) moved into recoil data flow. But not important now

@lanzhenw
Copy link
Contributor

lanzhenw commented Jun 7, 2023

Looking good to me. Only one minor thing with this the json formatter. It doesn't seem to still format. We can remove the format button if it's not a required feature.
https://github.com/voxel51/fiftyone/assets/17770824/4426ff72-aa8c-4e70-ba4d-f25d49327828

Copy link
Contributor

@lanzhenw lanzhenw left a comment

Choose a reason for hiding this comment

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

Tested. LGTM

@@ -8,6 +8,14 @@ export default defineConfig({
coverage: {
reporter: ["json", "lcov"],
reportsDirectory: "./coverage",
enabled: true,
all: true,
exclude: [
Copy link
Contributor

Choose a reason for hiding this comment

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

Nice

Copy link
Contributor

@benjaminpkane benjaminpkane left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

@manivoxel51 manivoxel51 merged commit c3025ef into develop Jun 10, 2023
@manivoxel51 manivoxel51 deleted the schema/improvement branch June 10, 2023 15:09
@benjaminpkane benjaminpkane restored the schema/improvement branch June 12, 2023 16:47
benjaminpkane added a commit that referenced this pull request Jun 12, 2023
* Refactor schemaControls, use selectField() when searching, cleaner schema documentation

selection mode is default now for filed visibility

* update count dependency to refelct when applying filter rules

* add documentation links

* better disable field handling - (un)select is broken - fixing next

* improve select all control

* uncheck subpaths even if they are disabled

* show embedded document in selection mode

* field doc type using tertiary text color

* minor tweaks in color modal title style

* review comments and fix include nested fields selection view

* review comments, refactor selection row, and count fix

* add first vitest for visibility, upgrade vitest packages

* add basic test and refactor more

* keep one embed doc field

* no coverage when yarn test

---------

Co-authored-by: manivoxel51 <mani@voxel51@gmail.com>
Co-authored-by: Lanny W <lanzhenwang9@gmail.com>
@benjaminpkane benjaminpkane deleted the schema/improvement branch June 12, 2023 16:48
@manivoxel51 manivoxel51 restored the schema/improvement branch June 12, 2023 18:47
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.

3 participants