@tuya-miniapp/smart-ui 2.1.1-beta-3 → 2.1.2-beta-1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,6 +1,6 @@
1
1
  <view class="contain">
2
2
  <smart-row>
3
- <smart-col wx:for="{{months}}" wx:key="index" span="6" custom-class="col_item">
3
+ <smart-col wx:for="{{months}}" span="6" custom-class="col_item">
4
4
  <view wx:if="{{item.type === 'disabled'}}" class="item item_disabled" data-index="{{index}}">
5
5
  {{item.text}}
6
6
  </view>
@@ -1,6 +1,6 @@
1
1
  <view class="contain">
2
2
  <smart-row>
3
- <smart-col wx:for="{{years}}" wx:key="index" span="6" custom-class="col_item">
3
+ <smart-col wx:for="{{years}}" span="6" custom-class="col_item">
4
4
  <view wx:if="{{item.type === 'disabled'}}" class="item item_disabled" data-index="{{index}}">
5
5
  {{item.text}}
6
6
  </view>
@@ -1 +1 @@
1
- @import '../common/index.css';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center}.smart-dropdown-item__option--first:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-first-line-color,rgba(0,0,0,.08))}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
1
+ @import '../common/index.css';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center;width:100vw;z-index:10}.smart-dropdown-item__option--first:after,.smart-dropdown-item__option:after{background-color:var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));height:var(--dropdown-menu-item-line-width,1px)}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
@@ -13,6 +13,7 @@
13
13
  position="{{ direction === 'down' ? 'top' : 'bottom' }}"
14
14
  duration="{{ transition ? duration : 0 }}"
15
15
  safe-area-tab-bar="{{ safeAreaTabBar }}"
16
+ safe-area-inset-bottom="{{ false }}"
16
17
  close-on-click-overlay="{{ closeOnClickOverlay }}"
17
18
  rootPortal="{{ rootPortal }}"
18
19
  bind:enter="onOpen"
@@ -1 +1 @@
1
- @import '../common/index.wxss';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center}.smart-dropdown-item__option--first:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-first-line-color,rgba(0,0,0,.08))}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
1
+ @import '../common/index.wxss';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center;width:100vw;z-index:10}.smart-dropdown-item__option--first:after,.smart-dropdown-item__option:after{background-color:var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));height:var(--dropdown-menu-item-line-width,1px)}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
@@ -103,13 +103,13 @@ SmartComponent({
103
103
  const { zIndex, direction } = this.data;
104
104
  return getRect(this, '.smart-dropdown-menu').then(rect => {
105
105
  const { top = 0, bottom = 0 } = rect;
106
- const offset = direction === 'down' ? bottom : this.windowHeight - top;
106
+ const offset = direction === 'down' ? bottom : top;
107
107
  let wrapperStyle = `z-index: ${zIndex};`;
108
108
  if (direction === 'down') {
109
109
  wrapperStyle += `top: ${addUnit(offset)};`;
110
110
  }
111
111
  else {
112
- wrapperStyle += `bottom: ${addUnit(offset)};`;
112
+ wrapperStyle += `top: 0;height: ${addUnit(offset)}`;
113
113
  }
114
114
  return wrapperStyle;
115
115
  });
@@ -1 +1 @@
1
- @import '../common/index.css';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
1
+ @import '../common/index.css';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);height:100%;left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
@@ -81,7 +81,6 @@ function cardStyle(data) {
81
81
  transform: 'translateX(' + data.lineOffsetLeft + 'px)',
82
82
  '-webkit-transform': 'translate(' + data.lineOffsetLeft + 'px, 0px)',
83
83
  'background-color': data.color,
84
- height: utils.addUnit(data.cardHeight),
85
84
  'transition-duration': !data.skipTransition ? data.duration + 's' : null,
86
85
  '-webkit-transition-duration': !data.skipTransition
87
86
  ? data.duration + 's'
@@ -1 +1 @@
1
- @import '../common/index.wxss';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
1
+ @import '../common/index.wxss';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);height:100%;left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
@@ -1,6 +1,6 @@
1
1
  <view class="contain">
2
2
  <smart-row>
3
- <smart-col wx:for="{{months}}" wx:key="index" span="6" custom-class="col_item">
3
+ <smart-col wx:for="{{months}}" span="6" custom-class="col_item">
4
4
  <view wx:if="{{item.type === 'disabled'}}" class="item item_disabled" data-index="{{index}}">
5
5
  {{item.text}}
6
6
  </view>
@@ -1,6 +1,6 @@
1
1
  <view class="contain">
2
2
  <smart-row>
3
- <smart-col wx:for="{{years}}" wx:key="index" span="6" custom-class="col_item">
3
+ <smart-col wx:for="{{years}}" span="6" custom-class="col_item">
4
4
  <view wx:if="{{item.type === 'disabled'}}" class="item item_disabled" data-index="{{index}}">
5
5
  {{item.text}}
6
6
  </view>
@@ -1 +1 @@
1
- @import '../common/index.css';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center}.smart-dropdown-item__option--first:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-first-line-color,rgba(0,0,0,.08))}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
1
+ @import '../common/index.css';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center;width:100vw;z-index:10}.smart-dropdown-item__option--first:after,.smart-dropdown-item__option:after{background-color:var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));height:var(--dropdown-menu-item-line-width,1px)}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
@@ -13,6 +13,7 @@
13
13
  position="{{ direction === 'down' ? 'top' : 'bottom' }}"
14
14
  duration="{{ transition ? duration : 0 }}"
15
15
  safe-area-tab-bar="{{ safeAreaTabBar }}"
16
+ safe-area-inset-bottom="{{ false }}"
16
17
  close-on-click-overlay="{{ closeOnClickOverlay }}"
17
18
  rootPortal="{{ rootPortal }}"
18
19
  bind:enter="onOpen"
@@ -1 +1 @@
1
- @import '../common/index.wxss';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center}.smart-dropdown-item__option--first:after{border-top:var(--dropdown-menu-item-line-width,1px) solid var(--dropdown-menu-item-first-line-color,rgba(0,0,0,.08))}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
1
+ @import '../common/index.wxss';.smart-dropdown-item{left:0;overflow:hidden;position:fixed;right:0}.smart-dropdown-item .smart-dropdown-item__title{font-size:var(--dropdown-menu-item-title-font-size,14px);font-weight:var(--dropdown-menu-item-title-font-weight,normal);line-height:var(--dropdown-menu-item-title-line-height,28px)}.smart-dropdown-item .smart-dropdown-item__icon{font-size:var(--dropdown-menu-item-icon-font-size,28px)}.smart-dropdown-item__option{--app-B6-N7:transparent;position:relative;text-align:left}.smart-dropdown-item__option:after{box-sizing:border-box;content:" ";left:0;pointer-events:none;position:absolute;right:0;top:0;transform-origin:center;width:100vw;z-index:10}.smart-dropdown-item__option--first:after,.smart-dropdown-item__option:after{background-color:var(--dropdown-menu-item-line-color,rgba(0,0,0,.05));height:var(--dropdown-menu-item-line-width,1px)}.smart-dropdown-item__option--active .smart-dropdown-item__icon,.smart-dropdown-item__option--active .smart-dropdown-item__title{color:var(--dropdown-menu-option-active-color,var(--app-M1,#3678e3));font-weight:var(--dropdown-menu-item-title-active-font-weight,500)}.smart-dropdown-item__option--up:after{bottom:0;top:auto}.smart-dropdown-item--up{top:0}.smart-dropdown-item--down{bottom:0}.smart-dropdown-item__icon{display:block;line-height:inherit}
@@ -106,17 +106,16 @@ var ARRAY = [];
106
106
  });
107
107
  },
108
108
  getChildWrapperStyle: function () {
109
- var _this = this;
110
109
  var _a = this.data, zIndex = _a.zIndex, direction = _a.direction;
111
110
  return (0, utils_1.getRect)(this, '.smart-dropdown-menu').then(function (rect) {
112
111
  var _a = rect.top, top = _a === void 0 ? 0 : _a, _b = rect.bottom, bottom = _b === void 0 ? 0 : _b;
113
- var offset = direction === 'down' ? bottom : _this.windowHeight - top;
112
+ var offset = direction === 'down' ? bottom : top;
114
113
  var wrapperStyle = "z-index: ".concat(zIndex, ";");
115
114
  if (direction === 'down') {
116
115
  wrapperStyle += "top: ".concat((0, utils_1.addUnit)(offset), ";");
117
116
  }
118
117
  else {
119
- wrapperStyle += "bottom: ".concat((0, utils_1.addUnit)(offset), ";");
118
+ wrapperStyle += "top: 0;height: ".concat((0, utils_1.addUnit)(offset));
120
119
  }
121
120
  return wrapperStyle;
122
121
  });
@@ -1 +1 @@
1
- @import '../common/index.css';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
1
+ @import '../common/index.css';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);height:100%;left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
@@ -81,7 +81,6 @@ function cardStyle(data) {
81
81
  transform: 'translateX(' + data.lineOffsetLeft + 'px)',
82
82
  '-webkit-transform': 'translate(' + data.lineOffsetLeft + 'px, 0px)',
83
83
  'background-color': data.color,
84
- height: utils.addUnit(data.cardHeight),
85
84
  'transition-duration': !data.skipTransition ? data.duration + 's' : null,
86
85
  '-webkit-transition-duration': !data.skipTransition
87
86
  ? data.duration + 's'
@@ -1 +1 @@
1
- @import '../common/index.wxss';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
1
+ @import '../common/index.wxss';.smart-tabs{-webkit-tap-highlight-color:transparent;position:relative}.smart-tabs__wrap{display:flex;overflow:hidden}.smart-tabs__wrap--scrollable .smart-tab{flex:0 0 22%}.smart-tabs__wrap--scrollable .smart-tab--complete{flex:1 0 auto!important;padding:0 12px}.smart-tabs__wrap--scrollable .smart-tabs__nav--complete{padding-left:8px;padding-right:8px}.smart-tabs__scroll{background-color:var(--tabs-background-color,var(--app-B3,#fff));overflow:auto}.smart-tabs__scroll--line{box-sizing:initial;height:calc(100% + 15px)}.smart-tabs__scroll--card{background-color:var(--tabs-card-background-color,var(--app-B6-N9,rgba(0,0,0,.05)));border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;padding:var(--tabs-card-padding,2px);width:100%}.smart-tabs__scroll::-webkit-scrollbar{display:none}.smart-tabs__nav{display:flex;position:relative;-webkit-user-select:none;user-select:none}.smart-tabs__nav--card{border-radius:var(--tabs-card-border-radius,8px);box-sizing:border-box;height:100%}.smart-tabs__nav--card .smart-tab{align-items:center;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));display:flex;justify-content:center}.smart-tabs__nav--card .smart-tab:last-child{border-right:none}.smart-tabs__nav--card .smart-tab.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000))}.smart-tabs__nav--card .smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tabs__line{background-color:var(--tabs-bottom-bar-color,var(--app-M4,#1989fa));border-radius:var(--tabs-bottom-bar-height,3px);bottom:0;height:var(--tabs-bottom-bar-height,3px);left:0;opacity:0;position:absolute;z-index:1}.smart-tabs__card-box{background-color:initial;height:100%;pointer-events:none;position:relative;width:100%}.smart-tabs__card{background-color:var(--tabs-card-active-background-color,var(--app-B3,#fff));border-radius:var(--tabs-card-active-border-radius,6px);height:100%;left:var(--tabs-card-active-left,0);opacity:0;position:absolute;top:var(--tabs-card-active-top,0);z-index:0}.smart-tabs__track{height:100%;position:relative;width:100%}.smart-tabs__track--animated{display:flex;transition-property:left}.smart-tabs__content{overflow:hidden}.smart-tabs--line{height:var(--tabs-line-height,32px)}.smart-tabs--card{height:var(--tabs-card-height,32px)}.smart-tab{box-sizing:border-box;color:var(--tabs-card-text-color,var(--app-B6-N3,rgba(0,0,0,.5)));cursor:pointer;flex:1;font-size:var(--tab-font-size,13px);line-height:var(--tabs-line-height,32px);min-width:0;position:relative;text-align:center}.smart-tab--active{color:var(--tabs-card-text-active-color,var(--app-B6-N1,#000));font-weight:var(--font-weight-bold,500)}.smart-tab--disabled{color:var(--tab-disabled-text-color,var(--app-B6-N7,rgba(0,0,0,.1)))}.smart-tab__title__info{position:relative!important;top:-1px!important;transform:translateX(0)!important}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tuya-miniapp/smart-ui",
3
- "version": "2.1.1-beta-3",
3
+ "version": "2.1.2-beta-1",
4
4
  "author": "MiniApp Team",
5
5
  "license": "MIT",
6
6
  "miniprogram": "lib",