functione(e){vart=this;Object.keys(e).forEach((function(n){t[n]=e[n]})),t.endpoints=t.endpoints||[]}functiont(e,t){"use strict";varn=this;t&&t.length?_.forEach(t,(function(t){n[t]=e[t]})):["currency","issuer","medianTime","number","version","powMin","dividend","membersCount","hash","identities","joiners","actives","leavers","revoked","excluded","certifications","transactions","unitbase"].forEach((function(t){n[t]=e[t]})),n.identitiesCount=n.identities?n.identities.length:0,n.joinersCount=n.joiners?n.joiners.length:0,n.activesCount=n.actives?n.actives.length:0,n.leaversCount=n.leavers?n.leavers.length:0,n.revokedCount=n.revoked?n.revoked.length:0,n.excludedCount=n.excluded?n.excluded.length:0,n.certificationsCount=n.certifications?n.certifications.length:0,n.transactionsCount=n.transactions?n.transactions.length:0,n.empty=n.isEmpty(),n.id=[n.number,n.hash].join("-")}functionn(e){vart=e.split(":");if(t.length<3||!t[0].startsWith("WS2P"))throwError("Invalid format: "+e);if("HEAD"==t[1]){if(t.length<4)throwError("Invalid format: "+e);if(4==t.length)this.pubkey=t[2],this.buid=t[3];elseif(t[2]>=1){varn=t[0];if(n.length>4){vari=this.regexp.WS2P_PREFIX.exec(n);if(!i)throwError("Invalid format: "+e);vara=i[1];if(a){this.private={useTor:a.startsWith("T")};varo=a.substring(1);"A"==o?this.private.mode="all":"M"==o?this.private.mode="mixed":"S"==o&&(this.private.mode="strict")}varr=i[2];r&&(this.public={useTor:r.startsWith("T"),mode:"all"})}this.pubkey=t[3],this.buid=t[4],this.ws2pid=t[5],this.software=t[6],this.version=t[7],this.powPrefix=t[8]}}}functiona(e,t){e.extensionPoint=t.extensions.points.current.get()}functiono(e,t,n,i,a,o,r,s,l,c,d,u,p,m,E,b,g,f,_,h){e.walletData=b.data,e.search={},e.login=b.isLogin(),e.auth=b.isAuth(),e.motion=m.motion.default,e.fullscreen=m.screen.fullscreen.isEnabled(),e.showHome=function(){returnr.nextViewOptions({historyRoot:!0}),n.go("app.home").then(m.loading.hide)},e.createHelptipScope=function(n){if(n||!t.tour&&t.settings.helptip.enable&&!m.screen.isSmall()){vari=e.$new();returns("HelpTipCtrl",{$scope:i}),i}},e.startHelpTour=function(n,i){if(n&&n.defaultPrevented)return!1;if(t.tour=!0,!i)returnr.clearHistory(),r.clearCache().then((function(){e.startHelpTour(null,!0)}));vara=e.createHelptipScope(!0);returna.startHelpTour().then((function(){a.$destroy(),deletet.tour})).catch((function(e){deletet.tour}))},e.disableHelpTour=function(e){e&&(e.preventDefault(),e.stopPropagation()),d.data.helptip&&d.data.helptip.enable&&(t.settings.helptip.enable=!1,d.store())},e.isLogin=function(){returne.login},e.loadWalletData=function(e){returnconsole.warn("[app-controller] DEPRECATED - Please use csWallet.load() instead of $scope.loadWalletData()",newError),((e=e||{}).wallet||b).loadData(e).then((function(e){if(!e)throw"CANCELLED";returne}))},e.loadWallet=function(t){if(console.warn("[app-controller] DEPRECATED - Please use csWallet.loginOrLoad() instead of $scope.loadWallet()",newError),!c.isStarted())returnc.ready().then((function(){returne.loadWallet(t)}));varn=(t=t||{}).wallet||b;returnt.auth&&!n.isAuth()?n.auth(t).then((function(e){if(e)returne;throw"CANCELLED"})):n.isLogin()?n.isDataLoaded(t)?a.when(n.data):e.loadWalletData(t):n.login(t).then((function(e){if(e)returne;throw"CANCELLED"}))},e.loginAndGo=function(t,i){e.closeProfilePopover();vara=(i=i||{}).wallet||b;if(deletei.wallet,t=t||"app.view_wallet",a.isLogin())returnn.go(t,i);if(_.httpsMode&&l.location&&"https:"!==l.location.protocol){varo=l.location.href,r=o.indexOf("#"),s=-1!=r?o.substr(0,r):o;if(o=(s="https"+s.substr(4))+n.href(t),!_.httpsModeDebug)returnvoid(l.location.href=o);console.debug("[httpsMode] --- Should redirect to: "+o)}returna.login(i).then((function(){returnn.go(t,i)})).then(m.loading.hide)},e.logout=function(t){varn=(t=t||{}).wallet||b;return!t.force&&e.profilePopover?e.profilePopover.hide().then((function(){returnt.force=!0,e.logout(t)})):t.askConfirm?m.alert.confirm("CONFIRM.LOGOUT").then((function(n){if(n)returnt.askConfirm=!1,e.logout(t)})):(m.loading.show(),n.logout().then((function(
}),500)):(e.saving=!0,o((function(){returne.cleanupHelpTip(),E.apply(e.formData),E.store()}),100).then((function(){e.saving=!1})))},e.onDataChanged=function(n,i,a){returne.loading||e.pendingSaving?t.when():e.saving?(e.pendingSaving=!0,o((function(){returne.pendingSaving=!1,e.onDataChanged(n,i,a)}),500)):void(a!==e||angular.equals(n,i)||e.save())},e.$watch("formData",e.onDataChanged,!0),E.api.data.on.changed(e,(function(t){e.loading||e.saving||e.pendingSaving||!angular.equals(t.useLocalStorageEncryption,e.formData.useLocalStorageEncryption)&&(console.debug("[settings] Settings changed (outside the settings page). Reloading..."),e.load())})),e.getServer=function(){returne.formData.node&&e.formData.node.host?u.getServer(e.formData.node.host,e.formData.node.port):""},e.cleanupHelpTip=function(){if(e.formData.helptip.enable!==E.data.helptip.enable){vart=e.formData.helptip.enable;e.formData.helptip=angular.merge({},E.defaultSettings.helptip),e.formData.helptip.enable=t}},e.showActionsPopover=function(t){l.popover.show(t,{templateUrl:"templates/settings/popover_actions.html",scope:e,autoremove:!0,afterShow:function(t){e.actionsPopover=t}})},e.hideActionsPopover=function(){e.actionsPopover&&(e.actionsPopover.hide(),e.actionsPopover=null)},e.startSettingsTour=function(){returne.hideActionsPopover(),e.showHelpTip(0,!0)},e.showHelpTip=function(t,n){if((e.isLogin()||n)&&!((t=angular.isDefined(t)?t:E.data.helptip.settings)<0)){0===t&&(t=1);vari=e.createHelptipScope(n);if(i)returni.startSettingsTour(t,!1).then((function(e){i.$destroy(),E.data.helptip.settings=e,E.store()}))}}}function$(e,n,i,a,o,r,s,l,c,d,u){e.search={result:[],total:0,loading:!0,loadingMore:!1,hasMore:!1,type:"last"},e.node={},e.currency=!1,e.entered=!1,e.searchTextId=null,e.ionItemClass="item-border-large",e.defaultSizeLimit=s.screen.isSmall()?50:100,e.helptipPrefix="helptip-network",e.listeners=[],e.enter=function(t,a){if(e.entered)e.addListeners();else{if(a&&a.stateParams&&a.stateParams.q&&(e.search.text=a.stateParams.q,e.search.text&&e.search.text.trim().length&&(e.search.type="text")),a&&a.stateParams&&a.stateParams.server){varo="true"==a.stateParams.ssl,r="true"==a.stateParams.tor,d={server:a.stateParams.server,host:a.stateParams.server,useSsl:o,useTor:r},p=a.stateParams.server.split(":");if(2===p.length&&(d.host=p[0],d.port=p[1]),!l.node.same(d))returne.node=r?l.instance(d.host+".to",443,!0,6e5):l.instance(d.host,d.port,d.useSsl),e.node.blockchain.parameters().then((function(t){e.currency=t.currency,e.enter()}));e.node=l}if(!e.currency)returnc.get().then((function(t){e.currency=t?t.name:null,e.node=t.node?t.node:l,e.currency?e.enter():s.alert.error("ERROR.GET_CURRENCY_FAILED")})).catch(s.onError("ERROR.GET_CURRENCY_FAILED"));e.compactMode=!angular.isDefined(e.compactMode)||e.compactMode,e.expertMode=angular.isDefined(e.expertMode)?e.expertMode:!s.screen.isSmall()&&u.data.expertMode,e.doSearch(),e.searchTextId&&n((function(){i(e.searchTextId)}),100),e.addListeners(),e.entered=!0,e.showHelpTip()}},e.$on("$ionicParentView.enter",e.enter),e.leave=function(){e.removeListeners()},e.$on("$ionicParentView.leave",e.leave),e.$on("$destroy",e.leave),e.doSearchLast=function(){returne.search.type="last",e.doSearch()},e.doSearch=function(n){vari;if(n=angular.isDefined(n)?n:0,e.search.loading=0===n,e.search.hasMore=!1,0===n)i=e.node.blockchain.current(!1).then((function(t){varn=t.number<e.defaultSizeLimit?t.number:e.defaultSizeLimit;returne.node.blockchain.blocksSlice({count:n,from:t.number-n}).then((function(e){returne&&e.splice(0,0,t),e}))})).catch((function(e){if(e&&e.ucode==l.errorCodes.NO_CURRENT_BLOCK)return[];throwe}));else{vara=e.search.results[e.search.results.length-1].number,o=a<e.defaultSizeLimit?a:e.defaultSizeLimit;i=e.node.blockchain.blocksSlice({count:o,from:a-o})}returni.then((function(i){if(!i||!i.length)returne.doDisplayResult([],n,0),void(e.search.loading=!1);i=i.reduce((function(e,n){vari=newt(n);returni.cleanData(),e.concat(i)}),[]),i=_.sortBy(i,(function(e){return-1*e.number}));vara=(0===n?i[0].number:e.search.results[0].numbe
id:void0},e.$on("$recordView.enter",(function(t,n){e.entered?e.id&&e.loadLikes(e.id):e.entered=!1})),e.$on("$recordView.load",(function(t,n){e.id=n||e.id,e.id&&e.loadLikes(e.id)})),e.initLikes=function(){if(!e.likeData)thrownewError("Missing 'likeData' in scope. Cannot load likes counter");if(!e.options.like.service){if(!e.options.like.index||!e.options.like.type)thrownewError("Missing 'options.like.index' or 'options.like.type' in scope. Cannot load likes counter");e.options.like.service=c.instance(e.options.like.index,e.options.like.type)}e.options.like.kinds||(e.options.like.kinds=_.filter(c.constants.KINDS,(function(t){varn=t.toLowerCase()+"s";returnangular.isDefined(e.likeData[n])})))},e.loadLikes=function(n){if(e.likeData&&!e.likeData.loading){n=n||e.likeData.id,e.initLikes();vari=e.options.like.kinds||[];if(i.length){e.likeData.loading=!0;vara=Date.now();console.debug("[ES] Loading counter of {0}... ({1})".format(n.substring(0,8),i));varo=s.isLogin()?s.pubkeys():void0;returnt.all(_.map(i,(function(t){vari=t.toLowerCase()+"s";returne.options.like.service.count(n,{issuers:o,kind:t}).then((function(t){e.likeData[i]&&angular.merge(e.likeData[i],t)}))}))).then((function(){e.likeData.id=n,console.debug("[ES] Loading counter of {0} [OK] in {1}ms".format(n.substring(0,8),Date.now()-a)),_.contains(i,"VIEW")&&!e.canEdit&&e.markAsView(),e.$parent&&(console.debug("[ES] [likes] Adding data and functions to parent scope"),e.$parent.toggleLike=e.toggleLike,e.$parent.reportAbuse=e.reportAbuse),e.likeData.loading=!1})).catch((function(t){console.error(t&&t.message||t),e.likeData.loading=!1}))}}},e.toggleLike=function(i,a){if(e.initLikes(),!e.likeData.id)thrownewError("Missing 'likeData.id' in scope. Cannot apply toggle");if(!s.isLogin())returns.auth({minData:!0}).then((function(t){if(o.loading.hide(),!t)thrownewError("CANCELLED");returna.pubkey=a.pubkey||t.pubkey,e.toggleLike(i,a)}));(a=a||{}).kind=a.kind&&a.kind.toUpperCase()||"LIKE";varl=a.kind.toLowerCase()+"s";if(e.likeData[l]=e.likeData[l]||{},!0===e.likeData[l].loading||e.likeData.loading)returni.preventDefault(),t.reject();if(!a.pubkey){if(0!==s.children.count())returnr.showSelectWallet({displayBalance:!1}).then((function(t){if(!t)thrownewError("CANCELLED");returna.pubkey=t.data.pubkey,e.toggleLike(i,a)}));a.pubkey=s.data.pubkey}varc=s.getByPubkey(a.pubkey);returnc?(e.likeData[l].loading=!0,c.auth({minData:!0}).then((function(t){if(t)returnt.isMember,a.id=e.likeData.id,e.options.like.service.toggle(e.likeData.id,a);o.loading.hide()})).then((function(t){o.loading.hide(),0!==t&&(e.likeData[l].total=(e.likeData[l].total||0)+t,e.likeData[l].wasHitByPubkey=e.likeData[l].wasHitByPubkey||{},e.likeData[l].wasHitByPubkey[a.pubkey]=t>0,e.likeData[l].wasHitCount+=t),n((function(){e.likeData[l].loading=!1,e.$broadcast("$$rebind::like")}),1e3)})).catch((function(t){if(e.likeData[l].loading=!1,"CANCELLED"===t)throw"CANCELLED";console.error(t),o.onError("LIKE.ERROR.FAILED_TOGGLE_LIKE")(t),i.preventDefault()}))):void0},e.setAbuseForm=function(t){e.abuseForm=t},e.showAbuseCommentPopover=function(t){returni(["COMMON.REPORT_ABUSE.TITLE","COMMON.REPORT_ABUSE.SUB_TITLE","COMMON.BTN_SEND","COMMON.BTN_CANCEL"]).then((function(t){returno.loading.hide(),a.show({templateUrl:"plugins/es/templates/common/popup_report_abuse.html",title:t["COMMON.REPORT_ABUSE.TITLE"],subTitle:t["COMMON.REPORT_ABUSE.SUB_TITLE"],cssClass:"popup-report-abuse",scope:e,buttons:[{text:t["COMMON.BTN_CANCEL"],type:"button-stable button-clear gray"},{text:t["COMMON.BTN_SEND"],type:"button button-positive ink",onTap:function(t){if(e.abuseForm.$submitted=!0,e.abuseForm.$valid&&e.abuseData.comment)returne.abuseData;t.preventDefault()}}]})})).then((function(t){if(e.abuseData={},t&&t.comment)returnt;o.loading.hide()}))},e.reportAbuse=function(t,n){if(!s.isLogin())returns.auth({minData:!0}).then((function(i){if(o.loading.hide(),!i)thrownewError("CANCELLED");returnn.pubkey=n.pubkey||i.pubkey,e.reportAbuse(t,n)}));if(e.likeData&&e.likeData.abuses&&!e.likeData.abuses.wasHitCount&&!e.likeData.abuses
vart=e.number-r.data.blockValidityWindow;returnt>0?a.blockchain.block({block:t}):e}))}},date:{now:function(){returnmoment().utc().unix()-(d.medianTimeOffset||c.WELL_KNOWN_CURRENCIES.g1.medianTimeOffset)}},api:p,default:function(){returnconsole.warn("[currency] 'csCurrency.default()' has been DEPRECATED - Please use 'csCurrency.get()' instead."),b()}}}]),angular.module("cesium.bma.services",["ngApi","cesium.http.services","cesium.settings.services"]).factory("BMA",["$q","$window","$rootScope","$timeout","csCrypto","Api","Device","UIUtils","csConfig","csSettings","csCache","csHttp",function(e,t,n,i,a,o,r,s,l,c,d,u){functionp(r,p,m,E){varb,g=r?"{0}:{1}".format(r,p||(m?"443":"80")):"default",f="[123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{43,44}",h="SIG\\(("+f+")\\)",T="OBJ\\(([0-9]+)\\)",v="( ([a-z_][a-z0-9-_.ğĞ]*))?( ([0-9.]+))?( ([0-9a-f:]+))?( ([0-9]+))( (.+))?",I={BMA:"BASIC_MERKLED_API",BMAS:"BMAS",WS2P:"WS2P",BMATOR:"BMATOR",WS2PTOR:"WS2PTOR"},O={USER_ID:"[0-9a-zA-Z-_]+",CURRENCY:"[0-9a-zA-Z-_]+",PUBKEY:f,PUBKEY_WITH_CHECKSUM:"("+f+"):([123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{3})",COMMENT:"[ a-zA-Z0-9-_:/;*\\[\\]()?!^\\+=@&~#{}|\\\\<>%.]*",INVALID_COMMENT_CHARS:"[^ a-zA-Z0-9-_:/;*\\[\\]()?!^\\+=@&~#{}|\\\\<>%.]*",URI_WITH_AT:"duniter://(?:([A-Za-z0-9_-]+):)?("+f+"@([a-zA-Z0-9-.]+.[ a-zA-Z0-9-_:/;*?!^\\+=@&~#|<>%.]+)",URI_WITH_PATH:"duniter://([a-zA-Z0-9-.]+.[a-zA-Z0-9-_:.]+)/("+f+")(?:/([A-Za-z0-9_-]+))?",BMA_ENDPOINT:I.BMA+v,BMAS_ENDPOINT:I.BMAS+v,WS2P_ENDPOINT:I.WS2P+" ([a-f0-9]{8})"+v,BMATOR_ENDPOINT:I.BMATOR+" ([a-z0-9-_.]*|[0-9.]+|[0-9a-f:]+.onion)(?: ([0-9]+))?",WS2PTOR_ENDPOINT:I.WS2PTOR+" ([a-f0-9]{8}) ([a-z0-9-_.]*|[0-9.]+|[0-9a-f:]+.onion)(?: ([0-9]+))?(?: (.+))?"},N={PROTOCOL_VERSION:10,ROOT_BLOCK_HASH:"E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",LIMIT_REQUEST_COUNT:5,LIMIT_REQUEST_DELAY:1e3,regexp:O,api:I},R=this;functionA(e,t,n){R.started&&R.stop(),R.alive=!1,c.data&&c.data.node&&(e=e||c.data.node.host,t=t||c.data.node.port,n=angular.isDefined(n)?n:443==t||c.data.node.useSsl||R.forceUseSsl),e&&(R.host=e,R.port=t||80,R.useSsl=angular.isDefined(n)?n:443==R.port||R.forceUseSsl,R.server=u.getServer(e,t),R.url=u.getUrl(e,t,"",n))}functionS(e){returnnewRegExp("^"+e+"$")}functionC(e){returnnewRegExp(e)}functionL(){R.raw&&(console.warn("[BMA] Closing all websockets..."),_.keys(R.raw.wsByPath||{}).forEach((function(e){R.raw.wsByPath[e].close()})),R.raw.wsByPath={})}functionD(e,t){t=R.useCache&&t||0;varn=e+(t?"#"+t:""),a=function(o){if(!R.started)returnR._startPromise||console.warn("[BMA] Trying to get [{0}] before start(). Waiting...".format(e)),R.ready().then((function(){returna(o)}));varr=R.raw.getByPath[n];r||(r=t?u.getWithCache(R.host,R.port,e,R.useSsl,t,null,null,"BMA-"):u.get(R.host,R.port,e,R.useSsl),R.raw.getByPath[n]=r);varl=1;returnr(o).catch((function(e){if(e&&e.ucode===M.errorCodes.HTTP_LIMITATION&&l<=M.constants.LIMIT_REQUEST_COUNT)return1===l&&(console.warn("[BMA] Too many HTTP requests: Will wait then retry..."),s.loading.update({template:"COMMON.LOADING_WAIT"})),i((function(){returnl++,r(o)}),M.constants.LIMIT_REQUEST_DELAY);throwe}))};returna}functiony(e){vart=function(n,i){if(!R.started)returnR._startPromise||console.error("[BMA] Trying to post [{0}] before start()...".format(e)),R.ready().then((function(){returnt(n,i)}));vara=R.raw.postByPath[e];returna||(a=u.post(R.host,R.port,e,R.useSsl),R.raw.postByPath[e]=a),a(n,i)};returnt}functionP(e){returnfunction(){vart=R.raw.wsByPath[e];returnt&&!t.isClosed()||((t=u.ws(R.host,R.port,e,R.useSsl)).onclose=function(){deleteR.raw.wsByPath[e]},R.raw.wsByPath[e]=t),t}}functionk(e){i((function(){M.copy(e.node)}),1e3)}R.raw={getByPath:{},postByPath:{},wsByPath:{}},R.api=newo(this,"BMA-"+g),R.started=!1,R.init=A,R.forceUseSsl=!!("true"===l.httpsMode||!0===l.httpsMode||"force"===l.httpsMode||t.location&&"https:"===t.location.protocol),R.forceUseSsl&&console.debug("[BMA] Enable SSL (forced by config or detected in URL)"),r&&A(r,p,m),R.useCache=!angular.isDefined(E)
CONNECTION_ERROR:"Peer <b>{{server}}</b> unreachable or invalid address.<br/><br/>Check your Internet connection, or contact the web site administrator."},HOME:{TITLE:"{{'COMMON.APP_NAME'|translate}} API Documentation",MESSAGE:'Welcome to the {{\'COMMON.APP_NAME\'|translate}} <b>API documentation </b>.<br/>Connect your web site to <a href="http://duniter.org" target="_system">Duniter</a> very easily!',MESSAGE_SHORT:'Connect your websites to <a href="http://duniter.org" target="_system">Duniter</a> very easily!',DOC_HEADER:"Available services:"},TRANSFER:{TITLE:"{{'COMMON.APP_NAME'|translate}} - Online payment",TITLE_SHORT:"Online payment",SUMMARY:"Order summary:",AMOUNT:"Amount:",AMOUNTS_HELP:"Please select the amount:",NAME:"Name:",PUBKEY:"Public key of the recipient:",COMMENT:"Order reference:",NODE:"Peer address:",DEMO:{SALT:"demo",PASSWORD:"demo",PUBKEY:"3G28bL6deXQBYpPBpLFuECo46d3kfYMJwst7uhdVBnD1",HELP:"<b>Demonstration mode</b>: No payment will actually be sent during this simulation.<br/>Please use credentials: <b>{{'API.TRANSFER.DEMO.SALT'|translate}} / {{'API.TRANSFER.DEMO.PASSWORD'|translate}}</b>",BAD_CREDENTIALS:"Invalid credentials.<br/>In demonstration mode, credentials should be: {{'API.TRANSFER.DEMO.SALT'|translate}} / {{'API.TRANSFER.DEMO.PASSWORD'|translate}}"},INFO:{SUCCESS_REDIRECTING_WITH_NAME:"Payment sent.<br/>Redirect to <b>{{name}}</b>...",SUCCESS_REDIRECTING:"Payment sent.<br/>Redirect to the seller's website...",CANCEL_REDIRECTING_WITH_NAME:"Payment cancelled.<br/>Redirect to <b>{{name}}</b>...",CANCEL_REDIRECTING:"Payment cancelled.<br/>Redirect to the seller's website..."},ERROR:{TRANSFER_FAILED:"Payment failed"}},DOC:{DESCRIPTION_DIVIDER:"Description",URL_DIVIDER:"Calling address",PARAMETERS_DIVIDER:"Parameters",AVAILABLE_PARAMETERS:"Here is the list of al available parameters:",DEMO_DIVIDER:"Try it !",DEMO_HELP:"To test this service, click on this button. The result content will be display below.",DEMO_RESULT:"Result returned by call:",DEMO_RESULT_PEER:"Peer address used:",DEMO_SUCCEED:'<i class="icon ion-checkmark"></i> Success!',DEMO_CANCELLED:'<i class="icon ion-close"></i> Canceled by user',INTEGRATE_DIVIDER:"Website integration",INTEGRATE_CODE:"Code:",INTEGRATE_RESULT:"Result preview:",INTEGRATE_PARAMETERS:"Parameters",TRANSFER:{TITLE:"Payments",DESCRIPTION:"From a site (eg online marketplace) you can delegate payment in free currency to Cesium API. To do this, simply open a page at the following address:",PARAM_PUBKEY:"Recipient's public key",PARAM_PUBKEY_HELP:"Recipient's public key (required)",PARAM_AMOUNT:"Amount",PARAM_AMOUNT_HELP:"Transaction amount (required)",PARAM_COMMENT:"Reference (or comment)",PARAM_COMMENT_HELP:"Reference or comment. You will allow for example to identify the payment in the BlockChain.",PARAM_NAME:"Name (of recipient or website)",PARAM_NAME_HELP:'The name of your website. This can be a readable name (eg "My online site"), or a web address (eg "www.MySite.com").',PARAM_REDIRECT_URL:"URL redirection",PARAM_REDIRECT_URL_HELP:'URL redirection after sending payment, after the payment has been sent. Can contain the following strings, which will be replaced by the values of the transaction: "{tx}", "{hash}", "{comment}", "{amount}" and "{pubkey}".',PARAM_CANCEL_URL:"URL if cancelled",PARAM_CANCEL_URL_HELP:'URL in case of cancellation. Can contain the following strings, which will be replaced: "{comment}", "{amount}" and "{pubkey}".',PARAM_PREFERRED_NODE:"Preferred Duniter peer",PARAM_PREFERRED_NODE_HELP:'Peer address (URL) to use preferably ("g1.domain.com:443" or "https://g1.domain.com")',EXAMPLES_HELP:"Examples of integration:",EXAMPLE_BUTTON:"HTML Button",EXAMPLE_BUTTON_DEFAULT_TEXT:"Pay in {{currency|abbreviate}}",EXAMPLE_BUTTON_DEFAULT_STYLE:"Custom style",EXAMPLE_BUTTON_TEXT_HELP:"Button text",EXAMPLE_BUTTON_BG_COLOR:"Background color",EXAMPLE_BUTTON_BG_COLOR_HELP:"eg: #fbc14c, yellow, lightgrey, rgb(180,180,180)",EXAMPLE_BUTTON_FONT_COLOR:"Font color",EXAMPLE_BUTTON_FONT_COLOR_HELP:"eg: black, orange, rgb(180,180,180)",EXAMPLE_BUTTON_TEXT_ICON:"Icon",EX
CURRENCY_UNIT_RELATIVE:"La unidad utilizada (“<b>{{'COMMON.UD'|translate}}<sub>{{currency|abbreviate}}</sub></b>”) significa que los importes en {{currency|capitalize}} han sido divididos entre el valor del <b>Dividendo Universal</b> (DU).<br/><br/><small> Esta unidad relativa es <b>pertinente</b>, porque permanece estable, independiente de la cantidad de moneda que aumenta constantemente.</small>",CURRENCY_CHANGE_UNIT:"Este botón permite <b>cambiar la unidad</b>, para visualizar los importes <b>directamente en {{currency|capitalize}}</b> (en lugar de “<b>{{'COMMON.UD'|translate}}<sub>{{currency|abbreviate}}</sub></b>”).",CURRENCY_CHANGE_UNIT_TO_RELATIVE:"Este botón permite <b>cambiar la unidad</b>, para visualizar los importes en “<b>{{'COMMON.UD'|translate}}<sub>{{currency|abbreviate}}</sub></b>”, es decir, relativo al Dividendo Universal (el monto co-producido por cada miembro).",CURRENCY_RULES:"Las <b>reglas</b> de la moneda fijan su funcionamiento <b>exacto y previsible</b>.<br/><br/>Es el propio ADN de la moneda, que hace que su código monetario sea <b>legible y transparente</b>.",MENU_BTN_NETWORK:"El menú <b>{{'MENU.NETWORK'|translate}}</b> permite consultar el estado de la red.",NETWORK_BLOCKCHAIN:"Todas las transacciones de la moneda están registradas dentro de un gran libro de contabilidad <b>público e infalsificable</b>, conocido como la <b>cadena de bloques</b> (<em>BlockChain</em> en inglés).",NETWORK_PEERS:"Los <b>nodos</b> visibles aquí corresponden a los <b>dispositivos de miembros que actualizan y validan</b> la cadena de bloques.<br/><br/>Cuanto más nodos haya conectados, la moneda tendrá una gestión más <b>descentralizada</b> y digna de confianza.",NETWORK_PEERS_BLOCK_NUMBER:"Este <b>número</b> (en verde) indica el <b>último bloque validado</b> por este nodo (última página escrita en la cadena de bloques).<br/><br/>El color verde indica que este bloque ha sido también validado por <b>la mayoría del resto de nodos</b>.",NETWORK_PEERS_PARTICIPATE:'<b>Cada miembro</b>, equipado de un dispositivo conectado a Internet, <b>puede contribuir añadiendo un nodo</b>. Necesita <b>instalar el programa Duniter</b> (libre y gratuito). <a href="{{installDocUrl}}" target="_system">Ver manual de uso >></a>.',MENU_BTN_ACCOUNT:"<b>{{'ACCOUNT.TITLE'|translate}}</b> permite acceder a la gestión y al historial de su cuenta.",MENU_BTN_ACCOUNT_MEMBER:"Consulte aquí el estado de su cuenta y la información sobre sus certificaciones.",WALLET_CERTIFICATIONS:"Haga clic aquí para consultar el detalle de sus certificaciones (recibidas y emitidas).",WALLET_RECEIVED_CERTIFICATIONS:"Haga clic aquí para consultar el detalle de sus <b>certificaciones recibidas</b>.",WALLET_GIVEN_CERTIFICATIONS:"Haga clic aquí para consultar el detalle de sus <b>certificaciones emitidas</b>.",WALLET_BALANCE:"El <b>saldo</b> de su cuenta se visualiza aquí.",WALLET_BALANCE_RELATIVE:"{{'HELP.TIP.WALLET_BALANCE'|translate}}<br/><br/>La unidad utilizada (“<b>{{'COMMON.UD'|translate}}<sub>{{currency|abbreviate}}</sub></b>”) significa que el importe en {{currency|capitalize}} fue dividido entre el <b>Dividendo Universal</b> (DU) co-producido por cada miembro.<br/><br/>Actualmente un DU vale {{currentUD|formatInteger}} {{currency|capitalize}}s.",WALLET_BALANCE_CHANGE_UNIT:"Podrá <b>cambiar la unidad</b> de visualización de los importes en los <b><i class=\"icon ion-android-settings\"></i> {{'MENU.SETTINGS'|translate}}</b>.<br/><br/>Por ejemplo, para visualizar los importes <b>directamente en {{currency|capitalize}}</b>, en lugar de unidad relativa.",WALLET_PUBKEY:"Esta es la llave pública de su cuenta. Puede comunicarla a un tercero para que pueda identificar su cuenta de forma simple.",WALLET_SEND:"Realizar un pago en algunos clics",WALLET_SEND_NO_MONEY:"Realizar un pago en algunos clics.<br/>(Su saldo ya no lo permite)",WALLET_OPTIONS:"Este botón permite acceder a las <b>acciones de adhesión</b> y de seguridad.<br/><br/>¡No olvide echar un vistazo!",WALLET_RECEIVED_CERTS
WALLET_BALANCE_RELATIVE:"{{'HELP.TIP.WALLET_BALANCE'|translate}}<br/><br/>L'unità utilizzata (“<b>{{'COMMON.UD'|translate}}<sub>{{currency|abbreviate}}</sub></b>”) significa che questo importo in {{currency|capitalize}} è stato diviso dal <b>Dividendo Universale</b> (DU) co-creato da ogni membro.<br/>Ad oggi, 1 DU equivale a {{currentUD}} {{currency|capitalize}}.",WALLET_BALANCE_CHANGE_UNIT:"Puoi <b>cambiare l'unità</b> in cui sono mostrati gli importi in <b><i class=\"icon ion-android-settings\"></i> {{'MENU.SETTINGS'|translate}}</b>.<br/><br/>Per esempio, per mostrare gli importi <b>direttamente in {{currency|capitalize}}</b> piuttosto che in unità relativa.",WALLET_PUBKEY:"Questa è la chiave pubblica del tuo conto. La puoi dare ad un terzo perche possa identificare tuo conto.",WALLET_SEND:"Paghi in pochi clics.",WALLET_SEND_NO_MONEY:"Paghi in pochi clics.<br/>(Tuo saldo ancora non lo permette)",WALLET_OPTIONS:"Questo bottone permette di fare <b>altre, meno frequenti azioni</b>.<br/><br/> Non dimenticarti di fare il tour guidato di Cesium quando hai un attimo!",WALLET_RECEIVED_CERTS:"Questo mostra l'elenco delle persone che ti hanno fatto entrare nella WoT.",WALLET_CERTIFY:"Questo bottone <b>{{'WOT.BTN_SELECT_AND_CERTIFY'|translate}}</b> permette di selezionare e certificare una identità.<br/><br/>Solo gli utenti <b>che sono già membri</b> possono certificare gli altri.",WALLET_CERT_STOCK:"Tuo stock di certificazioni da dare è limitato a <b>{{sigStock}} certificazioni</b>.<br/><br/>Questo stock si rifornisce col tempo, man mano che le certificazioni inviate scadono.",MENU_BTN_TX:"<b>{{'MENU.TRANSACTIONS'|translate}}</b> permette l'accesso alla cronologia delle transazioni, e permette di fare nuovi bonifici.",MENU_BTN_WOT:"Il menu<b>{{'MENU.WOT'|translate}}</b> permette di cercare <b>utenti</b> della moneta (membri o non).",WOT_SEARCH_TEXT_XS:"Per fare una ricerca nel annuario, digita <b>le prime lettere dello pseudonimo o della chiave pubblica di un utente</b>.<br/><br/>La ricerca inizierà automaticamente.",WOT_SEARCH_TEXT:"Per cercare nel annuario, digita <b>le prime lettere dello pseudonimo o della chiave pubblica di un utente</b>.<br/><br/>Dopodichè calca <b>Enter</b> per avviare la ricerca.",WOT_SEARCH_RESULT:"Visualizza la scheda dettagliata di un utente con un semplice click sulla linea.",WOT_VIEW_CERTIFICATIONS:"La linea <b>{{'ACCOUNT.CERTIFICATION_COUNT'|translate}}</b> mostra quanti membri hanno certificato questa identità.<br/><br/>Queste certificazioni dimostrano che il conto appartiene ad <b>una persona viva</b> e che questa persona non ha <b>nessun altro conto membro</b>.",WOT_VIEW_CERTIFICATIONS_COUNT:"Ci vogliono almeno <b>{{sigQty}} certificazioni</b> per diventare membro e co-produrre il <b>Dividendo Universale</b>.",WOT_VIEW_CERTIFICATIONS_CLICK:"Clicca qui per aprire <b>una lista di tutte le certificazioni</b> ricevute e date da questa identità.",WOT_VIEW_CERTIFY:"Il bottone <b>{{'WOT.BTN_CERTIFY'|translate}}</b> permette di aggiungere tua certificazione a questa identità.",CERTIFY_RULES:"<b>Attenzione:</b> Certifichi <b> solo persone reali e vive</b> che non hanno nessun altro conto membro.<br/><br/>L'affidabilità della moneta dipende della vigilanza di ciascuno.",MENU_BTN_SETTINGS:"Les <b>{{'MENU.SETTINGS'|translate}}</b> ti permettono di configurare Cesium.<br/><br/>Per esempio, puoi <b>cambiare l'unità</b> in cui visualizzi la moneta.",HEADER_BAR_BTN_PROFILE:"Clicca qui per entrare nel <b>tuo profilo utente</b>",SETTINGS_CHANGE_UNIT:"Puoi cambiare <b>l'unità</b> della moneta cliccando qui.<br/><br/>- Disabilita questa opzione per vedere gli importi in {{currency|capitalize}}.<br/>- Abilita l'opzione per importi relativi in {{'COMMON.UD'|translate}}<sub>{{currency|abbreviate}}</sub> (<b>divisi</b> dal attuale Dividendo Universale).",END_LOGIN:"Il tour guidato <b>è finito</b>.<br/><br/>Benvenuto nel <b>economia libera</b>!",END_NOT_LOGIN:"Iltourguidato<b>èfinito</b>.<br/><br/>SedesiderientrarenellaWebofTrust{{currency|capitalize}},bastacliccare<b>{{
ABUSES_TEXT:"{{total}} personne{{total > 1 ? 's' : ''}} {{total > 1 ? 'ont' : 'a'}} signalé un problème",BTN_LIKE:"Me gusta",BTN_LIKE_REMOVE:"Dejar de gustarme",BTN_REMOVE_REPORTED_ABUSE:"Cancelar mi reporte",BTN_REPORT_ABUSE_DOTS:"Reportar un problema o un abuso...",COMMENT_HELP:"Comentario",LIKES_TEXT:"A {{total}} persona{{total > 1 ? 's' : ''}} {{total > 1 ? 'les' : 'le'}} gusta esta página",NOTIFICATION:{HAS_UNREAD:"Tiene {{count}} notificaci{{count>0?'ones':'ón'}} no leída{{count>0?'s':''}}",TITLE:"Nueva notificación | {{'COMMON.APP_NAME'|translate}}"},REPORT_ABUSE:{ASK_DELETE:"¿ Solicitar la eliminación ?",CONFIRM:{SENT:"Reporte enviado. ¡ Gracias !"},REASON_HELP:"Yo explico el problema...",SUB_TITLE:"Por favor explique brevemente el problema :",TITLE:"Señalar un problema"},CATEGORY:"Categoría",CATEGORIES:"Categorías",CATEGORY_SEARCH_HELP:"Búsqueda",LAST_MODIFICATION_DATE:"Actualización el",SUBMIT_BY:"Enviado por",BTN_PUBLISH:"Publicar",BTN_PICTURE_DELETE:"Suprimir",BTN_PICTURE_FAVORISE:"Principal",BTN_PICTURE_ROTATE:"Girar",BTN_ADD_PICTURE:"Añadir una foto",NOTIFICATIONS:{TITLE:"Notificaciones",MARK_ALL_AS_READ:"Marcar todo como leído",NO_RESULT:"Ningúna notificación",SHOW_ALL:"Ver todo",LOAD_NOTIFICATIONS_FAILED:"Fallo en la carga de las notificaciones"}},DOCUMENT:{HASH:"Hash: ",LOOKUP:{BTN_COMPACT:"Compactar",HAS_CREATE_OR_UPDATE_PROFILE:"ha creado o modificado su perfil",LAST_DOCUMENTS_DOTS:"Últimos documentos :",TITLE:"Búsqueda de documentos",BTN_ACTIONS:"Acciones",SEARCH_HELP:"issuer:AAA*, time:1508406169",LAST_DOCUMENTS:"Últimos documentos",SHOW_QUERY:"Ver la búsqueda",HIDE_QUERY:"Esconder la búsqueda",HEADER_TIME:"Fecha/Hora",HEADER_ISSUER:"Emisor",HEADER_RECIPIENT:"Destinatario",READ:"Leído",BTN_REMOVE:"Sumprimer este documento",POPOVER_ACTIONS:{TITLE:"Acciones",REMOVE_ALL:"Suprimir estos documentos..."}},INFO:{REMOVED:"Documento suprimido"},CONFIRM:{REMOVE:"¿ Desea <b>suprimir este documento</b> ?",REMOVE_ALL:"¿ Desea <b>suprimer estos documentos</b> ?"},ERROR:{LOAD_DOCUMENTS_FAILED:"Error al buscar los documentos",REMOVE_FAILED:"Error al suprimir el documento",REMOVE_ALL_FAILED:"Error al suprimir los documentos"}},MENU:{REGISTRY:"Páginas",USER_PROFILE:"Mi perfil",MESSAGES:"Mensajes",NOTIFICATIONS:"Notificaciones",INVITATIONS:"Invitaciones"},ACCOUNT:{NEW:{ORGANIZATION_ACCOUNT:"Cuenta para una organización",ORGANIZATION_ACCOUNT_HELP:"Si representa una empresa, una asociación, etc.<br/>Ningún dividendo universal será creído por esta cuenta."},EVENT:{MEMBER_WITHOUT_PROFILE:'Para obtener sus certificaciones más rapidamente, complete <a ui-sref="app.edit_profile">su perfil usuario</a>. Los miembros concederán más fácilmente su confianza a una identidad verificable.'},ERROR:{WS_CONNECTION_FAILED:"Cesium no puede recibir las notificaciones, a causa de un error técnico (conexión al nodo de datos Cesium+).<br/><br/>Si el problema persiste, por favor <b>elige un otro nodo de datos</b> en los ajustes de Cesium+."}},WOT:{BTN_SUGGEST_CERTIFICATIONS_DOTS:"Sugerir identidades a certificar…",BTN_ASK_CERTIFICATIONS_DOTS:"Pedir a miembros que le certifiquen…",BTN_ASK_CERTIFICATION:"Pedir una certificación",SUGGEST_CERTIFICATIONS_MODAL:{TITLE:"Sugerir certificaciones",HELP:"Selectionar sus sugerencias"},ASK_CERTIFICATIONS_MODAL:{TITLE:"Solicitar certificaciones",HELP:"Selectionar los destinatarios"},SEARCH:{DIVIDER_PROFILE:"Cuentas",DIVIDER_PAGE:"Páginas",DIVIDER_GROUP:"Grupos"},CONFIRM:{SUGGEST_CERTIFICATIONS:"¿Desea <b>enviar estas sugerencias de certificatión</b> ?",ASK_CERTIFICATION:"¿Desea <b>enviar una solicitud de certificación</b> ?",ASK_CERTIFICATIONS:"¿Desea <b>enviar una solicitud de certificación</b> a estas personas ?"}},INVITATION:{TITLE:"Invitaciones",NO_RESULT:"Ningúna invitación en espera",BTN_DELETE_ALL:"Suprimir todas las invitaciones",BTN_DELETE:"Suprimir la invitación",BTN_NEW_INVITATION:"Nueva invitación",ASK_CERTIFICATION:'<a href="#/app/wot/{{pubkey}}/{{::uid}}">{{::name||uid}}</a> solicita su certificación',SUGGESTION_CERTIFICATION:'<ahref="#/
if((r=r||{}).kind=r.kind&&r.kind.toUpperCase()||"LIKE",!t.isLogin())returne.reject("Wallet must be login before sending record to ES node");vars={version:2,index:i,type:a,id:n,kind:r.kind};returnr.comment&&(s.comment=r.comment),angular.isDefined(r.level)&&(s.level=r.level),o.raw.postRecord(s,r)}functions(e,t){if(!e)thrownewError("Missing 'id' argument");returno.raw.removeRecord(e,t)}returno.raw={getSearch:n.get("/like/record/_search?_source=false&q=:q"),searchBaseQueryString:"index:{0} AND type:{1} AND id:".format(i,a),postSearch:n.post("/like/record/_search"),postRecord:n.record.post("/{0}/{1}/:id/_like".format(i,a)),removeRecord:n.record.remove("like","record")},{index:i,type:a,toggle:function(n,i){(i=i||{}).kind=i.kind||"LIKE";vara=i.pubkey||i.wallet&&i.wallet.data.pubkey||t.isLogin()&&t.data.pubkey;returna?(i.wallet=i.wallet||t.getByPubkey(a),function(e,t){(t=t||{}).kind=t.kind||"LIKE";varn=o.raw.searchBaseQueryString+e;returnt.kind&&(n+=" AND kind:"+t.kind.toUpperCase()),t.issuer&&(n+=" AND issuer:"+t.issuer),o.raw.getSearch({q:n}).then((function(e){return(e&&e.hits&&e.hits.hits||[]).map((function(e){returne._id}))}))}(n,{kind:i.kind,issuer:a}).then((function(t){returnt&&t.length?e.all(_.map(t,(function(e){returns(e,i)}))).then((function(){return-1*t.length})):r(n,i).then((function(){return1}))}))):e.reject("User not log in!")},add:r,remove:s,count:function(e,t){(t=t||{}).kind=t.kind||"LIKE";varn={query:{bool:{filter:[{term:{index:i}},{term:{type:a}},{term:{id:e}},{term:{kind:t.kind.toUpperCase()}}]}},size:0},r=t.issuer?[t.issuer]:t.issuers;returnr&&r.length&&(n.query.bool.should={terms:{issuer:r}},n.size=r.length,n._source=["issuer"]),o.raw.postSearch(n).then((function(e){vart=e&&e.hits,n={total:t&&t.total||0,wasHitByPubkey:{},wasHitCount:0};return_.forEach(r,(function(e){vari=t?_.findIndex(t.hits||[],(function(t){returnt._source.issuer===e})):-1;n.wasHitByPubkey[e]=-1!==i||!1,n.wasHitCount+=-1!==i?1:0})),n}))}}}}}]),Q.$inject=["$scope","UIUtils","$q","Device"],ee.$inject=["$scope","$focus","$filter","UIUtils","SocialUtils"],te.$inject=["$scope"],Z.$inject=["$scope","$filter","$state","$focus","$timeout","$anchorScroll","UIUtils"],J.$inject=["$scope","UIUtils","$timeout","parameters"],ne.$inject=["$scope","$sce"],ie.$inject=["$scope","csConfig","esGeo","ModalUtils"],ae.$inject=["$scope","$q","csConfig","esGeo","ModalUtils"],oe.$inject=["$scope","$timeout","ModalUtils","csConfig","esGeo"],re.$inject=["$scope","$q","$translate","esGeo","parameters"],angular.module("cesium.es.common.controllers",["ngResource","cesium.es.services"]).controller("ESPicturesEditCtrl",Q).controller("ESPicturesEditCtrl",Q).controller("ESSocialsEditCtrl",ee).controller("ESSocialsViewCtrl",te).controller("ESCommentsCtrl",Z).controller("ESCategoryModalCtrl",J).controller("ESAvatarModalCtrl",ne).controller("ESPositionEditCtrl",ie).controller("ESLookupPositionCtrl",ae).controller("ESSearchPositionItemCtrl",oe).controller("ESSearchPositionModalCtrl",re),se.$inject=["$scope","esSettings","PluginService"],le.$inject=["$scope","$state","$controller","UIUtils","csWallet"],ce.$inject=["$scope","$q","$state","esSettings","csWallet"],angular.module("cesium.es.app.controllers",["ngResource","cesium.es.services"]).config(["PluginServiceProvider","csConfig",function(e,t){t.plugins&&t.plugins.es&&(e.extendState("app",{points:{"nav-buttons-right":{templateUrl:"plugins/es/templates/menu_extend.html",controller:"ESMenuExtendCtrl"},"menu-user":{templateUrl:"plugins/es/templates/menu_extend.html",controller:"ESMenuExtendCtrl"}}}),e.extendState("app",{points:{"profile-popover-user":{templateUrl:"plugins/es/templates/common/popover_profile_extend.html",controller:"ESProfilePopoverExtendCtrl"}}}))}]).controller("ESExtensionCtrl",se).controller("ESMenuExtendCtrl",le).controller("ESProfilePopoverExtendCtrl",ce),de.$inject=["$scope","$window","$q","$translate","$ionicPopup","UIUtils","Modals","csHttp","csConfig","csSettings","esHttp","esSettings","esModals"],angular.module("cesium.es.settings.controllers",["cesium.es.services"]).config(["PluginS