@expo/ui 0.2.0-beta.1 → 0.2.0-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/android/build.gradle +2 -2
  3. package/android/src/main/java/expo/modules/ui/ChipView.kt +189 -0
  4. package/android/src/main/java/expo/modules/ui/ExpoUIModule.kt +7 -0
  5. package/android/src/main/java/expo/modules/ui/button/Button.kt +19 -8
  6. package/android/src/main/java/expo/modules/ui/menu/ContextMenu.kt +26 -4
  7. package/android/src/main/java/expo/modules/ui/menu/ContextMenuRecords.kt +2 -0
  8. package/build/jetpack-compose/Button/index.d.ts +14 -2
  9. package/build/jetpack-compose/Button/index.d.ts.map +1 -1
  10. package/build/jetpack-compose/Button/types.d.ts +1 -1
  11. package/build/jetpack-compose/Button/types.d.ts.map +1 -1
  12. package/build/jetpack-compose/Chip/index.d.ts +62 -0
  13. package/build/jetpack-compose/Chip/index.d.ts.map +1 -0
  14. package/build/jetpack-compose/ContextMenu/Submenu.d.ts +17 -0
  15. package/build/jetpack-compose/ContextMenu/Submenu.d.ts.map +1 -0
  16. package/build/jetpack-compose/ContextMenu/index.d.ts +3 -15
  17. package/build/jetpack-compose/ContextMenu/index.d.ts.map +1 -1
  18. package/build/jetpack-compose/ContextMenu/utils.d.ts.map +1 -1
  19. package/build/jetpack-compose/index.d.ts +1 -0
  20. package/build/jetpack-compose/index.d.ts.map +1 -1
  21. package/build/swift-ui/LabeledContent/index.d.ts +16 -0
  22. package/build/swift-ui/LabeledContent/index.d.ts.map +1 -0
  23. package/build/swift-ui/index.d.ts +1 -0
  24. package/build/swift-ui/index.d.ts.map +1 -1
  25. package/build/swift-ui/modifiers/index.d.ts +11 -8
  26. package/build/swift-ui/modifiers/index.d.ts.map +1 -1
  27. package/expo-module.config.json +1 -1
  28. package/ios/Button/Button.swift +7 -2
  29. package/ios/ExpoUIModule.swift +1 -0
  30. package/ios/LabeledContentView.swift +27 -0
  31. package/local-maven-repo/expo/modules/ui/expo.modules.ui/{0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1-sources.jar → 0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3-sources.jar} +0 -0
  32. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3-sources.jar.md5 +1 -0
  33. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3-sources.jar.sha1 +1 -0
  34. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3-sources.jar.sha256 +1 -0
  35. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3-sources.jar.sha512 +1 -0
  36. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.aar +0 -0
  37. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.aar.md5 +1 -0
  38. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.aar.sha1 +1 -0
  39. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.aar.sha256 +1 -0
  40. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.aar.sha512 +1 -0
  41. package/local-maven-repo/expo/modules/ui/expo.modules.ui/{0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.module → 0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.module} +22 -22
  42. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.module.md5 +1 -0
  43. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.module.sha1 +1 -0
  44. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.module.sha256 +1 -0
  45. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.module.sha512 +1 -0
  46. package/local-maven-repo/expo/modules/ui/expo.modules.ui/{0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.pom → 0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.pom} +1 -1
  47. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.pom.md5 +1 -0
  48. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.pom.sha1 +1 -0
  49. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.pom.sha256 +1 -0
  50. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.3/expo.modules.ui-0.2.0-beta.3.pom.sha512 +1 -0
  51. package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml +4 -4
  52. package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.md5 +1 -1
  53. package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.sha1 +1 -1
  54. package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.sha256 +1 -1
  55. package/local-maven-repo/expo/modules/ui/expo.modules.ui/maven-metadata.xml.sha512 +1 -1
  56. package/package.json +2 -2
  57. package/src/jetpack-compose/Button/index.tsx +21 -4
  58. package/src/jetpack-compose/Button/types.ts +3 -0
  59. package/src/jetpack-compose/Chip/index.tsx +101 -0
  60. package/src/jetpack-compose/ContextMenu/Submenu.tsx +21 -0
  61. package/src/jetpack-compose/ContextMenu/index.tsx +3 -19
  62. package/src/jetpack-compose/ContextMenu/utils.ts +3 -2
  63. package/src/jetpack-compose/index.ts +1 -0
  64. package/src/swift-ui/LabeledContent/index.tsx +34 -0
  65. package/src/swift-ui/index.tsx +1 -0
  66. package/src/swift-ui/modifiers/index.ts +32 -8
  67. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1-sources.jar.md5 +0 -1
  68. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1-sources.jar.sha1 +0 -1
  69. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1-sources.jar.sha256 +0 -1
  70. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1-sources.jar.sha512 +0 -1
  71. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.aar +0 -0
  72. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.aar.md5 +0 -1
  73. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.aar.sha1 +0 -1
  74. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.aar.sha256 +0 -1
  75. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.aar.sha512 +0 -1
  76. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.module.md5 +0 -1
  77. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.module.sha1 +0 -1
  78. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.module.sha256 +0 -1
  79. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.module.sha512 +0 -1
  80. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.pom.md5 +0 -1
  81. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.pom.sha1 +0 -1
  82. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.pom.sha256 +0 -1
  83. package/local-maven-repo/expo/modules/ui/expo.modules.ui/0.2.0-beta.1/expo.modules.ui-0.2.0-beta.1.pom.sha512 +0 -1
package/CHANGELOG.md CHANGED
@@ -10,6 +10,24 @@
10
10
 
11
11
  ### 💡 Others
12
12
 
13
+ ## 0.2.0-beta.3 — 2025-09-16
14
+
15
+ ### 🎉 New features
16
+
17
+ - [iOS] Add `LabeledContent` view ([#39463](https://github.com/expo/expo/pull/39617) by [@betomoedano](https://github.com/betomoedano))
18
+
19
+ ### 🐛 Bug fixes
20
+
21
+ - [ios] tvOS 26 compile fix and card button. ([#39639](https://github.com/expo/expo/pull/39639) by [@douglowder](https://github.com/douglowder))
22
+
23
+ ### 💡 Others
24
+
25
+ - [Android] **Button**: Deprecate `systemImage` prop in favor of `leadingIcon` and `trailingIcon` for more flexible icon placement. The `systemImage` prop will continue to work as `leadingIcon` for backward compatibility. ([#39095](https://github.com/expo/expo/pull/39095) by [@benjaminkomen](https://github.com/benjaminkomen))
26
+
27
+ ## 0.2.0-beta.2 — 2025-09-12
28
+
29
+ _This version does not introduce any user-facing changes._
30
+
13
31
  ## 0.2.0-beta.1 — 2025-09-11
14
32
 
15
33
  ### 🐛 Bug fixes
@@ -79,6 +97,7 @@ _This version does not introduce any user-facing changes._
79
97
 
80
98
  - [Android] Add compose modifier support. ([#38630](https://github.com/expo/expo/pull/38630) by [@aleqsio](https://github.com/aleqsio))
81
99
  - [iOS] Add `glassEffect` modifier. ([#38876](https://github.com/expo/expo/pull/38876) by [@nishan](https://github.com/intergalacticspacehighway))
100
+ - [Android] Add Chip component for Android. ([#39094](https://github.com/expo/expo/pull/39094) by [@hryhoriiK97](https://github.com/hryhoriiK97))
82
101
 
83
102
  ## 0.2.0-alpha.0 — 2025-08-13
84
103
 
@@ -12,13 +12,13 @@ apply plugin: 'expo-module-gradle-plugin'
12
12
  apply plugin: 'org.jetbrains.kotlin.plugin.compose'
13
13
 
14
14
  group = 'expo.modules.ui'
15
- version = '0.2.0-beta.1'
15
+ version = '0.2.0-beta.3'
16
16
 
17
17
  android {
18
18
  namespace "expo.modules.ui"
19
19
  defaultConfig {
20
20
  versionCode 1
21
- versionName "0.2.0-beta.1"
21
+ versionName "0.2.0-beta.3"
22
22
  }
23
23
  buildFeatures {
24
24
  compose true
@@ -0,0 +1,189 @@
1
+ package expo.modules.ui
2
+
3
+ import android.content.Context
4
+ import androidx.compose.foundation.layout.*
5
+ import androidx.compose.material3.*
6
+ import androidx.compose.runtime.*
7
+ import androidx.compose.ui.Alignment
8
+ import androidx.compose.ui.Modifier
9
+ import androidx.compose.ui.graphics.Color
10
+ import androidx.compose.ui.text.style.TextAlign
11
+ import androidx.compose.ui.unit.dp
12
+ import expo.modules.kotlin.AppContext
13
+ import expo.modules.kotlin.records.Record
14
+ import expo.modules.kotlin.viewevent.EventDispatcher
15
+ import expo.modules.kotlin.views.ComposeProps
16
+ import expo.modules.kotlin.views.ExpoComposeView
17
+ import java.io.Serializable
18
+
19
+ open class ChipPressedEvent : Record, Serializable
20
+
21
+ data class ChipProps(
22
+ val variant: MutableState<String> = mutableStateOf("assist"),
23
+ val label: MutableState<String> = mutableStateOf(""),
24
+ val leadingIcon: MutableState<String?> = mutableStateOf(null),
25
+ val trailingIcon: MutableState<String?> = mutableStateOf(null),
26
+ val iconSize: MutableState<Int> = mutableIntStateOf(18),
27
+ val textStyle: MutableState<String> = mutableStateOf("labelSmall"),
28
+ val enabled: MutableState<Boolean> = mutableStateOf(true),
29
+ val selected: MutableState<Boolean> = mutableStateOf(false)
30
+ ) : ComposeProps
31
+
32
+ class ChipView(context: Context, appContext: AppContext) :
33
+ ExpoComposeView<ChipProps>(context, appContext, withHostingView = true) {
34
+
35
+ override val props = ChipProps()
36
+
37
+ private val onPress by EventDispatcher<ChipPressedEvent>()
38
+ private val onDismiss by EventDispatcher<ChipPressedEvent>()
39
+
40
+ @OptIn(ExperimentalMaterial3Api::class)
41
+ @Composable
42
+ override fun Content(modifier: Modifier) {
43
+ val variant by props.variant
44
+ val label by props.label
45
+ val leadingIcon by props.leadingIcon
46
+ val trailingIcon by props.trailingIcon
47
+ val iconSize by props.iconSize
48
+ val textStyle by props.textStyle
49
+ val enabled by props.enabled
50
+ val selected by props.selected
51
+
52
+ val chipModifier = modifier
53
+ .padding(4.dp)
54
+ .wrapContentSize(Alignment.Center)
55
+
56
+ @Composable
57
+ fun AssistChipComposable() {
58
+ AssistChip(
59
+ onClick = { onPress.invoke(ChipPressedEvent()) },
60
+ label = { ChipText(label = label, textStyle = textStyle) },
61
+ leadingIcon = {
62
+ leadingIcon?.let {
63
+ ChipIcon(iconName = it, iconSize = iconSize)
64
+ }
65
+ },
66
+ trailingIcon = {
67
+ trailingIcon?.let {
68
+ ChipIcon(iconName = it, iconSize = iconSize)
69
+ }
70
+ },
71
+ enabled = enabled,
72
+ colors = AssistChipDefaults.assistChipColors(),
73
+ border = AssistChipDefaults.assistChipBorder(enabled = enabled),
74
+ modifier = chipModifier
75
+ )
76
+ }
77
+
78
+ @Composable
79
+ fun FilterChipComposable() {
80
+ FilterChip(
81
+ onClick = { onPress.invoke(ChipPressedEvent()) },
82
+ label = { ChipText(label = label, textStyle = textStyle) },
83
+ selected = selected,
84
+ leadingIcon = if (selected) {
85
+ {
86
+ ChipIcon(iconName = "filled.Done", iconSize = iconSize)
87
+ }
88
+ } else {
89
+ null
90
+ },
91
+ trailingIcon = {
92
+ trailingIcon?.let {
93
+ ChipIcon(iconName = it, iconSize = iconSize)
94
+ }
95
+ },
96
+ enabled = enabled,
97
+ colors = FilterChipDefaults.filterChipColors(),
98
+ border = FilterChipDefaults.filterChipBorder(enabled = enabled, selected = selected),
99
+ modifier = chipModifier
100
+ )
101
+ }
102
+
103
+ @Composable
104
+ fun InputChipComposable() {
105
+ if (!enabled) return
106
+ InputChip(
107
+ onClick = { onDismiss.invoke(ChipPressedEvent()) },
108
+ label = { ChipText(label = label, textStyle = textStyle) },
109
+ enabled = enabled,
110
+ selected = selected,
111
+ avatar = {
112
+ leadingIcon?.let {
113
+ ChipIcon(iconName = it, iconSize = iconSize)
114
+ }
115
+ },
116
+ trailingIcon = {
117
+ ChipIcon(
118
+ iconName = trailingIcon ?: "filled.Close",
119
+ iconSize = iconSize
120
+ )
121
+ },
122
+ modifier = chipModifier
123
+ )
124
+ }
125
+
126
+ @Composable
127
+ fun SuggestionChipComposable() {
128
+ SuggestionChip(
129
+ onClick = { onPress.invoke(ChipPressedEvent()) },
130
+ label = { ChipText(label = label, textStyle = textStyle) },
131
+ icon = {
132
+ leadingIcon?.let {
133
+ ChipIcon(iconName = it, iconSize = iconSize)
134
+ }
135
+ },
136
+ modifier = chipModifier
137
+ )
138
+ }
139
+
140
+ when (variant.lowercase()) {
141
+ "assist" -> AssistChipComposable()
142
+ "filter" -> FilterChipComposable()
143
+ "input" -> InputChipComposable()
144
+ "suggestion" -> SuggestionChipComposable()
145
+ else -> AssistChipComposable()
146
+ }
147
+ }
148
+ }
149
+
150
+ @Composable
151
+ private fun ChipText(label: String, textStyle: String = "labelSmall") {
152
+ Box(
153
+ contentAlignment = Alignment.Center,
154
+ modifier = Modifier.fillMaxSize()
155
+ ) {
156
+ Text(
157
+ text = label,
158
+ style = when (textStyle) {
159
+ "labelSmall" -> MaterialTheme.typography.labelSmall
160
+ "labelMedium" -> MaterialTheme.typography.labelMedium
161
+ "labelLarge" -> MaterialTheme.typography.labelLarge
162
+ "bodySmall" -> MaterialTheme.typography.bodySmall
163
+ "bodyMedium" -> MaterialTheme.typography.bodyMedium
164
+ "bodyLarge" -> MaterialTheme.typography.bodyLarge
165
+ else -> MaterialTheme.typography.labelSmall
166
+ },
167
+ textAlign = TextAlign.Center
168
+ )
169
+ }
170
+ }
171
+
172
+ @Composable
173
+ private fun ChipIcon(
174
+ iconName: String,
175
+ iconSize: Int = 18,
176
+ tint: Color = MaterialTheme.colorScheme.primary,
177
+ modifier: Modifier = Modifier
178
+ ) {
179
+ getImageVector(iconName)?.let { imageVector ->
180
+ Icon(
181
+ imageVector = imageVector,
182
+ contentDescription = iconName,
183
+ tint = tint,
184
+ modifier = modifier
185
+ .size(iconSize.dp)
186
+ .padding(end = 4.dp)
187
+ )
188
+ }
189
+ }
@@ -97,6 +97,13 @@ class ExpoUIModule : Module() {
97
97
  )
98
98
  }
99
99
 
100
+ View(ChipView::class) {
101
+ Events(
102
+ "onPress",
103
+ "onDismiss"
104
+ )
105
+ }
106
+
100
107
  Function("padding") { all: Int ->
101
108
  return@Function ExpoModifier(Modifier.padding(Dp(all.toFloat())))
102
109
  }
@@ -60,7 +60,8 @@ data class ButtonProps(
60
60
  val text: MutableState<String> = mutableStateOf(""),
61
61
  val variant: MutableState<ButtonVariant?> = mutableStateOf(ButtonVariant.DEFAULT),
62
62
  val elementColors: MutableState<ButtonColors> = mutableStateOf(ButtonColors()),
63
- val systemImage: MutableState<String?> = mutableStateOf(null),
63
+ val leadingIcon: MutableState<String?> = mutableStateOf(null),
64
+ val trailingIcon: MutableState<String?> = mutableStateOf(null),
64
65
  val disabled: MutableState<Boolean> = mutableStateOf(false),
65
66
  val modifiers: MutableState<List<ExpoModifier>> = mutableStateOf(emptyList())
66
67
  ) : ComposeProps
@@ -150,7 +151,8 @@ class Button(context: Context, appContext: AppContext) :
150
151
  val (variant) = props.variant
151
152
  val (text) = props.text
152
153
  val (colors) = props.elementColors
153
- val (systemImage) = props.systemImage
154
+ val (leadingIcon) = props.leadingIcon
155
+ val (trailingIcon) = props.trailingIcon
154
156
  val (disabled) = props.disabled
155
157
  DynamicTheme {
156
158
  StyledButton(
@@ -160,19 +162,28 @@ class Button(context: Context, appContext: AppContext) :
160
162
  onPress = { onButtonPressed.invoke(ButtonPressedEvent()) },
161
163
  modifier = Modifier.fromExpoModifiers(props.modifiers.value)
162
164
  ) {
163
- if (systemImage != null) {
164
- Row(verticalAlignment = Alignment.CenterVertically) {
165
- getImageVector(systemImage)?.let {
165
+ Row(verticalAlignment = Alignment.CenterVertically) {
166
+ leadingIcon?.let { iconName ->
167
+ getImageVector(iconName)?.let {
166
168
  Icon(
167
169
  it,
168
- contentDescription = systemImage,
170
+ contentDescription = iconName,
169
171
  modifier = Modifier.padding(end = 8.dp)
170
172
  )
171
173
  }
172
- Text(text)
173
174
  }
174
- } else {
175
+
175
176
  Text(text)
177
+
178
+ trailingIcon?.let { iconName ->
179
+ getImageVector(iconName)?.let {
180
+ Icon(
181
+ it,
182
+ contentDescription = iconName,
183
+ modifier = Modifier.padding(start = 8.dp)
184
+ )
185
+ }
186
+ }
176
187
  }
177
188
  }
178
189
  }
@@ -13,6 +13,7 @@ import androidx.compose.foundation.layout.wrapContentSize
13
13
  import androidx.compose.material3.DropdownMenu
14
14
  import androidx.compose.material3.DropdownMenuItem
15
15
  import androidx.compose.material3.HorizontalDivider
16
+ import androidx.compose.material3.Icon
16
17
  import androidx.compose.material3.MaterialTheme
17
18
  import androidx.compose.material3.MenuDefaults
18
19
  import androidx.compose.material3.MenuItemColors
@@ -34,6 +35,7 @@ import expo.modules.ui.DynamicTheme
34
35
  import expo.modules.ui.ThemedHybridSwitch
35
36
  import expo.modules.ui.compose
36
37
  import expo.modules.ui.composeOrNull
38
+ import expo.modules.ui.getImageVector
37
39
 
38
40
  @Composable
39
41
  private fun SectionTitle(text: String) {
@@ -58,15 +60,35 @@ fun FlatMenu(elements: Array<ContextMenuElement>, sectionTitle: String?, dispatc
58
60
  DropdownMenuItem(
59
61
  colors = MenuItemColors(
60
62
  textColor = it.elementColors.contentColor.compose,
61
- leadingIconColor = null.compose,
62
- trailingIconColor = null.compose,
63
+ leadingIconColor = it.elementColors.contentColor.compose,
64
+ trailingIconColor = it.elementColors.contentColor.compose,
63
65
  disabledTextColor = it.elementColors.disabledContentColor.compose,
64
- disabledLeadingIconColor = null.compose,
65
- disabledTrailingIconColor = null.compose
66
+ disabledLeadingIconColor = it.elementColors.disabledContentColor.compose,
67
+ disabledTrailingIconColor = it.elementColors.disabledContentColor.compose
66
68
  ),
67
69
  enabled = !it.disabled,
68
70
  modifier = Modifier.background(it.elementColors.containerColor.compose),
69
71
  text = { Text(it.text) },
72
+ leadingIcon = it.leadingIcon?.let { iconName ->
73
+ {
74
+ getImageVector(iconName)?.let { imageVector ->
75
+ Icon(
76
+ imageVector = imageVector,
77
+ contentDescription = iconName
78
+ )
79
+ }
80
+ }
81
+ },
82
+ trailingIcon = it.trailingIcon?.let { iconName ->
83
+ {
84
+ getImageVector(iconName)?.let { imageVector ->
85
+ Icon(
86
+ imageVector = imageVector,
87
+ contentDescription = iconName
88
+ )
89
+ }
90
+ }
91
+ },
70
92
  onClick = {
71
93
  dispatchers.buttonPressed(ContextMenuButtonPressedEvent(id))
72
94
  expanded.value = false
@@ -42,6 +42,8 @@ class ContextMenuButtonProps(
42
42
  @Field val text: String = "",
43
43
  @Field val variant: ButtonVariant? = ButtonVariant.DEFAULT,
44
44
  @Field val elementColors: ButtonColors = ButtonColors(),
45
+ @Field val leadingIcon: String? = null,
46
+ @Field val trailingIcon: String? = null,
45
47
  @Field val disabled: Boolean = false
46
48
  ) : Record, Serializable
47
49
 
@@ -21,9 +21,20 @@ export type ButtonProps = {
21
21
  * A callback that is called when the button is pressed.
22
22
  */
23
23
  onPress?: () => void;
24
+ /**
25
+ * A string describing the leading icon to display in the button.
26
+ * Uses Material Icons on Android.
27
+ */
28
+ leadingIcon?: MaterialIcon;
29
+ /**
30
+ * A string describing the trailing icon to display in the button.
31
+ * Uses Material Icons on Android.
32
+ */
33
+ trailingIcon?: MaterialIcon;
24
34
  /**
25
35
  * A string describing the system image to display in the button.
26
36
  * Uses Material Icons on Android.
37
+ * @deprecated Use `leadingIcon` instead.
27
38
  */
28
39
  systemImage?: MaterialIcon;
29
40
  /**
@@ -57,9 +68,10 @@ export type ButtonProps = {
57
68
  /**
58
69
  * @hidden
59
70
  */
60
- export type NativeButtonProps = Omit<ButtonProps, 'role' | 'onPress' | 'children' | 'systemImage'> & {
71
+ export type NativeButtonProps = Omit<ButtonProps, 'role' | 'onPress' | 'children' | 'leadingIcon' | 'trailingIcon' | 'systemImage'> & {
61
72
  text: string;
62
- systemImage?: string;
73
+ leadingIcon?: string;
74
+ trailingIcon?: string;
63
75
  } & ViewEvent<'onButtonPressed', void>;
64
76
  /**
65
77
  * @hidden
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/jetpack-compose/Button/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAc,SAAS,EAAE,MAAM,cAAc,CAAC;AAEhE,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAEtD;;;;GAIG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,UAAU,GAAG,YAAY,GAAG,UAAU,GAAG,UAAU,CAAC;AAE5F;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG;IAChC,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,oBAAoB,CAAC,EAAE,MAAM,CAAC;CAC/B,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB;;;OAGG;IACH,WAAW,CAAC,EAAE,YAAY,CAAC;IAC3B;;OAEG;IACH,OAAO,CAAC,EAAE,aAAa,CA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' | 'AddCircle' | 'ArrowBack' | 'ArrowDropDown' | 'ArrowForward' | 'Build' | 'Call' | 'Check' | 'CheckCircle' | 'Clear' | 'Close' | 'Create' | 'DateRange' | 'Delete' | 'Done' | 'Edit' | 'Email' | 'ExitToApp' | 'Face' | 'Favorite' | 'FavoriteBorder' | 'Home' | 'Info' | 'KeyboardArrowDown' | 'KeyboardArrowLeft' | 'KeyboardArrowRight' | 'KeyboardArrowUp' | 'List' | 'LocationOn' | 'Lock' | 'MailOutline' | 'Menu' | 'MoreVert' | 'Notifications' | 'Person' | 'Phone' | 'Place' | 'PlayArrow' | 'Refresh' | 'Search' | 'Send' | 'Settings' | 'Share' | 'ShoppingCart' | 'Star' | 'ThumbUp' | 'Warning';
2
+ type Icon = 'AccountBox' | 'AccountCircle' | 'Add' | 'AddCircle' | 'ArrowBack' | 'ArrowDropDown' | 'ArrowForward' | 'Build' | 'Call' | 'Check' | 'CheckCircle' | 'Clear' | 'Close' | 'Contrast' | 'Create' | 'DarkMode' | 'DateRange' | 'Delete' | 'Done' | 'Edit' | 'Email' | 'ExitToApp' | 'Face' | 'Favorite' | 'FavoriteBorder' | 'Home' | 'Info' | 'KeyboardArrowDown' | 'KeyboardArrowLeft' | 'KeyboardArrowRight' | 'KeyboardArrowUp' | 'LightMode' | 'List' | 'LocationOn' | 'Lock' | 'MailOutline' | 'Menu' | 'MoreVert' | 'Notifications' | 'Person' | 'Phone' | 'Place' | 'PlayArrow' | 'Refresh' | 'Search' | 'Send' | 'Settings' | 'Share' | 'ShoppingCart' | 'Star' | 'ThumbUp' | 'Warning';
3
3
  export type MaterialIcon = `${Variant}.${Icon}`;
4
4
  export {};
5
5
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/jetpack-compose/Button/types.ts"],"names":[],"mappings":"AAAA,KAAK,OAAO,GAAG,SAAS,GAAG,SAAS,GAAG,UAAU,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEvE,KAAK,IAAI,GACL,YAAY,GACZ,eAAe,GACf,KAAK,GACL,WAAW,GACX,WAAW,GACX,eAAe,GACf,cAAc,GACd,OAAO,GACP,MAAM,GACN,OAAO,GACP,aAAa,GACb,OAAO,GACP,OAAO,GACP,QAAQ,GACR,WAAW,GACX,QAAQ,GACR,MAAM,GACN,MAAM,GACN,OAAO,GACP,WAAW,GACX,MAAM,GACN,UAAU,GACV,gBAAgB,GAChB,MAAM,GACN,MAAM,GACN,mBAAmB,GACnB,mBAAmB,GACnB,oBAAoB,GACpB,iBAAiB,GACjB,MAAM,GACN,YAAY,GACZ,MAAM,GACN,aAAa,GACb,MAAM,GACN,UAAU,GACV,eAAe,GACf,QAAQ,GACR,OAAO,GACP,OAAO,GACP,WAAW,GACX,SAAS,GACT,QAAQ,GACR,MAAM,GACN,UAAU,GACV,OAAO,GACP,cAAc,GACd,MAAM,GACN,SAAS,GACT,SAAS,CAAC;AAEd,MAAM,MAAM,YAAY,GAAG,GAAG,OAAO,IAAI,IAAI,EAAE,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/jetpack-compose/Button/types.ts"],"names":[],"mappings":"AAAA,KAAK,OAAO,GAAG,SAAS,GAAG,SAAS,GAAG,UAAU,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEvE,KAAK,IAAI,GACL,YAAY,GACZ,eAAe,GACf,KAAK,GACL,WAAW,GACX,WAAW,GACX,eAAe,GACf,cAAc,GACd,OAAO,GACP,MAAM,GACN,OAAO,GACP,aAAa,GACb,OAAO,GACP,OAAO,GACP,UAAU,GACV,QAAQ,GACR,UAAU,GACV,WAAW,GACX,QAAQ,GACR,MAAM,GACN,MAAM,GACN,OAAO,GACP,WAAW,GACX,MAAM,GACN,UAAU,GACV,gBAAgB,GAChB,MAAM,GACN,MAAM,GACN,mBAAmB,GACnB,mBAAmB,GACnB,oBAAoB,GACpB,iBAAiB,GACjB,WAAW,GACX,MAAM,GACN,YAAY,GACZ,MAAM,GACN,aAAa,GACb,MAAM,GACN,UAAU,GACV,eAAe,GACf,QAAQ,GACR,OAAO,GACP,OAAO,GACP,WAAW,GACX,SAAS,GACT,QAAQ,GACR,MAAM,GACN,UAAU,GACV,OAAO,GACP,cAAc,GACd,MAAM,GACN,SAAS,GACT,SAAS,CAAC;AAEd,MAAM,MAAM,YAAY,GAAG,GAAG,OAAO,IAAI,IAAI,EAAE,CAAC"}
@@ -0,0 +1,62 @@
1
+ import React from 'react';
2
+ import { ViewProps } from 'react-native';
3
+ import { ExpoModifier } from '../../types';
4
+ /**
5
+ * Available text style variants for chip labels.
6
+ */
7
+ export type ChipTextStyle = 'labelSmall' | 'labelMedium' | 'labelLarge' | 'bodySmall' | 'bodyMedium' | 'bodyLarge';
8
+ export interface ChipProps extends ViewProps {
9
+ /**
10
+ * The variant of the chip
11
+ */
12
+ variant?: 'assist' | 'filter' | 'input' | 'suggestion';
13
+ /**
14
+ * The text label to display on the chip
15
+ */
16
+ label: string;
17
+ /**
18
+ * Optional leading icon name (using Material Icons). Used for assist, filter, input (avatar icon), and suggestion chips.
19
+ */
20
+ leadingIcon?: string;
21
+ /**
22
+ * Optional trailing icon name (using Material Icons). Used for assist, filter, and input chips. For input chips, defaults to 'filled.Close' if not specified.
23
+ */
24
+ trailingIcon?: string;
25
+ /**
26
+ * Size of the icon in density-independent pixels (dp). Defaults to 18.
27
+ */
28
+ iconSize?: number;
29
+ /**
30
+ * Text style variant for the chip label. Defaults to 'labelSmall'.
31
+ */
32
+ textStyle?: ChipTextStyle;
33
+ /**
34
+ * Whether the chip is enabled and can be clicked. Used for assist, filter and input chips.
35
+ */
36
+ enabled?: boolean;
37
+ /**
38
+ * Whether the chip is selected. Used only for filter chips.
39
+ */
40
+ selected?: boolean;
41
+ /**
42
+ * Modifiers for the component
43
+ */
44
+ modifiers?: ExpoModifier[];
45
+ /**
46
+ * Callback fired when the chip is clicked. Used for assist and filter chips.
47
+ */
48
+ onPress?: () => void;
49
+ /**
50
+ * Callback fired when the chip is dismissed. Only used for input chips.
51
+ */
52
+ onDismiss?: () => void;
53
+ }
54
+ /**
55
+ * @hidden
56
+ */
57
+ export declare function transformChipProps(props: ChipProps): ChipProps;
58
+ /**
59
+ * Displays a native chip component.
60
+ */
61
+ export declare function Chip(props: ChipProps): React.JSX.Element;
62
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/jetpack-compose/Chip/index.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAc,SAAS,EAAE,MAAM,cAAc,CAAC;AAErD,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAE3C;;GAEG;AACH,MAAM,MAAM,aAAa,GACrB,YAAY,GACZ,aAAa,GACb,YAAY,GACZ,WAAW,GACX,YAAY,GACZ,WAAW,CAAC;AAEhB,MAAM,WAAW,SAAU,SAAQ,SAAS;IAC1C;;OAEG;IACH,OAAO,CAAC,EAAE,QAAQ,GAAG,QAAQ,GAAG,OAAO,GAAG,YAAY,CAAC;IAEvD;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,SAAS,CAAC,EAAE,aAAa,CAAC;IAE1B;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;OAEG;IACH,SAAS,CAAC,EAAE,YAAY,EAAE,CAAC;IAE3B;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IAErB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;CACxB;AAKD;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,SAAS,GAAG,SAAS,CAO9D;AAED;;GAEG;AACH,wBAAgB,IAAI,CAAC,KAAK,EAAE,SAAS,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAQxD"}
@@ -0,0 +1,17 @@
1
+ import { ReactElement, ReactNode } from 'react';
2
+ import { ButtonProps } from '../Button';
3
+ /**
4
+ * Props of the `Submenu` component.
5
+ */
6
+ export type SubmenuProps = {
7
+ /**
8
+ * The button that will be used to expand the submenu. On Android the `text` prop of the `Button` will be used as a section title.
9
+ */
10
+ button: ReactElement<ButtonProps>;
11
+ /**
12
+ * Children of the submenu. Only `Button`, `Switch`, `Picker` and `Submenu` elements should be used.
13
+ */
14
+ children: ReactNode;
15
+ };
16
+ export declare function Submenu(props: SubmenuProps): import("react").JSX.Element;
17
+ //# sourceMappingURL=Submenu.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Submenu.d.ts","sourceRoot":"","sources":["../../../src/jetpack-compose/ContextMenu/Submenu.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEhD,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAExC;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB;;OAEG;IACH,MAAM,EAAE,YAAY,CAAC,WAAW,CAAC,CAAC;IAClC;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;CACrB,CAAC;AAEF,wBAAgB,OAAO,CAAC,KAAK,EAAE,YAAY,+BAE1C"}
@@ -1,5 +1,6 @@
1
1
  import { ReactElement, ReactNode } from 'react';
2
2
  import { NativeSyntheticEvent, StyleProp, ViewStyle } from 'react-native';
3
+ import { SubmenuProps } from './Submenu';
3
4
  import { ExpoModifier } from '../../types';
4
5
  import { ButtonProps } from '../Button';
5
6
  import { PickerProps } from '../Picker';
@@ -52,21 +53,7 @@ export type ContextMenuProps = {
52
53
  /** Modifiers for the component */
53
54
  modifiers?: ExpoModifier[];
54
55
  };
55
- /**
56
- * Props of the `Submenu` component.
57
- */
58
- export type SubmenuProps = {
59
- /**
60
- * The button that will be used to expand the submenu. On Android the `text` prop of the `Button` will be used as a section title.
61
- */
62
- button: ReactElement<ButtonProps>;
63
- /**
64
- * Children of the submenu. Only `Button`, `Switch`, `Picker` and `Submenu` elements should be used.
65
- */
66
- children: ReactNode;
67
- };
68
- export declare function Submenu(): import("react").JSX.Element;
69
- export declare function Items(): import("react").JSX.Element;
56
+ export declare function Items(props: ContextMenuContentProps): import("react").JSX.Element;
70
57
  export declare namespace Items {
71
58
  var tag: string;
72
59
  }
@@ -86,4 +73,5 @@ declare namespace ContextMenu {
86
73
  var Items: typeof import(".").Items;
87
74
  }
88
75
  export { ContextMenu };
76
+ export { Submenu } from './Submenu';
89
77
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/jetpack-compose/ContextMenu/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAY,YAAY,EAAE,SAAS,EAAW,MAAM,OAAO,CAAC;AACnE,OAAO,EAAE,oBAAoB,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAG1E,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAOxC,KAAK,cAAc,GACf,YAAY,CAAC,WAAW,CAAC,GACzB,YAAY,CAAC,WAAW,CAAC,GACzB,YAAY,CAAC,WAAW,CAAC,GACzB,YAAY,CAAC,YAAY,CAAC,CAAC;AAE/B,MAAM,MAAM,uBAAuB,GAAG;IACpC,QAAQ,EAAE,cAAc,GAAG,cAAc,EAAE,CAAC;CAC7C,CAAC;AAEF;;GAEG;AACH,MA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 +1,5 @@
1
1
  export * from './AlertDialog';
2
+ export * from './Chip';
2
3
  export * from './Button';
3
4
  export * from './ContextMenu';
4
5
  export * from './DatePicker';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/jetpack-compose/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/jetpack-compose/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC"}
@@ -0,0 +1,16 @@
1
+ import { type CommonViewModifierProps } from '../types';
2
+ export type LabeledContentProps = {
3
+ /**
4
+ * The label to be displayed in the labeled content.
5
+ */
6
+ label?: string;
7
+ children: React.ReactNode;
8
+ } & CommonViewModifierProps;
9
+ /**
10
+ * LabeledContent component uses the native [LabeledContent](https://developer.apple.com/documentation/swiftui/labeledcontent) component.
11
+ * A container for attaching a label to a value-bearing view.
12
+ * Available from iOS 16.0.
13
+ * @platform ios
14
+ */
15
+ export declare function LabeledContent(props: LabeledContentProps): import("react").JSX.Element;
16
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/swift-ui/LabeledContent/index.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,KAAK,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAExD,MAAM,MAAM,mBAAmB,GAAG;IAChC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B,GAAG,uBAAuB,CAAC;AAO5B;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,mBAAmB,+BASxD"}
@@ -11,6 +11,7 @@ export * from './Gauge';
11
11
  export * from './Host';
12
12
  export * from './Image';
13
13
  export * from './Label';
14
+ export * from './LabeledContent';
14
15
  export * from './Layout';
15
16
  export * from './List';
16
17
  export * from './Picker';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/swift-ui/index.tsx"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,eAAe,CAAC;AAC9B,cAAc,0BAA0B,CAAC;AACzC,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,a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