@accounts/graphql-client
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -1,1 +0,1 @@ | ||
!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n(require("graphql-tag"),require("babel-polyfill")):"function"==typeof define&&define.amd?define(["graphql-tag","babel-polyfill"],n):"object"==typeof exports?exports["@accounts/graphql-api"]=n(require("graphql-tag"),require("babel-polyfill")):e["@accounts/graphql-api"]=n(e["graphql-tag"],e["babel-polyfill"])}(this,function(e,n){return function(e){function n(r){if(t[r])return t[r].exports;var u=t[r]={exports:{},id:r,loaded:!1};return e[r].call(u.exports,u,u.exports,n),u.loaded=!0,u.exports}var t={};return n.m=e,n.c=t,n.p="",n(0)}([function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t(3);Object.keys(r).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return r[e]}})}),t(15)},function(e,n){e.exports=require("graphql-tag")},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.loginFieldsFragment=void 0;var o=u(["\n fragment LoginFields on LoginReturn {\n tokens {\n refreshToken\n accessToken\n }\n }\n "],["\n fragment LoginFields on LoginReturn {\n tokens {\n refreshToken\n accessToken\n }\n }\n "]),i=t(1),a=r(i);n.loginFieldsFragment=(0,a.default)(o)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e){return function(){var n=e.apply(this,arguments);return new Promise(function(e,t){function r(u,o){try{var i=n[u](o),a=i.value}catch(e){return void t(e)}return i.done?void e(a):Promise.resolve(a).then(function(e){r("next",e)},function(e){r("throw",e)})}return r("next")})}}function o(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}function i(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(n,"__esModule",{value:!0}),n.GraphQLClient=void 0;var a=function(){function e(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),s=o(["",""],["",""]),c=t(1),f=r(c),l=t(6),d=function(){function e(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(i(this,e),this.options=Object.assign({graphQLClient:null,userFieldsFragment:l.defaultUserFieldsFragment},n),this.options.userFieldsFragment=(0,f.default)(s,this.options.userFieldsFragment),!this.options.graphQLClient||!this.options.graphQLClient.query||!this.options.graphQLClient.mutate)throw new Error("Invalid GraphQL client provided: missing 'query' and 'mutate' methods!")}return a(e,[{key:"mutate",value:function(){function e(e,t,r){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n,t,r){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.options.graphQLClient.mutate({mutation:n,variables:r}).then(function(e){var n=e.data;return n[t]}).catch(function(e){throw new Error(e.message)});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"query",value:function(){function e(e,t,r){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n,t,r){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.options.graphQLClient.query({query:n,variables:r}).then(function(e){var n=e.data;return n[t]}).catch(function(e){throw new Error(e.message)});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"loginWithPassword",value:function(){function e(e,t){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n,t){var r;return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=(0,l.createLoginMutation)(this.options.userFieldsFragment),e.next=3,this.mutate(r,"loginWithPassword",{user:n,password:t});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}));return e}()},{key:"impersonate",value:function(){function e(e,t){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n,t){var r;return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=(0,l.createImpersonateMutation)(this.options.userFieldsFragment),e.next=3,this.mutate(r,"impersonate",{accessToken:n,username:t});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}));return e}()},{key:"createUser",value:function(){function e(e){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(l.createUserMutation,"createUser",{user:n});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"refreshTokens",value:function(){function e(e,t){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n,t){var r;return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=(0,l.createRefreshTokenMutation)(this.options.userFieldsFragment),e.next=3,this.mutate(r,"refreshTokens",{accessToken:n,refreshToken:t});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}));return e}()},{key:"logout",value:function(){function e(e){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(l.logoutMutation,"logout",{accessToken:n});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"verifyEmail",value:function(){function e(e){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(l.verifyEmailMutation,"verifyEmail",{token:n});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"resetPassword",value:function(){function e(e,t){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n,t){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(l.resetPasswordMutation,"resetPassword",{token:n,newPassword:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"sendVerificationEmail",value:function(){function e(e){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(l.sendVerificationEmailMutation,"sendVerificationEmail",{email:n});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"sendResetPasswordEmail",value:function(){function e(e){return n.apply(this,arguments)}var n=u(regeneratorRuntime.mark(function e(n){return regeneratorRuntime.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(l.sendResetPasswordEmailMutation,"sendResetPasswordEmail",{email:n});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()}]),e}();n.GraphQLClient=d},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.createUserMutation=void 0;var o=u([" \n mutation($user: CreateUserInput!) {\n createUser(user: $user)\n }\n"],[" \n mutation($user: CreateUserInput!) {\n createUser(user: $user)\n }\n"]),i=t(1),a=r(i);n.createUserMutation=(0,a.default)(o)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.createImpersonateMutation=void 0;var o=u(["\n mutation($accessToken: String! $username: String!) {\n impersonate(accessToken: $accessToken, username: $username) {\n authorized\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"],["\n mutation($accessToken: String! $username: String!) {\n impersonate(accessToken: $accessToken, username: $username) {\n authorized\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"]),i=t(1),a=r(i),s=t(2);n.createImpersonateMutation=function(e){return(0,a.default)(o,e,s.loginFieldsFragment)}},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t(7);Object.keys(r).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return r[e]}})});var u=t(9);Object.keys(u).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return u[e]}})});var o=t(4);Object.keys(o).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return o[e]}})});var i=t(8);Object.keys(i).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return i[e]}})});var a=t(14);Object.keys(a).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return a[e]}})});var s=t(10);Object.keys(s).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return s[e]}})});var c=t(12);Object.keys(c).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return c[e]}})});var f=t(11);Object.keys(f).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return f[e]}})});var l=t(13);Object.keys(l).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return l[e]}})});var d=t(5);Object.keys(d).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(n,e,{enumerable:!0,get:function(){return d[e]}})})},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.createLoginMutation=void 0;var o=u(["\n mutation($user: UserInput!, $password: String!) {\n loginWithPassword(user: $user, password: $password) {\n sessionId\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"],["\n mutation($user: UserInput!, $password: String!) {\n loginWithPassword(user: $user, password: $password) {\n sessionId\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"]),i=t(1),a=r(i),s=t(2);n.createLoginMutation=function(e){return(0,a.default)(o,e,s.loginFieldsFragment)}},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.logoutMutation=void 0;var o=u(["\n mutation logout($accessToken: String!) {\n logout(accessToken: $accessToken)\n }\n"],["\n mutation logout($accessToken: String!) {\n logout(accessToken: $accessToken)\n }\n"]),i=t(1),a=r(i);n.logoutMutation=(0,a.default)(o)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.createRefreshTokenMutation=void 0;var o=u(["\n mutation($accessToken: String!, $refreshToken: String!) {\n refreshTokens(accessToken: $accessToken, refreshToken: $refreshToken) {\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n\n ","\n ","\n"],["\n mutation($accessToken: String!, $refreshToken: String!) {\n refreshTokens(accessToken: $accessToken, refreshToken: $refreshToken) {\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n\n ","\n ","\n"]),i=t(1),a=r(i),s=t(2);n.createRefreshTokenMutation=function(e){return(0,a.default)(o,e,s.loginFieldsFragment)}},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.resetPasswordMutation=void 0;var o=u(["\n mutation($token: String!, $password: PasswordInput!) {\n resetPassword(token: $token, password: $password)\n }\n"],["\n mutation($token: String!, $password: PasswordInput!) {\n resetPassword(token: $token, password: $password)\n }\n"]),i=t(1),a=r(i);n.resetPasswordMutation=(0,a.default)(o)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.sendResetPasswordEmailMutation=void 0;var o=u(["\n mutation($email: String!) {\n sendResetPasswordEmail(email: $email)\n }\n"],["\n mutation($email: String!) {\n sendResetPasswordEmail(email: $email)\n }\n"]),i=t(1),a=r(i);n.sendResetPasswordEmailMutation=(0,a.default)(o)},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.sendVerificationEmailMutation=void 0;var o=u(["\n mutation($email: String!) {\n sendVerificationEmail(email: $email)\n }\n"],["\n mutation($email: String!) {\n sendVerificationEmail(email: $email)\n }\n"]),i=t(1),a=r(i);n.sendVerificationEmailMutation=(0,a.default)(o)},function(e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});n.defaultUserFieldsFragment="\n fragment UserFields on User {\n email\n username\n }\n"},function(e,n,t){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function u(e,n){return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}Object.defineProperty(n,"__esModule",{value:!0}),n.verifyEmailMutation=void 0;var o=u(["\n mutation($token: String!) {\n verifyEmail(token: $token)\n }\n"],["\n mutation($token: String!) {\n verifyEmail(token: $token)\n }\n"]),i=t(1),a=r(i);n.verifyEmailMutation=(0,a.default)(o)},function(e,n){e.exports=require("babel-polyfill")}])}); | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("babel-runtime/helpers/taggedTemplateLiteral"),require("graphql-tag"),require("babel-runtime/core-js/object/define-property"),require("babel-runtime/core-js/object/keys"),require("babel-runtime/core-js/object/assign"),require("babel-runtime/helpers/asyncToGenerator"),require("babel-runtime/helpers/classCallCheck"),require("babel-runtime/helpers/createClass"),require("babel-runtime/regenerator")):"function"==typeof define&&define.amd?define(["babel-runtime/helpers/taggedTemplateLiteral","graphql-tag","babel-runtime/core-js/object/define-property","babel-runtime/core-js/object/keys","babel-runtime/core-js/object/assign","babel-runtime/helpers/asyncToGenerator","babel-runtime/helpers/classCallCheck","babel-runtime/helpers/createClass","babel-runtime/regenerator"],t):"object"==typeof exports?exports["@accounts/graphql-api"]=t(require("babel-runtime/helpers/taggedTemplateLiteral"),require("graphql-tag"),require("babel-runtime/core-js/object/define-property"),require("babel-runtime/core-js/object/keys"),require("babel-runtime/core-js/object/assign"),require("babel-runtime/helpers/asyncToGenerator"),require("babel-runtime/helpers/classCallCheck"),require("babel-runtime/helpers/createClass"),require("babel-runtime/regenerator")):e["@accounts/graphql-api"]=t(e["babel-runtime/helpers/taggedTemplateLiteral"],e["graphql-tag"],e["babel-runtime/core-js/object/define-property"],e["babel-runtime/core-js/object/keys"],e["babel-runtime/core-js/object/assign"],e["babel-runtime/helpers/asyncToGenerator"],e["babel-runtime/helpers/classCallCheck"],e["babel-runtime/helpers/createClass"],e["babel-runtime/regenerator"])}(this,function(e,t,n,r,a,u,s,i,o){return function(e){function t(r){if(n[r])return n[r].exports;var a=n[r]={exports:{},id:r,loaded:!1};return e[r].call(a.exports,a,a.exports,t),a.loaded=!0,a.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}var a=n(4),u=r(a),s=n(5),i=r(s);Object.defineProperty(t,"__esModule",{value:!0});var o=n(6);(0,i.default)(o).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return o[e]}})})},function(e,t){e.exports=require("babel-runtime/helpers/taggedTemplateLiteral")},function(e,t){e.exports=require("graphql-tag")},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.loginFieldsFragment=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n fragment LoginFields on LoginReturn {\n tokens {\n refreshToken\n accessToken\n }\n }\n "],["\n fragment LoginFields on LoginReturn {\n tokens {\n refreshToken\n accessToken\n }\n }\n "]),i=n(2),o=r(i);t.loginFieldsFragment=(0,o.default)(s)},function(e,t){e.exports=require("babel-runtime/core-js/object/define-property")},function(e,t){e.exports=require("babel-runtime/core-js/object/keys")},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.GraphQLClient=void 0;var a=n(22),u=r(a),s=n(19),i=r(s),o=n(1),l=r(o),c=n(18),f=r(c),d=n(20),p=r(d),m=n(21),h=r(m),b=(0,l.default)(["",""],["",""]),g=n(2),v=r(g),k=n(9),_=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if((0,p.default)(this,e),this.options=(0,f.default)({graphQLClient:null,userFieldsFragment:k.defaultUserFieldsFragment},t),this.options.userFieldsFragment=(0,v.default)(b,this.options.userFieldsFragment),!this.options.graphQLClient||!this.options.graphQLClient.query||!this.options.graphQLClient.mutate)throw new Error("Invalid GraphQL client provided: missing 'query' and 'mutate' methods!")}return(0,h.default)(e,[{key:"mutate",value:function(){function e(e,n,r){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t,n,r){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.options.graphQLClient.mutate({mutation:t,variables:r}).then(function(e){var t=e.data;return t[n]}).catch(function(e){throw new Error(e.message)});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"query",value:function(){function e(e,n,r){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t,n,r){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.options.graphQLClient.query({query:t,variables:r}).then(function(e){var t=e.data;return t[n]}).catch(function(e){throw new Error(e.message)});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"loginWithPassword",value:function(){function e(e,n){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t,n){var r;return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=(0,k.createLoginMutation)(this.options.userFieldsFragment),e.next=3,this.mutate(r,"loginWithPassword",{user:t,password:n});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}));return e}()},{key:"impersonate",value:function(){function e(e,n){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t,n){var r;return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=(0,k.createImpersonateMutation)(this.options.userFieldsFragment),e.next=3,this.mutate(r,"impersonate",{accessToken:t,username:n});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}));return e}()},{key:"createUser",value:function(){function e(e){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(k.createUserMutation,"createUser",{user:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"refreshTokens",value:function(){function e(e,n){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t,n){var r;return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return r=(0,k.createRefreshTokenMutation)(this.options.userFieldsFragment),e.next=3,this.mutate(r,"refreshTokens",{accessToken:t,refreshToken:n});case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}},e,this)}));return e}()},{key:"logout",value:function(){function e(e){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(k.logoutMutation,"logout",{accessToken:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"verifyEmail",value:function(){function e(e){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(k.verifyEmailMutation,"verifyEmail",{token:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"resetPassword",value:function(){function e(e,n){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t,n){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(k.resetPasswordMutation,"resetPassword",{token:t,newPassword:n});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"sendVerificationEmail",value:function(){function e(e){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(k.sendVerificationEmailMutation,"sendVerificationEmail",{email:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()},{key:"sendResetPasswordEmail",value:function(){function e(e){return t.apply(this,arguments)}var t=(0,i.default)(u.default.mark(function e(t){return u.default.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.mutate(k.sendResetPasswordEmailMutation,"sendResetPasswordEmail",{email:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}},e,this)}));return e}()}]),e}();t.GraphQLClient=_},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createUserMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)([" \n mutation($user: CreateUserInput!) {\n createUser(user: $user)\n }\n"],[" \n mutation($user: CreateUserInput!) {\n createUser(user: $user)\n }\n"]),i=n(2),o=r(i);t.createUserMutation=(0,o.default)(s)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createImpersonateMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation($accessToken: String! $username: String!) {\n impersonate(accessToken: $accessToken, username: $username) {\n authorized\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"],["\n mutation($accessToken: String! $username: String!) {\n impersonate(accessToken: $accessToken, username: $username) {\n authorized\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"]),i=n(2),o=r(i),l=n(3);t.createImpersonateMutation=function(e){return(0,o.default)(s,e,l.loginFieldsFragment)}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}var a=n(4),u=r(a),s=n(5),i=r(s);Object.defineProperty(t,"__esModule",{value:!0});var o=n(10);(0,i.default)(o).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return o[e]}})});var l=n(12);(0,i.default)(l).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return l[e]}})});var c=n(7);(0,i.default)(c).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return c[e]}})});var f=n(11);(0,i.default)(f).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return f[e]}})});var d=n(17);(0,i.default)(d).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return d[e]}})});var p=n(13);(0,i.default)(p).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return p[e]}})});var m=n(15);(0,i.default)(m).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return m[e]}})});var h=n(14);(0,i.default)(h).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return h[e]}})});var b=n(16);(0,i.default)(b).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return b[e]}})});var g=n(8);(0,i.default)(g).forEach(function(e){"default"!==e&&"__esModule"!==e&&(0,u.default)(t,e,{enumerable:!0,get:function(){return g[e]}})})},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createLoginMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation($user: UserInput!, $password: String!) {\n loginWithPassword(user: $user, password: $password) {\n sessionId\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"],["\n mutation($user: UserInput!, $password: String!) {\n loginWithPassword(user: $user, password: $password) {\n sessionId\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n \n ","\n ","\n"]),i=n(2),o=r(i),l=n(3);t.createLoginMutation=function(e){return(0,o.default)(s,e,l.loginFieldsFragment)}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.logoutMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation logout($accessToken: String!) {\n logout(accessToken: $accessToken)\n }\n"],["\n mutation logout($accessToken: String!) {\n logout(accessToken: $accessToken)\n }\n"]),i=n(2),o=r(i);t.logoutMutation=(0,o.default)(s)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createRefreshTokenMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation($accessToken: String!, $refreshToken: String!) {\n refreshTokens(accessToken: $accessToken, refreshToken: $refreshToken) {\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n\n ","\n ","\n"],["\n mutation($accessToken: String!, $refreshToken: String!) {\n refreshTokens(accessToken: $accessToken, refreshToken: $refreshToken) {\n ...LoginFields\n user {\n id\n ...UserFields\n }\n }\n }\n\n ","\n ","\n"]),i=n(2),o=r(i),l=n(3);t.createRefreshTokenMutation=function(e){return(0,o.default)(s,e,l.loginFieldsFragment)}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.resetPasswordMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation($token: String!, $password: PasswordInput!) {\n resetPassword(token: $token, password: $password)\n }\n"],["\n mutation($token: String!, $password: PasswordInput!) {\n resetPassword(token: $token, password: $password)\n }\n"]),i=n(2),o=r(i);t.resetPasswordMutation=(0,o.default)(s)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.sendResetPasswordEmailMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation($email: String!) {\n sendResetPasswordEmail(email: $email)\n }\n"],["\n mutation($email: String!) {\n sendResetPasswordEmail(email: $email)\n }\n"]),i=n(2),o=r(i);t.sendResetPasswordEmailMutation=(0,o.default)(s)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.sendVerificationEmailMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation($email: String!) {\n sendVerificationEmail(email: $email)\n }\n"],["\n mutation($email: String!) {\n sendVerificationEmail(email: $email)\n }\n"]),i=n(2),o=r(i);t.sendVerificationEmailMutation=(0,o.default)(s)},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.defaultUserFieldsFragment="\n fragment UserFields on User {\n email\n username\n }\n"},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.verifyEmailMutation=void 0;var a=n(1),u=r(a),s=(0,u.default)(["\n mutation($token: String!) {\n verifyEmail(token: $token)\n }\n"],["\n mutation($token: String!) {\n verifyEmail(token: $token)\n }\n"]),i=n(2),o=r(i);t.verifyEmailMutation=(0,o.default)(s)},function(e,t){e.exports=require("babel-runtime/core-js/object/assign")},function(e,t){e.exports=require("babel-runtime/helpers/asyncToGenerator")},function(e,t){e.exports=require("babel-runtime/helpers/classCallCheck")},function(e,t){e.exports=require("babel-runtime/helpers/createClass")},function(e,t){e.exports=require("babel-runtime/regenerator")}])}); |
{ | ||
"name": "@accounts/graphql-client", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"description": "GraphQL client transport for accounts", | ||
@@ -39,10 +39,13 @@ "main": "lib/index.js", | ||
"babel-eslint": "^7.0.0", | ||
"babel-loader": "^6.4.1", | ||
"babel-loader": "^7.1.1", | ||
"babel-plugin-syntax-async-functions": "^6.13.0", | ||
"babel-plugin-transform-async-to-generator": "^6.16.0", | ||
"babel-plugin-transform-class-properties": "^6.24.1", | ||
"babel-plugin-transform-flow-strip-types": "^6.18.0", | ||
"babel-plugin-transform-object-rest-spread": "^6.16.0", | ||
"babel-plugin-transform-regenerator": "^6.16.1", | ||
"babel-plugin-transform-runtime": "^6.23.0", | ||
"babel-preset-es2015": "^6.24.1", | ||
"babel-preset-es2015-node4": "^2.1.0", | ||
"babel-preset-stage-0": "^6.24.1", | ||
"coveralls": "^2.11.14", | ||
@@ -66,5 +69,5 @@ "eslint": "^3.7.1", | ||
"@accounts/common": "^0.0.4", | ||
"babel-polyfill": "^6.23.0", | ||
"babel-runtime": "^6.23.0", | ||
"graphql-tag": "^1.1.2" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
20007
29
+ Addedbabel-runtime@^6.23.0
- Removedbabel-polyfill@^6.23.0
- Removedbabel-polyfill@6.26.0(transitive)
- Removedregenerator-runtime@0.10.5(transitive)