Repository navigation
Feature/panoramax - #74
Conversation
There was a problem hiding this comment.
Let's send the Enum value from the backend (main/graphql/enums.py) and use that instead of creating a separate enum on the client side. We can then receive and use it in the EnumContext. We should add custom panoramax option to StreetImageProviderNameEnum and only add url field to the custom option.
To summarize, let's change following in the backend
- In StreetImageProvider
- Add PANORAMAX_CUSTOM option
- Add pydantic validation to the StreetImageProvider.url
- Add StreetImageProviderNameEnum to ENUM_TO_STRAWBERRY_ENUMS (main/graphql/enum)
2610264 to
7ba77a9
Compare
| /> | ||
| {data.imageProvider?.url && ( | ||
| <TextOutput | ||
| label="Panoramax API URL" |
There was a problem hiding this comment.
Is this label correct? How do we know the url is for Panoramax?
There was a problem hiding this comment.
The url field is only allowed for custom Panoramax API (see https://github.com/mapswipe/mapswipe-backend/blob/3089d827103cc40157930d0ff527ca93d0caa33f/utils/geo/street_image_provider/models.py#L28)
There was a problem hiding this comment.
It's better to check the imageProvider type so that it does not break in the future.
| onChange={setFieldValue} | ||
| disabled={disabled} | ||
| hint="Provide a valid Mapillary organization ID to filter for images belonging to a specific organization. Empty indicates that no filter is set on organization." | ||
| hint="Provide a valid Mapillary organization ID to filter for images belonging to a specific organization. Empty indicates that no filter is set on organization (only Mapillary)." |
There was a problem hiding this comment.
This should be a conditional field if it is only applicable for Mapillary.
| import TextInput from '#components/TextInput'; | ||
|
|
||
| import { PartialStreetMapillaryImageFiltersInputFields } from './schema'; | ||
| import { PartialStreetMapillaryImageFiltersInputFields } from './schema.ts'; |
There was a problem hiding this comment.
We might also need to rename the variables?
e.g. PartialStreetMapillaryImageFiltersInputFields
70d5487 to
014b38e
Compare
0f31109 to
ae83a38
Compare
- Let street projects use Mapillary, Panoramax or a custom Panoramax instance. - Accept only a scheme and host for the custom Panoramax instance URL. - Carry the common image filters over when switching providers. - Show the organization ID filter only for Mapillary. - Validate the sampling threshold as a non-negative integer in meters. - Show the image provider and its filters in project details. - Update the backend submodule. Co-authored-by: tnagorra <weathermist@gmail.com>
- Show the Panoramax viewer for Panoramax and custom instance projects. - Load the viewer lazily and show an error if it fails to load. - Load MapComplete pictures through the public Panoramax catalog. - Label the tutorial image ID field as a street-level image ID. Co-authored-by: tnagorra <weathermist@gmail.com>
ae83a38 to
3400f70
Compare
Depends on mapswipe/mapswipe-backend#236
Changes
This introduces the possibility to create View Streets projects and tutorials with Panoramax as the image provider. Managers can choose to use either the federated Panoramax metacatalog, or a specific Panoramax instance (by providing the API url).
This PR doesn't introduce any:
console.logmeant for debugging