@momo-kits/native-kits 0.157.1-debug → 0.157.1-skill.1-debug

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 (43) hide show
  1. package/.claude/momo-native-kits/SKILL.md +87 -0
  2. package/.claude/momo-native-kits/references/Badge.md +39 -0
  3. package/.claude/momo-native-kits/references/BadgeDot.md +37 -0
  4. package/.claude/momo-native-kits/references/BottomSheet.md +51 -0
  5. package/.claude/momo-native-kits/references/BottomTab.md +65 -0
  6. package/.claude/momo-native-kits/references/Button.md +197 -0
  7. package/.claude/momo-native-kits/references/CheckBox.md +51 -0
  8. package/.claude/momo-native-kits/references/Chip.md +47 -0
  9. package/.claude/momo-native-kits/references/Divider.md +29 -0
  10. package/.claude/momo-native-kits/references/HeaderTitle.md +45 -0
  11. package/.claude/momo-native-kits/references/HeaderType.md +47 -0
  12. package/.claude/momo-native-kits/references/Icon.md +32 -0
  13. package/.claude/momo-native-kits/references/Image.md +38 -0
  14. package/.claude/momo-native-kits/references/Information.md +36 -0
  15. package/.claude/momo-native-kits/references/Input.md +334 -0
  16. package/.claude/momo-native-kits/references/InputDropDown.md +47 -0
  17. package/.claude/momo-native-kits/references/InputMoney.md +241 -0
  18. package/.claude/momo-native-kits/references/InputOTP.md +52 -0
  19. package/.claude/momo-native-kits/references/InputPhoneNumber.md +175 -0
  20. package/.claude/momo-native-kits/references/InputSearch.md +57 -0
  21. package/.claude/momo-native-kits/references/InputTextArea.md +46 -0
  22. package/.claude/momo-native-kits/references/NavigationContainer.md +51 -0
  23. package/.claude/momo-native-kits/references/Navigator.md +287 -0
  24. package/.claude/momo-native-kits/references/PaginationDot.md +28 -0
  25. package/.claude/momo-native-kits/references/PaginationNumber.md +28 -0
  26. package/.claude/momo-native-kits/references/PopupNotify.md +47 -0
  27. package/.claude/momo-native-kits/references/Radio.md +44 -0
  28. package/.claude/momo-native-kits/references/Skeleton.md +32 -0
  29. package/.claude/momo-native-kits/references/Switch.md +36 -0
  30. package/.claude/momo-native-kits/references/Tag.md +40 -0
  31. package/.claude/momo-native-kits/references/Text.md +37 -0
  32. package/.claude/momo-native-kits/references/Title.md +43 -0
  33. package/.claude/momo-native-kits/references/Tooltip.md +30 -0
  34. package/.claude/settings.local.json +13 -0
  35. package/building-skill-for-claude.md +1190 -0
  36. package/compose/build.gradle.kts +1 -1
  37. package/compose/compose.podspec +1 -1
  38. package/compose/src/commonMain/kotlin/vn/momo/kits/components/Button.kt +51 -33
  39. package/compose/src/commonMain/kotlin/vn/momo/kits/components/Tooltip.kt +41 -27
  40. package/gradle.properties +1 -1
  41. package/ios/Input/InputPhoneNumber.swift +2 -1
  42. package/local.properties +8 -0
  43. package/package.json +1 -1
@@ -0,0 +1,287 @@
1
+ ---
2
+ name: navigator
3
+ description: Class for managing navigation between screens. Use when navigating between screens, showing modals, bottom sheets, or snackbars.
4
+ ---
5
+
6
+ # Navigator
7
+
8
+ Class for managing navigation between screens, modals, bottom sheets, and snackbars.
9
+
10
+ ## API
11
+
12
+ ```kotlin
13
+ class Navigator(
14
+ private val navController: NavController,
15
+ private val maxApi: IMaxApi?
16
+ )
17
+ ```
18
+
19
+ ## Methods
20
+
21
+ ### Screen Navigation
22
+
23
+ | Method | Parameters | Description |
24
+ |--------|------------|-------------|
25
+ | `push` | `content: @Composable () -> Unit, options: NavigationOptions? = null` | Push new screen to stack |
26
+ | `replace` | `content: @Composable () -> Unit, options: NavigationOptions? = null` | Replace current screen |
27
+ | `pop` | `count: Int = 1, callBack: (() -> Unit)? = null` | Pop N screens from stack |
28
+ | `present` | `content: @Composable () -> Unit, options: NavigationOptions? = null` | Present as dialog |
29
+ | `reset` | `content: @Composable () -> Unit, options: NavigationOptions? = null` | Reset to new screen (clear stack) |
30
+ | `onBackSafe` | `callBack: (() -> Unit)? = null` | Handle back with optional callback |
31
+
32
+ ### Overlay Components
33
+
34
+ | Method | Parameters | Description |
35
+ |--------|------------|-------------|
36
+ | `showModal` | `content, barrierDismissible = true, onDismiss = null` | Show modal overlay |
37
+ | `showBottomSheet` | `content, isSurface, barrierDismissible, onDismiss, bottomSheetHeader` | Show bottom sheet |
38
+ | `showSnackBar` | `snackBar: SnackBar, onDismiss = null` | Show snackbar notification |
39
+ | `hideSnackBar` | - | Hide current snackbar |
40
+
41
+ ## NavigationOptions
42
+
43
+ ```kotlin
44
+ data class NavigationOptions(
45
+ val headerBackProps: HeaderBackProps? = null,
46
+ val onBackHandler: (() -> Unit)? = null,
47
+ // ... other options
48
+ )
49
+ ```
50
+
51
+ ## Usage
52
+
53
+ ### Get Navigator Instance
54
+
55
+ ```kotlin
56
+ // From NavigationContainer
57
+ NavigationContainer(
58
+ initialScreen = { MyScreen() },
59
+ setNavigator = { navigator = it }
60
+ )
61
+
62
+ // Or use composition local
63
+ val navigator = Navigator.current
64
+ ```
65
+
66
+ ### Push Screen
67
+
68
+ ```kotlin
69
+ // Simple push
70
+ navigator.push { MyScreen() }
71
+
72
+ // With options
73
+ navigator.push(
74
+ content = { DetailScreen(productId) },
75
+ options = NavigationOptions(
76
+ headerBackProps = HeaderBackProps(
77
+ title = "Product Details",
78
+ preventBack = PreventBackConfirm(
79
+ primary = PopupAction(title = "Leave", onPress = { })
80
+ )
81
+ )
82
+ )
83
+ )
84
+ ```
85
+
86
+ ### Replace Screen
87
+
88
+ ```kotlin
89
+ // Replace current screen (pops then pushes)
90
+ navigator.replace { NewScreen() }
91
+ ```
92
+
93
+ ### Pop Screen
94
+
95
+ ```kotlin
96
+ // Pop 1 screen
97
+ navigator.pop()
98
+
99
+ // Pop 2 screens
100
+ navigator.pop(2)
101
+
102
+ // Pop with callback
103
+ navigator.pop(1) {
104
+ // Called after pop completes
105
+ }
106
+ ```
107
+
108
+ ### Present Dialog
109
+
110
+ ```kotlin
111
+ navigator.present {
112
+ DialogContent()
113
+ }
114
+ ```
115
+
116
+ ### Reset Stack
117
+
118
+ ```kotlin
119
+ // Clear all screens and navigate to new screen
120
+ navigator.reset { HomeScreen() }
121
+ ```
122
+
123
+ ### Safe Back Handler
124
+
125
+ ```kotlin
126
+ // Handle back with confirmation if needed
127
+ navigator.onBackSafe {
128
+ // Callback after back completes
129
+ }
130
+ ```
131
+
132
+ ## BottomSheet
133
+
134
+ ```kotlin
135
+ // Simple bottom sheet
136
+ navigator.showBottomSheet(
137
+ content = { MyContent() }
138
+ )
139
+
140
+ // With header
141
+ navigator.showBottomSheet(
142
+ content = { MyContent() },
143
+ bottomSheetHeader = BottomHeader.Title("Select Option")
144
+ )
145
+
146
+ // Surface style (different background)
147
+ navigator.showBottomSheet(
148
+ content = { MyContent() },
149
+ isSurface = true
150
+ )
151
+
152
+ // Not dismissible
153
+ navigator.showBottomSheet(
154
+ content = { MyContent() },
155
+ barrierDismissible = false,
156
+ onDismiss = { /* handle dismiss */ }
157
+ )
158
+ ```
159
+
160
+ ## BottomHeader
161
+
162
+ ```kotlin
163
+ // Title header
164
+ BottomHeader.Title("Title")
165
+
166
+ // Custom header
167
+ BottomHeader.Custom {
168
+ MyHeaderContent()
169
+ }
170
+ ```
171
+
172
+ ## Modal
173
+
174
+ ```kotlin
175
+ // Simple modal
176
+ navigator.showModal(
177
+ content = { MyModalContent() }
178
+ )
179
+
180
+ // Not dismissible
181
+ navigator.showModal(
182
+ content = { MyModalContent() },
183
+ barrierDismissible = false,
184
+ onDismiss = { /* handle dismiss */ }
185
+ )
186
+ ```
187
+
188
+ ## SnackBar
189
+
190
+ ```kotlin
191
+ // Success snackbar
192
+ navigator.showSnackBar(
193
+ snackBar = SnackBar(
194
+ message = "Saved successfully",
195
+ type = SnackBar.Type.SUCCESS
196
+ )
197
+ )
198
+
199
+ // Error snackbar
200
+ navigator.showSnackBar(
201
+ snackBar = SnackBar(
202
+ message = "Something went wrong",
203
+ type = SnackBar.Type.ERROR
204
+ )
205
+ )
206
+
207
+ // Info snackbar
208
+ navigator.showSnackBar(
209
+ snackBar = SnackBar(
210
+ message = "Processing...",
211
+ type = SnackBar.Type.INFO
212
+ )
213
+ )
214
+
215
+ // With action button
216
+ navigator.showSnackBar(
217
+ snackBar = SnackBar(
218
+ message = "Item deleted",
219
+ action = SnackBar.Action(
220
+ title = "UNDO",
221
+ onPress = { /* undo */ }
222
+ )
223
+ )
224
+ )
225
+
226
+ // Hide snackbar
227
+ navigator.hideSnackBar()
228
+ ```
229
+
230
+ ## SnackBar Type
231
+
232
+ | Type | Description |
233
+ |------|-------------|
234
+ | `SUCCESS` | Green color, success messages |
235
+ | `ERROR` | Red color, error messages |
236
+ | `INFO` | Default color, informational |
237
+ | `WARNING` | Warning messages |
238
+
239
+ ## Common Patterns
240
+
241
+ ### Navigate with Result
242
+
243
+ ```kotlin
244
+ // Push screen and handle result
245
+ navigator.push {
246
+ SelectScreen(
247
+ onResult = { selected ->
248
+ // Handle result
249
+ navigator.pop()
250
+ }
251
+ )
252
+ }
253
+ ```
254
+
255
+ ### Confirm Before Back
256
+
257
+ ```kotlin
258
+ navigator.push(
259
+ content = { EditScreen() },
260
+ options = NavigationOptions(
261
+ onBackHandler = {
262
+ showUnsavedChangesDialog()
263
+ },
264
+ headerBackProps = HeaderBackProps(
265
+ preventBack = PreventBackConfirm(
266
+ primary = PopupAction(
267
+ title = "Discard",
268
+ onPress = { navigator.pop() }
269
+ )
270
+ )
271
+ )
272
+ )
273
+ )
274
+ ```
275
+
276
+ ### Nested Navigation
277
+
278
+ ```kotlin
279
+ // Present login as modal
280
+ navigator.present {
281
+ LoginScreen(
282
+ onSuccess = {
283
+ navigator.pop()
284
+ }
285
+ )
286
+ }
287
+ ```
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: pagination-dot
3
+ description: Pagination component showing dots. Use when implementing carousel-style pagination.
4
+ ---
5
+
6
+ # PaginationDot
7
+
8
+ Pagination component showing dots.
9
+
10
+ ## Keywords
11
+
12
+ pagination dots, dot pagination
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun PaginationDot(
19
+ activeIndex: Int = 0,
20
+ dataLength: Int = 3
21
+ )
22
+ ```
23
+
24
+ ## Examples
25
+
26
+ ```kotlin
27
+ PaginationDot(activeIndex = currentPage, dataLength = totalPages)
28
+ ```
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: pagination-number
3
+ description: Pagination component showing page numbers. Use when displaying current page position (e.g., "1/5").
4
+ ---
5
+
6
+ # PaginationNumber
7
+
8
+ Pagination component showing page numbers.
9
+
10
+ ## Keywords
11
+
12
+ pagination, page, trang
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun PaginationNumber(
19
+ activeIndex: Int = 0,
20
+ dataLength: Int = 2
21
+ )
22
+ ```
23
+
24
+ ## Examples
25
+
26
+ ```kotlin
27
+ PaginationNumber(activeIndex = 0, dataLength = 5) // Shows "1/5"
28
+ ```
@@ -0,0 +1,47 @@
1
+ ---
2
+ name: popup-notify
3
+ description: Confirm popup component. Use when showing confirmation dialogs, warnings, or alert popups.
4
+ ---
5
+
6
+ # PopupNotify
7
+
8
+ Confirm popup component.
9
+
10
+ ## Keywords
11
+
12
+ popup, confirm, xác nhận, thông báo
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun PopupNotify(
19
+ title: String = "",
20
+ content: String = "",
21
+ primary: PopupAction? = null,
22
+ secondary: PopupAction? = null,
23
+ type: PopupNotifyType = PopupNotifyType.DEFAULT
24
+ )
25
+
26
+ data class PopupAction(
27
+ val title: String,
28
+ val onPress: (() -> Unit)? = null,
29
+ val type: PopupActionType = PopupActionType.PRIMARY
30
+ )
31
+
32
+ enum class PopupNotifyType { DEFAULT, WARNING, ERROR }
33
+ enum class PopupActionType { PRIMARY, SECONDARY }
34
+ ```
35
+
36
+ ## Examples
37
+
38
+ ```kotlin
39
+ navigator.showModal {
40
+ PopupNotify(
41
+ title = "Confirm",
42
+ content = "Are you sure?",
43
+ primary = PopupAction(title = "Confirm", onClick = { }),
44
+ secondary = PopupAction(title = "Cancel", type = PopupActionType.SECONDARY)
45
+ )
46
+ }
47
+ ```
@@ -0,0 +1,44 @@
1
+ ---
2
+ name: radio
3
+ description: Radio button for single selection from multiple options. Use when user needs to select exactly one option from a list.
4
+ ---
5
+
6
+ # Radio
7
+
8
+ Radio button for single selection from multiple options.
9
+
10
+ ## Keywords
11
+
12
+ radio, radio button, chọn một
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun Radio(
19
+ value: Any,
20
+ groupValue: Any,
21
+ onChange: () -> Unit = {},
22
+ label: String = "",
23
+ disabled: Boolean = false,
24
+ )
25
+ ```
26
+
27
+ ## Examples
28
+
29
+ ```kotlin
30
+ var selected by remember { mutableStateOf("option1") }
31
+
32
+ Radio(
33
+ value = "option1",
34
+ groupValue = selected,
35
+ onChange = { selected = "option1" },
36
+ label = "Option 1"
37
+ )
38
+ Radio(
39
+ value = "option2",
40
+ groupValue = selected,
41
+ onChange = { selected = "option2" },
42
+ label = "Option 2"
43
+ )
44
+ ```
@@ -0,0 +1,32 @@
1
+ ---
2
+ name: skeleton
3
+ description: Loading placeholder with shimmer animation. Use when showing loading state for content.
4
+ ---
5
+
6
+ # Skeleton
7
+
8
+ Loading placeholder with shimmer animation.
9
+
10
+ ## Keywords
11
+
12
+ skeleton, loading, placeholder, shimmer
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun Skeleton()
19
+ ```
20
+
21
+ ## Features
22
+
23
+ - Shimmer animation effect
24
+ - Used as loading placeholder
25
+
26
+ ## Examples
27
+
28
+ ```kotlin
29
+ Box(modifier = Modifier.fillMaxWidth().height(100.dp)) {
30
+ Skeleton()
31
+ }
32
+ ```
@@ -0,0 +1,36 @@
1
+ ---
2
+ name: switch
3
+ description: Toggle switch for on/off states. Use when user needs to toggle a boolean setting or feature.
4
+ ---
5
+
6
+ # Switch
7
+
8
+ Toggle switch for on/off states.
9
+
10
+ ## Keywords
11
+
12
+ switch, toggle, bật tắt, on/off
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun Switch(
19
+ value: Boolean = false,
20
+ onChange: (Boolean) -> Unit = {},
21
+ title: String? = "",
22
+ disabled: Boolean = false,
23
+ )
24
+ ```
25
+
26
+ ## Examples
27
+
28
+ ```kotlin
29
+ var isEnabled by remember { mutableStateOf(false) }
30
+
31
+ Switch(
32
+ value = isEnabled,
33
+ onChange = { isEnabled = it },
34
+ title = "Enable notifications"
35
+ )
36
+ ```
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: tag
3
+ description: Colored label component. Use when displaying status labels, categories, or colored tags.
4
+ ---
5
+
6
+ # Tag
7
+
8
+ Colored label component.
9
+
10
+ ## Keywords
11
+
12
+ tag, label, nhãn, colored label
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun Tag(
19
+ label: String = "Label",
20
+ icon: String? = null,
21
+ color: TagColor = TagColor.Default,
22
+ size: TagSize = TagSize.Large,
23
+ )
24
+
25
+ enum class TagColor { Default, Orange, Green, Red, Blue, Grey }
26
+ enum class TagSize { Large, Medium }
27
+ ```
28
+
29
+ ## Examples
30
+
31
+ ```kotlin
32
+ // Default tag
33
+ Tag(label = "Tag")
34
+
35
+ // Colored tag
36
+ Tag(label = "Hot", color = TagColor.Red)
37
+
38
+ // Tag with icon
39
+ Tag(label = "New", icon = "star", color = TagColor.Blue)
40
+ ```
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: text
3
+ description: Text component for displaying text content. Use when adding text to UI.
4
+ ---
5
+
6
+ # Text
7
+
8
+ Text component for displaying text content.
9
+
10
+ ## Keywords
11
+
12
+ text, văn bản, text content
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun Text(
19
+ text: String,
20
+ color: Color? = null,
21
+ style: TextStyle = Typography.bodyDefaultRegular,
22
+ maxLines: Int = Int.MAX_VALUE,
23
+ overflow: TextOverflow = TextOverflow.Clip,
24
+ modifier: Modifier = Modifier,
25
+ )
26
+ ```
27
+
28
+ ## Examples
29
+
30
+ ```kotlin
31
+ Text(text = "Hello World")
32
+
33
+ Text(
34
+ text = "Title",
35
+ style = Typography.titleDefaultBold
36
+ )
37
+ ```
@@ -0,0 +1,43 @@
1
+ ---
2
+ name: title
3
+ description: Title component for section/card headers. Use when displaying section titles or card headers.
4
+ ---
5
+
6
+ # Title
7
+
8
+ Title component for section/card headers.
9
+
10
+ ## Keywords
11
+
12
+ title, heading, tiêu đề
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun Title(
19
+ title: String,
20
+ type: TitleType = TitleType.Section,
21
+ size: TitleSize = TitleSize.Medium,
22
+ icon: String? = null,
23
+ badgeLabel: String? = null,
24
+ description: String? = null,
25
+ showRightAction: Boolean = false,
26
+ onPressRightAction: () -> Unit = {},
27
+ )
28
+
29
+ enum class TitleType { Section, Card }
30
+ enum class TitleSize { Small, Medium, Large }
31
+ ```
32
+
33
+ ## Examples
34
+
35
+ ```kotlin
36
+ Title(title = "Section Title")
37
+
38
+ Title(
39
+ title = "Title",
40
+ description = "Description",
41
+ badgeLabel = "3"
42
+ )
43
+ ```
@@ -0,0 +1,30 @@
1
+ ---
2
+ name: tooltip
3
+ description: Tooltip component for showing info on hover/click. Use when providing additional information on user interaction.
4
+ ---
5
+
6
+ # Tooltip
7
+
8
+ Tooltip component for showing info on hover/click.
9
+
10
+ ## Keywords
11
+
12
+ tooltip, hover, info, thông tin
13
+
14
+ ## API
15
+
16
+ ```kotlin
17
+ @Composable
18
+ fun Tooltip(
19
+ content: String,
20
+ modifier: Modifier = Modifier,
21
+ )
22
+ ```
23
+
24
+ ## Examples
25
+
26
+ ```kotlin
27
+ Tooltip(content = "Information here") {
28
+ Icon(source = "info", size = 24.dp)
29
+ }
30
+ ```
@@ -0,0 +1,13 @@
1
+ {
2
+ "permissions": {
3
+ "allow": [
4
+ "WebFetch(domain:resources.anthropic.com)",
5
+ "Bash(brew list:*)",
6
+ "Bash(python3 -c \"import pypdf; print\\(''pypdf available''\\)\")",
7
+ "Bash(python3 -c \"import PyPDF2; print\\(''PyPDF2 available''\\)\")",
8
+ "Bash(pip3 install:*)",
9
+ "Bash(python3 -c \"import pypdf; print\\(''pypdf installed''\\)\")",
10
+ "Bash(python3:*)"
11
+ ]
12
+ }
13
+ }