_N_E=(window.webpackJsonp_N_E=window.webpackJsonp_N_E||[]).push([[54],{ewmg:function(e,t,n){"use strict";n.r(t);var r=n("rePB"),a=n("nKUr"),c=n("Ff2n"),o=(n("q1tI"),n("yE/o")),u=n("gaPq"),i=n("wx14"),O=n("h4VS"),s=n("eHHv"),b=n("UYTu"),g=n("JznV"),j=n("20a2"),p=n("hePV"),f=n.n(p),l=n("gmoh"),w=n.n(l),d=n("fjVX"),y=n.n(d),P=n("oB+O"),h=n.n(P),v=n("7zkD"),m=n("PaXs");function _(){var e=Object(O.a)(["\n      mutation createLanguage($language: CreateLanguageInput!) {\n        createLanguage(language: $language) {\n          _id\n        }\n      }\n    "]);return _=function(){return e},e}function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach((function(t){Object(r.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var E=Object(s.a)(j.withRouter,Object(g.a)(Object(b.a)(_()),{name:"createLanguage",options:{refetchQueries:["languages"]}}),Object(v.a)({isoCode:{type:String,optional:!1,label:"ISO Sprachcode"}}),Object(s.f)({onSubmitSuccess:function(e){var t=e.router;return function(e){var n=e.data.createLanguage;t.replace({pathname:"/languages/edit",query:{_id:n._id}})}},onSubmit:function(e){var t=e.createLanguage,n=e.schema;return function(e){var r=Object(i.a)({},e);return t({variables:{language:n.clean(r)}})}}}),m.a,Object(s.d)((function(e){e.createLanguage;return x({},Object(c.a)(e,["createLanguage"]))})),s.e)((function(e){return Object(a.jsxs)(h.a,x(x({},e),{},{children:[Object(a.jsx)(f.a,{name:"isoCode"}),Object(a.jsx)(y.a,{}),Object(a.jsx)(w.a,{value:"Add language",className:"primary"})]}))})),D=n("PZVx");function L(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?L(Object(n),!0).forEach((function(t){Object(r.a)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):L(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}t.default=Object(D.a)((function(e){e.onSuccess;var t=Object(c.a)(e,["onSuccess"]);return Object(a.jsx)(u.a,N(N({},t),{},{children:Object(a.jsxs)(o.a,{children:[Object(a.jsx)("p",{children:"Add Language"}),Object(a.jsx)(E,{})]})}))}))},luF5:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/languages/new",function(){return n("ewmg")}])}},[["luF5",0,2,3,1,4,5,6,7]]]);