PrismLibrary / PrismLibrary/Prism

Add CloseDialog to IDialogService or Extension Method

Open
#3,171 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Commercial Plus :rocket: Core enhancement
Dominant language
C#
Stars
6.8k
Forks
1.6k
Avg merge
2d 1h
Merged PRs (30d)
1

Description

Summary

When using the IDialogService for popups sometimes one might want to be able to close the View from the ViewModel that made the ShowDialog call. In the old NavigationService based Popup framework you could call GoBackAsync to achieve this behavior. This does not exist in the IDialogService.

API Changes

An extension method could potentially be added to IDialogService with a close method.

Intended Use Case

In our existing Xamarin Forms app we have several long running processes. To improve the user experience we have a Popup that displays a busy indicator and a message describing the on-going operation. This was easy to implement in Popups using NavigationService and calling GoBack when the job completed.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Review the IDialogService API and the existing NavigationService popup behavior described in the issue. Determine how a ViewModel should close its dialog after a long-running operation, then verify that the chosen API supports the intended busy-indicator popup use case.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
api, mobile-dev
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.