This commit is contained in:
2024-12-19 09:00:30 +08:00
parent 80226cc657
commit db5c4b08ff
19 changed files with 1592 additions and 108 deletions

42
dist/app.js vendored
View File

@@ -9,6 +9,7 @@ require("./prebundle/vendors-node_modules_taro_weapp_prebundle_redux-logger_js.j
require("./prebundle/vendors-node_modules_taro_weapp_prebundle_redux_js.js");
require("./prebundle/vendors-node_modules_taro_weapp_prebundle_tarojs_plugin-platform-weapp_dist_runtime_js.js");
require("./prebundle/node_modules_taro_weapp_prebundle_tarojs_runtime_js.js");
require("./prebundle/vendors-node_modules_taro_weapp_prebundle_tarojs_plugin-html_dist_runtime_js.js");
require("./prebundle/vendors-node_modules_taro_weapp_prebundle_tarojs_taro_js.js");
require("./prebundle/remoteEntry.js");
require("./prebundle/node_modules_taro_weapp_prebundle_react_jsx-runtime_js.js");
@@ -67,17 +68,20 @@ class App extends react__WEBPACK_IMPORTED_MODULE_0__.Component {
/* harmony import */ var _tarojs_plugin_platform_weapp_dist_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tarojs/plugin-platform-weapp/dist/runtime */ "webpack/container/remote/@tarojs/plugin-platform-weapp/dist/runtime");
/* harmony import */ var _tarojs_plugin_platform_weapp_dist_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_tarojs_plugin_platform_weapp_dist_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _tarojs_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @tarojs/runtime */ "webpack/container/remote/@tarojs/runtime");
/* harmony import */ var _tarojs_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_tarojs_runtime__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @tarojs/plugin-framework-react/dist/runtime */ "webpack/container/remote/@tarojs/plugin-framework-react/dist/runtime");
/* harmony import */ var _tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _tarojs_taro__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @tarojs/taro */ "webpack/container/remote/@tarojs/taro");
/* harmony import */ var _tarojs_taro__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_tarojs_taro__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _node_modules_pnpm_tarojs_taro_loader_4_0_8_webpack_5_91_0_swc_core_1_3_96_node_modules_tarojs_taro_loader_lib_entry_cache_js_name_app_app_jsx__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! !!../node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=app!./app.jsx */ "./node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=app!./src/app.jsx");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react */ "webpack/container/remote/react");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! react-dom */ "webpack/container/remote/react-dom");
/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(react_dom__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var _tarojs_plugin_html_dist_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @tarojs/plugin-html/dist/runtime */ "webpack/container/remote/@tarojs/plugin-html/dist/runtime");
/* harmony import */ var _tarojs_plugin_html_dist_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_tarojs_plugin_html_dist_runtime__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _tarojs_runtime__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @tarojs/runtime */ "webpack/container/remote/@tarojs/runtime");
/* harmony import */ var _tarojs_runtime__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_tarojs_runtime__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @tarojs/plugin-framework-react/dist/runtime */ "webpack/container/remote/@tarojs/plugin-framework-react/dist/runtime");
/* harmony import */ var _tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _tarojs_taro__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @tarojs/taro */ "webpack/container/remote/@tarojs/taro");
/* harmony import */ var _tarojs_taro__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_tarojs_taro__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _node_modules_pnpm_tarojs_taro_loader_4_0_8_webpack_5_91_0_swc_core_1_3_96_node_modules_tarojs_taro_loader_lib_entry_cache_js_name_app_app_jsx__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! !!../node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=app!./app.jsx */ "./node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=app!./src/app.jsx");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! react */ "webpack/container/remote/react");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! react-dom */ "webpack/container/remote/react-dom");
/* harmony import */ var react_dom__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(react_dom__WEBPACK_IMPORTED_MODULE_7__);
@@ -90,11 +94,19 @@ class App extends react__WEBPACK_IMPORTED_MODULE_0__.Component {
var config = {"pages":["pages/home/index","pages/index/index"],"window":{"backgroundTextStyle":"light","navigationBarBackgroundColor":"#fff","navigationBarTitleText":"WeChat","navigationBarTextStyle":"black"},"lazyCodeLoading":"requiredComponents"};
_tarojs_runtime__WEBPACK_IMPORTED_MODULE_1__.window.__taroAppConfig = config
var inst = App((0,_tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_2__.createReactApp)(_node_modules_pnpm_tarojs_taro_loader_4_0_8_webpack_5_91_0_swc_core_1_3_96_node_modules_tarojs_taro_loader_lib_entry_cache_js_name_app_app_jsx__WEBPACK_IMPORTED_MODULE_4__["default"], react__WEBPACK_IMPORTED_MODULE_5__, (react_dom__WEBPACK_IMPORTED_MODULE_6___default()), config))
_tarojs_runtime__WEBPACK_IMPORTED_MODULE_2__.window.__taroAppConfig = config
var inst = App((0,_tarojs_plugin_framework_react_dist_runtime__WEBPACK_IMPORTED_MODULE_3__.createReactApp)(_node_modules_pnpm_tarojs_taro_loader_4_0_8_webpack_5_91_0_swc_core_1_3_96_node_modules_tarojs_taro_loader_lib_entry_cache_js_name_app_app_jsx__WEBPACK_IMPORTED_MODULE_5__["default"], react__WEBPACK_IMPORTED_MODULE_6__, (react_dom__WEBPACK_IMPORTED_MODULE_7___default()), config))
;(0,_tarojs_taro__WEBPACK_IMPORTED_MODULE_3__.initPxTransform)({
designWidth: 750,
;(0,_tarojs_taro__WEBPACK_IMPORTED_MODULE_4__.initPxTransform)({
designWidth: function designWidth(input) {
var _input_file;
// 配置 NutUI 375 尺寸
if ((input === null || input === void 0 ? void 0 : (_input_file = input.file) === null || _input_file === void 0 ? void 0 : _input_file.replace(/\\+/g, "/").indexOf("@nutui")) > -1) {
return 375;
}
// 全局使用 Taro 默认的 750 尺寸
return 750;
},
deviceRatio: {"375":2,"640":1.17,"750":1,"828":0.905},
baseFontSize: 20,
unitPrecision: undefined,

2
dist/app.js.map vendored
View File

@@ -1 +1 @@
{"version":3,"file":"app.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;ACpBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;ACrBA;AAEA;AACA;AACA;AAEA;AAAA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;ACrBA;AACA;AAEA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;ACLA;AACA;AACA;AACA;AAEA;AAEA;AAAA;AAIA;AAIA;AACA;AACA;AAEA;AAEA;AACA;AAEA;AACA;AACA;AACA","sources":["webpack://taro-template/._src_app.jsx","webpack://taro-template/./src/app.jsx?b80d","webpack://taro-template/._src_reducers_counter.js","webpack://taro-template/._src_reducers_index.js","webpack://taro-template/._src_store_index.js"],"sourcesContent":["import { Component } from 'react';\nimport { Provider } from 'react-redux';\nimport configStore from './store';\nimport './app.scss';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst store = configStore();\nclass App extends Component {\n componentDidMount() {}\n componentDidShow() {}\n componentDidHide() {}\n\n // 在 App 类中的 render() 函数没有实际作用\n // 请勿修改此函数\n render() {\n return /*#__PURE__*/_jsx(Provider, {\n store: store,\n children: this.props.children\n });\n }\n}\nexport default App;","import '@tarojs/plugin-platform-weapp/dist/runtime'\n\nimport { window } from '@tarojs/runtime'\nimport { createReactApp } from '@tarojs/plugin-framework-react/dist/runtime'\nimport { initPxTransform } from '@tarojs/taro'\n\nimport component from \"!!../node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=app!./app.jsx\"\n\nimport * as React from 'react'\nimport ReactDOM from 'react-dom'\n\nvar config = {\"pages\":[\"pages/home/index\",\"pages/index/index\"],\"window\":{\"backgroundTextStyle\":\"light\",\"navigationBarBackgroundColor\":\"#fff\",\"navigationBarTitleText\":\"WeChat\",\"navigationBarTextStyle\":\"black\"},\"lazyCodeLoading\":\"requiredComponents\"};\nwindow.__taroAppConfig = config\nvar inst = App(createReactApp(component, React, ReactDOM, config))\n\ninitPxTransform({\n designWidth: 750,\n deviceRatio: {\"375\":2,\"640\":1.17,\"750\":1,\"828\":0.905},\n baseFontSize: 20,\n unitPrecision: undefined,\n targetUnit: undefined\n})\n","import { ADD, MINUS } from '../constants/counter'\n\nconst INITIAL_STATE = {\n num: 0\n}\n\nexport default function counter (state = INITIAL_STATE, action) {\n switch (action.type) {\n case ADD:\n return {\n ...state,\n num: state.num + 1\n }\n case MINUS:\n return {\n ...state,\n num: state.num - 1\n }\n default:\n return state\n }\n}\n","import { combineReducers } from 'redux'\nimport counter from './counter'\n\nexport default combineReducers({\n counter\n})\n","import { legacy_createStore as createStore, applyMiddleware, compose } from 'redux'\nimport thunkMiddleware from 'redux-thunk'\nimport logger from 'redux-logger'\nimport rootReducer from '../reducers'\n\nconst composeEnhancers = typeof window === 'object' && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__\n ? window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__({\n // Specify extensions options like name, actionsBlacklist, actionsCreators, serialize...\n })\n : compose\n\nconst middlewares = [\n thunkMiddleware\n]\n\nif (process.env.NODE_ENV === 'development') {\n middlewares.push(logger)\n}\n\nconst enhancer = composeEnhancers(\n applyMiddleware(...middlewares),\n // other store enhancers if any\n)\n\nexport default function configStore () {\n const store = createStore(rootReducer, enhancer)\n return store\n}\n"],"names":[],"sourceRoot":""}
{"version":3,"sources":[""],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;AAMA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;AAaA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;AAKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}

59
dist/app.wxss vendored
View File

@@ -1,65 +1,6 @@
/*!************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
!*** css ./node_modules/.pnpm/css-loader@7.1.2_webpack@5.91.0_@swc+core@1.3.96_/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].oneOf[0].use[1]!./node_modules/.pnpm/postcss-loader@8.1.1_postcss@8.4.49_typescript@5.7.2_webpack@5.91.0_@swc+core@1.3.96_/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[1].oneOf[0].use[2]!./node_modules/.pnpm/resolve-url-loader@5.0.0/node_modules/resolve-url-loader/index.js!./node_modules/.pnpm/sass-loader@14.2.1_sass@1.83.0_webpack@5.91.0_@swc+core@1.3.96_/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].oneOf[0].use[4]!./src/app.scss ***!
\************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
::before,::after {
--tw-content: ""}
view,text,::before,::after {
--tw-border-spacing-x: 0;
--tw-border-spacing-y: 0;
--tw-translate-x: 0;
--tw-translate-y: 0;
--tw-rotate: 0;
--tw-skew-x: 0;
--tw-skew-y: 0;
--tw-scale-x: 1;
--tw-scale-y: 1;
--tw-pan-x: ;
--tw-pan-y: ;
--tw-pinch-zoom: ;
--tw-scroll-snap-strictness: proximity;
--tw-gradient-from-position: ;
--tw-gradient-via-position: ;
--tw-gradient-to-position: ;
--tw-ordinal: ;
--tw-slashed-zero: ;
--tw-numeric-figure: ;
--tw-numeric-spacing: ;
--tw-numeric-fraction: ;
--tw-ring-inset: ;
--tw-ring-offset-width: 0rpx;
--tw-ring-offset-color: #fff;
--tw-ring-color: rgb(59 130 246 / 0.5);
--tw-ring-offset-shadow: 0 0 #0000;
--tw-ring-shadow: 0 0 #0000;
--tw-shadow: 0 0 #0000;
--tw-shadow-colored: 0 0 #0000;
--tw-blur: ;
--tw-brightness: ;
--tw-contrast: ;
--tw-grayscale: ;
--tw-hue-rotate: ;
--tw-invert: ;
--tw-saturate: ;
--tw-sepia: ;
--tw-drop-shadow: ;
--tw-backdrop-blur: ;
--tw-backdrop-brightness: ;
--tw-backdrop-contrast: ;
--tw-backdrop-grayscale: ;
--tw-backdrop-hue-rotate: ;
--tw-backdrop-invert: ;
--tw-backdrop-opacity: ;
--tw-backdrop-saturate: ;
--tw-backdrop-sepia: ;
--tw-contain-size: ;
--tw-contain-layout: ;
--tw-contain-paint: ;
--tw-contain-style:
;
box-sizing: border-box;
border-width: 0;
border-style: solid;
border-color: currentColor}
::backdrop {
--tw-border-spacing-x: 0;
--tw-border-spacing-y: 0;

2
dist/common.js.map vendored
View File

@@ -1 +1 @@
{"version":3,"file":"common.js","mappings":";;;;;;;;;;;;;AAAA;AACA","sources":["webpack://taro-template/._src_constants_counter.js"],"sourcesContent":["export const ADD = 'ADD'\nexport const MINUS = 'MINUS'\n"],"names":[],"sourceRoot":""}
{"version":3,"sources":[""],"names":[],"mappings":"AAAA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA"}

View File

@@ -1,4 +1,3 @@
"use strict";
(wx["webpackJsonp"] = wx["webpackJsonp"] || []).push([["pages/home/index"],{
/***/ "./node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=pages/home/index!./src/pages/home/index.jsx":
@@ -7,27 +6,33 @@
\********************************************************************************************************************************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "webpack/container/remote/react");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _tarojs_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @tarojs/components */ "./node_modules/.pnpm/@tarojs+plugin-platform-weapp@4.0.8_@tarojs+service@4.0.8_@tarojs+shared@4.0.8/node_modules/@tarojs/plugin-platform-weapp/dist/components-react.js");
/* harmony import */ var _api__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../api */ "./src/api/index.js");
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react/jsx-runtime */ "webpack/container/remote/react/jsx-runtime");
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__);
"use strict";
/* harmony import */ var _nutui_nutui_react_taro_dist_esm_Button_style_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @nutui/nutui-react-taro/dist/esm/Button/style/css */ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/Button/style/css.js");
/* harmony import */ var _nutui_nutui_react_taro_dist_esm_Button__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @nutui/nutui-react-taro/dist/esm/Button */ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/button.taro-CixO32Hw.js");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react */ "webpack/container/remote/react");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _tarojs_components__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @tarojs/components */ "./node_modules/.pnpm/@tarojs+plugin-platform-weapp@4.0.8_@tarojs+service@4.0.8_@tarojs+shared@4.0.8/node_modules/@tarojs/plugin-platform-weapp/dist/components-react.js");
/* harmony import */ var _api__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../api */ "./src/api/index.js");
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! react/jsx-runtime */ "webpack/container/remote/react/jsx-runtime");
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__);
class Home extends react__WEBPACK_IMPORTED_MODULE_0__.Component {
class Home extends react__WEBPACK_IMPORTED_MODULE_1__.Component {
async sendMsg() {
await _api__WEBPACK_IMPORTED_MODULE_1__["default"].system.getBaidu();
await _api__WEBPACK_IMPORTED_MODULE_2__["default"].system.getBaidu();
}
render() {
return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsxs)(_tarojs_components__WEBPACK_IMPORTED_MODULE_3__.View, {
children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_tarojs_components__WEBPACK_IMPORTED_MODULE_3__.View, {
return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsxs)(_tarojs_components__WEBPACK_IMPORTED_MODULE_4__.View, {
children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)(_tarojs_components__WEBPACK_IMPORTED_MODULE_4__.View, {
class: "text-_red_",
children: "123456"
}), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_tarojs_components__WEBPACK_IMPORTED_MODULE_3__.Button, {
}), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)(_nutui_nutui_react_taro_dist_esm_Button__WEBPACK_IMPORTED_MODULE_5__.B, {
type: "info",
onClick: this.sendMsg,
children: "\u53D1\u9001"
})]
@@ -36,6 +41,501 @@ class Home extends react__WEBPACK_IMPORTED_MODULE_0__.Component {
}
/* harmony default export */ __webpack_exports__["default"] = (Home);
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/Loading.js":
/*!************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/Loading.js ***!
\************************************************************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ "default": function() { return /* binding */ y; }
/* harmony export */ });
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "webpack/container/remote/react");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _IconTemplate_b29ebbb8_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./IconTemplate-b29ebbb8.mjs */ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/IconTemplate-b29ebbb8.mjs");
const y = D => {
const M = {
..._IconTemplate_b29ebbb8_mjs__WEBPACK_IMPORTED_MODULE_1__.d,
...D
};
return /* @__PURE__ */react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_IconTemplate_b29ebbb8_mjs__WEBPACK_IMPORTED_MODULE_1__.I, {
...M,
name: M.name || "Loading",
svg64: "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxMDI0IDEwMjQiPjxwYXRoIGZpbGw9InVuZGVmaW5lZCIgZD0iTTUxMiA3My4xNGE0My44OSA0My44OSAwIDAgMSA0My44OSA0My44OXYxMTguNDlhNDMuODkgNDMuODkgMCAwIDEtODcuNzggMFYxMTcuMDNBNDMuODkgNDMuODkgMCAwIDEgNTEyIDczLjE0TTIwMS42NSAyMDEuNjVhNDMuODkgNDMuODkgMCAwIDEgNjIuMSAwbDgzLjY4IDgzLjgzYTQzLjg5IDQzLjg5IDAgMSAxLTYyLjAzIDYyLjAybC04My43NS04My43NWE0My44OSA0My44OSAwIDAgMSAwLTYyLjFtNjIwLjcgMGE0My44OSA0My44OSAwIDAgMSAwIDYyLjFsLTgzLjgzIDgzLjY4YTQzLjg5IDQzLjg5IDAgMSAxLTYyLjAyLTYyLjAzbDgzLjc1LTgzLjgyYTQzLjg5IDQzLjg5IDAgMCAxIDYyLjEgMHpNNzMuMTQgNTEyYTQzLjg5IDQzLjg5IDAgMCAxIDQzLjg5LTQzLjg5aDExOC40OWE0My44OSA0My44OSAwIDAgMSAwIDg3Ljc4SDExNy4wM0E0My44OSA0My44OSAwIDAgMSA3My4xNCA1MTJtNjcxLjQ1IDBhNDMuODkgNDMuODkgMCAwIDEgNDMuODktNDMuODloMTE4LjQ5YTQzLjg5IDQzLjg5IDAgMSAxIDAgODcuNzhINzg4LjQ4QTQzLjg5IDQzLjg5IDAgMCAxIDc0NC41OSA1MTJNMzQ3LjUgNjc2LjVhNDMuODkgNDMuODkgMCAwIDEgMCA2Mi4wMmwtODMuNzUgODMuODNhNDMuODkgNDMuODkgMCAxIDEtNjIuMS02Mi4xbDgzLjgzLTgzLjY4YTQzLjg5IDQzLjg5IDAgMCAxIDYyLjAyIDB6bTMyOSAwYTQzLjg5IDQzLjg5IDAgMCAxIDYyLjAyIDBsODMuODMgODMuNzVhNDMuODkgNDMuODkgMCAxIDEtNjIuMSA2Mi4xbC04My42OC04My44M2E0My44OSA0My44OSAwIDAgMSAwLTYyLjAyek01MTIgNzQ0LjU5YTQzLjg5IDQzLjg5IDAgMCAxIDQzLjg5IDQzLjg5djExOC40OWE0My44OSA0My44OSAwIDEgMS04Ny43OCAwVjc4OC40OEE0My44OSA0My44OSAwIDAgMSA1MTIgNzQ0LjU5Ii8+PC9zdmc+"
});
};
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/internal.js":
/*!*************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/internal.js ***!
\*************************************************************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ globalConfig: function() { return /* binding */ n; }
/* harmony export */ });
const n = {
useSvg: !0,
classPrefix: "nut-icon",
tag: "i",
fontClassName: "nutui-iconfont"
};
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/index.es.js":
/*!*******************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/index.es.js ***!
\*******************************************************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ Loading: function() { return /* reexport safe */ _icons_Loading_js__WEBPACK_IMPORTED_MODULE_0__["default"]; }
/* harmony export */ });
/* harmony import */ var _icons_Loading_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./icons/Loading.js */ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/Loading.js");
/* harmony import */ var _style_icon_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../style_icon.css */ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/style_icon.css");
/** 此文件由 script generate 脚本生成 */
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/Button/style/css.js":
/*!************************************************************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/Button/style/css.js ***!
\************************************************************************************************************************************************************************/
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _style_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./style.css */ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/Button/style/style.css");
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/button.taro-CixO32Hw.js":
/*!****************************************************************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/button.taro-CixO32Hw.js ***!
\****************************************************************************************************************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ B: function() { return /* binding */ Button; }
/* harmony export */ });
/* harmony import */ var _tslib_es6_iWu3F_1J_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./tslib.es6-iWu3F_1J.js */ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/tslib.es6-iWu3F_1J.js");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "webpack/container/remote/react");
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! classnames */ "./node_modules/.pnpm/classnames@2.5.1/node_modules/classnames/index.js");
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(classnames__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _nutui_icons_react_taro__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @nutui/icons-react-taro */ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/index.es.js");
/* harmony import */ var _tarojs_taro__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @tarojs/taro */ "webpack/container/remote/@tarojs/taro");
/* harmony import */ var _tarojs_taro__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_tarojs_taro__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _typings_DV9RBfhj_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./typings-DV9RBfhj.js */ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/typings-DV9RBfhj.js");
const prefixCls = "nut-button";
const defaultProps = Object.assign(Object.assign({}, _typings_DV9RBfhj_js__WEBPACK_IMPORTED_MODULE_4__.C), {
color: "",
type: "default",
size: "normal",
shape: "round",
fill: "outline",
loading: false,
disabled: false,
block: false,
icon: null,
rightIcon: null,
onClick: e => {}
});
const Button = /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().forwardRef((props, ref) => {
const _a = Object.assign(Object.assign({}, defaultProps), props),
{
color,
shape,
fill,
loading,
disabled,
type,
size,
block,
icon,
rightIcon,
children,
className,
style,
nativeType,
onClick
} = _a,
rest = (0,_tslib_es6_iWu3F_1J_js__WEBPACK_IMPORTED_MODULE_5__._)(_a, ["color", "shape", "fill", "loading", "disabled", "type", "size", "block", "icon", "rightIcon", "children", "className", "style", "nativeType", "onClick"]);
const getStyle = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(() => {
const style2 = {};
if (color) {
if (props.fill === "outline" || props.fill === "dashed") {
style2.color = color;
if (!(color === null || color === void 0 ? void 0 : color.includes("gradient"))) {
style2.borderColor = color;
}
} else {
style2.color = "#fff";
style2.background = color;
style2.borderColor = "transparent";
}
}
return style2;
}, [color, props.fill]);
const handleClick = e => {
if (!loading && !disabled && onClick) {
onClick(e);
}
};
if ((0,_tarojs_taro__WEBPACK_IMPORTED_MODULE_3__.getEnv)() === "WEB") {
rest.type = rest.formType;
}
return (
/*#__PURE__*/
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore
// eslint-disable-next-line react/button-has-type
react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", Object.assign({}, rest, {
ref,
type: nativeType,
className: classnames__WEBPACK_IMPORTED_MODULE_1___default()(prefixCls, `${prefixCls}-${type}`, props.fill ? `${prefixCls}-${fill}` : null, children ? "" : `${prefixCls}-icononly`, {
[`${prefixCls}-${size}`]: size,
[`${prefixCls}-${shape}`]: shape,
[`${prefixCls}-block`]: block,
[`${prefixCls}-disabled`]: disabled || loading,
[`${prefixCls}-loading`]: loading
}, className),
style: Object.assign(Object.assign({}, getStyle()), style),
onClick: e => handleClick(e)
}), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
className: "nut-button-wrap"
}, loading && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_nutui_icons_react_taro__WEBPACK_IMPORTED_MODULE_2__.Loading, {
className: "nut-icon-loading"
}), !loading && icon ? icon : null, children && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
className: `${icon || loading ? "nut-button-text" : ""}${rightIcon ? " nut-button-text right" : ""}`
}, children), rightIcon || null))
);
});
Button.displayName = "NutButton";
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/tslib.es6-iWu3F_1J.js":
/*!**************************************************************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/tslib.es6-iWu3F_1J.js ***!
\**************************************************************************************************************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ _: function() { return /* binding */ __rest; }
/* harmony export */ });
/* unused harmony export a */
function __rest(s, e) {
var t = {};
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
}
return t;
}
function __awaiter(thisArg, _arguments, P, generator) {
function adopt(value) {
return value instanceof P ? value : new P(function (resolve) {
resolve(value);
});
}
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) {
try {
step(generator.next(value));
} catch (e) {
reject(e);
}
}
function rejected(value) {
try {
step(generator["throw"](value));
} catch (e) {
reject(e);
}
}
function step(result) {
result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
}
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
}
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
var e = new Error(message);
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
};
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/typings-DV9RBfhj.js":
/*!************************************************************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/typings-DV9RBfhj.js ***!
\************************************************************************************************************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ C: function() { return /* binding */ ComponentDefaults; }
/* harmony export */ });
const ComponentDefaults = {
className: "",
style: {}
};
/***/ }),
/***/ "./src/api/index.js":
@@ -44,6 +544,7 @@ class Home extends react__WEBPACK_IMPORTED_MODULE_0__.Component {
\**************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _system__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./system */ "./src/api/system/index.js");
const Api = {
@@ -61,6 +562,7 @@ const Api = {
\*********************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _utils_request__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../utils/request */ "./src/utils/request.js");
const system = {
@@ -81,6 +583,7 @@ const system = {
\**********************************/
/***/ (function(__unused_webpack_module, __unused_webpack___webpack_exports__, __webpack_require__) {
"use strict";
/* harmony import */ var _tarojs_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tarojs/runtime */ "webpack/container/remote/@tarojs/runtime");
/* harmony import */ var _tarojs_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_tarojs_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _node_modules_pnpm_tarojs_taro_loader_4_0_8_webpack_5_91_0_swc_core_1_3_96_node_modules_tarojs_taro_loader_lib_entry_cache_js_name_pages_home_index_index_jsx__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! !!../../../node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=pages/home/index!./index.jsx */ "./node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=pages/home/index!./src/pages/home/index.jsx");
@@ -109,6 +612,7 @@ var inst = Page(taroOption)
\******************************/
/***/ (function(__unused_webpack_module, __webpack_exports__) {
"use strict";
const request = options => {
const {
method,
@@ -123,6 +627,192 @@ const request = options => {
};
/* harmony default export */ __webpack_exports__["default"] = (request);
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/style_icon.css":
/*!*******************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/style_icon.css ***!
\*******************************************************************************************************************/
/***/ (function() {
"use strict";
// extracted by mini-css-extract-plugin
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/Button/style/style.css":
/*!***************************************************************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+nutui-react-taro@2.7.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@nutui/nutui-react-taro/dist/esm/Button/style/style.css ***!
\***************************************************************************************************************************************************************************/
/***/ (function() {
"use strict";
// extracted by mini-css-extract-plugin
/***/ }),
/***/ "./node_modules/.pnpm/classnames@2.5.1/node_modules/classnames/index.js":
/*!******************************************************************************!*\
!*** ./node_modules/.pnpm/classnames@2.5.1/node_modules/classnames/index.js ***!
\******************************************************************************/
/***/ (function(module, exports) {
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
Copyright (c) 2018 Jed Watson.
Licensed under the MIT License (MIT), see
http://jedwatson.github.io/classnames
*/
/* global define */
(function () {
'use strict';
var hasOwn = {}.hasOwnProperty;
function classNames () {
var classes = '';
for (var i = 0; i < arguments.length; i++) {
var arg = arguments[i];
if (arg) {
classes = appendClass(classes, parseValue(arg));
}
}
return classes;
}
function parseValue (arg) {
if (typeof arg === 'string' || typeof arg === 'number') {
return arg;
}
if (typeof arg !== 'object') {
return '';
}
if (Array.isArray(arg)) {
return classNames.apply(null, arg);
}
if (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes('[native code]')) {
return arg.toString();
}
var classes = '';
for (var key in arg) {
if (hasOwn.call(arg, key) && arg[key]) {
classes = appendClass(classes, key);
}
}
return classes;
}
function appendClass (value, newClass) {
if (!newClass) {
return value;
}
if (value) {
return value + ' ' + newClass;
}
return value + newClass;
}
if ( true && module.exports) {
classNames.default = classNames;
module.exports = classNames;
} else if (true) {
// register as 'classnames', consistent with npm package name
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function () {
return classNames;
}).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
} else {}
}());
/***/ }),
/***/ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/IconTemplate-b29ebbb8.mjs":
/*!***************************************************************************************************************************************!*\
!*** ./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/IconTemplate-b29ebbb8.mjs ***!
\***************************************************************************************************************************************/
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */ I: function() { return /* binding */ P; },
/* harmony export */ d: function() { return /* binding */ x; }
/* harmony export */ });
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "webpack/container/remote/react");
/* harmony import */ var _internal_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./internal.js */ "./node_modules/.pnpm/@nutui+icons-react-taro@1.0.5/node_modules/@nutui/icons-react-taro/dist/es/icons/internal.js");
const x = {
className: "",
style: void 0,
name: "",
width: "",
height: "",
size: "",
svg64: "",
onClick: () => {}
},
y = k => {
const n = _internal_js__WEBPACK_IMPORTED_MODULE_1__.globalConfig.classPrefix,
{
className: m,
style: f,
name: e,
color: r,
width: p,
height: C,
size: i,
svg64: a,
children: u,
onClick: l,
fallback: o = !_internal_js__WEBPACK_IMPORTED_MODULE_1__.globalConfig.useSvg
} = {
...x,
...k
},
N = t => {
l && l(t);
},
h = t => t === "" ? "" : isNaN(Number(t)) ? String(t) : t + "px",
$ = () => {
const t = o ? e == null ? void 0 : e.toLowerCase() : e;
return `${o ? _internal_js__WEBPACK_IMPORTED_MODULE_1__.globalConfig.fontClassName : ""} ${n} ${n}-${t} ${m}`;
},
c = {},
d = h(p || i || ""),
g = h(C || i || "");
d && (c.width = d), g && (c.height = g);
const b = () => ({
...f,
...(o ? {} : {
backgroundColor: r || "currentColor",
mask: `url('${a}') 0 0/100% 100% no-repeat`,
"-webkitMask": `url('${a}') 0 0/100% 100% no-repeat`
}),
...c
});
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement(_internal_js__WEBPACK_IMPORTED_MODULE_1__.globalConfig.tag, {
className: $(),
style: b(),
onClick: N,
color: r
}, u);
},
P = y;
/***/ })
},

View File

@@ -1 +1 @@
{"version":3,"sources":[""],"names":[],"mappings":"AAAA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;;;;;AAMA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gBAAgB,UAAU;AAC1B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;;AAGA;;;;AAIA;AACA;AACA;AACA;AACA;;;;AAIA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}
{"version":3,"sources":[""],"names":[],"mappings":"AAAA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;AAQA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gBAAgB,UAAU;AAC1B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;;;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwOA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;AAOA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;;AAGA;;;;AAIA;AACA;AACA;AACA;AACA;;;;AAIA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
{"version":3,"file":"pages/index/index.js","mappings":";;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;AC1DA;AAKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;ACvBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","sources":["webpack://taro-template/._src_pages_index_index.jsx","webpack://taro-template/._src_actions_counter.js","webpack://taro-template/./src/pages/index/index.jsx?e561"],"sourcesContent":["var _dec, _class;\nimport { Component } from 'react';\nimport { connect } from 'react-redux';\nimport { View, Button, Text } from '@tarojs/components';\nimport { add, minus, asyncAdd } from '../../actions/counter';\nimport './index.scss';\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nlet Index = (_dec = connect(_ref => {\n let {\n counter\n } = _ref;\n return {\n counter\n };\n}, dispatch => ({\n add() {\n dispatch(add());\n },\n dec() {\n dispatch(minus());\n },\n asyncAdd() {\n dispatch(asyncAdd());\n }\n})), _dec(_class = class Index extends Component {\n componentWillReceiveProps(nextProps) {\n console.log(this.props, nextProps);\n }\n componentWillUnmount() {}\n componentDidShow() {}\n componentDidHide() {}\n render() {\n return /*#__PURE__*/_jsxs(View, {\n className: \"index\",\n children: [/*#__PURE__*/_jsx(Button, {\n className: \"add_btn\",\n onClick: this.props.add,\n children: \"+\"\n }), /*#__PURE__*/_jsx(Button, {\n className: \"dec_btn\",\n onClick: this.props.dec,\n children: \"-\"\n }), /*#__PURE__*/_jsx(Button, {\n className: \"dec_btn\",\n onClick: this.props.asyncAdd,\n children: \"async\"\n }), /*#__PURE__*/_jsx(View, {\n children: /*#__PURE__*/_jsx(Text, {\n children: this.props.counter.num\n })\n }), /*#__PURE__*/_jsx(View, {\n children: /*#__PURE__*/_jsx(Text, {\n children: \"Hello, World\"\n })\n })]\n });\n }\n}) || _class);\nexport default Index;","import {\n ADD,\n MINUS\n} from '../constants/counter'\n\nexport const add = () => {\n return {\n type: ADD\n }\n}\nexport const minus = () => {\n return {\n type: MINUS\n }\n}\n\n// 异步的action\nexport function asyncAdd () {\n return dispatch => {\n setTimeout(() => {\n dispatch(add())\n }, 2000)\n }\n}\n","import { createPageConfig } from '@tarojs/runtime'\nimport component from \"!!../../../node_modules/.pnpm/@tarojs+taro-loader@4.0.8_webpack@5.91.0_@swc+core@1.3.96_/node_modules/@tarojs/taro-loader/lib/entry-cache.js?name=pages/index/index!./index.jsx\"\nvar config = {\"navigationBarTitleText\":\"首页\"};\n\n\n\nvar taroOption = createPageConfig(component, 'pages/index/index', {root:{cn:[]}}, config || {})\nif (component && component.behaviors) {\n taroOption.behaviors = (taroOption.behaviors || []).concat(component.behaviors)\n}\nvar inst = Page(taroOption)\n\n\n\nexport default component\n"],"names":[],"sourceRoot":""}
{"version":3,"sources":[""],"names":[],"mappings":"AAAA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;AAOA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;;AAGA;;;;AAIA;AACA;AACA;AACA;AACA;;;;AAIA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}

View File

@@ -33,6 +33,9 @@ var moduleMap = {
"./@tarojs/plugin-platform-weapp/dist/runtime": function() {
return Promise.all([__webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_chunk-GLEAZC6U_js"), __webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_tarojs_plugin-platform-weapp_dist_runtime_js")]).then(function() { return function() { return (__webpack_require__(/*! ./node_modules/.taro/weapp/prebundle/@tarojs_plugin-platform-weapp_dist_runtime.js */ "./node_modules/.taro/weapp/prebundle/@tarojs_plugin-platform-weapp_dist_runtime.js")); }; });
},
"./@tarojs/plugin-html/dist/runtime": function() {
return Promise.all([__webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_chunk-GLEAZC6U_js"), __webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_chunk-WRSQ3V3E_js"), __webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_tarojs_plugin-html_dist_runtime_js")]).then(function() { return function() { return (__webpack_require__(/*! ./node_modules/.taro/weapp/prebundle/@tarojs_plugin-html_dist_runtime.js */ "./node_modules/.taro/weapp/prebundle/@tarojs_plugin-html_dist_runtime.js")); }; });
},
"./@tarojs/plugin-framework-react/dist/runtime": function() {
return Promise.all([__webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_chunk-GLEAZC6U_js"), __webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_chunk-WRSQ3V3E_js"), __webpack_require__.e("vendors-node_modules_taro_weapp_prebundle_tarojs_plugin-framework-react_dist_runtime_js")]).then(function() { return function() { return (__webpack_require__(/*! ./node_modules/.taro/weapp/prebundle/@tarojs_plugin-framework-react_dist_runtime.js */ "./node_modules/.taro/weapp/prebundle/@tarojs_plugin-framework-react_dist_runtime.js")); }; });
},
@@ -95,6 +98,9 @@ var taroModuleMap = {
"./@tarojs/plugin-platform-weapp/dist/runtime": function() {
return function() { return (__webpack_require__(/*! ./node_modules/.taro/weapp/prebundle/@tarojs_plugin-platform-weapp_dist_runtime.js */ "./node_modules/.taro/weapp/prebundle/@tarojs_plugin-platform-weapp_dist_runtime.js")); };
},
"./@tarojs/plugin-html/dist/runtime": function() {
return function() { return (__webpack_require__(/*! ./node_modules/.taro/weapp/prebundle/@tarojs_plugin-html_dist_runtime.js */ "./node_modules/.taro/weapp/prebundle/@tarojs_plugin-html_dist_runtime.js")); };
},
"./@tarojs/plugin-framework-react/dist/runtime": function() {
return function() { return (__webpack_require__(/*! ./node_modules/.taro/weapp/prebundle/@tarojs_plugin-framework-react_dist_runtime.js */ "./node_modules/.taro/weapp/prebundle/@tarojs_plugin-framework-react_dist_runtime.js")); };
},

View File

@@ -4832,7 +4832,9 @@ var init_dom_external = (0,_chunk_QRPWKJ4C_js__WEBPACK_IMPORTED_MODULE_1__.__esm
}
if (false) {}
if (false) {}
if (false) {}
if (true) {
TaroElement.extend("getBoundingClientRect", getBoundingClientRectImpl);
}
if (false) {}
}
}

View File

@@ -0,0 +1,524 @@
"use strict";
(wx["webpackJsonp"] = wx["webpackJsonp"] || []).push([["vendors-node_modules_taro_weapp_prebundle_tarojs_plugin-html_dist_runtime_js"],{
/***/ "./node_modules/.taro/weapp/prebundle/@tarojs_plugin-html_dist_runtime.js":
/*!********************************************************************************!*\
!*** ./node_modules/.taro/weapp/prebundle/@tarojs_plugin-html_dist_runtime.js ***!
\********************************************************************************/
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _chunk_WRSQ3V3E_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./chunk-WRSQ3V3E.js */ "./node_modules/.taro/weapp/prebundle/chunk-WRSQ3V3E.js");
/* harmony import */ var _chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./chunk-GLEAZC6U.js */ "./node_modules/.taro/weapp/prebundle/chunk-GLEAZC6U.js");
/* harmony import */ var _chunk_QRPWKJ4C_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./chunk-QRPWKJ4C.js */ "./node_modules/.taro/weapp/prebundle/chunk-QRPWKJ4C.js");
// node_modules/.pnpm/@tarojs+plugin-html@4.0.8_@tarojs+helper@4.0.8_@tarojs+runtime@4.0.8_@tarojs+shared@4.0.8/node_modules/@tarojs/plugin-html/dist/runtime.js
(0,_chunk_WRSQ3V3E_js__WEBPACK_IMPORTED_MODULE_0__.init_dist)();
(0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.init_dist)();
function genAttrMapFnFromDir(dir) {
const fn = function(key, value) {
const lowerKey = key.toLowerCase();
if (lowerKey in dir) {
const res = dir[lowerKey];
if ((0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.isString)(res)) {
key = res;
} else {
key = res[0];
value = res[1][value] || value;
}
}
return [
key,
value
];
};
return fn;
}
var inlineElements = /* @__PURE__ */ new Set([
"i",
"abbr",
"select",
"acronym",
"small",
"bdi",
"kbd",
"strong",
"big",
"sub",
"sup",
"br",
"mark",
"meter",
"template",
"cite",
"object",
"time",
"code",
"output",
"u",
"data",
"picture",
"tt",
"datalist",
"var",
"dfn",
"del",
"q",
"em",
"s",
"embed",
"samp",
"b"
]);
var blockElements = /* @__PURE__ */ new Set([
"body",
"svg",
"address",
"fieldset",
"li",
"span",
"article",
"figcaption",
"main",
"aside",
"figure",
"nav",
"blockquote",
"footer",
"ol",
"details",
"p",
"dialog",
"h1",
"h2",
"h3",
"h4",
"h5",
"h6",
"pre",
"dd",
"header",
"section",
"div",
"hgroup",
"table",
"dl",
"hr",
"ul",
"dt",
"view",
"view-block"
]);
var specialElements = /* @__PURE__ */ new Map([
[
"slot",
"slot"
],
[
"form",
"form"
],
[
"iframe",
"web-view"
],
[
"img",
"image"
],
[
"audio",
"audio"
],
[
"video",
"video"
],
[
"canvas",
"canvas"
],
[
"a",
{
mapName (props) {
if (props.as && (0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.isString)(props.as)) return props.as.toLowerCase();
return !props.href || /^javascript/.test(props.href) ? "view" : "navigator";
},
mapNameCondition: [
"href"
],
mapAttr: genAttrMapFnFromDir({
href: "url",
target: [
"openType",
{
_blank: "navigate",
_self: "redirect"
}
]
})
}
],
[
"input",
{
mapName (props) {
if (props.type === "checkbox") {
return "checkbox";
} else if (props.type === "radio") {
return "radio";
}
return "input";
},
mapNameCondition: [
"type"
],
mapAttr (key, value, props) {
const htmlKey = key.toLowerCase();
if (htmlKey === "autofocus") {
key = "focus";
} else if (htmlKey === "readonly") {
if (props.disabled === true) {
value = true;
}
key = "disabled";
} else if (htmlKey === "type") {
if (value === "password") {
key = "password";
value = true;
} else if (value === "tel") {
value = "number";
}
} else if (htmlKey === "maxlength") {
key = "maxlength";
}
return [
key,
value
];
}
}
],
[
"label",
{
mapName: "label",
mapAttr: genAttrMapFnFromDir({
htmlfor: "for"
})
}
],
[
"textarea",
{
mapName: "textarea",
mapAttr: genAttrMapFnFromDir({
autofocus: "focus",
readonly: "disabled",
maxlength: "maxlength"
})
}
],
[
"progress",
{
mapName: "progress",
mapAttr (key, value, props) {
if (key === "value") {
const max = props.max || 1;
key = "percent";
value = Math.round(value / max * 100);
}
return [
key,
value
];
}
}
],
[
"button",
{
mapName: "button",
mapAttr (key, value) {
if (key === "type" && (value === "submit" || value === "reset")) {
key = "formType";
}
return [
key,
value
];
}
}
]
]);
function isHtmlTags(nodeName) {
if (inlineElements.has(nodeName) || blockElements.has(nodeName) || specialElements.has(nodeName)) {
return true;
}
return false;
}
function getMappedType(nodeName, rawProps, node) {
if (inlineElements.has(nodeName)) {
return "text";
} else if (specialElements.has(nodeName)) {
const mapping = specialElements.get(nodeName);
if ((0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.isString)(mapping)) {
return mapping;
}
const { mapName } = mapping;
return (0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.isFunction)(mapName) ? mapName(rawProps) : mapName;
} else {
if (false) {}
if (node) {
const { props } = node;
for(const prop in props){
const propInCamelCase = (0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.toCamelCase)(prop);
if (propInCamelCase === "catchMove" && props[prop] !== false) {
return "catch-view";
}
}
}
if (!node) {
return "view";
}
if (node.isOnlyClickBinded()) {
return "click-view";
} else if (node.isAnyEventBinded()) {
return "view";
} else if ((0,_chunk_WRSQ3V3E_js__WEBPACK_IMPORTED_MODULE_0__.isHasExtractProp)(node)) {
return "static-view";
} else {
return "pure-view";
}
}
}
function getAttrMapFn(nodeName) {
const mapping = specialElements.get(nodeName);
if (!(0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.isString)(mapping)) {
return mapping === null || mapping === void 0 ? void 0 : mapping.mapAttr;
}
}
function getMapNameByCondition(nodeName, attr, props) {
const mapping = specialElements.get(nodeName);
if (!mapping || (0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.isString)(mapping)) return;
const { mapName, mapNameCondition } = mapping;
if (!mapNameCondition) return;
if (mapNameCondition.indexOf(attr) > -1 && !(0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.isString)(mapName)) {
return mapName(props);
}
}
function mapNameByContion(nodeName, key, element, componentsAlias) {
const mapName = getMapNameByCondition(nodeName, key, element.props);
if (mapName) {
const mapNameAlias = componentsAlias[mapName]._num;
element.enqueueUpdate({
path: `${element._path}.${"nn"}`,
value: mapNameAlias
});
}
}
function ensureHtmlClass(tagName, className = "") {
const classList = className.split(" ");
const htmlClass = `h5-${tagName}`;
if (classList.indexOf(htmlClass) === -1) {
classList.unshift(htmlClass);
}
return classList.join(" ");
}
function ensureRect(props, style = "") {
let cssText = style;
const { width, height } = props;
if (width) {
cssText = `width: ${width};${cssText}`;
}
if (height) {
cssText = `height: ${height};${cssText}`;
}
return cssText;
}
function defineMappedProp(obj, propName, mapName) {
Object.defineProperty(obj, propName, {
enumerable: true,
configurable: true,
get () {
return obj[mapName];
},
set (val) {
obj[mapName] = val;
}
});
}
_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.hooks.tap("modifyHydrateData", (data, node)=>{
const nodeName = data["nn"];
if (!isHtmlTags(nodeName)) return;
(0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.warn)(data["nn"] === "select", "\u8BF7\u4F7F\u7528 Picker \u7EC4\u4EF6\u4EE3\u66FF <select>");
data["nn"] = getMappedType(nodeName, data, node);
const attrMapFn = getAttrMapFn(nodeName);
if (attrMapFn) {
for(const key in data){
const value = data[key];
const [mapKey, mapValue] = attrMapFn(key, value, data);
if (key !== mapKey) {
delete data[key];
data[mapKey] = mapValue;
} else if (value !== mapValue) {
data[key] = mapValue;
}
}
}
if (nodeName === "br") {
data["cn"] = [
{
["nn"]: "#text",
v: "\n"
}
];
}
data["cl"] = ensureHtmlClass(nodeName, data["cl"]);
data["st"] = ensureRect(data, data["st"]);
});
_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.hooks.tap("modifySetAttrPayload", (element, key, payload, componentsAlias)=>{
const { nodeName, _path, props } = element;
if (!isHtmlTags(nodeName)) return;
mapNameByContion(nodeName, key, element, componentsAlias);
const mapName = getMappedType(nodeName, props);
const alias = componentsAlias[mapName];
const attrMapFn = getAttrMapFn(nodeName);
if (attrMapFn) {
const value = payload.value;
const [mapKey, mapValue] = attrMapFn(key, value, props);
payload.path = `${_path}.${alias[mapKey] || mapKey}`;
payload.value = mapValue;
} else if (alias[key] && alias[key] !== key) {
payload.path = `${_path}.${(0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.toCamelCase)(alias[key])}`;
}
if (key === "cl") {
payload.value = ensureHtmlClass(nodeName, payload.value);
} else if (key === "st" || key === "width" || key === "height") {
payload.path = `${_path}.${"st"}`;
payload.value = ensureRect(props, element.style.cssText);
}
if (blockElements.has(element.nodeName) && true) {
const viewAlias = componentsAlias.view._num;
const staticViewAlias = componentsAlias["static-view"]._num;
const catchViewAlias = componentsAlias["catch-view"]._num;
const clickViewAlias = componentsAlias["click-view"]._num;
const qualifiedNameInCamelCase = (0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.toCamelCase)(key);
const dataPath = `${_path}.${"nn"}`;
if (qualifiedNameInCamelCase === "catchMove") {
element.enqueueUpdate({
path: dataPath,
value: payload.value ? catchViewAlias : element.isOnlyClickBinded() ? clickViewAlias : element.isAnyEventBinded() ? viewAlias : staticViewAlias
});
} else if ((0,_chunk_WRSQ3V3E_js__WEBPACK_IMPORTED_MODULE_0__.isHasExtractProp)(element) && !element.isAnyEventBinded()) {
element.enqueueUpdate({
path: dataPath,
value: staticViewAlias
});
}
}
});
_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.hooks.tap("modifyRmAttrPayload", (element, key, payload, componentsAlias)=>{
const { nodeName, _path, props } = element;
if (!isHtmlTags(nodeName)) return;
mapNameByContion(nodeName, key, element, componentsAlias);
const mapName = getMappedType(nodeName, props);
const alias = componentsAlias[mapName];
const attrMapFn = getAttrMapFn(nodeName);
if (attrMapFn) {
const value = payload[key];
const [mapKey] = attrMapFn(key, value, props);
payload.path = `${_path}.${alias[mapKey] || mapKey}`;
} else if (alias[key] && alias[key] !== key) {
payload.path = `${_path}.${(0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.toCamelCase)(alias[key])}`;
}
if (key === "cl") {
payload.value = ensureHtmlClass(nodeName, payload.value);
} else if (key === "st" || key === "width" || key === "height") {
payload.path = `${_path}.${"st"}`;
payload.value = ensureRect(props, element.style.cssText);
}
if (blockElements.has(element.nodeName) && true) {
const viewAlias = componentsAlias.view._num;
const staticViewAlias = componentsAlias["static-view"]._num;
const pureViewAlias = componentsAlias["pure-view"]._num;
const clickViewAlias = componentsAlias["click-view"]._num;
const qualifiedNameInCamelCase = (0,_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.toCamelCase)(key);
const dataPath = `${_path}.${"nn"}`;
if (qualifiedNameInCamelCase === "catchMove") {
element.enqueueUpdate({
path: dataPath,
value: element.isOnlyClickBinded() ? clickViewAlias : element.isAnyEventBinded() ? viewAlias : (0,_chunk_WRSQ3V3E_js__WEBPACK_IMPORTED_MODULE_0__.isHasExtractProp)(element) ? staticViewAlias : pureViewAlias
});
} else if (!(0,_chunk_WRSQ3V3E_js__WEBPACK_IMPORTED_MODULE_0__.isHasExtractProp)(element)) {
element.enqueueUpdate({
path: dataPath,
value: pureViewAlias
});
}
}
});
_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.hooks.tap("onAddEvent", (type, _handler, _options, node)=>{
node = node;
if (!isHtmlTags(node.nodeName)) return;
if (type === "click") {
defineMappedProp(node.__handlers, type, "tap");
} else if (node.nodeName === "input") {
if (type === "change") {
if (node.props.type === "checkbox" || node.props.type === "radio") {
defineMappedProp(node.__handlers, type, "tap");
} else {
defineMappedProp(node.__handlers, type, "input");
}
} else if (type === "keypress") {
defineMappedProp(node.__handlers, type, "confirm");
}
}
});
_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.hooks.tap("modifyTaroEvent", (event, element)=>{
const { nodeName, props } = element;
if (nodeName === "input" && event.type === "tap") {
if (props.type === "checkbox") {
props.checked = !props.checked;
} else if (props.type === "radio" && !props.checked) {
props.checked = true;
}
if (event.mpEvent) {
const { currentTarget, target } = event.mpEvent;
currentTarget.checked = props.checked;
if (target.id === currentTarget.id) {
target.checked = props.checked;
}
}
}
});
_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.hooks.tap("modifyAddEventListener", (element, sideEffect, getComponentsAlias)=>{
if (blockElements.has(element.nodeName) && sideEffect !== false && !element.isAnyEventBinded()) {
const componentsAlias = getComponentsAlias();
const alias = componentsAlias.view._num;
element.enqueueUpdate({
path: `${element._path}.${"nn"}`,
value: alias
});
}
});
_chunk_GLEAZC6U_js__WEBPACK_IMPORTED_MODULE_1__.hooks.tap("modifyRemoveEventListener", (element, sideEffect, getComponentsAlias)=>{
if (blockElements.has(element.nodeName) && sideEffect !== false && !element.isAnyEventBinded()) {
const componentsAlias = getComponentsAlias();
const value = (0,_chunk_WRSQ3V3E_js__WEBPACK_IMPORTED_MODULE_0__.isHasExtractProp)(element) ? "static-view" : "pure-view";
const valueAlias = componentsAlias[value]._num;
element.enqueueUpdate({
path: `${element._path}.${"nn"}`,
value: valueAlias
});
}
});
/***/ })
}]);

18
dist/runtime.js vendored
View File

@@ -198,8 +198,8 @@
/******/ var chunkMapping = {
/******/ "app": [
/******/ "webpack/container/remote/@tarojs/plugin-platform-weapp/dist/runtime",
/******/ "webpack/container/remote/@tarojs/plugin-html/dist/runtime",
/******/ "webpack/container/remote/@tarojs/plugin-framework-react/dist/runtime",
/******/ "webpack/container/remote/@tarojs/taro",
/******/ "webpack/container/remote/redux",
/******/ "webpack/container/remote/redux-thunk",
/******/ "webpack/container/remote/redux-logger",
@@ -207,6 +207,7 @@
/******/ ],
/******/ "common": [
/******/ "webpack/container/remote/@tarojs/runtime",
/******/ "webpack/container/remote/@tarojs/taro",
/******/ "webpack/container/remote/react",
/******/ "webpack/container/remote/react-redux",
/******/ "webpack/container/remote/react/jsx-runtime"
@@ -218,16 +219,16 @@
/******/ "./@tarojs/plugin-platform-weapp/dist/runtime",
/******/ null
/******/ ],
/******/ "webpack/container/remote/@tarojs/plugin-html/dist/runtime": [
/******/ "default",
/******/ "./@tarojs/plugin-html/dist/runtime",
/******/ null
/******/ ],
/******/ "webpack/container/remote/@tarojs/plugin-framework-react/dist/runtime": [
/******/ "default",
/******/ "./@tarojs/plugin-framework-react/dist/runtime",
/******/ null
/******/ ],
/******/ "webpack/container/remote/@tarojs/taro": [
/******/ "default",
/******/ "./@tarojs/taro",
/******/ null
/******/ ],
/******/ "webpack/container/remote/redux": [
/******/ "default",
/******/ "./redux",
@@ -253,6 +254,11 @@
/******/ "./@tarojs/runtime",
/******/ null
/******/ ],
/******/ "webpack/container/remote/@tarojs/taro": [
/******/ "default",
/******/ "./@tarojs/taro",
/******/ null
/******/ ],
/******/ "webpack/container/remote/react": [
/******/ "default",
/******/ "./react",

2
dist/runtime.js.map vendored

File diff suppressed because one or more lines are too long

2
dist/taro.js.map vendored
View File

@@ -1 +1 @@
{"version":3,"file":"taro.js","mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;ACvCA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;ACrCA;AACA;AACA;AACA;;;;;;;;;;;;ACHA;AACA;AACA;AACA","sources":["webpack://taro-template/.._.._taro-components_mini_index.js","webpack://taro-template/.._src_components-react.ts","webpack://taro-template/._node_modules_.pnpm_@tarojs+webpack5-runner@4.0.8_@babel+core@7.26.0_@swc+core@1.3.96_@tarojs+runtime@4.0.8_less@_bde7hlupvtnhjp5wnja2su6pqy_node_modules_@tarojs_webpack5-runner_dist_template_comp.js","webpack://taro-template/._node_modules_.pnpm_@tarojs+webpack5-runner@4.0.8_@babel+core@7.26.0_@swc+core@1.3.96_@tarojs+runtime@4.0.8_less@_bde7hlupvtnhjp5wnja2su6pqy_node_modules_@tarojs_webpack5-runner_dist_template_custom-wrapper.js"],"sourcesContent":["export const View = 'view'\nexport const Icon = 'icon'\nexport const Progress = 'progress'\nexport const RichText = 'rich-text'\nexport const Text = 'text'\nexport const Button = 'button'\nexport const Checkbox = 'checkbox'\nexport const CheckboxGroup = 'checkbox-group'\nexport const Form = 'form'\nexport const Input = 'input'\nexport const Label = 'label'\nexport const Picker = 'picker'\nexport const PickerView = 'picker-view'\nexport const PickerViewColumn = 'picker-view-column'\nexport const Radio = 'radio'\nexport const RadioGroup = 'radio-group'\nexport const Slider = 'slider'\nexport const Switch = 'switch'\nexport const CoverImage = 'cover-image'\nexport const Textarea = 'textarea'\nexport const CoverView = 'cover-view'\nexport const MovableArea = 'movable-area'\nexport const MovableView = 'movable-view'\nexport const ScrollView = 'scroll-view'\nexport const Swiper = 'swiper'\nexport const SwiperItem = 'swiper-item'\nexport const Navigator = 'navigator'\nexport const Audio = 'audio'\nexport const Camera = 'camera'\nexport const Image = 'image'\nexport const LivePlayer = 'live-player'\nexport const Video = 'video'\nexport const Canvas = 'canvas'\nexport const Ad = 'ad'\nexport const WebView = 'web-view'\nexport const Block = 'block'\nexport const Map = 'map'\nexport const Slot = 'slot'\nexport const NativeSlot = 'native-slot'\nexport const CustomWrapper = 'custom-wrapper'\n",null,"/* eslint-disable no-undef */\nimport { createRecursiveComponentConfig } from '@tarojs/runtime'\n// @ts-ignore\nComponent(createRecursiveComponentConfig())\n","/* eslint-disable no-undef */\nimport { createRecursiveComponentConfig } from '@tarojs/runtime'\n// @ts-ignore\nComponent(createRecursiveComponentConfig('custom-wrapper'))\n"],"names":[],"sourceRoot":""}
{"version":3,"sources":[""],"names":[],"mappings":"AAAA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA"}