@magic-ext/farcaster
Advanced tools
Comparing version 0.18.2-canary.842.12375745226.0 to 0.18.2-canary.846.12474511164.0
@@ -1,2 +0,2 @@ | ||
"use strict";var i=Object.defineProperty;var g=Object.getOwnPropertyDescriptor;var p=Object.getOwnPropertyNames;var f=Object.prototype.hasOwnProperty;var h=(n,e)=>{for(var t in e)i(n,t,{get:e[t],enumerable:!0})},v=(n,e,t,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of p(e))!f.call(n,r)&&r!==t&&i(n,r,{get:()=>e[r],enumerable:!(o=g(e,r))||o.enumerable});return n};var C=n=>v(i({},"__esModule",{value:!0}),n);var E={};h(E,{FarcasterExtension:()=>s,isMobile:()=>a});module.exports=C(E);var u=require("@magic-sdk/commons");function m(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function w(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function b(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function x(){return w()||b()}function a(){return m()||x()}function c(){return typeof window!="undefined"&&window===window.top}var A=!0;var s=class extends u.Extension.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=t=>{var l;let o=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(l=t==null?void 0:t.showUI)!=null?l:A,domain:window.location.host,siweUri:window.location.origin}}]),r=this.request(o);return r.on("channel",d=>{a()&&c()&&(window.location.href=d.url)}),r}}}; | ||
"use strict";var i=Object.defineProperty;var g=Object.getOwnPropertyDescriptor;var p=Object.getOwnPropertyNames;var f=Object.prototype.hasOwnProperty;var h=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},v=(t,e,r,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of p(e))!f.call(t,n)&&n!==r&&i(t,n,{get:()=>e[n],enumerable:!(o=g(e,n))||o.enumerable});return t};var C=t=>v(i({},"__esModule",{value:!0}),t);var A={};h(A,{FarcasterExtension:()=>l,isMobile:()=>s});module.exports=C(A);var a=require("@magic-sdk/commons");function m(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function E(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function w(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function b(){return E()||w()}function s(){return m()||b()}function d(){return typeof window!="undefined"&&window===window.top}var x=!0;var l=class extends a.Extension.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=r=>{var c;let o=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(c=r==null?void 0:r.showUI)!=null?c:x,domain:window.location.host,siweUri:window.location.origin}}]),n=this.request(o);return n.on("channel",u=>{s()&&d()&&(window.location.href=u.url)}),n.on(a.FarcasterLoginEventEmit.Cancel,()=>{this.createIntermediaryEvent(a.FarcasterLoginEventEmit.Cancel,o.id)()}),n}}}; | ||
//# sourceMappingURL=index.js.map |
@@ -1,2 +0,2 @@ | ||
"use strict";var i=Object.defineProperty;var g=Object.getOwnPropertyDescriptor;var p=Object.getOwnPropertyNames;var f=Object.prototype.hasOwnProperty;var h=(n,e)=>{for(var t in e)i(n,t,{get:e[t],enumerable:!0})},v=(n,e,t,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of p(e))!f.call(n,r)&&r!==t&&i(n,r,{get:()=>e[r],enumerable:!(o=g(e,r))||o.enumerable});return n};var C=n=>v(i({},"__esModule",{value:!0}),n);var E={};h(E,{FarcasterExtension:()=>s,isMobile:()=>a});module.exports=C(E);var u=require("@magic-sdk/commons");function m(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function w(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function b(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function x(){return w()||b()}function a(){return m()||x()}function c(){return typeof window!="undefined"&&window===window.top}var A=!0;var s=class extends u.Extension.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=t=>{var l;let o=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(l=t==null?void 0:t.showUI)!=null?l:A,domain:window.location.host,siweUri:window.location.origin}}]),r=this.request(o);return r.on("channel",d=>{a()&&c()&&(window.location.href=d.url)}),r}}}; | ||
"use strict";var i=Object.defineProperty;var g=Object.getOwnPropertyDescriptor;var p=Object.getOwnPropertyNames;var f=Object.prototype.hasOwnProperty;var h=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},v=(t,e,r,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of p(e))!f.call(t,n)&&n!==r&&i(t,n,{get:()=>e[n],enumerable:!(o=g(e,n))||o.enumerable});return t};var C=t=>v(i({},"__esModule",{value:!0}),t);var A={};h(A,{FarcasterExtension:()=>l,isMobile:()=>s});module.exports=C(A);var a=require("@magic-sdk/commons");function m(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function E(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function w(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function b(){return E()||w()}function s(){return m()||b()}function d(){return typeof window!="undefined"&&window===window.top}var x=!0;var l=class extends a.Extension.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=r=>{var c;let o=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(c=r==null?void 0:r.showUI)!=null?c:x,domain:window.location.host,siweUri:window.location.origin}}]),n=this.request(o);return n.on("channel",u=>{s()&&d()&&(window.location.href=u.url)}),n.on(a.FarcasterLoginEventEmit.Cancel,()=>{this.createIntermediaryEvent(a.FarcasterLoginEventEmit.Cancel,o.id)()}),n}}}; | ||
//# sourceMappingURL=index.js.map |
@@ -1,2 +0,2 @@ | ||
import{Extension as g}from"@magic-sdk/commons";function l(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function c(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function u(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function d(){return c()||u()}function r(){return l()||d()}function o(){return typeof window!="undefined"&&window===window.top}var p=!0;var i=class extends g.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=e=>{var t;let a=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(t=e==null?void 0:e.showUI)!=null?t:p,domain:window.location.host,siweUri:window.location.origin}}]),n=this.request(a);return n.on("channel",s=>{r()&&o()&&(window.location.href=s.url)}),n}}};export{i as FarcasterExtension,r as isMobile}; | ||
import{Extension as p,FarcasterLoginEventEmit as i}from"@magic-sdk/commons";function c(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function d(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function u(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function g(){return d()||u()}function o(){return c()||g()}function a(){return typeof window!="undefined"&&window===window.top}var f=!0;var s=class extends p.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=e=>{var r;let t=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(r=e==null?void 0:e.showUI)!=null?r:f,domain:window.location.host,siweUri:window.location.origin}}]),n=this.request(t);return n.on("channel",l=>{o()&&a()&&(window.location.href=l.url)}),n.on(i.Cancel,()=>{this.createIntermediaryEvent(i.Cancel,t.id)()}),n}}};export{s as FarcasterExtension,o as isMobile}; | ||
//# sourceMappingURL=index.js.map |
@@ -1,2 +0,2 @@ | ||
"use strict";var MagicFarcasterExtension=(()=>{var h=Object.create;var i=Object.defineProperty;var v=Object.getOwnPropertyDescriptor;var C=Object.getOwnPropertyNames;var m=Object.getPrototypeOf,w=Object.prototype.hasOwnProperty;var b=(e,n)=>()=>(n||e((n={exports:{}}).exports,n),n.exports),x=(e,n)=>{for(var t in n)i(e,t,{get:n[t],enumerable:!0})},c=(e,n,t,o)=>{if(n&&typeof n=="object"||typeof n=="function")for(let r of C(n))!w.call(e,r)&&r!==t&&i(e,r,{get:()=>n[r],enumerable:!(o=v(n,r))||o.enumerable});return e};var A=(e,n,t)=>(t=e!=null?h(m(e)):{},c(n||!e||!e.__esModule?i(t,"default",{value:e,enumerable:!0}):t,e)),E=e=>c(i({},"__esModule",{value:!0}),e);var d=b((S,u)=>{u.exports=Magic});var P={};x(P,{FarcasterExtension:()=>s,isMobile:()=>a});var p=A(d());function I(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function R(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function y(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function F(){return R()||y()}function a(){return I()||F()}function g(){return typeof window!="undefined"&&window===window.top}var O=!0;var s=class extends p.Extension.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=t=>{var l;let o=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(l=t==null?void 0:t.showUI)!=null?l:O,domain:window.location.host,siweUri:window.location.origin}}]),r=this.request(o);return r.on("channel",f=>{a()&&g()&&(window.location.href=f.url)}),r}}};return E(P);})(); | ||
"use strict";var MagicFarcasterExtension=(()=>{var h=Object.create;var i=Object.defineProperty;var v=Object.getOwnPropertyDescriptor;var C=Object.getOwnPropertyNames;var m=Object.getPrototypeOf,E=Object.prototype.hasOwnProperty;var w=(e,n)=>()=>(n||e((n={exports:{}}).exports,n),n.exports),b=(e,n)=>{for(var t in n)i(e,t,{get:n[t],enumerable:!0})},d=(e,n,t,o)=>{if(n&&typeof n=="object"||typeof n=="function")for(let r of C(n))!E.call(e,r)&&r!==t&&i(e,r,{get:()=>n[r],enumerable:!(o=v(n,r))||o.enumerable});return e};var x=(e,n,t)=>(t=e!=null?h(m(e)):{},d(n||!e||!e.__esModule?i(t,"default",{value:e,enumerable:!0}):t,e)),A=e=>d(i({},"__esModule",{value:!0}),e);var g=w((S,u)=>{u.exports=Magic});var O={};b(O,{FarcasterExtension:()=>c,isMobile:()=>s});var a=x(g());function y(){return typeof navigator!="undefined"&&/android/i.test(navigator.userAgent)}function I(){return typeof navigator!="undefined"&&/iPhone|iPod/.test(navigator.userAgent)}function F(){return typeof navigator!="undefined"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function R(){return I()||F()}function s(){return y()||R()}function p(){return typeof window!="undefined"&&window===window.top}var L=!0;var c=class extends a.Extension.Internal{constructor(){super(...arguments);this.name="farcaster";this.config={};this.login=t=>{var l;let o=this.utils.createJsonRpcRequestPayload("farcaster_show_QR",[{data:{showUI:(l=t==null?void 0:t.showUI)!=null?l:L,domain:window.location.host,siweUri:window.location.origin}}]),r=this.request(o);return r.on("channel",f=>{s()&&p()&&(window.location.href=f.url)}),r.on(a.FarcasterLoginEventEmit.Cancel,()=>{this.createIntermediaryEvent(a.FarcasterLoginEventEmit.Cancel,o.id)()}),r}}};return A(O);})(); | ||
if (MagicFarcasterExtension && MagicFarcasterExtension.default != null) { MagicFarcasterExtension = Object.assign(MagicFarcasterExtension.default, MagicFarcasterExtension); delete MagicFarcasterExtension.default; } |
@@ -1,2 +0,2 @@ | ||
import { Extension } from '@magic-sdk/commons'; | ||
import { Extension, FarcasterLoginEventEmit } from '@magic-sdk/commons'; | ||
import { isMobile } from './utils'; | ||
@@ -50,2 +50,3 @@ type LoginParams = { | ||
[FarcasterLoginEventOnReceived.Failed]: (error: AuthClientError) => void; | ||
[FarcasterLoginEventEmit.Cancel]: () => void; | ||
}; | ||
@@ -52,0 +53,0 @@ export declare class FarcasterExtension extends Extension.Internal<'farcaster'> { |
{ | ||
"name": "@magic-ext/farcaster", | ||
"version": "0.18.2-canary.842.12375745226.0", | ||
"version": "0.18.2-canary.846.12474511164.0", | ||
"description": "magic farcaster extension", | ||
@@ -31,5 +31,5 @@ "author": "Magic <team@magic.link> (https://magic.link/)", | ||
"devDependencies": { | ||
"@magic-sdk/commons": "24.18.2-canary.842.12375745226.0" | ||
"@magic-sdk/commons": "24.18.2-canary.846.12474511164.0" | ||
}, | ||
"gitHead": "4fb370cab02463ce4887cea2002f40ed81df62e9" | ||
"gitHead": "343b2f1d106fc26e642da17821962113c9edb1b9" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
36023
104