Skip to content

Commit

Permalink
update extensions
Browse files Browse the repository at this point in the history
  • Loading branch information
mip-platform committed Jun 15, 2017
1 parent 196e3ab commit 4b9eb53
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions mip-shouji-down/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ mip-shouji-down 下载站定制组件,主要用于导航切换与下载按钮

### 基本用法
```html
<mip-shouji-down type="1"></mip-shouji-down>
<mip-shouji-down down="URL"></mip-shouji-down>
```

## 属性

### type
### down

说明:类型
说明:网址
必选项:否
12 changes: 6 additions & 6 deletions mip-shouji-down/mip-shouji-down.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* @author: Qi
* @date: 2017-6-13
* @date: 2017-6-15
* @file: mip-shouji-down.js
*/

Expand Down Expand Up @@ -33,12 +33,12 @@ define(function (require) {
}
});
}
function htmlType() {
function htmlType(url) {
if (platform.isIos()) {
return false;
}
var Padownurl = $('.topdown a').attr('href') || '';
var Pbdownurl = $('.safe-link a').attr('href') || '';
var Pbdownurl = url || '';
if (Padownurl !== '' && Pbdownurl !== '') {
$('.topdown').hide();
$('.safe-link').hide();
Expand Down Expand Up @@ -73,9 +73,9 @@ define(function (require) {
// build 方法,元素插入到文档时执行,仅会执行一次
customElem.prototype.build = function () {
var Element = this.element;
var ToType = Element.getAttribute('type') || '';
if (ToType === '1') {
htmlType();
var ToDown = Element.getAttribute('down') || '';
if (ToDown !== '') {
htmlType(ToDown);
}
htmlSet();
};
Expand Down

0 comments on commit 4b9eb53

Please sign in to comment.