diff --git a/nix/gen/npm-deps-hash.nix b/nix/gen/npm-deps-hash.nix index 2d354039..02330d99 100644 --- a/nix/gen/npm-deps-hash.nix +++ b/nix/gen/npm-deps-hash.nix @@ -1,2 +1,2 @@ # This file was generated by prefetch-npm-deps -"sha256-pZ5QQgWs5ymu+2Vieurq/B84uU1bIM2abwIcdnt0U8U=" +"sha256-3sDbVhLjIYiSICPJZfjneW6s2nNKsKSJxtkOt+xTKKQ=" diff --git a/nix/gen/spago-packages.nix b/nix/gen/spago-packages.nix index b756acd8..8d52349b 100644 --- a/nix/gen/spago-packages.nix +++ b/nix/gen/spago-packages.nix @@ -199,11 +199,11 @@ let "cardano-wallet-client" = pkgs.stdenv.mkDerivation { name = "cardano-wallet-client"; - version = "v0.1.0"; + version = "v0.1.1"; src = pkgs.fetchgit { url = "https://github.com/input-output-hk/purescript-cardano-wallet-client.git"; - rev = "a2b08694d2c9d5e55e0707a1ce7d292503ee1eca"; - sha256 = "1pin92qfjm8lvirkrc9n8i38940nsa12cfadz2m9drrzr0z45m29"; + rev = "d6c4be8bc24d285e700264ad29cf6b6b7623c6ed"; + sha256 = "09vqahbsawzp8qjcylvpcy1yrk0b489c4hd9z22jabs8mpai624r"; }; phases = "installPhase"; installPhase = "ln -s $src $out"; diff --git a/packages.dhall b/packages.dhall index 4a8072e1..588b7089 100644 --- a/packages.dhall +++ b/packages.dhall @@ -321,7 +321,7 @@ in upstream , "web-encoding" ] "https://github.com/input-output-hk/purescript-cardano-wallet-client.git" - "v0.1.0" + "v0.1.1" -- with marlowe-runtime-client = ../purescript-marlowe-runtime-client/spago.dhall as Location with marlowe-runtime-client = diff --git a/spago.dhall b/spago.dhall index 74cdd9ea..1cff2580 100644 --- a/spago.dhall +++ b/spago.dhall @@ -27,7 +27,6 @@ , "foreign-generic" , "foreign-object" , "formatters" - , "free" , "functions" , "functors" , "halogen-subscriptions" @@ -78,7 +77,6 @@ , "typelevel-prelude" , "undefined-is-not-a-problem" , "unsafe-coerce" - , "unsafe-reference" , "uri" , "validation" , "variant" diff --git a/src/Component/App.purs b/src/Component/App.purs index 99975ba8..2d479f8e 100644 --- a/src/Component/App.purs +++ b/src/Component/App.purs @@ -73,18 +73,20 @@ import Web.HTML (window) -- | Debugging helpers which allow us to automatically connect wallet data WalletBrand - = Lace - | Yoroi + = Eternl + | Gero + | Lace | Nami - | Eternl | Typhon + | Yoroi instance Show WalletBrand where - show Yoroi = "Yoroi" - show Nami = "Nami" - show Lace = "Lace" show Eternl = "Eternl" + show Gero = "Gero" + show Lace = "Lace" + show Nami = "Nami" show Typhon = "Typhon" + show Yoroi = "Yoroi" autoConnectWallet :: WalletBrand -> (WalletInfo Wallet.Api -> Effect Unit) -> Aff Unit autoConnectWallet walletBrand onSuccess = liftEffect (window >>= Wallet.cardano) >>= case _ of @@ -94,12 +96,13 @@ autoConnectWallet walletBrand onSuccess = liftEffect (window >>= Wallet.cardano) Just cardano -> do let extractWallet = case walletBrand of + Eternl -> Wallet.eternl + Gero -> Wallet.gerowallet Lace -> Wallet.lace Nami -> Wallet.nami - Yoroi -> Wallet.yoroi - Eternl -> Wallet.eternl Typhon -> Wallet.typhon - liftEffect (extractWallet cardano) >>= traverse walletInfo >>= case _ of + Yoroi -> Wallet.yoroi + liftEffect (extractWallet cardano) >>= traverse walletInfo >>= join >>> case _ of Nothing -> do liftEffect $ throw $ "Unable to extract wallet " <> show walletBrand Just walletInfo@(WalletInfo { wallet }) -> do