Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions packages/rax-countdown/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Changelog
## v1.2.1

- Feat decrease setData data size for promote performance

## v1.2.0

Expand Down
2 changes: 1 addition & 1 deletion packages/rax-countdown/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rax-countdown",
"version": "1.2.0",
"version": "1.2.1",
"description": "Countdown component for Rax.",
"license": "BSD-3-Clause",
"main": "lib/index.js",
Expand Down
13 changes: 8 additions & 5 deletions packages/rax-countdown/src/miniapp-native/ali-miniapp/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,11 +88,14 @@ Component({
case 'm':
case 's':
if (index % 2 === 0) {
// insert plain text before current matched item
return {
value: tpl.slice(lastPlaintextIndex, val),
style: textStyle
};
const value = tpl.slice(lastPlaintextIndex, val);
if (value || textStyle) {
// insert plain text before current matched item
return {
value,
style: textStyle
};
}
} else {
// replace current matched item to realtime string
lastPlaintextIndex = val + 3;
Expand Down