crmbonus-component-wake 1.0.37 → 1.0.38

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.
Files changed (42) hide show
  1. package/dist/cjs/crm-bonus-note.cjs.entry.js +9 -1
  2. package/dist/cjs/crm-bonus-note.cjs.entry.js.map +1 -1
  3. package/dist/cjs/crmbonus-component-wake.cjs.js +1 -1
  4. package/dist/cjs/loader.cjs.js +1 -1
  5. package/dist/cjs/pedido-finalizado.cjs.entry.js +1 -1
  6. package/dist/cjs/phone-input-mask.cjs.entry.js +1 -1
  7. package/dist/collection/components/note/crm-bonus-note.js +30 -1
  8. package/dist/collection/components/note/crm-bonus-note.js.map +1 -1
  9. package/dist/collection/components/pedido/pedido.js +1 -1
  10. package/dist/collection/components/phone/phone-input-mask.js +1 -1
  11. package/dist/components/crm-bonus-note.js +10 -1
  12. package/dist/components/crm-bonus-note.js.map +1 -1
  13. package/dist/components/crm-bonus.js +3 -3
  14. package/dist/components/{p-21476699.js → p-3c29c6ad.js} +2 -2
  15. package/dist/components/{p-21476699.js.map → p-3c29c6ad.js.map} +1 -1
  16. package/dist/components/{p-5c55a55e.js → p-41d42a66.js} +2 -2
  17. package/dist/components/{p-5c55a55e.js.map → p-41d42a66.js.map} +1 -1
  18. package/dist/components/{p-5d7d182b.js → p-6c553ee7.js} +2 -2
  19. package/dist/components/{p-5d7d182b.js.map → p-6c553ee7.js.map} +1 -1
  20. package/dist/components/pedido-finalizado.js +1 -1
  21. package/dist/components/phone-cancel-input.js +1 -1
  22. package/dist/components/phone-input-mask.js +1 -1
  23. package/dist/components/phone-input.js +1 -1
  24. package/dist/crmbonus-component-wake/crmbonus-component-wake.esm.js +1 -1
  25. package/dist/crmbonus-component-wake/crmbonus-component-wake.esm.js.map +1 -1
  26. package/dist/crmbonus-component-wake/p-4c65d344.entry.js +2 -0
  27. package/dist/crmbonus-component-wake/p-4c65d344.entry.js.map +1 -0
  28. package/dist/crmbonus-component-wake/{p-cc12d99b.entry.js → p-61df4eb6.entry.js} +2 -2
  29. package/dist/crmbonus-component-wake/{p-20f2b764.entry.js → p-b36705fc.entry.js} +2 -2
  30. package/dist/esm/crm-bonus-note.entry.js +9 -1
  31. package/dist/esm/crm-bonus-note.entry.js.map +1 -1
  32. package/dist/esm/crmbonus-component-wake.js +1 -1
  33. package/dist/esm/loader.js +1 -1
  34. package/dist/esm/pedido-finalizado.entry.js +1 -1
  35. package/dist/esm/phone-input-mask.entry.js +1 -1
  36. package/dist/types/components/note/crm-bonus-note.d.ts +2 -0
  37. package/dist/types/components.d.ts +2 -0
  38. package/package.json +1 -1
  39. package/dist/crmbonus-component-wake/p-119ca508.entry.js +0 -2
  40. package/dist/crmbonus-component-wake/p-119ca508.entry.js.map +0 -1
  41. /package/dist/crmbonus-component-wake/{p-cc12d99b.entry.js.map → p-61df4eb6.entry.js.map} +0 -0
  42. /package/dist/crmbonus-component-wake/{p-20f2b764.entry.js.map → p-b36705fc.entry.js.map} +0 -0
@@ -10,13 +10,21 @@ const CrmBonusNoteStyle0 = crmBonusNoteCss;
10
10
  const CrmBonusNote = class {
11
11
  constructor(hostRef) {
12
12
  index.registerInstance(this, hostRef);
13
+ this.cartId = undefined;
13
14
  this.url = undefined;
14
15
  }
15
16
  componentWillLoad() {
16
17
  this.url = window.location.origin;
17
18
  }
19
+ handleHide() {
20
+ const amount = localStorage.getItem(this.cartId);
21
+ return !!amount;
22
+ }
18
23
  render() {
19
- return (index.h("div", { key: 'b38705934cd9d63a58b66be5c5bb8e0a0cc4b4c7' }, index.h("div", { key: '71a4b61ed58f64baa730687c54836b31a49c67a8', class: "note-container" }, index.h("p", { key: '72699b6c0c7033891cc1ae9cf31f3057e4e9ba15', class: "note-title" }, "Gift back"), index.h("p", { key: '3d893e0cefd093bed6b0fa5e65304f1cd81dfb59', class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), index.h("a", { key: '6ee7a910c2b1f3b5b088170568a314dd9e87e59e', class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
24
+ if (this.handleHide()) {
25
+ return (index.h("div", null));
26
+ }
27
+ return (index.h("div", null, index.h("div", { class: "note-container" }, index.h("p", { class: "note-title" }, "Gift back"), index.h("p", { class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), index.h("a", { class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
20
28
  }
21
29
  };
22
30
  CrmBonusNote.style = CrmBonusNoteStyle0;
@@ -1 +1 @@
1
- {"file":"crm-bonus-note.entry.cjs.js","mappings":";;;;;;AAAA,MAAM,eAAe,GAAG,2aAA2a,CAAC;AACpc,2BAAe,eAAe;;MCKjB,YAAY;;;;;IAKrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;KACrC;IAED,MAAM;QACF,QACIA,oEACIA,kEAAK,KAAK,EAAC,gBAAgB,IACvBA,gEAAG,KAAK,EAAC,YAAY,gBAEjB,EAEJA,gEAAG,KAAK,EAAC,kBAAkB,wFAEvB,EAEJA,gEAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,EACT;KACJ;;;;;;","names":["h"],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @State() url: string\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n render() {\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"version":3}
1
+ {"file":"crm-bonus-note.entry.cjs.js","mappings":";;;;;;AAAA,MAAM,eAAe,GAAG,2aAA2a,CAAC;AACpc,2BAAe,eAAe;;MCKjB,YAAY;;;;;;IAOrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;KACrC;IAED,UAAU;QACN,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QACjD,OAAO,CAAC,CAAC,MAAM,CAAC;KACnB;IAED,MAAM;QAEF,IAAG,IAAI,CAAC,UAAU,EAAE,EAAE;YAClB,QAAQA,oBAAW,EAAC;SACvB;QAED,QACIA,qBACIA,iBAAK,KAAK,EAAC,gBAAgB,IACvBA,eAAG,KAAK,EAAC,YAAY,gBAEjB,EAEJA,eAAG,KAAK,EAAC,kBAAkB,wFAEvB,EAEJA,eAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,EACT;KACJ;;;;;;","names":["h"],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, Prop, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @Prop({ attribute: 'cartid' }) cartId\n\n @State() url: string;\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n handleHide() {\n const amount = localStorage.getItem(this.cartId);\n return !!amount;\n }\n\n render() {\n\n if(this.handleHide()) {\n return (<div></div>)\n }\n\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"version":3}
@@ -19,7 +19,7 @@ var patchBrowser = () => {
19
19
 
20
20
  patchBrowser().then(async (options) => {
21
21
  await appGlobals.globalScripts();
22
- return index.bootstrapLazy([["crm-bonus.cjs",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note.cjs",[[0,"crm-bonus-note",{"url":[32]}]]],["pedido-finalizado.cjs",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask.cjs",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner.cjs",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4.cjs",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4.cjs",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
22
+ return index.bootstrapLazy([["crm-bonus.cjs",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note.cjs",[[0,"crm-bonus-note",{"cartId":[8,"cartid"],"url":[32]}]]],["pedido-finalizado.cjs",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask.cjs",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner.cjs",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4.cjs",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4.cjs",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
23
23
  });
24
24
 
25
25
  exports.setNonce = index.setNonce;
@@ -8,7 +8,7 @@ const appGlobals = require('./app-globals-3a1e7e63.js');
8
8
  const defineCustomElements = async (win, options) => {
9
9
  if (typeof window === 'undefined') return undefined;
10
10
  await appGlobals.globalScripts();
11
- return index.bootstrapLazy([["crm-bonus.cjs",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note.cjs",[[0,"crm-bonus-note",{"url":[32]}]]],["pedido-finalizado.cjs",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask.cjs",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner.cjs",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4.cjs",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4.cjs",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
11
+ return index.bootstrapLazy([["crm-bonus.cjs",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note.cjs",[[0,"crm-bonus-note",{"cartId":[8,"cartid"],"url":[32]}]]],["pedido-finalizado.cjs",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask.cjs",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner.cjs",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4.cjs",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4.cjs",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
12
12
  };
13
13
 
14
14
  exports.setNonce = index.setNonce;
@@ -27,7 +27,7 @@ const Pedido = class {
27
27
  }
28
28
  }
29
29
  render() {
30
- return (index.h("div", { key: '0110099751c9874bf52036de9a4f2d94095d7663' }));
30
+ return (index.h("div", { key: '13c169d62c8c89880108478e8f063bb9bc258d3f' }));
31
31
  }
32
32
  };
33
33
 
@@ -35,7 +35,7 @@ const PhoneInputMask = class {
35
35
  return this.phone;
36
36
  }
37
37
  render() {
38
- return (index.h("input", { key: 'ec33b7963cefd79431a0c0663df8fa1a82b09564', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
38
+ return (index.h("input", { key: '300e113a7a6983334145e9ce0ef78344bbb63974', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
39
39
  }
40
40
  };
41
41
  PhoneInputMask.style = PhoneInputMaskStyle0;
@@ -1,13 +1,21 @@
1
1
  import { h } from "@stencil/core";
2
2
  export class CrmBonusNote {
3
3
  constructor() {
4
+ this.cartId = undefined;
4
5
  this.url = undefined;
5
6
  }
6
7
  componentWillLoad() {
7
8
  this.url = window.location.origin;
8
9
  }
10
+ handleHide() {
11
+ const amount = localStorage.getItem(this.cartId);
12
+ return !!amount;
13
+ }
9
14
  render() {
10
- return (h("div", { key: 'b38705934cd9d63a58b66be5c5bb8e0a0cc4b4c7' }, h("div", { key: '71a4b61ed58f64baa730687c54836b31a49c67a8', class: "note-container" }, h("p", { key: '72699b6c0c7033891cc1ae9cf31f3057e4e9ba15', class: "note-title" }, "Gift back"), h("p", { key: '3d893e0cefd093bed6b0fa5e65304f1cd81dfb59', class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), h("a", { key: '6ee7a910c2b1f3b5b088170568a314dd9e87e59e', class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
15
+ if (this.handleHide()) {
16
+ return (h("div", null));
17
+ }
18
+ return (h("div", null, h("div", { class: "note-container" }, h("p", { class: "note-title" }, "Gift back"), h("p", { class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), h("a", { class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
11
19
  }
12
20
  static get is() { return "crm-bonus-note"; }
13
21
  static get originalStyleUrls() {
@@ -20,6 +28,27 @@ export class CrmBonusNote {
20
28
  "$": ["crm-bonus-note.css"]
21
29
  };
22
30
  }
31
+ static get properties() {
32
+ return {
33
+ "cartId": {
34
+ "type": "any",
35
+ "mutable": false,
36
+ "complexType": {
37
+ "original": "any",
38
+ "resolved": "any",
39
+ "references": {}
40
+ },
41
+ "required": false,
42
+ "optional": false,
43
+ "docs": {
44
+ "tags": [],
45
+ "text": ""
46
+ },
47
+ "attribute": "cartid",
48
+ "reflect": false
49
+ }
50
+ };
51
+ }
23
52
  static get states() {
24
53
  return {
25
54
  "url": {}
@@ -1 +1 @@
1
- {"version":3,"file":"crm-bonus-note.js","sourceRoot":"","sources":["../../../../src/components/note/crm-bonus-note.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAMpD,MAAM,OAAO,YAAY;;;;IAKrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;IACtC,CAAC;IAED,MAAM;QACF,OAAO,CACH;YACI,4DAAK,KAAK,EAAC,gBAAgB;gBACvB,0DAAG,KAAK,EAAC,YAAY,gBAEjB;gBAEJ,0DAAG,KAAK,EAAC,kBAAkB,wFAEvB;gBAEJ,0DAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,CACT,CAAA;IACL,CAAC;;;;;;;;;;;CACJ","sourcesContent":["import { Component, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @State() url: string\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n render() {\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"]}
1
+ {"version":3,"file":"crm-bonus-note.js","sourceRoot":"","sources":["../../../../src/components/note/crm-bonus-note.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAM1D,MAAM,OAAO,YAAY;;;;;IAOrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;IACtC,CAAC;IAED,UAAU;QACN,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QACjD,OAAO,CAAC,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,MAAM;QAEF,IAAG,IAAI,CAAC,UAAU,EAAE,EAAE,CAAC;YACnB,OAAO,CAAC,cAAW,CAAC,CAAA;QACxB,CAAC;QAED,OAAO,CACH;YACI,WAAK,KAAK,EAAC,gBAAgB;gBACvB,SAAG,KAAK,EAAC,YAAY,gBAEjB;gBAEJ,SAAG,KAAK,EAAC,kBAAkB,wFAEvB;gBAEJ,SAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,CACT,CAAA;IACL,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACJ","sourcesContent":["import { Component, Prop, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @Prop({ attribute: 'cartid' }) cartId\n\n @State() url: string;\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n handleHide() {\n const amount = localStorage.getItem(this.cartId);\n return !!amount;\n }\n\n render() {\n\n if(this.handleHide()) {\n return (<div></div>)\n }\n\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"]}
@@ -21,7 +21,7 @@ export class Pedido {
21
21
  }
22
22
  }
23
23
  render() {
24
- return (h("div", { key: '0110099751c9874bf52036de9a4f2d94095d7663' }));
24
+ return (h("div", { key: '13c169d62c8c89880108478e8f063bb9bc258d3f' }));
25
25
  }
26
26
  static get is() { return "pedido-finalizado"; }
27
27
  static get properties() {
@@ -26,7 +26,7 @@ export class PhoneInputMask {
26
26
  return this.phone;
27
27
  }
28
28
  render() {
29
- return (h("input", { key: 'ec33b7963cefd79431a0c0663df8fa1a82b09564', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
29
+ return (h("input", { key: '300e113a7a6983334145e9ce0ef78344bbb63974', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
30
30
  }
31
31
  static get is() { return "phone-input-mask"; }
32
32
  static get encapsulation() { return "shadow"; }
@@ -7,16 +7,25 @@ const CrmBonusNote$1 = /*@__PURE__*/ proxyCustomElement(class CrmBonusNote exten
7
7
  constructor() {
8
8
  super();
9
9
  this.__registerHost();
10
+ this.cartId = undefined;
10
11
  this.url = undefined;
11
12
  }
12
13
  componentWillLoad() {
13
14
  this.url = window.location.origin;
14
15
  }
16
+ handleHide() {
17
+ const amount = localStorage.getItem(this.cartId);
18
+ return !!amount;
19
+ }
15
20
  render() {
16
- return (h("div", { key: 'b38705934cd9d63a58b66be5c5bb8e0a0cc4b4c7' }, h("div", { key: '71a4b61ed58f64baa730687c54836b31a49c67a8', class: "note-container" }, h("p", { key: '72699b6c0c7033891cc1ae9cf31f3057e4e9ba15', class: "note-title" }, "Gift back"), h("p", { key: '3d893e0cefd093bed6b0fa5e65304f1cd81dfb59', class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), h("a", { key: '6ee7a910c2b1f3b5b088170568a314dd9e87e59e', class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
21
+ if (this.handleHide()) {
22
+ return (h("div", null));
23
+ }
24
+ return (h("div", null, h("div", { class: "note-container" }, h("p", { class: "note-title" }, "Gift back"), h("p", { class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), h("a", { class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
17
25
  }
18
26
  static get style() { return CrmBonusNoteStyle0; }
19
27
  }, [0, "crm-bonus-note", {
28
+ "cartId": [8, "cartid"],
20
29
  "url": [32]
21
30
  }]);
22
31
  function defineCustomElement$1() {
@@ -1 +1 @@
1
- {"file":"crm-bonus-note.js","mappings":";;AAAA,MAAM,eAAe,GAAG,2aAA2a,CAAC;AACpc,2BAAe,eAAe;;MCKjBA,cAAY;;;;;;IAKrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;KACrC;IAED,MAAM;QACF,QACI,8DACI,4DAAK,KAAK,EAAC,gBAAgB,IACvB,0DAAG,KAAK,EAAC,YAAY,gBAEjB,EAEJ,0DAAG,KAAK,EAAC,kBAAkB,wFAEvB,EAEJ,0DAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,EACT;KACJ;;;;;;;;;;;;;;;;;;;;;;;;;","names":["CrmBonusNote"],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @State() url: string\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n render() {\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"version":3}
1
+ {"file":"crm-bonus-note.js","mappings":";;AAAA,MAAM,eAAe,GAAG,2aAA2a,CAAC;AACpc,2BAAe,eAAe;;MCKjBA,cAAY;;;;;;;IAOrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;KACrC;IAED,UAAU;QACN,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QACjD,OAAO,CAAC,CAAC,MAAM,CAAC;KACnB;IAED,MAAM;QAEF,IAAG,IAAI,CAAC,UAAU,EAAE,EAAE;YAClB,QAAQ,cAAW,EAAC;SACvB;QAED,QACI,eACI,WAAK,KAAK,EAAC,gBAAgB,IACvB,SAAG,KAAK,EAAC,YAAY,gBAEjB,EAEJ,SAAG,KAAK,EAAC,kBAAkB,wFAEvB,EAEJ,SAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,EACT;KACJ;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["CrmBonusNote"],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, Prop, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @Prop({ attribute: 'cartid' }) cartId\n\n @State() url: string;\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n handleHide() {\n const amount = localStorage.getItem(this.cartId);\n return !!amount;\n }\n\n render() {\n\n if(this.handleHide()) {\n return (<div></div>)\n }\n\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"version":3}
@@ -7,9 +7,9 @@ import { d as defineCustomElement$8 } from './p-0e99f907.js';
7
7
  import { d as defineCustomElement$7 } from './p-e2727638.js';
8
8
  import { d as defineCustomElement$6 } from './p-ddc0ac71.js';
9
9
  import { d as defineCustomElement$5 } from './p-19b83423.js';
10
- import { d as defineCustomElement$4 } from './p-5d7d182b.js';
11
- import { d as defineCustomElement$3 } from './p-5c55a55e.js';
12
- import { d as defineCustomElement$2 } from './p-21476699.js';
10
+ import { d as defineCustomElement$4 } from './p-6c553ee7.js';
11
+ import { d as defineCustomElement$3 } from './p-41d42a66.js';
12
+ import { d as defineCustomElement$2 } from './p-3c29c6ad.js';
13
13
 
14
14
  const crmBonusCss = ".container-button{cursor:pointer;padding:5px 5px 5px 14px;}.section-crm{border:1px solid #dbd4d4;text-align:-webkit-center;margin-bottom:20px}.section-cart-crm{margin-top:10px}.section-cart-crm p{padding:0;margin:0px 0px 0px 15px}.button{top:50%;background-color:#6c6c7e;color:#fff;border:none;padding:15px;min-height:30px;min-width:120px;font-size:20px;cursor:pointer;margin-left:10px;height:70px}.form-container{width:97%;display:flex;justify-content:space-around}.btn{display:inline-block;padding:6px 12px;margin-bottom:0;font-size:14px;font-weight:400;line-height:1.42857143;text-align:center;white-space:nowrap;vertical-align:middle;-ms-touch-action:manipulation;touch-action:manipulation;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-image:none;border:1px solid transparent;border-radius:0px}.form-container .btnCrm{background:#00162e;border-color:#00162e;width:30%;color:#fff}.message-alert{font-family:sans-serif;color:#df4d4d;margin-top:5px}";
15
15
  const CrmBonusStyle0 = crmBonusCss;
@@ -33,7 +33,7 @@ const PhoneInputMask = /*@__PURE__*/ proxyCustomElement(class PhoneInputMask ext
33
33
  return this.phone;
34
34
  }
35
35
  render() {
36
- return (h("input", { key: 'ec33b7963cefd79431a0c0663df8fa1a82b09564', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
36
+ return (h("input", { key: '300e113a7a6983334145e9ce0ef78344bbb63974', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
37
37
  }
38
38
  static get style() { return PhoneInputMaskStyle0; }
39
39
  }, [1, "phone-input-mask", {
@@ -59,4 +59,4 @@ defineCustomElement();
59
59
 
60
60
  export { PhoneInputMask as P, defineCustomElement as d };
61
61
 
62
- //# sourceMappingURL=p-21476699.js.map
62
+ //# sourceMappingURL=p-3c29c6ad.js.map
@@ -1 +1 @@
1
- {"file":"p-21476699.js","mappings":";;AAAA,MAAM,iBAAiB,GAAG,ivCAAivC,CAAC;AAC5wC,6BAAe,iBAAiB;;MCMnB,cAAc;;;;;qBACE,EAAE;;;;IAI3B,iBAAiB;QACb,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,YAAY,CAAC;KAClC;IAEO,WAAW,CAAC,KAAa;QAC7B,MAAM,OAAO,GAAG,KAAK,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;QACzC,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,+BAA+B,CAAC,CAAC;QAC7D,IAAI,CAAC,KAAK;YAAE,OAAO,KAAK,CAAC;QAEzB,MAAM,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,IAAI,KAAK,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC;QAC7C,MAAM,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,KAAK,KAAK,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC;QAC9C,MAAM,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,IAAI,KAAK,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC;QAE7C,OAAO,GAAG,KAAK,GAAG,KAAK,GAAG,KAAK,EAAE,CAAC;KACrC;IAEO,WAAW,CAAC,KAAY;QAC5B,MAAM,KAAK,GAAG,KAAK,CAAC,MAA0B,CAAC;QAC/C,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;KAC9C;IAGM,MAAM,QAAQ;QACjB,OAAO,IAAI,CAAC,KAAK,CAAC;KACrB;IAED,MAAM;QACF,QACI,8DACI,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,EAAE,EAAC,OAAO,EACV,IAAI,EAAC,KAAK,EACV,KAAK,EAAC,OAAO,EACb,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,OAAO,EAAE,CAAC,KAAK,KAAK,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,EAC3C,WAAW,EAAC,iBAAiB,GAC/B,EACJ;KACL;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/phone/phone-input-mask.css?tag=phone-input-mask&encapsulation=shadow","src/components/phone/phone-input-mask.tsx"],"sourcesContent":[":host {\n width: 100%;\n}\n\n.inline-text-field-container {\n display: flex;\n flex-direction: column;\n}\n\n@supports (top: max(0%)) {\n .mdc-text-field--outlined {\n padding-right: max(16px, var(--mdc-shape-small, 4px));\n }\n}\n\n@supports (top: max(0%)) {\n .mdc-text-field--outlined {\n padding-left: max(16px, calc(var(--mdc-shape-small, 4px) + 4px));\n }\n}\n\n.mdc-text-field--outlined {\n height: 55px;\n overflow: visible;\n}\n\n.phone {\n display: block;\n width: 100%;\n height: 24px;\n padding: 6px 12px;\n font-size: 14px;\n line-height: 1.42857143;\n color: #555;\n background-color: #fff;\n background-image: none;\n border: 1px solid #ccc;\n border-radius: 0px;\n -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);\n box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);\n -webkit-transition: border-color ease-in-out .15s, -webkit-box-shadow ease-in-out .15s;\n -o-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;\n transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;\n}\n\n.mdc-text-field {\n border-top-left-radius: 4px;\n border-top-left-radius: var(--mdc-shape-small, 4px);\n border-top-right-radius: 4px;\n border-top-right-radius: var(--mdc-shape-small, 4px);\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n display: inline-flex;\n align-items: baseline;\n padding: 0 16px;\n position: relative;\n box-sizing: border-box;\n overflow: hidden;\n will-change: opacity, transform, color;\n}","import { Component, h, Method, Prop, State } from '@stencil/core';\n\n@Component({\n tag: 'phone-input-mask',\n styleUrl: 'phone-input-mask.css',\n shadow: true,\n})\nexport class PhoneInputMask {\n @State() phone: string = '';\n @Prop() initialValue: string;\n @Prop() disabled: boolean;\n\n componentWillLoad() {\n this.phone = this.initialValue; \n }\n\n private formatPhone(value: string): string {\n const cleaned = value.replace(/\\D/g, ''); // Remove tudo que não for número\n const match = cleaned.match(/^(\\d{0,2})(\\d{0,5})(\\d{0,4})$/);\n if (!match) return value;\n\n const part1 = match[1] ? `(${match[1]}` : '';\n const part2 = match[2] ? `) ${match[2]}` : '';\n const part3 = match[3] ? `-${match[3]}` : '';\n\n return `${part1}${part2}${part3}`;\n }\n\n private handleInput(event: Event): void {\n const input = event.target as HTMLInputElement;\n this.phone = this.formatPhone(input.value);\n }\n\n @Method()\n public async getPhone() {\n return this.phone;\n }\n\n render() {\n return (\n <input\n disabled={this.disabled}\n id=\"phone\"\n type=\"tel\"\n class=\"phone\"\n value={this.phone}\n onInput={(event) => this.handleInput(event)}\n placeholder=\"(12) 94567-8910\"\n />\n );\n }\n}\n"],"version":3}
1
+ {"file":"p-3c29c6ad.js","mappings":";;AAAA,MAAM,iBAAiB,GAAG,ivCAAivC,CAAC;AAC5wC,6BAAe,iBAAiB;;MCMnB,cAAc;;;;;qBACE,EAAE;;;;IAI3B,iBAAiB;QACb,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,YAAY,CAAC;KAClC;IAEO,WAAW,CAAC,KAAa;QAC7B,MAAM,OAAO,GAAG,KAAK,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;QACzC,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,+BAA+B,CAAC,CAAC;QAC7D,IAAI,CAAC,KAAK;YAAE,OAAO,KAAK,CAAC;QAEzB,MAAM,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,IAAI,KAAK,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC;QAC7C,MAAM,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,KAAK,KAAK,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC;QAC9C,MAAM,KAAK,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,IAAI,KAAK,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC;QAE7C,OAAO,GAAG,KAAK,GAAG,KAAK,GAAG,KAAK,EAAE,CAAC;KACrC;IAEO,WAAW,CAAC,KAAY;QAC5B,MAAM,KAAK,GAAG,KAAK,CAAC,MAA0B,CAAC;QAC/C,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;KAC9C;IAGM,MAAM,QAAQ;QACjB,OAAO,IAAI,CAAC,KAAK,CAAC;KACrB;IAED,MAAM;QACF,QACI,8DACI,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,EAAE,EAAC,OAAO,EACV,IAAI,EAAC,KAAK,EACV,KAAK,EAAC,OAAO,EACb,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,OAAO,EAAE,CAAC,KAAK,KAAK,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,EAC3C,WAAW,EAAC,iBAAiB,GAC/B,EACJ;KACL;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/phone/phone-input-mask.css?tag=phone-input-mask&encapsulation=shadow","src/components/phone/phone-input-mask.tsx"],"sourcesContent":[":host {\n width: 100%;\n}\n\n.inline-text-field-container {\n display: flex;\n flex-direction: column;\n}\n\n@supports (top: max(0%)) {\n .mdc-text-field--outlined {\n padding-right: max(16px, var(--mdc-shape-small, 4px));\n }\n}\n\n@supports (top: max(0%)) {\n .mdc-text-field--outlined {\n padding-left: max(16px, calc(var(--mdc-shape-small, 4px) + 4px));\n }\n}\n\n.mdc-text-field--outlined {\n height: 55px;\n overflow: visible;\n}\n\n.phone {\n display: block;\n width: 100%;\n height: 24px;\n padding: 6px 12px;\n font-size: 14px;\n line-height: 1.42857143;\n color: #555;\n background-color: #fff;\n background-image: none;\n border: 1px solid #ccc;\n border-radius: 0px;\n -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);\n box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);\n -webkit-transition: border-color ease-in-out .15s, -webkit-box-shadow ease-in-out .15s;\n -o-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;\n transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;\n}\n\n.mdc-text-field {\n border-top-left-radius: 4px;\n border-top-left-radius: var(--mdc-shape-small, 4px);\n border-top-right-radius: 4px;\n border-top-right-radius: var(--mdc-shape-small, 4px);\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n display: inline-flex;\n align-items: baseline;\n padding: 0 16px;\n position: relative;\n box-sizing: border-box;\n overflow: hidden;\n will-change: opacity, transform, color;\n}","import { Component, h, Method, Prop, State } from '@stencil/core';\n\n@Component({\n tag: 'phone-input-mask',\n styleUrl: 'phone-input-mask.css',\n shadow: true,\n})\nexport class PhoneInputMask {\n @State() phone: string = '';\n @Prop() initialValue: string;\n @Prop() disabled: boolean;\n\n componentWillLoad() {\n this.phone = this.initialValue; \n }\n\n private formatPhone(value: string): string {\n const cleaned = value.replace(/\\D/g, ''); // Remove tudo que não for número\n const match = cleaned.match(/^(\\d{0,2})(\\d{0,5})(\\d{0,4})$/);\n if (!match) return value;\n\n const part1 = match[1] ? `(${match[1]}` : '';\n const part2 = match[2] ? `) ${match[2]}` : '';\n const part3 = match[3] ? `-${match[3]}` : '';\n\n return `${part1}${part2}${part3}`;\n }\n\n private handleInput(event: Event): void {\n const input = event.target as HTMLInputElement;\n this.phone = this.formatPhone(input.value);\n }\n\n @Method()\n public async getPhone() {\n return this.phone;\n }\n\n render() {\n return (\n <input\n disabled={this.disabled}\n id=\"phone\"\n type=\"tel\"\n class=\"phone\"\n value={this.phone}\n onInput={(event) => this.handleInput(event)}\n placeholder=\"(12) 94567-8910\"\n />\n );\n }\n}\n"],"version":3}
@@ -1,6 +1,6 @@
1
1
  import { p as proxyCustomElement, H, h } from './p-faf7103e.js';
2
2
  import { d as defineCustomElement$2 } from './p-ddc0ac71.js';
3
- import { d as defineCustomElement$1 } from './p-21476699.js';
3
+ import { d as defineCustomElement$1 } from './p-3c29c6ad.js';
4
4
 
5
5
  const PhoneInput = /*@__PURE__*/ proxyCustomElement(class PhoneInput extends H {
6
6
  constructor() {
@@ -49,4 +49,4 @@ defineCustomElement();
49
49
 
50
50
  export { PhoneInput as P, defineCustomElement as d };
51
51
 
52
- //# sourceMappingURL=p-5c55a55e.js.map
52
+ //# sourceMappingURL=p-41d42a66.js.map
@@ -1 +1 @@
1
- {"file":"p-5c55a55e.js","mappings":";;;;MAKa,UAAU;;;;;;;;IAQnB,MAAM,aAAa;QACf,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,QAAQ,EAAE,CAAC;QACnD,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;KAC7B;IAED,MAAM;QACF,QACI,4DAAK,KAAK,EAAC,gBAAgB,IACvB,yEAAkB,YAAY,EAAE,IAAI,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,IAAI,IAAI,CAAC,cAAc,GAAG,GAAG,GAAI,EACrF,+DAAQ,KAAK,EAAE,0BAA0B,IAAI,CAAC,OAAO,GAAG,UAAU,GAAG,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC,aAAa,EAAE,IAE/H,CAAC,IAAI,CAAC,OAAO,GAAG,SAAS,GAAG,uBAAiB,IAAI,EAAC,MAAM,EAAC,KAAK,EAAC,MAAM,GAAG,CAEvE,CACP,EACT;KACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/crm-bonus-form/subcomponents/phone/phone.input.tsx"],"sourcesContent":["import { Component, Prop, h } from \"@stencil/core\";\n\n@Component({\n tag: 'phone-input'\n})\nexport class PhoneInput {\n\n private phoneInputMask: HTMLPhoneInputMaskElement;\n\n @Prop() sendPin: Function;\n @Prop() loading: boolean;\n @Prop() value: string;\n\n async validatePhone() {\n const phone = await this.phoneInputMask.getPhone();\n await this.sendPin(phone);\n }\n\n render() {\n return (\n <div class=\"form-container\">\n <phone-input-mask initialValue={this.value} ref={ref => this.phoneInputMask = ref} />\n <button class={`btn btn-success btnCrm ${this.loading ? 'disabled' : ''} `} disabled={this.loading} onClick={() => this.validatePhone()}>\n {\n !this.loading ? \"validar\" : <loading-spinner size=\"11px\" color=\"#fff\" />\n }\n </button>\n </div>\n )\n }\n}"],"version":3}
1
+ {"file":"p-41d42a66.js","mappings":";;;;MAKa,UAAU;;;;;;;;IAQnB,MAAM,aAAa;QACf,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,QAAQ,EAAE,CAAC;QACnD,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;KAC7B;IAED,MAAM;QACF,QACI,4DAAK,KAAK,EAAC,gBAAgB,IACvB,yEAAkB,YAAY,EAAE,IAAI,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,IAAI,IAAI,CAAC,cAAc,GAAG,GAAG,GAAI,EACrF,+DAAQ,KAAK,EAAE,0BAA0B,IAAI,CAAC,OAAO,GAAG,UAAU,GAAG,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC,aAAa,EAAE,IAE/H,CAAC,IAAI,CAAC,OAAO,GAAG,SAAS,GAAG,uBAAiB,IAAI,EAAC,MAAM,EAAC,KAAK,EAAC,MAAM,GAAG,CAEvE,CACP,EACT;KACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/crm-bonus-form/subcomponents/phone/phone.input.tsx"],"sourcesContent":["import { Component, Prop, h } from \"@stencil/core\";\n\n@Component({\n tag: 'phone-input'\n})\nexport class PhoneInput {\n\n private phoneInputMask: HTMLPhoneInputMaskElement;\n\n @Prop() sendPin: Function;\n @Prop() loading: boolean;\n @Prop() value: string;\n\n async validatePhone() {\n const phone = await this.phoneInputMask.getPhone();\n await this.sendPin(phone);\n }\n\n render() {\n return (\n <div class=\"form-container\">\n <phone-input-mask initialValue={this.value} ref={ref => this.phoneInputMask = ref} />\n <button class={`btn btn-success btnCrm ${this.loading ? 'disabled' : ''} `} disabled={this.loading} onClick={() => this.validatePhone()}>\n {\n !this.loading ? \"validar\" : <loading-spinner size=\"11px\" color=\"#fff\" />\n }\n </button>\n </div>\n )\n }\n}"],"version":3}
@@ -1,6 +1,6 @@
1
1
  import { p as proxyCustomElement, H, h } from './p-faf7103e.js';
2
2
  import { d as defineCustomElement$2 } from './p-ddc0ac71.js';
3
- import { d as defineCustomElement$1 } from './p-21476699.js';
3
+ import { d as defineCustomElement$1 } from './p-3c29c6ad.js';
4
4
 
5
5
  const PhoneCancelInput = /*@__PURE__*/ proxyCustomElement(class PhoneCancelInput extends H {
6
6
  constructor() {
@@ -49,4 +49,4 @@ defineCustomElement();
49
49
 
50
50
  export { PhoneCancelInput as P, defineCustomElement as d };
51
51
 
52
- //# sourceMappingURL=p-5d7d182b.js.map
52
+ //# sourceMappingURL=p-6c553ee7.js.map
@@ -1 +1 @@
1
- {"file":"p-5d7d182b.js","mappings":";;;;MAKa,gBAAgB;;;;;;;;IAQzB,MAAM,aAAa;QACf,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,QAAQ,EAAE,CAAC;QACnD,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;KAC7B;IAED,MAAM;QACF,QACI,4DAAK,KAAK,EAAC,gBAAgB,IACvB,yEAAkB,YAAY,EAAE,qBAAqB,IAAI,CAAC,KAAK,EAAE,EAAE,GAAG,EAAE,GAAG,IAAI,IAAI,CAAC,cAAc,GAAG,GAAG,EAAE,QAAQ,EAAE,IAAI,GAAI,EAC5H,+DAAQ,KAAK,EAAE,0BAA0B,IAAI,CAAC,OAAO,GAAG,UAAU,GAAG,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC,aAAa,EAAE,IAE/H,CAAC,IAAI,CAAC,OAAO,GAAG,UAAU,GAAG,uBAAiB,IAAI,EAAC,MAAM,EAAC,KAAK,EAAC,MAAM,GAAG,CAExE,CACP,EACT;KACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/crm-bonus-form/subcomponents/phone-cancel/phone.cancel.input.tsx"],"sourcesContent":["import { Component, Prop, h } from \"@stencil/core\";\n\n@Component({\n tag: 'phone-cancel-input'\n})\nexport class PhoneCancelInput {\n\n private phoneInputMask: HTMLPhoneInputMaskElement;\n\n @Prop() sendPin: Function;\n @Prop() loading: boolean;\n @Prop() value: string;\n\n async validatePhone() {\n const phone = await this.phoneInputMask.getPhone();\n await this.sendPin(phone);\n }\n\n render() {\n return (\n <div class=\"form-container\">\n <phone-input-mask initialValue={`Valor aplicado R$ ${this.value}`} ref={ref => this.phoneInputMask = ref} disabled={true} />\n <button class={`btn btn-success btnCrm ${this.loading ? 'disabled' : ''} `} disabled={this.loading} onClick={() => this.validatePhone()}>\n {\n !this.loading ? \"Cancelar\" : <loading-spinner size=\"11px\" color=\"#fff\" />\n }\n </button>\n </div>\n )\n }\n}"],"version":3}
1
+ {"file":"p-6c553ee7.js","mappings":";;;;MAKa,gBAAgB;;;;;;;;IAQzB,MAAM,aAAa;QACf,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,QAAQ,EAAE,CAAC;QACnD,MAAM,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;KAC7B;IAED,MAAM;QACF,QACI,4DAAK,KAAK,EAAC,gBAAgB,IACvB,yEAAkB,YAAY,EAAE,qBAAqB,IAAI,CAAC,KAAK,EAAE,EAAE,GAAG,EAAE,GAAG,IAAI,IAAI,CAAC,cAAc,GAAG,GAAG,EAAE,QAAQ,EAAE,IAAI,GAAI,EAC5H,+DAAQ,KAAK,EAAE,0BAA0B,IAAI,CAAC,OAAO,GAAG,UAAU,GAAG,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC,aAAa,EAAE,IAE/H,CAAC,IAAI,CAAC,OAAO,GAAG,UAAU,GAAG,uBAAiB,IAAI,EAAC,MAAM,EAAC,KAAK,EAAC,MAAM,GAAG,CAExE,CACP,EACT;KACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/crm-bonus-form/subcomponents/phone-cancel/phone.cancel.input.tsx"],"sourcesContent":["import { Component, Prop, h } from \"@stencil/core\";\n\n@Component({\n tag: 'phone-cancel-input'\n})\nexport class PhoneCancelInput {\n\n private phoneInputMask: HTMLPhoneInputMaskElement;\n\n @Prop() sendPin: Function;\n @Prop() loading: boolean;\n @Prop() value: string;\n\n async validatePhone() {\n const phone = await this.phoneInputMask.getPhone();\n await this.sendPin(phone);\n }\n\n render() {\n return (\n <div class=\"form-container\">\n <phone-input-mask initialValue={`Valor aplicado R$ ${this.value}`} ref={ref => this.phoneInputMask = ref} disabled={true} />\n <button class={`btn btn-success btnCrm ${this.loading ? 'disabled' : ''} `} disabled={this.loading} onClick={() => this.validatePhone()}>\n {\n !this.loading ? \"Cancelar\" : <loading-spinner size=\"11px\" color=\"#fff\" />\n }\n </button>\n </div>\n )\n }\n}"],"version":3}
@@ -24,7 +24,7 @@ const Pedido = /*@__PURE__*/ proxyCustomElement(class Pedido extends H {
24
24
  }
25
25
  }
26
26
  render() {
27
- return (h("div", { key: '0110099751c9874bf52036de9a4f2d94095d7663' }));
27
+ return (h("div", { key: '13c169d62c8c89880108478e8f063bb9bc258d3f' }));
28
28
  }
29
29
  }, [0, "pedido-finalizado", {
30
30
  "cartId": [1, "cartid"],
@@ -1,4 +1,4 @@
1
- import { P as PhoneCancelInput$1, d as defineCustomElement$1 } from './p-5d7d182b.js';
1
+ import { P as PhoneCancelInput$1, d as defineCustomElement$1 } from './p-6c553ee7.js';
2
2
 
3
3
  const PhoneCancelInput = PhoneCancelInput$1;
4
4
  const defineCustomElement = defineCustomElement$1;
@@ -1,4 +1,4 @@
1
- import { P as PhoneInputMask$1, d as defineCustomElement$1 } from './p-21476699.js';
1
+ import { P as PhoneInputMask$1, d as defineCustomElement$1 } from './p-3c29c6ad.js';
2
2
 
3
3
  const PhoneInputMask = PhoneInputMask$1;
4
4
  const defineCustomElement = defineCustomElement$1;
@@ -1,4 +1,4 @@
1
- import { P as PhoneInput$1, d as defineCustomElement$1 } from './p-5c55a55e.js';
1
+ import { P as PhoneInput$1, d as defineCustomElement$1 } from './p-41d42a66.js';
2
2
 
3
3
  const PhoneInput = PhoneInput$1;
4
4
  const defineCustomElement = defineCustomElement$1;
@@ -1,2 +1,2 @@
1
- import{p as e,b as a}from"./p-72510682.js";export{s as setNonce}from"./p-72510682.js";import{g as n}from"./p-e1255160.js";var o=()=>{const a=import.meta.url;const n={};if(a!==""){n.resourcesUrl=new URL(".",a).href}return e(n)};o().then((async e=>{await n();return a([["p-c12fd96a",[[1,"crm-bonus",{userId:[2,"userid"],storeName:[8,"storename"],productsInString:[1,"products"],cartId:[8,"cartid"],showModal:[32],products:[32],customer:[32],loading:[32],message:[32],phone:[32],canCancel:[32],amountCancel:[32],sent:[32]}]]],["p-119ca508",[[0,"crm-bonus-note",{url:[32]}]]],["p-20f2b764",[[0,"pedido-finalizado",{cartId:[1,"cartid"],orderId:[2,"orderid"],metadadoString:[1,"metadado"]}]]],["p-cc12d99b",[[1,"phone-input-mask",{initialValue:[1,"initial-value"],disabled:[4],phone:[32],getPhone:[64]}]]],["p-a01c57ab",[[1,"loading-spinner",{size:[1],color:[1]}]]],["p-2636f2f0",[[1,"giftback-pin",{sent:[16],validate:[16],cancel:[16],loading:[4],pin:[32],isVerified:[32]}],[1,"giftback-progress",{loading:[4],bonus:[16],reserve:[16],cancel:[16],usedValue:[32]}],[0,"name-input",{value:[1],loading:[4],applyName:[16],cancel:[16],newValue:[32],message:[32]}],[1,"giftback-finish"]]],["p-b5e9ea5d",[[1,"crm-bonus-form",{storeName:[8,"storename"],cartId:[8,"cart-id"],products:[16],customer:[16],sent:[16],stepNext:[2,"step-next"],phone:[2],loadingModal:[4,"loading-modal"],saveStore:[16],cancel:[16],handleCustomerName:[16],loading:[32],step:[32],message:[32],bonus:[32],setStep:[64]}],[0,"phone-cancel-input",{sendPin:[16],loading:[4],value:[1]}],[0,"phone-input",{sendPin:[16],loading:[4],value:[1]}],[1,"app-modal",{isOpen:[516,"is-open"],modalTitle:[1,"modal-title"]}]]]],e)}));
1
+ import{p as e,b as a}from"./p-72510682.js";export{s as setNonce}from"./p-72510682.js";import{g as n}from"./p-e1255160.js";var o=()=>{const a=import.meta.url;const n={};if(a!==""){n.resourcesUrl=new URL(".",a).href}return e(n)};o().then((async e=>{await n();return a([["p-c12fd96a",[[1,"crm-bonus",{userId:[2,"userid"],storeName:[8,"storename"],productsInString:[1,"products"],cartId:[8,"cartid"],showModal:[32],products:[32],customer:[32],loading:[32],message:[32],phone:[32],canCancel:[32],amountCancel:[32],sent:[32]}]]],["p-4c65d344",[[0,"crm-bonus-note",{cartId:[8,"cartid"],url:[32]}]]],["p-b36705fc",[[0,"pedido-finalizado",{cartId:[1,"cartid"],orderId:[2,"orderid"],metadadoString:[1,"metadado"]}]]],["p-61df4eb6",[[1,"phone-input-mask",{initialValue:[1,"initial-value"],disabled:[4],phone:[32],getPhone:[64]}]]],["p-a01c57ab",[[1,"loading-spinner",{size:[1],color:[1]}]]],["p-2636f2f0",[[1,"giftback-pin",{sent:[16],validate:[16],cancel:[16],loading:[4],pin:[32],isVerified:[32]}],[1,"giftback-progress",{loading:[4],bonus:[16],reserve:[16],cancel:[16],usedValue:[32]}],[0,"name-input",{value:[1],loading:[4],applyName:[16],cancel:[16],newValue:[32],message:[32]}],[1,"giftback-finish"]]],["p-b5e9ea5d",[[1,"crm-bonus-form",{storeName:[8,"storename"],cartId:[8,"cart-id"],products:[16],customer:[16],sent:[16],stepNext:[2,"step-next"],phone:[2],loadingModal:[4,"loading-modal"],saveStore:[16],cancel:[16],handleCustomerName:[16],loading:[32],step:[32],message:[32],bonus:[32],setStep:[64]}],[0,"phone-cancel-input",{sendPin:[16],loading:[4],value:[1]}],[0,"phone-input",{sendPin:[16],loading:[4],value:[1]}],[1,"app-modal",{isOpen:[516,"is-open"],modalTitle:[1,"modal-title"]}]]]],e)}));
2
2
  //# sourceMappingURL=crmbonus-component-wake.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","async","options","globalScripts","bootstrapLazy","userId","storeName","productsInString","cartId","showModal","products","customer","loading","message","phone","canCancel","amountCancel","sent","orderId","metadadoString","initialValue","disabled","getPhone","size","color","validate","cancel","pin","isVerified","bonus","reserve","usedValue","value","applyName","newValue","stepNext","loadingModal","saveStore","handleCustomerName","step","setStep","sendPin","isOpen","modalTitle"],"sources":["node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v4.22.2 | MIT Licensed | https://stenciljs.com\n */\n\n// src/client/client-patch-browser.ts\nimport { BUILD, NAMESPACE } from \"@stencil/core/internal/app-data\";\nimport { consoleDevInfo, doc, H, promiseResolve } from \"@stencil/core\";\nvar patchBrowser = () => {\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo(\"Running in development mode.\");\n }\n if (BUILD.cloneNodeFix) {\n patchCloneNodeFix(H.prototype);\n }\n const scriptElm = BUILD.scriptDataOpts ? Array.from(doc.querySelectorAll(\"script\")).find(\n (s) => new RegExp(`/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) || s.getAttribute(\"data-stencil-namespace\") === NAMESPACE\n ) : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})[\"data-opts\"] || {} : {};\n if (importMeta !== \"\") {\n opts.resourcesUrl = new URL(\".\", importMeta).href;\n }\n return promiseResolve(opts);\n};\nvar patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function(deep) {\n if (this.nodeName === \"TEMPLATE\") {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport {\n patchBrowser\n};\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(async (options) => {\n await globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"0HAOA,IAAIA,EAAe,KAUjB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAC3E,GAAIF,IAAe,GAAI,CACrBE,EAAKC,aAAe,IAAIC,IAAI,IAAKJ,GAAYK,IACjD,CACE,OAAOC,EAAeJ,EAAK,EClB7BH,IAAeQ,MAAKC,MAAOC,UACnBC,IACN,OAAOC,EAAc,+BAA8B,CAAAC,OAAS,aAAAC,UAAA,gBAAAC,iBAAA,eAAAC,OAAA,aAAAC,UAAA,KAAAC,SAAA,KAAAC,SAAA,KAAAC,QAAA,KAAAC,QAAA,KAAAC,MAAA,KAAAC,UAAA,KAAAC,aAAA,KAAAC,KAAA,6CAAAvB,IAAA,gDAAAc,OAAA,aAAAU,QAAA,cAAAC,eAAA,yDAAAC,aAAA,oBAAAC,SAAA,IAAAP,MAAA,KAAAQ,SAAA,8CAAAC,KAAA,IAAAC,MAAA,0CAAAP,KAAA,KAAAQ,SAAA,KAAAC,OAAA,KAAAd,QAAA,IAAAe,IAAA,KAAAC,WAAA,+BAAAhB,QAAA,IAAAiB,MAAA,KAAAC,QAAA,KAAAJ,OAAA,KAAAK,UAAA,wBAAAC,MAAA,IAAApB,QAAA,IAAAqB,UAAA,KAAAP,OAAA,KAAAQ,SAAA,KAAArB,QAAA,mEAAAP,UAAA,gBAAAE,OAAA,cAAAE,SAAA,KAAAC,SAAA,KAAAM,KAAA,KAAAkB,SAAA,gBAAArB,MAAA,IAAAsB,aAAA,oBAAAC,UAAA,KAAAX,OAAA,KAAAY,mBAAA,KAAA1B,QAAA,KAAA2B,KAAA,KAAA1B,QAAA,KAAAgB,MAAA,KAAAW,QAAA,gCAAAC,QAAA,KAAA7B,QAAA,IAAAoB,MAAA,wBAAAS,QAAA,KAAA7B,QAAA,IAAAoB,MAAA,sBAAAU,OAAA,gBAAAC,WAAA,uBAAAzC,EAAA","ignoreList":[]}
1
+ {"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","async","options","globalScripts","bootstrapLazy","userId","storeName","productsInString","cartId","showModal","products","customer","loading","message","phone","canCancel","amountCancel","sent","orderId","metadadoString","initialValue","disabled","getPhone","size","color","validate","cancel","pin","isVerified","bonus","reserve","usedValue","value","applyName","newValue","stepNext","loadingModal","saveStore","handleCustomerName","step","setStep","sendPin","isOpen","modalTitle"],"sources":["node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v4.22.2 | MIT Licensed | https://stenciljs.com\n */\n\n// src/client/client-patch-browser.ts\nimport { BUILD, NAMESPACE } from \"@stencil/core/internal/app-data\";\nimport { consoleDevInfo, doc, H, promiseResolve } from \"@stencil/core\";\nvar patchBrowser = () => {\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo(\"Running in development mode.\");\n }\n if (BUILD.cloneNodeFix) {\n patchCloneNodeFix(H.prototype);\n }\n const scriptElm = BUILD.scriptDataOpts ? Array.from(doc.querySelectorAll(\"script\")).find(\n (s) => new RegExp(`/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) || s.getAttribute(\"data-stencil-namespace\") === NAMESPACE\n ) : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})[\"data-opts\"] || {} : {};\n if (importMeta !== \"\") {\n opts.resourcesUrl = new URL(\".\", importMeta).href;\n }\n return promiseResolve(opts);\n};\nvar patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function(deep) {\n if (this.nodeName === \"TEMPLATE\") {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport {\n patchBrowser\n};\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(async (options) => {\n await globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"0HAOA,IAAIA,EAAe,KAUjB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAC3E,GAAIF,IAAe,GAAI,CACrBE,EAAKC,aAAe,IAAIC,IAAI,IAAKJ,GAAYK,IACjD,CACE,OAAOC,EAAeJ,EAAK,EClB7BH,IAAeQ,MAAKC,MAAOC,UACnBC,IACN,OAAOC,EAAc,+BAA8B,CAAAC,OAAS,aAAAC,UAAA,gBAAAC,iBAAA,eAAAC,OAAA,aAAAC,UAAA,KAAAC,SAAA,KAAAC,SAAA,KAAAC,QAAA,KAAAC,QAAA,KAAAC,MAAA,KAAAC,UAAA,KAAAC,aAAA,KAAAC,KAAA,6CAAAT,OAAA,aAAAd,IAAA,gDAAAc,OAAA,aAAAU,QAAA,cAAAC,eAAA,yDAAAC,aAAA,oBAAAC,SAAA,IAAAP,MAAA,KAAAQ,SAAA,8CAAAC,KAAA,IAAAC,MAAA,0CAAAP,KAAA,KAAAQ,SAAA,KAAAC,OAAA,KAAAd,QAAA,IAAAe,IAAA,KAAAC,WAAA,+BAAAhB,QAAA,IAAAiB,MAAA,KAAAC,QAAA,KAAAJ,OAAA,KAAAK,UAAA,wBAAAC,MAAA,IAAApB,QAAA,IAAAqB,UAAA,KAAAP,OAAA,KAAAQ,SAAA,KAAArB,QAAA,mEAAAP,UAAA,gBAAAE,OAAA,cAAAE,SAAA,KAAAC,SAAA,KAAAM,KAAA,KAAAkB,SAAA,gBAAArB,MAAA,IAAAsB,aAAA,oBAAAC,UAAA,KAAAX,OAAA,KAAAY,mBAAA,KAAA1B,QAAA,KAAA2B,KAAA,KAAA1B,QAAA,KAAAgB,MAAA,KAAAW,QAAA,gCAAAC,QAAA,KAAA7B,QAAA,IAAAoB,MAAA,wBAAAS,QAAA,KAAA7B,QAAA,IAAAoB,MAAA,sBAAAU,OAAA,gBAAAC,WAAA,uBAAAzC,EAAA","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ import{r as t,h as o}from"./p-72510682.js";const n=".note-container{border:1px solid #dddddd;padding:0 15px 15px;margin:0 0 26px 0px}.note-container .back-cart{display:flex;text-align:center}.note-title{font-weight:700;height:2em;line-height:2em;text-align:left;border-radius:3px;color:#333;margin-bottom:1.4em}.note-description{font-family:Arial;color:#6d6d5f;padding:0;margin:0 auto}.back-cart{font-size:.9em;color:#337ab7;text-decoration:none;cursor:pointer;margin-top:11px}";const e=n;const i=class{constructor(o){t(this,o);this.cartId=undefined;this.url=undefined}componentWillLoad(){this.url=window.location.origin}handleHide(){const t=localStorage.getItem(this.cartId);return!!t}render(){if(this.handleHide()){return o("div",null)}return o("div",null,o("div",{class:"note-container"},o("p",{class:"note-title"},"Gift back"),o("p",{class:"note-description"},"Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!"),o("a",{class:"back-cart",href:this.url},"Voltar ao carrinho")))}};i.style=e;export{i as crm_bonus_note};
2
+ //# sourceMappingURL=p-4c65d344.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["crmBonusNoteCss","CrmBonusNoteStyle0","CrmBonusNote","componentWillLoad","this","url","window","location","origin","handleHide","amount","localStorage","getItem","cartId","render","h","class","href"],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, Prop, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @Prop({ attribute: 'cartid' }) cartId\n\n @State() url: string;\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n handleHide() {\n const amount = localStorage.getItem(this.cartId);\n return !!amount;\n }\n\n render() {\n\n if(this.handleHide()) {\n return (<div></div>)\n }\n\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"mappings":"2CAAA,MAAMA,EAAkB,4aACxB,MAAAC,EAAeD,E,MCKFE,EAAY,M,kEAOrB,iBAAAC,GACIC,KAAKC,IAAMC,OAAOC,SAASC,M,CAG/B,UAAAC,GACI,MAAMC,EAASC,aAAaC,QAAQR,KAAKS,QACzC,QAASH,C,CAGb,MAAAI,GAEI,GAAGV,KAAKK,aAAc,CAClB,OAAQM,EAAA,W,CAGZ,OACIA,EAAA,WACIA,EAAA,OAAKC,MAAM,kBACPD,EAAA,KAAGC,MAAM,cAAY,aAIrBD,EAAA,KAAGC,MAAM,oBAAkB,gFAI3BD,EAAA,KAAGC,MAAM,YAAYC,KAAMb,KAAKC,KAAG,uB","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{r as o,h as e}from"./p-72510682.js";const t=":host{width:100%}.inline-text-field-container{display:flex;flex-direction:column}@supports (top: max(0%)){.mdc-text-field--outlined{padding-right:max(16px, var(--mdc-shape-small, 4px))}}@supports (top: max(0%)){.mdc-text-field--outlined{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}.mdc-text-field--outlined{height:55px;overflow:visible}.phone{display:block;width:100%;height:24px;padding:6px 12px;font-size:14px;line-height:1.42857143;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:0px;-webkit-box-shadow:inset 0 1px 1px rgba(0, 0, 0, .075);box-shadow:inset 0 1px 1px rgba(0, 0, 0, .075);-webkit-transition:border-color ease-in-out .15s, -webkit-box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s, box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s, box-shadow ease-in-out .15s}.mdc-text-field{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:0;border-bottom-left-radius:0;display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity, transform, color}";const i=t;const s=class{constructor(e){o(this,e);this.phone="";this.initialValue=undefined;this.disabled=undefined}componentWillLoad(){this.phone=this.initialValue}formatPhone(o){const e=o.replace(/\D/g,"");const t=e.match(/^(\d{0,2})(\d{0,5})(\d{0,4})$/);if(!t)return o;const i=t[1]?`(${t[1]}`:"";const s=t[2]?`) ${t[2]}`:"";const r=t[3]?`-${t[3]}`:"";return`${i}${s}${r}`}handleInput(o){const e=o.target;this.phone=this.formatPhone(e.value)}async getPhone(){return this.phone}render(){return e("input",{key:"ec33b7963cefd79431a0c0663df8fa1a82b09564",disabled:this.disabled,id:"phone",type:"tel",class:"phone",value:this.phone,onInput:o=>this.handleInput(o),placeholder:"(12) 94567-8910"})}};s.style=i;export{s as phone_input_mask};
2
- //# sourceMappingURL=p-cc12d99b.entry.js.map
1
+ import{r as e,h as o}from"./p-72510682.js";const t=":host{width:100%}.inline-text-field-container{display:flex;flex-direction:column}@supports (top: max(0%)){.mdc-text-field--outlined{padding-right:max(16px, var(--mdc-shape-small, 4px))}}@supports (top: max(0%)){.mdc-text-field--outlined{padding-left:max(16px, calc(var(--mdc-shape-small, 4px) + 4px))}}.mdc-text-field--outlined{height:55px;overflow:visible}.phone{display:block;width:100%;height:24px;padding:6px 12px;font-size:14px;line-height:1.42857143;color:#555;background-color:#fff;background-image:none;border:1px solid #ccc;border-radius:0px;-webkit-box-shadow:inset 0 1px 1px rgba(0, 0, 0, .075);box-shadow:inset 0 1px 1px rgba(0, 0, 0, .075);-webkit-transition:border-color ease-in-out .15s, -webkit-box-shadow ease-in-out .15s;-o-transition:border-color ease-in-out .15s, box-shadow ease-in-out .15s;transition:border-color ease-in-out .15s, box-shadow ease-in-out .15s}.mdc-text-field{border-top-left-radius:4px;border-top-left-radius:var(--mdc-shape-small, 4px);border-top-right-radius:4px;border-top-right-radius:var(--mdc-shape-small, 4px);border-bottom-right-radius:0;border-bottom-left-radius:0;display:inline-flex;align-items:baseline;padding:0 16px;position:relative;box-sizing:border-box;overflow:hidden;will-change:opacity, transform, color}";const i=t;const s=class{constructor(o){e(this,o);this.phone="";this.initialValue=undefined;this.disabled=undefined}componentWillLoad(){this.phone=this.initialValue}formatPhone(e){const o=e.replace(/\D/g,"");const t=o.match(/^(\d{0,2})(\d{0,5})(\d{0,4})$/);if(!t)return e;const i=t[1]?`(${t[1]}`:"";const s=t[2]?`) ${t[2]}`:"";const r=t[3]?`-${t[3]}`:"";return`${i}${s}${r}`}handleInput(e){const o=e.target;this.phone=this.formatPhone(o.value)}async getPhone(){return this.phone}render(){return o("input",{key:"300e113a7a6983334145e9ce0ef78344bbb63974",disabled:this.disabled,id:"phone",type:"tel",class:"phone",value:this.phone,onInput:e=>this.handleInput(e),placeholder:"(12) 94567-8910"})}};s.style=i;export{s as phone_input_mask};
2
+ //# sourceMappingURL=p-61df4eb6.entry.js.map
@@ -1,2 +1,2 @@
1
- import{r as i,h as t}from"./p-72510682.js";import{C as s}from"./p-a7e4526b.js";const d=class{constructor(t){i(this,t);this.cartId=undefined;this.orderId=undefined;this.metadadoString=undefined}async componentWillLoad(){console.log("this.metadadoString",this.metadadoString);const i=this.metadadoString?JSON.parse(this.metadadoString):{id:null};console.log("this.cartId",this.cartId);console.log("this.orderid",this.orderId);console.log("metadadoid",i);if(this.cartId&&this.orderId){await(new s).updateOrder({cartId:this.cartId,orderId:this.orderId,cartIdCrm:i.id})}}render(){return t("div",{key:"0110099751c9874bf52036de9a4f2d94095d7663"})}};export{d as pedido_finalizado};
2
- //# sourceMappingURL=p-20f2b764.entry.js.map
1
+ import{r as i,h as t}from"./p-72510682.js";import{C as s}from"./p-a7e4526b.js";const d=class{constructor(t){i(this,t);this.cartId=undefined;this.orderId=undefined;this.metadadoString=undefined}async componentWillLoad(){console.log("this.metadadoString",this.metadadoString);const i=this.metadadoString?JSON.parse(this.metadadoString):{id:null};console.log("this.cartId",this.cartId);console.log("this.orderid",this.orderId);console.log("metadadoid",i);if(this.cartId&&this.orderId){await(new s).updateOrder({cartId:this.cartId,orderId:this.orderId,cartIdCrm:i.id})}}render(){return t("div",{key:"13c169d62c8c89880108478e8f063bb9bc258d3f"})}};export{d as pedido_finalizado};
2
+ //# sourceMappingURL=p-b36705fc.entry.js.map
@@ -6,13 +6,21 @@ const CrmBonusNoteStyle0 = crmBonusNoteCss;
6
6
  const CrmBonusNote = class {
7
7
  constructor(hostRef) {
8
8
  registerInstance(this, hostRef);
9
+ this.cartId = undefined;
9
10
  this.url = undefined;
10
11
  }
11
12
  componentWillLoad() {
12
13
  this.url = window.location.origin;
13
14
  }
15
+ handleHide() {
16
+ const amount = localStorage.getItem(this.cartId);
17
+ return !!amount;
18
+ }
14
19
  render() {
15
- return (h("div", { key: 'b38705934cd9d63a58b66be5c5bb8e0a0cc4b4c7' }, h("div", { key: '71a4b61ed58f64baa730687c54836b31a49c67a8', class: "note-container" }, h("p", { key: '72699b6c0c7033891cc1ae9cf31f3057e4e9ba15', class: "note-title" }, "Gift back"), h("p", { key: '3d893e0cefd093bed6b0fa5e65304f1cd81dfb59', class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), h("a", { key: '6ee7a910c2b1f3b5b088170568a314dd9e87e59e', class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
20
+ if (this.handleHide()) {
21
+ return (h("div", null));
22
+ }
23
+ return (h("div", null, h("div", { class: "note-container" }, h("p", { class: "note-title" }, "Gift back"), h("p", { class: "note-description" }, "Volte ao carrinho e confira se voc\u00EA tem Giftback para aplicar na sua compra!"), h("a", { class: "back-cart", href: this.url }, "Voltar ao carrinho"))));
16
24
  }
17
25
  };
18
26
  CrmBonusNote.style = CrmBonusNoteStyle0;
@@ -1 +1 @@
1
- {"file":"crm-bonus-note.entry.js","mappings":";;AAAA,MAAM,eAAe,GAAG,2aAA2a,CAAC;AACpc,2BAAe,eAAe;;MCKjB,YAAY;;;;;IAKrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;KACrC;IAED,MAAM;QACF,QACI,8DACI,4DAAK,KAAK,EAAC,gBAAgB,IACvB,0DAAG,KAAK,EAAC,YAAY,gBAEjB,EAEJ,0DAAG,KAAK,EAAC,kBAAkB,wFAEvB,EAEJ,0DAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,EACT;KACJ;;;;;;","names":[],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @State() url: string\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n render() {\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"version":3}
1
+ {"file":"crm-bonus-note.entry.js","mappings":";;AAAA,MAAM,eAAe,GAAG,2aAA2a,CAAC;AACpc,2BAAe,eAAe;;MCKjB,YAAY;;;;;;IAOrB,iBAAiB;QACb,IAAI,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC;KACrC;IAED,UAAU;QACN,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QACjD,OAAO,CAAC,CAAC,MAAM,CAAC;KACnB;IAED,MAAM;QAEF,IAAG,IAAI,CAAC,UAAU,EAAE,EAAE;YAClB,QAAQ,cAAW,EAAC;SACvB;QAED,QACI,eACI,WAAK,KAAK,EAAC,gBAAgB,IACvB,SAAG,KAAK,EAAC,YAAY,gBAEjB,EAEJ,SAAG,KAAK,EAAC,kBAAkB,wFAEvB,EAEJ,SAAG,KAAK,EAAC,WAAW,EAAC,IAAI,EAAE,IAAI,CAAC,GAAG,yBAE/B,CACF,CACJ,EACT;KACJ;;;;;;","names":[],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, Prop, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @Prop({ attribute: 'cartid' }) cartId\n\n @State() url: string;\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n handleHide() {\n const amount = localStorage.getItem(this.cartId);\n return !!amount;\n }\n\n render() {\n\n if(this.handleHide()) {\n return (<div></div>)\n }\n\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"version":3}
@@ -16,7 +16,7 @@ var patchBrowser = () => {
16
16
 
17
17
  patchBrowser().then(async (options) => {
18
18
  await globalScripts();
19
- return bootstrapLazy([["crm-bonus",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note",[[0,"crm-bonus-note",{"url":[32]}]]],["pedido-finalizado",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
19
+ return bootstrapLazy([["crm-bonus",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note",[[0,"crm-bonus-note",{"cartId":[8,"cartid"],"url":[32]}]]],["pedido-finalizado",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
20
20
  });
21
21
 
22
22
  //# sourceMappingURL=crmbonus-component-wake.js.map
@@ -5,7 +5,7 @@ import { g as globalScripts } from './app-globals-0f993ce5.js';
5
5
  const defineCustomElements = async (win, options) => {
6
6
  if (typeof window === 'undefined') return undefined;
7
7
  await globalScripts();
8
- return bootstrapLazy([["crm-bonus",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note",[[0,"crm-bonus-note",{"url":[32]}]]],["pedido-finalizado",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
8
+ return bootstrapLazy([["crm-bonus",[[1,"crm-bonus",{"userId":[2,"userid"],"storeName":[8,"storename"],"productsInString":[1,"products"],"cartId":[8,"cartid"],"showModal":[32],"products":[32],"customer":[32],"loading":[32],"message":[32],"phone":[32],"canCancel":[32],"amountCancel":[32],"sent":[32]}]]],["crm-bonus-note",[[0,"crm-bonus-note",{"cartId":[8,"cartid"],"url":[32]}]]],["pedido-finalizado",[[0,"pedido-finalizado",{"cartId":[1,"cartid"],"orderId":[2,"orderid"],"metadadoString":[1,"metadado"]}]]],["phone-input-mask",[[1,"phone-input-mask",{"initialValue":[1,"initial-value"],"disabled":[4],"phone":[32],"getPhone":[64]}]]],["loading-spinner",[[1,"loading-spinner",{"size":[1],"color":[1]}]]],["giftback-finish_4",[[1,"giftback-pin",{"sent":[16],"validate":[16],"cancel":[16],"loading":[4],"pin":[32],"isVerified":[32]}],[1,"giftback-progress",{"loading":[4],"bonus":[16],"reserve":[16],"cancel":[16],"usedValue":[32]}],[0,"name-input",{"value":[1],"loading":[4],"applyName":[16],"cancel":[16],"newValue":[32],"message":[32]}],[1,"giftback-finish"]]],["app-modal_4",[[1,"crm-bonus-form",{"storeName":[8,"storename"],"cartId":[8,"cart-id"],"products":[16],"customer":[16],"sent":[16],"stepNext":[2,"step-next"],"phone":[2],"loadingModal":[4,"loading-modal"],"saveStore":[16],"cancel":[16],"handleCustomerName":[16],"loading":[32],"step":[32],"message":[32],"bonus":[32],"setStep":[64]}],[0,"phone-cancel-input",{"sendPin":[16],"loading":[4],"value":[1]}],[0,"phone-input",{"sendPin":[16],"loading":[4],"value":[1]}],[1,"app-modal",{"isOpen":[516,"is-open"],"modalTitle":[1,"modal-title"]}]]]], options);
9
9
  };
10
10
 
11
11
  export { defineCustomElements };
@@ -23,7 +23,7 @@ const Pedido = class {
23
23
  }
24
24
  }
25
25
  render() {
26
- return (h("div", { key: '0110099751c9874bf52036de9a4f2d94095d7663' }));
26
+ return (h("div", { key: '13c169d62c8c89880108478e8f063bb9bc258d3f' }));
27
27
  }
28
28
  };
29
29
 
@@ -31,7 +31,7 @@ const PhoneInputMask = class {
31
31
  return this.phone;
32
32
  }
33
33
  render() {
34
- return (h("input", { key: 'ec33b7963cefd79431a0c0663df8fa1a82b09564', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
34
+ return (h("input", { key: '300e113a7a6983334145e9ce0ef78344bbb63974', disabled: this.disabled, id: "phone", type: "tel", class: "phone", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(12) 94567-8910" }));
35
35
  }
36
36
  };
37
37
  PhoneInputMask.style = PhoneInputMaskStyle0;
@@ -1,5 +1,7 @@
1
1
  export declare class CrmBonusNote {
2
+ cartId: any;
2
3
  url: string;
3
4
  componentWillLoad(): void;
5
+ handleHide(): boolean;
4
6
  render(): any;
5
7
  }
@@ -37,6 +37,7 @@ export namespace Components {
37
37
  "storeName": any;
38
38
  }
39
39
  interface CrmBonusNote {
40
+ "cartId": any;
40
41
  }
41
42
  interface GiftbackFinish {
42
43
  }
@@ -219,6 +220,7 @@ declare namespace LocalJSX {
219
220
  "storeName"?: any;
220
221
  }
221
222
  interface CrmBonusNote {
223
+ "cartId"?: any;
222
224
  }
223
225
  interface GiftbackFinish {
224
226
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "crmbonus-component-wake",
3
- "version": "1.0.37",
3
+ "version": "1.0.38",
4
4
  "description": "Stencil Component Starter",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.js",
@@ -1,2 +0,0 @@
1
- import{r as e,h as a}from"./p-72510682.js";const t=".note-container{border:1px solid #dddddd;padding:0 15px 15px;margin:0 0 26px 0px}.note-container .back-cart{display:flex;text-align:center}.note-title{font-weight:700;height:2em;line-height:2em;text-align:left;border-radius:3px;color:#333;margin-bottom:1.4em}.note-description{font-family:Arial;color:#6d6d5f;padding:0;margin:0 auto}.back-cart{font-size:.9em;color:#337ab7;text-decoration:none;cursor:pointer;margin-top:11px}";const o=t;const c=class{constructor(a){e(this,a);this.url=undefined}componentWillLoad(){this.url=window.location.origin}render(){return a("div",{key:"b38705934cd9d63a58b66be5c5bb8e0a0cc4b4c7"},a("div",{key:"71a4b61ed58f64baa730687c54836b31a49c67a8",class:"note-container"},a("p",{key:"72699b6c0c7033891cc1ae9cf31f3057e4e9ba15",class:"note-title"},"Gift back"),a("p",{key:"3d893e0cefd093bed6b0fa5e65304f1cd81dfb59",class:"note-description"},"Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!"),a("a",{key:"6ee7a910c2b1f3b5b088170568a314dd9e87e59e",class:"back-cart",href:this.url},"Voltar ao carrinho")))}};c.style=o;export{c as crm_bonus_note};
2
- //# sourceMappingURL=p-119ca508.entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["crmBonusNoteCss","CrmBonusNoteStyle0","CrmBonusNote","componentWillLoad","this","url","window","location","origin","render","h","key","class","href"],"sources":["src/components/note/crm-bonus-note.css?tag=crm-bonus-note","src/components/note/crm-bonus-note.tsx"],"sourcesContent":[".note-container {\n border: 1px solid #dddddd;\n padding: 0 15px 15px;\n margin: 0 0 26px 0px;\n}\n\n.note-container .back-cart {\n display: flex;\n text-align: center;\n} \n\n.note-title {\n font-weight: 700;\n height: 2em;\n line-height: 2em;\n text-align: left;\n border-radius: 3px;\n color: #333;\n margin-bottom: 1.4em;\n}\n\n.note-description {\n font-family: Arial;\n color: #6d6d5f;\n padding: 0;\n margin: 0 auto;\n}\n\n.back-cart {\n font-size: .9em;\n color: #337ab7;\n text-decoration: none;\n cursor: pointer;\n margin-top: 11px;\n}","import { Component, State, h } from \"@stencil/core\";\n\n@Component({\n tag: 'crm-bonus-note',\n styleUrl: 'crm-bonus-note.css'\n})\nexport class CrmBonusNote {\n\n @State() url: string\n\n\n componentWillLoad() {\n this.url = window.location.origin;\n }\n\n render() {\n return (\n <div>\n <div class=\"note-container\">\n <p class=\"note-title\">\n Gift back\n </p>\n\n <p class=\"note-description\">\n Volte ao carrinho e confira se você tem Giftback para aplicar na sua compra!\n </p>\n\n <a class=\"back-cart\" href={this.url}>\n Voltar ao carrinho\n </a>\n </div>\n </div>\n )\n }\n}"],"mappings":"2CAAA,MAAMA,EAAkB,4aACxB,MAAAC,EAAeD,E,MCKFE,EAAY,M,4CAKrB,iBAAAC,GACIC,KAAKC,IAAMC,OAAOC,SAASC,M,CAG/B,MAAAC,GACI,OACIC,EAAA,OAAAC,IAAA,4CACID,EAAA,OAAAC,IAAA,2CAAKC,MAAM,kBACPF,EAAA,KAAAC,IAAA,2CAAGC,MAAM,cAAY,aAIrBF,EAAA,KAAAC,IAAA,2CAAGC,MAAM,oBAAkB,gFAI3BF,EAAA,KAAAC,IAAA,2CAAGC,MAAM,YAAYC,KAAMT,KAAKC,KAAG,uB","ignoreList":[]}