Skip to content

Commit

Permalink
Fix VMDTextField parameter not used in the implementation (#218)
Browse files Browse the repository at this point in the history
* Fix VMDTextField parameter not used in the implementation

* Run apiDump

* Add a breaking change in changelog

* Remove a linefeed I added by accident
  • Loading branch information
Vincent-Ribou authored Feb 12, 2024
1 parent 0cccfb4 commit 679ce09
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
### Breaking Changes

- [VMD] Change parameters order for some Compose components
- [VMD] Change VMDTextField's signature on Android

### Updates

Expand Down
2 changes: 1 addition & 1 deletion trikot-viewmodels-declarative/compose/api/compose.api
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public final class com/mirego/trikot/viewmodels/declarative/compose/viewmodel/VM
}

public final class com/mirego/trikot/viewmodels/declarative/compose/viewmodel/VMDTextFieldKt {
public static final fun VMDTextField (Lcom/mirego/trikot/viewmodels/declarative/components/VMDTextFieldViewModel;Landroidx/compose/ui/Modifier;Landroidx/compose/ui/text/TextStyle;Landroidx/compose/ui/text/TextStyle;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function2;Landroidx/compose/foundation/text/KeyboardActions;ZZIILandroidx/compose/foundation/interaction/MutableInteractionSource;Landroidx/compose/ui/graphics/Shape;Landroidx/compose/material/TextFieldColors;Landroidx/compose/runtime/Composer;III)V
public static final fun VMDTextField (Lcom/mirego/trikot/viewmodels/declarative/components/VMDTextFieldViewModel;Landroidx/compose/ui/Modifier;Landroidx/compose/ui/text/TextStyle;Landroidx/compose/ui/text/TextStyle;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function3;Lkotlin/jvm/functions/Function2;Lkotlin/jvm/functions/Function2;Landroidx/compose/foundation/text/KeyboardActions;ZZIILandroidx/compose/foundation/interaction/MutableInteractionSource;Landroidx/compose/ui/graphics/Shape;Landroidx/compose/material/TextFieldColors;Landroidx/compose/runtime/Composer;III)V
public static final fun buildKeyboardActions (Lcom/mirego/trikot/viewmodels/declarative/components/VMDTextFieldViewModel;Landroidx/compose/foundation/text/KeyboardActions;)Landroidx/compose/foundation/text/KeyboardActions;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ fun VMDTextField(
textStyle: TextStyle = LocalTextStyle.current,
placeHolderStyle: TextStyle = LocalTextStyle.current,
label: @Composable (() -> Unit)? = null,
placeholder: @Composable (() -> Unit)? = null,
placeholder: @Composable ((String) -> Unit)? = null,
leadingIcon: @Composable (() -> Unit)? = null,
trailingIcon: @Composable (() -> Unit)? = null,
keyboardActions: KeyboardActions = KeyboardActions(),
Expand All @@ -56,7 +56,7 @@ fun VMDTextField(
enabled = textFieldViewModel.isEnabled,
label = label,
placeholder = {
Text(
placeholder?.invoke(textFieldViewModel.placeholder) ?: Text(
text = textFieldViewModel.placeholder,
style = placeHolderStyle
)
Expand Down

0 comments on commit 679ce09

Please sign in to comment.