Skip to content

This is a small collection for 3 different Loading-Dialogs. Especially the KittLoadingDialog is my personal favorit and ready-to-use. I use this Dialogs in all my projects. As a Knight Rider fan, I love the Kitt running light!

Notifications You must be signed in to change notification settings

nexus421/ComposeLoadingDialog

Repository files navigation

ComposeLoadingDialog

A collection of beautiful and customizable loading dialogs for Jetpack Compose, including the iconic KITT running light from Knight Rider!

Table of Contents

Overview

This library provides a set of ready-to-use loading dialogs for your Android applications built with Jetpack Compose. The dialogs are highly customizable and easy to integrate into any project.

Features

  • 3 different loading dialog styles: KITT, CIRCLE, and LINE
  • Progress indicators with customizable appearance
  • Info dialog with up to three buttons
  • Easy to implement and customize
  • Lightweight and efficient

Installation

Step 1: Add the JitPack repository

Add the following to your project's settings.gradle file:

dependencyResolutionManagement {
    repositories {
        // ... other repositories
        maven { url 'https://jitpack.io' }
    }
}

Step 2: Add the dependency

Add the dependency to your module's build.gradle file:

dependencies {
    implementation("com.github.nexus421:ComposeLoadingDialog:2.1.1")
}

Usage

Basic Loading Dialog

LoadingDialog(
    show = showDialog,
    onDismissRequest = { showDialog = false },
    type = LoadingDialogType.KITT // Default type
)

Loading Dialog with Progress

LoadingDialogWithProgress(
    show = showDialog,
    progress = 0.75f, // 75% progress
    onDismissRequest = { showDialog = false }
)

Info Dialog

InfoDialog(
    show = showDialog,
    title = "Information",
    message = "This is an example message",
    onDismissRequest = { showDialog = false },
    positiveButton = "OK" to { /* action */ }
)

Dialog Types

KITT Loading Dialog

The KITT loading dialog features a running light animation inspired by the iconic KITT car from Knight Rider. This is the default and my personal favorite!

CIRCLE Loading Dialog

A circular loading animation that's perfect for most loading scenarios.

LINE Loading Dialog

A linear loading animation for a more traditional loading experience.

Screenshots

KITT Loading Dialog Circle Loading Dialog Line Loading Dialog
Progress Dialog Info Dialog

For more detailed information, check the code documentation. Enjoy using these dialogs in your projects!

About

This is a small collection for 3 different Loading-Dialogs. Especially the KittLoadingDialog is my personal favorit and ready-to-use. I use this Dialogs in all my projects. As a Knight Rider fan, I love the Kitt running light!

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages