Skip to content

Commit

Permalink
Merge branch 'main' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
LeeJim authored Mar 2, 2023
2 parents 79d4126 + 43437d5 commit bd6a0e9
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 17 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ spline: explain
toc: false
docClass: timeline
---

## 🌈 1.0.1 `2023-03-01`
### 🚀 Features
- `Cascader`: 新增 close 事件 @LeeJim ([#1685](https://github.com/Tencent/tdesign-miniprogram/pull/1685))
Expand All @@ -19,6 +20,7 @@ docClass: timeline
- `DropdownMenu`: 修复 radio 图标显示位置不正确的问题 @LeeJim ([#1693](https://github.com/Tencent/tdesign-miniprogram/pull/1693))
- `TreeSelect`: 修复 radio 图标显示位置不正确的问题 @LeeJim ([#1693](https://github.com/Tencent/tdesign-miniprogram/pull/1693))
- `Message`: 更新内嵌 `link` 组件的属性 @anlyyao ([#1694](https://github.com/Tencent/tdesign-miniprogram/pull/1694))

## 🌈 1.0.0 `2023-02-27`
### ❗ Breaking Changes
- `Cell`: 调整 hover 状态对应的类名 @anlyyao ([#1635](https://github.com/Tencent/tdesign-miniprogram/pull/1635))
Expand Down
12 changes: 12 additions & 0 deletions example/project.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,18 @@
"pathName": "pages/upload/upload",
"query": "",
"scene": null
},
{
"id": -1,
"name": "search",
"pathName": "pages/search/search",
"scene": null
},
{
"id": -1,
"name": "checkbox",
"pathName": "pages/checkbox/checkbox",
"scene": null
}
]
}
Expand Down
2 changes: 1 addition & 1 deletion src/image/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ error | String / Slot | 'default' | 加载失败时显示的内容。值为 `def
external-classes | Array | - | 组件类名,分别用于设置加载组件外层元素,中间内容等元素类名。`['t-class', 't-class-load']` | N
height | String / Number | - | 高度,默认单位为`px` | N
lazy | Boolean | false | 是否开启图片懒加载 | N
loading | String / Slot | 'default' | 加载态内容。值为 `default` 则表示使用默认加载中风格;值为空或者 `slot` 表示使用插槽渲染,插槽名称为 `loading`值为其他则表示普通文本内容,如“加载中” | N
loading | String / Slot | 'default' | 加载态内容。值为 `default` 则表示使用默认加载中风格;值为其他则表示普通文本内容,如“加载中” | N
mode | String | scaleToFill | 图片裁剪、缩放的模式;[小程序官方文档](https://developers.weixin.qq.com/miniprogram/dev/component/image.html)。可选项:scaleToFill/aspectFit/aspectFill/widthFix/heightFix/top/bottom/center/left/right/top left/top right/bottom left/bottom right | N
shape | String | square | 图片圆角类型。可选项:circle/round/square | N
show-menu-by-longpress | Boolean | false | 长按图片显示发送给朋友、收藏、保存图片、搜一搜、打开名片/前往群聊/打开小程序(若图片中包含对应二维码或小程序码)的菜单。 | N
Expand Down
32 changes: 16 additions & 16 deletions src/input/__test__/__snapshots__/index.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ exports[`input props : clearable && label && suffix 1`] = `
style=""
>
<wx-view
class="t-input__wrap--prefix"
class="t-input__icon--prefix"
/>
<wx-view
ariaHidden="{{true}}"
class="t-input__label"
>
<wx-view
class="t-input__icon--prefix"
Expand All @@ -19,12 +23,8 @@ exports[`input props : clearable && label && suffix 1`] = `
ariaHidden="{{true}}"
class="t-input__label"
>
<wx-text
class="t-class-label"
>
tdesign
</wx-text>
</wx-view>
tdesign
</wx-text>
</wx-view>
<wx-view
class="t-input__wrap"
Expand Down Expand Up @@ -137,7 +137,11 @@ exports[`input slots : label 1`] = `
style=""
>
<wx-view
class="t-input__wrap--prefix"
class="t-input__icon--prefix"
/>
<wx-view
ariaHidden="{{true}}"
class="t-input__label"
>
<wx-view
class="t-input__icon--prefix"
Expand All @@ -146,17 +150,13 @@ exports[`input slots : label 1`] = `
ariaHidden="{{true}}"
class="t-input__label"
>
标签文字
<wx-text
slot="label"
style="color: #e34d59"
>
标签文字
<wx-text
style="color: #e34d59"
>
*
</wx-text>
*
</wx-text>
</wx-view>
</wx-text>
</wx-view>
<wx-view
class="t-input__wrap"
Expand Down
9 changes: 9 additions & 0 deletions src/input/input.less
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
.@{prefix}-input {
background-color: @input-bg-color;
display: flex;
align-items: center;
flex: 1;
padding: @input-vertical-padding;

Expand Down Expand Up @@ -69,6 +70,14 @@
padding-left: 8rpx;
}

&__label:not(:empty) + &__wrap {
margin-left: @spacer-2;
}

&__icon--prefix:not(:empty) + &__label:empty {
margin-right: @spacer-2;
}

&__wrap {
display: flex;
flex-direction: column;
Expand Down

0 comments on commit bd6a0e9

Please sign in to comment.