@tencent-rtc/mcp 1.3.9 → 1.4.0
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.
- package/package.json +2 -2
- package/resource/doc/{tuicallkit/iOS/faq.md → callkit/faq/android-faq.md} +10 -22
- package/resource/doc/{tuicallkit/android/faq.md → callkit/faq/flutter-faq.md} +10 -22
- package/resource/doc/{tuicallkit/flutter/faq.md → callkit/faq/ios-faq.md} +10 -22
- package/resource/doc/callkit/preset/android/api.md +296 -0
- package/resource/doc/{tuicallkit → callkit/preset}/android/integration.md +53 -365
- package/resource/doc/callkit/preset/flutter/api.md +410 -0
- package/resource/doc/{tuicallkit → callkit/preset}/flutter/integration.md +35 -97
- package/resource/doc/callkit/preset/ios/api.md +80 -0
- package/resource/doc/{tuicallkit/iOS → callkit/preset/ios}/integration.md +37 -118
- package/resource/doc/callkit/preset/react/api.md +501 -0
- package/resource/doc/{tuicallkit → callkit/preset}/react/integration.md +5 -20
- package/resource/doc/callkit/preset/vue/api.md +501 -0
- package/resource/doc/{tuicallkit → callkit/preset}/vue/integration.md +4 -19
- package/resource/doc/{chatuikit → chatkit}/android/faq.md +29 -38
- package/resource/doc/{chatuikit → chatkit}/android/features/theme.md +22 -166
- package/resource/doc/{chatuikit → chatkit}/android/integration.md +28 -121
- package/resource/doc/chatkit/faq/android_sdk/client-api.md +281 -0
- package/resource/doc/{chatuikit → chatkit}/faq/common/product.md +0 -1
- package/resource/doc/{chatuikit → chatkit}/faq/common/server.md +1 -1
- package/resource/doc/chatkit/faq/flutter_sdk/client-api.md +199 -0
- package/resource/doc/{chatuikit → chatkit}/faq/flutter_sdk/faq.md +3 -3
- package/resource/doc/chatkit/faq/ios_sdk/client-api.md +235 -0
- package/resource/doc/{chatuikit → chatkit}/faq/web_sdk/faq.md +3 -3
- package/resource/doc/{chatuikit → chatkit}/flutter/features/theme.md +22 -166
- package/resource/doc/{chatuikit → chatkit}/flutter/integration.md +18 -87
- package/resource/doc/{chatuikit/iOS → chatkit/ios}/faq.md +29 -38
- package/resource/doc/{chatuikit/iOS → chatkit/ios}/features/theme.md +27 -176
- package/resource/doc/{chatuikit/iOS → chatkit/ios}/integration.md +47 -165
- package/resource/doc/{chatuikit → chatkit}/react/components/avatar.md +0 -33
- package/resource/doc/{chatuikit → chatkit}/react/components/chat-header.md +8 -49
- package/resource/doc/{chatuikit → chatkit}/react/components/chat-setting.md +6 -35
- package/resource/doc/{chatuikit → chatkit}/react/components/chat.md +0 -6
- package/resource/doc/{chatuikit → chatkit}/react/components/component-list.md +0 -11
- package/resource/doc/{chatuikit → chatkit}/react/components/contact-list.md +96 -502
- package/resource/doc/chatkit/react/components/conversation-actions.md +174 -0
- package/resource/doc/chatkit/react/components/conversation-list.md +333 -0
- package/resource/doc/chatkit/react/components/conversation-preview.md +118 -0
- package/resource/doc/chatkit/react/components/conversation-search.md +60 -0
- package/resource/doc/{chatuikit → chatkit}/react/components/message-input.md +36 -337
- package/resource/doc/{chatuikit → chatkit}/react/components/message-list.md +20 -212
- package/resource/doc/chatkit/react/components/search.md +243 -0
- package/resource/doc/{chatuikit → chatkit}/react/components/tuikit.md +1 -47
- package/resource/doc/{chatuikit → chatkit}/react/integration.md +21 -81
- package/resource/doc/{chatuikit → chatkit}/vue/components/avatar.md +0 -33
- package/resource/doc/{chatuikit → chatkit}/vue/components/chat-header.md +7 -48
- package/resource/doc/{chatuikit → chatkit}/vue/components/chat-setting.md +3 -5
- package/resource/doc/{chatuikit → chatkit}/vue/components/chat.md +0 -5
- package/resource/doc/{chatuikit → chatkit}/vue/components/component-list.md +0 -15
- package/resource/doc/chatkit/vue/components/contact-list.md +271 -0
- package/resource/doc/chatkit/vue/components/conversation-actions.md +228 -0
- package/resource/doc/{chatuikit → chatkit}/vue/components/conversation-list.md +42 -492
- package/resource/doc/chatkit/vue/components/conversation-preview.md +213 -0
- package/resource/doc/chatkit/vue/components/conversation-search.md +50 -0
- package/resource/doc/{chatuikit → chatkit}/vue/components/message-input.md +2 -223
- package/resource/doc/{chatuikit → chatkit}/vue/components/message-list.md +23 -252
- package/resource/doc/{chatuikit → chatkit}/vue/components/search.md +73 -640
- package/resource/doc/{chatuikit → chatkit}/vue/components/tuikit.md +7 -21
- package/resource/doc/{chatuikit → chatkit}/vue/components/userpicker.md +3 -62
- package/resource/doc/{chatuikit → chatkit}/vue/faq.md +1 -1
- package/resource/doc/{chatuikit → chatkit}/vue/integration.md +22 -23
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-audience-list.md +18 -89
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-audio-effect.md +34 -192
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-barrage.md +28 -141
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-base-beauty.md +20 -112
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-co-guest-interaction.md +59 -193
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-gift.md +75 -455
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-host-interaction.md +94 -344
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-integration.md +107 -515
- package/resource/doc/livekit/{live → core-sdk/live}/android/live-live-list.md +33 -173
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-audience-list.md +14 -93
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-audio-effect.md +34 -179
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-barrage.md +19 -107
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-base-beauty.md +24 -166
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-co-guest-interaction.md +56 -163
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-gift.md +69 -443
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-host-interaction.md +117 -364
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-integration.md +107 -492
- package/resource/doc/livekit/{live → core-sdk/live}/flutter/live-live-list.md +23 -165
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-audience-list.md +35 -111
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-audio-effect.md +35 -193
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-barrage.md +31 -144
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-base-beauty.md +24 -116
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-co-guest-interaction.md +37 -171
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-gift.md +79 -459
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-host-interaction.md +69 -320
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-integration.md +85 -502
- package/resource/doc/livekit/{live → core-sdk/live}/ios/live-live-list.md +32 -169
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-audience-list.md +18 -89
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-audio-effect.md +34 -192
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-barrage.md +28 -141
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-co-guest-interaction.md +50 -259
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-gift.md +75 -455
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-host-interaction.md +51 -265
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-integration.md +61 -427
- package/resource/doc/livekit/{voice → core-sdk/voice}/android/voice-room-list.md +33 -173
- package/resource/doc/livekit/{voice → core-sdk/voice}/flutter/voice-co-guest-interaction.md +44 -203
- package/resource/doc/livekit/{voice → core-sdk/voice}/flutter/voice-integration.md +56 -416
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-audience-list.md +35 -111
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-audio-effect.md +35 -193
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-barrage.md +31 -144
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-co-guest-interaction.md +43 -252
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-gift.md +79 -459
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-host-interaction.md +46 -264
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-integration.md +61 -445
- package/resource/doc/livekit/{voice → core-sdk/voice}/ios/voice-room-list.md +32 -169
- package/resource/doc/livekit/faq/common/{error_code.md → error-code.md} +2 -2
- package/resource/doc/livekit/preset/live/vue/api-reference/index.md +780 -0
- package/resource/doc/livekit/preset/live/vue/components/barrage.md +291 -0
- package/resource/doc/livekit/{live → preset/live}/vue/components/co-guest-panel.md +10 -49
- package/resource/doc/livekit/{live → preset/live}/vue/components/live-audience-list.md +26 -144
- package/resource/doc/livekit/{live → preset/live}/vue/components/live-scene-panel.md +12 -75
- package/resource/doc/livekit/{live → preset/live}/vue/components/live-view.md +36 -227
- package/resource/doc/livekit/preset/live/vue/components/stream-mixer.md +215 -0
- package/resource/doc/livekit/preset/live/vue/faq.md +1 -0
- package/resource/doc/livekit/preset/live/vue/live-list-integration.md +241 -0
- package/resource/doc/livekit/preset/live/vue/live-player-desk-integration.md +299 -0
- package/resource/doc/livekit/preset/live/vue/live-player-h5-integration.md +300 -0
- package/resource/doc/livekit/preset/live/vue/live-pusher-integration.md +743 -0
- package/resource/doc/roomkit/vue/faq.md +1 -0
- package/resource/doc/roomkit/vue/features/call-user-to-room.md +17 -53
- package/resource/doc/roomkit/vue/features/device-detection.md +30 -48
- package/resource/doc/roomkit/vue/features/device-state.md +24 -44
- package/resource/doc/roomkit/vue/features/free-beauty-panel.md +13 -36
- package/resource/doc/roomkit/vue/features/room-chat.md +31 -89
- package/resource/doc/roomkit/vue/features/room-participant-state.md +28 -50
- package/resource/doc/roomkit/vue/features/room-state.md +25 -34
- package/resource/doc/roomkit/vue/features/room-view.md +30 -125
- package/resource/doc/roomkit/vue/features/schedule-room.md +9 -40
- package/resource/doc/roomkit/vue/features/screen-share.md +22 -90
- package/resource/doc/roomkit/vue/features/virtual-background.md +13 -29
- package/resource/doc/roomkit/vue/integration.md +21 -76
- package/resource/doc/rtcengine/faq/common/error_code.md +1 -0
- package/resource/doc/rtcengine/faq/web/web.md +14 -24
- package/resource/doc/rtcengine/web/api.md +1 -3
- package/resource/doc/rtcengine/web/how_to_integrated_web_sdk.md +3 -10
- package/resource/doc/rtcengine/web/how_to_run_web_sdk_demo.md +1 -5
- package/resource/doc/rtcengine/web/plugin/20-advanced-customized-capture-rendering.md +1 -2
- package/resource/doc/rtcengine/web/plugin/21-advanced-auto-play-policy.md +2 -4
- package/resource/doc/rtcengine/web/plugin/23-advanced-support-detection.md +3 -5
- package/resource/doc/rtcengine/web/plugin/24-advanced-network-quality.md +1 -7
- package/resource/doc/rtcengine/web/plugin/25-advanced-device-change.md +0 -2
- package/resource/doc/rtcengine/web/plugin/26-advanced-publish-cdn-stream.md +4 -8
- package/resource/doc/rtcengine/web/plugin/27-advanced-small-stream.md +11 -11
- package/resource/doc/rtcengine/web/plugin/28-advanced-beauty.md +12 -88
- package/resource/doc/rtcengine/web/plugin/31-advanced-plugins-overview.md +5 -5
- package/resource/doc/rtcengine/web/plugin/34-advanced-proxy.md +30 -37
- package/resource/doc/rtcengine/web/plugin/36-advanced-virtual-background.md +13 -90
- package/resource/doc/rtcengine/web/plugin/37-advanced-voice-changer.md +1 -2
- package/resource/doc/rtcengine/web/plugin/39-advanced-video-decoder.md +1 -2
- package/resource/doc/rtcengine/web/plugin/40-advanced-video-mixer.md +19 -19
- package/resource/doc/rtcengine/web/plugin/41-advanced-small-stream-auto-switcher.md +1 -1
- package/resource/doc/rtcengine/web/plugin/42-advanced-realtime-transcriber.md +4 -5
- package/resource/doc/rtcengine/web/plugin/43-advanced-face-detection.md +3 -3
- package/resource/doc/trtc/C++/ITRTCCloud.md +686 -2835
- package/resource/doc/trtc/C++/ITRTCStatistics.md +53 -308
- package/resource/doc/trtc/C++/ITXAudioEffectManager.md +202 -1022
- package/resource/doc/trtc/C++/ITXDeviceManager.md +126 -767
- package/resource/doc/trtc/C++/TRTCCloudCallback.md +579 -2147
- package/resource/doc/trtc/C++/TRTCTypeDef.md +703 -3378
- package/resource/doc/trtc/C++/TXLiteAVCode.md +116 -908
- package/resource/doc/trtc/android/TRTCCloud.md +606 -2573
- package/resource/doc/trtc/android/TRTCCloudDef.md +752 -3640
- package/resource/doc/trtc/android/TRTCCloudListener.md +581 -2008
- package/resource/doc/trtc/android/TRTCStatistics.md +48 -278
- package/resource/doc/trtc/android/TXAudioEffectManager.md +202 -1022
- package/resource/doc/trtc/android/TXBeautyManager.md +127 -704
- package/resource/doc/trtc/android/TXDeviceManager.md +51 -318
- package/resource/doc/trtc/android/TXLiteAVCode.md +114 -892
- package/resource/doc/trtc/iOS/TRTCCloud.md +694 -2904
- package/resource/doc/trtc/iOS/TRTCCloudDef.md +726 -3498
- package/resource/doc/trtc/iOS/TRTCCloudDelegate.md +543 -2028
- package/resource/doc/trtc/iOS/TRTCStatistics.md +48 -278
- package/resource/doc/trtc/iOS/TXAudioEffectManager.md +174 -877
- package/resource/doc/trtc/iOS/TXBeautyManager.md +128 -710
- package/resource/doc/trtc/iOS/TXDeviceManager.md +129 -772
- package/resource/doc/trtc/iOS/TXLiteAVCode.md +117 -915
- package/server.js +1 -5
- package/server.js.map +1 -1
- package/tools/call/get_callkit_api.js +32 -0
- package/tools/call/get_callkit_api.js.map +1 -0
- package/tools/call/get_native_call_uikit_integration.js +34 -0
- package/tools/call/get_native_call_uikit_integration.js.map +1 -0
- package/tools/call/{get-web-call-integration.js → get_web_call_uikit_integration.js} +13 -8
- package/tools/call/get_web_call_uikit_integration.js.map +1 -0
- package/tools/chat/get_native_chat_uikit_feature_detail.js +34 -0
- package/tools/chat/get_native_chat_uikit_feature_detail.js.map +1 -0
- package/tools/chat/get_native_chat_uikit_integration.js +45 -0
- package/tools/chat/get_native_chat_uikit_integration.js.map +1 -0
- package/tools/chat/get_web_chat_uikit_component_detail.js +34 -0
- package/tools/chat/get_web_chat_uikit_component_detail.js.map +1 -0
- package/tools/chat/get_web_chat_uikit_integration.js +45 -0
- package/tools/chat/get_web_chat_uikit_integration.js.map +1 -0
- package/tools/common/get_faq.js +265 -0
- package/tools/common/get_faq.js.map +1 -0
- package/tools/common/{get-usersig.js → get_usersig.js} +6 -3
- package/tools/common/get_usersig.js.map +1 -0
- package/tools/common/present_framework_choice.js +63 -0
- package/tools/common/present_framework_choice.js.map +1 -0
- package/tools/definitions/get_callkit_api_def.js +29 -0
- package/tools/definitions/get_callkit_api_def.js.map +1 -0
- package/tools/definitions/get_faq_def.js +17 -18
- package/tools/definitions/get_faq_def.js.map +1 -1
- package/tools/definitions/get_native_call_uikit_integration_def.js +15 -34
- package/tools/definitions/get_native_call_uikit_integration_def.js.map +1 -1
- package/tools/definitions/get_native_chat_uikit_feature_detail_def.js +31 -0
- package/tools/definitions/get_native_chat_uikit_feature_detail_def.js.map +1 -0
- package/tools/definitions/get_native_chat_uikit_integration_def.js +16 -41
- package/tools/definitions/get_native_chat_uikit_integration_def.js.map +1 -1
- package/tools/definitions/get_native_livekit_core_features_def.js +34 -0
- package/tools/definitions/get_native_livekit_core_features_def.js.map +1 -0
- package/tools/definitions/get_native_livekit_core_integration_def.js +34 -0
- package/tools/definitions/get_native_livekit_core_integration_def.js.map +1 -0
- package/tools/definitions/get_native_trtc_sdk_docs_def.js +32 -0
- package/tools/definitions/get_native_trtc_sdk_docs_def.js.map +1 -0
- package/tools/definitions/get_usersig_def.js +17 -22
- package/tools/definitions/get_usersig_def.js.map +1 -1
- package/tools/definitions/get_web_call_uikit_integration_def.js +15 -7
- package/tools/definitions/get_web_call_uikit_integration_def.js.map +1 -1
- package/tools/definitions/get_web_chat_uikit_component_detail_def.js +17 -49
- package/tools/definitions/get_web_chat_uikit_component_detail_def.js.map +1 -1
- package/tools/definitions/get_web_chat_uikit_integration_def.js +16 -19
- package/tools/definitions/get_web_chat_uikit_integration_def.js.map +1 -1
- package/tools/definitions/get_web_live_uikit_integration_def.js +15 -18
- package/tools/definitions/get_web_live_uikit_integration_def.js.map +1 -1
- package/tools/definitions/get_web_livekit_api_def.js +30 -0
- package/tools/definitions/get_web_livekit_api_def.js.map +1 -0
- package/tools/definitions/get_web_livekit_component_detail_def.js +32 -0
- package/tools/definitions/get_web_livekit_component_detail_def.js.map +1 -0
- package/tools/definitions/get_web_room_uikit_integration_def.js +15 -46
- package/tools/definitions/get_web_room_uikit_integration_def.js.map +1 -1
- package/tools/definitions/get_web_roomkit_feature_detail_def.js +31 -0
- package/tools/definitions/get_web_roomkit_feature_detail_def.js.map +1 -0
- package/tools/definitions/get_web_trtc_sdk_api_def.js +27 -0
- package/tools/definitions/get_web_trtc_sdk_api_def.js.map +1 -0
- package/tools/definitions/get_web_trtc_sdk_integration_def.js +27 -0
- package/tools/definitions/get_web_trtc_sdk_integration_def.js.map +1 -0
- package/tools/definitions/get_web_trtc_sdk_plugin_def.js +27 -0
- package/tools/definitions/get_web_trtc_sdk_plugin_def.js.map +1 -0
- package/tools/definitions/present_framework_choice_def.js +24 -12
- package/tools/definitions/present_framework_choice_def.js.map +1 -1
- package/tools/index.js +47 -61
- package/tools/index.js.map +1 -1
- package/tools/live/get_native_livekit_core_features.js +65 -0
- package/tools/live/get_native_livekit_core_features.js.map +1 -0
- package/tools/live/get_native_livekit_core_integration.js +59 -0
- package/tools/live/get_native_livekit_core_integration.js.map +1 -0
- package/tools/live/get_web_live_uikit_integration.js +48 -0
- package/tools/live/get_web_live_uikit_integration.js.map +1 -0
- package/tools/live/get_web_livekit_api.js +32 -0
- package/tools/live/get_web_livekit_api.js.map +1 -0
- package/tools/live/get_web_livekit_component_detail.js +34 -0
- package/tools/live/get_web_livekit_component_detail.js.map +1 -0
- package/tools/room/{get-web-room-integration.js → get_web_room_uikit_integration.js} +13 -14
- package/tools/room/get_web_room_uikit_integration.js.map +1 -0
- package/tools/room/{get-web-room-feature-detail.js → get_web_roomkit_feature_detail.js} +30 -31
- package/tools/room/get_web_roomkit_feature_detail.js.map +1 -0
- package/tools/rtcengine/get_web_trtc_sdk_api.js +31 -0
- package/tools/rtcengine/get_web_trtc_sdk_api.js.map +1 -0
- package/tools/rtcengine/get_web_trtc_sdk_integration.js +31 -0
- package/tools/rtcengine/get_web_trtc_sdk_integration.js.map +1 -0
- package/tools/rtcengine/get_web_trtc_sdk_plugin.js +31 -0
- package/tools/rtcengine/get_web_trtc_sdk_plugin.js.map +1 -0
- package/tools/trtc/get_native_trtc_sdk_docs.js +73 -0
- package/tools/trtc/get_native_trtc_sdk_docs.js.map +1 -0
- package/utils/generate-structured-result.js +61 -17
- package/utils/generate-structured-result.js.map +1 -1
- package/utils/report-cls-client.js +12 -1
- package/utils/report-cls-client.js.map +1 -1
- package/utils/report-es-client.js +2 -2
- package/resource/doc/chatuikit/android/workflow.md +0 -713
- package/resource/doc/chatuikit/faq/android_sdk/client-api.md +0 -1371
- package/resource/doc/chatuikit/faq/flutter_sdk/client-api.md +0 -932
- package/resource/doc/chatuikit/faq/ios_sdk/client-api.md +0 -1119
- package/resource/doc/chatuikit/flutter/workflow.md +0 -941
- package/resource/doc/chatuikit/react/components/conversation-list.md +0 -1017
- package/resource/doc/chatuikit/react/components/search.md +0 -745
- package/resource/doc/chatuikit/react/create-group.md +0 -23
- package/resource/doc/chatuikit/react/init.md +0 -26
- package/resource/doc/chatuikit/react/workflow.md +0 -258
- package/resource/doc/chatuikit/vue/components/contact-list.md +0 -679
- package/resource/doc/chatuikit/vue/create-group.md +0 -25
- package/resource/doc/chatuikit/vue/init.md +0 -40
- package/resource/doc/chatuikit/vue/workflow.md +0 -395
- package/resource/doc/livekit/live/android/workflow.md +0 -320
- package/resource/doc/livekit/live/flutter/workflow.md +0 -353
- package/resource/doc/livekit/live/ios/workflow.md +0 -454
- package/resource/doc/livekit/live/vue/components/barrage.md +0 -616
- package/resource/doc/livekit/live/vue/components/stream-mixer.md +0 -446
- package/resource/doc/livekit/live/vue/faq.md +0 -0
- package/resource/doc/livekit/live/vue/live-list-integration.md +0 -200
- package/resource/doc/livekit/live/vue/live-player-desk-integration.md +0 -269
- package/resource/doc/livekit/live/vue/live-player-h5-integration.md +0 -269
- package/resource/doc/livekit/live/vue/live-pusher-integration.md +0 -595
- package/resource/doc/livekit/live/vue/states/live-state.md +0 -3591
- package/resource/doc/livekit/live/vue/workflow.md +0 -218
- package/resource/doc/native_live/android/V2TXLiveCode_api_android.md +0 -312
- package/resource/doc/native_live/android/V2TXLiveDef_api_android.md +0 -430
- package/resource/doc/native_live/android/V2TXLivePlayerObserver_api_android.md +0 -679
- package/resource/doc/native_live/android/V2TXLivePlayer_api_android.md +0 -671
- package/resource/doc/native_live/android/V2TXLivePremier_api_android.md +0 -271
- package/resource/doc/native_live/android/V2TXLivePusherObserver_api_android.md +0 -849
- package/resource/doc/native_live/android/V2TXLivePusher_api_android.md +0 -1046
- package/resource/doc/native_live/flutter/V2TXLiveCode_api_flutter.md +0 -460
- package/resource/doc/native_live/flutter/V2TXLiveDef_api_flutter.md +0 -558
- package/resource/doc/native_live/flutter/V2TXLivePlayerObserver_api_flutter.md +0 -865
- package/resource/doc/native_live/flutter/V2TXLivePlayer_api_flutter.md +0 -657
- package/resource/doc/native_live/flutter/V2TXLivePremier_api_flutter.md +0 -437
- package/resource/doc/native_live/flutter/V2TXLivePusherObserver_api_flutter.md +0 -335
- package/resource/doc/native_live/flutter/V2TXLivePusher_api_flutter.md +0 -748
- package/resource/doc/native_live/iOS/V2TXLiveCode_api_iOS.md +0 -327
- package/resource/doc/native_live/iOS/V2TXLiveDef_api_iOS.md +0 -507
- package/resource/doc/native_live/iOS/V2TXLivePlayerObserver_api_iOS.md +0 -507
- package/resource/doc/native_live/iOS/V2TXLivePlayer_api_iOS.md +0 -659
- package/resource/doc/native_live/iOS/V2TXLivePremier_api_iOS.md +0 -284
- package/resource/doc/native_live/iOS/V2TXLivePusherObserver_api_iOS.md +0 -814
- package/resource/doc/native_live/iOS/V2TXLivePusher_api_iOS.md +0 -1000
- package/resource/doc/roomkit/vue/features/workflow.md +0 -553
- package/resource/doc/roomkit/vue/workflow.md +0 -733
- package/resource/doc/tuicallkit/android/workflow.md +0 -441
- package/resource/doc/tuicallkit/faq/android_sdk/call-observer-api.md +0 -784
- package/resource/doc/tuicallkit/faq/android_sdk/callkit-api.md +0 -610
- package/resource/doc/tuicallkit/faq/flutter_sdk/call-define-api.md +0 -938
- package/resource/doc/tuicallkit/faq/flutter_sdk/call-observer-api.md +0 -897
- package/resource/doc/tuicallkit/faq/flutter_sdk/callkit-api.md +0 -469
- package/resource/doc/tuicallkit/faq/ios_sdk/call-observer-api.md +0 -781
- package/resource/doc/tuicallkit/faq/ios_sdk/callkit-api.md +0 -398
- package/resource/doc/tuicallkit/flutter/workflow.md +0 -331
- package/resource/doc/tuicallkit/react/api.md +0 -1404
- package/resource/doc/tuicallkit/vue/api.md +0 -1406
- package/resource/doc/tuicallkit/vue/faq.md +0 -36
- package/tools/call/get-native-call-integration.js +0 -43
- package/tools/call/get-native-call-integration.js.map +0 -1
- package/tools/call/get-web-call-api.js +0 -27
- package/tools/call/get-web-call-api.js.map +0 -1
- package/tools/call/get-web-call-integration.js.map +0 -1
- package/tools/chat/get-native-chat-feature-detail.js +0 -30
- package/tools/chat/get-native-chat-feature-detail.js.map +0 -1
- package/tools/chat/get-native-chat-integration.js +0 -45
- package/tools/chat/get-native-chat-integration.js.map +0 -1
- package/tools/chat/get-web-chat-component-detail.js +0 -31
- package/tools/chat/get-web-chat-component-detail.js.map +0 -1
- package/tools/chat/get-web-chat-integration.js +0 -45
- package/tools/chat/get-web-chat-integration.js.map +0 -1
- package/tools/chat/get-web-chat-uikit-init.js +0 -28
- package/tools/chat/get-web-chat-uikit-init.js.map +0 -1
- package/tools/chat/get-web-create-group-doc.js +0 -28
- package/tools/chat/get-web-create-group-doc.js.map +0 -1
- package/tools/common/get-faq.js +0 -91
- package/tools/common/get-faq.js.map +0 -1
- package/tools/common/get-usersig.js.map +0 -1
- package/tools/common/present-framework-choice.js +0 -16
- package/tools/common/present-framework-choice.js.map +0 -1
- package/tools/common/present-scenario-choice.js +0 -16
- package/tools/common/present-scenario-choice.js.map +0 -1
- package/tools/common/record-prompt.js +0 -55
- package/tools/common/record-prompt.js.map +0 -1
- package/tools/common/record-result.js +0 -60
- package/tools/common/record-result.js.map +0 -1
- package/tools/definitions/get_native_chat_feature_detail_def.js +0 -32
- package/tools/definitions/get_native_chat_feature_detail_def.js.map +0 -1
- package/tools/definitions/get_native_live_api_def.js +0 -23
- package/tools/definitions/get_native_live_api_def.js.map +0 -1
- package/tools/definitions/get_native_live_uikit_extra_features_def.js +0 -87
- package/tools/definitions/get_native_live_uikit_extra_features_def.js.map +0 -1
- package/tools/definitions/get_native_live_uikit_integration_def.js +0 -75
- package/tools/definitions/get_native_live_uikit_integration_def.js.map +0 -1
- package/tools/definitions/get_native_live_uikit_interaction_def.js +0 -63
- package/tools/definitions/get_native_live_uikit_interaction_def.js.map +0 -1
- package/tools/definitions/get_trtc_native_api_def.js +0 -16
- package/tools/definitions/get_trtc_native_api_def.js.map +0 -1
- package/tools/definitions/get_web_call_uikit_api_def.js +0 -23
- package/tools/definitions/get_web_call_uikit_api_def.js.map +0 -1
- package/tools/definitions/get_web_chat_uikit_init_def.js +0 -23
- package/tools/definitions/get_web_chat_uikit_init_def.js.map +0 -1
- package/tools/definitions/get_web_create_group_doc_def.js +0 -18
- package/tools/definitions/get_web_create_group_doc_def.js.map +0 -1
- package/tools/definitions/get_web_live_state_detail_def.js +0 -19
- package/tools/definitions/get_web_live_state_detail_def.js.map +0 -1
- package/tools/definitions/get_web_live_uikit_component_detail_def.js +0 -27
- package/tools/definitions/get_web_live_uikit_component_detail_def.js.map +0 -1
- package/tools/definitions/get_web_room_feature_detail_def.js +0 -92
- package/tools/definitions/get_web_room_feature_detail_def.js.map +0 -1
- package/tools/definitions/get_web_room_state_detail_def.js +0 -19
- package/tools/definitions/get_web_room_state_detail_def.js.map +0 -1
- package/tools/definitions/present_scenario_choice_def.js +0 -53
- package/tools/definitions/present_scenario_choice_def.js.map +0 -1
- package/tools/definitions/record_prompt_def.js +0 -58
- package/tools/definitions/record_prompt_def.js.map +0 -1
- package/tools/definitions/record_result_def.js +0 -46
- package/tools/definitions/record_result_def.js.map +0 -1
- package/tools/live/get-native-live-uikit-integration.js +0 -177
- package/tools/live/get-native-live-uikit-integration.js.map +0 -1
- package/tools/live/get-web-live-component-detail.js +0 -31
- package/tools/live/get-web-live-component-detail.js.map +0 -1
- package/tools/live/get-web-live-state-detail.js +0 -31
- package/tools/live/get-web-live-state-detail.js.map +0 -1
- package/tools/live/get-web-live-uikit-integration.js +0 -52
- package/tools/live/get-web-live-uikit-integration.js.map +0 -1
- package/tools/live/get_native_live_uikit_extra_features.js +0 -105
- package/tools/live/get_native_live_uikit_extra_features.js.map +0 -1
- package/tools/live/get_native_live_uikit_interaction.js +0 -194
- package/tools/live/get_native_live_uikit_interaction.js.map +0 -1
- package/tools/native_live/get-native-live-api.js +0 -31
- package/tools/native_live/get-native-live-api.js.map +0 -1
- package/tools/room/get-web-room-feature-detail.js.map +0 -1
- package/tools/room/get-web-room-integration.js.map +0 -1
- package/tools/rtcengine/get-rtcengine-web-sdk-integration.js +0 -28
- package/tools/rtcengine/get-rtcengine-web-sdk-integration.js.map +0 -1
- package/tools/rtcengine/get-trtc-sdk-faq.js +0 -32
- package/tools/rtcengine/get-trtc-sdk-faq.js.map +0 -1
- package/tools/rtcengine/get-trtc-web-sdk-api.js +0 -28
- package/tools/rtcengine/get-trtc-web-sdk-api.js.map +0 -1
- package/tools/rtcengine/get-trtc-web-sdk-faq.js +0 -30
- package/tools/rtcengine/get-trtc-web-sdk-faq.js.map +0 -1
- package/tools/rtcengine/get-trtc-web-sdk-integration.js +0 -29
- package/tools/rtcengine/get-trtc-web-sdk-integration.js.map +0 -1
- package/tools/rtcengine/get-trtc-web-sdk-plugin.js +0 -45
- package/tools/rtcengine/get-trtc-web-sdk-plugin.js.map +0 -1
- package/tools/trtc/get-trtc-native-api.js +0 -31
- package/tools/trtc/get-trtc-native-api.js.map +0 -1
- package/utils/handle-component-name.js +0 -33
- package/utils/handle-component-name.js.map +0 -1
- /package/resource/doc/{chatuikit/iOS/workflow.md → callkit/core-sdk/.gitkeep} +0 -0
- /package/resource/doc/{tuicallkit/faq/common/error_code.md → callkit/faq/common/error-code.md} +0 -0
- /package/resource/doc/{tuicallkit/react/faq.md → callkit/faq/web-faq.md} +0 -0
- /package/resource/doc/{chatuikit → chatkit}/faq/common/server_error_code.md +0 -0
- /package/resource/doc/{chatuikit → chatkit}/faq/web_sdk/error_code.md +0 -0
- /package/resource/doc/{chatuikit → chatkit}/flutter/faq.md +0 -0
- /package/resource/doc/{chatuikit → chatkit}/react/faq.md +0 -0
- /package/resource/doc/roomkit/faq/common/{error_code.md → error-code.md} +0 -0
|
@@ -1,941 +0,0 @@
|
|
|
1
|
-
# Flutter TUIKit Chat Application Code Generation Workflow Instructions
|
|
2
|
-
|
|
3
|
-
## 📋 Purpose of Instructions
|
|
4
|
-
|
|
5
|
-
Provide Agents with a **code generation blueprint for implementing Flutter TUIKit Chat core features**, and guide Agents to **prioritize using the latest documentation content obtained in real-time through tools**, specifically for Flutter instant messaging chat application scenarios.
|
|
6
|
-
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
## 🛑 Agent Execution Hard Constraints (Guardrails)
|
|
10
|
-
|
|
11
|
-
Agents must strictly follow these instructions when generating code:
|
|
12
|
-
|
|
13
|
-
### 0. 🚨 Core Page Code Source (Highest Priority)
|
|
14
|
-
**This is the constraint most easily violated and must be emphasized first!**
|
|
15
|
-
|
|
16
|
-
**Absolutely Prohibited Behaviors**:
|
|
17
|
-
- ❌ **Strictly prohibited from writing any core page code yourself** (ConversationsPage, ChatPage, ContactsPage)
|
|
18
|
-
- ❌ **Strictly prohibited from simplified implementations**, such as "simplified version" pages with only a few dozen lines of code
|
|
19
|
-
- ❌ **Strictly prohibited from skipping page code generation**, directly asking users to "refer to official examples"
|
|
20
|
-
|
|
21
|
-
**Mandatory Execution Requirements**:
|
|
22
|
-
- ✅ **Must directly use the following official page files**:
|
|
23
|
-
- `TUIKit_Flutter/chat/uikit/lib/conversations_page.dart`
|
|
24
|
-
- `TUIKit_Flutter/chat/uikit/lib/chat_page.dart`
|
|
25
|
-
- `TUIKit_Flutter/chat/uikit/lib/contacts_page.dart`
|
|
26
|
-
- ✅ **Must completely copy the above files from the `TUIKit_Flutter/chat/uikit/lib/` directory**
|
|
27
|
-
- ✅ **Must include complete State classes, UI component trees, business logic**
|
|
28
|
-
- ✅ **Must copy all dependent components and utility classes**, keeping the file structure intact
|
|
29
|
-
|
|
30
|
-
**Verification Standard**: Generated core page code should match official source code and be fully functional
|
|
31
|
-
|
|
32
|
-
### 1. Documentation-Driven Integration
|
|
33
|
-
- Must strictly follow the steps in `llm_code_generation_instructions_md` from the tool return results
|
|
34
|
-
- **Must strictly generate code according to the sample code in the integration documentation**, do not modify code structure and implementation methods without authorization
|
|
35
|
-
- Code generation should fully follow the best practices and examples provided in the integration documentation to ensure code correctness and runnability
|
|
36
|
-
|
|
37
|
-
### 2. Source Code Integration Method
|
|
38
|
-
- TUIKit Flutter adopts **source code integration method**, requiring cloning from GitHub and copying core source code files
|
|
39
|
-
- **Must clone the source code to the root directory of the user's project** (i.e., `project_root/TUIKit_Flutter/`)
|
|
40
|
-
- Must follow the integration documentation guidance to copy the specified source code folders (`atomic-x`, `chat/uikit`) into the user's project
|
|
41
|
-
- When copying, must ensure merging with existing folders in the user's project, avoid direct overwriting
|
|
42
|
-
|
|
43
|
-
### 3. Silent Integration Execution
|
|
44
|
-
- After all code is written, automatically install dependencies and start the project in the final step
|
|
45
|
-
- **Flutter Command Execution Strategy (Multi-level Fallback, Ensure Success)**:
|
|
46
|
-
1. **First Priority**: Try to execute `flutter pub get` directly
|
|
47
|
-
2. **Second Priority**: If it fails, use `which flutter` to get the full path and execute
|
|
48
|
-
3. **Third Priority**: If it still fails, try common paths:
|
|
49
|
-
- macOS/Linux: `$HOME/flutter/bin/flutter`
|
|
50
|
-
- macOS (Homebrew): `/opt/homebrew/bin/flutter`
|
|
51
|
-
4. **Final Fallback**: If all fail, **guide users to execute manually** (see guidance below)
|
|
52
|
-
- After successful startup, prompt users to run the application on simulator or real device
|
|
53
|
-
|
|
54
|
-
#### 📋 Manual Dependency Installation Guidance
|
|
55
|
-
|
|
56
|
-
**When automatic execution of `flutter pub get` fails, please guide users to follow these steps**:
|
|
57
|
-
|
|
58
|
-
**Step 1: Open terminal and navigate to project directory**
|
|
59
|
-
```bash
|
|
60
|
-
cd /path/to/your/project # Replace with actual project path
|
|
61
|
-
```
|
|
62
|
-
|
|
63
|
-
**Step 2: Manually install Flutter dependencies**
|
|
64
|
-
```bash
|
|
65
|
-
flutter pub get
|
|
66
|
-
```
|
|
67
|
-
|
|
68
|
-
**Step 3: (iOS Project) Install CocoaPods dependencies**
|
|
69
|
-
```bash
|
|
70
|
-
cd ios
|
|
71
|
-
pod install
|
|
72
|
-
cd ..
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
**Step 4: Verify dependency installation**
|
|
76
|
-
```bash
|
|
77
|
-
flutter doctor -v # Check Flutter environment
|
|
78
|
-
flutter pub deps # View dependency tree
|
|
79
|
-
```
|
|
80
|
-
|
|
81
|
-
**Step 5: Start project**
|
|
82
|
-
```bash
|
|
83
|
-
# Method 1: Use simulator/real device
|
|
84
|
-
flutter run
|
|
85
|
-
|
|
86
|
-
# Method 2: Specify device
|
|
87
|
-
flutter devices # List available devices
|
|
88
|
-
flutter run -d <device-id> # Run on specified device
|
|
89
|
-
```
|
|
90
|
-
|
|
91
|
-
**💡 Common Issue Troubleshooting**
|
|
92
|
-
|
|
93
|
-
| Error Phenomenon | Possible Cause | Solution |
|
|
94
|
-
|---------|---------|---------|
|
|
95
|
-
| `bash: flutter: command not found` | Flutter not added to PATH | Run `export PATH="$PATH:$HOME/flutter/bin"` or refer to [Flutter Installation Documentation](https://docs.flutter.dev/get-started/install) |
|
|
96
|
-
| `Error: Cannot find package` | pubspec.yaml configuration error | Check if dependency paths are correct (`tuikit_atomic_x` should point to `TUIKit_Flutter/atomic-x`) |
|
|
97
|
-
| `CocoaPods not installed` | iOS missing CocoaPods | Run `sudo gem install cocoapods` |
|
|
98
|
-
| `version solving failed` | Dependency version conflict | Run `flutter pub upgrade` or use `dependency_overrides` |
|
|
99
|
-
|
|
100
|
-
**⚠️ Remind Users**:
|
|
101
|
-
1. Ensure Flutter environment is correctly installed (run `flutter doctor` to check)
|
|
102
|
-
2. Ensure network can access `pub.dev` and `github.com`
|
|
103
|
-
3. If in mainland China, it is recommended to configure mirrors:
|
|
104
|
-
```bash
|
|
105
|
-
export PUB_HOSTED_URL=https://pub.flutter-io.cn
|
|
106
|
-
export FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn
|
|
107
|
-
```
|
|
108
|
-
|
|
109
|
-
### 4. Authentication Credential Configuration 🔴
|
|
110
|
-
- **Must call the `get_usersig` tool to obtain SDKAppID, UserID, UserSig for testing**
|
|
111
|
-
- UserID format: `userXXX` (XXX is a number), e.g., `user123`
|
|
112
|
-
- **⚠️ Security Warning**: Must inform users that client-side generation of UserSig is only suitable for local testing, production environment must generate UserSig on the server side
|
|
113
|
-
- Authentication information can be hard-coded in code for testing, but must be clearly marked in comments as for testing only
|
|
114
|
-
|
|
115
|
-
### 5. LoginPage Implementation Constraints 🔴
|
|
116
|
-
- **Must refer to `TUIKit_Flutter/chat/demo/lib/login_page.dart` to implement the login page** (note path prefix)
|
|
117
|
-
- **SDKAppID, UserID, UserSig must directly use the information returned by the `get_usersig` tool**
|
|
118
|
-
- **Prohibited from adding UserID input box in UI**, do not allow users to actively input UserID
|
|
119
|
-
- **Prohibited from adding SDKAppID and UserSig input boxes in UI**
|
|
120
|
-
- **Login interface must call `LoginStore.shared.login`**, passing complete credentials obtained from `get_usersig`
|
|
121
|
-
- After successful login, automatically navigate to the main page (ConversationsPage or ChatPage)
|
|
122
|
-
|
|
123
|
-
### 6. chat-only Mode Feature Restrictions (⚠️ Default Constraints + Exceptions When Users Actively Request)
|
|
124
|
-
|
|
125
|
-
**Default Behavior**:
|
|
126
|
-
When users choose chat-only mode, Agent **by default excludes** the following extended features:
|
|
127
|
-
- **By default, do not integrate ConversationsPage** (conversation list page)
|
|
128
|
-
- **By default, do not integrate ContactsPage** (contacts page)
|
|
129
|
-
- **By default, only retain core chat page**: `ChatPage`
|
|
130
|
-
|
|
131
|
-
**Exception Handling**:
|
|
132
|
-
If users **explicitly request** adding certain extended features (such as "need ConversationsPage", "want to integrate contacts", etc.), Agent **should allow and execute**:
|
|
133
|
-
- ✅ On the basis of core chat page, additionally integrate features explicitly requested by users
|
|
134
|
-
- ✅ Only add features explicitly requested by users, do not expand other features without authorization
|
|
135
|
-
- ✅ Integrate required pages correctly according to integration documentation specifications
|
|
136
|
-
|
|
137
|
-
**Judgment Criteria**:
|
|
138
|
-
- User requirements contain explicit feature keywords (such as "ConversationsPage", "contacts", "search", "conversation list", etc.)
|
|
139
|
-
- User explicitly states the need for a certain extended feature
|
|
140
|
-
|
|
141
|
-
### 7. Package Name Import Constraints 🔴
|
|
142
|
-
- **The correct package name is `package:tuikit_atomic_x/atomicx.dart`**
|
|
143
|
-
- **Prohibited from using the following incorrect package names**:
|
|
144
|
-
- ❌ `package:tuikit_atomic_x/tuikit_atomicx.dart`
|
|
145
|
-
- ❌ `package:tuikit_atomic_x/tuikit_atomic_x.dart`
|
|
146
|
-
- **Prohibited from guessing package names**, must strictly use them according to the sample code in the integration documentation
|
|
147
|
-
- All import statements must use correct package name paths
|
|
148
|
-
- **When using `BaseThemeProvider.colorsOf(context)`, must use correct property names** (see Section 9 for detailed specifications)
|
|
149
|
-
|
|
150
|
-
### 8. Flutter Project Specifications
|
|
151
|
-
- Use Flutter >= 3.29.0, Dart >= 3.7.0, Kotlin >= 1.9 versions
|
|
152
|
-
- Follow Flutter official code style and best practices
|
|
153
|
-
- Configure permissions and dependencies for Android and iOS platforms according to integration documentation
|
|
154
|
-
- **🌐 Special Note: All UI Text Must Be in English**
|
|
155
|
-
- **All page text, button labels, prompts, and error messages must be in English**
|
|
156
|
-
- **Prohibited from hard-coding Chinese text** (such as `'登录'`, `'发送'`, `'确认'`)
|
|
157
|
-
- **Must use `atomicLocale` for internationalization** or hard-code English text directly
|
|
158
|
-
- **Examples**:
|
|
159
|
-
- ❌ Wrong: `Text('登录')`, `label: '聊天'`
|
|
160
|
-
- ✅ Correct: `Text(atomicLocale.login)`, `label: atomicLocale.chat`, or `Text('Login')`
|
|
161
|
-
- **Must configure internationalization and LocaleProvider** (mandatory requirement):
|
|
162
|
-
|
|
163
|
-
**⚠️ Critical: Initialize StorageUtil Before Setting Language**
|
|
164
|
-
|
|
165
|
-
To ensure `LocaleProvider()..changeLanguage('en')` takes effect properly, **must call `StorageUtil.init()` in the `main()` function** before running the app.
|
|
166
|
-
|
|
167
|
-
**Why is this necessary?**
|
|
168
|
-
- `LocaleProvider()..changeLanguage('en')` relies on `StorageUtil` to persist language settings
|
|
169
|
-
- Without initialization, the language setting may fail due to timing issues
|
|
170
|
-
- `StorageUtil.init()` is an async operation and must be awaited before `runApp()`
|
|
171
|
-
|
|
172
|
-
**Complete Example (main.dart):**
|
|
173
|
-
```dart
|
|
174
|
-
import 'package:flutter/material.dart';
|
|
175
|
-
import 'package:flutter_localizations/flutter_localizations.dart';
|
|
176
|
-
import 'package:provider/provider.dart';
|
|
177
|
-
import 'package:tuikit_atomic_x/atomicx.dart';
|
|
178
|
-
|
|
179
|
-
// ✅ STEP 1: Initialize StorageUtil in main() function
|
|
180
|
-
void main() async {
|
|
181
|
-
WidgetsFlutterBinding.ensureInitialized();
|
|
182
|
-
await StorageUtil.init(); // CRITICAL: Must be called before runApp()
|
|
183
|
-
runApp(const MyApp());
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
// ✅ STEP 2: Configure LocaleProvider in MyApp
|
|
187
|
-
class MyApp extends StatelessWidget {
|
|
188
|
-
const MyApp({super.key});
|
|
189
|
-
|
|
190
|
-
@override
|
|
191
|
-
Widget build(BuildContext context) {
|
|
192
|
-
return ComponentTheme(
|
|
193
|
-
child: MultiProvider(
|
|
194
|
-
providers: [
|
|
195
|
-
ChangeNotifierProvider(
|
|
196
|
-
create: (_) => LocaleProvider()..changeLanguage('en'), // Set default to English
|
|
197
|
-
),
|
|
198
|
-
],
|
|
199
|
-
child: Builder(
|
|
200
|
-
builder: (context) {
|
|
201
|
-
final localeProvider = Provider.of<LocaleProvider>(context);
|
|
202
|
-
|
|
203
|
-
return MaterialApp(
|
|
204
|
-
title: 'TUIKit Flutter Demo',
|
|
205
|
-
theme: ThemeData(
|
|
206
|
-
colorScheme: ColorScheme.fromSeed(seedColor: Colors.blue),
|
|
207
|
-
useMaterial3: true,
|
|
208
|
-
),
|
|
209
|
-
localizationsDelegates: const [
|
|
210
|
-
AtomicLocalizations.delegate, // TUIKit internationalization (required)
|
|
211
|
-
GlobalMaterialLocalizations.delegate, // Material component internationalization
|
|
212
|
-
GlobalWidgetsLocalizations.delegate, // Widget internationalization
|
|
213
|
-
GlobalCupertinoLocalizations.delegate, // iOS style component internationalization
|
|
214
|
-
],
|
|
215
|
-
supportedLocales: AtomicLocalizations.supportedLocales, // Use TUIKit supported languages
|
|
216
|
-
locale: localeProvider.locale, // Bind current language
|
|
217
|
-
home: const LoginPage(), // Replace with your home Widget (e.g., HomePage, LoginScreen, etc.)
|
|
218
|
-
);
|
|
219
|
-
},
|
|
220
|
-
),
|
|
221
|
-
),
|
|
222
|
-
);
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
```
|
|
226
|
-
|
|
227
|
-
**pubspec.yaml must add dependencies**:
|
|
228
|
-
```yaml
|
|
229
|
-
dependencies:
|
|
230
|
-
flutter_localizations:
|
|
231
|
-
sdk: flutter
|
|
232
|
-
provider: ^6.0.0 # Or latest version
|
|
233
|
-
```
|
|
234
|
-
|
|
235
|
-
**Widget Tree Structure Requirements** (from outer to inner):
|
|
236
|
-
```
|
|
237
|
-
ComponentTheme ← Outermost layer (TUIKit theme component)
|
|
238
|
-
└─ MultiProvider ← Provider container
|
|
239
|
-
└─ providers: [LocaleProvider] ← Register LocaleProvider
|
|
240
|
-
└─ Builder ← For obtaining context
|
|
241
|
-
└─ MaterialApp ← Application entry
|
|
242
|
-
├─ localizationsDelegates ← Internationalization delegates
|
|
243
|
-
│ ├─ AtomicLocalizations.delegate (TUIKit internationalization, required)
|
|
244
|
-
│ ├─ GlobalMaterialLocalizations.delegate
|
|
245
|
-
│ ├─ GlobalWidgetsLocalizations.delegate
|
|
246
|
-
│ └─ GlobalCupertinoLocalizations.delegate
|
|
247
|
-
├─ supportedLocales ← AtomicLocalizations.supportedLocales
|
|
248
|
-
├─ locale ← localeProvider.locale (bind language)
|
|
249
|
-
└─ home: YourHomePage ← Home page (replace according to actual situation)
|
|
250
|
-
```
|
|
251
|
-
|
|
252
|
-
**⚠️ Key Points**:
|
|
253
|
-
1. **Must initialize StorageUtil in main() function** (`await StorageUtil.init()` before `runApp()`)
|
|
254
|
-
2. **ComponentTheme must be at the outermost layer** (wrapping MultiProvider)
|
|
255
|
-
3. **Must add AtomicLocalizations.delegate** (TUIKit internationalization delegate)
|
|
256
|
-
4. **supportedLocales uses `AtomicLocalizations.supportedLocales`** (not manually specified)
|
|
257
|
-
5. **Use Builder + Provider.of to get LocaleProvider** (implement language switching)
|
|
258
|
-
6. **Use `ChangeNotifierProvider` with `create: (_) => LocaleProvider()..changeLanguage('en')`** (set default to English)
|
|
259
|
-
7. **Add `const` constructors and constant Widgets** (performance optimization)
|
|
260
|
-
8. **`home` parameter adjusted according to actual needs** (see explanation below)
|
|
261
|
-
9. **🌐 All custom UI text must be in English** (button labels, prompts, error messages, etc.)
|
|
262
|
-
|
|
263
|
-
**📱 `home` Parameter Usage Scenarios**:
|
|
264
|
-
|
|
265
|
-
| Scenario | Recommended `home` Widget | Description |
|
|
266
|
-
|-----|-------------------|------|
|
|
267
|
-
| Need Login | `const LoginPage()` or `const LoginScreen()` | Users not logged in first enter login page |
|
|
268
|
-
| Logged-in Users | `const HomePage()` | Directly enter home page (including TabBar) |
|
|
269
|
-
| Debug Testing | `const ChatPage(conversationID: 'test')` | Directly enter a chat page |
|
|
270
|
-
| Onboarding | `const OnboardingPage()` | Show onboarding on first use |
|
|
271
|
-
|
|
272
|
-
**💡 Common Implementation Methods**:
|
|
273
|
-
|
|
274
|
-
```dart
|
|
275
|
-
// Method 1: Dynamically choose home page based on login status
|
|
276
|
-
home: _isLoggedIn ? const HomePage() : const LoginPage(),
|
|
277
|
-
|
|
278
|
-
// Method 2: Use route guards (recommended)
|
|
279
|
-
initialRoute: '/',
|
|
280
|
-
routes: {
|
|
281
|
-
'/': (context) => const SplashPage(), // Splash page determines status
|
|
282
|
-
'/login': (context) => const LoginPage(), // Login page
|
|
283
|
-
'/home': (context) => const HomePage(), // Home page
|
|
284
|
-
},
|
|
285
|
-
```
|
|
286
|
-
|
|
287
|
-
### 9. BaseThemeProvider Color Property Usage Specifications 🎨
|
|
288
|
-
|
|
289
|
-
**Purpose**: Ensure correct usage of `BaseThemeProvider.colorsOf(context)` properties when integrating TUIKit Flutter components, preventing common property name errors.
|
|
290
|
-
|
|
291
|
-
#### ⚠️ Common Mistakes to Avoid
|
|
292
|
-
|
|
293
|
-
**❌ WRONG - These properties DO NOT exist:**
|
|
294
|
-
- `bgColorContainer` ❌
|
|
295
|
-
- `borderColorNormal` ❌
|
|
296
|
-
- `bgColorCard` ❌
|
|
297
|
-
- `bgColorPage` ❌
|
|
298
|
-
|
|
299
|
-
**✅ CORRECT - Use these properties instead:**
|
|
300
|
-
|
|
301
|
-
#### 📋 Available Background Colors (`bgColor*`)
|
|
302
|
-
|
|
303
|
-
| Property Name | Usage Scenario |
|
|
304
|
-
|--------------|----------------|
|
|
305
|
-
| `bgColorTopBar` | Top navigation bar background |
|
|
306
|
-
| `bgColorOperate` | Main operation area background (pages, screens) |
|
|
307
|
-
| `bgColorDialog` | Dialog/modal background |
|
|
308
|
-
| `bgColorDialogModule` | Sub-modules within dialogs |
|
|
309
|
-
| `bgColorEntryCard` | Card/entry components (✅ Use this instead of `bgColorContainer`) |
|
|
310
|
-
| `bgColorFunction` | Functional area background |
|
|
311
|
-
| `bgColorBottomBar` | Bottom navigation bar background |
|
|
312
|
-
| `bgColorInput` | Input field background |
|
|
313
|
-
| `bgColorBubbleReciprocal` | Chat bubble background (received messages) |
|
|
314
|
-
| `bgColorBubbleOwn` | Chat bubble background (sent messages) |
|
|
315
|
-
| `bgColorDefault` | Default background color |
|
|
316
|
-
| `bgColorTagMask` | Tag mask background |
|
|
317
|
-
| `bgColorElementMask` | Element mask background |
|
|
318
|
-
| `bgColorMask` | General mask background |
|
|
319
|
-
| `bgColorMaskDisappeared` | Disappearing mask |
|
|
320
|
-
| `bgColorMaskBegin` | Initial mask state |
|
|
321
|
-
| `bgColorAvatar` | Avatar background |
|
|
322
|
-
|
|
323
|
-
#### 📋 Available Border/Stroke Colors
|
|
324
|
-
|
|
325
|
-
| Property Name | Usage Scenario |
|
|
326
|
-
|--------------|----------------|
|
|
327
|
-
| `strokeColorPrimary` | Primary borders (✅ Use this instead of `borderColorNormal`) |
|
|
328
|
-
| `strokeColorSecondary` | Secondary borders |
|
|
329
|
-
| `strokeColorModule` | Module dividers/borders |
|
|
330
|
-
|
|
331
|
-
#### 📋 Available Text Colors
|
|
332
|
-
|
|
333
|
-
| Property Name | Usage Scenario |
|
|
334
|
-
|--------------|----------------|
|
|
335
|
-
| `textColorPrimary` | Primary text |
|
|
336
|
-
| `textColorSecondary` | Secondary/hint text |
|
|
337
|
-
| `textColorTertiary` | Tertiary/less important text |
|
|
338
|
-
| `textColorDisable` | Disabled text |
|
|
339
|
-
| `textColorButton` | Button text |
|
|
340
|
-
| `textColorLink` | Link text |
|
|
341
|
-
| `textColorWarning` | Warning text |
|
|
342
|
-
| `textColorSuccess` | Success text |
|
|
343
|
-
| `textColorError` | Error text |
|
|
344
|
-
|
|
345
|
-
#### 📋 Available Button Colors
|
|
346
|
-
|
|
347
|
-
| Property Name | Usage Scenario |
|
|
348
|
-
|--------------|----------------|
|
|
349
|
-
| `buttonColorPrimaryDefault` | Primary button default state |
|
|
350
|
-
| `buttonColorPrimaryHover` | Primary button hover state |
|
|
351
|
-
| `buttonColorPrimaryActive` | Primary button active state |
|
|
352
|
-
| `buttonColorPrimaryDisabled` | Primary button disabled state |
|
|
353
|
-
| `buttonColorSecondaryDefault` | Secondary button default state |
|
|
354
|
-
| `buttonColorSecondaryHover` | Secondary button hover state |
|
|
355
|
-
| `buttonColorSecondaryActive` | Secondary button active state |
|
|
356
|
-
| `buttonColorSecondaryDisabled` | Secondary button disabled state |
|
|
357
|
-
|
|
358
|
-
**Usage Example:**
|
|
359
|
-
```dart
|
|
360
|
-
// ✅ Correct usage
|
|
361
|
-
Container(
|
|
362
|
-
color: BaseThemeProvider.colorsOf(context).bgColorOperate, // For page background
|
|
363
|
-
child: Card(
|
|
364
|
-
color: BaseThemeProvider.colorsOf(context).bgColorEntryCard, // For card background
|
|
365
|
-
shape: RoundedRectangleBorder(
|
|
366
|
-
borderRadius: BorderRadius.circular(8),
|
|
367
|
-
side: BorderSide(
|
|
368
|
-
color: BaseThemeProvider.colorsOf(context).strokeColorPrimary, // For border
|
|
369
|
-
),
|
|
370
|
-
),
|
|
371
|
-
),
|
|
372
|
-
)
|
|
373
|
-
|
|
374
|
-
// ❌ Wrong usage - these properties don't exist
|
|
375
|
-
Container(
|
|
376
|
-
color: BaseThemeProvider.colorsOf(context).bgColorContainer, // ❌ Error
|
|
377
|
-
decoration: BoxDecoration(
|
|
378
|
-
border: Border.all(
|
|
379
|
-
color: BaseThemeProvider.colorsOf(context).borderColorNormal, // ❌ Error
|
|
380
|
-
),
|
|
381
|
-
),
|
|
382
|
-
)
|
|
383
|
-
```
|
|
384
|
-
|
|
385
|
-
### 10. Environment Dependency Preparation
|
|
386
|
-
- Ensure users have installed Flutter SDK, Android Studio, and Xcode (macOS)
|
|
387
|
-
- **Flutter command execution follows the multi-level fallback strategy in Section 3**
|
|
388
|
-
- iOS platform requires additional execution of `cd ios && pod install && cd ..` to install Pods dependencies
|
|
389
|
-
- **If automatic execution fails, must generate fallback scripts for users to execute manually**
|
|
390
|
-
|
|
391
|
-
---
|
|
392
|
-
|
|
393
|
-
## 🛠️ Integration Mode Distribution (Goals)
|
|
394
|
-
|
|
395
|
-
According to user requirements, Agent must choose the corresponding execution path:
|
|
396
|
-
|
|
397
|
-
### 1. Full-Featured Integration (full-featured)
|
|
398
|
-
|
|
399
|
-
**Goal**: Implement a complete IM application similar to WeChat
|
|
400
|
-
|
|
401
|
-
**Core Pages**:
|
|
402
|
-
- `ConversationsPage` (conversation list)
|
|
403
|
-
- `ChatPage` (chat page)
|
|
404
|
-
- `ContactsPage` (contacts)
|
|
405
|
-
|
|
406
|
-
**Execution Reference**:
|
|
407
|
-
- Refer to the `integration.md` instructions obtained in real-time from tool return results
|
|
408
|
-
|
|
409
|
-
**Applicable Scenarios**:
|
|
410
|
-
- Build standalone chat applications
|
|
411
|
-
- Need complete conversation management, address book, group management features
|
|
412
|
-
- As a core functional module of mobile applications
|
|
413
|
-
|
|
414
|
-
**HomePage and TabBar Implementation Requirements** (🔴 Mandatory Requirements):
|
|
415
|
-
|
|
416
|
-
If the project does not have TabBar navigation, **must create HomePage as the main page**, including the following requirements:
|
|
417
|
-
|
|
418
|
-
1. **Must implement bottom TabBar**:
|
|
419
|
-
- By default, includes two tabs: **Chat** (ConversationsPage) and **Contacts** (ContactsPage)
|
|
420
|
-
- Use Flutter's `BottomNavigationBar` or `TabBar` component
|
|
421
|
-
|
|
422
|
-
2. **Tab clicks must navigate to real pages**:
|
|
423
|
-
- Click "Chat" Tab → Display `ConversationsPage` (conversation list)
|
|
424
|
-
- Click "Contacts" Tab → Display `ContactsPage` (contacts list)
|
|
425
|
-
- Use `PageView`, `IndexedStack`, or route switching to implement page switching
|
|
426
|
-
|
|
427
|
-
3. **HomePage Structure Example**:
|
|
428
|
-
```dart
|
|
429
|
-
import 'package:flutter/material.dart';
|
|
430
|
-
import 'package:tuikit_atomic_x/atomicx.dart';
|
|
431
|
-
|
|
432
|
-
class HomePage extends StatefulWidget {
|
|
433
|
-
@override
|
|
434
|
-
_HomePageState createState() => _HomePageState();
|
|
435
|
-
}
|
|
436
|
-
|
|
437
|
-
class _HomePageState extends State<HomePage> {
|
|
438
|
-
int _selectedIndex = 0;
|
|
439
|
-
|
|
440
|
-
final List<Widget> _pages = [
|
|
441
|
-
ConversationsPage(), // Conversation list
|
|
442
|
-
ContactsPage(), // Contacts
|
|
443
|
-
];
|
|
444
|
-
|
|
445
|
-
void _onItemTapped(int index) {
|
|
446
|
-
setState(() {
|
|
447
|
-
_selectedIndex = index;
|
|
448
|
-
});
|
|
449
|
-
}
|
|
450
|
-
|
|
451
|
-
@override
|
|
452
|
-
Widget build(BuildContext context) {
|
|
453
|
-
return Scaffold(
|
|
454
|
-
body: IndexedStack(
|
|
455
|
-
index: _selectedIndex,
|
|
456
|
-
children: _pages,
|
|
457
|
-
),
|
|
458
|
-
bottomNavigationBar: BottomNavigationBar(
|
|
459
|
-
items: [
|
|
460
|
-
BottomNavigationBarItem(
|
|
461
|
-
icon: Icon(Icons.chat_bubble_outline),
|
|
462
|
-
activeIcon: Icon(Icons.chat_bubble),
|
|
463
|
-
label: atomicLocale.chat,
|
|
464
|
-
),
|
|
465
|
-
BottomNavigationBarItem(
|
|
466
|
-
icon: Icon(Icons.contacts_outlined),
|
|
467
|
-
activeIcon: Icon(Icons.contacts),
|
|
468
|
-
label: atomicLocale.contact,
|
|
469
|
-
),
|
|
470
|
-
],
|
|
471
|
-
currentIndex: _selectedIndex,
|
|
472
|
-
onTap: _onItemTapped,
|
|
473
|
-
),
|
|
474
|
-
);
|
|
475
|
-
}
|
|
476
|
-
}
|
|
477
|
-
```
|
|
478
|
-
|
|
479
|
-
**⚠️ TabBar label Internationalization Requirements**:
|
|
480
|
-
- **Must use `atomicLocale` to read Tab label text**
|
|
481
|
-
- ✅ Correct usage: `label: atomicLocale.chat`, `label: atomicLocale.contact`
|
|
482
|
-
- `atomicLocale` will automatically return corresponding translated text based on current language environment
|
|
483
|
-
|
|
484
|
-
**💡 TabBar Best Practices**:
|
|
485
|
-
- Use `icon` and `activeIcon` to distinguish selected/unselected states
|
|
486
|
-
- Use semantic icons: Chat (`Icons.chat_bubble_outline` / `Icons.chat_bubble`), Contacts (`Icons.contacts_outlined` / `Icons.contacts`)
|
|
487
|
-
- Variable name `_selectedIndex` is more semantic than `_currentIndex`
|
|
488
|
-
|
|
489
|
-
4. **Navigate to HomePage after successful login**:
|
|
490
|
-
```dart
|
|
491
|
-
// LoginPage.dart
|
|
492
|
-
await LoginStore.shared.login(...);
|
|
493
|
-
Navigator.pushReplacement(
|
|
494
|
-
context,
|
|
495
|
-
MaterialPageRoute(builder: (_) => HomePage()), // Navigate to HomePage
|
|
496
|
-
);
|
|
497
|
-
```
|
|
498
|
-
|
|
499
|
-
5. **Prohibited Behaviors**:
|
|
500
|
-
- ❌ Directly navigate to a single page after login (such as ConversationsPage) without TabBar
|
|
501
|
-
- ❌ Create empty HomePage but without actual page switching logic
|
|
502
|
-
- ❌ TabBar has only one Tab (must have at least "Chat" and "Contacts")
|
|
503
|
-
|
|
504
|
-
---
|
|
505
|
-
|
|
506
|
-
### 2. Chat Page Only Integration (chat-only)
|
|
507
|
-
|
|
508
|
-
**Goal**: Suitable for pure conversation scenarios such as customer service, consultation, detail page private chat
|
|
509
|
-
|
|
510
|
-
**Core Pages**:
|
|
511
|
-
- `ChatPage` (chat page)
|
|
512
|
-
|
|
513
|
-
**Execution Reference**:
|
|
514
|
-
- Refer to the `integration.md` instructions obtained in real-time from tool return results
|
|
515
|
-
|
|
516
|
-
**Applicable Scenarios**:
|
|
517
|
-
- Customer service consultation scenario (users click consultation button to enter chat page)
|
|
518
|
-
- Online medical consultation (patient and doctor one-on-one communication)
|
|
519
|
-
- Order detail page private chat (buyer and seller communication)
|
|
520
|
-
- Private message feature in social applications
|
|
521
|
-
|
|
522
|
-
**💡 Page Navigation After Successful Login (chat-only Mode Guidance)**:
|
|
523
|
-
|
|
524
|
-
**Default Behavior**: If the user does not specifically specify, after successful login, directly navigate to `ChatPage`, opening a single chat session with `administrator`.
|
|
525
|
-
|
|
526
|
-
**Flexible Adjustment**: If the user has other requirements (such as opening chat page at a specific time, specifying other conversation targets), need to confirm navigation timing and target conversation according to user guidance.
|
|
527
|
-
|
|
528
|
-
**Default Implementation Example**:
|
|
529
|
-
|
|
530
|
-
```dart
|
|
531
|
-
// ✅ Successful login, directly enter chat page
|
|
532
|
-
Navigator.pushReplacement(
|
|
533
|
-
context,
|
|
534
|
-
MaterialPageRoute(
|
|
535
|
-
builder: (context) => const ChatPage(
|
|
536
|
-
conversationID: 'c2c_administrator', // Default single chat with administrator
|
|
537
|
-
),
|
|
538
|
-
),
|
|
539
|
-
);
|
|
540
|
-
```
|
|
541
|
-
|
|
542
|
-
**⚠️ Key Points**:
|
|
543
|
-
1. **Use `Navigator.pushReplacement`** (replace login page, prevent going back)
|
|
544
|
-
2. **conversationID format**: Single chat `'c2c_<userID>'`, group chat `'group_<groupID>'`
|
|
545
|
-
3. **Default conversation ID**: `'c2c_administrator'` (can be adjusted to other userID or groupID according to user needs)
|
|
546
|
-
4. **Navigation timing**: By default, navigate immediately in the successful login callback, if user has special needs (such as navigate after clicking button), need to adjust according to user guidance
|
|
547
|
-
|
|
548
|
-
**🔴 Default Excluded Features (Agent Must Comply)**:
|
|
549
|
-
|
|
550
|
-
When generating chat-only mode code, Agent **by default excludes** the following features and pages:
|
|
551
|
-
|
|
552
|
-
1. **By default, do not integrate ConversationsPage (conversation list)**
|
|
553
|
-
- By default, do not generate conversation list page
|
|
554
|
-
- By default, do not introduce conversation switching feature
|
|
555
|
-
- Chat page by default should be an independent, direct pure chat interface
|
|
556
|
-
|
|
557
|
-
2. **By default, do not integrate ContactsPage (contacts)**
|
|
558
|
-
- By default, do not generate address book page
|
|
559
|
-
- By default, do not introduce contact management feature
|
|
560
|
-
|
|
561
|
-
3. **By default, do not integrate bottom navigation bar (TabBar)**
|
|
562
|
-
- In chat-only mode, users specify conversation ID through external routing/parameters
|
|
563
|
-
- By default, no need for page switching feature
|
|
564
|
-
|
|
565
|
-
---
|
|
566
|
-
|
|
567
|
-
**⚠️ Exception Handling When Users Actively Request**:
|
|
568
|
-
|
|
569
|
-
If users **explicitly request** adding certain extended features in chat-only mode, Agent **should allow and execute**:
|
|
570
|
-
|
|
571
|
-
**Trigger Conditions** (satisfy any one):
|
|
572
|
-
- User explicitly states: "need ConversationsPage", "want to integrate conversation list", "add conversation switching feature"
|
|
573
|
-
- User explicitly states: "need ContactsPage", "want to add contacts", "integrate address book"
|
|
574
|
-
- User explicitly proposes other extended feature requirements
|
|
575
|
-
|
|
576
|
-
**Agent Execution Process**:
|
|
577
|
-
1. ✅ **Confirm user requirements**: Recognize that users actively request adding extended features
|
|
578
|
-
2. ✅ **Allow integration**: On the basis of chat-only mode, additionally integrate pages requested by users
|
|
579
|
-
3. ✅ **Maintain restraint**: Only add features explicitly requested by users, do not expand other features without authorization
|
|
580
|
-
4. ✅ **Follow documentation**: Integrate required pages correctly according to integration documentation specifications
|
|
581
|
-
|
|
582
|
-
---
|
|
583
|
-
|
|
584
|
-
## 📦 Core Version Requirements
|
|
585
|
-
|
|
586
|
-
| Tool/Platform | Minimum Version Requirement |
|
|
587
|
-
|----------|-------------|
|
|
588
|
-
| **Flutter** | >= 3.29.0 |
|
|
589
|
-
| **Dart** | >= 3.7.0 |
|
|
590
|
-
| **Kotlin** | >= 1.9 |
|
|
591
|
-
| **Android Studio** | Ladybug \| 2024.2.1 and above |
|
|
592
|
-
| **Android Gradle Plugin** | >= 7.3.1 |
|
|
593
|
-
| **JDK** | 17 |
|
|
594
|
-
| **Xcode** | >= 12.0 (macOS) |
|
|
595
|
-
|
|
596
|
-
---
|
|
597
|
-
|
|
598
|
-
## 📦 Installation Command Examples
|
|
599
|
-
After Agent completes code generation, must execute the following commands in order:
|
|
600
|
-
|
|
601
|
-
**⚠️ Important: Flutter Command Execution Specification**
|
|
602
|
-
- Must use `which flutter` to get Flutter actual installation path
|
|
603
|
-
- Use full path to execute commands, avoid environment variable issues
|
|
604
|
-
- Ensure execution in user project directory
|
|
605
|
-
|
|
606
|
-
```bash
|
|
607
|
-
# 0. Get Flutter actual path (must execute first)
|
|
608
|
-
FLUTTER_PATH=$(which flutter)
|
|
609
|
-
|
|
610
|
-
# 1. Clean project
|
|
611
|
-
$FLUTTER_PATH clean
|
|
612
|
-
|
|
613
|
-
# 2. Get dependencies
|
|
614
|
-
$FLUTTER_PATH pub get
|
|
615
|
-
|
|
616
|
-
# 3. iOS dependency installation (macOS only)
|
|
617
|
-
cd ios && pod install && cd ..
|
|
618
|
-
|
|
619
|
-
# 4. Run project (choose device or simulator)
|
|
620
|
-
$FLUTTER_PATH run
|
|
621
|
-
```
|
|
622
|
-
|
|
623
|
-
**Command Execution Strategy**:
|
|
624
|
-
- First use full path obtained from `which flutter`
|
|
625
|
-
- If `which flutter` fails, try common paths:
|
|
626
|
-
- macOS/Linux: `$HOME/flutter/bin/flutter`
|
|
627
|
-
- Custom user path (read from environment variable `FLUTTER_ROOT`)
|
|
628
|
-
- If all paths fail, prompt user to check Flutter installation
|
|
629
|
-
|
|
630
|
-
---
|
|
631
|
-
|
|
632
|
-
## 📱 Real Device Debugging Guide
|
|
633
|
-
|
|
634
|
-
### iOS Real Device Debugging Steps
|
|
635
|
-
|
|
636
|
-
#### 1. Hardware Preparation
|
|
637
|
-
- Use USB cable to connect iPhone/iPad to Mac
|
|
638
|
-
- Ensure device is unlocked and trusts this computer (prompt will pop up on first connection)
|
|
639
|
-
|
|
640
|
-
#### 2. Configure Developer Account
|
|
641
|
-
|
|
642
|
-
**⚠️ Important: Correctly Open iOS Project**
|
|
643
|
-
|
|
644
|
-
When opening iOS project with Xcode, **must** open the `Runner.xcworkspace` file (not `Runner.xcodeproj`):
|
|
645
|
-
|
|
646
|
-
```bash
|
|
647
|
-
open ios/Runner.xcworkspace
|
|
648
|
-
```
|
|
649
|
-
|
|
650
|
-
**❌ Common Errors**:
|
|
651
|
-
- Do not open `ios/Runner.xcodeproj` (will cause CocoaPods dependencies to not be recognized)
|
|
652
|
-
- Do not double-click `ios` folder directly
|
|
653
|
-
|
|
654
|
-
**✅ Correct Approach**:
|
|
655
|
-
- Execute `open ios/Runner.xcworkspace` in terminal
|
|
656
|
-
- Or find `ios/Runner.xcworkspace` in Finder, double-click to open
|
|
657
|
-
|
|
658
|
-
**Configure Signing**:
|
|
659
|
-
|
|
660
|
-
In Xcode:
|
|
661
|
-
- Select **Runner** project → **Signing & Capabilities**
|
|
662
|
-
- Check **Automatically manage signing**
|
|
663
|
-
- Select your **Apple ID** (Team)
|
|
664
|
-
- Modify **Bundle Identifier** (must be unique, recommended format: `com.yourname.appname`)
|
|
665
|
-
|
|
666
|
-
#### 3. View Connected Devices
|
|
667
|
-
```bash
|
|
668
|
-
FLUTTER_PATH=$(which flutter)
|
|
669
|
-
$FLUTTER_PATH devices
|
|
670
|
-
```
|
|
671
|
-
|
|
672
|
-
Example output:
|
|
673
|
-
```
|
|
674
|
-
iPhone 15 Pro (mobile) • 00008110-XXXXX • ios • iOS 17.2
|
|
675
|
-
```
|
|
676
|
-
|
|
677
|
-
#### 4. Run on Specified Device
|
|
678
|
-
```bash
|
|
679
|
-
# Method 1: Use device ID
|
|
680
|
-
$FLUTTER_PATH run -d 00008110-XXXXX
|
|
681
|
-
|
|
682
|
-
# Method 2: Let Flutter automatically choose connected iOS device
|
|
683
|
-
$FLUTTER_PATH run -d ios
|
|
684
|
-
```
|
|
685
|
-
|
|
686
|
-
#### 5. First Run Authorization
|
|
687
|
-
- Real device first run will prompt "Untrusted Developer"
|
|
688
|
-
- On iPhone: **Settings → General → VPN & Device Management → Developer App → Trust**
|
|
689
|
-
- Run again `$FLUTTER_PATH run -d ios`
|
|
690
|
-
|
|
691
|
-
#### 6. Common Issues
|
|
692
|
-
| Issue | Solution |
|
|
693
|
-
|------|----------|
|
|
694
|
-
| **Signing error** | Check Team and Bundle ID configuration in Xcode |
|
|
695
|
-
| **Device not recognized** | Re-plug USB cable, ensure device is unlocked |
|
|
696
|
-
| **Pod installation failed** | Execute `cd ios && pod repo update && pod install && cd ..` |
|
|
697
|
-
|
|
698
|
-
---
|
|
699
|
-
|
|
700
|
-
### Android Real Device Debugging Steps
|
|
701
|
-
|
|
702
|
-
#### 1. Hardware Preparation
|
|
703
|
-
- Use USB cable to connect Android device to computer
|
|
704
|
-
- Ensure device is charged (recommended > 50%)
|
|
705
|
-
|
|
706
|
-
#### 2. Enable Developer Mode
|
|
707
|
-
On Android device:
|
|
708
|
-
1. Go to **Settings → About Phone**
|
|
709
|
-
2. Tap **Build Number** 7 times continuously to enable developer mode
|
|
710
|
-
3. Return to **Settings → System → Developer Options**
|
|
711
|
-
4. Enable **USB Debugging**
|
|
712
|
-
5. After connecting to computer, device will pop up **Allow USB Debugging** prompt, tap **Allow**
|
|
713
|
-
|
|
714
|
-
#### 3. Verify Device Connection
|
|
715
|
-
```bash
|
|
716
|
-
# Method 1: Use adb command
|
|
717
|
-
adb devices
|
|
718
|
-
|
|
719
|
-
# Example output:
|
|
720
|
-
# List of devices attached
|
|
721
|
-
# XXXXXXXX device
|
|
722
|
-
|
|
723
|
-
# Method 2: Use Flutter command
|
|
724
|
-
FLUTTER_PATH=$(which flutter)
|
|
725
|
-
$FLUTTER_PATH devices
|
|
726
|
-
```
|
|
727
|
-
|
|
728
|
-
Example output:
|
|
729
|
-
```
|
|
730
|
-
SM G9900 (mobile) • XXXXXXXX • android-arm64 • Android 13 (API 33)
|
|
731
|
-
```
|
|
732
|
-
|
|
733
|
-
#### 4. Run on Specified Device
|
|
734
|
-
```bash
|
|
735
|
-
# Method 1: Use device ID
|
|
736
|
-
$FLUTTER_PATH run -d XXXXXXXX
|
|
737
|
-
|
|
738
|
-
# Method 2: Let Flutter automatically choose connected Android device
|
|
739
|
-
$FLUTTER_PATH run -d android
|
|
740
|
-
```
|
|
741
|
-
|
|
742
|
-
#### 5. First Build Wait
|
|
743
|
-
- First run will download Gradle dependencies (may take 5-10 minutes)
|
|
744
|
-
- Wait for `Installing build/app/outputs/flutter-apk/app.apk...` to complete
|
|
745
|
-
- App will automatically install and launch
|
|
746
|
-
|
|
747
|
-
#### 6. Common Issues
|
|
748
|
-
| Issue | Solution |
|
|
749
|
-
|------|----------|
|
|
750
|
-
| **Device unauthorized** | Tap "Allow USB Debugging" on phone, check "Always allow" |
|
|
751
|
-
| **adb devices shows unauthorized** | Re-plug USB cable, re-authorize |
|
|
752
|
-
| **Gradle download slow** | Configure domestic mirror (modify `android/build.gradle`) |
|
|
753
|
-
| **Device offline** | Execute `adb kill-server && adb start-server` |
|
|
754
|
-
|
|
755
|
-
---
|
|
756
|
-
|
|
757
|
-
## 🚀 Multi-Device Simultaneous Debugging
|
|
758
|
-
|
|
759
|
-
If multiple devices are connected simultaneously, use the following commands to select:
|
|
760
|
-
|
|
761
|
-
```bash
|
|
762
|
-
FLUTTER_PATH=$(which flutter)
|
|
763
|
-
|
|
764
|
-
# View all devices
|
|
765
|
-
$FLUTTER_PATH devices
|
|
766
|
-
|
|
767
|
-
# Run on specified device
|
|
768
|
-
$FLUTTER_PATH run -d <device-id>
|
|
769
|
-
|
|
770
|
-
# Example: Run simultaneously on iOS and Android
|
|
771
|
-
$FLUTTER_PATH run -d ios &
|
|
772
|
-
$FLUTTER_PATH run -d android &
|
|
773
|
-
```
|
|
774
|
-
|
|
775
|
-
---
|
|
776
|
-
|
|
777
|
-
## 📊 Debugging Recommendations
|
|
778
|
-
|
|
779
|
-
### Hot Reload
|
|
780
|
-
After app is running, code will automatically hot reload when saved:
|
|
781
|
-
- Press `r` key in terminal to manually trigger hot reload
|
|
782
|
-
- Press `R` key to trigger hot restart
|
|
783
|
-
- Press `q` key to exit debugging
|
|
784
|
-
|
|
785
|
-
### View Logs
|
|
786
|
-
```bash
|
|
787
|
-
# Flutter logs
|
|
788
|
-
$FLUTTER_PATH logs
|
|
789
|
-
|
|
790
|
-
# Android logs
|
|
791
|
-
adb logcat | grep flutter
|
|
792
|
-
|
|
793
|
-
# iOS logs (requires ios-deploy)
|
|
794
|
-
ios-deploy --id <device-id> --debug
|
|
795
|
-
```
|
|
796
|
-
|
|
797
|
-
### Performance Analysis
|
|
798
|
-
```bash
|
|
799
|
-
# Start performance analysis
|
|
800
|
-
$FLUTTER_PATH run --profile
|
|
801
|
-
|
|
802
|
-
# Start debugging tools
|
|
803
|
-
$FLUTTER_PATH pub global run devtools
|
|
804
|
-
```
|
|
805
|
-
|
|
806
|
-
---
|
|
807
|
-
|
|
808
|
-
## 🔄 Complete Automation Process
|
|
809
|
-
|
|
810
|
-
```mermaid
|
|
811
|
-
graph TD
|
|
812
|
-
A[Receive User Requirements] --> B[Get Flutter Actual Path: which flutter]
|
|
813
|
-
B --> C[Check Flutter Environment]
|
|
814
|
-
C --> D[Enter Project Parent Directory and Clone TUIKit_Flutter]
|
|
815
|
-
D --> E[Configure pubspec.yaml According to Integration Documentation]
|
|
816
|
-
E --> F[Configure iOS Podfile According to Integration Documentation]
|
|
817
|
-
F --> G[Configure main.dart According to Integration Documentation]
|
|
818
|
-
G --> H[Call get_usersig Tool to Obtain Authentication Information]
|
|
819
|
-
H --> I[Implement Login Logic According to Integration Documentation]
|
|
820
|
-
I --> J[Implement Core Pages According to Integration Documentation]
|
|
821
|
-
J --> K[Call record_result to Record Integration Results]
|
|
822
|
-
K --> L[Execute Using Full Path: $FLUTTER_PATH pub get]
|
|
823
|
-
L --> M{iOS Platform?}
|
|
824
|
-
M -->|Yes| N[Execute pod install]
|
|
825
|
-
M -->|No| O[Skip pod install]
|
|
826
|
-
N --> P[Guide Users to Connect Real Device Debugging]
|
|
827
|
-
O --> P
|
|
828
|
-
P --> Q{Choose Running Method}
|
|
829
|
-
Q -->|Simulator| R[Execute: $FLUTTER_PATH run]
|
|
830
|
-
Q -->|iOS Real Device| S[Execute: $FLUTTER_PATH run -d ios]
|
|
831
|
-
Q -->|Android Real Device| T[Execute: $FLUTTER_PATH run -d android]
|
|
832
|
-
R --> U[Project Startup Successful]
|
|
833
|
-
S --> U
|
|
834
|
-
T --> U
|
|
835
|
-
```
|
|
836
|
-
|
|
837
|
-
---
|
|
838
|
-
|
|
839
|
-
## 📝 Key Points Summary
|
|
840
|
-
|
|
841
|
-
| Category | Requirement |
|
|
842
|
-
|------|------|
|
|
843
|
-
| **Framework Version** | Flutter >= 3.29.0, Dart >= 3.7.0, Kotlin >= 1.9 |
|
|
844
|
-
| **Integration Method** | Source code integration (clone from GitHub and reference through local path) |
|
|
845
|
-
| **Documentation First** | ⚠️ Strictly follow sample code in integration documentation, do not modify without authorization |
|
|
846
|
-
| **Storage Initialization** | 🚨 **Must call `await StorageUtil.init()` in main() before runApp()** to ensure language settings work |
|
|
847
|
-
| **Core Page Source** | 🚨 **Strictly prohibited from writing core page code yourself**, must completely copy official page files from `TUIKit_Flutter/chat/uikit/lib/` |
|
|
848
|
-
| **Page Integrity Verification** | ⚠️ Core page code must be > 100 lines, including complete State classes, UI component trees, business logic |
|
|
849
|
-
| **Silent Integration** | Automatically install dependencies and start project after code writing is complete, **must use `which flutter` to get actual path** |
|
|
850
|
-
| **Credential Acquisition** | ⚠️ Must use `get_usersig` tool to obtain test authentication information |
|
|
851
|
-
| **Security Reminder** | ⚠️ Must inform users: Client-side generation of UserSig is only suitable for testing, production environment must generate on server side |
|
|
852
|
-
| **Result Recording** | ⚠️ Must call `record_result` tool to record results after integration is complete |
|
|
853
|
-
| **Integration Mode** | Support full-featured (full) and chat-only (chat only) modes |
|
|
854
|
-
| **chat-only Restrictions** | ⚠️ By default exclude ConversationsPage, ContactsPage, SearchPage; allow integration when users actively request |
|
|
855
|
-
| **Package Name Constraints** | ⚠️ Must use `package:tuikit_atomic_x/atomicx.dart`, prohibited from guessing package names |
|
|
856
|
-
| **Color Scheme Properties** | ⚠️ Must use correct `BaseThemeProvider.colorsOf(context)` property names (e.g., `bgColorOperate`, `strokeColorPrimary`), prohibited from using non-existent properties |
|
|
857
|
-
|
|
858
|
-
---
|
|
859
|
-
|
|
860
|
-
## 🎯 Agent Execution Checklist
|
|
861
|
-
|
|
862
|
-
After completing code generation, Agent must confirm all the following items:
|
|
863
|
-
|
|
864
|
-
### Project Initialization
|
|
865
|
-
- [ ] Entered user project parent directory
|
|
866
|
-
- [ ] Cloned TUIKit_Flutter repository to correct location
|
|
867
|
-
- [ ] Configured `pubspec.yaml` according to integration documentation
|
|
868
|
-
- [ ] Configured iOS Podfile according to integration documentation (iOS platform)
|
|
869
|
-
|
|
870
|
-
### Code Generation
|
|
871
|
-
- [ ] Configured `main.dart` according to integration documentation
|
|
872
|
-
- [ ] 🔴 **Added `await StorageUtil.init()` in main() function before runApp()**
|
|
873
|
-
- [ ] 🔴 **Added `WidgetsFlutterBinding.ensureInitialized()` before StorageUtil.init()**
|
|
874
|
-
- [ ] 🔴 **Called `get_usersig` tool to obtain SDKAppID, UserID, UserSig**
|
|
875
|
-
- [ ] 🔴 **Referred to `TUIKit_Flutter/chat/demo/lib/login_page.dart` to implement login page** (note path prefix)
|
|
876
|
-
- [ ] 🔴 **Login page does not contain UserID, SDKAppID, UserSig input boxes**
|
|
877
|
-
- [ ] Implemented login logic according to integration documentation, automatically using credentials returned by `get_usersig`
|
|
878
|
-
- [ ] 🔴 **Completely copied official page files from `TUIKit_Flutter/chat/uikit/lib/`**
|
|
879
|
-
- [ ] 🔴 **Core page code lines > 100 lines (verify not simplified version)**
|
|
880
|
-
- [ ] 🔴 **Core pages include complete State classes, UI component trees, business logic**
|
|
881
|
-
- [ ] 🔴 **Strictly prohibited from writing simplified implementations yourself, strictly prohibited from skipping page code generation**
|
|
882
|
-
- [ ] 🔴 **All imports use correct package name `package:tuikit_atomic_x/atomicx.dart`**
|
|
883
|
-
- [ ] 🔴 **All `BaseThemeProvider.colorsOf(context)` properties use correct names** (e.g., `bgColorOperate`, `strokeColorPrimary`, not `bgColorContainer` or `borderColorNormal`)
|
|
884
|
-
- [ ] Implemented navigation logic between pages according to integration documentation
|
|
885
|
-
|
|
886
|
-
### Integration Mode
|
|
887
|
-
- [ ] Selected correct integration mode according to user requirements (full-featured or chat-only)
|
|
888
|
-
- [ ] full-featured mode: Integrated ConversationsPage, ChatPage, ContactsPage and other pages
|
|
889
|
-
- [ ] chat-only mode: Integrated core page (ChatPage)
|
|
890
|
-
- [ ] chat-only mode: Judged whether extended features need to be integrated according to user requirements
|
|
891
|
-
- [ ] If user did not actively request, confirmed not to include ConversationsPage, ContactsPage, SearchPage and other pages
|
|
892
|
-
- [ ] If user actively requested (such as "need ConversationsPage"), additionally integrated features explicitly requested by user
|
|
893
|
-
|
|
894
|
-
### Security and Reminders
|
|
895
|
-
- [ ] 🔴 **Informed user**: Currently generated code is only suitable for local testing, production environment must generate UserSig on server side
|
|
896
|
-
- [ ] Marked location of test configuration in code comments
|
|
897
|
-
|
|
898
|
-
### Final Check
|
|
899
|
-
- [ ] 🔴 **Called `record_result` tool to record integration results**
|
|
900
|
-
- [ ] 🔴 **Used `which flutter` to get Flutter actual path**
|
|
901
|
-
- [ ] Executed `$FLUTTER_PATH pub get` to install dependencies (using full path)
|
|
902
|
-
- [ ] Executed `pod install` (iOS platform)
|
|
903
|
-
- [ ] Executed `$FLUTTER_PATH run` to start project (using full path)
|
|
904
|
-
- [ ] Prompted user to choose device or simulator to run
|
|
905
|
-
- [ ] Project can run normally without errors
|
|
906
|
-
|
|
907
|
-
---
|
|
908
|
-
|
|
909
|
-
## 🔗 Tools That Must Be Used
|
|
910
|
-
|
|
911
|
-
### `get_usersig` - Obtain Test Authentication Information
|
|
912
|
-
**Purpose**: Obtain Tencent Cloud IM test authentication information
|
|
913
|
-
- `SDKAppID`: Application identifier
|
|
914
|
-
- `UserID`: User ID
|
|
915
|
-
- `UserSig`: User signature
|
|
916
|
-
|
|
917
|
-
**Usage Constraints**:
|
|
918
|
-
- ✅ Must use `get_usersig` tool to obtain test authentication
|
|
919
|
-
- ❌ Prohibited from letting users manually input or copy from console
|
|
920
|
-
- ⚠️ Must inform users: Client-side generation of UserSig is only suitable for testing, production environment must generate on server side
|
|
921
|
-
|
|
922
|
-
### `record_result` - Record Integration Results
|
|
923
|
-
**Purpose**: Record integration process and results for statistics and analysis
|
|
924
|
-
|
|
925
|
-
**Calling Timing**: Call after completing all integration steps and successfully starting project
|
|
926
|
-
|
|
927
|
-
---
|
|
928
|
-
|
|
929
|
-
## 📚 Related Resource Links
|
|
930
|
-
|
|
931
|
-
- **TUIKit Flutter GitHub Repository**: https://github.com/Tencent-RTC/TUIKit_Flutter
|
|
932
|
-
- **Tencent Cloud Instant Messaging Chat Console**: https://console.trtc.io/chat
|
|
933
|
-
- **Server-side Generation of UserSig**: https://trtc.io/document/34385
|
|
934
|
-
- **Activate Chat Service**: https://trtc.io/document/45907
|
|
935
|
-
- **Flutter Official Documentation**: https://flutter.dev/docs
|
|
936
|
-
|
|
937
|
-
---
|
|
938
|
-
|
|
939
|
-
**Applicable Platform**: Flutter (Android & iOS)
|
|
940
|
-
**TUIKit Version**: tuikit_atomic_x (AtomicXCore version)
|
|
941
|
-
**Minimum Requirements**: Flutter >= 3.29.0, Dart >= 3.7.0
|