diff --git a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonCustomizationState.kt b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonCustomizationState.kt index 129b8b837..0a499672d 100644 --- a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonCustomizationState.kt +++ b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonCustomizationState.kt @@ -25,10 +25,10 @@ fun rememberButtonCustomizationState( textButtonStyle: MutableState = rememberSaveable { mutableStateOf(OdsTextButtonStyle.Default) }, leadingIcon: MutableState = rememberSaveable { mutableStateOf(false) }, variableWidth: MutableState = rememberSaveable { mutableStateOf(false) }, - disabled: MutableState = rememberSaveable { mutableStateOf(false) } + enabled: MutableState = rememberSaveable { mutableStateOf(true) } ) = - remember(containedButtonStyle, textButtonStyle, leadingIcon, variableWidth, disabled) { - ButtonCustomizationState(containedButtonStyle, textButtonStyle, leadingIcon, variableWidth, disabled) + remember(containedButtonStyle, textButtonStyle, leadingIcon, variableWidth, enabled) { + ButtonCustomizationState(containedButtonStyle, textButtonStyle, leadingIcon, variableWidth, enabled) } @Composable @@ -44,14 +44,14 @@ class ButtonCustomizationState( val textButtonStyle: MutableState, val leadingIcon: MutableState, val variableWidth: MutableState, - val disabled: MutableState + val enabled: MutableState ) { val hasLeadingIcon get() = leadingIcon.value val isEnabled - get() = !disabled.value + get() = enabled.value val hasVariableWidth get() = variableWidth.value diff --git a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsContained.kt b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsContained.kt index 256ca22d9..06e91a52b 100644 --- a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsContained.kt +++ b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsContained.kt @@ -70,8 +70,8 @@ fun ButtonsContained(style: OdsButtonStyle) { trailing = OdsSwitchTrailing(checked = variableWidth) ) OdsListItem( - text = stringResource(id = R.string.component_state_disabled), - trailing = OdsSwitchTrailing(checked = disabled) + text = stringResource(id = R.string.component_state_enabled), + trailing = OdsSwitchTrailing(checked = enabled) ) }) { diff --git a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsIcon.kt b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsIcon.kt index fab28d68f..56cfa1ea3 100644 --- a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsIcon.kt +++ b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsIcon.kt @@ -48,8 +48,8 @@ fun ButtonsIcon() { bottomSheetScaffoldState = rememberBottomSheetScaffoldState(), bottomSheetContent = { OdsListItem( - text = stringResource(id = R.string.component_state_disabled), - trailing = OdsSwitchTrailing(checked = disabled) + text = stringResource(id = R.string.component_state_enabled), + trailing = OdsSwitchTrailing(checked = enabled) ) }) { Column( diff --git a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsOutlined.kt b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsOutlined.kt index 69f478c62..e24df1766 100644 --- a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsOutlined.kt +++ b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsOutlined.kt @@ -51,8 +51,8 @@ fun ButtonsOutlined() { trailing = OdsSwitchTrailing(checked = variableWidth) ) OdsListItem( - text = stringResource(id = R.string.component_state_disabled), - trailing = OdsSwitchTrailing(checked = disabled) + text = stringResource(id = R.string.component_state_enabled), + trailing = OdsSwitchTrailing(checked = enabled) ) }) { diff --git a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsText.kt b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsText.kt index e1e80dc64..eac8bf65f 100644 --- a/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsText.kt +++ b/demo/src/main/java/com/orange/ods/demo/ui/components/buttons/ButtonsText.kt @@ -66,8 +66,8 @@ fun ButtonsText() { trailing = OdsSwitchTrailing(checked = variableWidth) ) OdsListItem( - text = stringResource(id = R.string.component_state_disabled), - trailing = OdsSwitchTrailing(checked = disabled) + text = stringResource(id = R.string.component_state_enabled), + trailing = OdsSwitchTrailing(checked = enabled) ) }) {