Skip to content

Commit 187331b

Browse files
committed
chore: solve conflicts
2 parents 9f7e994 + 0a973ee commit 187331b

File tree

5 files changed

+24
-12
lines changed

5 files changed

+24
-12
lines changed

CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,14 @@ All notable changes to this project will be documented in this file. Dates are d
44

55
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
66

7+
#### [3.0.8](https://github.com/ant-design/ant-design-mini/compare/3.0.7...3.0.8)
8+
9+
- indexbar scroll not silky [`#1386`](https://github.com/ant-design/ant-design-mini/pull/1386)
10+
711
#### [3.0.7](https://github.com/ant-design/ant-design-mini/compare/3.0.6...3.0.7)
812

13+
> 16 January 2025
14+
915
- fix: display range problem [`#1383`](https://github.com/ant-design/ant-design-mini/pull/1383)
1016
- Fix card divier [`#1378`](https://github.com/ant-design/ant-design-mini/pull/1378)
1117
- fix: card divider [`#1377`](https://github.com/ant-design/ant-design-mini/pull/1377)

mini.project.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@
1616
"sourcemap": false,
1717
"lazyCompile": false
1818
}
19-
}
19+
}

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "antd-mini",
3-
"version": "3.0.7",
3+
"version": "3.0.8",
44
"description": "antd-mini 是支付宝小程序 UI 组件库,遵循 Ant Design 规范。",
55
"miniprogram": "compiled/wechat/src",
66
"scripts": {

scripts/axml/mapping.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,9 @@ export const wechatCustomMapping = {
195195
'ant-select-contact': {
196196
onSelect: 'bindselect',
197197
},
198+
'ant-empty': {
199+
onClickButton: 'bindclickbutton',
200+
},
198201
'ant-prompts': {
199202
onItemTap: 'binditemtap',
200203
},
@@ -206,9 +209,6 @@ export const wechatCustomMapping = {
206209
onExpand: 'bindexpand',
207210
onContentItemTap: 'bindcontentitemtap'
208211
},
209-
'ant-empty': {
210-
onClickButton: 'bindclickbutton',
211-
},
212212
'ant-actions': {
213213
onItemTap: 'binditemtap',
214214
},

src/IndexBar/index.ts

+13-7
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,19 @@ Component(
2929
? current
3030
: defaultCurrent;
3131
const _index = items?.findIndex((u) => initCurrent === u.label);
32-
this.setData({
33-
currentKey: _index,
34-
touchKeyIndex: _index,
35-
touchKey: initCurrent,
36-
});
32+
this.setData(
33+
{
34+
currentKey: _index,
35+
touchKeyIndex: _index,
36+
touchKey: initCurrent,
37+
},
38+
() => {
39+
this.setData({
40+
touchKeyIndex: -1,
41+
touchKey: '',
42+
});
43+
}
44+
);
3745
},
3846
isControlled(nextProps, valueKey = 'current') {
3947
if ('controlled' in nextProps) {
@@ -129,8 +137,6 @@ Component(
129137
if (currentKey !== newIndex - 1 && newIndex - 1 >= 0 && !moving) {
130138
this.setData({
131139
currentKey: newIndex - 1,
132-
touchKeyIndex: newIndex - 1,
133-
touchKey: items[newIndex - 1].label,
134140
});
135141
this.onAlphabetClick(items[newIndex - 1], newIndex - 1);
136142
}

0 commit comments

Comments
 (0)