@everymatrix/user-actions 1.66.0 → 1.66.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,6 +5,7 @@ export const config = {
5
5
  taskQueue: 'async',
6
6
  sourceMap: false,
7
7
  minifyJs: true,
8
+ hashFileNames: false,
8
9
  extras: {
9
10
  experimentalImportInjection: true
10
11
  },
@@ -0,0 +1 @@
1
+ import{r as i}from"./index-2b2bb7fc.js";const o={"verification-popup":{emit:"openKycVerificationModal",listen:"closeKycVerificationModal"},"get-temporary-account-consents":{emit:"openTemporaryConsentsModal",listen:"closeTemporaryConsentsModal"},"limits-popup":{emit:"openLugasPopup",listen:"closeLugasPopup"},"video-verification-popup":{emit:"openKycVerificationModal",listen:"closeKycVerificationModal"},"unverified-phone-number":{emit:"openSmsVerificationModal",listen:"closeSmsVerificationModal"},"expired-consents":{emit:"openExpiredConsentsModal",listen:"closeExpiredConsentsModal"}},e=class{constructor(e){i(this,e),this.emitCurrentActionEvent=()=>{window.postMessage({type:o[this.actionStack[0].action].emit})},this.shiftActionStack=()=>{this.actionStack=this.actionStack.slice(1)},this.endpoint=void 0,this.userid=void 0,this.actionStack=[]}handleEvent(i){var e,t;(null===(t=o[null===(e=this.actionStack[0])||void 0===e?void 0:e.action])||void 0===t?void 0:t.listen)===i.data.type&&(this.shiftActionStack(),this.actionStack.length>0&&this.emitCurrentActionEvent())}fetchUserActions(){const i=new URL(`${this.endpoint}/v1/player/${this.userid}/legislation/actions`);return fetch(i.href).then((i=>i.json())).then((i=>{this.actionStack=i.actions.filter((i=>o[i.action])),this.actionStack.length>0&&this.emitCurrentActionEvent()}))}componentWillLoad(){return this.fetchUserActions()}render(){}};e.style=":host{display:block}";export{e as user_actions}
@@ -1 +1 @@
1
- import{p as a,b as e}from"./p-8d46bf7a.js";export{s as setNonce}from"./p-8d46bf7a.js";import{g as t}from"./p-e1255160.js";(()=>{const s=import.meta.url,e={};return""!==s&&(e.resourcesUrl=new URL(".",s).href),a(e)})().then((async a=>(await t(),e([["p-ac1b2491",[[1,"user-actions",{endpoint:[1],userid:[1],actionStack:[32]},[[8,"message","handleEvent"]]]]]],a))));
1
+ import{p as e,b as a}from"./index-2b2bb7fc.js";export{s as setNonce}from"./index-2b2bb7fc.js";import{g as t}from"./app-globals-0f993ce5.js";(()=>{const s=import.meta.url,a={};return""!==s&&(a.resourcesUrl=new URL(".",s).href),e(a)})().then((async s=>(await t(),a([["user-actions",[[1,"user-actions",{endpoint:[1],userid:[1],actionStack:[32]},[[8,"message","handleEvent"]]]]]],s))));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@everymatrix/user-actions",
3
- "version": "1.66.0",
3
+ "version": "1.66.2",
4
4
  "main": "./dist/index.cjs.js",
5
5
  "module": "./dist/index.js",
6
6
  "es2015": "./dist/esm/index.mjs",
@@ -1 +0,0 @@
1
- import{r as i}from"./p-8d46bf7a.js";const o={"verification-popup":{emit:"openKycVerificationModal",listen:"closeKycVerificationModal"},"get-temporary-account-consents":{emit:"openTemporaryConsentsModal",listen:"closeTemporaryConsentsModal"},"limits-popup":{emit:"openLugasPopup",listen:"closeLugasPopup"},"video-verification-popup":{emit:"openKycVerificationModal",listen:"closeKycVerificationModal"},"unverified-phone-number":{emit:"openSmsVerificationModal",listen:"closeSmsVerificationModal"},"expired-consents":{emit:"openExpiredConsentsModal",listen:"closeExpiredConsentsModal"}},e=class{constructor(e){i(this,e),this.emitCurrentActionEvent=()=>{window.postMessage({type:o[this.actionStack[0].action].emit})},this.shiftActionStack=()=>{this.actionStack=this.actionStack.slice(1)},this.endpoint=void 0,this.userid=void 0,this.actionStack=[]}handleEvent(i){var e,t;(null===(t=o[null===(e=this.actionStack[0])||void 0===e?void 0:e.action])||void 0===t?void 0:t.listen)===i.data.type&&(this.shiftActionStack(),this.actionStack.length>0&&this.emitCurrentActionEvent())}fetchUserActions(){const i=new URL(`${this.endpoint}/v1/player/${this.userid}/legislation/actions`);return fetch(i.href).then((i=>i.json())).then((i=>{this.actionStack=i.actions.filter((i=>o[i.action])),this.actionStack.length>0&&this.emitCurrentActionEvent()}))}componentWillLoad(){return this.fetchUserActions()}render(){}};e.style=":host{display:block}";export{e as user_actions}