Revert change on AutoFillNode.
This commit is contained in:
parent
c9049be239
commit
76d3e64f41
2 changed files with 6 additions and 11 deletions
|
|
@ -31,7 +31,7 @@ class BooksViewModel @Inject constructor(
|
||||||
val updateError: Flow<BookUpdateErrorUio> get() = _updateError
|
val updateError: Flow<BookUpdateErrorUio> get() = _updateError
|
||||||
|
|
||||||
init {
|
init {
|
||||||
updateBooks()
|
// updateBooks()
|
||||||
}
|
}
|
||||||
|
|
||||||
fun updateBooks() {
|
fun updateBooks() {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,5 @@
|
||||||
package com.pixelized.biblib.utils.extention
|
package com.pixelized.biblib.utils.extention
|
||||||
|
|
||||||
import androidx.compose.runtime.remember
|
|
||||||
import androidx.compose.ui.ExperimentalComposeUiApi
|
import androidx.compose.ui.ExperimentalComposeUiApi
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.autofill.AutofillNode
|
import androidx.compose.ui.autofill.AutofillNode
|
||||||
|
|
@ -18,15 +17,11 @@ fun Modifier.autofill(
|
||||||
onFill: ((String) -> Unit),
|
onFill: ((String) -> Unit),
|
||||||
) = composed {
|
) = composed {
|
||||||
val autofill = LocalAutofill.current
|
val autofill = LocalAutofill.current
|
||||||
val autofillTree = LocalAutofillTree.current
|
val autofillNode = AutofillNode(
|
||||||
val autofillNode = remember {
|
onFill = onFill,
|
||||||
AutofillNode(
|
autofillTypes = autofillTypes
|
||||||
onFill = onFill,
|
)
|
||||||
autofillTypes = autofillTypes
|
LocalAutofillTree.current += autofillNode
|
||||||
).also {
|
|
||||||
autofillTree += it
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return@composed this
|
return@composed this
|
||||||
.onGloballyPositioned {
|
.onGloballyPositioned {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue