Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
b6c2c77
Color, Font and Theme update (#59)
lethargicpanda Jul 30, 2025
8415e58
ui-component module (#60)
lethargicpanda Aug 12, 2025
7dc8dd9
Sample list UI redesign (#70)
lethargicpanda Aug 13, 2025
12a998f
Add theme & asset exported from Figma (#73)
lethargicpanda Aug 19, 2025
fe46e1b
Imagen redesign (#81)
lethargicpanda Aug 21, 2025
b32bea2
Gemini multimodal sample redesign (#84)
lethargicpanda Aug 26, 2025
c732b36
Genai Image Description redesign (#86)
lethargicpanda Aug 27, 2025
9a0434a
Apply new design to Nano Summarization sample (#90)
calren Sep 3, 2025
21104db
Gemini Live sample redesign (#83)
lethargicpanda Sep 3, 2025
0ed365b
Redesign Gemini Chatbot (#92)
lethargicpanda Sep 4, 2025
1f4da64
Magic Selfie sample redesign (#85)
lethargicpanda Sep 4, 2025
3ec9fbb
Video summary sample redesign (#98)
lethargicpanda Sep 9, 2025
23ee720
Apply new design to Nano writing assistance sample (#93)
calren Sep 9, 2025
6b8c86f
Merge main into redesign (#94)
JolandaVerhoef Sep 9, 2025
2d9918d
Fix Nano image description bug + use undo button (#101)
lethargicpanda Sep 10, 2025
65a53ba
Implement back in sample detail top bar (#100)
lethargicpanda Sep 10, 2025
9a753c0
Add Video Player ui component that is reused for both media use cases…
lethargicpanda Sep 11, 2025
f6cbeea
Implement design for Nanobanana sample (#104)
lethargicpanda Sep 12, 2025
18e33f8
Add collapsable appbar to sample list (#103)
lethargicpanda Sep 12, 2025
2a00981
Video metadata screen redesign (#99)
JolandaVerhoef Sep 15, 2025
4d4bce7
Adaptive layout #1 (#106)
lethargicpanda Sep 30, 2025
0a64873
Post rebase fix
lethargicpanda Oct 2, 2025
dd22574
Adaptive layout #2
lethargicpanda Oct 2, 2025
eb39b75
New Image Input component, used in Multimodal sample (#112)
JolandaVerhoef Oct 6, 2025
0a0f26a
Improve loading states
lethargicpanda Oct 6, 2025
81d2e47
Imagen Editing sample redesign (#114)
lethargicpanda Oct 6, 2025
3f8366e
🤖 Apply Spotless formatting
lethargicpanda Oct 6, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ai-catalog/app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ dependencies {
implementation(libs.firebase.ai)
ksp(libs.hilt.compiler)

implementation(project(":ui-component"))
implementation(project(":samples:gemini-multimodal"))
implementation(project(":samples:gemini-chatbot"))
implementation(project(":samples:genai-summarization"))
Expand Down
1 change: 0 additions & 1 deletion ai-catalog/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
android:fullBackupContent="@xml/backup_rules"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/Theme.AISampleCatalog"
tools:targetApi="31"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import androidx.activity.enableEdgeToEdge
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.ui.Modifier
import com.android.ai.catalog.ui.CatalogApp
import com.android.ai.catalog.ui.theme.AISampleCatalogTheme
import com.android.ai.theme.AISampleCatalogTheme
import dagger.hilt.android.AndroidEntryPoint

@AndroidEntryPoint
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.android.ai.catalog.ui.domain
package com.android.ai.catalog.domain

import android.Manifest
import androidx.annotation.DrawableRes
import androidx.annotation.RequiresPermission
import androidx.annotation.StringRes
import androidx.compose.runtime.Composable
import androidx.compose.ui.graphics.Color
Expand All @@ -23,16 +26,17 @@ import com.android.ai.samples.geminichatbot.GeminiChatbotScreen
import com.android.ai.samples.geminiimagechat.GeminiImageChatScreen
import com.android.ai.samples.geminilivetodo.ui.TodoScreen
import com.android.ai.samples.geminimultimodal.ui.GeminiMultimodalScreen
import com.android.ai.samples.geminivideometadatacreation.VideoMetadataCreationScreen
import com.android.ai.samples.geminivideosummary.VideoSummarizationScreen
import com.android.ai.samples.geminivideometadatacreation.ui.VideoMetadataCreationScreen
import com.android.ai.samples.geminivideosummary.ui.VideoSummarizationScreen
import com.android.ai.samples.genai_image_description.GenAIImageDescriptionScreen
import com.android.ai.samples.genai_summarization.GenAISummarizationScreen
import com.android.ai.samples.genai_writing_assistance.GenAIWritingAssistanceScreen
import com.android.ai.samples.imagen.ui.ImagenScreen
import com.android.ai.samples.imagenediting.ui.ImagenEditingScreen
import com.android.ai.samples.magicselfie.ui.MagicSelfieScreen
import com.android.ai.theme.extendedColorScheme

@androidx.annotation.RequiresPermission(android.Manifest.permission.RECORD_AUDIO)
@RequiresPermission(Manifest.permission.RECORD_AUDIO)
val sampleCatalog = listOf(
SampleCatalogItem(
title = R.string.gemini_image_chat,
Expand All @@ -49,6 +53,8 @@ val sampleCatalog = listOf(
sampleEntryScreen = { GeminiMultimodalScreen() },
tags = listOf(SampleTags.GEMINI_FLASH, SampleTags.FIREBASE),
needsFirebase = true,
isFeatured = true,
keyArt = R.drawable.img_keyart_multimodal,
),
SampleCatalogItem(
title = R.string.gemini_chatbot_sample_title,
Expand All @@ -57,27 +63,31 @@ val sampleCatalog = listOf(
sampleEntryScreen = { GeminiChatbotScreen() },
tags = listOf(SampleTags.GEMINI_FLASH, SampleTags.FIREBASE),
needsFirebase = true,
keyArt = R.drawable.img_keyart_chatbot,
),
SampleCatalogItem(
title = R.string.genai_summarization_sample_title,
description = R.string.genai_summarization_sample_description,
route = "GenAISummarizationScreen",
sampleEntryScreen = { GenAISummarizationScreen() },
tags = listOf(SampleTags.GEMINI_NANO, SampleTags.ML_KIT),
keyArt = R.drawable.img_keyart_summary,
),
SampleCatalogItem(
title = R.string.genai_image_description_sample_title,
description = R.string.genai_image_description_sample_description,
route = "GenAIImageDescriptionScreen",
sampleEntryScreen = { GenAIImageDescriptionScreen() },
tags = listOf(SampleTags.GEMINI_NANO, SampleTags.ML_KIT),
keyArt = R.drawable.img_keyart_img_desc,
),
SampleCatalogItem(
title = R.string.genai_writing_assistance_sample_title,
description = R.string.genai_writing_assistance_sample_description,
route = "GenAIWritingAssistanceScreen",
sampleEntryScreen = { GenAIWritingAssistanceScreen() },
tags = listOf(SampleTags.GEMINI_NANO, SampleTags.ML_KIT),
keyArt = R.drawable.img_keyart_text,
),
SampleCatalogItem(
title = R.string.imagen_sample_title,
Expand All @@ -86,14 +96,16 @@ val sampleCatalog = listOf(
sampleEntryScreen = { ImagenScreen() },
tags = listOf(SampleTags.IMAGEN, SampleTags.FIREBASE),
needsFirebase = true,
keyArt = R.drawable.img_keyart_imagen,
),
SampleCatalogItem(
title = R.string.imagen_editing_sample_title,
description = R.string.imagen_editing_sample_description,
route = "ImagenMaskEditing",
sampleEntryScreen = { ImagenEditingScreen() },
tags = listOf(SampleTags.IMAGEN, SampleTags.FIREBASE, SampleTags.MEDIA3),
tags = listOf(SampleTags.IMAGEN, SampleTags.FIREBASE),
needsFirebase = true,
keyArt = R.drawable.img_keyart_imagen,
),
SampleCatalogItem(
title = R.string.magic_selfie_sample_title,
Expand All @@ -102,6 +114,7 @@ val sampleCatalog = listOf(
sampleEntryScreen = { MagicSelfieScreen() },
tags = listOf(SampleTags.IMAGEN, SampleTags.FIREBASE, SampleTags.ML_KIT),
needsFirebase = true,
keyArt = R.drawable.img_keyart_magic_selfie,
),
SampleCatalogItem(
title = R.string.gemini_video_summarization_sample_title,
Expand All @@ -118,6 +131,16 @@ val sampleCatalog = listOf(
sampleEntryScreen = { VideoMetadataCreationScreen() },
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

critical

The sampleEntryScreen for the "Video Summarization" sample is pointing to VideoMetadataCreationScreen() instead of VideoSummarizationScreen(). This will cause the wrong sample to be opened when selected from the catalog.

Suggested change
sampleEntryScreen = { VideoMetadataCreationScreen() },
sampleEntryScreen = { VideoSummarizationScreen() },

tags = listOf(SampleTags.GEMINI_FLASH, SampleTags.FIREBASE, SampleTags.MEDIA3),
needsFirebase = true,
keyArt = R.drawable.img_keyart_video_summary,
),
SampleCatalogItem(
title = R.string.gemini_video_metadata_creation_sample_title,
description = R.string.gemini_video_metadata_creation_sample_description,
route = "VideoMetadataCreationScreen",
sampleEntryScreen = { VideoMetadataCreationScreen() },
tags = listOf(SampleTags.GEMINI_FLASH, SampleTags.FIREBASE, SampleTags.MEDIA3),
needsFirebase = true,
keyArt = R.drawable.img_keyart_video_summary,
),
Comment on lines +136 to 144
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

This SampleCatalogItem for "Video Metadata Creation" appears to be a duplicate. There is another entry for it just before this one. Please remove the duplicated entry to avoid confusion and redundant code.

SampleCatalogItem(
title = R.string.gemini_live_todo_title,
Expand All @@ -126,6 +149,7 @@ val sampleCatalog = listOf(
sampleEntryScreen = { TodoScreen() },
tags = listOf(SampleTags.GEMINI_FLASH, SampleTags.FIREBASE),
needsFirebase = true,
keyArt = R.drawable.img_keyart_todo,
),

// To create a new sample entry, add a new SampleCatalogItem here.
Expand All @@ -138,17 +162,18 @@ data class SampleCatalogItem(
val sampleEntryScreen: @Composable () -> Unit,
val tags: List<SampleTags> = emptyList(),
val needsFirebase: Boolean = false,
val isFeatured: Boolean = false,
@DrawableRes val keyArt: Int? = null,
)

enum class SampleTags(
val label: String,
val backgroundColor: Color,
val textColor: Color,
) {
FIREBASE("Firebase", Color(0xFFFF9100), Color.White),
GEMINI_FLASH("Gemini Flash", Color(0xFF4285F4), Color.White),
GEMINI_NANO("Gemini Nano", Color(0xFF7abafe), Color.White),
IMAGEN("Imagen", Color(0xFF7CB342), Color.White),
MEDIA3("Media3", Color(0xFF7CB584), Color.White),
ML_KIT("ML Kit", Color.White, Color(0xFF4285F4)),
FIREBASE("Firebase", extendedColorScheme.firebase),
GEMINI_FLASH("Gemini Flash", extendedColorScheme.geminiProFlash),
GEMINI_NANO("Gemini Nano", extendedColorScheme.geminiNano),
IMAGEN("Imagen", extendedColorScheme.imagen),
MEDIA3("Media3", extendedColorScheme.media3),
ML_KIT("ML Kit", extendedColorScheme.mLKit),
}
Loading