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

feat: Show loading indicators and failure indicators for soil id #1688

Merged
merged 12 commits into from
Jul 8, 2024

Conversation

knipec
Copy link
Contributor

@knipec knipec commented Jul 2, 2024

Description

  • Temporary Location Callout:
    • Loading: shows spinner
    • Error: shows red "Error" for Soil ID and Ecological Site (Figma)
    • Data unavailable: shows "No matches"
  • Location Dashboard Screen: (for both sites and temporary)
    • Loading: shows the LocationPrediction soil ID box, with "Loading..." for the value of Soil ID and Ecological Site
    • Error: shows the LocationPrediction soil ID box, with "Error" for Soil ID and Ecological Site (Figma)
    • Data unavailable: shows "No matches"
  • Location Soil ID Screen: (for both sites and temporary)
    • Loading: Show the section with the header, info button, and a loading spinner
    • Error: Show the Top Soil Matches section with a "Can't fetch soil map" error message box instead of soil tiles per Figma
    • Data unavailable: Show the Top Soil Matches section with a "No soil map data" alert message box instead of soil tiles per Figma

Related Issues

Implements techmatters/terraso-product#895 (except request timeout behavior, which I intend to be a future PR)

@knipec knipec force-pushed the feat/soil-id-error-loading branch from 67392da to 092d1ff Compare July 5, 2024 22:47
@knipec knipec merged commit dafa571 into main Jul 8, 2024
9 checks passed
@knipec knipec deleted the feat/soil-id-error-loading branch July 8, 2024 16:15
paulschreiber pushed a commit that referenced this pull request Jul 8, 2024
Commits:
* feat: Location dashboard displays "Loading..." or "No matches" or soil id results

* feat: Add loading spinner for matches section in Soil ID screen

* feat: error and alert boxes appear for soil id screen's top soil matches section

* feat: temporary location callout displays each datum section with loading spinner, error, no matches, or the top match

* refactor: Move message box components to separate files

* refactor: Consolidate no matches and error strings

* refactor: get soil match and ecological site similarly between TemporaryLocationCallout and LocationPrediction on dashboard

* fix: use consistent apostrophe characters in strings

* fix: minor styling and refactoring

* fix: Remove unused import after rebase

* refactor: Consolidate some duplicate logic with SoilIdStatusDisplay

* fix: Update test snapshot to accomodate soil id tile existing regardless of status
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