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, {
|
41 | configurable: false,
|
42 | enumerable: true,
|
43 | get: getter
|
44 | /******/ });
|
45 | /******/ }
|
46 | /******/ };
|
47 | /******/
|
48 | /******/ // getDefaultExport function for compatibility with non-harmony modules
|
49 | /******/ __webpack_require__.n = function(module) {
|
50 | var getter = module && module.__esModule ?
|
51 | function getDefault() { return module['default']; } :
|
52 | function getModuleExports() { return module; };
|
53 | __webpack_require__.d(getter, 'a', getter);
|
54 | return getter;
|
55 | };
|
56 |
|
57 |
|
58 | __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
59 |
|
60 |
|
61 | __webpack_require__.p = "/dist/";
|
62 |
|
63 |
|
64 | return __webpack_require__(__webpack_require__.s = 299);
|
65 | })
|
66 |
|
67 | ({
|
68 |
|
69 | 0:
|
70 | (function(module, exports) {
|
71 |
|
72 |
|
73 |
|
74 |
|
75 |
|
76 |
|
77 |
|
78 | module.exports = function normalizeComponent (
|
79 | rawScriptExports,
|
80 | compiledTemplate,
|
81 | functionalTemplate,
|
82 | injectStyles,
|
83 | scopeId,
|
84 | moduleIdentifier /* server only */
|
85 | ) {
|
86 | var esModule
|
87 | var scriptExports = rawScriptExports = rawScriptExports || {}
|
88 |
|
89 |
|
90 | var type = typeof rawScriptExports.default
|
91 | if (type === 'object' || type === 'function') {
|
92 | esModule = rawScriptExports
|
93 | scriptExports = rawScriptExports.default
|
94 | }
|
95 |
|
96 |
|
97 | var options = typeof scriptExports === 'function'
|
98 | ? scriptExports.options
|
99 | : scriptExports
|
100 |
|
101 |
|
102 | if (compiledTemplate) {
|
103 | options.render = compiledTemplate.render
|
104 | options.staticRenderFns = compiledTemplate.staticRenderFns
|
105 | options._compiled = true
|
106 | }
|
107 |
|
108 |
|
109 | if (functionalTemplate) {
|
110 | options.functional = true
|
111 | }
|
112 |
|
113 |
|
114 | if (scopeId) {
|
115 | options._scopeId = scopeId
|
116 | }
|
117 |
|
118 | var hook
|
119 | if (moduleIdentifier) {
|
120 | hook = function (context) {
|
121 |
|
122 | context =
|
123 | context ||
|
124 | (this.$vnode && this.$vnode.ssrContext) ||
|
125 | (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext)
|
126 |
|
127 | if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
|
128 | context = __VUE_SSR_CONTEXT__
|
129 | }
|
130 |
|
131 | if (injectStyles) {
|
132 | injectStyles.call(this, context)
|
133 | }
|
134 |
|
135 | if (context && context._registeredComponents) {
|
136 | context._registeredComponents.add(moduleIdentifier)
|
137 | }
|
138 | }
|
139 |
|
140 |
|
141 | options._ssrRegister = hook
|
142 | } else if (injectStyles) {
|
143 | hook = injectStyles
|
144 | }
|
145 |
|
146 | if (hook) {
|
147 | var functional = options.functional
|
148 | var existing = functional
|
149 | ? options.render
|
150 | : options.beforeCreate
|
151 |
|
152 | if (!functional) {
|
153 |
|
154 | options.beforeCreate = existing
|
155 | ? [].concat(existing, hook)
|
156 | : [hook]
|
157 | } else {
|
158 |
|
159 |
|
160 | options._injectStyles = hook
|
161 |
|
162 | options.render = function renderWithStyleInjection (h, context) {
|
163 | hook.call(context)
|
164 | return existing(h, context)
|
165 | }
|
166 | }
|
167 | }
|
168 |
|
169 | return {
|
170 | esModule: esModule,
|
171 | exports: scriptExports,
|
172 | options: options
|
173 | }
|
174 | }
|
175 |
|
176 |
|
177 | }),
|
178 |
|
179 | 299:
|
180 | (function(module, exports, __webpack_require__) {
|
181 |
|
182 | "use strict";
|
183 |
|
184 |
|
185 | exports.__esModule = true;
|
186 |
|
187 | var _progress = __webpack_require__(300);
|
188 |
|
189 | var _progress2 = _interopRequireDefault(_progress);
|
190 |
|
191 | function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
192 |
|
193 |
|
194 | _progress2.default.install = function (Vue) {
|
195 | Vue.component(_progress2.default.name, _progress2.default);
|
196 | };
|
197 |
|
198 | exports.default = _progress2.default;
|
199 |
|
200 | }),
|
201 |
|
202 | 300:
|
203 | (function(module, __webpack_exports__, __webpack_require__) {
|
204 |
|
205 | "use strict";
|
206 | Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
|
207 | var __WEBPACK_IMPORTED_MODULE_0__babel_loader_node_modules_vue_loader_lib_selector_type_script_index_0_progress_vue__ = __webpack_require__(301);
|
208 | var __WEBPACK_IMPORTED_MODULE_0__babel_loader_node_modules_vue_loader_lib_selector_type_script_index_0_progress_vue___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__babel_loader_node_modules_vue_loader_lib_selector_type_script_index_0_progress_vue__);
|
209 | var __WEBPACK_IMPORTED_MODULE_1__node_modules_vue_loader_lib_template_compiler_index_id_data_v_605ce16e_hasScoped_false_preserveWhitespace_false_buble_transforms_node_modules_vue_loader_lib_selector_type_template_index_0_progress_vue__ = __webpack_require__(302);
|
210 | var normalizeComponent = __webpack_require__(0)
|
211 |
|
212 |
|
213 |
|
214 |
|
215 |
|
216 | var __vue_template_functional__ = false
|
217 |
|
218 | var __vue_styles__ = null
|
219 |
|
220 | var __vue_scopeId__ = null
|
221 |
|
222 | var __vue_module_identifier__ = null
|
223 | var Component = normalizeComponent(
|
224 | __WEBPACK_IMPORTED_MODULE_0__babel_loader_node_modules_vue_loader_lib_selector_type_script_index_0_progress_vue___default.a,
|
225 | __WEBPACK_IMPORTED_MODULE_1__node_modules_vue_loader_lib_template_compiler_index_id_data_v_605ce16e_hasScoped_false_preserveWhitespace_false_buble_transforms_node_modules_vue_loader_lib_selector_type_template_index_0_progress_vue__["a" ],
|
226 | __vue_template_functional__,
|
227 | __vue_styles__,
|
228 | __vue_scopeId__,
|
229 | __vue_module_identifier__
|
230 | )
|
231 |
|
232 | __webpack_exports__["default"] = (Component.exports);
|
233 |
|
234 |
|
235 | }),
|
236 |
|
237 | 301:
|
238 | (function(module, exports, __webpack_require__) {
|
239 |
|
240 | "use strict";
|
241 |
|
242 |
|
243 | exports.__esModule = true;
|
244 |
|
245 |
|
246 |
|
247 |
|
248 |
|
249 |
|
250 |
|
251 |
|
252 |
|
253 |
|
254 |
|
255 |
|
256 |
|
257 |
|
258 |
|
259 |
|
260 |
|
261 |
|
262 |
|
263 |
|
264 |
|
265 |
|
266 |
|
267 |
|
268 |
|
269 |
|
270 |
|
271 |
|
272 |
|
273 |
|
274 |
|
275 |
|
276 |
|
277 |
|
278 |
|
279 |
|
280 |
|
281 |
|
282 |
|
283 |
|
284 | exports.default = {
|
285 | name: 'ElProgress',
|
286 | props: {
|
287 | type: {
|
288 | type: String,
|
289 | default: 'line',
|
290 | validator: function validator(val) {
|
291 | return ['line', 'circle'].indexOf(val) > -1;
|
292 | }
|
293 | },
|
294 | percentage: {
|
295 | type: Number,
|
296 | default: 0,
|
297 | required: true,
|
298 | validator: function validator(val) {
|
299 | return val >= 0 && val <= 100;
|
300 | }
|
301 | },
|
302 | status: {
|
303 | type: String
|
304 | },
|
305 | strokeWidth: {
|
306 | type: Number,
|
307 | default: 6
|
308 | },
|
309 | textInside: {
|
310 | type: Boolean,
|
311 | default: false
|
312 | },
|
313 | width: {
|
314 | type: Number,
|
315 | default: 126
|
316 | },
|
317 | showText: {
|
318 | type: Boolean,
|
319 | default: true
|
320 | },
|
321 | color: {
|
322 | type: String,
|
323 | default: ''
|
324 | }
|
325 | },
|
326 | computed: {
|
327 | barStyle: function barStyle() {
|
328 | var style = {};
|
329 | style.width = this.percentage + '%';
|
330 | style.backgroundColor = this.color;
|
331 | return style;
|
332 | },
|
333 | relativeStrokeWidth: function relativeStrokeWidth() {
|
334 | return (this.strokeWidth / this.width * 100).toFixed(1);
|
335 | },
|
336 | trackPath: function trackPath() {
|
337 | var radius = parseInt(50 - parseFloat(this.relativeStrokeWidth) / 2, 10);
|
338 |
|
339 | return 'M 50 50 m 0 -' + radius + ' a ' + radius + ' ' + radius + ' 0 1 1 0 ' + radius * 2 + ' a ' + radius + ' ' + radius + ' 0 1 1 0 -' + radius * 2;
|
340 | },
|
341 | perimeter: function perimeter() {
|
342 | var radius = 50 - parseFloat(this.relativeStrokeWidth) / 2;
|
343 | return 2 * Math.PI * radius;
|
344 | },
|
345 | circlePathStyle: function circlePathStyle() {
|
346 | var perimeter = this.perimeter;
|
347 | return {
|
348 | strokeDasharray: perimeter + 'px,' + perimeter + 'px',
|
349 | strokeDashoffset: (1 - this.percentage / 100) * perimeter + 'px',
|
350 | transition: 'stroke-dashoffset 0.6s ease 0s, stroke 0.6s ease'
|
351 | };
|
352 | },
|
353 | stroke: function stroke() {
|
354 | var ret = void 0;
|
355 | if (this.color) {
|
356 | ret = this.color;
|
357 | } else {
|
358 | switch (this.status) {
|
359 | case 'success':
|
360 | ret = '#13ce66';
|
361 | break;
|
362 | case 'exception':
|
363 | ret = '#ff4949';
|
364 | break;
|
365 | default:
|
366 | ret = '#20a0ff';
|
367 | }
|
368 | }
|
369 | return ret;
|
370 | },
|
371 | iconClass: function iconClass() {
|
372 | if (this.type === 'line') {
|
373 | return this.status === 'success' ? 'el-icon-circle-check' : 'el-icon-circle-close';
|
374 | } else {
|
375 | return this.status === 'success' ? 'el-icon-check' : 'el-icon-close';
|
376 | }
|
377 | },
|
378 | progressTextSize: function progressTextSize() {
|
379 | return this.type === 'line' ? 12 + this.strokeWidth * 0.4 : this.width * 0.111111 + 2;
|
380 | }
|
381 | }
|
382 | };
|
383 |
|
384 | }),
|
385 |
|
386 | 302:
|
387 | (function(module, __webpack_exports__, __webpack_require__) {
|
388 |
|
389 | "use strict";
|
390 | var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"el-progress",class:[
|
391 | 'el-progress--' + _vm.type,
|
392 | _vm.status ? 'is-' + _vm.status : '',
|
393 | {
|
394 | 'el-progress--without-text': !_vm.showText,
|
395 | 'el-progress--text-inside': _vm.textInside,
|
396 | }
|
397 | ],attrs:{"role":"progressbar","aria-valuenow":_vm.percentage,"aria-valuemin":"0","aria-valuemax":"100"}},[(_vm.type === 'line')?_c('div',{staticClass:"el-progress-bar"},[_c('div',{staticClass:"el-progress-bar__outer",style:({height: _vm.strokeWidth + 'px'})},[_c('div',{staticClass:"el-progress-bar__inner",style:(_vm.barStyle)},[(_vm.showText && _vm.textInside)?_c('div',{staticClass:"el-progress-bar__innerText"},[_vm._v(_vm._s(_vm.percentage)+"%")]):_vm._e()])])]):_c('div',{staticClass:"el-progress-circle",style:({height: _vm.width + 'px', width: _vm.width + 'px'})},[_c('svg',{attrs:{"viewBox":"0 0 100 100"}},[_c('path',{staticClass:"el-progress-circle__track",attrs:{"d":_vm.trackPath,"stroke":"#e5e9f2","stroke-width":_vm.relativeStrokeWidth,"fill":"none"}}),_c('path',{staticClass:"el-progress-circle__path",style:(_vm.circlePathStyle),attrs:{"d":_vm.trackPath,"stroke-linecap":"round","stroke":_vm.stroke,"stroke-width":_vm.relativeStrokeWidth,"fill":"none"}})])]),(_vm.showText && !_vm.textInside)?_c('div',{staticClass:"el-progress__text",style:({fontSize: _vm.progressTextSize + 'px'})},[(!_vm.status)?[_vm._v(_vm._s(_vm.percentage)+"%")]:_c('i',{class:_vm.iconClass})],2):_vm._e()])}
|
398 | var staticRenderFns = []
|
399 | var esExports = { render: render, staticRenderFns: staticRenderFns }
|
400 | __webpack_exports__["a"] = (esExports);
|
401 |
|
402 | })
|
403 |
|
404 | }); |
\ | No newline at end of file |