提交 bc15d63a 编写于 作者: S suzigang

feat: taro

上级 805616b0
registry=https://registry.npmjs.org
engine-strict=true
registry=http://registry.m.jd.com
engine-strict=true
\ No newline at end of file
// .nut-button {
// position: relative;
// display: inline-block;
// flex-shrink: 0;
// height: 30px;
// box-sizing: border-box;
// margin: 0;
// padding: 0;
// line-height: 30px;
// font-size: 16px;
// text-align: center;
// cursor: pointer;
// transition: opacity 0.2s;
// -webkit-appearance: none;
// user-select: none;
// touch-action: manipulation;
// }
@import './../../styles/variables.scss';
.nut-button {
position: relative;
display: inline-block;
flex-shrink: 0;
height: 30px;
height: $button-default-height;
box-sizing: border-box;
margin: 0;
padding: 0;
line-height: 30px;
font-size: 16px;
line-height: $button-default-line-height;
font-size: $button-default-font-size;
text-align: center;
cursor: pointer;
transition: opacity 0.2s;
-webkit-appearance: none;
user-select: none;
touch-action: manipulation;
.text {
margin-left: 5px;
}
&::before {
position: absolute;
top: 50%;
left: 50%;
width: 100%;
height: 100%;
background-color: $black;
border: inherit;
border-color: $black;
border-radius: inherit;
transform: translate(-50%, -50%);
opacity: 0;
content: ' ';
}
&:active::before {
opacity: 0.1;
}
&__warp {
height: 100%;
width: 100%;
display: flex;
align-items: center;
justify-content: center;
}
&--loading,
&--disabled {
&::before {
display: none;
}
}
&--default {
color: $button-default-color;
background: $button-default-bg-color;
border: $button-border-width solid $button-default-border-color;
}
&--primary {
color: $button-primary-color;
background: $button-primary-background-color;
border: $button-border-width solid transparent;
}
&--info {
color: $button-info-color;
background: $button-info-background-color;
border: $button-border-width solid transparent;
}
&--success {
color: $button-success-color;
background: $button-success-background-color;
border: $button-border-width solid transparent;
}
&--danger {
color: $button-danger-color;
background: $button-danger-background-color;
border: $button-border-width solid transparent;
}
&--warning {
color: $button-warning-color;
background: $button-warning-background-color;
border: $button-border-width solid transparent;
}
&--plain {
background: $button-plain-background-color;
&.nut-button--primary {
color: $button-primary-border-color;
border-color: $button-primary-border-color;
}
&.nut-button--info {
color: $button-info-border-color;
border-color: $button-info-border-color;
}
&.nut-button--success {
color: $button-success-border-color;
border-color: $button-success-border-color;
}
&.nut-button--danger {
color: $button-danger-border-color;
border-color: $button-danger-border-color;
}
&.nut-button--warning {
color: $button-warning-border-color;
border-color: $button-warning-border-color;
}
}
&--large {
width: 100%;
height: $button-large-height;
line-height: $button-large-line-height;
}
&--normal {
padding: 0 18px;
font-size: $button-default-font-size;
}
&--small {
height: $button-small-height;
line-height: $button-small-line-height;
padding: 0 $padding-xs;
font-size: $font-size-1;
}
&--block {
display: block;
width: 100%;
}
&--disabled {
cursor: not-allowed;
opacity: $button-disabled-opacity;
}
&--loading {
cursor: default;
opacity: 0.9;
}
&--round {
border-radius: $button-border-radius;
}
&--square {
border-radius: 0;
}
}
......@@ -12,7 +12,8 @@
<script lang="ts">
import { PropType, CSSProperties, toRefs, computed } from 'vue';
import { createComponent } from './../../../packages/utils/create';
// import { createComponent } from '@packages/utils/create';
import { createComponent } from './../../utils/create';
const { componentName, create } = createComponent('button');
export type ButtonType =
......
import { App } from 'vue';
import Button from './__VUE/button/index.taro.vue';
// import Collapse from './__VUE/collapse/index.taro.vue';
// import Layout from './__VUE/layout/index.taro.vue';
// import BackTop from './__VUE/backtop/index.taro.vue';
// import ActionSheet from './__VUE/actionsheet/index.taro.vue';
// import Toast from './__VUE/toast/index';
// import Notify from './__VUE/notify/index.taro.vue';
// import Picker from './__VUE/picker/index.taro.vue';
// import DatePicker from './__VUE/datepicker/index.taro.vue';
// import Cell from './__VUE/cell/index.taro.vue';
// import Uploader from './__VUE/uploader/index.taro.vue';
import Collapse from './__VUE/collapse/index.taro.vue';
import Layout from './__VUE/layout/index.taro.vue';
import BackTop from './__VUE/backtop/index.taro.vue';
import ActionSheet from './__VUE/actionsheet/index.taro.vue';
import Toast from './__VUE/toast/index';
import Notify from './__VUE/notify/index.taro.vue';
import Picker from './__VUE/picker/index.taro.vue';
import DatePicker from './__VUE/datepicker/index.taro.vue';
import Cell from './__VUE/cell/index.taro.vue';
import Uploader from './__VUE/uploader/index.taro.vue';
import Icon from './__VUE/icon/index.taro.vue';
// import Price from './__VUE/price/index.taro.vue';
// import Checkbox from './__VUE/checkbox/index.taro.vue';
// import Swiper from './__VUE/swiper/index.taro.vue';
// import Avatar from './__VUE/avatar/index.taro.vue';
// import Popup from './__VUE/popup/index.taro.vue';
// import Dialog from './__VUE/dialog/index';
// import Radio from './__VUE/radio/index.taro.vue';
// import OverLay from './__VUE/overlay/index.taro.vue';
// import InfiniteLoading from './__VUE/infiniteloading/index.taro.vue';
// import Range from './__VUE/range/index.taro.vue';
// import Drag from './__VUE/drag/index.taro.vue';
// import Steps from './__VUE/steps/index.taro.vue';
// import Navbar from './__VUE/navbar/index.taro.vue';
// import Tabbar from './__VUE/tabbar/index.taro.vue';
// import InputNumber from './__VUE/inputnumber/index.taro.vue';
// import Input from './__VUE/input/index.taro.vue';
// import Switch from './__VUE/switch/index.taro.vue';
// import Rate from './__VUE/rate/index.taro.vue';
// import Calendar from './__VUE/calendar/index.taro.vue';
// import ShortPassword from './__VUE/shortpassword/index.taro.vue';
// import TextArea from './__VUE/textarea/index.taro.vue';
// import Address from './__VUE/address/index.taro.vue';
import Price from './__VUE/price/index.taro.vue';
import Checkbox from './__VUE/checkbox/index.taro.vue';
import Swiper from './__VUE/swiper/index.taro.vue';
import Avatar from './__VUE/avatar/index.taro.vue';
import Popup from './__VUE/popup/index.taro.vue';
import Dialog from './__VUE/dialog/index';
import Radio from './__VUE/radio/index.taro.vue';
import OverLay from './__VUE/overlay/index.taro.vue';
import InfiniteLoading from './__VUE/infiniteloading/index.taro.vue';
import Range from './__VUE/range/index.taro.vue';
import Drag from './__VUE/drag/index.taro.vue';
import Steps from './__VUE/steps/index.taro.vue';
import Navbar from './__VUE/navbar/index.taro.vue';
import Tabbar from './__VUE/tabbar/index.taro.vue';
import InputNumber from './__VUE/inputnumber/index.taro.vue';
import Input from './__VUE/input/index.taro.vue';
import Switch from './__VUE/switch/index.taro.vue';
import Rate from './__VUE/rate/index.taro.vue';
import Calendar from './__VUE/calendar/index.taro.vue';
import ShortPassword from './__VUE/shortpassword/index.taro.vue';
import TextArea from './__VUE/textarea/index.taro.vue';
import Address from './__VUE/address/index.taro.vue';
function install(app: App) {
const packages = [Button, Icon];
const packages = [
Button,
Collapse,
Layout,
BackTop,
ActionSheet,
Toast,
Notify,
Picker,
DatePicker,
Cell,
Uploader,
Icon,
Price,
Checkbox,
Swiper,
Avatar,
Popup,
Dialog,
Radio,
OverLay,
InfiniteLoading,
Range,
Drag,
Steps,
Navbar,
Tabbar,
InputNumber,
Input,
Switch,
Rate,
Calendar,
ShortPassword,
TextArea,
Address
];
packages.forEach((item: any) => {
if (item.install) {
app.use(item);
......@@ -44,5 +79,40 @@ function install(app: App) {
}
});
}
export { Button, Icon };
export {
Button,
Collapse,
Layout,
BackTop,
ActionSheet,
Toast,
Notify,
Picker,
DatePicker,
Cell,
Uploader,
Icon,
Price,
Checkbox,
Swiper,
Avatar,
Popup,
Dialog,
Radio,
OverLay,
InfiniteLoading,
Range,
Drag,
Steps,
Navbar,
Tabbar,
InputNumber,
Input,
Switch,
Rate,
Calendar,
ShortPassword,
TextArea,
Address
};
export default { install, version: '3.0.0-beta.16' };
此差异已折叠。
此差异已折叠。
此差异已折叠。
......@@ -77,14 +77,6 @@
</image>
</template>
<template name="tmpl_0_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_0_#text" data="{{i:i}}">
<block>{{i.v}}</block>
</template>
......@@ -149,14 +141,6 @@
</scroll-view>
</template>
<template name="tmpl_1_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_1_container">
<template is="{{xs.a(1, i.nn, l)}}" data="{{i:i,cid:1,l:xs.f(l,i.nn)}}" />
</template>
......@@ -217,14 +201,6 @@
</scroll-view>
</template>
<template name="tmpl_2_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_2_container">
<template is="{{xs.a(2, i.nn, l)}}" data="{{i:i,cid:2,l:xs.f(l,i.nn)}}" />
</template>
......@@ -285,14 +261,6 @@
</scroll-view>
</template>
<template name="tmpl_3_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_3_container">
<template is="{{xs.a(3, i.nn, l)}}" data="{{i:i,cid:3,l:xs.f(l,i.nn)}}" />
</template>
......@@ -345,14 +313,6 @@
</text>
</template>
<template name="tmpl_4_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_4_container">
<template is="{{xs.a(4, i.nn, l)}}" data="{{i:i,cid:4,l:xs.f(l,i.nn)}}" />
</template>
......@@ -405,14 +365,6 @@
</text>
</template>
<template name="tmpl_5_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_5_container">
<template is="{{xs.a(5, i.nn, l)}}" data="{{i:i,cid:5,l:xs.f(l,i.nn)}}" />
</template>
......@@ -457,14 +409,6 @@
</text>
</template>
<template name="tmpl_6_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_6_container">
<template is="{{xs.a(6, i.nn, l)}}" data="{{i:i,cid:6,l:xs.f(l,i.nn)}}" />
</template>
......@@ -509,14 +453,6 @@
</text>
</template>
<template name="tmpl_7_slot">
<view slot="{{i.name}}" id="{{i.uid}}">
<block wx:for="{{i.cn}}" wx:key="uid">
<template is="{{xs.e(cid+1)}}" data="{{i:item,l:l}}" />
</block>
</view>
</template>
<template name="tmpl_7_container">
<template is="{{xs.a(7, i.nn, l)}}" data="{{i:i,cid:7,l:xs.f(l,i.nn)}}" />
</template>
......
(wx['webpackJsonp'] = wx['webpackJsonp'] || []).push([
['comp'],
[],
[
[
'./node_modules/@tarojs/mini-runner/dist/template/comp.js',
'runtime',
'taro',
'vendors'
]
]
]);
//# sourceMappingURL=comp.js.map
{"version":3,"file":"comp.js","sources":[],"mappings":"","sourceRoot":""}
\ No newline at end of file
(wx['webpackJsonp'] = wx['webpackJsonp'] || []).push([
['custom-wrapper'],
[],
[
[
'./node_modules/@tarojs/mini-runner/dist/template/custom-wrapper.js',
'runtime',
'taro',
'vendors'
]
]
]);
//# sourceMappingURL=custom-wrapper.js.map
{"version":3,"file":"custom-wrapper.js","sources":[],"mappings":"","sourceRoot":""}
\ No newline at end of file
{"version":3,"file":"pages/button/index.js","sources":["webpack:////Users/suzigang/Downloads/project/nutui3.0/nutui/src/packages/__VUE/button/demo.vue?56cb","webpack:////Users/suzigang/Downloads/project/nutui3.0/nutui/src/packages/__VUE/button/demo.vue?4012","webpack:////Users/suzigang/Downloads/project/nutui3.0/nutui/src/packages/__VUE/button/demo.vue?ed72","webpack:////Users/suzigang/Downloads/project/nutui3.0/nutui/src/packages/__VUE/button/demo.vue?819b","webpack:////Users/suzigang/Downloads/project/nutui3.0/nutui/src/packages/__VUE/button/demo.vue","webpack:///./src/pages/button/index.vue","webpack:///./src/pages/button/index.vue?ed02","webpack:////Users/suzigang/Downloads/project/nutui3.0/nutui/src/packages/__VUE/button/demo.vue?b73c","webpack:///./src/pages/button/index.vue?b5b8","webpack:///./src/pages/button/index.vue?0e9d","webpack:///./src/pages/button/index.vue?c858"],"sourcesContent":["import { render } from \"./demo.vue?vue&type=template&id=77e39083\"\nimport script from \"./demo.vue?vue&type=script&lang=ts\"\nexport * from \"./demo.vue?vue&type=script&lang=ts\"\n\nimport \"./demo.vue?vue&type=style&index=0&id=77e39083&lang=scss\"\nscript.render = render\n/* hot reload */\nif (module.hot) {\n script.__hmrId = \"77e39083\"\n const api = __VUE_HMR_RUNTIME__\n module.hot.accept()\n if (!api.createRecord('77e39083', script)) {\n api.reload('77e39083', script)\n }\n \n module.hot.accept(\"./demo.vue?vue&type=template&id=77e39083\", () => {\n api.rerender('77e39083', render)\n })\n\n}\n\nscript.__file = \"packages/__VUE/button/demo.vue\"\n\nexport default script","export { default } from \"-!../../../sites/mobile-taro/vue/node_modules/@tarojs/mini-runner/node_modules/babel-loader/lib/index.js!../../../sites/mobile-taro/vue/node_modules/vue-loader/dist/index.js??ref--10-0!./demo.vue?vue&type=script&lang=ts\"; export * from \"-!../../../sites/mobile-taro/vue/node_modules/@tarojs/mini-runner/node_modules/babel-loader/lib/index.js!../../../sites/mobile-taro/vue/node_modules/vue-loader/dist/index.js??ref--10-0!./demo.vue?vue&type=script&lang=ts\"","export * from \"-!../../../sites/mobile-taro/vue/node_modules/mini-css-extract-plugin/dist/loader.js!../../../sites/mobile-taro/vue/node_modules/@tarojs/mini-runner/node_modules/css-loader/dist/cjs.js??ref--1-oneOf-0-1!../../../sites/mobile-taro/vue/node_modules/vue-loader/dist/stylePostLoader.js!../../../sites/mobile-taro/vue/node_modules/postcss-loader/src/index.js??postcss!../../../sites/mobile-taro/vue/node_modules/@tarojs/mini-runner/node_modules/resolve-url-loader/index.js!../../../sites/mobile-taro/vue/node_modules/sass-loader/dist/cjs.js??ref--1-oneOf-0-4!../../../sites/mobile-taro/vue/node_modules/vue-loader/dist/index.js??ref--10-0!./demo.vue?vue&type=style&index=0&id=77e39083&lang=scss\"","export * from \"-!../../../sites/mobile-taro/vue/node_modules/@tarojs/mini-runner/node_modules/babel-loader/lib/index.js!../../../sites/mobile-taro/vue/node_modules/vue-loader/dist/templateLoader.js??ref--6!../../../sites/mobile-taro/vue/node_modules/vue-loader/dist/index.js??ref--10-0!./demo.vue?vue&type=template&id=77e39083\"","<template>\n <view class=\"demo\">\n <view class=\"h2\">按钮类型</view>\n <view class=\"demo-button-row\">\n <nut-button type=\"primary\">主要按钮</nut-button>\n <nut-button type=\"info\">信息按钮</nut-button>\n <nut-button type=\"default\">默认按钮</nut-button>\n </view>\n <view class=\"demo-button-row2\">\n <nut-button type=\"danger\">危险按钮</nut-button>\n <nut-button type=\"warning\">警告按钮</nut-button>\n <nut-button type=\"success\">成功按钮</nut-button>\n </view>\n <view>朴素按钮</view>\n <view class=\"demo-button-row2\">\n <nut-button plain type=\"primary\">朴素按钮</nut-button>\n <nut-button plain type=\"info\">朴素按钮</nut-button>\n </view>\n <view>禁用状态</view>\n <view class=\"demo-button-row2\">\n <nut-button disabled type=\"primary\">禁用状态</nut-button>\n <nut-button plain disabled type=\"info\">禁用状态</nut-button>\n <nut-button plain disabled type=\"primary\">禁用状态</nut-button>\n </view>\n <view>按钮形状</view>\n <view class=\"demo-button-row2\">\n <nut-button shape=\"square\" type=\"primary\">方形按钮</nut-button>\n <nut-button type=\"info\">圆形按钮</nut-button>\n </view>\n <view>加载状态</view>\n <view class=\"demo-button-row2\">\n <nut-button loading type=\"info\"></nut-button>\n <nut-button loading type=\"warning\">加载中...</nut-button>\n <nut-button :loading=\"isLoading\" type=\"success\" @click=\"changeLoading\"\n >Click me!</nut-button\n >\n </view>\n <view>图标按钮</view>\n <view class=\"demo-button-row2\">\n <nut-button\n shape=\"square\"\n plain\n type=\"primary\"\n icon=\"star-fill\"\n ></nut-button>\n <nut-button shape=\"square\" type=\"primary\" icon=\"star\">收藏</nut-button>\n </view>\n\n <view>按钮尺寸</view>\n <view class=\"demo-button-row2\">\n <nut-button size=\"large\" type=\"primary\" style=\"margin-bottom: 10px\"\n >大号按钮</nut-button\n >\n <nut-button type=\"primary\">普通按钮</nut-button>\n <nut-button size=\"small\" type=\"primary\">小型按钮</nut-button>\n </view>\n <view>块级元素</view>\n <view class=\"demo-button-row2\">\n <nut-button block type=\"primary\">块级元素</nut-button>\n </view>\n <view>自定义颜色</view>\n <view class=\"demo-button-row2\">\n <nut-button color=\"#7232dd\">单色按钮</nut-button>\n <nut-button color=\"#7232dd\" plain>单色按钮</nut-button>\n <nut-button color=\"linear-gradient(to right, #ff6034, #ee0a24)\">\n 渐变按钮\n </nut-button>\n </view>\n </view>\n</template>\n\n<script lang=\"ts\">\nimport { ref, defineComponent } from 'vue';\n// import { createComponent } from './../../utils/create';\n// const { createDemo } = createComponent('button');\nexport default defineComponent({\n props: {},\n setup(props) {\n let isLoading = ref(false);\n const changeLoading = () => {\n isLoading.value = true;\n setTimeout(() => {\n isLoading.value = false;\n }, 3000);\n };\n\n return {\n isLoading,\n changeLoading\n };\n }\n});\n</script>\n\n<style lang=\"scss\">\n.h2 {\n margin-top: 30px;\n margin-bottom: 10px;\n font-size: 14px;\n color: #909ca4;\n padding: 0 10px;\n font-weight: 400;\n}\nview {\n display: block;\n}\n.demo-button-row {\n margin-bottom: 20px;\n}\n.demo-button-row2 {\n margin-bottom: 10px;\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n}\n.nut-button {\n margin-right: 15px;\n &:last-child {\n margin-bottom: 0;\n margin-right: 0;\n }\n}\n</style>\n","<template>\n <view>\n <nut-button type=\"primary\">主要按钮</nut-button>\n <!-- <nut-icon name=\"dongdong\"></nut-icon> -->\n <Demo></Demo>\n </view>\n</template>\n<script lang=\"ts\">\nimport { defineComponent } from 'vue';\nimport Demo from './../../../../../../packages/__VUE/button/demo.vue';\nexport default defineComponent({\n components: {\n Demo\n }\n})\n</script>\n","import { render } from \"./index.vue?vue&type=template&id=cbda188e\"\nimport script from \"./index.vue?vue&type=script&lang=ts\"\nexport * from \"./index.vue?vue&type=script&lang=ts\"\nscript.render = render\n/* hot reload */\nif (module.hot) {\n script.__hmrId = \"cbda188e\"\n const api = __VUE_HMR_RUNTIME__\n module.hot.accept()\n if (!api.createRecord('cbda188e', script)) {\n api.reload('cbda188e', script)\n }\n \n module.hot.accept(\"./index.vue?vue&type=template&id=cbda188e\", () => {\n api.rerender('cbda188e', render)\n })\n\n}\n\nscript.__file = \"src/pages/button/index.vue\"\n\nexport default script","// extracted by mini-css-extract-plugin","import { createPageConfig } from '@tarojs/runtime'\nimport component from \"../../../node_modules/@tarojs/taro-loader/lib/raw.js!./index.vue\"\nvar config = {\"navigationBarTitleText\":\"Button\"};\n\n\nvar inst = Page(createPageConfig(component, 'pages/button/index', {root:{cn:[]}}, config || {}))\n\n","export { default } from \"-!../../../node_modules/@tarojs/mini-runner/node_modules/babel-loader/lib/index.js!../../../node_modules/vue-loader/dist/index.js??ref--10-0!./index.vue?vue&type=script&lang=ts\"; export * from \"-!../../../node_modules/@tarojs/mini-runner/node_modules/babel-loader/lib/index.js!../../../node_modules/vue-loader/dist/index.js??ref--10-0!./index.vue?vue&type=script&lang=ts\"","export * from \"-!../../../node_modules/@tarojs/mini-runner/node_modules/babel-loader/lib/index.js!../../../node_modules/vue-loader/dist/templateLoader.js??ref--6!../../../node_modules/vue-loader/dist/index.js??ref--10-0!./index.vue?vue&type=template&id=cbda188e\""],"mappings":"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","sourceRoot":""}
\ No newline at end of file
.h2 {
margin-top: 30rpx;
margin-bottom: 10rpx;
font-size: 14rpx;
color: #909ca4;
padding: 0 10rpx;
font-weight: 400;
}
view {
display: block;
}
.demo-button-row {
margin-bottom: 20rpx;
}
.demo-button-row2 {
margin-bottom: 10rpx;
display: flex;
align-items: center;
flex-wrap: wrap;
}
.nut-button {
margin-right: 15rpx;
}
.nut-button:last-child {
margin-bottom: 0;
margin-right: 0;
}
{
"miniprogramRoot": "./",
"projectname": "myApp",
"description": "taro-vue",
"appid": "wxee296c9bffc451d9",
"setting": {
"urlCheck": true,
"es6": false,
"enhance": false,
"postcss": false,
"preloadBackgroundData": false,
"minified": false,
"newFeature": false,
"coverView": true,
"nodeModules": false,
"autoAudits": false,
"showShadowRootInWxmlPanel": true,
"scopeDataCheck": false,
"uglifyFileName": false,
"checkInvalidKey": true,
"checkSiteMap": true,
"uploadWithSourceMap": true,
"compileHotReLoad": false,
"useMultiFrameRuntime": true,
"useApiHook": true,
"useApiHostProcess": true,
"babelSetting": {
"ignore": [],
"disablePlugins": [],
"outputPath": ""
},
"enableEngineNative": false,
"useIsolateContext": true,
"useCompilerModule": true,
"userConfirmedUseCompilerModuleSwitch": false,
"userConfirmedBundleSwitch": false,
"packNpmManually": false,
"packNpmRelationList": [],
"minifyWXSS": true
},
"compileType": "miniprogram",
"condition": {}
}
\ No newline at end of file
/******/ (function(modules) {
// webpackBootstrap
/******/ // install a JSONP callback for chunk loading
/******/ function webpackJsonpCallback(data) {
/******/ var chunkIds = data[0];
/******/ var moreModules = data[1];
/******/ var executeModules = data[2]; // add "moreModules" to the modules object, // then flag all "chunkIds" as loaded and fire callback
/******/
/******/ /******/ /******/ var moduleId,
chunkId,
i = 0,
resolves = [];
/******/ for (; i < chunkIds.length; i++) {
/******/ chunkId = chunkIds[i];
/******/ if (
Object.prototype.hasOwnProperty.call(installedChunks, chunkId) &&
installedChunks[chunkId]
) {
/******/ resolves.push(installedChunks[chunkId][0]);
/******/
}
/******/ installedChunks[chunkId] = 0;
/******/
}
/******/ for (moduleId in moreModules) {
/******/ if (
Object.prototype.hasOwnProperty.call(moreModules, moduleId)
) {
/******/ modules[moduleId] = moreModules[moduleId];
/******/
}
/******/
}
/******/ if (parentJsonpFunction) parentJsonpFunction(data);
/******/
/******/ while (resolves.length) {
/******/ resolves.shift()();
/******/
} // add entry modules from loaded chunk to deferred list
/******/
/******/ /******/ deferredModules.push.apply(
deferredModules,
executeModules || []
); // run deferred modules when all chunks ready
/******/
/******/ /******/ return checkDeferredModules();
/******/
}
/******/ function checkDeferredModules() {
/******/ var result;
/******/ for (var i = 0; i < deferredModules.length; i++) {
/******/ var deferredModule = deferredModules[i];
/******/ var fulfilled = true;
/******/ for (var j = 1; j < deferredModule.length; j++) {
/******/ var depId = deferredModule[j];
/******/ if (installedChunks[depId] !== 0) fulfilled = false;
/******/
}
/******/ if (fulfilled) {
/******/ deferredModules.splice(i--, 1);
/******/ result = __webpack_require__(
(__webpack_require__.s = deferredModule[0])
);
/******/
}
/******/
}
/******/
/******/ return result;
/******/
} // The module cache
/******/
/******/ /******/ var installedModules = {}; // object to store loaded and loading chunks // undefined = chunk not loaded, null = chunk preloaded/prefetched // Promise = chunk loading, 0 = chunk loaded
/******/
/******/ /******/ /******/ /******/ var installedChunks = {
/******/ runtime: 0
/******/
};
/******/
/******/ var deferredModules = []; // The require function
/******/
/******/ /******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if (installedModules[moduleId]) {
/******/ return installedModules[moduleId].exports;
/******/
} // Create a new module (and put it into the cache)
/******/ /******/ var module = (installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/
}); // Execute the module function
/******/
/******/ /******/ modules[moduleId].call(
module.exports,
module,
module.exports,
__webpack_require__
); // Flag the module as loaded
/******/
/******/ /******/ module.l = true; // Return the exports of the module
/******/
/******/ /******/ return module.exports;
/******/
} // expose the modules object (__webpack_modules__)
/******/
/******/
/******/ /******/ __webpack_require__.m = modules; // expose the module cache
/******/
/******/ /******/ __webpack_require__.c = installedModules; // define getter function for harmony exports
/******/
/******/ /******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if (!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, {
enumerable: true,
get: getter
});
/******/
}
/******/
}; // define __esModule on exports
/******/
/******/ /******/ __webpack_require__.r = function(exports) {
/******/ if (typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ Object.defineProperty(exports, Symbol.toStringTag, {
value: 'Module'
});
/******/
}
/******/ Object.defineProperty(exports, '__esModule', { value: true });
/******/
}; // create a fake namespace object // mode & 1: value is a module id, require it // mode & 2: merge all properties of value into the ns // mode & 4: return value when already ns object // mode & 8|1: behave like require
/******/
/******/ /******/ /******/ /******/ /******/ /******/ __webpack_require__.t = function(
value,
mode
) {
/******/ if (mode & 1) value = __webpack_require__(value);
/******/ if (mode & 8) return value;
/******/ if (
mode & 4 &&
typeof value === 'object' &&
value &&
value.__esModule
)
return value;
/******/ var ns = Object.create(null);
/******/ __webpack_require__.r(ns);
/******/ Object.defineProperty(ns, 'default', {
enumerable: true,
value: value
});
/******/ if (mode & 2 && typeof value != 'string')
for (var key in value)
__webpack_require__.d(
ns,
key,
function(key) {
return value[key];
}.bind(null, key)
);
/******/ return ns;
/******/
}; // getDefaultExport function for compatibility with non-harmony modules
/******/
/******/ /******/ __webpack_require__.n = function(module) {
/******/ var getter =
module && module.__esModule
? /******/ function getDefault() {
return module['default'];
}
: /******/ function getModuleExports() {
return module;
};
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/
}; // Object.prototype.hasOwnProperty.call
/******/
/******/ /******/ __webpack_require__.o = function(object, property) {
return Object.prototype.hasOwnProperty.call(object, property);
}; // __webpack_public_path__
/******/
/******/ /******/ __webpack_require__.p = '/';
/******/
/******/ var jsonpArray = (wx['webpackJsonp'] = wx['webpackJsonp'] || []);
/******/ var oldJsonpFunction = jsonpArray.push.bind(jsonpArray);
/******/ jsonpArray.push = webpackJsonpCallback;
/******/ jsonpArray = jsonpArray.slice();
/******/ for (var i = 0; i < jsonpArray.length; i++)
webpackJsonpCallback(jsonpArray[i]);
/******/ var parentJsonpFunction = oldJsonpFunction; // run deferred modules from other chunks
/******/
/******/
/******/ /******/ checkDeferredModules();
/******/
})(
/************************************************************************/
/******/ []
);
//# sourceMappingURL=runtime.js.map
{"version":3,"file":"runtime.js","sources":["webpack:///webpack/bootstrap"],"sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tfunction webpackJsonpCallback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n \t\tvar executeModules = data[2];\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t\t// add entry modules from loaded chunk to deferred list\n \t\tdeferredModules.push.apply(deferredModules, executeModules || []);\n\n \t\t// run deferred modules when all chunks ready\n \t\treturn checkDeferredModules();\n \t};\n \tfunction checkDeferredModules() {\n \t\tvar result;\n \t\tfor(var i = 0; i < deferredModules.length; i++) {\n \t\t\tvar deferredModule = deferredModules[i];\n \t\t\tvar fulfilled = true;\n \t\t\tfor(var j = 1; j < deferredModule.length; j++) {\n \t\t\t\tvar depId = deferredModule[j];\n \t\t\t\tif(installedChunks[depId] !== 0) fulfilled = false;\n \t\t\t}\n \t\t\tif(fulfilled) {\n \t\t\t\tdeferredModules.splice(i--, 1);\n \t\t\t\tresult = __webpack_require__(__webpack_require__.s = deferredModule[0]);\n \t\t\t}\n \t\t}\n\n \t\treturn result;\n \t}\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t\"runtime\": 0\n \t};\n\n \tvar deferredModules = [];\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/\";\n\n \tvar jsonpArray = wx[\"webpackJsonp\"] = wx[\"webpackJsonp\"] || [];\n \tvar oldJsonpFunction = jsonpArray.push.bind(jsonpArray);\n \tjsonpArray.push = webpackJsonpCallback;\n \tjsonpArray = jsonpArray.slice();\n \tfor(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]);\n \tvar parentJsonpFunction = oldJsonpFunction;\n\n\n \t// run deferred modules from other chunks\n \tcheckDeferredModules();\n"],"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;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;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;A","sourceRoot":""}
\ No newline at end of file
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
......@@ -43,7 +43,6 @@
},
"devDependencies": {
"@babel/core": "^7.8.0",
"@nutui/nutui": "^3.0.0-beta.15",
"@tarojs/cli": "^3.3.0-alpha.2",
"@tarojs/mini-runner": "^3.3.0-alpha.2",
"@tarojs/plugin-html": "^3.3.0-alpha.2",
......
import { createApp } from 'vue';
import './app.scss';
import { Button, Icon } from './../../../../packages/nutui.taro.vue';
import NUTUI from '@/packages/nutui.taro.vue';
// import NUTUI from './../../../../packages/nutui.taro.vue';
console.log(Button);
console.log(NUTUI);
const App = createApp({
onShow() {}
// 入口组件不需要实现 render 方法,即使实现了也会被 taro 所覆盖
})
.use(Button)
.use(Icon);
// .use(Button)
.use(NUTUI);
export default App;
<template>
<view>
<nut-button type="primary">主要按钮</nut-button>
<!-- <nut-icon name="dongdong"></nut-icon> -->
<Demo></Demo>
</view>
</template>
<script lang="ts">
import { defineComponent } from 'vue';
import Demo from './../../../../../../packages/__VUE/button/demo.vue';
import Demo from '@/packages/__VUE/button/demo.vue';
// import Demo from './../../../../../../packages/__VUE/button/demo.vue';
export default defineComponent({
components: {
Demo
......
......@@ -8,24 +8,32 @@
"experimentalDecorators": true,
"noImplicitAny": false,
"allowSyntheticDefaultImports": true,
"outDir": "lib",
"outDir": "./../../../../tsc/test/test",
"noUnusedLocals": true,
"noUnusedParameters": true,
"strictNullChecks": true,
"sourceMap": true,
"baseUrl": ".",
"rootDir": ".",
"baseUrl": "./../../../../src",
"jsx": "react-jsx",
"allowJs": true,
"composite": true,
"resolveJsonModule": true,
"typeRoots": [
"node_modules/@types",
"global.d.ts"
],
"paths": {
"@/*": ["./../../../../src/*"]
}
},
"references": [
{
"path": "./../../../../tsconfig.json",
}
],
"include": ["src/**/*.ts", "src/**/*.d.ts", "src/**/*.tsx", "src/**/*.vue"],
"exclude": [
"node_modules",
"dist"
],
"compileOnSave": false
}
......@@ -8,13 +8,13 @@
"strict": true,
"jsx": "preserve",
"sourceMap": false,
"declaration": false,
"removeComments": true,
"resolveJsonModule": true,
"esModuleInterop": true,
"lib": ["esnext", "dom"],
"outDir": "./tsc/test",
"types": ["vite/client", "jest"],
"composite": true,
"paths": {
"@/*": ["src/*"]
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册