@momo-kits/native-kits 0.89.33-beta.20 → 0.89.33-beta.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -91,6 +91,7 @@ data class InputSearchProps(
|
|
|
91
91
|
val fontWeight: InputFontWeight = InputFontWeight.REGULAR,
|
|
92
92
|
val keyboardType: KeyboardType = KeyboardType.Text,
|
|
93
93
|
val backgroundColor: Color = Colors.black_01,
|
|
94
|
+
val clearCondition: (() -> Boolean)? = null,
|
|
94
95
|
val keyboardOptions: KeyboardOptions = KeyboardOptions.Default,
|
|
95
96
|
val keyboardActions: KeyboardActions = KeyboardActions.Default,
|
|
96
97
|
val modifier: Modifier = Modifier
|
|
@@ -102,7 +103,6 @@ fun InputSearch(
|
|
|
102
103
|
text = remember { mutableStateOf("") },
|
|
103
104
|
iconColor = AppTheme.current.colors.text.default
|
|
104
105
|
),
|
|
105
|
-
clearCondition: (() -> Boolean)? = null
|
|
106
106
|
) {
|
|
107
107
|
var isFocused by remember { mutableStateOf(false) }
|
|
108
108
|
var isBlurred = false
|
|
@@ -192,7 +192,7 @@ fun InputSearch(
|
|
|
192
192
|
)
|
|
193
193
|
}
|
|
194
194
|
}
|
|
195
|
-
if (clearCondition?.invoke() == true) {
|
|
195
|
+
if (inputSearchProps.clearCondition?.invoke() == true) {
|
|
196
196
|
RenderRightIconSearch(
|
|
197
197
|
inputSearchProps.loading,
|
|
198
198
|
inputSearchProps.icon,
|