text: webpackJsonp([11],{591:function(e,t,s){var n,l,i={};n=s(592),Object.keys(n).some(function(e){return"default"!==e&&"__esModule"!==e})&&console.warn("[vue-loader] vendor/yootheme/theme/builder/newsletter/app/field-newsletter-lists.vue: named exports in *.vue files are ignored."),l=s(593),e.exports=n||{},e.exports.__esModule&&(e.exports=e.exports.default);var o="function"==typeof e.exports?e.exports.options||(e.exports.options={}):e.exports;l&&(o.template=l),o.computed||(o.computed={}),Object.keys(i).forEach(function(e){var t=i[e];o.computed[e]=function(){return t}})},592:function(e,t,s){"use strict";function n(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var l=s(5),i=n(l),o=s(3),a=n(o),r={extends:a.default.component("field"),data:function(){return{clients:[],lists:[],error:!1}},compiled:function(){this.load()},computed:{apiKey:function(){return this.$app.config[this.field.provider+"_api"]}},methods:{load:function(){var e=this;this.apiKey&&this.$http.post("theme/newsletter/list",{settings:(0,i.default)({name:this.field.provider},this.value)}).then(function(t){e.clients=t.data.clients,e.lists=t.data.lists,!e.value.client_id&&e.clients.length&&(e.value.client_id=e.clients[0].value),!e.value.list_id&&e.lists.length&&(e.value.list_id=e.lists[0].value)},function(t){e.error=t.data})}}};a.default.fields["newsletter-lists"]=r,t.default=r},593:function(e,t){e.exports='\n\n<div>\n\n    <p class="uk-text uk-text-danger uk-margin-small" v-show="!apiKey">{{ $trans(\'Enter the API key in advanced system settings.\') }}</p>\n\n    <p class="uk-text uk-text-danger uk-margin-small" v-show="error">{{ error }}</p>\n\n    <select class="uk-select uk-margin-small-bottom" :class="class" v-bind="attrs" v-model="value.client_id" @change="load" v-show="clients.length">\n        <option v-for="option in clients" :value="option.value">{{ option.text }}</option>\n    </select>\n\n    <select class="uk-select" :class="class" v-bind="attrs" v-model="value.list_id" v-show="lists.length">\n        <option v-for="option in lists" :value="option.value">{{ option.text }}</option>\n    </select>\n    <p class="uk-text-muted uk-margin-small" v-show="lists.length">{{ $trans(\'Select the list to subscribe to.\')}}</p>\n\n</div>\n\n'}},[591]);