weex-flymeui
Version:
A Flyme Style UI library based on Weex for Creator.
2,007 lines (1,781 loc) • 471 kB
JavaScript
// { "framework": "Vue" }
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory();
else if(typeof define === 'function' && define.amd)
define([], factory);
else if(typeof exports === 'object')
exports["npm/weex-flymeui/index"] = factory();
else
root["npm/weex-flymeui/index"] = factory();
})(typeof self !== 'undefined' ? self : this, function() {
return /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId]) {
/******/ return installedModules[moduleId].exports;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.l = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/******/
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/
/******/ // define getter function for harmony exports
/******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if(!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, {
/******/ configurable: false,
/******/ enumerable: true,
/******/ get: getter
/******/ });
/******/ }
/******/ };
/******/
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ function getDefault() { return module['default']; } :
/******/ function getModuleExports() { return module; };
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/ };
/******/
/******/ // Object.prototype.hasOwnProperty.call
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "/";
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = 234);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = __webpack_require__(4);
Object.defineProperty(exports, 'default', {
enumerable: true,
get: function get() {
return _interopRequireDefault(_index).default;
}
});
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/***/ }),
/* 1 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = __webpack_require__(21);
Object.defineProperty(exports, 'default', {
enumerable: true,
get: function get() {
return _interopRequireDefault(_index).default;
}
});
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/***/ }),
/* 2 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = __webpack_require__(8);
Object.defineProperty(exports, 'default', {
enumerable: true,
get: function get() {
return _interopRequireDefault(_index).default;
}
});
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/***/ }),
/* 3 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.use = exports.t = undefined;
var _zhCN = __webpack_require__(31);
var _zhCN2 = _interopRequireDefault(_zhCN);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
var lang = _zhCN2.default;
var t = exports.t = function t(path, options) {
var value = void 0;
var array = path.split('.');
var current = lang;
for (var i = 0, j = array.length; i < j; i++) {
var property = array[i];
value = current[property];
if (i === j - 1) return value;
if (!value) return '';
current = value;
}
return '';
};
var use = exports.use = function use(l) {
lang = l || lang;
};
exports.default = { t: t, use: use };
/***/ }),
/* 4 */
/***/ (function(module, exports, __webpack_require__) {
var __vue_exports__, __vue_options__
var __vue_styles__ = []
/* styles */
__vue_styles__.push(__webpack_require__(5)
)
/* script */
__vue_exports__ = __webpack_require__(6)
/* template */
var __vue_template__ = __webpack_require__(7)
__vue_options__ = __vue_exports__ = __vue_exports__ || {}
if (
typeof __vue_exports__.default === "object" ||
typeof __vue_exports__.default === "function"
) {
if (Object.keys(__vue_exports__).some(function (key) { return key !== "default" && key !== "__esModule" })) {console.error("named exports are not supported in *.vue files.")}
__vue_options__ = __vue_exports__ = __vue_exports__.default
}
if (typeof __vue_options__ === "function") {
__vue_options__ = __vue_options__.options
}
__vue_options__.__file = "/Users/suen/Documents/develop/project/weex-flymeui/packages/fm-text/index.vue"
__vue_options__.render = __vue_template__.render
__vue_options__.staticRenderFns = __vue_template__.staticRenderFns
__vue_options__._scopeId = "data-v-5cfa2da2"
__vue_options__.style = __vue_options__.style || {}
__vue_styles__.forEach(function (module) {
for (var name in module) {
__vue_options__.style[name] = module[name]
}
})
if (typeof __register_static_styles__ === "function") {
__register_static_styles__(__vue_options__._scopeId, __vue_styles__)
}
module.exports = __vue_exports__
/***/ }),
/* 5 */
/***/ (function(module, exports) {
module.exports = {
"text": {
"fontSize": "42",
"lineHeight": "63",
"color": "#999999",
"fontFamily": "\"Source Han Sans CN\", Roboto, sans-serif"
},
"medium": {
"fontFamily": "sans-serif-medium",
"fontWeight": "500"
},
"bold": {
"fontWeight": "700"
},
"light": {
"fontWeight": "400"
},
"small": {
"fontSize": "36"
},
"large": {
"fontSize": "48",
"fontWeight": "500",
"lineHeight": "72",
"color": "#000000"
},
"huge": {
"fontSize": "54",
"lineHeight": "81",
"color": "#000000"
},
"margin-text": {
"marginRight": "9"
}
}
/***/ }),
/* 6 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
exports.default = {
name: 'FmText',
props: {
value: String,
fontWeight: {
type: String,
default: 'normal'
},
size: {
type: String,
default: 'normal'
},
textStyle: {
type: Object,
default: function _default() {
return {};
}
},
hasTextMargin: {
type: Boolean,
default: true
}
},
data: function data() {
return {
inValue: ''
};
},
watch: {
value: function value(val) {
this.inValue = val;
}
},
computed: {
textClz: function textClz() {
var clz = ['text'];
if (this.hasTextMargin) {
clz.push('margin-text');
}
if (this.size !== 'normal') {
clz.push('' + this.size);
}
if (this.fontWeight !== 'normal') {
clz.push('' + this.fontWeight);
}
return clz;
}
},
created: function created() {
this.value && (this.inValue = this.value);
this.$slots.default && (this.inValue = this.$slots.default[0].text);
}
};
/***/ }),
/* 7 */
/***/ (function(module, exports) {
module.exports={render:function (){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;
return _c('text', {
class: _vm.textClz,
style: _vm.textStyle
}, [_vm._t("default"), (!_vm.$slots.default) ? [_vm._v(_vm._s(_vm.inValue))] : _vm._e()], 2)
},staticRenderFns: []}
module.exports.render._withStripped = true
/***/ }),
/* 8 */
/***/ (function(module, exports, __webpack_require__) {
var __vue_exports__, __vue_options__
var __vue_styles__ = []
/* script */
__vue_exports__ = __webpack_require__(9)
/* template */
var __vue_template__ = __webpack_require__(10)
__vue_options__ = __vue_exports__ = __vue_exports__ || {}
if (
typeof __vue_exports__.default === "object" ||
typeof __vue_exports__.default === "function"
) {
if (Object.keys(__vue_exports__).some(function (key) { return key !== "default" && key !== "__esModule" })) {console.error("named exports are not supported in *.vue files.")}
__vue_options__ = __vue_exports__ = __vue_exports__.default
}
if (typeof __vue_options__ === "function") {
__vue_options__ = __vue_options__.options
}
__vue_options__.__file = "/Users/suen/Documents/develop/project/weex-flymeui/packages/fm-image/index.vue"
__vue_options__.render = __vue_template__.render
__vue_options__.staticRenderFns = __vue_template__.staticRenderFns
__vue_options__.style = __vue_options__.style || {}
__vue_styles__.forEach(function (module) {
for (var name in module) {
__vue_options__.style[name] = module[name]
}
})
if (typeof __register_static_styles__ === "function") {
__register_static_styles__(__vue_options__._scopeId, __vue_styles__)
}
module.exports = __vue_exports__
/***/ }),
/* 9 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
//
//
//
//
//
//
exports.default = {
name: 'FmImage',
data: function data() {
return {
loaded: false
};
},
props: {
src: {
type: String,
default: ''
},
scale: {
type: Number,
default: 0
},
width: {
type: Number,
default: 1
},
height: {
type: Number,
default: 1
},
occupyingColor: {
type: String,
default: 'transparent'
},
imgStyle: {
type: Object
}
},
computed: {
getStyle: function getStyle() {
return _extends({
width: this.width + 'px',
height: this.height + 'px',
backgroundColor: this.loaded ? 'transparent' : this.occupyingColor
}, this.imgStyle);
}
},
methods: {
onLoad: function onLoad(e) {
this.$emit('fmImageLoaded', e);
e.success && (this.loaded = true);
if (e.success && e.size && e.size.naturalWidth > 0 && this.scale) {
this.width = e.size.naturalWidth * this.scale;
this.height = e.size.naturalHeight * this.scale;
}
}
}
};
/***/ }),
/* 10 */
/***/ (function(module, exports) {
module.exports={render:function (){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;
return _c('image', {
ref: "img",
style: _vm.getStyle,
attrs: {
"src": _vm.src
},
on: {
"load": _vm.onLoad
}
})
},staticRenderFns: []}
module.exports.render._withStripped = true
/***/ }),
/* 11 */,
/* 12 */,
/* 13 */,
/* 14 */,
/* 15 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = {
biaoqing: '',
bofang: '',
bianji: '',
bofang2: '',
cebianlan: '',
caijian: '',
chakan: '',
chexiao: '',
chuangkouhua: '',
daojishi: '',
dianzan: '',
chuangkouhua2: '',
dianhua: '',
diannao: '',
dingwei2: '',
dingwei: '',
dingyue: '',
erweima: '',
fanhui: '',
fasong: '',
fujian: '',
fenlei: '',
fanhui2: 'ູ',
fenxiang: '',
fuzhi: '',
gengduo: '',
gouwuche: '',
gongjuxiang: '',
gengduo2: '',
guanbi: '',
jishi: '',
hongxin: '',
jingyin: '',
jianpan: '',
jiesuo: '',
jisuanqi: '󦰶',
liangdu: '',
lvjing: '',
paixu: '',
paihang: '',
paizhao: '',
pingmutoushe: '',
riqi: '',
shanchu: '',
shangchaun: '',
shangyishou: '',
shezhi: '',
shizhong: '',
shezhi1: '',
sousuo: '',
shuqian: '',
shuoming: '',
shuaxin: '',
suoding: '',
shipin: '',
tuichu: '',
tupian: '',
tianjia: '',
tixing: '',
wancheng: '',
wengao: '',
xiayishou: '',
xinxi: '',
xiazai: '',
xingxing: '',
xinxi1: '',
xuanxiangliebiao: '',
yidu: '',
yinliang: '',
yinbi: '',
yuyin: '',
zanting: '',
yonghu: '',
youjian: '',
zhiding: '',
chongzuo: '',
zhuye: '',
ziti: '',
VPN: '',
'Wi-Fi': '',
zhuti: '',
lanya: '',
quanping: '',
pingmufanzhuan: '',
gouwu: '',
saomiao: ''
};
/***/ }),
/* 16 */,
/* 17 */,
/* 18 */,
/* 19 */,
/* 20 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
/**
* CopyRight (C) 2017-2022 Alibaba Group Holding Limited.
* Created by Yanjiie on 18/04/01
*/
exports.default = {
primaryColor: '#198DED',
disabledColor: '#BDE2FB',
highlightColor: '#156DC9',
lightColor: '#42A2F1',
weakColor: '#E6F8FF',
grayColor: '#F2F3F4',
fontColorLight: '#FFFFFF',
fontColorDark: '#3D3D3D',
fontColorGray: '#F2F3F4'
};
/***/ }),
/* 21 */
/***/ (function(module, exports, __webpack_require__) {
var __vue_exports__, __vue_options__
var __vue_styles__ = []
/* styles */
__vue_styles__.push(__webpack_require__(22)
)
/* script */
__vue_exports__ = __webpack_require__(23)
/* template */
var __vue_template__ = __webpack_require__(24)
__vue_options__ = __vue_exports__ = __vue_exports__ || {}
if (
typeof __vue_exports__.default === "object" ||
typeof __vue_exports__.default === "function"
) {
if (Object.keys(__vue_exports__).some(function (key) { return key !== "default" && key !== "__esModule" })) {console.error("named exports are not supported in *.vue files.")}
__vue_options__ = __vue_exports__ = __vue_exports__.default
}
if (typeof __vue_options__ === "function") {
__vue_options__ = __vue_options__.options
}
__vue_options__.__file = "/Users/suen/Documents/develop/project/weex-flymeui/packages/fm-icon/index.vue"
__vue_options__.render = __vue_template__.render
__vue_options__.staticRenderFns = __vue_template__.staticRenderFns
__vue_options__._scopeId = "data-v-08d175ee"
__vue_options__.style = __vue_options__.style || {}
__vue_styles__.forEach(function (module) {
for (var name in module) {
__vue_options__.style[name] = module[name]
}
})
if (typeof __register_static_styles__ === "function") {
__register_static_styles__(__vue_options__._scopeId, __vue_styles__)
}
module.exports = __vue_exports__
/***/ }),
/* 22 */
/***/ (function(module, exports) {
module.exports = {}
/***/ }),
/* 23 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; //
//
//
//
//
//
//
//
//
var _map = __webpack_require__(15);
var _map2 = _interopRequireDefault(_map);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
var dom = weex.requireModule('dom');
exports.default = {
name: 'FmIcon',
props: {
name: {
default: 'wancheng',
type: String
},
value: {
type: String,
default: ''
},
iconStyle: {
type: [Number, Object, String],
default: 42
},
color: {
type: String,
default: '#666666'
}
},
data: function data() {
return {
Icon: _map2.default
};
},
computed: {
getIcon: function getIcon() {
var Icon = this.Icon,
name = this.name,
value = this.value;
return decode(value === '' ? Icon[name] || 'wancheng' : value);
},
mergeStyle: function mergeStyle() {
var iconStyle = this.iconStyle;
var style = { fontFamily: 'flymeicon', color: this.color };
if (Object.prototype.toString.call(this.iconStyle).slice(8, -1).toLowerCase() !== 'object') {
style.fontSize = iconStyle + 'px';
style.height = iconStyle + 'px';
} else {
style = Object.assign({}, style, _extends({}, iconStyle));
}
return style;
}
},
beforeCreate: function beforeCreate() {
if (!this.isCreator) {
dom.addRule('fontFace', {
'fontFamily': 'flymeicon',
'src': "url('http://weixin-res.flyme.cn/resources/weex-flymeui/assets/iconfont.ttf')"
});
}
},
methods: {
itemClicked: function itemClicked(name) {
this.$emit('fmIconClicked', {
name: name
});
}
}
};
var reg = /&([^;]{2,});?/g;
var decode = function decode(html) {
html = html.replace(reg, function (match, entity) {
if (entity.charAt(0) === '#') {
var num = 0;
if (entity.charAt(1).toLowerCase() === 'x') {
num = parseInt(entity.slice(2), 16);
} else {
num = parseInt(entity.slice(1), 10);
}
if (!isNaN(num) && num >= -32768 && num <= 65535) {
return String.fromCharCode(num);
}
}
return match;
});
return html;
};
/***/ }),
/* 24 */
/***/ (function(module, exports) {
module.exports={render:function (){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;
return _c('text', {
style: _vm.mergeStyle,
on: {
"click": function($event) {
_vm.itemClicked(_vm.name)
}
}
}, [_vm._v(_vm._s(_vm.getIcon))])
},staticRenderFns: []}
module.exports.render._withStripped = true
/***/ }),
/* 25 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _locale = __webpack_require__(3);
exports.default = {
methods: {
t: function t() {
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key];
}
return _locale.t.apply(this, args);
}
}
};
/***/ }),
/* 26 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = __webpack_require__(27);
Object.defineProperty(exports, 'default', {
enumerable: true,
get: function get() {
return _interopRequireDefault(_index).default;
}
});
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/***/ }),
/* 27 */
/***/ (function(module, exports, __webpack_require__) {
var __vue_exports__, __vue_options__
var __vue_styles__ = []
/* styles */
__vue_styles__.push(__webpack_require__(28)
)
/* script */
__vue_exports__ = __webpack_require__(29)
/* template */
var __vue_template__ = __webpack_require__(30)
__vue_options__ = __vue_exports__ = __vue_exports__ || {}
if (
typeof __vue_exports__.default === "object" ||
typeof __vue_exports__.default === "function"
) {
if (Object.keys(__vue_exports__).some(function (key) { return key !== "default" && key !== "__esModule" })) {console.error("named exports are not supported in *.vue files.")}
__vue_options__ = __vue_exports__ = __vue_exports__.default
}
if (typeof __vue_options__ === "function") {
__vue_options__ = __vue_options__.options
}
__vue_options__.__file = "/Users/suen/Documents/develop/project/weex-flymeui/packages/fm-button/index.vue"
__vue_options__.render = __vue_template__.render
__vue_options__.staticRenderFns = __vue_template__.staticRenderFns
__vue_options__._scopeId = "data-v-7fe7e232"
__vue_options__.style = __vue_options__.style || {}
__vue_styles__.forEach(function (module) {
for (var name in module) {
__vue_options__.style[name] = module[name]
}
})
if (typeof __register_static_styles__ === "function") {
__register_static_styles__(__vue_options__._scopeId, __vue_styles__)
}
module.exports = __vue_exports__
/***/ }),
/* 28 */
/***/ (function(module, exports) {
module.exports = {
"fm-button": {
"flexDirection": "row",
"alignItems": "center",
"justifyContent": "center",
"overflow": "hidden",
"transform": "scale(1)",
"transitionProperty": "transform,backgroundColor",
"transitionDuration": 200,
"transitionTimingFunction": "cubic-bezier(0.215,0.61,0.355,1)"
},
"@TRANSITION": {
"fm-button": {
"property": "transform,backgroundColor",
"duration": 200,
"timingFunction": "cubic-bezier(0.215,0.61,0.355,1)"
}
},
"fm-button-hollow": {
"borderWidth": "4"
},
"button-text": {
"flex": 1,
"textAlign": "center",
"color": "#FFFFFF",
"fontWeight": "500",
"fontFamily": "sans-serif-medium"
},
"fm-button-small": {
"height": "72",
"borderRadius": "36"
},
"fm-button-middle": {
"width": "312",
"height": "114",
"borderRadius": "57"
},
"fm-button-large": {
"width": "396",
"height": "114",
"borderRadius": "57"
},
"fm-button-circle": {
"width": "168",
"height": "168",
"borderRadius": "84"
},
"fm-button-huge": {
"width": "720",
"height": "114",
"borderRadius": "57"
},
"button-text-small": {
"fontSize": "36"
},
"button-text-middle": {
"fontSize": "48"
},
"button-text-large": {
"fontSize": "48"
},
"button-text-huge": {
"fontSize": "48"
},
"overlay": {
"position": "absolute",
"top": 0,
"left": 0,
"right": 0,
"bottom": 0,
"zIndex": 30,
"borderRadius": "200",
"backgroundColor:active": "rgba(0,0,0,0.1)"
}
}
/***/ }),
/* 29 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = __webpack_require__(20);
var _index2 = _interopRequireDefault(_index);
var _fmIcon = __webpack_require__(1);
var _fmIcon2 = _interopRequireDefault(_fmIcon);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
var dom = weex.requireModule('dom');
exports.default = {
name: 'FmButton',
components: { FmIcon: _fmIcon2.default },
props: {
size: {
type: String,
default: 'small'
},
type: String,
color: {
type: String,
default: _index2.default.primaryColor
},
titleColor: {
type: String,
default: '#FFFFFF'
},
titleSize: {
type: Number,
default: 0
},
icon: {
type: String,
default: 'wancheng'
},
width: Number,
height: Number,
animated: Boolean,
disabled: Boolean,
title: String
},
data: function data() {
return {
active: false,
padding: 36
};
},
computed: {
buttonClass: function buttonClass() {
var clz = [];
this.size && clz.push('fm-button-' + this.size);
this.type && clz.push('fm-button-' + this.type);
return clz;
},
computedColor: function computedColor() {
return this.color || _index2.default.primaryColor;
},
computedStyle: function computedStyle() {
var color = this.color,
active = this.active,
disabled = this.disabled,
padding = this.padding,
animated = this.animated,
type = this.type,
width = this.width,
height = this.height;
var transform = !animated || disabled ? 'scale(1)' : 'scale(' + (active ? 0.95 : 1) + ')';
var style = {
borderColor: type === 'hollow' ? color : '',
backgroundColor: type !== 'hollow' ? color : '',
opacity: disabled ? 0.2 : 1,
transform: transform,
paddingLeft: padding + 'px',
paddingRight: padding + 'px'
};
if (type !== 'circle') {
width && (style.width = width + 'px');
height && (style.height = height + 'px') && (style.borderRadius = Math.ceil(height * 1000 / 2000) + 'px');
}
return style;
}
},
methods: {
btnClick: function btnClick(e) {
!this.disabled && this.$emit('buttonClicked', e);
},
_startHandle: function _startHandle(e) {
this.active = true;
},
_endHandle: function _endHandle(e) {
this.active = false;
}
},
mounted: function mounted() {
var _this = this;
this.$nextTick(function () {
dom.getComponentRect(_this.$refs['fm-button'], function (option) {
if (option.size.width >= 240) {
_this.padding = 24;
}
});
});
}
};
/***/ }),
/* 30 */
/***/ (function(module, exports) {
module.exports={render:function (){var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;
return _c('div', {
ref: "fm-button",
staticClass: ["fm-button"],
class: _vm.buttonClass,
style: _vm.computedStyle,
on: {
"click": _vm.btnClick,
"touchstart": _vm._startHandle,
"touchend": _vm._endHandle
}
}, [(!_vm.disabled) ? _c('div', {
staticClass: ["overlay"],
on: {
"click": _vm.btnClick
}
}) : _vm._e(), (_vm.type === 'circle') ? _c('fm-icon', {
attrs: {
"color": (_vm.type !== 'hollow') ? _vm.titleColor : _vm.color,
"name": _vm.icon,
"iconStyle": "72"
}
}) : _vm._t("title", [_c('text', {
staticClass: ["button-text"],
class: ['button-text-' + _vm.size],
style: Object.assign({}, {
color: (_vm.type !== 'hollow') ? _vm.titleColor : _vm.computedColor
}, (_vm.titleSize ? {
fontSize: _vm.titleSize
} : {}))
}, [_vm._t("default"), (!_vm.$slots.default) ? [_vm._v(_vm._s(_vm.title))] : _vm._e()], 2)])], 2)
},staticRenderFns: []}
module.exports.render._withStripped = true
/***/ }),
/* 31 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = {
el: {
common: {
delete: '删除',
cancel: '取消',
confirm: '确认',
close: '关闭',
title: '标题',
more: '更多'
},
titlebar: {
title: '标题'
},
searchbar: {
search: '搜索'
},
foldabletext: {
more: '更多'
},
input: {
placeholder: '请输入',
inputError: '输入有误'
},
tag: {
tagName: '标签'
}
}
};
/***/ }),
/* 32 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = __webpack_require__(37);
Object.defineProperty(exports, 'default', {
enumerable: true,
get: function get() {
return _interopRequireDefault(_index).default;
}
});
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/***/ }),
/* 33 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _typeof2 = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
/**
* Created by Yanjiie on 18/03/08. Fork from https://github.com/alibaba/weex-ui
*/
var Utils = {
_typeof: function _typeof(obj) {
return Object.prototype.toString.call(obj).slice(8, -1).toLowerCase();
},
isPlainObject: function isPlainObject(obj) {
return Utils._typeof(obj) === 'object';
},
isString: function isString(obj) {
return typeof obj === 'string';
},
isNonEmptyArray: function isNonEmptyArray() {
var obj = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
return obj && obj.length > 0 && Array.isArray(obj) && typeof obj !== 'undefined';
},
isObject: function isObject(item) {
return item && (typeof item === 'undefined' ? 'undefined' : _typeof2(item)) === 'object' && !Array.isArray(item);
},
isEmptyObject: function isEmptyObject(obj) {
return Object.keys(obj).length === 0 && obj.constructor === Object;
},
decodeIconFont: function decodeIconFont(text) {
// 正则匹配 图标和文字混排 eg: 我去上学校,天天不迟到
var regExp = /&#x[a-z|0-9]{4,5};?/g;
if (regExp.test(text)) {
return text.replace(new RegExp(regExp, 'g'), function (iconText) {
var replace = iconText.replace(/&#x/, '0x').replace(/;$/, '');
return String.fromCharCode(replace);
});
} else {
return text;
}
},
mergeDeep: function mergeDeep(target) {
for (var _len = arguments.length, sources = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
sources[_key - 1] = arguments[_key];
}
if (!sources.length) return target;
var source = sources.shift();
if (Utils.isObject(target) && Utils.isObject(source)) {
for (var key in source) {
if (Utils.isObject(source[key])) {
if (!target[key]) {
Object.assign(target, _defineProperty({}, key, {}));
}
Utils.mergeDeep(target[key], source[key]);
} else {
Object.assign(target, _defineProperty({}, key, source[key]));
}
}
}
return Utils.mergeDeep.apply(Utils, [target].concat(sources));
},
appendProtocol: function appendProtocol(url) {
if (/^\/\//.test(url)) {
var bundleUrl = weex.config.bundleUrl;
return 'http' + (/^https:/.test(bundleUrl) ? 's' : '') + ':' + url;
}
return url;
},
encodeURLParams: function encodeURLParams(url) {
var parsedUrl = new UrlParser(url, true);
return parsedUrl.toString();
},
goToH5Page: function goToH5Page(jumpUrl) {
var animated = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
var callback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
var Navigator = weex.requireModule('navigator');
var jumpUrlObj = new Utils.UrlParser(jumpUrl, true);
var url = Utils.appendProtocol(jumpUrlObj.toString());
Navigator.push({
url: Utils.encodeURLParams(url),
animated: animated.toString()
}, callback);
},
env: {
isWeb: function isWeb() {
var platform = weex.config.env.platform;
return (typeof window === 'undefined' ? 'undefined' : _typeof2(window)) === 'object' && platform.toLowerCase() === 'web';
},
isIOS: function isIOS() {
var platform = weex.config.env.platform;
return platform.toLowerCase() === 'ios';
},
/**
* 是否为 iPhone X
* @returns {boolean}
*/
isIPhoneX: function isIPhoneX() {
var deviceHeight = weex.config.env.deviceHeight;
if (Utils.env.isWeb()) {
return (typeof window === 'undefined' ? 'undefined' : _typeof2(window)) !== undefined && window.screen && window.screen.width && window.screen.height && parseInt(window.screen.width, 10) === 375 && parseInt(window.screen.height, 10) === 812;
}
return Utils.env.isIOS() && deviceHeight === 2436;
},
isAndroid: function isAndroid() {
var platform = weex.config.env.platform;
return platform.toLowerCase() === 'android';
},
/**
* 获取weex屏幕真实的设置高度,需要减去导航栏高度
* @returns {Number}
*/
getPageHeight: function getPageHeight() {
var env = weex.config.env;
var navHeight = Utils.env.isWeb() ? 0 : Utils.env.isIPhoneX() ? 176 : 132;
return env.deviceHeight / env.deviceWidth * 750 - navHeight;
},
/**
* 获取weex屏幕真实的设置高度
* @returns {Number}
*/
getScreenHeight: function getScreenHeight() {
var env = weex.config.env;
return env.deviceHeight / env.deviceWidth * 750;
}
},
/**
* 版本号比较
* @memberOf Utils
* @param currVer {string}
* @param promoteVer {string}
* @returns {boolean}
* @example
*
* const { Utils } = require('@ali/wx-bridge');
* const { compareVersion } = Utils;
* console.log(compareVersion('0.1.100', '0.1.11')); // 'true'
*/
compareVersion: function compareVersion() {
var currVer = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '0.0.0';
var promoteVer = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '0.0.0';
if (currVer === promoteVer) return true;
var currVerArr = currVer.split('.');
var promoteVerArr = promoteVer.split('.');
var len = Math.max(currVerArr.length, promoteVerArr.length);
for (var i = 0; i < len; i++) {
var proVal = ~~promoteVerArr[i];
var curVal = ~~currVerArr[i];
if (proVal < curVal) {
return true;
} else if (proVal > curVal) {
return false;
}
}
return false;
},
/**
* 分割数组
* @param arr 被分割数组
* @param size 分割数组的长度
* @returns {Array}
*/
arrayChunk: function arrayChunk() {
var arr = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
var size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 4;
var groups = [];
if (arr && arr.length > 0) {
groups = arr.map(function (e, i) {
return i % size === 0 ? arr.slice(i, i + size) : null;
}).filter(function (e) {
return e;
});
}
return groups;
},
truncateString: function truncateString(str, len) {
var hasDot = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
var newLength = 0;
var newStr = '';
var singleChar = '';
var chineseRegex = /[^\x00-\xff]/g;
var strLength = str.replace(chineseRegex, '**').length;
for (var i = 0; i < strLength; i++) {
singleChar = str.charAt(i).toString();
if (singleChar.match(chineseRegex) !== null) {
newLength += 2;
} else {
newLength++;
}
if (newLength > len) {
break;
}
newStr += singleChar;
}
if (hasDot && strLength > len) {
newStr += '...';
}
return newStr;
},
animation: {
/**
* 返回定义页面转场动画起初的位置
* @param ref
* @param transform 运动类型
* @param status
* @param callback 回调函数
*/
pageTransitionAnimation: function pageTransitionAnimation(ref, transform, status, callback) {
var animation = weex.requireModule('animation');
animation.transition(ref, {
styles: {
transform: transform
},
duration: status ? 250 : 300, // ms
timingFunction: status ? 'ease-in' : 'ease-out',
delay: 0 // ms
}, function () {
callback && callback();
});
}
},
uiStyle: {
/**
* 返回定义页面转场动画起初的位置
* @param animationType 页面转场动画的类型 push,model
* @param size 分割数组的长度
* @returns {}
*/
pageTransitionAnimationStyle: function pageTransitionAnimationStyle(animationType) {
if (animationType === 'push') {
return {
left: '750px',
top: '0px',
height: weex.config.env.deviceHeight / weex.config.env.deviceWidth * 750 + 'px'
};
} else if (animationType === 'model') {
return {
top: weex.config.env.deviceHeight / weex.config.env.deviceWidth * 750 + 'px',
left: '0px',
height: weex.config.env.deviceHeight / weex.config.env.deviceWidth * 750 + 'px'
};
}
return {};
}
}
};
exports.default = Utils;
/***/ }),
/* 34 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _index = __webpack_require__(42);
Object.defineProperty(exports, 'default', {
enumerable: true,
get: function get() {
return _interopRequireDefault(_index).default;
}
});
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/***/ }),
/* 35 */
/***/ (function(module, exports, __webpack_require__) {
;(function(fn) {
if (true) {
module.exports = fn();
} else if (typeof define === "function") {
define("index.weex", function(require, exports, module){
module.exports = fn();
});
} else {
var root;
if (typeof window !== "undefined") {
root = window;
} else if (typeof self !== "undefined") {
root = self;
} else if (typeof global !== "undefined") {
root = global;
} else {
// NOTICE: In JavaScript strict mode, this is null
root = this;
}
root["index.weex"] = fn();
}
})(function(){
return /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId]) {
/******/ return installedModules[moduleId].exports;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.l = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/******/
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/
/******/ // define getter function for harmony exports
/******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if(!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, {
/******/ configurable: false,
/******/ enumerable: true,
/******/ get: getter
/******/ });
/******/ }
/******/ };
/******/
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ function getDefault() { return module['default']; } :
/******/ function getModuleExports() { return module; };
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/ };
/******/
/******/ // Object.prototype.hasOwnProperty.call
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = 0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
/**
Copyright 2018 Alibaba Group
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
Object.defineProperty(exports, "__esModule", {
value: true
});
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
var _bindingxParser = __webpack_require__(1);
var isWeb = false;
var isWeex = true;
function requireModule(moduleName) {
try {
if ((typeof weex === 'undefined' ? 'undefined' : _typeof(weex)) !== undefined && weex.requireModule) {
// eslint-disable-line
return weex.requireModule(moduleName); // eslint-disable-line
}
} catch (err) {}
return window.require('@weex-module/' + moduleName);
}
var isSupportNewBinding = true;
var isSupportBinding = true;
var WeexBinding = void 0;
var WebBinding = {};
try {
WeexBinding = requireModule('bindingx');
isSupportNewBinding = true;
} catch (e) {
isSupportNewBinding = false;
}
if (!WeexBinding || !WeexBinding.bind) {
try {
WeexBinding = requireModule('binding');
isSupportNewBinding = true;
} catch (e) {
isSupportNewBinding = false;
}
}
isSupportNewBinding = !!(WeexBinding && WeexBinding.bind && WeexBinding.unbind);
if (!isSupportNewBinding) {
try {
WeexBinding = requireModule('expressionBinding');
isSupportBinding = true;
} catch (err) {
isSupportBinding = false;
}
}
isSupportBinding = !!(WeexBinding && (WeexBinding.bind || WeexBinding.createBinding));
function formatExpression(expression) {
if (expression === undefined) return;
try {
expression = JSON.parse(expression);
} catch (err) {}
var resultExpression = {};
if (typeof expression === 'string') {
resultExpression.origin = expression;
} else if (expression) {
resultExpression.origin = expression.origin;
resultExpression.transformed = expression.transformed;
}
if (!resultExpression.transformed && !resultExpression.origin) return;
resultExpression.transformed = resultExpression.transformed || (0, _bindingxParser.parse)(resultExpression.origin);
return resultExpression;
}
// 统一回调参数
function fixCallback(callback) {
return function () {
var params = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
if (typeof callback === 'function') {
return callback({
state: params.state === 'end' ? 'exit' : params.state,
t: params.t !== undefined ? params.t : params.deltaT
});
}
};
}
exports.default = {
// 是否支持新版本的binding
isSupportNewBinding: isSupportNewBinding,
// 是否支持binding
isSupportBinding: isSupportBinding,
_bindingInstances: [],
/**
* 绑定
* @param options 参数
* @example
{
anchor:blockRef,
eventType:'pan',
props: [
{
element:blockRef,
property:'transform.translateX',
expression:{
origin:"x+1",
transformed:"{\"type\":\"+\",\"children\":[{\"type\":\"Identifier\",\"value\":\"x\"},{\"type\":\"NumericLiteral\",\"value\":1}]}"
}
}
]
}
*/
bind: function bind(options) {
var callback = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};
if (!options) {
throw new Error('should pass options for binding');
}
options.exitExpression = formatExpression(options.exitExpression);
if (options.props) {
options.props.forEach(function (prop) {
prop.expression = formatExpression(prop.expression);
});
}
if (WeexBinding && isSupportBinding) {
if (isSupportNewBinding) {
return WeexBinding.bind(options, options && options.eventType === 'timing' ? fixCallback(callback) : callback);
} else {
WeexBinding.enableBinding(options.anchor, options.eventType);
// 处理expression的参数格式
var expressionArgs = options.props.map(function (prop) {
return {
element: prop.element,
property: prop.property,
expression: prop.expression.transformed
};
});
WeexBinding.createBinding(options.anchor, options.eventType, '', expressionArgs, callback);
}
}
},
/**
* @param {object} options
* @example
* {eventType:'pan',
* token:self.gesToken}
*/
unbind: function unbind(options) {
if (!options) {
throw new Error('should pass options for binding');
}
if (WeexBinding && isSupportBinding) {
if (isSupportNewBinding) {
return WeexBinding.unbind(options);
} else {
return WeexBinding.disableBinding(options.anchor, options.eventType);
}
}
},
unbindAll: function unbindAll() {
if (WeexBinding && isSupportBinding) {
if (isSupportNewBinding) {
return WeexBinding.unbindAll();
} else {
return WeexBinding.disableAll();
}
}
},
prepare: function prepare(options) {
if (WeexBinding && isSupportBinding) {
if (isSupportNewBinding) {
return WeexBinding.prepare(options);
} else {
return WeexBinding.enableBinding(options.anchor, options.eventType);
}
}
},
getComputedStyle: function getComputedStyle(el) {
if (isSupportNewBinding) {
return WeexBinding.getComputedStyle(el);
} else {
return {};
}
}
};
module.exports = exports['default'];
/***/ }),
/* 1 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
module.exports = __webpack_require__(2);
/***/ }),
/* 2 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var lex = {
InputElementDiv: '<WhiteSpace>|<LineTerminator>|<ReservedWord>|<Identifier>|<NumericLiteral>|<Punctuator>|<StringLiteral>',
InputElementRegExp: '<WhiteSpace>|<LineTerminator>|<ReservedWord>|<Identifier>|<NumericLiteral>|<Punctuator>|<StringLiteral>',
ReservedWord: '<Keyword>|<NullLiteral>|<BooleanLiteral>',
WhiteSpace: /[\t\v\f\u0020\u00A0\u1680\u180E\u2000-\u200A\u202F\u205f\u3000\uFEFF]/,
LineTerminator: /[\n\r\u2028\u2029]/,
Keyword: /new(?![_$a-zA-Z0-9])|void(?![_$a-zA-Z0-9])|delete(?![_$a-zA-Z0-9])|in(?![_$a-zA-Z0-9])|instanceof(?![_$a-zA-Z0-9])|typeof(?![_$a-zA-Z0-9])/,
NullLiteral: /null(?![_$a-zA-Z0-9])/,
BooleanLiteral: /(?:true|false)(?![_$a-zA-Z0-9])/,
Identifier: /[_$a-zA-Z][_$a-zA-Z0-9]*/,
Punctuator: /\/|=>|\*\*|>>>=|>>=|<<=|===|!==|>>>|<<|%=|\*=|-=|\+=|<=|>=|==|!=|\^=|\|=|\|\||&&|&=|>>|\+\+|--|\:|}|\*|&|\||\^|!|~|-|\+|\?|%|=|>|<|,|;|\.(?![0-9])|\]|\[|\)|\(|{/,
DivPunctuator: /\/=|\//,
NumericLiteral: /(?:0[xX][0-9a-fA-F]*|\.[0-9]+|(?:[1-9]+[0-9]*|0)(?:\.[0-9]*|\.)?)(?:[eE][+-]{0,1}[0-9]+)?(?![_$a-zA-Z0-9])/,
StringLiteral: /"(?:[^"\n\\\r\u2028\u2029]|\\(?:['"\\bfnrtv\n\r\u2028\u2029]|\r\n)|\\x[0-9a-fA-F]{2}|\\u[0-9a-fA-F]{4}|\\[^0-9ux'"\\bfnrtv\n\\\r\u2028\u2029])*"|'(?:[^'\n\\\r\u2028\u2029]|\\(?:['"\\bfnrtv\n\r\u2028\u2029]|\r\n)|\\x[0-9a-fA-F]{2}|\\u[0-9a-fA-F]{4}|\\[^0-9ux'"\\bfnrtv\n\\\r\u2028\u2029])*'/,
RegularExpressionLiteral: /\/(?:\[(?:\\[\s\S]|[^\]])*\]|[^*\/\\\n\r\u2028\u2029]|\\[^\n\r\u2028\u2029])(?:\[(?:\\[\s\S]|[^\]])*\]|[^\/\\\n\r\u2028\u2029]|\\[^\n\r\u2028\u2029])*\/[0-9a-zA-Z]*/
};
function XRegExp(xregexps, rootname, flag) {
var expnames = [rootname];
function buildRegExp(source) {
var regexp = new RegExp;
regexp.compile(source.replace(/<([^>]+)>/g,
function (all, expname) {
if (!xregexps[expname])
return '';
expnames.push(expname);
if (xregexps[expname] instanceof RegExp)
return '(' + xregexps[expname].source + ')';
return '(' + buildRegExp(xregexps[expname]).source + ')';
}), flag);
return regexp;
}
var regexp = buildRegExp(xregexps[rootname]);
this.exec = function (string) {
var matches = regexp.exec(string);
if (matches == null)
return null;
var result = new String(matches[0]);
for (var i = 0; i < expnames.length; i++)
if (matches[i])
result[expnames[i]] = matches[i];
return result;
};
Object.defineProperty(this, 'lastIndex',
{
'get': function () {
return regexp.lastIndex;
},
'set': function (v) {
regexp.lastIndex = v;
}
});
}
function LexicalParser() {
var inputElementDiv = new XRegExp(lex, 'InputElementDiv', 'g');
var inputElementRegExp = new XRegExp(lex, 'InputElementRegExp', 'g');
var source;
Object.defineProperty(this, 'source', {
'get': function () {
return source;
},