1 | module.exports =
|
2 | (function(modules) {
|
3 |
|
4 | var installedModules = {};
|
5 |
|
6 |
|
7 | function __webpack_require__(moduleId) {
|
8 |
|
9 |
|
10 | if(installedModules[moduleId]) {
|
11 | return installedModules[moduleId].exports;
|
12 | }
|
13 |
|
14 | var module = installedModules[moduleId] = {
|
15 | i: moduleId,
|
16 | l: false,
|
17 | exports: {}
|
18 | };
|
19 |
|
20 |
|
21 | modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
22 |
|
23 |
|
24 | module.l = true;
|
25 |
|
26 |
|
27 | return module.exports;
|
28 | }
|
29 |
|
30 |
|
31 |
|
32 | __webpack_require__.m = modules;
|
33 |
|
34 |
|
35 | __webpack_require__.c = installedModules;
|
36 |
|
37 |
|
38 | __webpack_require__.d = function(exports, name, getter) {
|
39 | if(!__webpack_require__.o(exports, name)) {
|
40 | Object.defineProperty(exports, name, { enumerable: true, get: getter });
|
41 | }
|
42 | };
|
43 |
|
44 |
|
45 | __webpack_require__.r = function(exports) {
|
46 | if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
47 | Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
48 | }
|
49 | Object.defineProperty(exports, '__esModule', { value: true });
|
50 | };
|
51 |
|
52 |
|
53 |
|
54 |
|
55 |
|
56 |
|
57 | __webpack_require__.t = function(value, mode) {
|
58 | if(mode & 1) value = __webpack_require__(value);
|
59 | if(mode & 8) return value;
|
60 | if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
|
61 | var ns = Object.create(null);
|
62 | __webpack_require__.r(ns);
|
63 | Object.defineProperty(ns, 'default', { enumerable: true, value: value });
|
64 | if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
|
65 | return ns;
|
66 | };
|
67 |
|
68 |
|
69 | __webpack_require__.n = function(module) {
|
70 | var getter = module && module.__esModule ?
|
71 | function getDefault() { return module['default']; } :
|
72 | function getModuleExports() { return module; };
|
73 | __webpack_require__.d(getter, 'a', getter);
|
74 | return getter;
|
75 | };
|
76 |
|
77 |
|
78 | __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
79 |
|
80 |
|
81 | __webpack_require__.p = "/dist/";
|
82 |
|
83 |
|
84 |
|
85 | return __webpack_require__(__webpack_require__.s = 81);
|
86 | })
|
87 |
|
88 | ({
|
89 |
|
90 | 0:
|
91 | (function(module, __webpack_exports__, __webpack_require__) {
|
92 |
|
93 | "use strict";
|
94 | __webpack_require__.d(__webpack_exports__, "a", function() { return normalizeComponent; });
|
95 |
|
96 |
|
97 |
|
98 |
|
99 |
|
100 |
|
101 | function normalizeComponent (
|
102 | scriptExports,
|
103 | render,
|
104 | staticRenderFns,
|
105 | functionalTemplate,
|
106 | injectStyles,
|
107 | scopeId,
|
108 | moduleIdentifier, /* server only */
|
109 | shadowMode /* vue-cli only */
|
110 | ) {
|
111 |
|
112 | var options = typeof scriptExports === 'function'
|
113 | ? scriptExports.options
|
114 | : scriptExports
|
115 |
|
116 |
|
117 | if (render) {
|
118 | options.render = render
|
119 | options.staticRenderFns = staticRenderFns
|
120 | options._compiled = true
|
121 | }
|
122 |
|
123 |
|
124 | if (functionalTemplate) {
|
125 | options.functional = true
|
126 | }
|
127 |
|
128 |
|
129 | if (scopeId) {
|
130 | options._scopeId = 'data-v-' + scopeId
|
131 | }
|
132 |
|
133 | var hook
|
134 | if (moduleIdentifier) {
|
135 | hook = function (context) {
|
136 |
|
137 | context =
|
138 | context ||
|
139 | (this.$vnode && this.$vnode.ssrContext) ||
|
140 | (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext)
|
141 |
|
142 | if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
|
143 | context = __VUE_SSR_CONTEXT__
|
144 | }
|
145 |
|
146 | if (injectStyles) {
|
147 | injectStyles.call(this, context)
|
148 | }
|
149 |
|
150 | if (context && context._registeredComponents) {
|
151 | context._registeredComponents.add(moduleIdentifier)
|
152 | }
|
153 | }
|
154 |
|
155 |
|
156 | options._ssrRegister = hook
|
157 | } else if (injectStyles) {
|
158 | hook = shadowMode
|
159 | ? function () { injectStyles.call(this, this.$root.$options.shadowRoot) }
|
160 | : injectStyles
|
161 | }
|
162 |
|
163 | if (hook) {
|
164 | if (options.functional) {
|
165 |
|
166 |
|
167 | options._injectStyles = hook
|
168 |
|
169 | var originalRender = options.render
|
170 | options.render = function renderWithStyleInjection (h, context) {
|
171 | hook.call(context)
|
172 | return originalRender(h, context)
|
173 | }
|
174 | } else {
|
175 |
|
176 | var existing = options.beforeCreate
|
177 | options.beforeCreate = existing
|
178 | ? [].concat(existing, hook)
|
179 | : [hook]
|
180 | }
|
181 | }
|
182 |
|
183 | return {
|
184 | exports: scriptExports,
|
185 | options: options
|
186 | }
|
187 | }
|
188 |
|
189 |
|
190 | }),
|
191 |
|
192 | 4:
|
193 | (function(module, exports) {
|
194 |
|
195 | module.exports = require("element-ui/lib/mixins/emitter");
|
196 |
|
197 | }),
|
198 |
|
199 | 81:
|
200 | (function(module, __webpack_exports__, __webpack_require__) {
|
201 |
|
202 | "use strict";
|
203 | __webpack_require__.r(__webpack_exports__);
|
204 |
|
205 |
|
206 | var render = function() {
|
207 | var _vm = this
|
208 | var _h = _vm.$createElement
|
209 | var _c = _vm._self._c || _h
|
210 | return _c(
|
211 | "label",
|
212 | {
|
213 | staticClass: "el-radio-button",
|
214 | class: [
|
215 | _vm.size ? "el-radio-button--" + _vm.size : "",
|
216 | { "is-active": _vm.value === _vm.label },
|
217 | { "is-disabled": _vm.isDisabled },
|
218 | { "is-focus": _vm.focus }
|
219 | ],
|
220 | attrs: {
|
221 | role: "radio",
|
222 | "aria-checked": _vm.value === _vm.label,
|
223 | "aria-disabled": _vm.isDisabled,
|
224 | tabindex: _vm.tabIndex
|
225 | },
|
226 | on: {
|
227 | keydown: function($event) {
|
228 | if (
|
229 | !("button" in $event) &&
|
230 | _vm._k($event.keyCode, "space", 32, $event.key, [" ", "Spacebar"])
|
231 | ) {
|
232 | return null
|
233 | }
|
234 | $event.stopPropagation()
|
235 | $event.preventDefault()
|
236 | _vm.value = _vm.isDisabled ? _vm.value : _vm.label
|
237 | }
|
238 | }
|
239 | },
|
240 | [
|
241 | _c("input", {
|
242 | directives: [
|
243 | {
|
244 | name: "model",
|
245 | rawName: "v-model",
|
246 | value: _vm.value,
|
247 | expression: "value"
|
248 | }
|
249 | ],
|
250 | staticClass: "el-radio-button__orig-radio",
|
251 | attrs: {
|
252 | type: "radio",
|
253 | name: _vm.name,
|
254 | disabled: _vm.isDisabled,
|
255 | tabindex: "-1"
|
256 | },
|
257 | domProps: { value: _vm.label, checked: _vm._q(_vm.value, _vm.label) },
|
258 | on: {
|
259 | change: [
|
260 | function($event) {
|
261 | _vm.value = _vm.label
|
262 | },
|
263 | _vm.handleChange
|
264 | ],
|
265 | focus: function($event) {
|
266 | _vm.focus = true
|
267 | },
|
268 | blur: function($event) {
|
269 | _vm.focus = false
|
270 | }
|
271 | }
|
272 | }),
|
273 | _c(
|
274 | "span",
|
275 | {
|
276 | staticClass: "el-radio-button__inner",
|
277 | style: _vm.value === _vm.label ? _vm.activeStyle : null,
|
278 | on: {
|
279 | keydown: function($event) {
|
280 | $event.stopPropagation()
|
281 | }
|
282 | }
|
283 | },
|
284 | [
|
285 | _vm._t("default"),
|
286 | !_vm.$slots.default ? [_vm._v(_vm._s(_vm.label))] : _vm._e()
|
287 | ],
|
288 | 2
|
289 | )
|
290 | ]
|
291 | )
|
292 | }
|
293 | var staticRenderFns = []
|
294 | render._withStripped = true
|
295 |
|
296 |
|
297 |
|
298 |
|
299 |
|
300 | var emitter_ = __webpack_require__(4);
|
301 | var emitter_default = __webpack_require__.n(emitter_);
|
302 |
|
303 |
|
304 |
|
305 |
|
306 |
|
307 |
|
308 |
|
309 |
|
310 |
|
311 |
|
312 |
|
313 |
|
314 |
|
315 |
|
316 |
|
317 |
|
318 |
|
319 |
|
320 |
|
321 |
|
322 |
|
323 |
|
324 |
|
325 |
|
326 |
|
327 |
|
328 |
|
329 |
|
330 |
|
331 |
|
332 |
|
333 |
|
334 |
|
335 |
|
336 |
|
337 |
|
338 |
|
339 |
|
340 |
|
341 |
|
342 |
|
343 | var radio_buttonvue_type_script_lang_js_ = ({
|
344 | name: 'ElRadioButton',
|
345 |
|
346 | mixins: [emitter_default.a],
|
347 |
|
348 | inject: {
|
349 | elForm: {
|
350 | default: ''
|
351 | },
|
352 | elFormItem: {
|
353 | default: ''
|
354 | }
|
355 | },
|
356 |
|
357 | props: {
|
358 | label: {},
|
359 | disabled: Boolean,
|
360 | name: String
|
361 | },
|
362 | data: function data() {
|
363 | return {
|
364 | focus: false
|
365 | };
|
366 | },
|
367 |
|
368 | computed: {
|
369 | value: {
|
370 | get: function get() {
|
371 | return this._radioGroup.value;
|
372 | },
|
373 | set: function set(value) {
|
374 | this._radioGroup.$emit('input', value);
|
375 | }
|
376 | },
|
377 | _radioGroup: function _radioGroup() {
|
378 | var parent = this.$parent;
|
379 | while (parent) {
|
380 | if (parent.$options.componentName !== 'ElRadioGroup') {
|
381 | parent = parent.$parent;
|
382 | } else {
|
383 | return parent;
|
384 | }
|
385 | }
|
386 | return false;
|
387 | },
|
388 | activeStyle: function activeStyle() {
|
389 | return {
|
390 | backgroundColor: this._radioGroup.fill || '',
|
391 | borderColor: this._radioGroup.fill || '',
|
392 | boxShadow: this._radioGroup.fill ? '-1px 0 0 0 ' + this._radioGroup.fill : '',
|
393 | color: this._radioGroup.textColor || ''
|
394 | };
|
395 | },
|
396 | _elFormItemSize: function _elFormItemSize() {
|
397 | return (this.elFormItem || {}).elFormItemSize;
|
398 | },
|
399 | size: function size() {
|
400 | return this._radioGroup.radioGroupSize || this._elFormItemSize || (this.$ELEMENT || {}).size;
|
401 | },
|
402 | isDisabled: function isDisabled() {
|
403 | return this.disabled || this._radioGroup.disabled || (this.elForm || {}).disabled;
|
404 | },
|
405 | tabIndex: function tabIndex() {
|
406 | return this.isDisabled || this._radioGroup && this.value !== this.label ? -1 : 0;
|
407 | }
|
408 | },
|
409 |
|
410 | methods: {
|
411 | handleChange: function handleChange() {
|
412 | var _this = this;
|
413 |
|
414 | this.$nextTick(function () {
|
415 | _this.dispatch('ElRadioGroup', 'handleChange', _this.value);
|
416 | });
|
417 | }
|
418 | }
|
419 | });
|
420 |
|
421 | var src_radio_buttonvue_type_script_lang_js_ = (radio_buttonvue_type_script_lang_js_);
|
422 |
|
423 | var componentNormalizer = __webpack_require__(0);
|
424 |
|
425 |
|
426 |
|
427 |
|
428 |
|
429 |
|
430 |
|
431 |
|
432 |
|
433 | var component = Object(componentNormalizer["a" ])(
|
434 | src_radio_buttonvue_type_script_lang_js_,
|
435 | render,
|
436 | staticRenderFns,
|
437 | false,
|
438 | null,
|
439 | null,
|
440 | null
|
441 |
|
442 | )
|
443 |
|
444 |
|
445 | if (false) { var api; }
|
446 | component.options.__file = "packages/radio/src/radio-button.vue"
|
447 | var radio_button = (component.exports);
|
448 |
|
449 |
|
450 |
|
451 |
|
452 | radio_button.install = function (Vue) {
|
453 | Vue.component(radio_button.name, radio_button);
|
454 | };
|
455 |
|
456 | var packages_radio_button = __webpack_exports__["default"] = (radio_button);
|
457 |
|
458 | })
|
459 |
|
460 | }); |
\ | No newline at end of file |