Changed to popups for installing and uninstalling extensions
Signed-off-by: Julien Eluard <julien.eluard@gmail.com>
This commit is contained in:
parent
a31d10f6dc
commit
5d549fec12
|
@ -56,10 +56,9 @@
|
|||
:active? true}
|
||||
new-extensions (assoc (:extensions account) (:url extension) extension)]
|
||||
(fx/merge cofx
|
||||
{:ui/show-confirmation {:title (i18n/label :t/success)
|
||||
:content (i18n/label :t/extension-installed)
|
||||
:on-accept #(re-frame/dispatch [:navigate-to-clean :my-profile])
|
||||
:on-cancel nil}}
|
||||
{:utils/show-popup {:title (i18n/label :t/success)
|
||||
:content (i18n/label :t/extension-installed)
|
||||
:on-dismiss #(re-frame/dispatch [:navigate-to-clean :my-profile])}}
|
||||
(accounts.update/account-update {:extensions new-extensions} {})
|
||||
(add-to-registry (:value url) extension-data true))))
|
||||
|
||||
|
@ -68,10 +67,8 @@
|
|||
(let [{:account/keys [account]} db
|
||||
new-extensions (dissoc (:extensions account) extension-key)]
|
||||
(fx/merge cofx
|
||||
{:ui/show-confirmation {:title (i18n/label :t/success)
|
||||
:content (i18n/label :t/extension-uninstalled)
|
||||
:on-accept nil
|
||||
:on-cancel nil}}
|
||||
{:utils/show-popup {:title (i18n/label :t/success)
|
||||
:content (i18n/label :t/extension-uninstalled)}}
|
||||
(remove-from-registry extension-key)
|
||||
(accounts.update/account-update {:extensions new-extensions} {}))))
|
||||
|
||||
|
|
Loading…
Reference in New Issue