File tree Expand file tree Collapse file tree
basic_bls_signing/frontend/scripts
basic_ibe/frontend/scripts
basic_timelock_ibe/frontend/scripts
encrypted_chat/frontend/scripts
encrypted_notes_dapp_vetkd/frontend/scripts
password_manager_with_metadata/frontend/scripts
password_manager/frontend Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ npm install -g @icp-sdk/icp-cli @icp-sdk/ic-wasm ic-mops
1010
1111# Install rust
1212wget --output-document install-rustup.sh " https://sh.rustup.rs"
13- sudo bash install-rustup.sh -y
13+ bash install-rustup.sh -y
1414rustup target add wasm32-unknown-unknown
1515
1616# Set environment variables.
Original file line number Diff line number Diff line change 22
33# Bindings are always generated from the Rust backend since both backends
44# expose the same Candid interface.
5- cd ../../rust/backend && make extract-candid
6-
7- cd ../..
5+ if command -v candid-extractor > /dev/null 2>&1 ; then
6+ cd ../../rust/backend && make extract-candid
7+ cd ../..
8+ else
9+ cd ../..
10+ fi
811
912rm -rf frontend/src/declarations/basic_bls_signing
1013
Original file line number Diff line number Diff line change 11#! /bin/bash
22
3- cd ../../rust/backend && make extract-candid
4-
5- cd ../..
3+ if command -v candid-extractor > /dev/null 2>&1 ; then
4+ cd ../../rust/backend && make extract-candid
5+ cd ../..
6+ else
7+ cd ../..
8+ fi
69
710rm -rf frontend/src/declarations/basic_ibe
811
Original file line number Diff line number Diff line change 11#! /bin/bash
22
3- cd ../../backend && make extract-candid
4-
5- cd ..
3+ if command -v candid-extractor > /dev/null 2>&1 ; then
4+ cd ../../backend && make extract-candid
5+ cd ..
6+ else
7+ cd ..
8+ fi
69
710rm -rf frontend/src/declarations/basic_timelock_ibe
811
Original file line number Diff line number Diff line change 55# Resolve the physical path of this script so that navigating up works
66# correctly even when frontend/ is reached via a symlink (e.g. motoko/frontend).
77SCRIPT_DIR=$( cd " $( dirname " $0 " ) " && pwd -P)
8- cd " $SCRIPT_DIR /../../rust/backend" && make extract-candid
8+ if command -v candid-extractor > /dev/null 2>&1 ; then
9+ cd " $SCRIPT_DIR /../../rust/backend" && make extract-candid
10+ fi
911
1012cd " $SCRIPT_DIR /../.."
1113rm -rf frontend/src/declarations/encrypted_chat
Original file line number Diff line number Diff line change 66# Resolve the physical path of this script so that navigating up works
77# correctly even when frontend/ is reached via a symlink (e.g. motoko/frontend).
88SCRIPT_DIR=$( cd " $( dirname " $0 " ) " && pwd -P)
9- cd " $SCRIPT_DIR /../../rust/backend" && make extract-candid
9+ if command -v candid-extractor > /dev/null 2>&1 ; then
10+ cd " $SCRIPT_DIR /../../rust/backend" && make extract-candid
11+ fi
1012
1113cd " $SCRIPT_DIR /../.."
1214
Original file line number Diff line number Diff line change 55# Resolve the physical path of this script so that navigating up works
66# correctly even when frontend/ is reached via a symlink (e.g. motoko/frontend).
77SCRIPT_DIR=$( cd " $( dirname " $0 " ) " && pwd -P)
8- cd " $SCRIPT_DIR /../../rust/backend" && make extract-candid
8+ if command -v candid-extractor > /dev/null 2>&1 ; then
9+ cd " $SCRIPT_DIR /../../rust/backend" && make extract-candid
10+ fi
911
1012cd " $SCRIPT_DIR /../.."
1113rm -rf frontend/src/declarations/ic_vetkeys_encrypted_maps_canister
Original file line number Diff line number Diff line change 110110 <PasswordEditor {editor } class ="mb-3" disabled ={creating } />
111111 <button
112112 class ="btn mt-6 btn-primary {creating ? ' loading' : ' ' }"
113- disabled ={creating || vaultName .trim () === " " || passwordName .trim () === " " }
113+ disabled ={creating ||
114+ vaultName .trim () === " " ||
115+ passwordName .trim () === " " }
114116 on:click ={add }>{creating ? " Adding..." : " Add password" }</button
115117 >
116118</main >
Original file line number Diff line number Diff line change 66 import { Principal } from " @icp-sdk/core/principal" ;
77 import Header from " ./Header.svelte" ;
88 import Spinner from " ./Spinner.svelte" ;
9- // @ts-ignore: svelte-icons have no type declarations
109 import GiOpenTreasureChest from " svelte-icons/gi/GiOpenTreasureChest.svelte" ;
1110 import { auth } from " ../store/auth" ;
1211 import SharingEditor from " ./SharingEditor.svelte" ;
Original file line number Diff line number Diff line change @@ -14,9 +14,7 @@ export async function createEncryptedMaps(
1414 agentOptions ?: HttpAgentOptions ,
1515) : Promise < EncryptedMaps > {
1616 const canisterId =
17- canisterEnv ?. [
18- "PUBLIC_CANISTER_ID:ic_vetkeys_encrypted_maps_canister"
19- ] ;
17+ canisterEnv ?. [ "PUBLIC_CANISTER_ID:ic_vetkeys_encrypted_maps_canister" ] ;
2018 if ( ! canisterId ) {
2119 throw new Error (
2220 "Canister ID for ic_vetkeys_encrypted_maps_canister is not set" ,
You can’t perform that action at this time.
0 commit comments