From 0884dd7f5bf59fc8b72f363a6e42e9ac23881822 Mon Sep 17 00:00:00 2001
From: haoziqaq <357229046@qq.com>
Date: Wed, 13 Jan 2021 19:16:36 +0800
Subject: [PATCH] =?UTF-8?q?fix(ui/icon):=20icon=20name=E6=94=AF=E6=8C=81?=
=?UTF-8?q?=E5=9B=BE=E7=89=87=E5=9C=B0=E5=9D=80?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
affects: @varlet/cli, @varlet/ui
---
.../src/config/webpack.base.config.ts | 12 +---
packages/varlet-ui/src/icon/Icon.vue | 14 +++++
packages/varlet-ui/src/icon/example/index.vue | 11 +++-
packages/varlet-ui/src/icon/icon.less | 6 ++
packages/varlet-ui/src/input/Input.vue | 15 +++++
.../src/input/__tests__/index.spec.js | 7 +++
packages/varlet-ui/src/input/docs/en_US.md | 0
packages/varlet-ui/src/input/docs/zh_CN.md | 0
.../varlet-ui/src/input/example/index.vue | 21 +++++++
packages/varlet-ui/src/input/index.ts | 8 +++
packages/varlet-ui/src/input/input.less | 3 +
packages/varlet-ui/src/menu/example/index.vue | 1 -
packages/varlet-ui/src/menu/menu.less | 3 +
packages/varlet-ui/src/tab/Tab.vue | 2 +
packages/varlet-ui/src/tab/provide.ts | 1 +
.../varlet-ui/src/tabs-items/TabsItems.vue | 14 +----
packages/varlet-ui/src/tabs/Tabs.vue | 2 +-
packages/varlet-ui/src/utils/shared.ts | 2 +
packages/varlet-ui/varlet.config.js | 56 +++++++++++++++++++
19 files changed, 150 insertions(+), 28 deletions(-)
create mode 100644 packages/varlet-ui/src/input/Input.vue
create mode 100644 packages/varlet-ui/src/input/__tests__/index.spec.js
create mode 100644 packages/varlet-ui/src/input/docs/en_US.md
create mode 100644 packages/varlet-ui/src/input/docs/zh_CN.md
create mode 100644 packages/varlet-ui/src/input/example/index.vue
create mode 100644 packages/varlet-ui/src/input/index.ts
create mode 100644 packages/varlet-ui/src/input/input.less
diff --git a/packages/varlet-cli/src/config/webpack.base.config.ts b/packages/varlet-cli/src/config/webpack.base.config.ts
index ac53f1c76ea..7f0cc8051eb 100644
--- a/packages/varlet-cli/src/config/webpack.base.config.ts
+++ b/packages/varlet-cli/src/config/webpack.base.config.ts
@@ -50,17 +50,7 @@ export function createBabelConfig() {
return {
loader: 'babel-loader',
options: {
- presets: [
- [
- '@babel/preset-env',
- {
- targets: {
- chrome: '58',
- ie: '11',
- },
- },
- ],
- ],
+ presets: ['@babel/preset-env'],
plugins: ['@babel/plugin-transform-runtime'],
},
}
diff --git a/packages/varlet-ui/src/icon/Icon.vue b/packages/varlet-ui/src/icon/Icon.vue
index 22058d1c405..1a616458260 100644
--- a/packages/varlet-ui/src/icon/Icon.vue
+++ b/packages/varlet-ui/src/icon/Icon.vue
@@ -1,16 +1,29 @@
+
+
+
+
diff --git a/packages/varlet-ui/src/input/__tests__/index.spec.js b/packages/varlet-ui/src/input/__tests__/index.spec.js
new file mode 100644
index 00000000000..68eab16bfa1
--- /dev/null
+++ b/packages/varlet-ui/src/input/__tests__/index.spec.js
@@ -0,0 +1,7 @@
+const Input = require('../../../cjs/input').default
+const { render } = require('@testing-library/vue')
+
+test('test input', async () => {
+ const wrapper = render(Input)
+ console.log(wrapper)
+})
diff --git a/packages/varlet-ui/src/input/docs/en_US.md b/packages/varlet-ui/src/input/docs/en_US.md
new file mode 100644
index 00000000000..e69de29bb2d
diff --git a/packages/varlet-ui/src/input/docs/zh_CN.md b/packages/varlet-ui/src/input/docs/zh_CN.md
new file mode 100644
index 00000000000..e69de29bb2d
diff --git a/packages/varlet-ui/src/input/example/index.vue b/packages/varlet-ui/src/input/example/index.vue
new file mode 100644
index 00000000000..5f0740a1e37
--- /dev/null
+++ b/packages/varlet-ui/src/input/example/index.vue
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
diff --git a/packages/varlet-ui/src/input/index.ts b/packages/varlet-ui/src/input/index.ts
new file mode 100644
index 00000000000..c0c90df2a44
--- /dev/null
+++ b/packages/varlet-ui/src/input/index.ts
@@ -0,0 +1,8 @@
+import { App } from 'vue'
+import Input from './Input.vue'
+
+Input.install = function(app: App) {
+ app.component(Input.name, Input)
+}
+
+export default Input
diff --git a/packages/varlet-ui/src/input/input.less b/packages/varlet-ui/src/input/input.less
new file mode 100644
index 00000000000..c6b9b6bce47
--- /dev/null
+++ b/packages/varlet-ui/src/input/input.less
@@ -0,0 +1,3 @@
+.var-input {
+
+}
diff --git a/packages/varlet-ui/src/menu/example/index.vue b/packages/varlet-ui/src/menu/example/index.vue
index 763ef60b576..6a16dd748c9 100644
--- a/packages/varlet-ui/src/menu/example/index.vue
+++ b/packages/varlet-ui/src/menu/example/index.vue
@@ -47,7 +47,6 @@ export default defineComponent({