{"_id":"@bogos/freegifts-hydrogen","_rev":"12-87cb78cf2a21ad168fc5e72a8215394d","name":"@bogos/freegifts-hydrogen","dist-tags":{"latest":"0.1.0"},"versions":{"0.0.1":{"name":"@bogos/freegifts-hydrogen","version":"0.0.1","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.1","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"385acd25db819585cb4045740e73db6c169cd503","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.1.tgz","fileCount":123,"integrity":"sha512-bnC9hujlAHTwjVuu3yeM2xFNzOPRdvrXO623kHB2NV3jKuTKHYeh76oUcuvzYsOoynIQFeTtSU5172pdpm0uEw==","signatures":[{"sig":"MEUCIQCD/LLPQyoyGcUtPcGCVKDcP86osgIWgynVkLJTpa9C/wIgdWZSz506uXvWp4oGne7tKZ/uQ/OpKwkm4wVoy+uvIF0=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":709758},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.1_1697771094764_0.7790369080289308","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.2":{"name":"@bogos/freegifts-hydrogen","version":"0.0.2","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.2","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"79fc6a3388fe84514619e01225719d9f1fecd6da","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.2.tgz","fileCount":123,"integrity":"sha512-wOtZEVczsajF/hjpRUgIsyIpCcvr/CzI8PaOrLkQKewwcjzwcb4/iPtSwC8hiKL7LLNaBl8SSkcdtGxBXDyTwA==","signatures":[{"sig":"MEYCIQDlhMQNOtpYDACIr3zZTHBr8/kuo9Y7VX5mgNew43iMowIhAJBu4p8tlFIHDP/g62iuOHTCjOZLLt5fOAh+/4G1Qm54","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":709410},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"1a75d5e439baa26713ff8d44a035b8f3700473f5","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.2_1697781287845_0.24828214481774613","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.3":{"name":"@bogos/freegifts-hydrogen","version":"0.0.3","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.3","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"cb2a7a9d047c7ef5fff649a39446aaea71c65edd","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.3.tgz","fileCount":141,"integrity":"sha512-H+QIVu9ThqgJr68lHGNGpd9kPw2UK5jlJNnLAoGhS/Dz8Sa6P601W25ewYxOxQF/kJa50UQuMuwHEy8jjAMBhQ==","signatures":[{"sig":"MEUCIQC9QRjEoO31m69sjHimdW+YsoYQh+PvXv3451AHF/Fm6gIgZVPkByrZroJmqrNABn95u+vwl8RHDm4E5xL+Yth2GcU=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":812576},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"1a75d5e439baa26713ff8d44a035b8f3700473f5","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.3_1698208664429_0.02558842504601655","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.4":{"name":"@bogos/freegifts-hydrogen","version":"0.0.4","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.4","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"a5146f2a5c33ec6a586e1055e3783d83d2bff03c","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.4.tgz","fileCount":141,"integrity":"sha512-tQrcjYPPyuRW/+TRRkXSK+Wc9tmFDtEkTqSzixnGF7DhTJlLxgEOPJlNQlmEVbvYRmuLH9l60rM1VRec0muVhA==","signatures":[{"sig":"MEUCIQC+HiisrbirkIdjn022feu0FflBbECoLr5u5y5gy/S1CQIgCV3Z27PiZoXM3KbZuRBu/H6+GNO/teInC+KWYeewv0E=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":833614},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"e3acabf6f93e603d0647029ecf3847aaec17c130","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.4_1698829909347_0.7708337100944154","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.5":{"name":"@bogos/freegifts-hydrogen","version":"0.0.5","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.5","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"f049b33a2dc013ea847a66dd802ce093b2ac790f","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.5.tgz","fileCount":141,"integrity":"sha512-j1yeIiVtEEQbhsZUVCX40q+Boh3dR3cti8GUxKqoUnEjY8LJb91GZJzSl72U7L4AB9pNGG09k79ZyIk7Wh07Qg==","signatures":[{"sig":"MEUCIQDUrCG/uLD5rH6U1NtOtHsYV5GHoY0knCiB72hpcAdrTAIgPkVY6H5p6zq18h+kj2S9CPXKDu3zaieWDVuGFabe6h0=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":835714},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"f91b55efd05f3f38a28617092408974cacaea45c","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.5_1699977186101_0.21280258325770984","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.6":{"name":"@bogos/freegifts-hydrogen","version":"0.0.6","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.6","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"a9624383e15708c1e093554ea6d1b0d2d8a141ff","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.6.tgz","fileCount":141,"integrity":"sha512-Xrc6IgbZ8jg+IoG4FjI5g19ChnwhLiwYHs2nw37GLboUhKnnqkro/1fpIqTgvLBarqwzTK1Sv0t6hngN9TK17Q==","signatures":[{"sig":"MEUCIF4878/VGJ5GruK/QOndsLsQnOV7TaFUKJywpZb3/6SRAiEA5mxVOd2n1s7w73rQy68BSb6LLFq79n6nr1m93WLRWkI=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":835716},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"a63c9f89953e9fde3c22e4472a63f7b2bc0c03bc","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.6_1700013690944_0.8403670115898465","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.7":{"name":"@bogos/freegifts-hydrogen","version":"0.0.7","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.7","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"29381ee5d2117d8db467a46c3f71a520ba018fed","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.7.tgz","fileCount":141,"integrity":"sha512-/HR6EwV40FHip8i9O5lOFzz2yxz7+5/KvrBh1cUIjoFBRBzeJSSP/HE52U0/D8NDuoqN/jdxM6M1Ze2CpbTYPQ==","signatures":[{"sig":"MEQCIAsfXhaVBig4yK4mio5C/gIdg+GDFIXla1WoGSbcJxVHAiASn4dWyXYl347UK1Y3U5HVDToT9/IoYFwb+Sv9VdZyiA==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":839934},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"666ab03875f2255195e5557eaeefe0e694573dbb","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.7_1701146154581_0.2988748417426548","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.8":{"name":"@bogos/freegifts-hydrogen","version":"0.0.8","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.8","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"9052bba0ff91d3105ca2bdce4e59bce927f40fc4","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.8.tgz","fileCount":141,"integrity":"sha512-eXtZe0j10zXieHXzHs75MGRA5Okx0g+zCos6UC9wnA2ziz12fM/d7sK1ldvFZOKSlwoyNPshM9gbNupY2jdvpA==","signatures":[{"sig":"MEYCIQD4Xm0LAtj/Dv+NWk4mvllGo0Ty2QSjhlHotdyZFd0MJwIhAM8OYDRf3qRr0n2PXApXEuA/JHTSihNnD31tXFH17uJU","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":841833},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"964c8401efe8da2b8afaed3d310116ada3e01d2b","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.8_1701918388774_0.6418555712425804","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.9":{"name":"@bogos/freegifts-hydrogen","version":"0.0.9","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.9","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"4998f3b86d8509373a083ced985d0054abed1215","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.9.tgz","fileCount":141,"integrity":"sha512-/WPegJU0aBmahN+zccaIATUMkDlcGj8IjIgWaA4MgLsoirirbW97xlT/uYQfRJw8TydfgZHIOQyV3G2y20rxmA==","signatures":[{"sig":"MEUCIDP2pBdaOKj+nCy4YzmRQ0xij9RawuQzeUZLrnD9FkzyAiEAgMDeez3IvQmEIhK2dqw8Rw+8+ZMpjpbAKM7PRJhyZa0=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":846076},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"911c1093d96105efeb960505b57d4e4c1640c003","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.9_1702365436931_0.23543093029406426","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.0.10":{"name":"@bogos/freegifts-hydrogen","version":"0.0.10","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.0.10","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"be7bb75193ac1a1d99231157e8c9e12e6b27be25","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.0.10.tgz","fileCount":141,"integrity":"sha512-RDkDTAMb6nep52C7KKp80lRi/PPYf5+Yp2+gKnDVSZdwUVVpDNxtmepMXOLLZNDL6MeZoDwwzQS9E1D0xeTAqw==","signatures":[{"sig":"MEUCIHjzaKUMmqE1naOg3OLLVZm2EcZUrZlw8HgWXL5hpKVDAiEAs2ZvkFKw6TgVDoIrVIereSKOu0TcN7wsfm49plaBmEA=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":861378},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"9e0af77c0785c12d3dd95909f79bc3a272bf9771","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{"@shopify/hydrogen":"^2023.4.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","eslint-plugin-react":"^7.32.2","@shopify/remix-oxygen":"^1.0.4","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.0.10_1703589433426_0.7904526896985089","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.1.0":{"name":"@bogos/freegifts-hydrogen","version":"0.1.0","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"author":{"name":"BOGOS: Free gift"},"license":"MIT","_id":"@bogos/freegifts-hydrogen@0.1.0","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"}],"bugs":{"email":"support@secomapp.com"},"dist":{"shasum":"217efef8b25b2a4ef9c9b1727d81f65612608f55","tarball":"https://registry.npmjs.org/@bogos/freegifts-hydrogen/-/freegifts-hydrogen-0.1.0.tgz","fileCount":147,"integrity":"sha512-ST3fmsTa43FzWb+1Cr3qv01gvin+kBxqHK8jVQ+ocaVQRR+e2NvApECWPWtiL7TT9HqpCIGnnE6gsYkeVVHYZg==","signatures":[{"sig":"MEUCIQD9Z1dI4qSeCOg8jGyOkk6lXbW8joddNy3YdY+c4KWanwIgdOSVGeSdqLNlUii9fCGMSqMzgb9dtb28nVrCYT+B/d0=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":906012},"main":"./dist/cjs/index.js","type":"module","types":"./dist/esm/index.d.ts","module":"./dist/esm/index.js","gitHead":"61bf514bbed1e20ec2c483c00d8daba8c1d10ba8","scripts":{"build":"npm run build:esm && npm run build:cjs && npm run copy-assets","public":"npm run build && npm publish","prepare":"npm run build","build:cjs":"tsc --module commonjs --outDir dist/cjs","build:esm":"tsc","copy-assets":"copyfiles ./public/**/* ./dist/"},"_npmUser":{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},"_npmVersion":"9.6.7","description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","directories":{},"_nodeVersion":"20.3.0","dependencies":{},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"react":"^18.2.0","eslint":"^8.38.0","copyfiles":"^2.4.1","lz-string":"^1.5.0","react-dom":"^18.2.0","jwt-encode":"^1.0.1","@types/react":"^18.2.20","@shopify/hydrogen":"^2023.4.0","@types/jwt-encode":"^1.0.3","eslint-plugin-react":"^7.32.2","@typescript-eslint/parser":"^5.57.1","eslint-plugin-react-hooks":"^4.6.0","@typescript-eslint/eslint-plugin":"^5.57.1"},"peerDependencies":{"react":"^16 || ^17 || ^18","lz-string":"^1.5.0","react-dom":"^16 || ^17 || ^18","jwt-encode":"^1.0.1","@types/node":"^18.16.3"},"_npmOperationalInternal":{"tmp":"tmp/freegifts-hydrogen_0.1.0_1708933798952_0.438843025894041","host":"s3://npm-registry-packages"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."}},"time":{"created":"2023-10-20T03:04:54.676Z","modified":"2025-11-03T10:19:51.021Z","0.0.1":"2023-10-20T03:04:55.223Z","0.0.2":"2023-10-20T05:54:48.140Z","0.0.3":"2023-10-25T04:37:44.728Z","0.0.4":"2023-11-01T09:11:49.753Z","0.0.5":"2023-11-14T15:53:06.463Z","0.0.6":"2023-11-15T02:01:31.297Z","0.0.7":"2023-11-28T04:35:54.824Z","0.0.8":"2023-12-07T03:06:28.965Z","0.0.9":"2023-12-12T07:17:17.516Z","0.0.10":"2023-12-26T11:17:13.768Z","0.1.0":"2024-02-26T07:49:59.188Z"},"bugs":{"email":"support@secomapp.com"},"author":{"name":"BOGOS: Free gift"},"license":"MIT","keywords":["freegifts","bogos","bogos hydrogen","bogos react","bogos shopify app","bogos free gift","BOGOS: Free gift & Buy X Get Y"],"description":"BOGOS: Free gift & Buy X Get Y - Hydrogen","maintainers":[{"name":"alex.fengdx","email":"phong.dongxuan@secomus.com"},{"name":"cuong.nhc","email":"cuongnhc@gmail.com"},{"name":"cuonglv112","email":"cuonglv@secomus.com"}],"readme":"# BOGOS: Freegifts Hydrogen App\n\n## Requirements\n\n- First, you must have [Hydrogen App](https://shopify.dev/docs/custom-storefronts/hydrogen/getting-started/quickstart) and [BOGOS: Free gift & Buy X Get Y](https://apps.shopify.com/freegifts) installed on your Shopify store.\n- Second, we only support development framework [<b>Hydrogen version 2</b>](https://shopify.dev/docs/custom-storefronts/hydrogen) and above. You can learn how to upgrade to Hydrogen version 2 using this [link](https://shopify.dev/docs/custom-storefronts/hydrogen/migrate-hydrogen-remix).\n\n- If your Headless store was not built on Hydrogen, please refer to this [API document](https://bogos-api-integration.gitbook.io/bogos-api-integration) for integration.\n\n## Installation\n\n### Step 1: Getting started\n\n1. Navigate to your working directory.\n\n   ```shell\n   cd <directory>\n   ```\n\n2. Install BOGOS: Free gift package\n\n    ```sh\n    npm i @bogos/freegifts-hydrogen\n    ```\n\n### Step 2: Integration\n\n1. Open file containing event to render cart component (This event should be rendered on every single page), and add this basic integration:\n\n    ```typescript jsx\n    import {BOGOS} from '@bogos/freegifts-hydrogen';\n    ...\n    <Await resolve={data.cart}>\n        {(cart) => (\n            <>\n                <BOGOS\n                    cart={cart}\n                    customerAccessToken={CUSTOMER_ACCESS_TOKEN}\n\n                    publicStoreDomain={PUBLIC_STORE_DOMAIN}\n                    publicStorefrontApiToken={PUBLIC_STORE_FRONT_API_TOKEN}\n                    publicStorefrontApiVersion={PUBLIC_STOREFRONT_API_VERSION}\n                    bogosAccessToken={BOGOS_ACCESS_TOKEN}\n                />\n            ...\n            </>\n        )}\n    </Await>\n    ...\n    ```\n\n    - Details of BOGOS component properties\n\n    ```typescript jsx\n    import { Cart, Customer } from \"@shopify/hydrogen/storefront-api-types\";\n\n    interface BOGOSProps {\n        cart: Cart;\n        customerAccessToken?: string;\n        publicStoreDomain: string;\n        publicStorefrontApiToken: string;\n        publicStorefrontApiVersion: string;\n        bogosAccessToken: string;\n\n        customer?: Customer;\n        others?: OthersSetting;\n        renderCart?: Function;\n    }\n\n    ```\n\n    <table>\n    <thead>\n        <th>\n        <strong>Property</strong>\n        </th>\n        <th><strong>Description</strong></th>\n        <th><strong>Effect</strong></th>\n        <th><strong>Required</strong></th>\n    </thead>\n    <tr id=\"cart-detail\">\n        <td><code>cart: Cart</code></td>\n        <td>Cart object from storefront API, and it is used for BOGOS app's logic.</td>\n        <td>\n            <a href=\"#cart-action\">useCart</a>\n        </td>\n        <td>Yes</td>\n    </tr>\n    <tr>\n        <td><code>publicStoreDomain: string</code></td>\n        <td>PUBLIC_STORE_DOMAIN</td>\n        <td>_</td>\n        <td>Yes</td>\n    </tr>\n    <tr>\n        <td><code>publicStorefrontApiToken: string</code></td>\n        <td>PUBLIC_STOREFRONT_API_TOKEN</td>\n        <td>_</td>\n        <td>Yes</td>\n    </tr>\n    <tr>\n        <td><code>publicStorefrontApiVersion: string</code></td>\n        <td>PUBLIC_STOREFRONT_API_VERSION</td>\n        <td>_</td>\n        <td>Yes</td>\n    </tr>\n    <tr>\n        <td><code>bogosAccessToken: string</code></td>\n        <td>Access token generated by BOGOS app</td>\n        <td>_</td>\n        <td>Yes</td>\n    </tr>\n    <tr>\n        <td><code>customerAccessToken?: string</code></td>\n        <td>\n            It is customer access token. This field will be used if there is offer with sub-condition to track customer information: order history, customer tags, etc. <br/>\n            If this property is used, it will be default when fetching customer information.\n        </td>\n        <td>\n            <a href=\"#customer-action\">useCustomer</a>,\n            <a href=\"#customer-action\">customer</a>\n        </td>\n        <td>No</td>\n    </tr>\n    <tr id=\"customer-detail\">\n        <td><code>customer?: Customer</code></td>\n        <td>Use this in case you already had customer information and do not want to fetch it again.</td>\n        <td>\n            <a href=\"#customer-action\">useCustomer</a>,\n            <a href=\"#customer-action\">customer</a>\n        </td>\n        <td>No</td>\n    </tr>\n    <tr>\n        <td><a href=\"#step-3-details-of-other-settings-for-bogos\"><code>others?: OthersSetting</a></td>\n        <td>Other settings for BOGOS</td>\n        <td>_</td>\n        <td>No</td>\n    </tr>\n    <tr id =\"render-cart-detail\">\n        <td><code>renderCart?: Function</code></td>\n        <td>\n            Use this property in case you already had function to re-render cart. It will be used after adding/removing gift from cart. By default, all the page will be reloaded.\n        </td>\n        <td>\n            <a href=\"#cart-action\">useCart</a>\n            <a href=\"#disableReloadCartUpdated\">disableReloadCartUpdated</a>\n        </td>\n        <td>No</td>\n    </tr>\n\n    </table>\n\n2. Find Checkout button, and add <strong><code>bogosCheckCartValid</code></strong> function to prevent gift invalid after checkout.\n\n    ```typescript\n    import {bogosCheckCartValid} from '@bogos/freegifts-hydrogen';\n\n    async function {your_function_checkout} (args) {\n        ...\n        await bogosCheckCartValid({});\n        ...\n    }\n    ```\n\n    - Details of <strong><code>bogosCheckCartValid</code></strong> function\n\n    ```typescript\n    export type BogosCheckCartValidParams = {\n        cart?: Cart | FGObject; /* If you don't want to fetch catch again */\n        reloadIfInvalid?: boolean; /* Default: true. You don't want to reload page if invalid */\n        callback?: (isValidCart: boolean) => void; /* If you want to do something after BOGOS check */\n    };\n\n    export declare const bogosCheckCartValid: (params: BogosCheckCartValidParams) => Promise<boolean>;\n    ```\n\n### Step 3: Details of Other settings for BOGOS\n\n```typescript\nexport type OthersSetting = {\n    isPopUp?: boolean;\n    customGiftImgSize?: string;\n    enableToastAdded?: boolean;\n    scaTextNotifySuccess?: string;\n    localesFormat?: string;\n    currencyCode?: string;\n    currencyRate?: number;\n    useRateForOffer?: boolean;\n    disableBogosAttrCart?: boolean;\n    disableReloadCartUpdated?: boolean;\n    renderCart?: Function;\n    useCart?: boolean;\n    useCustomer?: boolean;\n    prefixProduct?: string;\n    numberOrders?: number;\n    toFixed?: number;\n    debug?: boolean;\n};\n```\n\n<table>\n    <thead>\n        <th>\n        <strong>Property</strong>\n        </th>\n        <th><strong>Default</strong></th>\n        <th><strong>Description</strong></th>\n    </thead>\n    <tr id=\"isPopup\">\n        <td><code>isPopUp?: boolean</code></td>\n        <td>true</td>\n        <td>You can disable it or use it to customize the interface of gift popup/slide.</td>\n    </tr>\n    <tr>\n        <td><code>customGiftImgSize?: string</code></td>\n        <td>&width=480&height=480</td>\n        <td>Iframe image product with <a href=\"https://shopify.dev/docs/api/liquid/filters/image_tag\" target=\"_blank\">Shopify Filters</a></td>\n    </tr>\n    <tr>\n        <td><code>enableToastAdded?: boolean</code></td>\n        <td>false</td>\n        <td>Enable toast success when gifts are added.</td>\n    </tr>\n    <tr>\n        <td><code>scaTextNotifySuccess?: string</code></td>\n        <td>\"Add gift to cart successfully!\"</td>\n        <td>Text for toast success above.</td>\n    </tr>\n    <tr>\n        <td><code>localesFormat?: string</code></td>\n        <td>\"en-US\"</td>\n        <td>Currency format</td>\n    </tr>\n    <tr id=\"disableReloadCartUpdated\">\n        <td><code>disableReloadCartUpdated?: boolean</code></td>\n        <td>false</td>\n        <td>\n            Disable reloading page after gift changed (add/remove). You can use <a href=\"#render-cart-detail\">renderCart</a> function instead\n        </td>\n    </tr>\n        <tr id=\"cart-action\">\n        <td><a href=\"#render-cart-detail\">renderCart?: Function</a></td>\n        <td>_</td>\n        <td>_</td>\n    </tr>\n        <tr>\n        <td><code>useCart?: boolean</code></td>\n        <td>false</td>\n        <td>Set true and use with <a href=\"#cart-detail\">cart</a></td>\n    </tr>\n    <tr id=\"customer-action\">\n        <td><code>useCustomer?: boolean</code></td>\n        <td>false</td>\n        <td>Set true and use with <a href=\"#customer-detail\">customer</a></td>\n    </tr>\n    <tr>\n        <td><code>currencyCode?: string</code></td>\n        <td>your_store_currency</td>\n        <td>\n            You can use different currency code from your default currency in Shopify.\n        </td>\n    </tr>\n    <tr>\n        <td><code>currencyRate?: number</code></td>\n        <td>1</td>\n        <td>\n            Currency conversion rate from your store currency. Formula: Converted currency = Currency conversion rate x Store currency. <br/>\n            Note: This property is used for display only\n        </td>\n    </tr>\n    <tr>\n        <td><code>useRateForOffer?: boolean</code></td>\n        <td>false</td>\n        <td>\n            Use the currency conversion rate above for offer condition or not.\n        </td>\n    </tr>\n    <tr>\n        <td><code>disableBogosAttrCart?: boolean</code></td>\n        <td>false</td>\n        <td>\n            Add cart attributes if the gift exists in the customer cart.\n        </td>\n    </tr>\n    <tr>\n        <td><code>numberOrders?: number</code></td>\n        <td>20</td>\n        <td>\n            Number of orders to track on sub-condition of customers' order history.\n        </td>\n    </tr>\n    <tr>\n        <td><code>prefixProduct?: number</code></td>\n        <td>\"/products/\"</td>\n        <td>\n            Path name product.\n        </td>\n    </tr>\n    <tr>\n        <td><code>toFixed?: number</code></td>\n        <td>0</td>\n        <td>\n            Number of characters after \".\" <br/>\n            E.g: 100.00\n        </td>\n    </tr>\n    <tr>\n        <td><code>debug?: boolean</code></td>\n        <td>true</td>\n        <td>\n            Disable log for debug process.\n        </td>\n    </tr>\n\n </table>\n\n### Step 4: Integration customize\n\n1. Gift Icon\n\n    - Details of <b><code>BOGOSGiftIcon</code></b>\n\n    ```typescript\n    type GiftItem = {\n        id: number;\n        discount_type: 'percentage' | 'fixed_amount';\n        discount_value: number;\n        original_price: number;  // Original price - price before discount\n        price: number;           // Discount price - price after discount\n        title: string;\n        thumbnail?: string;\n    };\n\n    type GiftProduct = {\n        id: number;\n        title: string;\n        handle: string;\n        thumbnail?: string;\n        belongs_to_offer: string;\n        variants: GiftItem[];\n    };\n    \n    type FilterVariant = {\n        id: string | number;\n        title: string;\n        price?: string | number;\n    };\n\n    type ProductInfo = {\n        id: string | number;\n        handle: string;\n        title: string;\n        price_max?: string | number;\n        collections?: {\n            id: string | number;\n            title?: string;\n        }[];\n        product_type?: string;\n        vendor?: string;\n        variants?: FilterVariant[];\n    };\n\n    interface BOGOSGiftIconProps {\n        product: ProductInfo;\n        selectedVariant?: FilterVariant;\n        enableForAllCondition?: boolean; /* Default false - only use with specific product condition */\n        page: \"collection\" | \"product\";\n    };\n\n    /* Example Collection page or page has list products */\n    <div ...>\n        ...\n        {products.map(product => (\n            <div>\n                ...\n                <div style={{position: 'relative'}}>\n                    ...\n                    <BOGOSGiftIcon\n                        product={{\n                            id: product.id,\n                            handle: product.handle,\n                            title: product.title,\n                        }}\n                        page=\"collection\"\n                    />\n                    ...\n                </div>\n                ...\n            </div>\n        ))}\n        ...\n    </div>\n    \n    /* Example Product page */\n    <div ...> \n        ...\n        <h1 style={{width: 'fit-content', position: 'relative'}}>\n            {title}\n            <BOGOSGiftIcon\n                product={{\n                    id: product.id,\n                    handle: product.handle,\n                    title: product.title,\n                }}\n                page=\"product\"\n            />\n        </h1>\n        ...\n    </div>\n    ```\n\n    - Gift-icon customization (Use it in case you want to handle the customization of gift icon instead of using BOGOS default component)\n\n    ```typescript\n    /* Other type check above */\n    export interface BogosCheckProductHasGiftsParams {\n        product: ProductInfo;\n        selectedVariant?: FilterVariant;\n        enableForAllCondition?: boolean;\n    }\n\n    /* Return the gift product associated with purchasing the product from product page */\n    export declare const bogosCheckProductHasGifts: async ({ \n        product, \n        selectedVariant, \n        enableForAllCondition, \n    }: BogosCheckProductHasGiftsParams) => GiftProduct[];\n\n    export const GiftIcon = (props: Props) => {\n        /* States */\n        const [gifts, setGifts] = useState<GiftProduct[]>([]);\n\n        /* Vars */\n        const event = \"fg-data:loaded\";\n\n        const handleGiftIcon = async (e?: Event) => {\n            try {\n                setGifts(await bogosCheckProductHasGifts(props));\n            } catch (e) {}\n        };\n\n        useEffect(() => {\n            handleGiftIcon();\n        }, [props.selectedVariant?.id]);\n\n        useEffect(() => {\n            /* This event will run on the next render */\n            handleGiftIcon();\n            /* This event is used after fetching BOGOS' data to get information of gift icon (only run once) */\n            document.addEventListener(event, handleGiftIcon);\n\n            return () => {\n                document.removeEventListener(event, handleGiftIcon);\n            };\n        }, []);\n\n        const renderGiftIcon = useCallback(() => {\n            const gift_icon = typeof window !== \"undefined\" &&\n                window?.FGSECOMAPP?.appearance?.gift_icon?.product_page?.gift_icon;\n\n            /* Check if gift icon can be shown or not */\n            if (gifts?.length > 0 && gift_icon && gift_icon?.status) {\n                const giftIcon = window.FGSECOMAPP?.giftIcon; // or other icon you want to show\n            }\n            \n            // render gift icons\n        }, [gifts]);\n\n        return <Fragment>{renderGiftIcon()}</Fragment>;\n    };\n    ```\n\n2. Gift thumbnail\n\n    - Details of <b><code>BOGOSGiftThumbnail</code></b>\n\n    ```typescript\n    /* Other type check above */\n    \n    interface Props {\n        product: ProductInfo;\n        selectedVariant?: FilterVariant;\n        enableForAllCondition?: boolean;\n        numberGiftsThumbnail?: number; /* Default: 3. Number of gift images can be shown per thumbnail */\n        arrows?: boolean;\n        dots?: boolean;\n        prefixProduct?: string; /* Default: \"/products/\". Path name product */\n    }\n\n    /* Example Product page */\n    <div ...> \n        ...\n        <BOGOSGiftThumbnail\n            product={{\n                id: product.id,\n                handle: product.handle,\n                title: product.title,\n            }}\n            arrows={false}\n        />\n        {{ add_to_cart_btn }}\n        ...\n    </div>\n    ```\n\n    - Gift-thumbnail customization (Use it in case you want to handle the customization of gift thumbnail instead of using BOGOS default component)\n\n    ```typescript\n    /* Other type check above */\n    export interface BogosCheckProductHasGiftsParams {\n        product: ProductInfo;\n        selectedVariant?: FilterVariant;\n        enableForAllCondition?: boolean;\n    }\n\n    /* Return the gift product associated with purchasing the product from product page */\n    export declare const bogosCheckProductHasGifts: async ({ \n        product, \n        selectedVariant, \n        enableForAllCondition, \n    }: BogosCheckProductHasGiftsParams) => GiftProduct[];\n\n    export const GiftThumbnail = (props: Props) => {\n        /* States */\n        const [gifts, setGifts] = useState<GiftProduct[]>([]);\n\n        /* Vars */\n        const event = \"fg-data:loaded\";\n\n        const handleGiftThumbnail = (e?: Event) => {\n            try {\n                const gifts = await bogosCheckProductHasGifts(props);\n                renderGiftThumbnail(gifts);\n            } catch (e) {}\n        };\n\n        useEffect(() => {\n            handleGiftThumbnail();\n        }, [props.selectedVariant?.id]);\n\n        useEffect(() => {\n            /* This event will run on the next render */\n            handleGiftThumbnail();\n            /* This event is used after fetching BOGOS' data to get information of gift thumbnail (only run once) */\n            document.addEventListener(event, handleGiftThumbnail);\n\n            return () => {\n                document.removeEventListener(event, handleGiftThumbnail);\n            };\n        }, []);\n\n        const renderGiftThumbnail = useCallback(() => {\n            const gift_thumbnail = typeof window !== \"undefined\" &&\n                window?.FGSECOMAPP?.appearance?.gift_icon?.product_page?.gift_thumbnail;\n                \n            /* Check if gift thumbnail can be shown or not */\n            if (gifts?.length > 0 && gift_thumbnail && gift_thumbnail?.status) {\n                \n            }\n            \n            // render gift thumbnail\n        }, [gifts]);\n\n        return <Fragment>{renderGiftThumbnail()}</Fragment>;\n    };\n    ```\n\n3. Cart message\n\n    - Details of <b><code>BOGOSCartMessage</code></b>\n\n    ```typescript\n    /* Other type check above */\n    \n    interface Props {\n        delay?: number; /* Default: 3000 (ms). Time delay between auto scroll cart message */\n        toFixed?: number; /* Default: 2. Number after '.' E.g: 100.00*/\n    }\n\n    /* Example */\n    <div className={className}>\n        <BOGOSCartMessage\n            delay={5000}\n        />\n\n        <CartEmpty ... />\n        <CartDetails ... />\n    </div>\n    ```\n\n    - Cart message customization (Use it in case you want to handle the customization of cart message instead of using BOGOS default component)\n\n    ```typescript\n    /* Other type check above */\n    export interface BOGOSCartMessageParams {\n        toFixed?: number;\n    }\n\n    /* return cart message can be shown */\n    export declare const bogosCheckCartMessage: ({ toFixed, }: BOGOSCartMessageParams) => string[]; \n\n    export const CartMessage = (props: Props) => {\n        /* States */\n        const [msgs, setMsgs] = useState<{value: string}[]>([]);\n\n        /* Vars */\n        const event = \"fg-cart:end-process\";\n\n        const handleCartMsg = (e?: Event) => {\n            try {\n            const msgs = e\n                ? (e as CustomEvent)?.detail?.data\n                : (typeof window !== \"undefined\" && window?.FGSECOMAPP?.cart_message) ?? [];\n                setMsgs(msgs);\n            } catch (e) {}\n        };\n\n        useEffect(() => {\n            /* This event will run on the next render */\n            handleGiftCartMsg();\n            /* This event is used after fetching BOGOS' data to get information of cart message (only run once) */\n            document.addEventListener(event, handleGiftCartMsg);\n\n            return () => {\n                document.removeEventListener(event, handleGiftCartMsg);\n            };\n        }, []);\n\n        const renderCartMsg = useCallback(() => {\n            const promotion_message = typeof window !== \"undefined\" &&\n                window?.FGSECOMAPP?.appearance?.promotion_message;\n      \n            /* Check if cart message can be shown or not */\n            if (\n                messages?.length > 0 &&\n                promotion_message &&\n                promotion_message?.show_on_cart_page\n            ) {\n            \n            }\n            \n            // render gift thumbnail\n        }, [msgs]);\n\n        return <Fragment>{renderCartMsg()}</Fragment>;\n    };\n    ```\n\n### Step 5: Other integration for BOGOS: Free Gift\n\n1. Hide gift product (cloned product) from your headless store\n\n    - If you use [products](https://shopify.dev/docs/api/storefront/lastes/queries/products) query, you should add : ```query: \"tag_not:bogos-gift\"```\n\n    ```graphql\n    products (\n        ...,\n        query: \"tag_not:bogos-gift\"\n    ) {\n    ...\n    }\n    ```\n\n    - For collection and product page, you can import <strong><code>bogosCheckGift</code></strong> and use returned value to skip gift products or replace to other pages\n\n    ```typescript\n    import {bogosCheckGift} from '@bogos/freegifts-hydrogen';\n    ```\n\n    - Details of <strong><code>bogosCheckGift</code></strong>\n\n    ```typescript\n    export type ProductObject = {\n        handle?: string;\n        tags?: string[];\n    };\n\n    /* item can be product handle */\n    export declare const bogosCheckGift: (item: string | ProductObject) => boolean;\n    ```\n\n2. <span id=\"customize-popup\">Customize gift popup/slider</span>\n\n    Change [isPopup](#isPopup) to true and listen event:\n\n    ```typescript\n    type GiftItem = {\n        id: number;\n        discount_type: 'percentage' | 'fixed_amount';\n        discount_value: number;\n        original_price: number;  // Original price - price before discount\n        price: number;           // Discount price - price after discount\n        title: string;\n        thumbnail?: string;\n    };\n\n    type GiftProduct = {\n        id: number;\n        title: string;\n        handle: string;\n        thumbnail?: string;\n        belongs_to_offer: string;\n        variants: GiftItem[];\n    };\n\n    export declare const bogosProcessAddGift: (variantID: number | string, quantity: number, offerId: string) => void;\n\n    document.addEventListener(\"fg-gifts:show-slider\", (e) => {\n        console.log((e as CustomEvent).detail.arrGiftShow);\n        /* render gift slider with arrGiftShow: GiftProduct[] */\n        /* use bogosProcessAddGift when click add to cart from popup to process BOGOS */\n    });\n    \n    ```\n\n3. Details of other event listeners\n\n    - <code>fg-gifts:updated</code>\n\n    ```typescript\n    document.addEventListener(\"fg-gifts:updated\", (e) => {\n        /* use this function to re-render cart with disableReloadCartUpdated: true */\n        console.log((e as CustomEvent).detail);\n        /* render gift slider with detail: { \n            is_auto?: boolean,\n            popup?: gift can be shown \n            add?: gift can be added to cart\n            update?: gift already in cart need to update\n        } */\n    });\n    ```\n\n    - <code>fg-cart:auto-updated</code>\n\n    ```typescript\n    document.addEventListener(\"fg-gifts:updated\", (e) => {\n        /* use this function to re-render cart with disableReloadCartUpdated: true when gifts are auto updated (add/remove) */\n        console.log((e as CustomEvent).detail);\n        /* detail: { \n            popup?: gift can be shown \n            add?: gift can be added to cart\n            update?: gift already in cart need to update\n        } */\n    });\n    ```\n\n    - <code>fg-gifts:added</code>: will not work if you [customize gifts popup](#customize-popup)\n\n    ```typescript\n    document.addEventListener(\"fg-gifts:added\", (e) => {\n        /* use this function to re-render cart with disableReloadCartUpdated: true */\n        console.log((e as CustomEvent).detail);\n        /* render gift slider with detail: { \n            is_auto?: boolean,\n            gift?: {\n                variant_id,\n                quantity\n            } gift added from popup\n        } */\n    });\n    ```\n\n4. Some features is not available on this version yet\n\n    - Stop the offer when the gift is out of stock\n    - Draft-Order API\n\n## Notice\n\n### Publish gift/cloned product to Headless channel (or other channels you want BOGOS package to work with)\n\n- After creating/editing offer, please make sure that the gift/cloned product is available on Headless channel in order for the offer to work.\n\n## Support\n\n[BOGOS: Free Gift](https://apps.shopify.com/freegifts) - [support@secomapp.com](mailto:support@secomapp.com)\n\nOR\n\nYou can contact our live-chat supporters in app on Shopify Admin.\n","readmeFilename":"README.md"}