From 93b9ee1d1c711de2e4a754b732122abcbdbc722a Mon Sep 17 00:00:00 2001 From: MrRaindrop Date: Thu, 18 Jan 2018 15:08:04 +0800 Subject: [PATCH] update --- .../{textarea.js => textarea/index.js} | 12 ++-------- src/components/textarea/style.css | 24 +++++++++++++++++++ 2 files changed, 26 insertions(+), 10 deletions(-) rename src/components/{textarea.js => textarea/index.js} (95%) create mode 100644 src/components/textarea/style.css diff --git a/src/components/textarea.js b/src/components/textarea/index.js similarity index 95% rename from src/components/textarea.js rename to src/components/textarea/index.js index 1b94dd3..7b3313d 100644 --- a/src/components/textarea.js +++ b/src/components/textarea/index.js @@ -16,14 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -const _css = ` -.weex-textarea { - font-size: 0.426667rem -} -.weex-textarea:focus { - outline: none; -} -` +import './style.css' function getTextarea (weex) { const { extractComponentStyle } = weex @@ -74,8 +67,7 @@ function getTextarea (weex) { staticClass: 'weex-textarea weex-el', staticStyle: extractComponentStyle(this) }) - }, - _css + } } } diff --git a/src/components/textarea/style.css b/src/components/textarea/style.css new file mode 100644 index 0000000..243ad1d --- /dev/null +++ b/src/components/textarea/style.css @@ -0,0 +1,24 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +.weex-textarea { + font-size: 0.426667rem +} +.weex-textarea:focus { + outline: none; +}