Package-level declarations

Types

Link copied to clipboard
enum GenerationAspectRatio(val displayName: String, val width: Int, val height: Int) : Enum<GenerationAspectRatio>

Preset aspect ratios applied by resizing the active width/height fields.

Link copied to clipboard

Provides the GenerationInputFormConstants singleton used by the SDAI presentation layer.

Link copied to clipboard
sealed interface GenerationInputFormEvent

Events emitted by the reusable generation input form.

Link copied to clipboard

Shared state contract for generation controls.

Link copied to clipboard
private class PlatformTextInputView(val singleLine: Boolean) : UIView

Coordinates PlatformTextInputView behavior in the SDAI presentation layer.

Link copied to clipboard
internal class PlatformUITextField : UITextField, UITextFieldDelegateProtocol

Coordinates PlatformUITextField behavior in the SDAI presentation layer.

Link copied to clipboard
internal class PlatformUITextView : UITextView, UITextViewDelegateProtocol

Coordinates PlatformUITextView behavior in the SDAI presentation layer.

Properties

Link copied to clipboard
private const val BATCH_RANGE_FAL_AI_MAX: Int = 4
Link copied to clipboard
internal const val FIELD_TOP: Double = 8.0

Exposes the FIELD_TOP value used by the SDAI presentation layer.

Link copied to clipboard
internal const val LABEL_HEIGHT: Double = 20.0

Exposes the LABEL_HEIGHT value used by the SDAI presentation layer.

Link copied to clipboard
internal const val MIN_FIELD_HEIGHT: Double = 56.0

Exposes the MIN_FIELD_HEIGHT value used by the SDAI presentation layer.

Link copied to clipboard
internal const val MULTILINE_BOTTOM_INSET: Double = 10.0

Exposes the MULTILINE_BOTTOM_INSET value used by the SDAI presentation layer.

Link copied to clipboard
internal const val MULTILINE_HORIZONTAL_INSET: Double = 14.0

Exposes the MULTILINE_HORIZONTAL_INSET value used by the SDAI presentation layer.

Link copied to clipboard
internal const val MULTILINE_TOP_INSET: Double = 16.0

Exposes the MULTILINE_TOP_INSET value used by the SDAI presentation layer.

Link copied to clipboard
internal const val TEXT_FIELD_CORNER_RADIUS: Double = 4.0

Exposes the TEXT_FIELD_CORNER_RADIUS value used by the SDAI presentation layer.

Functions

Link copied to clipboard
private fun ADetailerMissingContent(refreshing: Boolean, onInstallClick: () -> Unit, onRefreshClick: () -> Unit)

Renders ADetailer missing state in the SDAI presentation layer.

Link copied to clipboard
private fun ADetailerSection(modifier: Modifier = Modifier, config: ADetailerConfig, available: Boolean, refreshing: Boolean, onConfigChange: (ADetailerConfig) -> Unit, onInstallClick: () -> Unit, onRefreshClick: () -> Unit)

Renders ADetailer controls in the SDAI presentation layer.

Link copied to clipboard
fun <T : Any> DropdownTextField(modifier: Modifier = Modifier, loading: Boolean = false, label: UiText = UiText.empty, value: T?, items: List<T> = emptyList(), onItemSelected: (T) -> Unit = {}, displayDelegate: (T) -> UiText = { t -> t.toString().asUiText() })

Renders the DropdownTextField UI for the SDAI presentation layer.

Link copied to clipboard

Renders the GenerationBatchComponent UI for the SDAI presentation layer.

Link copied to clipboard

Renders A1111-only generation options in the SDAI presentation layer.

Link copied to clipboard
internal fun GenerationInputAdvancedOptions(state: GenerationInputFormState, isImg2Img: Boolean, onEvent: (GenerationInputFormEvent) -> Unit, afterSlidersSection: @Composable () -> Unit)

Renders the GenerationInputAdvancedOptions UI for the SDAI presentation layer.

Link copied to clipboard
fun GenerationInputForm(modifier: Modifier = Modifier, state: GenerationInputFormState, isImg2Img: Boolean = false, textFieldContainerColor: Color = MaterialTheme.colorScheme.surfaceVariant, promptChipTextFieldState: MutableState<TextFieldValue>, negativePromptChipTextFieldState: MutableState<TextFieldValue>, onEvent: (GenerationInputFormEvent) -> Unit = {}, afterSlidersSection: @Composable () -> Unit = {})

Renders the GenerationInputForm UI for the SDAI presentation layer.

Link copied to clipboard

Renders the GenerationSizeTextFieldsComponent UI for the SDAI presentation layer.

Link copied to clipboard
private fun HiresSection(modifier: Modifier = Modifier, config: HiresConfig, onConfigChange: (HiresConfig) -> Unit)

Renders Hires.fix controls in the SDAI presentation layer.

Link copied to clipboard
fun <T : Any> MultiSelectDropdownField(modifier: Modifier = Modifier, label: UiText = UiText.empty, selectedItems: List<T> = emptyList(), availableItems: List<T> = emptyList(), onSelectionChanged: (List<T>) -> Unit = {}, displayDelegate: (T) -> UiText = { t -> t.toString().asUiText() })

Renders the MultiSelectDropdownField UI for the SDAI presentation layer.

Link copied to clipboard
internal actual fun PlatformOutlinedTextField(value: String, onValueChange: (String) -> Unit, label: String, containerColor: Color, textColor: Color, hintColor: Color, modifier: Modifier, enabled: Boolean, error: String?, keyboardType: KeyboardType, visualTransformation: VisualTransformation, trailingIcon: () -> Unit?, singleLine: Boolean)

Renders the PlatformOutlinedTextField UI for the SDAI presentation layer.

internal expect fun PlatformOutlinedTextField(value: String, onValueChange: (String) -> Unit, label: String, containerColor: Color, textColor: Color, hintColor: Color, modifier: Modifier = Modifier, enabled: Boolean = true, error: String? = null, keyboardType: KeyboardType = KeyboardType.Text, visualTransformation: VisualTransformation = VisualTransformation.None, trailingIcon: @Composable () -> Unit? = null, singleLine: Boolean = false)

Renders the PlatformOutlinedTextField UI for the SDAI presentation layer.

internal actual fun PlatformOutlinedTextField(value: String, onValueChange: (String) -> Unit, label: String, containerColor: Color, textColor: Color, hintColor: Color, modifier: Modifier, enabled: Boolean, error: String?, keyboardType: KeyboardType, visualTransformation: VisualTransformation, trailingIcon: () -> Unit?, singleLine: Boolean)

Renders the PlatformOutlinedTextField UI for the SDAI presentation layer.

Link copied to clipboard
internal fun processTaggedPrompt(keywords: List<String>, event: ChipTextFieldEvent<String>): String

Executes the processTaggedPrompt step in the SDAI presentation layer.

Link copied to clipboard
private fun SchedulerSection(modifier: Modifier = Modifier, config: Scheduler, onConfigChange: (Scheduler) -> Unit)

Renders scheduler controls in the SDAI presentation layer.

Link copied to clipboard
fun SliderTextInputField(value: Double, onValueChange: (Double) -> Unit, modifier: Modifier = Modifier, valueRange: ClosedFloatingPointRange<Double> = 0.0..1.0, valueDiff: Double = 1.0, fractionDigits: Int = 2, steps: Int = 0, sliderColors: SliderColors = SliderDefaults.colors())
fun SliderTextInputField(value: Float, onValueChange: (Float) -> Unit, modifier: Modifier = Modifier, valueRange: ClosedFloatingPointRange<Float> = 0f..1f, valueDiff: Float = 1.0f, fractionDigits: Int = 2, steps: Int = 0, sliderColors: SliderColors = SliderDefaults.colors())

Renders the SliderTextInputField UI for the SDAI presentation layer.

Link copied to clipboard
internal fun Color.toUIColor(): UIColor

Converts SDAI data with toUIColor.

Link copied to clipboard
internal fun KeyboardType.toUiKeyboardType(): UIKeyboardType

Converts SDAI data with toUiKeyboardType.