app模板、应用模板、组件模板、widget模板
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

3086 lines
125 KiB

4 years ago
  1. module.exports =
  2. /******/ (function(modules) { // webpackBootstrap
  3. /******/ // The module cache
  4. /******/ var installedModules = {};
  5. /******/
  6. /******/ // The require function
  7. /******/ function __webpack_require__(moduleId) {
  8. /******/
  9. /******/ // Check if module is in cache
  10. /******/ if(installedModules[moduleId]) {
  11. /******/ return installedModules[moduleId].exports;
  12. /******/ }
  13. /******/ // Create a new module (and put it into the cache)
  14. /******/ var module = installedModules[moduleId] = {
  15. /******/ i: moduleId,
  16. /******/ l: false,
  17. /******/ exports: {}
  18. /******/ };
  19. /******/
  20. /******/ // Execute the module function
  21. /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
  22. /******/
  23. /******/ // Flag the module as loaded
  24. /******/ module.l = true;
  25. /******/
  26. /******/ // Return the exports of the module
  27. /******/ return module.exports;
  28. /******/ }
  29. /******/
  30. /******/
  31. /******/ // expose the modules object (__webpack_modules__)
  32. /******/ __webpack_require__.m = modules;
  33. /******/
  34. /******/ // expose the module cache
  35. /******/ __webpack_require__.c = installedModules;
  36. /******/
  37. /******/ // define getter function for harmony exports
  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. /******/ // define __esModule on exports
  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. /******/ // create a fake namespace object
  53. /******/ // mode & 1: value is a module id, require it
  54. /******/ // mode & 2: merge all properties of value into the ns
  55. /******/ // mode & 4: return value when already ns object
  56. /******/ // mode & 8|1: behave like require
  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. /******/ // getDefaultExport function for compatibility with non-harmony modules
  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. /******/ // Object.prototype.hasOwnProperty.call
  78. /******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
  79. /******/
  80. /******/ // __webpack_public_path__
  81. /******/ __webpack_require__.p = "/dist/";
  82. /******/
  83. /******/
  84. /******/ // Load entry module and return exports
  85. /******/ return __webpack_require__(__webpack_require__.s = 360);
  86. /******/ })
  87. /************************************************************************/
  88. /******/ ({
  89. /***/ 0:
  90. /***/ (function(module, exports, __webpack_require__) {
  91. "use strict";
  92. var _interopRequireDefault = __webpack_require__(1);
  93. exports.__esModule = true;
  94. exports.noop = noop;
  95. exports.isDef = isDef;
  96. exports.isFunction = isFunction;
  97. exports.isObject = isObject;
  98. exports.isPromise = isPromise;
  99. exports.get = get;
  100. exports.isServer = exports.inBrowser = exports.addUnit = exports.createNamespace = void 0;
  101. var _vue = _interopRequireDefault(__webpack_require__(4));
  102. var _create = __webpack_require__(24);
  103. exports.createNamespace = _create.createNamespace;
  104. var _unit = __webpack_require__(20);
  105. exports.addUnit = _unit.addUnit;
  106. var inBrowser = typeof window !== 'undefined';
  107. exports.inBrowser = inBrowser;
  108. var isServer = _vue.default.prototype.$isServer; // eslint-disable-next-line @typescript-eslint/no-empty-function
  109. exports.isServer = isServer;
  110. function noop() {}
  111. function isDef(val) {
  112. return val !== undefined && val !== null;
  113. }
  114. function isFunction(val) {
  115. return typeof val === 'function';
  116. }
  117. function isObject(val) {
  118. return val !== null && typeof val === 'object';
  119. }
  120. function isPromise(val) {
  121. return isObject(val) && isFunction(val.then) && isFunction(val.catch);
  122. }
  123. function get(object, path) {
  124. var keys = path.split('.');
  125. var result = object;
  126. keys.forEach(function (key) {
  127. var _result$key;
  128. result = (_result$key = result[key]) != null ? _result$key : '';
  129. });
  130. return result;
  131. }
  132. /***/ }),
  133. /***/ 1:
  134. /***/ (function(module, exports) {
  135. function _interopRequireDefault(obj) {
  136. return obj && obj.__esModule ? obj : {
  137. "default": obj
  138. };
  139. }
  140. module.exports = _interopRequireDefault;
  141. /***/ }),
  142. /***/ 106:
  143. /***/ (function(module, exports, __webpack_require__) {
  144. var content = __webpack_require__(107);
  145. if(typeof content === 'string') content = [[module.i, content, '']];
  146. var transform;
  147. var insertInto;
  148. var options = {"hmr":true}
  149. options.transform = transform
  150. options.insertInto = undefined;
  151. var update = __webpack_require__(6)(content, options);
  152. if(content.locals) module.exports = content.locals;
  153. if(false) {}
  154. /***/ }),
  155. /***/ 107:
  156. /***/ (function(module, exports, __webpack_require__) {
  157. exports = module.exports = __webpack_require__(5)(false);
  158. // Module
  159. exports.push([module.i, ".van-cell{position:relative;display:-webkit-box;display:-webkit-flex;display:flex;box-sizing:border-box;width:100%;padding:10px 16px;overflow:hidden;color:#323233;font-size:14px;line-height:24px;background-color:#fff}.van-cell::after{position:absolute;box-sizing:border-box;content:' ';pointer-events:none;right:16px;bottom:0;left:16px;border-bottom:1px solid #ebedf0;-webkit-transform:scaleY(.5);transform:scaleY(.5)}.van-cell--borderless::after,.van-cell:last-child::after{display:none}.van-cell__label{margin-top:4px;color:#969799;font-size:12px;line-height:18px}.van-cell__title,.van-cell__value{-webkit-box-flex:1;-webkit-flex:1;flex:1}.van-cell__value{position:relative;overflow:hidden;color:#969799;text-align:right;vertical-align:middle;word-wrap:break-word}.van-cell__value--alone{color:#323233;text-align:left}.van-cell__left-icon,.van-cell__right-icon{height:24px;font-size:16px;line-height:24px}.van-cell__left-icon{margin-right:4px}.van-cell__right-icon{margin-left:4px;color:#969799}.van-cell--clickable{cursor:pointer}.van-cell--clickable:active{background-color:#f2f3f5}.van-cell--required{overflow:visible}.van-cell--required::before{position:absolute;left:8px;color:#ffce6d;font-size:14px;content:'*'}.van-cell--center{-webkit-box-align:center;-webkit-align-items:center;align-items:center}.van-cell--large{padding-top:12px;padding-bottom:12px}.van-cell--large .van-cell__title{font-size:16px}.van-cell--large .van-cell__label{font-size:14px}", ""]);
  160. /***/ }),
  161. /***/ 11:
  162. /***/ (function(module, exports, __webpack_require__) {
  163. "use strict";
  164. var _interopRequireDefault = __webpack_require__(1);
  165. exports.__esModule = true;
  166. exports.default = void 0;
  167. var _vue = _interopRequireDefault(__webpack_require__(4));
  168. var _deepAssign = __webpack_require__(21);
  169. var _zhCN = _interopRequireDefault(__webpack_require__(27));
  170. var proto = _vue.default.prototype;
  171. var defineReactive = _vue.default.util.defineReactive;
  172. defineReactive(proto, '$vantLang', 'zh-CN');
  173. defineReactive(proto, '$vantMessages', {
  174. 'zh-CN': _zhCN.default
  175. });
  176. var _default = {
  177. messages: function messages() {
  178. return proto.$vantMessages[proto.$vantLang];
  179. },
  180. use: function use(lang, messages) {
  181. var _this$add;
  182. proto.$vantLang = lang;
  183. this.add((_this$add = {}, _this$add[lang] = messages, _this$add));
  184. },
  185. add: function add(messages) {
  186. if (messages === void 0) {
  187. messages = {};
  188. }
  189. (0, _deepAssign.deepAssign)(proto.$vantMessages, messages);
  190. }
  191. };
  192. exports.default = _default;
  193. /***/ }),
  194. /***/ 12:
  195. /***/ (function(module, exports) {
  196. /**
  197. * When source maps are enabled, `style-loader` uses a link element with a data-uri to
  198. * embed the css on the page. This breaks all relative urls because now they are relative to a
  199. * bundle instead of the current page.
  200. *
  201. * One solution is to only use full urls, but that may be impossible.
  202. *
  203. * Instead, this function "fixes" the relative urls to be absolute according to the current page location.
  204. *
  205. * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command.
  206. *
  207. */
  208. module.exports = function (css) {
  209. // get current location
  210. var location = typeof window !== "undefined" && window.location;
  211. if (!location) {
  212. throw new Error("fixUrls requires window.location");
  213. }
  214. // blank or null?
  215. if (!css || typeof css !== "string") {
  216. return css;
  217. }
  218. var baseUrl = location.protocol + "//" + location.host;
  219. var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/");
  220. // convert each url(...)
  221. /*
  222. This regular expression is just a way to recursively match brackets within
  223. a string.
  224. /url\s*\( = Match on the word "url" with any whitespace after it and then a parens
  225. ( = Start a capturing group
  226. (?: = Start a non-capturing group
  227. [^)(] = Match anything that isn't a parentheses
  228. | = OR
  229. \( = Match a start parentheses
  230. (?: = Start another non-capturing groups
  231. [^)(]+ = Match anything that isn't a parentheses
  232. | = OR
  233. \( = Match a start parentheses
  234. [^)(]* = Match anything that isn't a parentheses
  235. \) = Match a end parentheses
  236. ) = End Group
  237. *\) = Match anything and then a close parens
  238. ) = Close non-capturing group
  239. * = Match anything
  240. ) = Close capturing group
  241. \) = Match a close parens
  242. /gi = Get all matches, not the first. Be case insensitive.
  243. */
  244. var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) {
  245. // strip quotes (if they exist)
  246. var unquotedOrigUrl = origUrl
  247. .trim()
  248. .replace(/^"(.*)"$/, function(o, $1){ return $1; })
  249. .replace(/^'(.*)'$/, function(o, $1){ return $1; });
  250. // already a full url? no change
  251. if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/|\s*$)/i.test(unquotedOrigUrl)) {
  252. return fullMatch;
  253. }
  254. // convert the url to a full url
  255. var newUrl;
  256. if (unquotedOrigUrl.indexOf("//") === 0) {
  257. //TODO: should we add protocol?
  258. newUrl = unquotedOrigUrl;
  259. } else if (unquotedOrigUrl.indexOf("/") === 0) {
  260. // path should be relative to the base url
  261. newUrl = baseUrl + unquotedOrigUrl; // already starts with '/'
  262. } else {
  263. // path should be relative to current directory
  264. newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './'
  265. }
  266. // send back the fixed url(...)
  267. return "url(" + JSON.stringify(newUrl) + ")";
  268. });
  269. // send back the fixed css
  270. return fixedCss;
  271. };
  272. /***/ }),
  273. /***/ 127:
  274. /***/ (function(module, exports, __webpack_require__) {
  275. "use strict";
  276. exports.__esModule = true;
  277. exports.resetScroll = resetScroll;
  278. var _system = __webpack_require__(128);
  279. var _scroll = __webpack_require__(53);
  280. /**
  281. * Hack for iOS12 page scroll
  282. * https://developers.weixin.qq.com/community/develop/doc/00044ae90742f8c82fb78fcae56800
  283. */
  284. var isIOS = (0, _system.isIOS)();
  285. /* istanbul ignore next */
  286. function resetScroll() {
  287. if (isIOS) {
  288. (0, _scroll.setRootScrollTop)((0, _scroll.getRootScrollTop)());
  289. }
  290. }
  291. /***/ }),
  292. /***/ 128:
  293. /***/ (function(module, exports, __webpack_require__) {
  294. "use strict";
  295. exports.__esModule = true;
  296. exports.isAndroid = isAndroid;
  297. exports.isIOS = isIOS;
  298. var _ = __webpack_require__(0);
  299. function isAndroid() {
  300. /* istanbul ignore next */
  301. return _.isServer ? false : /android/.test(navigator.userAgent.toLowerCase());
  302. }
  303. function isIOS() {
  304. /* istanbul ignore next */
  305. return _.isServer ? false : /ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase());
  306. }
  307. /***/ }),
  308. /***/ 14:
  309. /***/ (function(module, exports, __webpack_require__) {
  310. "use strict";
  311. var _interopRequireDefault = __webpack_require__(1);
  312. exports.__esModule = true;
  313. exports.inherit = inherit;
  314. exports.emit = emit;
  315. exports.mount = mount;
  316. var _extends2 = _interopRequireDefault(__webpack_require__(18));
  317. var _vue = _interopRequireDefault(__webpack_require__(4));
  318. var inheritKey = ['ref', 'style', 'class', 'attrs', 'refInFor', 'nativeOn', 'directives', 'staticClass', 'staticStyle'];
  319. var mapInheritKey = {
  320. nativeOn: 'on'
  321. }; // inherit partial context, map nativeOn to on
  322. function inherit(context, inheritListeners) {
  323. var result = inheritKey.reduce(function (obj, key) {
  324. if (context.data[key]) {
  325. obj[mapInheritKey[key] || key] = context.data[key];
  326. }
  327. return obj;
  328. }, {});
  329. if (inheritListeners) {
  330. result.on = result.on || {};
  331. (0, _extends2.default)(result.on, context.data.on);
  332. }
  333. return result;
  334. } // emit event
  335. function emit(context, eventName) {
  336. for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
  337. args[_key - 2] = arguments[_key];
  338. }
  339. var listeners = context.listeners[eventName];
  340. if (listeners) {
  341. if (Array.isArray(listeners)) {
  342. listeners.forEach(function (listener) {
  343. listener.apply(void 0, args);
  344. });
  345. } else {
  346. listeners.apply(void 0, args);
  347. }
  348. }
  349. } // mount functional component
  350. function mount(Component, data) {
  351. var instance = new _vue.default({
  352. el: document.createElement('div'),
  353. props: Component.props,
  354. render: function render(h) {
  355. return h(Component, (0, _extends2.default)({
  356. props: this.$props
  357. }, data));
  358. }
  359. });
  360. document.body.appendChild(instance.$el);
  361. return instance;
  362. }
  363. /***/ }),
  364. /***/ 143:
  365. /***/ (function(module, exports, __webpack_require__) {
  366. "use strict";
  367. var _interopRequireDefault = __webpack_require__(1);
  368. exports.__esModule = true;
  369. exports.default = void 0;
  370. var _babelHelperVueJsxMergeProps = _interopRequireDefault(__webpack_require__(16));
  371. var _extends2 = _interopRequireDefault(__webpack_require__(18));
  372. var _resetScroll = __webpack_require__(127);
  373. var _number = __webpack_require__(81);
  374. var _event = __webpack_require__(30);
  375. var _utils = __webpack_require__(0);
  376. var _icon = _interopRequireDefault(__webpack_require__(35));
  377. var _cell = _interopRequireDefault(__webpack_require__(97));
  378. var _shared = __webpack_require__(96);
  379. // Utils
  380. // Components
  381. var _createNamespace = (0, _utils.createNamespace)('field'),
  382. createComponent = _createNamespace[0],
  383. bem = _createNamespace[1];
  384. var _default = createComponent({
  385. inheritAttrs: false,
  386. provide: function provide() {
  387. return {
  388. vanField: this
  389. };
  390. },
  391. inject: {
  392. vanForm: {
  393. default: null
  394. }
  395. },
  396. props: (0, _extends2.default)({}, _shared.cellProps, {
  397. name: String,
  398. rules: Array,
  399. disabled: {
  400. type: Boolean,
  401. default: null
  402. },
  403. readonly: {
  404. type: Boolean,
  405. default: null
  406. },
  407. autosize: [Boolean, Object],
  408. leftIcon: String,
  409. rightIcon: String,
  410. clearable: Boolean,
  411. formatter: Function,
  412. maxlength: [Number, String],
  413. labelWidth: [Number, String],
  414. labelClass: null,
  415. labelAlign: String,
  416. inputAlign: String,
  417. placeholder: String,
  418. errorMessage: String,
  419. errorMessageAlign: String,
  420. showWordLimit: Boolean,
  421. value: {
  422. type: [Number, String],
  423. default: ''
  424. },
  425. type: {
  426. type: String,
  427. default: 'text'
  428. },
  429. error: {
  430. type: Boolean,
  431. default: null
  432. },
  433. colon: {
  434. type: Boolean,
  435. default: null
  436. },
  437. clearTrigger: {
  438. type: String,
  439. default: 'focus'
  440. },
  441. formatTrigger: {
  442. type: String,
  443. default: 'onChange'
  444. }
  445. }),
  446. data: function data() {
  447. return {
  448. focused: false,
  449. validateFailed: false,
  450. validateMessage: ''
  451. };
  452. },
  453. watch: {
  454. value: function value() {
  455. this.updateValue(this.value);
  456. this.resetValidation();
  457. this.validateWithTrigger('onChange');
  458. this.$nextTick(this.adjustSize);
  459. }
  460. },
  461. mounted: function mounted() {
  462. this.updateValue(this.value, this.formatTrigger);
  463. this.$nextTick(this.adjustSize);
  464. if (this.vanForm) {
  465. this.vanForm.addField(this);
  466. }
  467. },
  468. beforeDestroy: function beforeDestroy() {
  469. if (this.vanForm) {
  470. this.vanForm.removeField(this);
  471. }
  472. },
  473. computed: {
  474. showClear: function showClear() {
  475. var readonly = this.getProp('readonly');
  476. if (this.clearable && !readonly) {
  477. var hasValue = (0, _utils.isDef)(this.value) && this.value !== '';
  478. var trigger = this.clearTrigger === 'always' || this.clearTrigger === 'focus' && this.focused;
  479. return hasValue && trigger;
  480. }
  481. },
  482. showError: function showError() {
  483. if (this.error !== null) {
  484. return this.error;
  485. }
  486. if (this.vanForm && this.vanForm.showError && this.validateFailed) {
  487. return true;
  488. }
  489. },
  490. listeners: function listeners() {
  491. return (0, _extends2.default)({}, this.$listeners, {
  492. blur: this.onBlur,
  493. focus: this.onFocus,
  494. input: this.onInput,
  495. click: this.onClickInput,
  496. keypress: this.onKeypress
  497. });
  498. },
  499. labelStyle: function labelStyle() {
  500. var labelWidth = this.getProp('labelWidth');
  501. if (labelWidth) {
  502. return {
  503. width: (0, _utils.addUnit)(labelWidth)
  504. };
  505. }
  506. },
  507. formValue: function formValue() {
  508. if (this.children && (this.$scopedSlots.input || this.$slots.input)) {
  509. return this.children.value;
  510. }
  511. return this.value;
  512. }
  513. },
  514. methods: {
  515. // @exposed-api
  516. focus: function focus() {
  517. if (this.$refs.input) {
  518. this.$refs.input.focus();
  519. }
  520. },
  521. // @exposed-api
  522. blur: function blur() {
  523. if (this.$refs.input) {
  524. this.$refs.input.blur();
  525. }
  526. },
  527. runValidator: function runValidator(value, rule) {
  528. return new Promise(function (resolve) {
  529. var returnVal = rule.validator(value, rule);
  530. if ((0, _utils.isPromise)(returnVal)) {
  531. return returnVal.then(resolve);
  532. }
  533. resolve(returnVal);
  534. });
  535. },
  536. isEmptyValue: function isEmptyValue(value) {
  537. if (Array.isArray(value)) {
  538. return !value.length;
  539. }
  540. if (value === 0) {
  541. return false;
  542. }
  543. return !value;
  544. },
  545. runSyncRule: function runSyncRule(value, rule) {
  546. if (rule.required && this.isEmptyValue(value)) {
  547. return false;
  548. }
  549. if (rule.pattern && !rule.pattern.test(value)) {
  550. return false;
  551. }
  552. return true;
  553. },
  554. getRuleMessage: function getRuleMessage(value, rule) {
  555. var message = rule.message;
  556. if ((0, _utils.isFunction)(message)) {
  557. return message(value, rule);
  558. }
  559. return message;
  560. },
  561. runRules: function runRules(rules) {
  562. var _this = this;
  563. return rules.reduce(function (promise, rule) {
  564. return promise.then(function () {
  565. if (_this.validateFailed) {
  566. return;
  567. }
  568. var value = _this.formValue;
  569. if (rule.formatter) {
  570. value = rule.formatter(value, rule);
  571. }
  572. if (!_this.runSyncRule(value, rule)) {
  573. _this.validateFailed = true;
  574. _this.validateMessage = _this.getRuleMessage(value, rule);
  575. return;
  576. }
  577. if (rule.validator) {
  578. return _this.runValidator(value, rule).then(function (result) {
  579. if (result === false) {
  580. _this.validateFailed = true;
  581. _this.validateMessage = _this.getRuleMessage(value, rule);
  582. }
  583. });
  584. }
  585. });
  586. }, Promise.resolve());
  587. },
  588. validate: function validate(rules) {
  589. var _this2 = this;
  590. if (rules === void 0) {
  591. rules = this.rules;
  592. }
  593. return new Promise(function (resolve) {
  594. if (!rules) {
  595. resolve();
  596. }
  597. _this2.resetValidation();
  598. _this2.runRules(rules).then(function () {
  599. if (_this2.validateFailed) {
  600. resolve({
  601. name: _this2.name,
  602. message: _this2.validateMessage
  603. });
  604. } else {
  605. resolve();
  606. }
  607. });
  608. });
  609. },
  610. validateWithTrigger: function validateWithTrigger(trigger) {
  611. if (this.vanForm && this.rules) {
  612. var defaultTrigger = this.vanForm.validateTrigger === trigger;
  613. var rules = this.rules.filter(function (rule) {
  614. if (rule.trigger) {
  615. return rule.trigger === trigger;
  616. }
  617. return defaultTrigger;
  618. });
  619. this.validate(rules);
  620. }
  621. },
  622. resetValidation: function resetValidation() {
  623. if (this.validateFailed) {
  624. this.validateFailed = false;
  625. this.validateMessage = '';
  626. }
  627. },
  628. updateValue: function updateValue(value, trigger) {
  629. if (trigger === void 0) {
  630. trigger = 'onChange';
  631. }
  632. value = (0, _utils.isDef)(value) ? String(value) : ''; // native maxlength have incorrect line-break counting
  633. // see: https://github.com/youzan/vant/issues/5033
  634. var maxlength = this.maxlength;
  635. if ((0, _utils.isDef)(maxlength) && value.length > maxlength) {
  636. if (this.value && this.value.length === +maxlength) {
  637. value = this.value;
  638. } else {
  639. value = value.slice(0, maxlength);
  640. }
  641. }
  642. if (this.type === 'number' || this.type === 'digit') {
  643. var isNumber = this.type === 'number';
  644. value = (0, _number.formatNumber)(value, isNumber, isNumber);
  645. }
  646. if (this.formatter && trigger === this.formatTrigger) {
  647. value = this.formatter(value);
  648. }
  649. var input = this.$refs.input;
  650. if (input && value !== input.value) {
  651. input.value = value;
  652. }
  653. if (value !== this.value) {
  654. this.$emit('input', value);
  655. }
  656. },
  657. onInput: function onInput(event) {
  658. // not update v-model when composing
  659. if (event.target.composing) {
  660. return;
  661. }
  662. this.updateValue(event.target.value);
  663. },
  664. onFocus: function onFocus(event) {
  665. this.focused = true;
  666. this.$emit('focus', event); // readonly not work in lagacy mobile safari
  667. /* istanbul ignore if */
  668. var readonly = this.getProp('readonly');
  669. if (readonly) {
  670. this.blur();
  671. }
  672. },
  673. onBlur: function onBlur(event) {
  674. this.focused = false;
  675. this.updateValue(this.value, 'onBlur');
  676. this.$emit('blur', event);
  677. this.validateWithTrigger('onBlur');
  678. (0, _resetScroll.resetScroll)();
  679. },
  680. onClick: function onClick(event) {
  681. this.$emit('click', event);
  682. },
  683. onClickInput: function onClickInput(event) {
  684. this.$emit('click-input', event);
  685. },
  686. onClickLeftIcon: function onClickLeftIcon(event) {
  687. this.$emit('click-left-icon', event);
  688. },
  689. onClickRightIcon: function onClickRightIcon(event) {
  690. this.$emit('click-right-icon', event);
  691. },
  692. onClear: function onClear(event) {
  693. (0, _event.preventDefault)(event);
  694. this.$emit('input', '');
  695. this.$emit('clear', event);
  696. },
  697. onKeypress: function onKeypress(event) {
  698. var ENTER_CODE = 13;
  699. if (event.keyCode === ENTER_CODE) {
  700. var submitOnEnter = this.getProp('submitOnEnter');
  701. if (!submitOnEnter && this.type !== 'textarea') {
  702. (0, _event.preventDefault)(event);
  703. } // trigger blur after click keyboard search button
  704. if (this.type === 'search') {
  705. this.blur();
  706. }
  707. }
  708. this.$emit('keypress', event);
  709. },
  710. adjustSize: function adjustSize() {
  711. var input = this.$refs.input;
  712. if (!(this.type === 'textarea' && this.autosize) || !input) {
  713. return;
  714. }
  715. input.style.height = 'auto';
  716. var height = input.scrollHeight;
  717. if ((0, _utils.isObject)(this.autosize)) {
  718. var _this$autosize = this.autosize,
  719. maxHeight = _this$autosize.maxHeight,
  720. minHeight = _this$autosize.minHeight;
  721. if (maxHeight) {
  722. height = Math.min(height, maxHeight);
  723. }
  724. if (minHeight) {
  725. height = Math.max(height, minHeight);
  726. }
  727. }
  728. if (height) {
  729. input.style.height = height + 'px';
  730. }
  731. },
  732. genInput: function genInput() {
  733. var h = this.$createElement;
  734. var type = this.type;
  735. var disabled = this.getProp('disabled');
  736. var readonly = this.getProp('readonly');
  737. var inputSlot = this.slots('input');
  738. var inputAlign = this.getProp('inputAlign');
  739. if (inputSlot) {
  740. return h("div", {
  741. "class": bem('control', [inputAlign, 'custom']),
  742. "on": {
  743. "click": this.onClickInput
  744. }
  745. }, [inputSlot]);
  746. }
  747. var inputProps = {
  748. ref: 'input',
  749. class: bem('control', inputAlign),
  750. domProps: {
  751. value: this.value
  752. },
  753. attrs: (0, _extends2.default)({}, this.$attrs, {
  754. name: this.name,
  755. disabled: disabled,
  756. readonly: readonly,
  757. placeholder: this.placeholder
  758. }),
  759. on: this.listeners,
  760. // add model directive to skip IME composition
  761. directives: [{
  762. name: 'model',
  763. value: this.value
  764. }]
  765. };
  766. if (type === 'textarea') {
  767. return h("textarea", (0, _babelHelperVueJsxMergeProps.default)([{}, inputProps]));
  768. }
  769. var inputType = type;
  770. var inputMode; // type="number" is weired in iOS, and can't prevent dot in Android
  771. // so use inputmode to set keyboard in mordern browers
  772. if (type === 'number') {
  773. inputType = 'text';
  774. inputMode = 'decimal';
  775. }
  776. if (type === 'digit') {
  777. inputType = 'tel';
  778. inputMode = 'numeric';
  779. }
  780. return h("input", (0, _babelHelperVueJsxMergeProps.default)([{
  781. "attrs": {
  782. "type": inputType,
  783. "inputmode": inputMode
  784. }
  785. }, inputProps]));
  786. },
  787. genLeftIcon: function genLeftIcon() {
  788. var h = this.$createElement;
  789. var showLeftIcon = this.slots('left-icon') || this.leftIcon;
  790. if (showLeftIcon) {
  791. return h("div", {
  792. "class": bem('left-icon'),
  793. "on": {
  794. "click": this.onClickLeftIcon
  795. }
  796. }, [this.slots('left-icon') || h(_icon.default, {
  797. "attrs": {
  798. "name": this.leftIcon,
  799. "classPrefix": this.iconPrefix
  800. }
  801. })]);
  802. }
  803. },
  804. genRightIcon: function genRightIcon() {
  805. var h = this.$createElement;
  806. var slots = this.slots;
  807. var showRightIcon = slots('right-icon') || this.rightIcon;
  808. if (showRightIcon) {
  809. return h("div", {
  810. "class": bem('right-icon'),
  811. "on": {
  812. "click": this.onClickRightIcon
  813. }
  814. }, [slots('right-icon') || h(_icon.default, {
  815. "attrs": {
  816. "name": this.rightIcon,
  817. "classPrefix": this.iconPrefix
  818. }
  819. })]);
  820. }
  821. },
  822. genWordLimit: function genWordLimit() {
  823. var h = this.$createElement;
  824. if (this.showWordLimit && this.maxlength) {
  825. var count = (this.value || '').length;
  826. return h("div", {
  827. "class": bem('word-limit')
  828. }, [h("span", {
  829. "class": bem('word-num')
  830. }, [count]), "/", this.maxlength]);
  831. }
  832. },
  833. genMessage: function genMessage() {
  834. var h = this.$createElement;
  835. if (this.vanForm && this.vanForm.showErrorMessage === false) {
  836. return;
  837. }
  838. var message = this.errorMessage || this.validateMessage;
  839. if (message) {
  840. var errorMessageAlign = this.getProp('errorMessageAlign');
  841. return h("div", {
  842. "class": bem('error-message', errorMessageAlign)
  843. }, [message]);
  844. }
  845. },
  846. getProp: function getProp(key) {
  847. if ((0, _utils.isDef)(this[key])) {
  848. return this[key];
  849. }
  850. if (this.vanForm && (0, _utils.isDef)(this.vanForm[key])) {
  851. return this.vanForm[key];
  852. }
  853. },
  854. genLabel: function genLabel() {
  855. var h = this.$createElement;
  856. var colon = this.getProp('colon') ? ':' : '';
  857. if (this.slots('label')) {
  858. return [this.slots('label'), colon];
  859. }
  860. if (this.label) {
  861. return h("span", [this.label + colon]);
  862. }
  863. }
  864. },
  865. render: function render() {
  866. var _bem;
  867. var h = arguments[0];
  868. var slots = this.slots;
  869. var disabled = this.getProp('disabled');
  870. var labelAlign = this.getProp('labelAlign');
  871. var scopedSlots = {
  872. icon: this.genLeftIcon
  873. };
  874. var Label = this.genLabel();
  875. if (Label) {
  876. scopedSlots.title = function () {
  877. return Label;
  878. };
  879. }
  880. var extra = this.slots('extra');
  881. if (extra) {
  882. scopedSlots.extra = function () {
  883. return extra;
  884. };
  885. }
  886. return h(_cell.default, {
  887. "attrs": {
  888. "icon": this.leftIcon,
  889. "size": this.size,
  890. "center": this.center,
  891. "border": this.border,
  892. "isLink": this.isLink,
  893. "required": this.required,
  894. "clickable": this.clickable,
  895. "titleStyle": this.labelStyle,
  896. "valueClass": bem('value'),
  897. "titleClass": [bem('label', labelAlign), this.labelClass],
  898. "arrowDirection": this.arrowDirection
  899. },
  900. "scopedSlots": scopedSlots,
  901. "class": bem((_bem = {
  902. error: this.showError,
  903. disabled: disabled
  904. }, _bem["label-" + labelAlign] = labelAlign, _bem['min-height'] = this.type === 'textarea' && !this.autosize, _bem)),
  905. "on": {
  906. "click": this.onClick
  907. }
  908. }, [h("div", {
  909. "class": bem('body')
  910. }, [this.genInput(), this.showClear && h(_icon.default, {
  911. "attrs": {
  912. "name": "clear"
  913. },
  914. "class": bem('clear'),
  915. "on": {
  916. "touchstart": this.onClear
  917. }
  918. }), this.genRightIcon(), slots('button') && h("div", {
  919. "class": bem('button')
  920. }, [slots('button')])]), this.genWordLimit(), this.genMessage()]);
  921. }
  922. });
  923. exports.default = _default;
  924. /***/ }),
  925. /***/ 16:
  926. /***/ (function(module, exports, __webpack_require__) {
  927. "use strict";
  928. function _extends(){return _extends=Object.assign||function(a){for(var b,c=1;c<arguments.length;c++)for(var d in b=arguments[c],b)Object.prototype.hasOwnProperty.call(b,d)&&(a[d]=b[d]);return a},_extends.apply(this,arguments)}var normalMerge=["attrs","props","domProps"],toArrayMerge=["class","style","directives"],functionalMerge=["on","nativeOn"],mergeJsxProps=function(a){return a.reduce(function(c,a){for(var b in a)if(!c[b])c[b]=a[b];else if(-1!==normalMerge.indexOf(b))c[b]=_extends({},c[b],a[b]);else if(-1!==toArrayMerge.indexOf(b)){var d=c[b]instanceof Array?c[b]:[c[b]],e=a[b]instanceof Array?a[b]:[a[b]];c[b]=d.concat(e)}else if(-1!==functionalMerge.indexOf(b)){for(var f in a[b])if(c[b][f]){var g=c[b][f]instanceof Array?c[b][f]:[c[b][f]],h=a[b][f]instanceof Array?a[b][f]:[a[b][f]];c[b][f]=g.concat(h)}else c[b][f]=a[b][f];}else if("hook"==b)for(var i in a[b])c[b][i]=c[b][i]?mergeFn(c[b][i],a[b][i]):a[b][i];else c[b]=a[b];return c},{})},mergeFn=function(a,b){return function(){a&&a.apply(this,arguments),b&&b.apply(this,arguments)}};module.exports=mergeJsxProps;
  929. /***/ }),
  930. /***/ 18:
  931. /***/ (function(module, exports) {
  932. function _extends() {
  933. module.exports = _extends = Object.assign || function (target) {
  934. for (var i = 1; i < arguments.length; i++) {
  935. var source = arguments[i];
  936. for (var key in source) {
  937. if (Object.prototype.hasOwnProperty.call(source, key)) {
  938. target[key] = source[key];
  939. }
  940. }
  941. }
  942. return target;
  943. };
  944. return _extends.apply(this, arguments);
  945. }
  946. module.exports = _extends;
  947. /***/ }),
  948. /***/ 182:
  949. /***/ (function(module, exports, __webpack_require__) {
  950. var content = __webpack_require__(183);
  951. if(typeof content === 'string') content = [[module.i, content, '']];
  952. var transform;
  953. var insertInto;
  954. var options = {"hmr":true}
  955. options.transform = transform
  956. options.insertInto = undefined;
  957. var update = __webpack_require__(6)(content, options);
  958. if(content.locals) module.exports = content.locals;
  959. if(false) {}
  960. /***/ }),
  961. /***/ 183:
  962. /***/ (function(module, exports, __webpack_require__) {
  963. exports = module.exports = __webpack_require__(5)(false);
  964. // Module
  965. exports.push([module.i, ".van-field__label{-webkit-box-flex:0;-webkit-flex:none;flex:none;box-sizing:border-box;width:6.2em;margin-right:12px;color:#646566;text-align:left;word-wrap:break-word}.van-field__label--center{text-align:center}.van-field__label--right{text-align:right}.van-field--disabled .van-field__label{color:#c8c9cc}.van-field__value{overflow:visible}.van-field__body{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-align:center;-webkit-align-items:center;align-items:center}.van-field__control{display:block;box-sizing:border-box;width:100%;min-width:0;margin:0;padding:0;color:#323233;line-height:inherit;text-align:left;background-color:transparent;border:0;resize:none}.van-field__control::-webkit-input-placeholder{color:#c8c9cc}.van-field__control::placeholder{color:#c8c9cc}.van-field__control:disabled{color:#c8c9cc;cursor:not-allowed;opacity:1;-webkit-text-fill-color:#c8c9cc}.van-field__control:read-only{cursor:default}.van-field__control--center{-webkit-box-pack:center;-webkit-justify-content:center;justify-content:center;text-align:center}.van-field__control--right{-webkit-box-pack:end;-webkit-justify-content:flex-end;justify-content:flex-end;text-align:right}.van-field__control--custom{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-align:center;-webkit-align-items:center;align-items:center;min-height:24px}.van-field__control[type=date],.van-field__control[type=datetime-local],.van-field__control[type=time]{min-height:24px}.van-field__control[type=search]{-webkit-appearance:none}.van-field__button,.van-field__clear,.van-field__icon,.van-field__right-icon{-webkit-flex-shrink:0;flex-shrink:0}.van-field__clear,.van-field__right-icon{margin-right:-8px;padding:0 8px;line-height:inherit}.van-field__clear{color:#c8c9cc;font-size:16px;cursor:pointer}.van-field__left-icon .van-icon,.van-field__right-icon .van-icon{display:block;font-size:16px;line-height:inherit}.van-field__left-icon{margin-right:4px}.van-field__right-icon{color:#969799}.van-field__button{padding-left:8px}.van-field__error-message{color:#ffce6d;font-size:12px;text-align:left}.van-field__error-message--center{text-align:center}.van-field__error-message--right{text-align:right}.van-field__word-limit{margin-top:4px;color:#646566;font-size:12px;line-height:16px;text-align:right}.van-field--error .van-field__control::-webkit-input-placeholder{color:#ffce6d;-webkit-text-fill-color:currentColor}.van-field--error .van-field__control,.van-field--error .van-field__control::placeholder{color:#ffce6d;-webkit-text-fill-color:currentColor}.van-field--min-height .van-field__control{min-height:60px}", ""]);
  966. /***/ }),
  967. /***/ 19:
  968. /***/ (function(module, exports, __webpack_require__) {
  969. "use strict";
  970. exports.__esModule = true;
  971. exports.isNumeric = isNumeric;
  972. exports.isNaN = isNaN;
  973. function isNumeric(val) {
  974. return /^\d+(\.\d+)?$/.test(val);
  975. }
  976. function isNaN(val) {
  977. if (Number.isNaN) {
  978. return Number.isNaN(val);
  979. } // eslint-disable-next-line no-self-compare
  980. return val !== val;
  981. }
  982. /***/ }),
  983. /***/ 20:
  984. /***/ (function(module, exports, __webpack_require__) {
  985. "use strict";
  986. exports.__esModule = true;
  987. exports.addUnit = addUnit;
  988. exports.unitToPx = unitToPx;
  989. var _ = __webpack_require__(0);
  990. var _number = __webpack_require__(19);
  991. function addUnit(value) {
  992. if (!(0, _.isDef)(value)) {
  993. return undefined;
  994. }
  995. value = String(value);
  996. return (0, _number.isNumeric)(value) ? value + "px" : value;
  997. } // cache
  998. var rootFontSize;
  999. function getRootFontSize() {
  1000. if (!rootFontSize) {
  1001. var doc = document.documentElement;
  1002. var fontSize = doc.style.fontSize || window.getComputedStyle(doc).fontSize;
  1003. rootFontSize = parseFloat(fontSize);
  1004. }
  1005. return rootFontSize;
  1006. }
  1007. function convertRem(value) {
  1008. value = value.replace(/rem/g, '');
  1009. return +value * getRootFontSize();
  1010. }
  1011. function convertVw(value) {
  1012. value = value.replace(/vw/g, '');
  1013. return +value * window.innerWidth / 100;
  1014. }
  1015. function convertVh(value) {
  1016. value = value.replace(/vh/g, '');
  1017. return +value * window.innerHeight / 100;
  1018. }
  1019. function unitToPx(value) {
  1020. if (typeof value === 'number') {
  1021. return value;
  1022. }
  1023. if (_.inBrowser) {
  1024. if (value.indexOf('rem') !== -1) {
  1025. return convertRem(value);
  1026. }
  1027. if (value.indexOf('vw') !== -1) {
  1028. return convertVw(value);
  1029. }
  1030. if (value.indexOf('vh') !== -1) {
  1031. return convertVh(value);
  1032. }
  1033. }
  1034. return parseFloat(value);
  1035. }
  1036. /***/ }),
  1037. /***/ 21:
  1038. /***/ (function(module, exports, __webpack_require__) {
  1039. "use strict";
  1040. exports.__esModule = true;
  1041. exports.deepAssign = deepAssign;
  1042. var _ = __webpack_require__(0);
  1043. var hasOwnProperty = Object.prototype.hasOwnProperty;
  1044. function assignKey(to, from, key) {
  1045. var val = from[key];
  1046. if (!(0, _.isDef)(val)) {
  1047. return;
  1048. }
  1049. if (!hasOwnProperty.call(to, key) || !(0, _.isObject)(val)) {
  1050. to[key] = val;
  1051. } else {
  1052. // eslint-disable-next-line @typescript-eslint/no-use-before-define
  1053. to[key] = deepAssign(Object(to[key]), from[key]);
  1054. }
  1055. }
  1056. function deepAssign(to, from) {
  1057. Object.keys(from).forEach(function (key) {
  1058. assignKey(to, from, key);
  1059. });
  1060. return to;
  1061. }
  1062. /***/ }),
  1063. /***/ 211:
  1064. /***/ (function(module, exports, __webpack_require__) {
  1065. "use strict";
  1066. var _interopRequireDefault = __webpack_require__(1);
  1067. exports.__esModule = true;
  1068. exports.default = void 0;
  1069. var _babelHelperVueJsxMergeProps = _interopRequireDefault(__webpack_require__(16));
  1070. var _extends2 = _interopRequireDefault(__webpack_require__(18));
  1071. var _utils = __webpack_require__(0);
  1072. var _functional = __webpack_require__(14);
  1073. var _event = __webpack_require__(30);
  1074. var _field = _interopRequireDefault(__webpack_require__(143));
  1075. // Utils
  1076. // Components
  1077. var _createNamespace = (0, _utils.createNamespace)('search'),
  1078. createComponent = _createNamespace[0],
  1079. bem = _createNamespace[1],
  1080. t = _createNamespace[2];
  1081. function Search(h, props, slots, ctx) {
  1082. function Label() {
  1083. if (slots.label || props.label) {
  1084. return h("div", {
  1085. "class": bem('label')
  1086. }, [slots.label ? slots.label() : props.label]);
  1087. }
  1088. }
  1089. function Action() {
  1090. if (!props.showAction) {
  1091. return;
  1092. }
  1093. function onCancel() {
  1094. if (slots.action) {
  1095. return;
  1096. }
  1097. (0, _functional.emit)(ctx, 'input', '');
  1098. (0, _functional.emit)(ctx, 'cancel');
  1099. }
  1100. return h("div", {
  1101. "class": bem('action'),
  1102. "attrs": {
  1103. "role": "button",
  1104. "tabindex": "0"
  1105. },
  1106. "on": {
  1107. "click": onCancel
  1108. }
  1109. }, [slots.action ? slots.action() : props.actionText || t('cancel')]);
  1110. }
  1111. var fieldData = {
  1112. attrs: ctx.data.attrs,
  1113. on: (0, _extends2.default)({}, ctx.listeners, {
  1114. keypress: function keypress(event) {
  1115. // press enter
  1116. if (event.keyCode === 13) {
  1117. (0, _event.preventDefault)(event);
  1118. (0, _functional.emit)(ctx, 'search', props.value);
  1119. }
  1120. (0, _functional.emit)(ctx, 'keypress', event);
  1121. }
  1122. })
  1123. };
  1124. var inheritData = (0, _functional.inherit)(ctx);
  1125. inheritData.attrs = undefined;
  1126. return h("div", (0, _babelHelperVueJsxMergeProps.default)([{
  1127. "class": bem({
  1128. 'show-action': props.showAction
  1129. }),
  1130. "style": {
  1131. background: props.background
  1132. }
  1133. }, inheritData]), [slots.left == null ? void 0 : slots.left(), h("div", {
  1134. "class": bem('content', props.shape)
  1135. }, [Label(), h(_field.default, (0, _babelHelperVueJsxMergeProps.default)([{
  1136. "attrs": {
  1137. "type": "search",
  1138. "border": false,
  1139. "value": props.value,
  1140. "leftIcon": props.leftIcon,
  1141. "rightIcon": props.rightIcon,
  1142. "clearable": props.clearable,
  1143. "clearTrigger": props.clearTrigger
  1144. },
  1145. "scopedSlots": {
  1146. 'left-icon': slots['left-icon'],
  1147. 'right-icon': slots['right-icon']
  1148. }
  1149. }, fieldData]))]), Action()]);
  1150. }
  1151. Search.props = {
  1152. value: String,
  1153. label: String,
  1154. rightIcon: String,
  1155. actionText: String,
  1156. background: String,
  1157. showAction: Boolean,
  1158. clearTrigger: String,
  1159. shape: {
  1160. type: String,
  1161. default: 'square'
  1162. },
  1163. clearable: {
  1164. type: Boolean,
  1165. default: true
  1166. },
  1167. leftIcon: {
  1168. type: String,
  1169. default: 'search'
  1170. }
  1171. };
  1172. var _default = createComponent(Search);
  1173. exports.default = _default;
  1174. /***/ }),
  1175. /***/ 22:
  1176. /***/ (function(module, exports, __webpack_require__) {
  1177. var content = __webpack_require__(23);
  1178. if(typeof content === 'string') content = [[module.i, content, '']];
  1179. var transform;
  1180. var insertInto;
  1181. var options = {"hmr":true}
  1182. options.transform = transform
  1183. options.insertInto = undefined;
  1184. var update = __webpack_require__(6)(content, options);
  1185. if(content.locals) module.exports = content.locals;
  1186. if(false) {}
  1187. /***/ }),
  1188. /***/ 23:
  1189. /***/ (function(module, exports, __webpack_require__) {
  1190. exports = module.exports = __webpack_require__(5)(false);
  1191. // Module
  1192. exports.push([module.i, "html{-webkit-tap-highlight-color:transparent}body{margin:0;font-family:-apple-system,BlinkMacSystemFont,'Helvetica Neue',Helvetica,Segoe UI,Arial,Roboto,'PingFang SC',miui,'Hiragino Sans GB','Microsoft Yahei',sans-serif}a{text-decoration:none}button,input,textarea{color:inherit;font:inherit}[class*=van-]:focus,a:focus,button:focus,input:focus,textarea:focus{outline:0}ol,ul{margin:0;padding:0;list-style:none}.van-ellipsis{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.van-multi-ellipsis--l2{display:-webkit-box;overflow:hidden;text-overflow:ellipsis;-webkit-line-clamp:2;-webkit-box-orient:vertical}.van-multi-ellipsis--l3{display:-webkit-box;overflow:hidden;text-overflow:ellipsis;-webkit-line-clamp:3;-webkit-box-orient:vertical}.van-clearfix::after{display:table;clear:both;content:''}[class*=van-hairline]::after{position:absolute;box-sizing:border-box;content:' ';pointer-events:none;top:-50%;right:-50%;bottom:-50%;left:-50%;border:0 solid #ebedf0;-webkit-transform:scale(.5);transform:scale(.5)}.van-hairline,.van-hairline--bottom,.van-hairline--left,.van-hairline--right,.van-hairline--surround,.van-hairline--top,.van-hairline--top-bottom{position:relative}.van-hairline--top::after{border-top-width:1px}.van-hairline--left::after{border-left-width:1px}.van-hairline--right::after{border-right-width:1px}.van-hairline--bottom::after{border-bottom-width:1px}.van-hairline--top-bottom::after,.van-hairline-unset--top-bottom::after{border-width:1px 0}.van-hairline--surround::after{border-width:1px}@-webkit-keyframes van-slide-up-enter{from{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}@keyframes van-slide-up-enter{from{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}@-webkit-keyframes van-slide-up-leave{to{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}@keyframes van-slide-up-leave{to{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}@-webkit-keyframes van-slide-down-enter{from{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}@keyframes van-slide-down-enter{from{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}@-webkit-keyframes van-slide-down-leave{to{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}@keyframes van-slide-down-leave{to{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}@-webkit-keyframes van-slide-left-enter{from{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}@keyframes van-slide-left-enter{from{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}@-webkit-keyframes van-slide-left-leave{to{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}@keyframes van-slide-left-leave{to{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}@-webkit-keyframes van-slide-right-enter{from{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}@keyframes van-slide-right-enter{from{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}@-webkit-keyframes van-slide-right-leave{to{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}@keyframes van-slide-right-leave{to{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}@-webkit-keyframes van-fade-in{from{opacity:0}to{opacity:1}}@keyframes van-fade-in{from{opacity:0}to{opacity:1}}@-webkit-keyframes van-fade-out{from{opacity:1}to{opacity:0}}@keyframes van-fade-out{from{opacity:1}to{opacity:0}}@-webkit-keyframes van-rotate{from{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes van-rotate{from{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.van-fade-enter-active{-webkit-animation:.3s van-fade-in both ease-out;animation:.3s van-fade-in both ease-out}.van-fade-leave-active{-webkit-animation:.3s van-fade-out both ease-in;animation:.3s van-fade-out both ease-in
  1193. /***/ }),
  1194. /***/ 24:
  1195. /***/ (function(module, exports, __webpack_require__) {
  1196. "use strict";
  1197. exports.__esModule = true;
  1198. exports.createNamespace = createNamespace;
  1199. var _bem = __webpack_require__(25);
  1200. var _component = __webpack_require__(26);
  1201. var _i18n = __webpack_require__(29);
  1202. function createNamespace(name) {
  1203. name = 'van-' + name;
  1204. return [(0, _component.createComponent)(name), (0, _bem.createBEM)(name), (0, _i18n.createI18N)(name)];
  1205. }
  1206. /***/ }),
  1207. /***/ 25:
  1208. /***/ (function(module, exports, __webpack_require__) {
  1209. "use strict";
  1210. exports.__esModule = true;
  1211. exports.createBEM = createBEM;
  1212. /**
  1213. * bem helper
  1214. * b() // 'button'
  1215. * b('text') // 'button__text'
  1216. * b({ disabled }) // 'button button--disabled'
  1217. * b('text', { disabled }) // 'button__text button__text--disabled'
  1218. * b(['disabled', 'primary']) // 'button button--disabled button--primary'
  1219. */
  1220. function gen(name, mods) {
  1221. if (!mods) {
  1222. return '';
  1223. }
  1224. if (typeof mods === 'string') {
  1225. return " " + name + "--" + mods;
  1226. }
  1227. if (Array.isArray(mods)) {
  1228. return mods.reduce(function (ret, item) {
  1229. return ret + gen(name, item);
  1230. }, '');
  1231. }
  1232. return Object.keys(mods).reduce(function (ret, key) {
  1233. return ret + (mods[key] ? gen(name, key) : '');
  1234. }, '');
  1235. }
  1236. function createBEM(name) {
  1237. return function (el, mods) {
  1238. if (el && typeof el !== 'string') {
  1239. mods = el;
  1240. el = '';
  1241. }
  1242. el = el ? name + "__" + el : name;
  1243. return "" + el + gen(el, mods);
  1244. };
  1245. }
  1246. /***/ }),
  1247. /***/ 26:
  1248. /***/ (function(module, exports, __webpack_require__) {
  1249. "use strict";
  1250. var _interopRequireDefault = __webpack_require__(1);
  1251. exports.__esModule = true;
  1252. exports.unifySlots = unifySlots;
  1253. exports.createComponent = createComponent;
  1254. __webpack_require__(11);
  1255. var _ = __webpack_require__(0);
  1256. var _string = __webpack_require__(9);
  1257. var _slots = __webpack_require__(28);
  1258. var _vue = _interopRequireDefault(__webpack_require__(4));
  1259. /**
  1260. * Create a basic component with common options
  1261. */
  1262. function install(Vue) {
  1263. var name = this.name;
  1264. Vue.component(name, this);
  1265. Vue.component((0, _string.camelize)("-" + name), this);
  1266. } // unify slots & scopedSlots
  1267. function unifySlots(context) {
  1268. // use data.scopedSlots in lower Vue version
  1269. var scopedSlots = context.scopedSlots || context.data.scopedSlots || {};
  1270. var slots = context.slots();
  1271. Object.keys(slots).forEach(function (key) {
  1272. if (!scopedSlots[key]) {
  1273. scopedSlots[key] = function () {
  1274. return slots[key];
  1275. };
  1276. }
  1277. });
  1278. return scopedSlots;
  1279. } // should be removed after Vue 3
  1280. function transformFunctionComponent(pure) {
  1281. return {
  1282. functional: true,
  1283. props: pure.props,
  1284. model: pure.model,
  1285. render: function render(h, context) {
  1286. return pure(h, context.props, unifySlots(context), context);
  1287. }
  1288. };
  1289. }
  1290. function createComponent(name) {
  1291. return function (sfc) {
  1292. if ((0, _.isFunction)(sfc)) {
  1293. sfc = transformFunctionComponent(sfc);
  1294. }
  1295. if (!sfc.functional) {
  1296. sfc.mixins = sfc.mixins || [];
  1297. sfc.mixins.push(_slots.SlotsMixin);
  1298. }
  1299. sfc.name = name;
  1300. sfc.install = install;
  1301. return sfc;
  1302. };
  1303. }
  1304. /***/ }),
  1305. /***/ 27:
  1306. /***/ (function(module, exports, __webpack_require__) {
  1307. "use strict";
  1308. exports.__esModule = true;
  1309. exports.default = void 0;
  1310. var _default = {
  1311. name: '姓名',
  1312. tel: '电话',
  1313. save: '保存',
  1314. confirm: '确认',
  1315. cancel: '取消',
  1316. delete: '删除',
  1317. complete: '完成',
  1318. loading: '加载中...',
  1319. telEmpty: '请填写电话',
  1320. nameEmpty: '请填写姓名',
  1321. nameInvalid: '请输入正确的姓名',
  1322. confirmDelete: '确定要删除吗',
  1323. telInvalid: '请输入正确的手机号',
  1324. vanCalendar: {
  1325. end: '结束',
  1326. start: '开始',
  1327. title: '日期选择',
  1328. confirm: '确定',
  1329. startEnd: '开始/结束',
  1330. weekdays: ['日', '一', '二', '三', '四', '五', '六'],
  1331. monthTitle: function monthTitle(year, month) {
  1332. return year + "\u5E74" + month + "\u6708";
  1333. },
  1334. rangePrompt: function rangePrompt(maxRange) {
  1335. return "\u9009\u62E9\u5929\u6570\u4E0D\u80FD\u8D85\u8FC7 " + maxRange + " \u5929";
  1336. }
  1337. },
  1338. vanCascader: {
  1339. select: '请选择'
  1340. },
  1341. vanContactCard: {
  1342. addText: '添加联系人'
  1343. },
  1344. vanContactList: {
  1345. addText: '新建联系人'
  1346. },
  1347. vanPagination: {
  1348. prev: '上一页',
  1349. next: '下一页'
  1350. },
  1351. vanPullRefresh: {
  1352. pulling: '下拉即可刷新...',
  1353. loosing: '释放即可刷新...'
  1354. },
  1355. vanSubmitBar: {
  1356. label: '合计:'
  1357. },
  1358. vanCoupon: {
  1359. unlimited: '无使用门槛',
  1360. discount: function discount(_discount) {
  1361. return _discount + "\u6298";
  1362. },
  1363. condition: function condition(_condition) {
  1364. return "\u6EE1" + _condition + "\u5143\u53EF\u7528";
  1365. }
  1366. },
  1367. vanCouponCell: {
  1368. title: '优惠券',
  1369. tips: '暂无可用',
  1370. count: function count(_count) {
  1371. return _count + "\u5F20\u53EF\u7528";
  1372. }
  1373. },
  1374. vanCouponList: {
  1375. empty: '暂无优惠券',
  1376. exchange: '兑换',
  1377. close: '不使用优惠券',
  1378. enable: '可用',
  1379. disabled: '不可用',
  1380. placeholder: '请输入优惠码'
  1381. },
  1382. vanAddressEdit: {
  1383. area: '地区',
  1384. postal: '邮政编码',
  1385. areaEmpty: '请选择地区',
  1386. addressEmpty: '请填写详细地址',
  1387. postalEmpty: '邮政编码格式不正确',
  1388. defaultAddress: '设为默认收货地址',
  1389. telPlaceholder: '收货人手机号',
  1390. namePlaceholder: '收货人姓名',
  1391. areaPlaceholder: '选择省 / 市 / 区'
  1392. },
  1393. vanAddressEditDetail: {
  1394. label: '详细地址',
  1395. placeholder: '街道门牌、楼层房间号等信息'
  1396. },
  1397. vanAddressList: {
  1398. add: '新增地址'
  1399. }
  1400. };
  1401. exports.default = _default;
  1402. /***/ }),
  1403. /***/ 28:
  1404. /***/ (function(module, exports, __webpack_require__) {
  1405. "use strict";
  1406. exports.__esModule = true;
  1407. exports.SlotsMixin = void 0;
  1408. /**
  1409. * Use scopedSlots in Vue 2.6+
  1410. * downgrade to slots in lower version
  1411. */
  1412. var SlotsMixin = {
  1413. methods: {
  1414. slots: function slots(name, props) {
  1415. if (name === void 0) {
  1416. name = 'default';
  1417. }
  1418. var $slots = this.$slots,
  1419. $scopedSlots = this.$scopedSlots;
  1420. var scopedSlot = $scopedSlots[name];
  1421. if (scopedSlot) {
  1422. return scopedSlot(props);
  1423. }
  1424. return $slots[name];
  1425. }
  1426. }
  1427. };
  1428. exports.SlotsMixin = SlotsMixin;
  1429. /***/ }),
  1430. /***/ 29:
  1431. /***/ (function(module, exports, __webpack_require__) {
  1432. "use strict";
  1433. var _interopRequireDefault = __webpack_require__(1);
  1434. exports.__esModule = true;
  1435. exports.createI18N = createI18N;
  1436. var _ = __webpack_require__(0);
  1437. var _string = __webpack_require__(9);
  1438. var _locale = _interopRequireDefault(__webpack_require__(11));
  1439. function createI18N(name) {
  1440. var prefix = (0, _string.camelize)(name) + '.';
  1441. return function (path) {
  1442. var messages = _locale.default.messages();
  1443. var message = (0, _.get)(messages, prefix + path) || (0, _.get)(messages, path);
  1444. for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
  1445. args[_key - 1] = arguments[_key];
  1446. }
  1447. return (0, _.isFunction)(message) ? message.apply(void 0, args) : message;
  1448. };
  1449. }
  1450. /***/ }),
  1451. /***/ 30:
  1452. /***/ (function(module, exports, __webpack_require__) {
  1453. "use strict";
  1454. exports.__esModule = true;
  1455. exports.on = on;
  1456. exports.off = off;
  1457. exports.stopPropagation = stopPropagation;
  1458. exports.preventDefault = preventDefault;
  1459. exports.supportsPassive = void 0;
  1460. var _ = __webpack_require__(0);
  1461. // eslint-disable-next-line import/no-mutable-exports
  1462. var supportsPassive = false;
  1463. exports.supportsPassive = supportsPassive;
  1464. if (!_.isServer) {
  1465. try {
  1466. var opts = {};
  1467. Object.defineProperty(opts, 'passive', {
  1468. // eslint-disable-next-line getter-return
  1469. get: function get() {
  1470. /* istanbul ignore next */
  1471. exports.supportsPassive = supportsPassive = true;
  1472. }
  1473. });
  1474. window.addEventListener('test-passive', null, opts); // eslint-disable-next-line no-empty
  1475. } catch (e) {}
  1476. }
  1477. function on(target, event, handler, passive) {
  1478. if (passive === void 0) {
  1479. passive = false;
  1480. }
  1481. if (!_.isServer) {
  1482. target.addEventListener(event, handler, supportsPassive ? {
  1483. capture: false,
  1484. passive: passive
  1485. } : false);
  1486. }
  1487. }
  1488. function off(target, event, handler) {
  1489. if (!_.isServer) {
  1490. target.removeEventListener(event, handler);
  1491. }
  1492. }
  1493. function stopPropagation(event) {
  1494. event.stopPropagation();
  1495. }
  1496. function preventDefault(event, isStopPropagation) {
  1497. /* istanbul ignore else */
  1498. if (typeof event.cancelable !== 'boolean' || event.cancelable) {
  1499. event.preventDefault();
  1500. }
  1501. if (isStopPropagation) {
  1502. stopPropagation(event);
  1503. }
  1504. }
  1505. /***/ }),
  1506. /***/ 35:
  1507. /***/ (function(module, exports, __webpack_require__) {
  1508. "use strict";
  1509. var _interopRequireDefault = __webpack_require__(1);
  1510. exports.__esModule = true;
  1511. exports.default = void 0;
  1512. var _babelHelperVueJsxMergeProps = _interopRequireDefault(__webpack_require__(16));
  1513. var _utils = __webpack_require__(0);
  1514. var _functional = __webpack_require__(14);
  1515. var _info = _interopRequireDefault(__webpack_require__(37));
  1516. // Utils
  1517. // Components
  1518. var _createNamespace = (0, _utils.createNamespace)('icon'),
  1519. createComponent = _createNamespace[0],
  1520. bem = _createNamespace[1];
  1521. function isImage(name) {
  1522. return name ? name.indexOf('/') !== -1 : false;
  1523. } // compatible with legacy usage, should be removed in next major version
  1524. var LEGACY_MAP = {
  1525. medel: 'medal',
  1526. 'medel-o': 'medal-o',
  1527. 'calender-o': 'calendar-o'
  1528. };
  1529. function correctName(name) {
  1530. return name && LEGACY_MAP[name] || name;
  1531. }
  1532. function Icon(h, props, slots, ctx) {
  1533. var _props$badge;
  1534. var name = correctName(props.name);
  1535. var imageIcon = isImage(name);
  1536. if (false) {}
  1537. return h(props.tag, (0, _babelHelperVueJsxMergeProps.default)([{
  1538. "class": [props.classPrefix, imageIcon ? '' : props.classPrefix + "-" + name],
  1539. "style": {
  1540. color: props.color,
  1541. fontSize: (0, _utils.addUnit)(props.size)
  1542. }
  1543. }, (0, _functional.inherit)(ctx, true)]), [slots.default && slots.default(), imageIcon && h("img", {
  1544. "class": bem('image'),
  1545. "attrs": {
  1546. "src": name
  1547. }
  1548. }), h(_info.default, {
  1549. "attrs": {
  1550. "dot": props.dot,
  1551. "info": (_props$badge = props.badge) != null ? _props$badge : props.info
  1552. }
  1553. })]);
  1554. }
  1555. Icon.props = {
  1556. dot: Boolean,
  1557. name: String,
  1558. size: [Number, String],
  1559. // @deprecated
  1560. // should be removed in next major version
  1561. info: [Number, String],
  1562. badge: [Number, String],
  1563. color: String,
  1564. tag: {
  1565. type: String,
  1566. default: 'i'
  1567. },
  1568. classPrefix: {
  1569. type: String,
  1570. default: bem()
  1571. }
  1572. };
  1573. var _default = createComponent(Icon);
  1574. exports.default = _default;
  1575. /***/ }),
  1576. /***/ 360:
  1577. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  1578. "use strict";
  1579. __webpack_require__.r(__webpack_exports__);
  1580. /* harmony import */ var _tisdesign_m_lib_search__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(211);
  1581. /* harmony import */ var _tisdesign_m_lib_search__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_tisdesign_m_lib_search__WEBPACK_IMPORTED_MODULE_0__);
  1582. /* harmony import */ var _tisdesign_m_lib_search_style__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(361);
  1583. /* harmony import */ var _tisdesign_m_lib_search_style__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_tisdesign_m_lib_search_style__WEBPACK_IMPORTED_MODULE_1__);
  1584. _tisdesign_m_lib_search__WEBPACK_IMPORTED_MODULE_0___default.a.name = 'm-search';
  1585. /* harmony default export */ __webpack_exports__["default"] = (_tisdesign_m_lib_search__WEBPACK_IMPORTED_MODULE_0___default.a);
  1586. /***/ }),
  1587. /***/ 361:
  1588. /***/ (function(module, exports, __webpack_require__) {
  1589. __webpack_require__(22);
  1590. __webpack_require__(41);
  1591. __webpack_require__(45);
  1592. __webpack_require__(106);
  1593. __webpack_require__(182);
  1594. __webpack_require__(362);
  1595. /***/ }),
  1596. /***/ 362:
  1597. /***/ (function(module, exports, __webpack_require__) {
  1598. var content = __webpack_require__(363);
  1599. if(typeof content === 'string') content = [[module.i, content, '']];
  1600. var transform;
  1601. var insertInto;
  1602. var options = {"hmr":true}
  1603. options.transform = transform
  1604. options.insertInto = undefined;
  1605. var update = __webpack_require__(6)(content, options);
  1606. if(content.locals) module.exports = content.locals;
  1607. if(false) {}
  1608. /***/ }),
  1609. /***/ 363:
  1610. /***/ (function(module, exports, __webpack_require__) {
  1611. exports = module.exports = __webpack_require__(5)(false);
  1612. // Module
  1613. exports.push([module.i, ".van-search{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-align:center;-webkit-align-items:center;align-items:center;box-sizing:border-box;padding:10px 12px;background-color:#fff}.van-search__content{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-flex:1;-webkit-flex:1;flex:1;padding-left:12px;background-color:#f7f8fa;border-radius:2px}.van-search__content--round{border-radius:999px}.van-search__label{padding:0 5px;color:#323233;font-size:14px;line-height:34px}.van-search .van-cell{-webkit-box-flex:1;-webkit-flex:1;flex:1;padding:5px 8px 5px 0;background-color:transparent}.van-search .van-cell__left-icon{color:#969799}.van-search--show-action{padding-right:0}.van-search input::-webkit-search-cancel-button,.van-search input::-webkit-search-decoration,.van-search input::-webkit-search-results-button,.van-search input::-webkit-search-results-decoration{display:none}.van-search__action{padding:0 8px;color:#323233;font-size:14px;line-height:34px;cursor:pointer;-webkit-user-select:none;user-select:none}.van-search__action:active{background-color:#f2f3f5}", ""]);
  1614. /***/ }),
  1615. /***/ 37:
  1616. /***/ (function(module, exports, __webpack_require__) {
  1617. "use strict";
  1618. var _interopRequireDefault = __webpack_require__(1);
  1619. exports.__esModule = true;
  1620. exports.default = void 0;
  1621. var _babelHelperVueJsxMergeProps = _interopRequireDefault(__webpack_require__(16));
  1622. var _utils = __webpack_require__(0);
  1623. var _functional = __webpack_require__(14);
  1624. // Utils
  1625. var _createNamespace = (0, _utils.createNamespace)('info'),
  1626. createComponent = _createNamespace[0],
  1627. bem = _createNamespace[1];
  1628. function Info(h, props, slots, ctx) {
  1629. var dot = props.dot,
  1630. info = props.info;
  1631. var showInfo = (0, _utils.isDef)(info) && info !== '';
  1632. if (!dot && !showInfo) {
  1633. return;
  1634. }
  1635. return h("div", (0, _babelHelperVueJsxMergeProps.default)([{
  1636. "class": bem({
  1637. dot: dot
  1638. })
  1639. }, (0, _functional.inherit)(ctx, true)]), [dot ? '' : props.info]);
  1640. }
  1641. Info.props = {
  1642. dot: Boolean,
  1643. info: [Number, String]
  1644. };
  1645. var _default = createComponent(Info);
  1646. exports.default = _default;
  1647. /***/ }),
  1648. /***/ 4:
  1649. /***/ (function(module, exports) {
  1650. module.exports = require("vue");
  1651. /***/ }),
  1652. /***/ 41:
  1653. /***/ (function(module, exports, __webpack_require__) {
  1654. var content = __webpack_require__(42);
  1655. if(typeof content === 'string') content = [[module.i, content, '']];
  1656. var transform;
  1657. var insertInto;
  1658. var options = {"hmr":true}
  1659. options.transform = transform
  1660. options.insertInto = undefined;
  1661. var update = __webpack_require__(6)(content, options);
  1662. if(content.locals) module.exports = content.locals;
  1663. if(false) {}
  1664. /***/ }),
  1665. /***/ 42:
  1666. /***/ (function(module, exports, __webpack_require__) {
  1667. exports = module.exports = __webpack_require__(5)(false);
  1668. // Module
  1669. exports.push([module.i, ".van-info{position:absolute;top:0;right:0;box-sizing:border-box;min-width:16px;padding:0 3px;color:#fff;font-weight:500;font-size:12px;font-family:-apple-system-font,Helvetica Neue,Arial,sans-serif;line-height:1.2;text-align:center;background-color:#ffce6d;border:1px solid #fff;border-radius:16px;-webkit-transform:translate(50%,-50%);transform:translate(50%,-50%);-webkit-transform-origin:100%;transform-origin:100%}.van-info--dot{width:8px;min-width:0;height:8px;background-color:#ffce6d;border-radius:100%}", ""]);
  1670. /***/ }),
  1671. /***/ 45:
  1672. /***/ (function(module, exports, __webpack_require__) {
  1673. var content = __webpack_require__(46);
  1674. if(typeof content === 'string') content = [[module.i, content, '']];
  1675. var transform;
  1676. var insertInto;
  1677. var options = {"hmr":true}
  1678. options.transform = transform
  1679. options.insertInto = undefined;
  1680. var update = __webpack_require__(6)(content, options);
  1681. if(content.locals) module.exports = content.locals;
  1682. if(false) {}
  1683. /***/ }),
  1684. /***/ 46:
  1685. /***/ (function(module, exports, __webpack_require__) {
  1686. exports = module.exports = __webpack_require__(5)(false);
  1687. // Module
  1688. exports.push([module.i, "@font-face{font-weight:400;font-family:vant-icon;font-style:normal;font-display:auto;src:url(data:font/ttf;base64,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
  1689. /***/ }),
  1690. /***/ 5:
  1691. /***/ (function(module, exports, __webpack_require__) {
  1692. "use strict";
  1693. /*
  1694. MIT License http://www.opensource.org/licenses/mit-license.php
  1695. Author Tobias Koppers @sokra
  1696. */
  1697. // css base code, injected by the css-loader
  1698. module.exports = function (useSourceMap) {
  1699. var list = []; // return the list of modules as css string
  1700. list.toString = function toString() {
  1701. return this.map(function (item) {
  1702. var content = cssWithMappingToString(item, useSourceMap);
  1703. if (item[2]) {
  1704. return '@media ' + item[2] + '{' + content + '}';
  1705. } else {
  1706. return content;
  1707. }
  1708. }).join('');
  1709. }; // import a list of modules into the list
  1710. list.i = function (modules, mediaQuery) {
  1711. if (typeof modules === 'string') {
  1712. modules = [[null, modules, '']];
  1713. }
  1714. var alreadyImportedModules = {};
  1715. for (var i = 0; i < this.length; i++) {
  1716. var id = this[i][0];
  1717. if (id != null) {
  1718. alreadyImportedModules[id] = true;
  1719. }
  1720. }
  1721. for (i = 0; i < modules.length; i++) {
  1722. var item = modules[i]; // skip already imported module
  1723. // this implementation is not 100% perfect for weird media query combinations
  1724. // when a module is imported multiple times with different media queries.
  1725. // I hope this will never occur (Hey this way we have smaller bundles)
  1726. if (item[0] == null || !alreadyImportedModules[item[0]]) {
  1727. if (mediaQuery && !item[2]) {
  1728. item[2] = mediaQuery;
  1729. } else if (mediaQuery) {
  1730. item[2] = '(' + item[2] + ') and (' + mediaQuery + ')';
  1731. }
  1732. list.push(item);
  1733. }
  1734. }
  1735. };
  1736. return list;
  1737. };
  1738. function cssWithMappingToString(item, useSourceMap) {
  1739. var content = item[1] || '';
  1740. var cssMapping = item[3];
  1741. if (!cssMapping) {
  1742. return content;
  1743. }
  1744. if (useSourceMap && typeof btoa === 'function') {
  1745. var sourceMapping = toComment(cssMapping);
  1746. var sourceURLs = cssMapping.sources.map(function (source) {
  1747. return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */';
  1748. });
  1749. return [content].concat(sourceURLs).concat([sourceMapping]).join('\n');
  1750. }
  1751. return [content].join('\n');
  1752. } // Adapted from convert-source-map (MIT)
  1753. function toComment(sourceMap) {
  1754. // eslint-disable-next-line no-undef
  1755. var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));
  1756. var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64;
  1757. return '/*# ' + data + ' */';
  1758. }
  1759. /***/ }),
  1760. /***/ 53:
  1761. /***/ (function(module, exports, __webpack_require__) {
  1762. "use strict";
  1763. exports.__esModule = true;
  1764. exports.getScroller = getScroller;
  1765. exports.getScrollTop = getScrollTop;
  1766. exports.setScrollTop = setScrollTop;
  1767. exports.getRootScrollTop = getRootScrollTop;
  1768. exports.setRootScrollTop = setRootScrollTop;
  1769. exports.getElementTop = getElementTop;
  1770. exports.getVisibleHeight = getVisibleHeight;
  1771. exports.getVisibleTop = getVisibleTop;
  1772. function isWindow(val) {
  1773. return val === window;
  1774. } // get nearest scroll element
  1775. // https://github.com/youzan/vant/issues/3823
  1776. var overflowScrollReg = /scroll|auto/i;
  1777. function getScroller(el, root) {
  1778. if (root === void 0) {
  1779. root = window;
  1780. }
  1781. var node = el;
  1782. while (node && node.tagName !== 'HTML' && node.tagName !== 'BODY' && node.nodeType === 1 && node !== root) {
  1783. var _window$getComputedSt = window.getComputedStyle(node),
  1784. overflowY = _window$getComputedSt.overflowY;
  1785. if (overflowScrollReg.test(overflowY)) {
  1786. return node;
  1787. }
  1788. node = node.parentNode;
  1789. }
  1790. return root;
  1791. }
  1792. function getScrollTop(el) {
  1793. var top = 'scrollTop' in el ? el.scrollTop : el.pageYOffset; // iOS scroll bounce cause minus scrollTop
  1794. return Math.max(top, 0);
  1795. }
  1796. function setScrollTop(el, value) {
  1797. if ('scrollTop' in el) {
  1798. el.scrollTop = value;
  1799. } else {
  1800. el.scrollTo(el.scrollX, value);
  1801. }
  1802. }
  1803. function getRootScrollTop() {
  1804. return window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 0;
  1805. }
  1806. function setRootScrollTop(value) {
  1807. setScrollTop(window, value);
  1808. setScrollTop(document.body, value);
  1809. } // get distance from element top to page top or scroller top
  1810. function getElementTop(el, scroller) {
  1811. if (isWindow(el)) {
  1812. return 0;
  1813. }
  1814. var scrollTop = scroller ? getScrollTop(scroller) : getRootScrollTop();
  1815. return el.getBoundingClientRect().top + scrollTop;
  1816. }
  1817. function getVisibleHeight(el) {
  1818. if (isWindow(el)) {
  1819. return el.innerHeight;
  1820. }
  1821. return el.getBoundingClientRect().height;
  1822. }
  1823. function getVisibleTop(el) {
  1824. if (isWindow(el)) {
  1825. return 0;
  1826. }
  1827. return el.getBoundingClientRect().top;
  1828. }
  1829. /***/ }),
  1830. /***/ 6:
  1831. /***/ (function(module, exports, __webpack_require__) {
  1832. /*
  1833. MIT License http://www.opensource.org/licenses/mit-license.php
  1834. Author Tobias Koppers @sokra
  1835. */
  1836. var stylesInDom = {};
  1837. var memoize = function (fn) {
  1838. var memo;
  1839. return function () {
  1840. if (typeof memo === "undefined") memo = fn.apply(this, arguments);
  1841. return memo;
  1842. };
  1843. };
  1844. var isOldIE = memoize(function () {
  1845. // Test for IE <= 9 as proposed by Browserhacks
  1846. // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805
  1847. // Tests for existence of standard globals is to allow style-loader
  1848. // to operate correctly into non-standard environments
  1849. // @see https://github.com/webpack-contrib/style-loader/issues/177
  1850. return window && document && document.all && !window.atob;
  1851. });
  1852. var getTarget = function (target, parent) {
  1853. if (parent){
  1854. return parent.querySelector(target);
  1855. }
  1856. return document.querySelector(target);
  1857. };
  1858. var getElement = (function (fn) {
  1859. var memo = {};
  1860. return function(target, parent) {
  1861. // If passing function in options, then use it for resolve "head" element.
  1862. // Useful for Shadow Root style i.e
  1863. // {
  1864. // insertInto: function () { return document.querySelector("#foo").shadowRoot }
  1865. // }
  1866. if (typeof target === 'function') {
  1867. return target();
  1868. }
  1869. if (typeof memo[target] === "undefined") {
  1870. var styleTarget = getTarget.call(this, target, parent);
  1871. // Special case to return head of iframe instead of iframe itself
  1872. if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {
  1873. try {
  1874. // This will throw an exception if access to iframe is blocked
  1875. // due to cross-origin restrictions
  1876. styleTarget = styleTarget.contentDocument.head;
  1877. } catch(e) {
  1878. styleTarget = null;
  1879. }
  1880. }
  1881. memo[target] = styleTarget;
  1882. }
  1883. return memo[target]
  1884. };
  1885. })();
  1886. var singleton = null;
  1887. var singletonCounter = 0;
  1888. var stylesInsertedAtTop = [];
  1889. var fixUrls = __webpack_require__(12);
  1890. module.exports = function(list, options) {
  1891. if (typeof DEBUG !== "undefined" && DEBUG) {
  1892. if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment");
  1893. }
  1894. options = options || {};
  1895. options.attrs = typeof options.attrs === "object" ? options.attrs : {};
  1896. // Force single-tag solution on IE6-9, which has a hard limit on the # of <style>
  1897. // tags it will allow on a page
  1898. if (!options.singleton && typeof options.singleton !== "boolean") options.singleton = isOldIE();
  1899. // By default, add <style> tags to the <head> element
  1900. if (!options.insertInto) options.insertInto = "head";
  1901. // By default, add <style> tags to the bottom of the target
  1902. if (!options.insertAt) options.insertAt = "bottom";
  1903. var styles = listToStyles(list, options);
  1904. addStylesToDom(styles, options);
  1905. return function update (newList) {
  1906. var mayRemove = [];
  1907. for (var i = 0; i < styles.length; i++) {
  1908. var item = styles[i];
  1909. var domStyle = stylesInDom[item.id];
  1910. domStyle.refs--;
  1911. mayRemove.push(domStyle);
  1912. }
  1913. if(newList) {
  1914. var newStyles = listToStyles(newList, options);
  1915. addStylesToDom(newStyles, options);
  1916. }
  1917. for (var i = 0; i < mayRemove.length; i++) {
  1918. var domStyle = mayRemove[i];
  1919. if(domStyle.refs === 0) {
  1920. for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j]();
  1921. delete stylesInDom[domStyle.id];
  1922. }
  1923. }
  1924. };
  1925. };
  1926. function addStylesToDom (styles, options) {
  1927. for (var i = 0; i < styles.length; i++) {
  1928. var item = styles[i];
  1929. var domStyle = stylesInDom[item.id];
  1930. if(domStyle) {
  1931. domStyle.refs++;
  1932. for(var j = 0; j < domStyle.parts.length; j++) {
  1933. domStyle.parts[j](item.parts[j]);
  1934. }
  1935. for(; j < item.parts.length; j++) {
  1936. domStyle.parts.push(addStyle(item.parts[j], options));
  1937. }
  1938. } else {
  1939. var parts = [];
  1940. for(var j = 0; j < item.parts.length; j++) {
  1941. parts.push(addStyle(item.parts[j], options));
  1942. }
  1943. stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts};
  1944. }
  1945. }
  1946. }
  1947. function listToStyles (list, options) {
  1948. var styles = [];
  1949. var newStyles = {};
  1950. for (var i = 0; i < list.length; i++) {
  1951. var item = list[i];
  1952. var id = options.base ? item[0] + options.base : item[0];
  1953. var css = item[1];
  1954. var media = item[2];
  1955. var sourceMap = item[3];
  1956. var part = {css: css, media: media, sourceMap: sourceMap};
  1957. if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]});
  1958. else newStyles[id].parts.push(part);
  1959. }
  1960. return styles;
  1961. }
  1962. function insertStyleElement (options, style) {
  1963. var target = getElement(options.insertInto)
  1964. if (!target) {
  1965. throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid.");
  1966. }
  1967. var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1];
  1968. if (options.insertAt === "top") {
  1969. if (!lastStyleElementInsertedAtTop) {
  1970. target.insertBefore(style, target.firstChild);
  1971. } else if (lastStyleElementInsertedAtTop.nextSibling) {
  1972. target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling);
  1973. } else {
  1974. target.appendChild(style);
  1975. }
  1976. stylesInsertedAtTop.push(style);
  1977. } else if (options.insertAt === "bottom") {
  1978. target.appendChild(style);
  1979. } else if (typeof options.insertAt === "object" && options.insertAt.before) {
  1980. var nextSibling = getElement(options.insertAt.before, target);
  1981. target.insertBefore(style, nextSibling);
  1982. } else {
  1983. throw new Error("[Style Loader]\n\n Invalid value for parameter 'insertAt' ('options.insertAt') found.\n Must be 'top', 'bottom', or Object.\n (https://github.com/webpack-contrib/style-loader#insertat)\n");
  1984. }
  1985. }
  1986. function removeStyleElement (style) {
  1987. if (style.parentNode === null) return false;
  1988. style.parentNode.removeChild(style);
  1989. var idx = stylesInsertedAtTop.indexOf(style);
  1990. if(idx >= 0) {
  1991. stylesInsertedAtTop.splice(idx, 1);
  1992. }
  1993. }
  1994. function createStyleElement (options) {
  1995. var style = document.createElement("style");
  1996. if(options.attrs.type === undefined) {
  1997. options.attrs.type = "text/css";
  1998. }
  1999. if(options.attrs.nonce === undefined) {
  2000. var nonce = getNonce();
  2001. if (nonce) {
  2002. options.attrs.nonce = nonce;
  2003. }
  2004. }
  2005. addAttrs(style, options.attrs);
  2006. insertStyleElement(options, style);
  2007. return style;
  2008. }
  2009. function createLinkElement (options) {
  2010. var link = document.createElement("link");
  2011. if(options.attrs.type === undefined) {
  2012. options.attrs.type = "text/css";
  2013. }
  2014. options.attrs.rel = "stylesheet";
  2015. addAttrs(link, options.attrs);
  2016. insertStyleElement(options, link);
  2017. return link;
  2018. }
  2019. function addAttrs (el, attrs) {
  2020. Object.keys(attrs).forEach(function (key) {
  2021. el.setAttribute(key, attrs[key]);
  2022. });
  2023. }
  2024. function getNonce() {
  2025. if (false) {}
  2026. return __webpack_require__.nc;
  2027. }
  2028. function addStyle (obj, options) {
  2029. var style, update, remove, result;
  2030. // If a transform function was defined, run it on the css
  2031. if (options.transform && obj.css) {
  2032. result = typeof options.transform === 'function'
  2033. ? options.transform(obj.css)
  2034. : options.transform.default(obj.css);
  2035. if (result) {
  2036. // If transform returns a value, use that instead of the original css.
  2037. // This allows running runtime transformations on the css.
  2038. obj.css = result;
  2039. } else {
  2040. // If the transform function returns a falsy value, don't add this css.
  2041. // This allows conditional loading of css
  2042. return function() {
  2043. // noop
  2044. };
  2045. }
  2046. }
  2047. if (options.singleton) {
  2048. var styleIndex = singletonCounter++;
  2049. style = singleton || (singleton = createStyleElement(options));
  2050. update = applyToSingletonTag.bind(null, style, styleIndex, false);
  2051. remove = applyToSingletonTag.bind(null, style, styleIndex, true);
  2052. } else if (
  2053. obj.sourceMap &&
  2054. typeof URL === "function" &&
  2055. typeof URL.createObjectURL === "function" &&
  2056. typeof URL.revokeObjectURL === "function" &&
  2057. typeof Blob === "function" &&
  2058. typeof btoa === "function"
  2059. ) {
  2060. style = createLinkElement(options);
  2061. update = updateLink.bind(null, style, options);
  2062. remove = function () {
  2063. removeStyleElement(style);
  2064. if(style.href) URL.revokeObjectURL(style.href);
  2065. };
  2066. } else {
  2067. style = createStyleElement(options);
  2068. update = applyToTag.bind(null, style);
  2069. remove = function () {
  2070. removeStyleElement(style);
  2071. };
  2072. }
  2073. update(obj);
  2074. return function updateStyle (newObj) {
  2075. if (newObj) {
  2076. if (
  2077. newObj.css === obj.css &&
  2078. newObj.media === obj.media &&
  2079. newObj.sourceMap === obj.sourceMap
  2080. ) {
  2081. return;
  2082. }
  2083. update(obj = newObj);
  2084. } else {
  2085. remove();
  2086. }
  2087. };
  2088. }
  2089. var replaceText = (function () {
  2090. var textStore = [];
  2091. return function (index, replacement) {
  2092. textStore[index] = replacement;
  2093. return textStore.filter(Boolean).join('\n');
  2094. };
  2095. })();
  2096. function applyToSingletonTag (style, index, remove, obj) {
  2097. var css = remove ? "" : obj.css;
  2098. if (style.styleSheet) {
  2099. style.styleSheet.cssText = replaceText(index, css);
  2100. } else {
  2101. var cssNode = document.createTextNode(css);
  2102. var childNodes = style.childNodes;
  2103. if (childNodes[index]) style.removeChild(childNodes[index]);
  2104. if (childNodes.length) {
  2105. style.insertBefore(cssNode, childNodes[index]);
  2106. } else {
  2107. style.appendChild(cssNode);
  2108. }
  2109. }
  2110. }
  2111. function applyToTag (style, obj) {
  2112. var css = obj.css;
  2113. var media = obj.media;
  2114. if(media) {
  2115. style.setAttribute("media", media)
  2116. }
  2117. if(style.styleSheet) {
  2118. style.styleSheet.cssText = css;
  2119. } else {
  2120. while(style.firstChild) {
  2121. style.removeChild(style.firstChild);
  2122. }
  2123. style.appendChild(document.createTextNode(css));
  2124. }
  2125. }
  2126. function updateLink (link, options, obj) {
  2127. var css = obj.css;
  2128. var sourceMap = obj.sourceMap;
  2129. /*
  2130. If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled
  2131. and there is no publicPath defined then lets turn convertToAbsoluteUrls
  2132. on by default. Otherwise default to the convertToAbsoluteUrls option
  2133. directly
  2134. */
  2135. var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap;
  2136. if (options.convertToAbsoluteUrls || autoFixUrls) {
  2137. css = fixUrls(css);
  2138. }
  2139. if (sourceMap) {
  2140. // http://stackoverflow.com/a/26603875
  2141. css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */";
  2142. }
  2143. var blob = new Blob([css], { type: "text/css" });
  2144. var oldSrc = link.href;
  2145. link.href = URL.createObjectURL(blob);
  2146. if(oldSrc) URL.revokeObjectURL(oldSrc);
  2147. }
  2148. /***/ }),
  2149. /***/ 69:
  2150. /***/ (function(module, exports, __webpack_require__) {
  2151. "use strict";
  2152. exports.__esModule = true;
  2153. exports.route = route;
  2154. exports.functionalRoute = functionalRoute;
  2155. exports.routeProps = void 0;
  2156. /**
  2157. * Vue Router support
  2158. */
  2159. function isRedundantNavigation(err) {
  2160. return err.name === 'NavigationDuplicated' || // compatible with vue-router@3.3
  2161. err.message && err.message.indexOf('redundant navigation') !== -1;
  2162. }
  2163. function route(router, config) {
  2164. var to = config.to,
  2165. url = config.url,
  2166. replace = config.replace;
  2167. if (to && router) {
  2168. var promise = router[replace ? 'replace' : 'push'](to);
  2169. /* istanbul ignore else */
  2170. if (promise && promise.catch) {
  2171. promise.catch(function (err) {
  2172. if (err && !isRedundantNavigation(err)) {
  2173. throw err;
  2174. }
  2175. });
  2176. }
  2177. } else if (url) {
  2178. replace ? location.replace(url) : location.href = url;
  2179. }
  2180. }
  2181. function functionalRoute(context) {
  2182. route(context.parent && context.parent.$router, context.props);
  2183. }
  2184. var routeProps = {
  2185. url: String,
  2186. replace: Boolean,
  2187. to: [String, Object]
  2188. };
  2189. exports.routeProps = routeProps;
  2190. /***/ }),
  2191. /***/ 81:
  2192. /***/ (function(module, exports, __webpack_require__) {
  2193. "use strict";
  2194. exports.__esModule = true;
  2195. exports.range = range;
  2196. exports.formatNumber = formatNumber;
  2197. function range(num, min, max) {
  2198. return Math.min(Math.max(num, min), max);
  2199. }
  2200. function trimExtraChar(value, _char, regExp) {
  2201. var index = value.indexOf(_char);
  2202. if (index === -1) {
  2203. return value;
  2204. }
  2205. if (_char === '-' && index !== 0) {
  2206. return value.slice(0, index);
  2207. }
  2208. return value.slice(0, index + 1) + value.slice(index).replace(regExp, '');
  2209. }
  2210. function formatNumber(value, allowDot, allowMinus) {
  2211. if (allowDot === void 0) {
  2212. allowDot = true;
  2213. }
  2214. if (allowMinus === void 0) {
  2215. allowMinus = true;
  2216. }
  2217. if (allowDot) {
  2218. value = trimExtraChar(value, '.', /\./g);
  2219. } else {
  2220. value = value.split('.')[0];
  2221. }
  2222. if (allowMinus) {
  2223. value = trimExtraChar(value, '-', /-/g);
  2224. } else {
  2225. value = value.replace(/-/, '');
  2226. }
  2227. var regExp = allowDot ? /[^-0-9.]/g : /[^-0-9]/g;
  2228. return value.replace(regExp, '');
  2229. }
  2230. /***/ }),
  2231. /***/ 9:
  2232. /***/ (function(module, exports, __webpack_require__) {
  2233. "use strict";
  2234. exports.__esModule = true;
  2235. exports.camelize = camelize;
  2236. exports.padZero = padZero;
  2237. var camelizeRE = /-(\w)/g;
  2238. function camelize(str) {
  2239. return str.replace(camelizeRE, function (_, c) {
  2240. return c.toUpperCase();
  2241. });
  2242. }
  2243. function padZero(num, targetLength) {
  2244. if (targetLength === void 0) {
  2245. targetLength = 2;
  2246. }
  2247. var str = num + '';
  2248. while (str.length < targetLength) {
  2249. str = '0' + str;
  2250. }
  2251. return str;
  2252. }
  2253. /***/ }),
  2254. /***/ 96:
  2255. /***/ (function(module, exports, __webpack_require__) {
  2256. "use strict";
  2257. exports.__esModule = true;
  2258. exports.cellProps = void 0;
  2259. var cellProps = {
  2260. icon: String,
  2261. size: String,
  2262. center: Boolean,
  2263. isLink: Boolean,
  2264. required: Boolean,
  2265. clickable: Boolean,
  2266. iconPrefix: String,
  2267. titleStyle: null,
  2268. titleClass: null,
  2269. valueClass: null,
  2270. labelClass: null,
  2271. title: [Number, String],
  2272. value: [Number, String],
  2273. label: [Number, String],
  2274. arrowDirection: String,
  2275. border: {
  2276. type: Boolean,
  2277. default: true
  2278. }
  2279. };
  2280. exports.cellProps = cellProps;
  2281. /***/ }),
  2282. /***/ 97:
  2283. /***/ (function(module, exports, __webpack_require__) {
  2284. "use strict";
  2285. var _interopRequireDefault = __webpack_require__(1);
  2286. exports.__esModule = true;
  2287. exports.default = void 0;
  2288. var _extends2 = _interopRequireDefault(__webpack_require__(18));
  2289. var _babelHelperVueJsxMergeProps = _interopRequireDefault(__webpack_require__(16));
  2290. var _utils = __webpack_require__(0);
  2291. var _functional = __webpack_require__(14);
  2292. var _router = __webpack_require__(69);
  2293. var _shared = __webpack_require__(96);
  2294. var _icon = _interopRequireDefault(__webpack_require__(35));
  2295. // Utils
  2296. // Components
  2297. var _createNamespace = (0, _utils.createNamespace)('cell'),
  2298. createComponent = _createNamespace[0],
  2299. bem = _createNamespace[1];
  2300. function Cell(h, props, slots, ctx) {
  2301. var icon = props.icon,
  2302. size = props.size,
  2303. title = props.title,
  2304. label = props.label,
  2305. value = props.value,
  2306. isLink = props.isLink;
  2307. var showTitle = slots.title || (0, _utils.isDef)(title);
  2308. function Label() {
  2309. var showLabel = slots.label || (0, _utils.isDef)(label);
  2310. if (showLabel) {
  2311. return h("div", {
  2312. "class": [bem('label'), props.labelClass]
  2313. }, [slots.label ? slots.label() : label]);
  2314. }
  2315. }
  2316. function Title() {
  2317. if (showTitle) {
  2318. return h("div", {
  2319. "class": [bem('title'), props.titleClass],
  2320. "style": props.titleStyle
  2321. }, [slots.title ? slots.title() : h("span", [title]), Label()]);
  2322. }
  2323. }
  2324. function Value() {
  2325. var showValue = slots.default || (0, _utils.isDef)(value);
  2326. if (showValue) {
  2327. return h("div", {
  2328. "class": [bem('value', {
  2329. alone: !showTitle
  2330. }), props.valueClass]
  2331. }, [slots.default ? slots.default() : h("span", [value])]);
  2332. }
  2333. }
  2334. function LeftIcon() {
  2335. if (slots.icon) {
  2336. return slots.icon();
  2337. }
  2338. if (icon) {
  2339. return h(_icon.default, {
  2340. "class": bem('left-icon'),
  2341. "attrs": {
  2342. "name": icon,
  2343. "classPrefix": props.iconPrefix
  2344. }
  2345. });
  2346. }
  2347. }
  2348. function RightIcon() {
  2349. var rightIconSlot = slots['right-icon'];
  2350. if (rightIconSlot) {
  2351. return rightIconSlot();
  2352. }
  2353. if (isLink) {
  2354. var arrowDirection = props.arrowDirection;
  2355. return h(_icon.default, {
  2356. "class": bem('right-icon'),
  2357. "attrs": {
  2358. "name": arrowDirection ? "arrow-" + arrowDirection : 'arrow'
  2359. }
  2360. });
  2361. }
  2362. }
  2363. function onClick(event) {
  2364. (0, _functional.emit)(ctx, 'click', event);
  2365. (0, _router.functionalRoute)(ctx);
  2366. }
  2367. var clickable = isLink || props.clickable;
  2368. var classes = {
  2369. clickable: clickable,
  2370. center: props.center,
  2371. required: props.required,
  2372. borderless: !props.border
  2373. };
  2374. if (size) {
  2375. classes[size] = size;
  2376. }
  2377. return h("div", (0, _babelHelperVueJsxMergeProps.default)([{
  2378. "class": bem(classes),
  2379. "attrs": {
  2380. "role": clickable ? 'button' : null,
  2381. "tabindex": clickable ? 0 : null
  2382. },
  2383. "on": {
  2384. "click": onClick
  2385. }
  2386. }, (0, _functional.inherit)(ctx)]), [LeftIcon(), Title(), Value(), RightIcon(), slots.extra == null ? void 0 : slots.extra()]);
  2387. }
  2388. Cell.props = (0, _extends2.default)({}, _shared.cellProps, _router.routeProps);
  2389. var _default = createComponent(Cell);
  2390. exports.default = _default;
  2391. /***/ })
  2392. /******/ });