Package-level declarations

Types

Link copied to clipboard
sealed interface EmbeddingIntent : MviIntent

Defines the EmbeddingIntent contract for the SDAI presentation layer.

Link copied to clipboard
data class EmbeddingItemUi(val keyword: String, val isInPrompt: Boolean, val isInNegativePrompt: Boolean)

Carries EmbeddingItemUi data through the SDAI presentation layer.

Link copied to clipboard
data class EmbeddingState(val loading: Boolean = true, val source: ServerSource = ServerSource.AUTOMATIC1111, val error: ErrorState = ErrorState.None, val prompt: String = "", val negativePrompt: String = "", val embeddings: List<EmbeddingItemUi> = emptyList(), val selector: Boolean = true) : MviState

Carries EmbeddingState data through the SDAI presentation layer.

Link copied to clipboard
class EmbeddingViewModel(val dispatchersProvider: DispatchersProvider, val fetchAndGetEmbeddingsUseCase: FetchAndGetEmbeddingsUseCase, val preferenceManager: PreferenceManager, prompt: String, negativePrompt: String, val onError: (Throwable) -> Unit = {}) : BaseMviViewModel<EmbeddingState, EmbeddingIntent, ExtrasEffect>

Coordinates EmbeddingViewModel behavior in the SDAI presentation layer.

Functions

Link copied to clipboard

Renders the EmbeddingEmptyState UI for the SDAI presentation layer.

Link copied to clipboard
private fun EmbeddingItemComposable(item: EmbeddingItemUi, selector: Boolean, onItemToggle: (EmbeddingItemUi) -> Unit)

Renders the EmbeddingItemComposable UI for the SDAI presentation layer.

Link copied to clipboard
fun EmbeddingScreen(prompt: String, negativePrompt: String, onNewPrompts: (String, String) -> Unit, onClose: () -> Unit)

Renders the EmbeddingScreen UI for the SDAI presentation layer.

Link copied to clipboard
private fun ScreenContent(modifier: Modifier = Modifier, state: EmbeddingState, processIntent: (EmbeddingIntent) -> Unit)

Renders the ScreenContent UI for the SDAI presentation layer.