@everymatrix/casino-tournaments-limited-controller 0.0.411 → 0.0.413

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.
@@ -1004,7 +1004,7 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
1004
1004
  DOMException.prototype.constructor = DOMException;
1005
1005
  }
1006
1006
 
1007
- function fetch(input, init) {
1007
+ function fetch$1(input, init) {
1008
1008
  return new Promise(function(resolve, reject) {
1009
1009
  var request = new Request(input, init);
1010
1010
 
@@ -1102,10 +1102,10 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
1102
1102
  })
1103
1103
  }
1104
1104
 
1105
- fetch.polyfill = true;
1105
+ fetch$1.polyfill = true;
1106
1106
 
1107
1107
  if (!global$1.fetch) {
1108
- global$1.fetch = fetch;
1108
+ global$1.fetch = fetch$1;
1109
1109
  global$1.Headers = Headers;
1110
1110
  global$1.Request = Request;
1111
1111
  global$1.Response = Response;
@@ -7538,15 +7538,15 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7538
7538
 
7539
7539
  function get_each_context$1(ctx, list, i) {
7540
7540
  const child_ctx = ctx.slice();
7541
- child_ctx[7] = list[i];
7541
+ child_ctx[14] = list[i];
7542
7542
  return child_ctx;
7543
7543
  }
7544
7544
 
7545
- // (35:8) {#if totalReceiver[_tab] >= 0}
7545
+ // (60:8) {#if totalReceiver[_tab] >= 0}
7546
7546
  function create_if_block$1(ctx) {
7547
7547
  let sup;
7548
7548
  let span;
7549
- let t_value = /*totalReceiver*/ ctx[0][/*_tab*/ ctx[7]] + "";
7549
+ let t_value = /*totalReceiver*/ ctx[1][/*_tab*/ ctx[14]] + "";
7550
7550
  let t;
7551
7551
 
7552
7552
  const block = {
@@ -7555,9 +7555,9 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7555
7555
  span = element("span");
7556
7556
  t = text(t_value);
7557
7557
  attr_dev(span, "part", "SupText");
7558
- add_location(span, file$1, 36, 10, 1145);
7558
+ add_location(span, file$1, 61, 10, 2075);
7559
7559
  attr_dev(sup, "part", "sup");
7560
- add_location(sup, file$1, 35, 8, 1118);
7560
+ add_location(sup, file$1, 60, 8, 2048);
7561
7561
  },
7562
7562
  m: function mount(target, anchor) {
7563
7563
  insert_dev(target, sup, anchor);
@@ -7565,7 +7565,7 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7565
7565
  append_dev(span, t);
7566
7566
  },
7567
7567
  p: function update(ctx, dirty) {
7568
- if (dirty & /*totalReceiver, __tabs*/ 9 && t_value !== (t_value = /*totalReceiver*/ ctx[0][/*_tab*/ ctx[7]] + "")) set_data_dev(t, t_value);
7568
+ if (dirty & /*totalReceiver, __tabs*/ 18 && t_value !== (t_value = /*totalReceiver*/ ctx[1][/*_tab*/ ctx[14]] + "")) set_data_dev(t, t_value);
7569
7569
  },
7570
7570
  d: function destroy(detaching) {
7571
7571
  if (detaching) detach_dev(sup);
@@ -7576,18 +7576,18 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7576
7576
  block,
7577
7577
  id: create_if_block$1.name,
7578
7578
  type: "if",
7579
- source: "(35:8) {#if totalReceiver[_tab] >= 0}",
7579
+ source: "(60:8) {#if totalReceiver[_tab] >= 0}",
7580
7580
  ctx
7581
7581
  });
7582
7582
 
7583
7583
  return block;
7584
7584
  }
7585
7585
 
7586
- // (22:4) {#each __tabs as _tab}
7586
+ // (47:4) {#each __tabs as _tab}
7587
7587
  function create_each_block$1(ctx) {
7588
7588
  let li;
7589
7589
  let span;
7590
- let t0_value = /*textReceiver*/ ctx[1][/*_tab*/ ctx[7]] + "";
7590
+ let t0_value = /*textReceiver*/ ctx[2][/*_tab*/ ctx[14]] + "";
7591
7591
  let t0;
7592
7592
  let t1;
7593
7593
  let t2;
@@ -7595,10 +7595,10 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7595
7595
  let li_part_value;
7596
7596
  let mounted;
7597
7597
  let dispose;
7598
- let if_block = /*totalReceiver*/ ctx[0][/*_tab*/ ctx[7]] >= 0 && create_if_block$1(ctx);
7598
+ let if_block = /*totalReceiver*/ ctx[1][/*_tab*/ ctx[14]] >= 0 && create_if_block$1(ctx);
7599
7599
 
7600
7600
  function click_handler() {
7601
- return /*click_handler*/ ctx[6](/*_tab*/ ctx[7]);
7601
+ return /*click_handler*/ ctx[9](/*_tab*/ ctx[14]);
7602
7602
  }
7603
7603
 
7604
7604
  const block = {
@@ -7610,10 +7610,10 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7610
7610
  if (if_block) if_block.c();
7611
7611
  t2 = space();
7612
7612
  attr_dev(span, "part", "LiText");
7613
- add_location(span, file$1, 30, 8, 1002);
7614
- attr_dev(li, "class", li_class_value = /*__tab*/ ctx[2] === /*_tab*/ ctx[7] ? 'active' : '');
7615
- attr_dev(li, "part", li_part_value = "" + (`${/*_tab*/ ctx[7]} li` + " " + (/*__tab*/ ctx[2] === /*_tab*/ ctx[7] ? 'active' : '')));
7616
- add_location(li, file$1, 22, 6, 739);
7613
+ add_location(span, file$1, 55, 8, 1932);
7614
+ attr_dev(li, "class", li_class_value = /*__tab*/ ctx[3] === /*_tab*/ ctx[14] ? 'active' : '');
7615
+ attr_dev(li, "part", li_part_value = "" + (`${/*_tab*/ ctx[14]} li` + " " + (/*__tab*/ ctx[3] === /*_tab*/ ctx[14] ? 'active' : '')));
7616
+ add_location(li, file$1, 47, 6, 1669);
7617
7617
  },
7618
7618
  m: function mount(target, anchor) {
7619
7619
  insert_dev(target, li, anchor);
@@ -7630,9 +7630,9 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7630
7630
  },
7631
7631
  p: function update(new_ctx, dirty) {
7632
7632
  ctx = new_ctx;
7633
- if (dirty & /*textReceiver, __tabs*/ 10 && t0_value !== (t0_value = /*textReceiver*/ ctx[1][/*_tab*/ ctx[7]] + "")) set_data_dev(t0, t0_value);
7633
+ if (dirty & /*textReceiver, __tabs*/ 20 && t0_value !== (t0_value = /*textReceiver*/ ctx[2][/*_tab*/ ctx[14]] + "")) set_data_dev(t0, t0_value);
7634
7634
 
7635
- if (/*totalReceiver*/ ctx[0][/*_tab*/ ctx[7]] >= 0) {
7635
+ if (/*totalReceiver*/ ctx[1][/*_tab*/ ctx[14]] >= 0) {
7636
7636
  if (if_block) {
7637
7637
  if_block.p(ctx, dirty);
7638
7638
  } else {
@@ -7645,11 +7645,11 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7645
7645
  if_block = null;
7646
7646
  }
7647
7647
 
7648
- if (dirty & /*__tab, __tabs*/ 12 && li_class_value !== (li_class_value = /*__tab*/ ctx[2] === /*_tab*/ ctx[7] ? 'active' : '')) {
7648
+ if (dirty & /*__tab, __tabs*/ 24 && li_class_value !== (li_class_value = /*__tab*/ ctx[3] === /*_tab*/ ctx[14] ? 'active' : '')) {
7649
7649
  attr_dev(li, "class", li_class_value);
7650
7650
  }
7651
7651
 
7652
- if (dirty & /*__tabs, __tab*/ 12 && li_part_value !== (li_part_value = "" + (`${/*_tab*/ ctx[7]} li` + " " + (/*__tab*/ ctx[2] === /*_tab*/ ctx[7] ? 'active' : '')))) {
7652
+ if (dirty & /*__tabs, __tab*/ 24 && li_part_value !== (li_part_value = "" + (`${/*_tab*/ ctx[14]} li` + " " + (/*__tab*/ ctx[3] === /*_tab*/ ctx[14] ? 'active' : '')))) {
7653
7653
  attr_dev(li, "part", li_part_value);
7654
7654
  }
7655
7655
  },
@@ -7665,7 +7665,7 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7665
7665
  block,
7666
7666
  id: create_each_block$1.name,
7667
7667
  type: "each",
7668
- source: "(22:4) {#each __tabs as _tab}",
7668
+ source: "(47:4) {#each __tabs as _tab}",
7669
7669
  ctx
7670
7670
  });
7671
7671
 
@@ -7675,7 +7675,7 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7675
7675
  function create_fragment$1(ctx) {
7676
7676
  let div;
7677
7677
  let ul;
7678
- let each_value = /*__tabs*/ ctx[3];
7678
+ let each_value = /*__tabs*/ ctx[4];
7679
7679
  validate_each_argument(each_value);
7680
7680
  let each_blocks = [];
7681
7681
 
@@ -7694,10 +7694,10 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7694
7694
 
7695
7695
  this.c = noop$1;
7696
7696
  attr_dev(ul, "part", "ul");
7697
- add_location(ul, file$1, 20, 2, 691);
7697
+ add_location(ul, file$1, 45, 2, 1621);
7698
7698
  attr_dev(div, "class", "casino-tournaments-tab");
7699
7699
  attr_dev(div, "part", "CustomStylingContainer");
7700
- add_location(div, file$1, 19, 0, 622);
7700
+ add_location(div, file$1, 44, 0, 1517);
7701
7701
  },
7702
7702
  l: function claim(nodes) {
7703
7703
  throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option");
@@ -7709,10 +7709,12 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7709
7709
  for (let i = 0; i < each_blocks.length; i += 1) {
7710
7710
  each_blocks[i].m(ul, null);
7711
7711
  }
7712
+
7713
+ /*div_binding*/ ctx[10](div);
7712
7714
  },
7713
7715
  p: function update(ctx, [dirty]) {
7714
- if (dirty & /*__tab, __tabs, window, totalReceiver, textReceiver*/ 15) {
7715
- each_value = /*__tabs*/ ctx[3];
7716
+ if (dirty & /*__tab, __tabs, window, totalReceiver, textReceiver*/ 30) {
7717
+ each_value = /*__tabs*/ ctx[4];
7716
7718
  validate_each_argument(each_value);
7717
7719
  let i;
7718
7720
 
@@ -7740,6 +7742,7 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7740
7742
  d: function destroy(detaching) {
7741
7743
  if (detaching) detach_dev(div);
7742
7744
  destroy_each(each_blocks, detaching);
7745
+ /*div_binding*/ ctx[10](null);
7743
7746
  }
7744
7747
  };
7745
7748
 
@@ -7761,51 +7764,106 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7761
7764
  validate_slots('undefined', slots, []);
7762
7765
  let { tabs = '' } = $$props;
7763
7766
  let { tab = undefined } = $$props;
7767
+ let { clientstyling = '' } = $$props;
7768
+ let { clientstylingurl = '' } = $$props;
7769
+ let customStylingContainer;
7770
+ let displayNone = false;
7764
7771
  let totalReceiver = {};
7765
7772
  let textReceiver = {};
7766
7773
 
7774
+ const setClientStyling = () => {
7775
+ let sheet = document.createElement('style');
7776
+ sheet.innerHTML = clientstyling;
7777
+ customStylingContainer.appendChild(sheet);
7778
+ };
7779
+
7780
+ const setClientStylingURL = () => {
7781
+ displayNone = true;
7782
+ let url = new URL(clientstylingurl);
7783
+ let cssFile = document.createElement('style');
7784
+
7785
+ fetch(url.href).then(res => res.text()).then(data => {
7786
+ cssFile.innerHTML = data;
7787
+
7788
+ if (customStylingContainer) {
7789
+ setTimeout(
7790
+ () => {
7791
+ customStylingContainer.appendChild(cssFile);
7792
+ },
7793
+ 1
7794
+ );
7795
+
7796
+ setTimeout(
7797
+ () => {
7798
+ displayNone = false;
7799
+ },
7800
+ 500
7801
+ );
7802
+ }
7803
+ });
7804
+ };
7805
+
7767
7806
  onMountMessageLifeCycle({
7768
7807
  TournamentsTabTotalUpdate: data => {
7769
- $$invalidate(0, totalReceiver = Object.assign(Object.assign({}, totalReceiver), { [data.state]: data.total }));
7808
+ $$invalidate(1, totalReceiver = Object.assign(Object.assign({}, totalReceiver), { [data.state]: data.total }));
7770
7809
  },
7771
7810
  TournamentsTabLocaleTextUpdate: data => {
7772
- $$invalidate(1, textReceiver = Object.assign(Object.assign({}, textReceiver), { [data.state]: data.text }));
7811
+ $$invalidate(2, textReceiver = Object.assign(Object.assign({}, textReceiver), { [data.state]: data.text }));
7773
7812
  }
7774
7813
  });
7775
7814
 
7776
- const writable_props = ['tabs', 'tab'];
7815
+ const writable_props = ['tabs', 'tab', 'clientstyling', 'clientstylingurl'];
7777
7816
 
7778
7817
  Object_1$1.keys($$props).forEach(key => {
7779
7818
  if (!~writable_props.indexOf(key) && key.slice(0, 2) !== '$$' && key !== 'slot') console.warn(`<undefined> was created with unknown prop '${key}'`);
7780
7819
  });
7781
7820
 
7782
7821
  const click_handler = _tab => {
7783
- $$invalidate(2, __tab = _tab);
7822
+ $$invalidate(3, __tab = _tab);
7784
7823
  window.postMessage({ type: 'TournamentsTabSwitch', tab: _tab });
7785
7824
  };
7786
7825
 
7826
+ function div_binding($$value) {
7827
+ binding_callbacks[$$value ? 'unshift' : 'push'](() => {
7828
+ customStylingContainer = $$value;
7829
+ $$invalidate(0, customStylingContainer);
7830
+ });
7831
+ }
7832
+
7787
7833
  $$self.$$set = $$props => {
7788
- if ('tabs' in $$props) $$invalidate(4, tabs = $$props.tabs);
7789
- if ('tab' in $$props) $$invalidate(5, tab = $$props.tab);
7834
+ if ('tabs' in $$props) $$invalidate(5, tabs = $$props.tabs);
7835
+ if ('tab' in $$props) $$invalidate(6, tab = $$props.tab);
7836
+ if ('clientstyling' in $$props) $$invalidate(7, clientstyling = $$props.clientstyling);
7837
+ if ('clientstylingurl' in $$props) $$invalidate(8, clientstylingurl = $$props.clientstylingurl);
7790
7838
  };
7791
7839
 
7792
7840
  $$self.$capture_state = () => ({
7793
7841
  onMountMessageLifeCycle,
7794
7842
  tabs,
7795
7843
  tab,
7844
+ clientstyling,
7845
+ clientstylingurl,
7846
+ customStylingContainer,
7847
+ displayNone,
7796
7848
  totalReceiver,
7797
7849
  textReceiver,
7850
+ setClientStyling,
7851
+ setClientStylingURL,
7798
7852
  __tab,
7799
7853
  __tabs
7800
7854
  });
7801
7855
 
7802
7856
  $$self.$inject_state = $$props => {
7803
- if ('tabs' in $$props) $$invalidate(4, tabs = $$props.tabs);
7804
- if ('tab' in $$props) $$invalidate(5, tab = $$props.tab);
7805
- if ('totalReceiver' in $$props) $$invalidate(0, totalReceiver = $$props.totalReceiver);
7806
- if ('textReceiver' in $$props) $$invalidate(1, textReceiver = $$props.textReceiver);
7807
- if ('__tab' in $$props) $$invalidate(2, __tab = $$props.__tab);
7808
- if ('__tabs' in $$props) $$invalidate(3, __tabs = $$props.__tabs);
7857
+ if ('tabs' in $$props) $$invalidate(5, tabs = $$props.tabs);
7858
+ if ('tab' in $$props) $$invalidate(6, tab = $$props.tab);
7859
+ if ('clientstyling' in $$props) $$invalidate(7, clientstyling = $$props.clientstyling);
7860
+ if ('clientstylingurl' in $$props) $$invalidate(8, clientstylingurl = $$props.clientstylingurl);
7861
+ if ('customStylingContainer' in $$props) $$invalidate(0, customStylingContainer = $$props.customStylingContainer);
7862
+ if ('displayNone' in $$props) displayNone = $$props.displayNone;
7863
+ if ('totalReceiver' in $$props) $$invalidate(1, totalReceiver = $$props.totalReceiver);
7864
+ if ('textReceiver' in $$props) $$invalidate(2, textReceiver = $$props.textReceiver);
7865
+ if ('__tab' in $$props) $$invalidate(3, __tab = $$props.__tab);
7866
+ if ('__tabs' in $$props) $$invalidate(4, __tabs = $$props.__tabs);
7809
7867
  };
7810
7868
 
7811
7869
  if ($$props && "$$inject" in $$props) {
@@ -7813,16 +7871,36 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7813
7871
  }
7814
7872
 
7815
7873
  $$self.$$.update = () => {
7816
- if ($$self.$$.dirty & /*tabs*/ 16) {
7817
- $$invalidate(3, __tabs = tabs.split(','));
7874
+ if ($$self.$$.dirty & /*customStylingContainer, clientstyling*/ 129) {
7875
+ customStylingContainer && clientstyling && setClientStyling();
7818
7876
  }
7819
7877
 
7820
- if ($$self.$$.dirty & /*tab*/ 32) {
7821
- $$invalidate(2, __tab = tab);
7878
+ if ($$self.$$.dirty & /*customStylingContainer, clientstylingurl*/ 257) {
7879
+ customStylingContainer && clientstylingurl && setClientStylingURL();
7880
+ }
7881
+
7882
+ if ($$self.$$.dirty & /*tabs*/ 32) {
7883
+ $$invalidate(4, __tabs = tabs.split(','));
7884
+ }
7885
+
7886
+ if ($$self.$$.dirty & /*tab*/ 64) {
7887
+ $$invalidate(3, __tab = tab);
7822
7888
  }
7823
7889
  };
7824
7890
 
7825
- return [totalReceiver, textReceiver, __tab, __tabs, tabs, tab, click_handler];
7891
+ return [
7892
+ customStylingContainer,
7893
+ totalReceiver,
7894
+ textReceiver,
7895
+ __tab,
7896
+ __tabs,
7897
+ tabs,
7898
+ tab,
7899
+ clientstyling,
7900
+ clientstylingurl,
7901
+ click_handler,
7902
+ div_binding
7903
+ ];
7826
7904
  }
7827
7905
 
7828
7906
  class CasinoTournamentsTab extends SvelteElement {
@@ -7840,7 +7918,12 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7840
7918
  instance$1,
7841
7919
  create_fragment$1,
7842
7920
  safe_not_equal,
7843
- { tabs: 4, tab: 5 },
7921
+ {
7922
+ tabs: 5,
7923
+ tab: 6,
7924
+ clientstyling: 7,
7925
+ clientstylingurl: 8
7926
+ },
7844
7927
  null
7845
7928
  );
7846
7929
 
@@ -7857,11 +7940,11 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7857
7940
  }
7858
7941
 
7859
7942
  static get observedAttributes() {
7860
- return ["tabs", "tab"];
7943
+ return ["tabs", "tab", "clientstyling", "clientstylingurl"];
7861
7944
  }
7862
7945
 
7863
7946
  get tabs() {
7864
- return this.$$.ctx[4];
7947
+ return this.$$.ctx[5];
7865
7948
  }
7866
7949
 
7867
7950
  set tabs(tabs) {
@@ -7870,13 +7953,31 @@ data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAgAAAAIACAYAAAD0eNT6AAAABHNCSVQICA
7870
7953
  }
7871
7954
 
7872
7955
  get tab() {
7873
- return this.$$.ctx[5];
7956
+ return this.$$.ctx[6];
7874
7957
  }
7875
7958
 
7876
7959
  set tab(tab) {
7877
7960
  this.$$set({ tab });
7878
7961
  flush();
7879
7962
  }
7963
+
7964
+ get clientstyling() {
7965
+ return this.$$.ctx[7];
7966
+ }
7967
+
7968
+ set clientstyling(clientstyling) {
7969
+ this.$$set({ clientstyling });
7970
+ flush();
7971
+ }
7972
+
7973
+ get clientstylingurl() {
7974
+ return this.$$.ctx[8];
7975
+ }
7976
+
7977
+ set clientstylingurl(clientstylingurl) {
7978
+ this.$$set({ clientstylingurl });
7979
+ flush();
7980
+ }
7880
7981
  }
7881
7982
 
7882
7983
  !customElements.get('casino-tournaments-tab') && customElements.define('casino-tournaments-tab', CasinoTournamentsTab);