Skip to content

Improve DAP HTML form by grouping file types into Data and Image categories#439

Open
vishwas-droid wants to merge 1 commit intoERDDAP:mainfrom
vishwas-droid:ui/filetype-clean
Open

Improve DAP HTML form by grouping file types into Data and Image categories#439
vishwas-droid wants to merge 1 commit intoERDDAP:mainfrom
vishwas-droid:ui/filetype-clean

Conversation

@vishwas-droid
Copy link

Description

This change improves the DAP HTML form by separating file types into clear “Data File Types” and “Image File Types” groups using <optgroup>.

Previously, all file formats were displayed in a single flat dropdown list, which could cause confusion — especially for users expecting raw data formats (e.g., CSV, NetCDF) versus rendered outputs (e.g., PNG, PDF, GeoTIFF images).

This update enhances clarity without modifying any backend logic or request handling behavior. The default file type selection is preserved, and existing functionality remains unchanged.

The goal is purely to improve usability and reduce ambiguity in the output format selection UI.

Fixes #268

Type of change

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

Checklist before requesting a review

  • I have performed a self-review of my code
  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@vishwas-droid
Copy link
Author

hey @ChrisJohnNOAA This implementation keeps the change localized to the current HTML generation logic.
If preferred, I can adapt this to the jte-based UI structure as well.

Copy link
Contributor

@ChrisJohnNOAA ChrisJohnNOAA left a comment

Choose a reason for hiding this comment

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

Before making a pull request make sure your changes pass tests (run with mvn verify) and if you're modifying the UI I strongly recommend running the server locally to verify the UI changes (the easiest way to do this is using Jetty, see the documentation in the development/jetty folder).

writeFunctionHtml(
request, language, loggedInAs, queryParts, writer, widgets, formName, nOrderByComboBox);

/ writer.write(
Copy link
Contributor

Choose a reason for hiding this comment

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

This doesn't even compile. Make sure to verify your changes before making a pull request.

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.

Avoid confusion between “data file type” and “image file type” output formats

2 participants