Skip to content

WIP: Location Modal UX - #1140

Open
slifty wants to merge 3 commits into
mainfrom
1134-location-modal
Open

WIP: Location Modal UX#1140
slifty wants to merge 3 commits into
mainfrom
1134-location-modal

Conversation

@slifty

@slifty slifty commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

This PR adds un-wired UX to the uncertain locations modal. This is focused on non-coordinate based location entry specifically.

Resolves #1134

Copilot AI lite review requested due to automatic review settings August 19, 2026 20:13
@codecov

codecov Bot commented Aug 19, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 98.52941% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 52.64%. Comparing base (4435d45) to head (970a8cf).

Files with missing lines Patch % Lines
...tion-picker/uncertain-location-picker.component.ts 97.95% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1140      +/-   ##
==========================================
+ Coverage   52.43%   52.64%   +0.20%     
==========================================
  Files         355      357       +2     
  Lines       12134    12197      +63     
  Branches     2197     2206       +9     
==========================================
+ Hits         6363     6421      +58     
- Misses       5547     5553       +6     
+ Partials      224      223       -1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@slifty
slifty force-pushed the 1134-location-modal branch from 5d6bb62 to 95ff525 Compare August 19, 2026 20:16

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR implements a frontend-only UX for the “uncertain locations” modal (non-coordinate location entry), adding reusable input UI and wiring dialog open behavior based on the uncertain-locations feature flag, without persisting changes to the API.

Changes:

  • Added a standalone LocationFieldComponent with icon + labeled input + clear affordance (and unit tests/styles).
  • Rebuilt UncertainLocationPickerComponent as a standalone dialog with address-part fields, qualifier toggles, clear/save/cancel UX, and expanded test coverage.
  • Updated dialog launchers (EditService + ProfileEditComponent) to select the new dialog and adjust modal width when the feature flag is enabled.

Reviewed changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
src/app/shared/components/location-field/location-field.component.ts New standalone reusable location input component (icon/label/value/clear).
src/app/shared/components/location-field/location-field.component.html Template for the reusable field (input + conditional clear button).
src/app/shared/components/location-field/location-field.component.scss Styling for the field, including icon gradient fill behavior.
src/app/shared/components/location-field/location-field.component.spec.ts Unit tests for rendering, binding, clear behavior, and a11y labeling.
src/app/models/locn-vo.ts Introduces qualifier enum/flags and defaults alongside existing precision typing.
src/app/file-browser/file-browser-components.module.ts Removes UncertainLocationPickerComponent from the NgModule now that it’s standalone.
src/app/file-browser/components/uncertain-location-picker/uncertain-location-picker.component.ts Standalone uncertain-location dialog logic using signals; supports qualifiers, clear all, save/cancel.
src/app/file-browser/components/uncertain-location-picker/uncertain-location-picker.component.html New dialog UX layout (gradient defs, qualifiers, fields, footer actions).
src/app/file-browser/components/uncertain-location-picker/uncertain-location-picker.component.scss Dialog styling, including toggle UI, layout, and footer controls.
src/app/file-browser/components/uncertain-location-picker/uncertain-location-picker.component.spec.ts Expanded unit tests for field behavior, qualifiers, prefill logic, and clear behavior.
src/app/core/services/edit/edit.service.ts Chooses between legacy/new picker via feature flag and adjusts dialog width accordingly.
src/app/core/services/edit/edit.service.spec.ts Updates expectations for dialog open behavior/width under the feature flag.
src/app/core/components/profile-edit/profile-edit.component.ts Chooses between legacy/new picker via feature flag and adjusts dialog width accordingly.
src/app/core/components/profile-edit/profile-edit.component.spec.ts Updates expectations for dialog open behavior/width under the feature flag.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +31 to +45
<div class="pr-qualifier-option">
<span>{{ option.label }}</span>
<label class="pr-toggle">
<input
type="checkbox"
[attr.aria-label]="option.label"
[checked]="qualifiers()[option.key]"
[disabled]="
option.key !== LocationQualifier.Unknown && fieldsDisabled()
"
(change)="onQualifierChange(option.key)"
/>
<span class="pr-toggle-slider"></span>
</label>
</div>
Comment on lines +96 to +101
span {
@include usual-text;
font-family: 'UsualRegular', sans-serif;
color: $PR-blue-900;
white-space: nowrap;
}
Comment on lines +143 to 154
input:checked + .pr-toggle-slider {
background-color: $toggle-checked;
}

input:checked + .pr-toggle-slider::before {
transform: translateX(16px);
}

input:disabled + .pr-toggle-slider {
opacity: 0.5;
cursor: not-allowed;
}
Comment thread src/app/models/locn-vo.ts
Comment on lines 3 to +9
export type LocationPrecision = 'approximate' | 'uncertain' | 'unknown';

export enum LocationQualifier {
Approximate = 'approximate',
Uncertain = 'uncertain',
Unknown = 'unknown',
}
@slifty
slifty force-pushed the 1134-location-modal branch 3 times, most recently from 5d7a5d2 to f560d7a Compare August 21, 2026 14:29
slifty added 3 commits August 21, 2026 10:49
{ commit message TBD }

Issue #1134 Create frontend-only implementation of uncertain address modal

Claude-Session: 3fc6caae-2a65-4475-8a49-f12a760fcb83
{ commit message TBD }

Issue #1134 Create frontend-only implementation of uncertain address modal

Claude-Session: 3fc6caae-2a65-4475-8a49-f12a760fcb83
{ commit message TBD }

Issue #1134 Create frontend-only implementation of uncertain address modal

Claude-Session: 3fc6caae-2a65-4475-8a49-f12a760fcb83
@slifty
slifty force-pushed the 1134-location-modal branch from f560d7a to 970a8cf Compare August 21, 2026 14:51
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.

Create frontend-only implementation of uncertain address modal

2 participants