diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/.gitignore" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/.gitignore" new file mode 100644 index 0000000000000000000000000000000000000000..dc4e6353bf3caf74c5953d0bec81c72a3635bf33 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/.gitignore" @@ -0,0 +1,9 @@ +/node_modules +/local.properties +/.idea +**/build +/.hvigor +.cxx +/.clangd +/.clang-format +/.clang-tidy \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/app.json5" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/app.json5" new file mode 100644 index 0000000000000000000000000000000000000000..f89c7f39bda3e2d596d17eb99038f38b0206b4c6 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/app.json5" @@ -0,0 +1,11 @@ +{ + "app": { + "bundleName": "com.example.healthydietli", + "vendor": "example", + "versionCode": 1000000, + "versionName": "1.0.0", + "icon": "$media:app_icon", + "label": "$string:app_name", + "distributedNotificationEnabled": true + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/resources/base/element/string.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/resources/base/element/string.json" new file mode 100644 index 0000000000000000000000000000000000000000..df748cf5d9d3d14f79f1bf4d9bf719c34edfa4df --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/resources/base/element/string.json" @@ -0,0 +1,8 @@ +{ + "string": [ + { + "name": "app_name", + "value": "HealthyDietLi" + } + ] +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/resources/base/media/app_icon.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/resources/base/media/app_icon.png" new file mode 100644 index 0000000000000000000000000000000000000000..ce307a8827bd75456441ceb57d530e4c8d45d36c Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/AppScope/resources/base/media/app_icon.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/README.md" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/README.md" new file mode 100644 index 0000000000000000000000000000000000000000..f3df7fd2f992148cd47ff0791da1087d51d818d8 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/README.md" @@ -0,0 +1,20 @@ +# 健康饮食实例 + +#### 介绍 +这是一个记录饮食和查看食物信息的应用,主要用于管理饮食健康。可以添加饮食信息,包括食物的种类、重量以及用餐时间,如早餐、 午餐、晚餐和夜宵,并能统计得到相应用餐时间,并且用柱状图的形式展示出来。 + +#### 开发环境 +DevEco Studio 3.1 Canary1 + +构建版本:3.1.0.100,构建 November 3, 2022 + +运行时版本:11.0.13+7-b1751.21 amd64 + + +#### 知识要点 +1. 组件化 +2. 属性动画、显示动画、转场动画 + + +#### 效果图: +![输入图片说明](screenshots/healthy_diet_li.gif) \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/build-profile.json5" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/build-profile.json5" new file mode 100644 index 0000000000000000000000000000000000000000..d7b1117cdb34aab2983ac65026d9e8dcc91332d1 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/build-profile.json5" @@ -0,0 +1,27 @@ +{ + "app": { + "signingConfigs": [], + "compileSdkVersion": 9, + "compatibleSdkVersion": 9, + "products": [ + { + "name": "default", + "signingConfig": "default", + } + ] + }, + "modules": [ + { + "name": "entry", + "srcPath": "./entry", + "targets": [ + { + "name": "default", + "applyToProducts": [ + "default" + ] + } + ] + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/.gitignore" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/.gitignore" new file mode 100644 index 0000000000000000000000000000000000000000..5a6ba80fa3d9498a23ae8ae7d9518f8743fa8a96 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/.gitignore" @@ -0,0 +1,4 @@ +/node_modules +/.preview +/build +/.cxx \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/build-profile.json5" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/build-profile.json5" new file mode 100644 index 0000000000000000000000000000000000000000..20c75049f2d45e57d267899b6547c79fb6aa84c1 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/build-profile.json5" @@ -0,0 +1,14 @@ +{ + "apiType": 'stageMode', + "buildOption": { + }, + "targets": [ + { + "name": "default", + "runtimeOS": "HarmonyOS" + }, + { + "name": "ohosTest", + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/hvigorfile.ts" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/hvigorfile.ts" new file mode 100644 index 0000000000000000000000000000000000000000..80e4ec5b81689f238c34614b167a0b9e9c83e8d9 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/hvigorfile.ts" @@ -0,0 +1,2 @@ +// Script for compiling build behavior. It is built in the build plug-in and cannot be modified currently. +export { hapTasks } from '@ohos/hvigor-ohos-plugin'; diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/package-lock.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/package-lock.json" new file mode 100644 index 0000000000000000000000000000000000000000..15bc7145be1490029883067847743ea7134cf545 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/package-lock.json" @@ -0,0 +1,5 @@ +{ + "name": "entry", + "version": "1.0.0", + "lockfileVersion": 1 +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/package.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/package.json" new file mode 100644 index 0000000000000000000000000000000000000000..c4e988f30f2ec9e3430a4d0c8f05e89fabbc2659 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/package.json" @@ -0,0 +1,13 @@ +{ + "name": "entry", + "version": "1.0.0", + "ohos": { + "org": "huawei", + "buildTool": "hvigor", + "directoryLevel": "module" + }, + "description": "example description", + "repository": {}, + "license": "ISC", + "dependencies": {} +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/HomeBottom.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/HomeBottom.ets" new file mode 100644 index 0000000000000000000000000000000000000000..1c299db6d2b2789413cd6be93bfe1bbd8fa1754b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/HomeBottom.ets" @@ -0,0 +1,44 @@ +import { getIconPath, getIconPathSelect } from '../model/Model' + +@Component +export struct HomeBottom { + @Link currentPage: number + private iconPathTmp: string[] = getIconPath() + private iconPathSelectsTmp: string[] = getIconPathSelect() + @State iconPath: string[] = getIconPath() + build() { + Row(){ + List() { + ForEach(this.iconPath, item => { + ListItem() { + Image($rawfile(item)) + .objectFit(ImageFit.Fill) + .height(30) + .width(30) + .renderMode(ImageRenderMode.Original) + .onClick(()=>{ + if(item==this.iconPath[0]){ + this.iconPath[0]=this.iconPathTmp[0] + this.iconPath[1]=this.iconPathTmp[1] + this.currentPage=1 + } + if(item==this.iconPath[1]){ + this.iconPath[0]=this.iconPathSelectsTmp[0] + this.iconPath[1]=this.iconPathSelectsTmp[1] + this.currentPage=2 + } + }) + } + .width(120) + .height(40) + }, item => item) + } + .margin({left:10}) + .align(Alignment.BottomStart) + .listDirection(Axis.Horizontal) + } + .alignItems(VerticalAlign.Bottom) + .height(50) + .margin({top:10 ,bottom:10}) + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/calories_progress.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/calories_progress.ets" new file mode 100644 index 0000000000000000000000000000000000000000..e43941f71cf00edf3569f32af50c5d9197451a6e --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/calories_progress.ets" @@ -0,0 +1,72 @@ +import { FoodInfo } from '../../model/DietType' +import { CategoryEnum } from '../../model/DietEnum' + +import { CardTitle } from './card_title' + +@Component +export struct CaloriesProgress { + private foodInfo: FoodInfo + private averageCalories: number = 0 + private totalCalories: number = 0 + private highCalories: boolean = false + + aboutToAppear() { + switch (this.foodInfo.categoryId) { + case CategoryEnum.Vegetable: + this.averageCalories = 26 + break + case CategoryEnum.Fruit: + this.averageCalories = 60 + break + case CategoryEnum.Nut: + this.averageCalories = 606 + break + case CategoryEnum.Seafood: + this.averageCalories = 56 + break + case CategoryEnum.Dessert: + this.averageCalories = 365 + break + } + this.totalCalories = this.averageCalories * 2 + this.highCalories = this.foodInfo.calories < this.averageCalories + } + + build() { + Column() { + CardTitle({ title: $r('app.string.diet_record_calorie'), subtitle: $r('app.string.unit_weight') }) + + Row() { + Text(this.foodInfo.calories.toString()) + .fontColor(this.getCalorieColor()) + .fontSize(65) + Text($r('app.string.calorie_with_kcal_unit', '')) + .fontSize(20) + .margin({ bottom: 10 }) + } + .margin({ top: 25, bottom: 25 }) + .alignItems(VerticalAlign.Bottom) + + Text(this.highCalories ? $r('app.string.high_calorie_food') : $r('app.string.low_calorie_food')) + .fontSize(13) + .fontColor('#313131') + + Progress({ value: this.foodInfo.calories, total: this.totalCalories, style: ProgressStyle.Linear }) + .style({ strokeWidth: 24 }) + .color(this.getCalorieColor()) + .margin({ top: 18 }) + } + .cardStyle() + } + + getCalorieColor() { + return this.highCalories ? $r('app.color.high_calorie') : $r('app.color.low_calorie') + } +} + +@Styles function cardStyle () { + .height('100%') + .padding({ top: 20, right: 20, left: 20 }) + .backgroundColor(Color.White) + .borderRadius(12) +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/card_title.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/card_title.ets" new file mode 100644 index 0000000000000000000000000000000000000000..f54f71846f02d3d4c6840dc381e5c403dce4afd9 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/card_title.ets" @@ -0,0 +1,19 @@ + +@Component +export struct CardTitle { + private title: Resource + private subtitle: Resource + + build() { + Row() { + Text(this.title) + .fontSize(26) + Blank() + Text(this.subtitle) + .fontSize(13) + .fontColor('rgba(0,0,0,0.6)') + } + .width('100%') + .height(26) + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/content_table.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/content_table.ets" new file mode 100644 index 0000000000000000000000000000000000000000..74f977a55f5a2a732f84acc7f1612fc029180e95 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/content_table.ets" @@ -0,0 +1,54 @@ +import { FoodInfo } from '../../model/DietType' + +@Preview +@Component +export struct ContentTable { + private foodInfo: FoodInfo + + aboutToAppear() { + console.log('xxx ContentTable') + console.log(JSON.stringify(this.foodInfo)) + } + + @Builder IngredientItem(title: Resource, colorValue: string, name: Resource, value: Resource) { + Row() { + Text(title) + .fontSize(18) + .fontWeight(FontWeight.Bold) + .layoutWeight(1) + .align(Alignment.Start) + Row() { + Circle({ width: 6, height: 6 }) + .margin({ right: 12 }) + .fill(colorValue) + Text(name) + .fontSize(18) + Blank() + Text(value) + .fontSize(18) + } + .width('100%') + .layoutWeight(2) + } + .margin({ bottom: 20 }) + } + + build() { + Column() { + this.IngredientItem($r('app.string.diet_record_calorie'), '#F54040', $r('app.string.diet_record_calorie'), $r('app.string.calorie_with_kcal_unit', this.foodInfo.calories.toString())) + Row().height(20) + this.IngredientItem($r('app.string.nutrition_element'), '#CCC', $r('app.string.nutrition_element'), $r('app.string.weight_with_gram_unit', this.foodInfo.protein.toString())) + this.IngredientItem(null, '#F5D640', $r('app.string.diet_record_fat'), $r('app.string.weight_with_gram_unit', this.foodInfo.fat.toString())) + this.IngredientItem(null, '#9E9EFF', $r('app.string.diet_record_carbohydrates'), $r('app.string.weight_with_gram_unit', this.foodInfo.carbohydrates.toString())) + this.IngredientItem(null, '#53F540', $r('app.string.diet_record_vitaminC'), $r('app.string.weight_with_milligram_unit', this.foodInfo.vitaminC.toString())) + } + .cardStyle() + } +} + +@Styles function cardStyle () { + .height('100%') + .padding({ top: 20, right: 20, left: 20 }) + .backgroundColor(Color.White) + .borderRadius(12) +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/dialog.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/dialog.ets" new file mode 100644 index 0000000000000000000000000000000000000000..dea899333f32f0f5a5ea4c745f921b53a9228921 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/dialog.ets" @@ -0,0 +1,89 @@ +import { FoodInfo } from '../../model/DietType' +import { MealTimeEnum } from '../../model/DietEnum' +import { getMileTimes } from '../../model/DataUtil' +import { DietRecord, MealTime } from '../../model/DataModels' + +@CustomDialog +export struct Record { + private foodInfo: FoodInfo + private controller: CustomDialogController + private select: number = 1 + private mileTime: string[] | Resource = getMileTimes() + private foodWeight: string[] = ['25', '50', '100', '150', '200', '250', '300', '350', '400', '450', '500'] + private mealTimeId: MealTimeEnum = MealTimeEnum.Lunch + private mealWeight: number = Number(this.foodWeight[this.select]) + + build() { + Column() { + Row({ space: 6 }) { + Column() { + Text(this.foodInfo.name) + .minFontSize(18) + .maxFontSize(30) + .maxLines(1) + Text($r('app.string.calorie_with_kcal_unit', this.foodInfo.calories.toString())) + .fontSize(16) + .fontColor('rgba(0,0,0,0.4)') + .margin({ top: 2 }) + } + .layoutWeight(1) + .justifyContent(FlexAlign.Center) + + TextPicker({ range: this.mileTime, selected: this.select }) + .layoutWeight(1) + .linearGradient({ + angle: 0, + direction: GradientDirection.Top, + colors: [[0xfdfdfd, 0.0], [0xe0e0e0, 0.5], [0xfdfdfd, 1]], + }) + .onChange((value: string, index: number) => { + console.log('xx 进餐类别:' + index) + this.mealTimeId = index + }) + + TextPicker({ range: this.foodWeight, selected: this.select }) + .layoutWeight(1) + .linearGradient({ + angle: 0, + direction: GradientDirection.Top, + colors: [[0xfdfdfd, 0.0], [0xe0e0e0, 0.5], [0xfdfdfd, 1]], + }) + .onChange((value: string) => { + console.log('xx 进餐重量:' + value) + this.mealWeight = Number(value) + }) + } + .height(128) + + Button($r('app.string.button_food_detail_complete'), { type: ButtonType.Capsule, stateEffect: true }) + .height(43) + .width('100%') + .margin({ top: 33, left: 72, right: 72 }) + .backgroundColor($r('app.color.theme_color_green')) + .onClick(() => { + let dietRecordsList = AppStorage.Get>('dietRecords') + if (dietRecordsList == undefined || dietRecordsList.length === 0) { +// dietRecordsList = initDietRecords + dietRecordsList = new Array() + } + let dietRecordData = new DietRecord(dietRecordsList.length, this.foodInfo.id, new MealTime(this.mealTimeId), this.mealWeight) + dietRecordsList.push(dietRecordData) + AppStorage.SetOrCreate>('dietRecords', dietRecordsList) + console.log('xx 记录' + JSON.stringify(dietRecordsList)) + this.controller.close() + }) + } + .cardStyle() + .height(254) + .width('90%') + } +} + + +@Styles function cardStyle() { + .height('100%') + .padding({ top: 20, right: 20, left: 20 }) + .backgroundColor(Color.White) + .borderRadius(12) +} + diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/food_image_display.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/food_image_display.ets" new file mode 100644 index 0000000000000000000000000000000000000000..9d74bb2d34c0c9a02f7faab4956b61e47b16a8ab --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/food_image_display.ets" @@ -0,0 +1,28 @@ +import { FoodInfo } from '../../model/DietType' +import curves from '@ohos.curves' + +@Preview +@Component +export struct FoodImageDisplay { + private foodInfo: FoodInfo + @State imageBgColorA: number = 0 + @StorageProp('currentBreakpoint') currentBreakpoint: string = 'sm' + + build() { + Stack({ alignContent: Alignment.BottomStart }) { + Image(this.foodInfo.image) + .sharedTransition(this.foodInfo.letter, { + duration: 400, + curve: curves.cubicBezier(0.2, 0.2, 0.1, 1.0), + delay: 100 + }) + .backgroundColor(`rgba(255, 255, 255, ${this.imageBgColorA})`) + .objectFit(ImageFit.Contain) + Text(this.foodInfo.name) + .fontSize(26) + .fontWeight(FontWeight.Bold) + .margin({ left: 26, bottom: 18 }) + } + .height(this.currentBreakpoint == 'lg' ? 166 : 280) + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/nutrition_percent.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/nutrition_percent.ets" new file mode 100644 index 0000000000000000000000000000000000000000..85707c5408d4bc2527e6968ad84f7bd3aa4d44fe --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/nutrition_percent.ets" @@ -0,0 +1,47 @@ +import { FoodInfo } from '../../model/DietType' +import { NutritionElement } from '../../model/DataModels' + +import { CardTitle } from './card_title' + +@Component +export struct NutritionPercent { + private foodInfo: FoodInfo + private nutritionElements: NutritionElement[] + + build() { + Column() { + CardTitle({ title: $r('app.string.nutrition_element'), subtitle: $r('app.string.unit_weight') }) + + Row() { + ForEach(this.nutritionElements, (item: NutritionElement) => { + Column() { + Stack({ alignContent: Alignment.Center }) { + Progress({ value: item.percent, type: ProgressType.Ring }) + .style({ strokeWidth: 10 }) + .color(item.color) + .margin(4) + Text(item.percent + '%').fontSize(17) + } + + Text(item.element) + .fontSize(13) + .margin({ top: 24 }) + Text($r('app.string.weight_with_gram_unit', item.weight.toString())) + .fontSize(13) + }.layoutWeight(1) + + }) + } + .width('100%') + .margin({ top: 50 }) + } + .cardStyle() + } +} + +@Styles function cardStyle () { + .height('100%') + .padding({ top: 20, right: 20, left: 20 }) + .backgroundColor(Color.White) + .borderRadius(12) +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/nutrition_pie_chart.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/nutrition_pie_chart.ets" new file mode 100644 index 0000000000000000000000000000000000000000..3e07fccfa9e7099ced0f8b8a0b702a14913936ee --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/nutrition_pie_chart.ets" @@ -0,0 +1,51 @@ +import { FoodInfo } from '../../model/DietType' +import { NutritionElement } from '../../model/DataModels' +import { CIRCLE_RADIUS } from '../../model/Constants' + +import { CardTitle } from './card_title' + +@Component +export struct NutritionPieChart { + private foodInfo: FoodInfo + private nutritionElements: NutritionElement[] + private settings: RenderingContextSettings = new RenderingContextSettings(true) + private context: CanvasRenderingContext2D = new CanvasRenderingContext2D(this.settings) + + build() { + Column() { + CardTitle({ title: $r('app.string.nutrition_element'), subtitle: $r('app.string.unit_weight') }) + Canvas(this.context) + .height(CIRCLE_RADIUS * 2) + .aspectRatio(1) + .margin({ top: 30, bottom: 32 }) + .onReady(() => { + this.nutritionElements.forEach((item) => { + this.context.beginPath() + this.context.moveTo(CIRCLE_RADIUS, CIRCLE_RADIUS) + this.context.arc(CIRCLE_RADIUS, CIRCLE_RADIUS, CIRCLE_RADIUS, item.beginAngle, item.endAngle) + this.context.fillStyle = item.color + this.context.fill() + }) + }) + Row() { + ForEach(this.nutritionElements, (item: NutritionElement) => { + Row({ space: 4 }) { + Circle({ width: 8, height: 8 }).fill(item.color) + Text(item.element).fontSize(12) + Text($r('app.string.weight_with_gram_unit', item.weight.toString())).fontSize(12) + } + }) + } + .width('100%') + .justifyContent(FlexAlign.SpaceAround) + } + .cardStyle() + } +} + +@Styles function cardStyle () { + .height('100%') + .padding({ top: 20, right: 20, left: 20 }) + .backgroundColor(Color.White) + .borderRadius(12) +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/page_title.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/page_title.ets" new file mode 100644 index 0000000000000000000000000000000000000000..33db84067c36812f4087a35efd537d3040b002d3 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/detail/page_title.ets" @@ -0,0 +1,22 @@ +import router from '@ohos.router'; + +@Component +export struct PageTitle { + private foodName: Resource = $r('app.string.title_food_detail') + + build() { + Row() { + Image($r('app.media.back')) + .width(20) + .height(20) + .onClick(() => { + router.back() + }) + Text(this.foodName) + .fontSize(22) + .margin({ left: 20 }) + } + .padding(12) + .width('100%') + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/foods_display.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/foods_display.ets" new file mode 100644 index 0000000000000000000000000000000000000000..acb455931ec35a38c9a9b866819455bfba52cc60 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/foods_display.ets" @@ -0,0 +1,29 @@ +import { CategoryModeFoods } from './grid/category_mode_foods' +import { ListModeFoods } from './list/list_mode_foods' + +@Component +export struct FoodsDisplay { + @State isCategoryMode: boolean = true + + build() { + Stack({ alignContent: Alignment.TopEnd }) { + if (this.isCategoryMode) { + CategoryModeFoods() + } else { + ListModeFoods() + } + Row() { + Image($r("app.media.ic_switch")) + .height(24) + .width(24) + .margin({ left: 24, right: 24 }) + } + .height(56) + .backgroundColor(this.isCategoryMode ? Color.White : '#F1F3F5') + .onClick(() => { + this.isCategoryMode = !this.isCategoryMode + }) + } + } +} + diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/category_mode_foods.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/category_mode_foods.ets" new file mode 100644 index 0000000000000000000000000000000000000000..bfe36b229e93a3ee67fe6b212237593a94e6b1a7 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/category_mode_foods.ets" @@ -0,0 +1,38 @@ +import { FoodInfo, Category } from '../../../model/DietType' +import { getFoods, getFoodCategories } from '../../../model/DataUtil' + +import { FoodGrid } from './food_grid' + +@Component +export struct CategoryModeFoods { + @State currentTabIndex: number = 0 + private foodItems: FoodInfo[] = getFoods() + private foodCategories: Category[] = getFoodCategories() + + @Builder tabBarItemBuilder(value: Resource, index: number) { + Text(value) + .fontColor(this.currentTabIndex === index ? 'rgba(0,0,0,0.9)' : 'rgba(0,0,0,0.6)') + .fontSize(this.currentTabIndex === index ? 24 : 18) + .margin({ top: 2 }) + .height(56) + } + + build() { + Tabs() { + TabContent() { + FoodGrid({ foodItems: this.foodItems }) + }.tabBar(this.tabBarItemBuilder($r('app.string.category_all'), 0)) + + ForEach(this.foodCategories, (foodCategory: Category, index) => { + TabContent() { + FoodGrid({ foodItems: this.foodItems.filter(item => (item.categoryId === foodCategory.id)) }) + }.tabBar(this.tabBarItemBuilder(foodCategory.name, index + 1)) + }) + } + .animationDuration(0) + .barMode(BarMode.Scrollable) + .onChange((index) => { + this.currentTabIndex = index + }) + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/food_grid.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/food_grid.ets" new file mode 100644 index 0000000000000000000000000000000000000000..d4181add19bde266ada4a076056b80ea04b58f4c --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/food_grid.ets" @@ -0,0 +1,26 @@ +import { FoodInfo } from '../../../model/DietType' +import { FoodGridItem } from './food_grid_item' + +@Component +export struct FoodGrid { + private foodItems: FoodInfo[] + + aboutToAppear() { + console.log('xx FoodGrid') + console.log(JSON.stringify(this.foodItems)); + } + + build() { + Grid() { + ForEach(this.foodItems, (fItem: FoodInfo) => { + GridItem() { + FoodGridItem({ foodItem: fItem }) + } + }) + } + .columnsTemplate("1fr 1fr") + .columnsGap(8) + .rowsGap(8) + .padding({ left: 16, right: 16 }) + } +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/food_grid_item.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/food_grid_item.ets" new file mode 100644 index 0000000000000000000000000000000000000000..b3d65df8cea8d321defcb9dcaf82664b5d9c7b7e --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/grid/food_grid_item.ets" @@ -0,0 +1,45 @@ +import router from '@ohos.router'; +import curves from '@ohos.curves'; +import { FoodInfo } from '../../../model/DietType' + +@Component +export struct FoodGridItem { + private foodItem: FoodInfo + + + aboutToAppear() { + console.log('xx FoodGridItem') + console.log(JSON.stringify(this.foodItem)); + } + + build() { + Column() { + Image(this.foodItem.image) + .objectFit(ImageFit.Contain) + .backgroundColor('#f1f3f5') + .height(152) + .sharedTransition(this.foodItem.letter, { + duration: 400, + curve: curves.cubicBezier(0.2, 0.2, 0.1, 1.0), + delay: 100 + }) + Row() { + Text(this.foodItem.name) + .fontSize(14) + Blank() + Text($r('app.string.calorie_with_kcal_unit', this.foodItem.calories.toString())) + .fontSize(14) + .fontColor(0x99000000) + } + .padding({ left: 12, right: 12 }) + .width('100%') + .height(32) + .backgroundColor('#E5E5E5') + } + .height(184) + .clip(new Rect({ width: '100%', height: '100%', radius: 12 })) + .onClick(() => { + router.push({ url: 'pages/FoodDetail', params: { foodId: this.foodItem } }) + }) + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/list/food_list_item.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/list/food_list_item.ets" new file mode 100644 index 0000000000000000000000000000000000000000..f8ad0a7ad75f87387c11b8fa9ece6101db7841c0 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/list/food_list_item.ets" @@ -0,0 +1,36 @@ +import curves from '@ohos.curves' +import { FoodInfo } from '../../../model/DietType' + +@Component +export struct FoodListItem { + private foodItem: FoodInfo + + build() { + Navigator({ target: 'pages/FoodDetail' }) { + Row() { + Image(this.foodItem.image) + .objectFit(ImageFit.Contain) + .autoResize(false) + .height(40) + .width(40) + .backgroundColor('#FFf1f3f5') + .margin({ right: 16 }) + .borderRadius(6) + .sharedTransition(this.foodItem.letter, { + duration: 400, + curve: curves.cubicBezier(0.2, 0.2, 0.1, 1.0), + delay: 100 + }) + Text(this.foodItem.name) + .fontSize(14) + Blank() + Text($r('app.string.calorie_with_kcal_unit', this.foodItem.calories.toString())) + .fontSize(14) + } + .height(64) + .width('100%') + } + .params({ foodId: this.foodItem }) + .margin({ right: 24, left: 32 }) + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/list/list_mode_foods.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/list/list_mode_foods.ets" new file mode 100644 index 0000000000000000000000000000000000000000..9011f67347cf8d016453282bccdb93fa396f99ba --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/home/list/list_mode_foods.ets" @@ -0,0 +1,36 @@ +import { FoodInfo } from '../../../model/DietType' +import { getSortedFoodData } from '../../../model/DataUtil' +import { FoodListItem } from './food_list_item' + +@Component +export struct ListModeFoods { + private foodItems: FoodInfo[] = getSortedFoodData() + + build() { + Column() { + Text($r("app.string.title_food_list")) + .width('100%') + .height(56) + .padding({ left: 20 }) + .backgroundColor('#FF1f3f5') + .fontSize(20) + + List() { + ForEach(this.foodItems, (item) => { + ListItem() { + if (item.letter !== undefined) { + FoodListItem({ foodItem: item }) + } else { + Text(item) + .fontSize(14) + .height(48) + .margin({ left: 24 }) + .width('100%') + } + } + }) + } + .layoutWeight(1) + } + } +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/custom_counter.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/custom_counter.ets" new file mode 100644 index 0000000000000000000000000000000000000000..f7b6c1b2cb61bc4866f0a4324c29e9c9582302bc --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/custom_counter.ets" @@ -0,0 +1,78 @@ +/** + * 减按钮组件 + */ +@Preview +@Component +struct DecIcon { + // 减按钮事件 + private click: () => void = undefined + + build() { + Stack() { + Line() + .startPoint([0, 0]) + .endPoint([12, 0]) + .stroke(Color.White) + .strokeWidth(2) + .strokeLineCap(LineCapStyle.Round) + } + .borderRadius(10) + .backgroundColor('#35BD6A') + .width(20) + .height(20) + .opacity(0.6) + .onClick(() => { + this.click() + }) + } +} +/** + * 加按钮组件 + */ +@Preview +@Component +struct IncIcon { + private readonly click: () => void = undefined + + build() { + Stack() { + Line() + .startPoint([0, 0]) + .endPoint([12, 0]) + .stroke(Color.White) + .strokeWidth(2) + .strokeLineCap(LineCapStyle.Round) + Line() + .startPoint([0, 0]) + .endPoint([0, 12]) + .stroke(Color.White) + .strokeWidth(2) + .strokeLineCap(LineCapStyle.Round) + } + .borderRadius(10) + .backgroundColor('#35BD6A') + .width(20) + .height(20) + .onClick(() => { + this.click() + }) + } +} + +/** + * 自定义计算组件 + */ +@Component +export struct CustomCounter { + @Prop value: string + private onDec: () => void = undefined + private onInc: () => void = undefined + + build() { + Row() { + DecIcon({ click: this.onDec }) + Text(this.value).margin({ left: 11, right: 11 }) + IncIcon({ click: this.onInc }) + } + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/heat_histogram_content.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/heat_histogram_content.ets" new file mode 100644 index 0000000000000000000000000000000000000000..6a617f5ff90c99e5815712e627e8905b4b64279d --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/heat_histogram_content.ets" @@ -0,0 +1,43 @@ +import { HistogramLegend } from '../../../model/DataModels' +import { Histogram } from './histogram' + +@Component +export struct HeatHistogramContent { + private legend: HistogramLegend[] = [ + new HistogramLegend('#FD9A42', $r("app.string.high_calorie")), + new HistogramLegend('#73CD57', $r("app.string.medium_low_calories")), + ] + + @Builder legendComponent(item) { + Text(item.value).fontSize(12).fontColor('#18181A').fontFamily('HarmonyHeTi') + } + + @Builder content(item) { + Column() { + Rect({ width: 14, height: item.totalCalories / 1000 + 14, radius: 14 }) + .fill(GetColor(item.totalCalories)) + .padding({ top: 7 }) + .margin({ bottom: -7 }) + } + .clip(true) + } + + build() { + Row() { + Histogram({ + title: $r("app.string.diet_record_calorie"), + content: this.content, + legend: this.legend, + legendComponent: this.legendComponent + }) + } + } +} + +function GetColor(value: number): Resource { + if (value / 1000 > 100) { + return $r("app.color.theme_color_orange") + } else { + return $r("app.color.theme_color_green") + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/histogram.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/histogram.ets" new file mode 100644 index 0000000000000000000000000000000000000000..6cc815bc13b9b66524b5085c01d145d436e60688 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/histogram.ets" @@ -0,0 +1,72 @@ +import { HistogramLegend, OneMealStatisticsInfo } from '../../../model/DataModels' + +@Component +export struct Histogram { + @Consume("dietData") dietData: Array + @BuilderParam content: any + @BuilderParam legendComponent: any + private title: string | Resource + private legend: HistogramLegend[] + + build() { + Column() { + Text(this.title) + .textAlign(TextAlign.Start) + .fontSize(24) + .fontColor('#000000') + .fontFamily('HarmonyHeTi-Medium') + .width('100%') + .height(46) + + Stack({ alignContent: Alignment.Bottom }) { + Column() { + ForEach(new Array(6), (item) => { + Divider() + .strokeWidth(1) + .color('#D8D8D8') + }) + } + .height('100%') + .margin({ top: 20 }) + .justifyContent(FlexAlign.SpaceBetween) + + Column() { + Flex({ direction: FlexDirection.Row, justifyContent: FlexAlign.SpaceEvenly, alignItems: ItemAlign.Start }) { + ForEach(this.dietData, (item: OneMealStatisticsInfo) => { + if (item.mealFoods.length > 1) { + Column() { + this.content(item) + Text(item.mealTime.name).fontSize(14) + .fontColor('#7E7E7E') + .fontFamily('HarmonyHeTi') + .margin({ top: 10 }) + } + .justifyContent(FlexAlign.End) + .height('100%') + } + }) + } + } + .height(236) + } + .height(190) + + Row() { + ForEach(this.legend, item => { + Row() { + Rect({ width: 9, height: 9, radius: 9 }).fill(item.color).margin({ right: 18 }) + this.legendComponent(item) + } + }) + } + .justifyContent(FlexAlign.SpaceEvenly) + .width('100%') + .margin({ top: 70 }) + } + .height('100%') + .padding({ left: 32, right: 32 }) + .borderRadius(12) + .backgroundColor('#FFFFFF') + } +} + diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/meal_card.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/meal_card.ets" new file mode 100644 index 0000000000000000000000000000000000000000..a6edb78307307394d5a446da1017c4c288961016 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/meal_card.ets" @@ -0,0 +1,119 @@ +import { OneMealStatisticsInfo } from '../../../model/DataModels' +import { MealFoodInfo } from '../../../model/DataModels' +import { updateDietWeight } from '../../../model/DataUtil' + +import { CustomCounter } from './custom_counter' + +@Component +export struct MealCard { + @ObjectLink mealInfo: OneMealStatisticsInfo + + build() { + Column() { + if (this.mealInfo.mealFoods.length > 1) { + // 标题(早餐、午餐、晚餐、宵夜) + Text(this.mealInfo.mealTime.name) + .fontSize(24) + .fontFamily('HarmonyHeTi-Medium') + .height(56) + .width('100%') + .backgroundColor('#FFFFFF') + .padding({ left: 16, right: 16 }) + // 用餐食物(草莓、甜点、核桃.....) + ForEach(this.mealInfo.mealFoods, (mealItem) => { + // 饮食详情 + MealFoodDetail({ mealFoodInfo: mealItem }) + }) + } + } + .backgroundColor(Color.White) + .borderRadius(12) + .padding({ left: 16, right: 16 }) + .margin(12) + } +} + + +@Component +struct MealFoodDetail { + @Consume("dataChange") notifyDataChange: number + @State shown: boolean = true + @State translateX: number = 0 + private mealFoodInfo: MealFoodInfo + + aboutToAppear() { + console.log('xx '+JSON.stringify(this.mealFoodInfo)) + } + + build() { + if (this.shown) { + if (this.mealFoodInfo.weight != 0) { + Row() { + Row() { + Image(this.mealFoodInfo.image) + .width(50) + .height(50) + Column() { + Text(this.mealFoodInfo.name) + .fontSize(16) + .fontColor('#444444') + .fontFamily('HarmonyHeTi') + .margin({ bottom: 4 }) + Text($r('app.string.calorie_with_kcal_unit', (this.mealFoodInfo.calories / 100).toString())) + .fontSize(11) + .fontColor('#A3A3A3') + .fontFamily('HarmonyHeTi') + }.alignItems(HorizontalAlign.Start) + + Blank() + CustomCounter({ + value: this.mealFoodInfo.weight + 'g', + onDec: () => { + if (this.mealFoodInfo.weight > 0) { + this.mealFoodInfo.weight -= 50 + updateDietWeight(this.mealFoodInfo.recordId, this.mealFoodInfo.weight) + this.notifyDataChange++ + } + }, + onInc: () => { + this.mealFoodInfo.weight += 50 + updateDietWeight(this.mealFoodInfo.recordId, this.mealFoodInfo.weight) + this.notifyDataChange++ + } + }) + } + .width('100%') + + Image($r("app.media.ic_public_delete")) + .backgroundColor('#E84026') + .objectFit(ImageFit.ScaleDown) + .borderRadius(20) + .margin({ left: 50 }) + .size({ width: 40, height: 40 }) + .onClick(() => { + animateTo({ duration: 400 }, () => { + this.shown = false + }) + }) + } + .transition({ type: TransitionType.Delete, translate: { x: -350, y: 0 }, opacity: 0 }) + .translate({ x: this.translateX }) + .width('100%') + .height(70) + .gesture( + PanGesture() + .onActionUpdate((event: GestureEvent) => { + if (event.offsetX < 0) { + if (event.offsetX < -100) { + this.translateX = (event.offsetX * Math.exp(-1.848)) - 100 + } else { + this.translateX = event.offsetX + } + } + }) + ) + } + } + } +} + diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/nutrition_histogram_content.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/nutrition_histogram_content.ets" new file mode 100644 index 0000000000000000000000000000000000000000..488fd0423b6df33d2aea8d4bb2ee2ebca9e17e77 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/detail/nutrition_histogram_content.ets" @@ -0,0 +1,47 @@ +import { HistogramLegend } from '../../../model/DataModels' +import { Histogram } from './histogram' + +@Component +export struct NutritionHistogramContent { + private legend: HistogramLegend[] = [ + new HistogramLegend('#FFD339', $r("app.string.diet_record_fat")), + new HistogramLegend('#FD9A42', $r("app.string.diet_record_protein")), + new HistogramLegend('#73CD57', $r("app.string.diet_record_carbohydrates")) + ] + + @Builder legendComponent(item: HistogramLegend) { + Text(item.value).fontSize(12).fontColor('#18181A').fontFamily('HarmonyHeTi') + } + + @Builder content(item) { + Column() { + if (item.totalFat > 0) { + Rect({ width: 14, height: item.totalFat / 200 + 14, radius: 7 }).fill('#FD9A42') + .padding({ top: 14 }) + .margin({ bottom: -28 }) + } + if (item.totalProtein > 0) { + Rect({ width: 14, height: item.totalProtein / 200 + 14, radius: 7 }) + .fill('#FBD44E') + .padding({ top: 14 }) + .margin({ bottom: -21 }) + } + if (item.totalCarbohydrates > 0) { + Rect({ width: 14, height: item.totalCarbohydrates / 200 + 14, radius: 7 }).fill('#73CD57') + .padding({ top: 7 }) + .margin({ bottom: -7 }) + } + }.clip(true) + } + + build() { + Row() { + Histogram({ + title: $r("app.string.nutrition_element"), + content: this.content, + legend: this.legend, + legendComponent: this.legendComponent + }) + } + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/diet_details.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/diet_details.ets" new file mode 100644 index 0000000000000000000000000000000000000000..d5d84301eb9f760d12da74a6344992814a3aa292 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/diet_details.ets" @@ -0,0 +1,40 @@ +import { OneMealStatisticsInfo } from '../../model/DataModels' + +import { HeatHistogramContent } from './detail/heat_histogram_content' +import { NutritionHistogramContent } from './detail/nutrition_histogram_content' +import { MealCard } from './detail/meal_card' + +@Component +export struct DietDetails { + // 关联父组件Provide提供的数据 + @Consume("dietData") dietData: Array + // 当前设备尺寸模式 + @StorageProp('currentBreakpoint') currentBreakpoint: string = 'sm' + + build() { + Scroll() { + Column() { + Swiper() { + // 热量图表 + HeatHistogramContent() + // 营养元素图表 + NutritionHistogramContent() + } + .itemSpace(12) + .height(400) + .width('100%') + .indicatorStyle({ selectedColor: $r('app.color.theme_color_green') }) + // 是否启用导航点指示器 + .indicator(true) + // 设置导航点样式 + .displayCount(1) + + ForEach(this.dietData, (item) => { + // 饮食卡片 + MealCard({ mealInfo: item }) + }) + } + } + .backgroundColor('#EDF2F5') + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/diet_record.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/diet_record.ets" new file mode 100644 index 0000000000000000000000000000000000000000..bafa8a3d48539ebc00fe2d04017422b630f3a9aa --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/diet_record.ets" @@ -0,0 +1,32 @@ +import { statistics } from '../../model/DataUtil' +import { OneMealStatisticsInfo, DietRecord } from '../../model/DataModels' + +import { NoRecord } from './no_record' +import { DietDetails } from './diet_details' + +@Component +export struct Records { + @StorageLink('dietRecords') @Watch('onDataChange') dietRecords: Array = [] + @Provide("dietData") dietStatisticsData: Array = [] + @Provide("dataChange") @Watch('onDataChange') listenDataChange: number = 0 + + onDataChange() { + console.log('xx Records onDataChange') + this.dietStatisticsData = statistics() + } + + aboutToAppear() { + console.log('xx Records aboutToAppear') + this.dietStatisticsData = statistics() + } + + build() { + Column() { + if (this.dietStatisticsData.length === 0) { + NoRecord() + } else { + DietDetails() + } + } + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/no_record.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/no_record.ets" new file mode 100644 index 0000000000000000000000000000000000000000..19232fbfc0a986305aef145610a39c669c90fe8b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/components/record/no_record.ets" @@ -0,0 +1,26 @@ +/** + * 无记录组件 + */ +@Component +export struct NoRecord { + build() { + Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Start }) { + // 标题 + Text($r("app.string.title_record")) + .fontSize(26) + .padding({ left: 26, top: 12 }) + Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Center, justifyContent: FlexAlign.Center }) { + // 无记录图片 + Image($r("app.media.norecord")) + .height(130) + .width(130) + // 无记录描述 + Text($r("app.string.no_record_content")) + .fontSize(15) + .fontColor('rgba(0, 0,0,0.4)') + } + .width('100%') + } + .width('100%') + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/entryability/EntryAbility.ts" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/entryability/EntryAbility.ts" new file mode 100644 index 0000000000000000000000000000000000000000..a548a4a610b5dd2da5ff1fa5173e9d21ccb88d97 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/entryability/EntryAbility.ts" @@ -0,0 +1,51 @@ +import hilog from '@ohos.hilog'; +import Ability from '@ohos.application.Ability' +import Window from '@ohos.window' + +export default class EntryAbility extends Ability { + onCreate(want, launchParam) { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onCreate'); + hilog.info(0x0000, 'testTag', '%{public}s', 'want param:' + JSON.stringify(want) ?? ''); + hilog.info(0x0000, 'testTag', '%{public}s', 'launchParam:' + JSON.stringify(launchParam) ?? ''); + } + + onDestroy() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onDestroy'); + } + + onWindowStageCreate(windowStage: Window.WindowStage) { + // Main window is created, set main page for this ability + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onWindowStageCreate'); + + windowStage.loadContent('pages/Index', (err, data) => { + if (err.code) { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.ERROR); + hilog.error(0x0000, 'testTag', 'Failed to load the content. Cause: %{public}s', JSON.stringify(err) ?? ''); + return; + } + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', 'Succeeded in loading the content. Data: %{public}s', JSON.stringify(data) ?? ''); + }); + } + + onWindowStageDestroy() { + // Main window is destroyed, release UI related resources + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onWindowStageDestroy'); + } + + onForeground() { + // Ability has brought to foreground + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onForeground'); + } + + onBackground() { + // Ability has back to background + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'Ability onBackground'); + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/Constants.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/Constants.ets" new file mode 100644 index 0000000000000000000000000000000000000000..312def3d3250f9c7ece3018ac7e91615d65add7f --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/Constants.ets" @@ -0,0 +1,4 @@ +/** + * 圆半径常量 + */ +export let CIRCLE_RADIUS: number = 80 diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DataModels.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DataModels.ets" new file mode 100644 index 0000000000000000000000000000000000000000..42b614a02624815f01c787c24bfe0df820e8f275 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DataModels.ets" @@ -0,0 +1,118 @@ +import { MealTimeEnum } from './DietEnum' + + +/** + * 用餐实体类 + */ +export class MealTime { + name: Resource + id: MealTimeEnum + + constructor(id: MealTimeEnum) { + this.id = id + switch (id) { + case MealTimeEnum.Breakfast: + this.name = $r('app.string.meal_time_breakfast') + break + case MealTimeEnum.Lunch: + this.name = $r('app.string.meal_time_lunch') + break + case MealTimeEnum.Dinner: + this.name = $r('app.string.meal_time_dinner') + break + case MealTimeEnum.Supper: + this.name = $r('app.string.meal_time_supper') + break + } + } +} + +/** + * 饮食记录实体类 + */ +export class DietRecord { + id: number + foodId: number + mealTime: MealTime + weight: number + + constructor(id: number, foodId: number, mealTime: MealTime, weight: number) { + this.id = id + this.foodId = foodId + this.mealTime = mealTime + this.weight = weight + } +} + +/** + * 用餐统计信息 + */ +@Observed +export class OneMealStatisticsInfo { + mealTime: MealTime + mealFoods: Array = [] + totalCalories: number = 0 + totalFat: number = 0 + totalCarbohydrates: number = 0 + totalProtein: number = 0 + + constructor(mealTime: MealTime) { + this.mealTime = mealTime + } +} + +/** + * 餐饮信息 + */ +export class MealFoodInfo { + recordId: number + name: string | Resource + image: Resource + calories: number + protein: number + fat: number + carbohydrates: number + weight: number + + constructor(recordId: number, name: string | Resource, image: Resource, calories: number, protein: number, fat: number, carbohydrates: number, weight: number) { + this.recordId = recordId + this.name = name + this.image = image + this.calories = calories + this.protein = protein + this.fat = fat + this.carbohydrates = carbohydrates + this.weight = weight + } +} + +/** + * 营养元素实体类 + */ +export class NutritionElement { + element: Resource + weight: number + percent: number + beginAngle: number + endAngle: number + color: string + + constructor(element: Resource, weight: number, color: string) { + this.element = element + this.weight = weight + this.color = color + } +} + +/** + * 柱状图实体类 + */ +export class HistogramLegend { + public color: string + public value: Resource + + constructor(color: string, value: Resource) { + this.color = color + this.value = value + } +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DataUtil.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DataUtil.ets" new file mode 100644 index 0000000000000000000000000000000000000000..a75957aaf541375aafef2f2b5085e1ce5124f29b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DataUtil.ets" @@ -0,0 +1,194 @@ +import router from '@ohos.router' + +import { mockFoods } from './MockData' + +import { FoodInfo, Category } from './DietType' +import { MealTimeEnum, CategoryEnum } from './DietEnum' +import { DietRecord, OneMealStatisticsInfo, MealFoodInfo } from './DataModels' + +// 调试时,可以指定模拟数据 +const DEBUG_PREVIEW = false +const MOCK_API = false + +/** + * 获取模拟数据数组 + * 此处可以通过http获取远程服务器数据 + */ +export function getFoods(): Array { + return mockFoods +} + +/** + * 获取单个食物信息 + */ +export function getFoodInfo(): FoodInfo { + return router.getParams()['foodId'] +// return DEBUG_PREVIEW ? mockFoodInfo : router.getParams()['foodId'] +} + +/** + * 按用餐时间做记录 + */ +export let initDietRecords: Array = [ + { + id: -1, + foodId: 0, + mealTime: { name: $r('app.string.meal_time_breakfast'), id: MealTimeEnum.Breakfast }, + weight: 0 + }, + { + id: -1, + foodId: 0, + mealTime: { name: $r('app.string.meal_time_lunch'), id: MealTimeEnum.Lunch }, + weight: 0 + }, + { + id: -1, + foodId: 0, + mealTime: { name: $r('app.string.meal_time_dinner'), id: MealTimeEnum.Dinner }, + weight: 0 + }, + { + id: -1, + foodId: 0, + mealTime: { name: $r('app.string.meal_time_supper'), id: MealTimeEnum.Supper }, + weight: 0 + }] + +/** + * 获取饮食记录集 + */ +export function getDietRecords(): Array { + // 如果是调试在初始化记录上追加模拟记录数据,否则从AppStorage获取 +// return DEBUG_PREVIEW ? initDietRecords.concat(mockDietRecords) : AppStorage.Get>('dietRecords') + return AppStorage.Get>('dietRecords') +} + +/** + * 获取食物类别数组 + */ +export function getFoodCategories(): Category[] { + return [{ id: CategoryEnum.Vegetable, name: $r('app.string.category_vegetable') }, + { id: CategoryEnum.Fruit, name: $r('app.string.category_fruit') }, + { id: CategoryEnum.Nut, name: $r('app.string.category_nut') }, + { id: CategoryEnum.Seafood, name: $r('app.string.category_seafood') }, + { id: CategoryEnum.Dessert, name: $r('app.string.category_dessert') }] +} + +/** + * 获取用餐类别 + */ +export function getMileTimes(): string[] | Resource { + if (MOCK_API) { + return ['早餐', '午餐', '晚餐', '夜宵'] + } else { + return $r('app.strarray.mealTime_labels') + } +} + +/** + * 获取排序食品数据 + */ +export function getSortedFoodData(): Array { + var letterReg = /^[A-Z]$/ + var list = new Array() + var foods = getFoods() + for (var i = 0;i < foods.length; i++) { + list['#'] = new Array() + // 将第一个字母转换为大写 + var letter = foods[i].letter.substr(0, 1).toUpperCase() + if (!letterReg.test(letter)) { + letter = '#' + } + // 按字母创建组 + if (!(letter in list)) { + list[letter] = new Array() + } + list[letter].push(foods[i]) + } + + // 按字母顺序排序 + var letterGroup = new Array() + for (var key in list) { + letterGroup.push({ + letter: key, + list: list[key] + }) + } + letterGroup.sort(function (x, y) { + return x.letter.charCodeAt(0) - y.letter.charCodeAt(0) + }) + + // 将“#”放在最后 + var lastArr = letterGroup[0] + letterGroup.splice(0, 1) + letterGroup.push(lastArr) + + // 创建结果列表 + var resultList = [] + for (var i = 0; i < letterGroup.length; i++) { + resultList.push(letterGroup[i].letter) + resultList = resultList.concat(letterGroup[i].list) + } + return resultList +} + +export function statistics(): Array { + console.info('膳食统计') + // 获取饮食总记录数据 + let dietRecords = getDietRecords() + // 创建一个Map对象 + const mealMap = new Map() + dietRecords.forEach((item) => { + // 获取用餐时段(早餐,午餐,晚餐,宵夜),总卡路里,总脂肪,总碳水,总蛋白质 + let oneMealStatisticsInfo: OneMealStatisticsInfo = mealMap.get(item.mealTime.id) + if (oneMealStatisticsInfo === undefined) { + // 如果之前没有缓存,创建一个用餐统计信息 + oneMealStatisticsInfo = new OneMealStatisticsInfo(item.mealTime) + } + // 与模拟数据匹配出饮食了哪些食物 + var foodInfo = getFoods().find((food) => { + return food.id === item.foodId + }) + // 统计卡路里 + var calories = Math.round(foodInfo.calories * item.weight) + // 统计蛋白质 + var protein = Math.round(foodInfo.protein * item.weight) + // 统计脂肪 + var fat = Math.round(foodInfo.fat * item.weight) + // 统计碳水 + var carbohydrates = Math.round(foodInfo.carbohydrates * item.weight) + // 把食物信息保存在用餐食物属性里 + oneMealStatisticsInfo.mealFoods.push(new MealFoodInfo(item.id, foodInfo.name, foodInfo.image, calories, protein, fat, carbohydrates, item.weight)) + // 赋值统计脂肪 + oneMealStatisticsInfo.totalFat += fat + // 赋值统计卡路里 + oneMealStatisticsInfo.totalCalories += calories + // 赋值统计碳水 + oneMealStatisticsInfo.totalCarbohydrates += carbohydrates + // 赋值统计蛋白质 + oneMealStatisticsInfo.totalProtein += protein + // 使用早餐,午餐,晚餐,宵夜Id为Key,单餐统计信息为Value + mealMap.set(item.mealTime.id, oneMealStatisticsInfo) + }) + // 返回数据 + return Array.from(mealMap.values()) +} + +/** + * 更新饮食重量 + * @param recordId + * @param weight + */ +export function updateDietWeight(recordId: number, weight: number) { + // 获取饮食记录集 + let dietRecords = getDietRecords() + // 从饮食记录集匹配出参数记录Id的下标 + let index = dietRecords.findIndex((record) => { + return record.id === recordId + }) + // 根据下标更新饮食记录 + dietRecords[index].weight = weight + // 更新后的包含记录保存到AppStorage + AppStorage.SetOrCreate>('dietRecords', dietRecords) +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DietEnum.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DietEnum.ets" new file mode 100644 index 0000000000000000000000000000000000000000..6d09f4e49b2208d7e212a6c913e97d9b7af47b60 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DietEnum.ets" @@ -0,0 +1,21 @@ + +/** + * 类别枚举 + */ +export enum CategoryEnum { + Fruit = 0, // 水果 + Vegetable = 1, // 蔬菜 + Nut = 2, // 坚果 + Seafood = 3, // 海鲜 + Dessert= 4 // 甜点 +} + +/** + * 用餐枚举 + */ +export enum MealTimeEnum { + Breakfast = 0, // 早餐 + Lunch = 1, // 午餐 + Dinner = 2, // 晚餐 + Supper = 3 // 宵夜 +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DietType.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DietType.ets" new file mode 100644 index 0000000000000000000000000000000000000000..041390b3820398bb89c563de3f16ca448ffe1bea --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/DietType.ets" @@ -0,0 +1,26 @@ +import { CategoryEnum } from './DietEnum' + +/** + * 类别 + */ +export type Category = { + name: Resource + id: CategoryEnum +} + +/** + * 食物信息 + */ +export type FoodInfo = { + id: number + letter: string + name: string | Resource + image: Resource + categoryId: CategoryEnum + calories: number + protein: number + fat: number + carbohydrates: number + vitaminC: number +} + diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/MockData.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/MockData.ets" new file mode 100644 index 0000000000000000000000000000000000000000..e5a2f8fc5c42e6942c1b1f42d74f60eed04f25fd --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/MockData.ets" @@ -0,0 +1,199 @@ +import { FoodInfo } from './DietType' +import { CategoryEnum, MealTimeEnum } from './DietEnum' +import { DietRecord } from './DataModels' + +/** + * 模拟食物信息数组 + */ +export let mockFoods: Array = [ + { + id: 0, + letter: 'Tomato', + name: $r('app.string.food_name_tomato'), + image: $r('app.media.tomato'), + categoryId: CategoryEnum.Vegetable, + calories: 15, + protein: 0.9, + fat: 0.2, + carbohydrates: 3.3, + vitaminC: 14.0 + }, + { + id: 1, + letter: 'Walnut', + name: $r('app.string.food_name_walnut'), + image: $r('app.media.walnut'), + categoryId: CategoryEnum.Nut, + calories: 646, + protein: 14.9, + fat: 58.8, + carbohydrates: 19.1, + vitaminC: 1.0 + }, + { + id: 2, + letter: 'Cucumber', + name: $r('app.string.food_name_cucumber'), + image: $r('app.media.cucumber'), + categoryId: CategoryEnum.Vegetable, + calories: 16, + protein: 0.8, + fat: 0.2, + carbohydrates: 2.9, + vitaminC: 9.0 + }, + { + id: 3, + letter: 'Blueberry', + name: $r('app.string.food_name_blueberry'), + image: $r('app.media.blueberry'), + categoryId: CategoryEnum.Fruit, + calories: 57, + protein: 0.7, + fat: 0.3, + carbohydrates: 14.5, + vitaminC: 9.7 + }, + { + id: 4, + letter: 'Crab', + name: $r('app.string.food_name_crab'), + image: $r('app.media.crab'), + categoryId: CategoryEnum.Seafood, + calories: 97, + protein: 19, + fat: 1.5, + carbohydrates: 0, + vitaminC: 7.6 + }, + { + id: 5, + letter: 'IceCream', + name: $r('app.string.food_name_ice_cream'), + image: $r('app.media.icecream'), + categoryId: CategoryEnum.Dessert, + calories: 150, + protein: 3.5, + fat: 11, + carbohydrates: 24, + vitaminC: 0.6 + }, + { + id: 6, + letter: 'Onion', + name: $r('app.string.food_name_onion'), + image: $r('app.media.onion'), + categoryId: CategoryEnum.Vegetable, + calories: 40, + protein: 1.1, + fat: 0.2, + carbohydrates: 9, + vitaminC: 8.0 + }, + { + id: 7, + letter: 'Mushroom', + name: $r('app.string.food_name_mushroom'), + image: $r('app.media.mushroom'), + categoryId: CategoryEnum.Vegetable, + calories: 20, + protein: 3.1, + fat: 0.3, + carbohydrates: 3.3, + vitaminC: 206 + }, + { + id: 8, + letter: 'Kiwi', + name: $r('app.string.food_name_kiwi'), + image: $r('app.media.kiwi'), + categoryId: CategoryEnum.Fruit, + calories: 61, + protein: 0.8, + fat: 0.6, + carbohydrates: 14.5, + vitaminC: 62 + }, + { + id: 9, + letter: 'Pitaya', + name: $r('app.string.food_name_pitaya'), + image: $r('app.media.pitaya'), + categoryId: CategoryEnum.Fruit, + calories: 55, + protein: 1.1, + fat: 0.2, + carbohydrates: 13.3, + vitaminC: 3.0 + }, + { + id: 10, + letter: 'Avocado', + name: $r('app.string.food_name_avocado'), + image: $r('app.media.avocado'), + categoryId: CategoryEnum.Fruit, + calories: 171, + protein: 2.0, + fat: 15.3, + carbohydrates: 7.4, + vitaminC: 8.0 + }, + { + id: 11, + letter: 'Strawberry', + name: $r('app.string.food_name_strawberry'), + image: $r('app.media.strawberry'), + categoryId: CategoryEnum.Fruit, + calories: 32, + protein: 1.0, + fat: 0.2, + carbohydrates: 7.1, + vitaminC: 47.0 + } +] + +/** + * 模拟食物信息 + */ +export let mockFoodInfo: FoodInfo = { + id: 0, + letter: 'Tomato', + name: $r('app.string.food_name_tomato'), + image: $r('app.media.tomato'), + categoryId: CategoryEnum.Vegetable, + calories: 15, + protein: 0.9, + fat: 0.2, + carbohydrates: 3.3, + vitaminC: 14.0 +} + +/** + * 模拟饮食记录 + */ +export let mockDietRecords: Array = [ + { + id: 1, + foodId: 2, + mealTime: { name: $r('app.string.meal_time_dinner'), id: MealTimeEnum.Dinner }, + weight: 200 + }, + { + id: 2, + foodId: 8, + mealTime: { name: $r('app.string.meal_time_dinner'), id: MealTimeEnum.Dinner }, + weight: 200 + }, + { + id: 3, + foodId: 6, + mealTime: { name: $r('app.string.meal_time_lunch'), id: MealTimeEnum.Lunch }, + weight: 200 + }, + { + id: 4, + foodId: 3, + mealTime: { name: $r('app.string.meal_time_dinner'), id: MealTimeEnum.Dinner }, + weight: 200 + } +] \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/Model.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/Model.ets" new file mode 100644 index 0000000000000000000000000000000000000000..5264b3558b41448e34058001f3b88a0880d87e68 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/model/Model.ets" @@ -0,0 +1,11 @@ +/** + * 底部导航栏Icon数据 + */ +export function getIconPath(): Array { + let IconPath: Array = ['nav/index.png','nav/statisticsgray.png'] + return IconPath; +} +export function getIconPathSelect(): Array { + let IconPathSelect: Array = ['nav/indexgray.png','nav/statistics.png'] + return IconPathSelect; +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/pages/FoodDetail.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/pages/FoodDetail.ets" new file mode 100644 index 0000000000000000000000000000000000000000..80ecb48ffb1328232e3c1128ed47282ad02b53c0 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/pages/FoodDetail.ets" @@ -0,0 +1,78 @@ +import { FoodInfo } from '../model/DietType' +import { getFoodInfo } from '../model/DataUtil' +import { Record } from '../components/detail/dialog' +import { NutritionElement } from '../model/DataModels' + +import { PageTitle } from '../components/detail/page_title' +import { FoodImageDisplay } from '../components/detail/food_image_display' +import { ContentTable } from '../components/detail/content_table' +import { CaloriesProgress } from '../components/detail/calories_progress' +import { NutritionPercent } from '../components/detail/nutrition_percent' +import { NutritionPieChart } from '../components/detail/nutrition_pie_chart' + +@Entry +@Component +struct FoodDetail { + private foodInfo: FoodInfo = getFoodInfo() + private nutritionElements: NutritionElement[] + dialogController: CustomDialogController = new CustomDialogController({ + builder: Record({ foodInfo: this.foodInfo }), + autoCancel: true, + alignment: DialogAlignment.Bottom, + offset: { dx: 0, dy: -20 }, + customStyle: true + }) + + aboutToAppear() { + let total = this.foodInfo.protein + this.foodInfo.fat + this.foodInfo.carbohydrates + this.nutritionElements = [ + new NutritionElement($r('app.string.diet_record_protein'), this.foodInfo.protein, '#ff9421'), + new NutritionElement($r('app.string.diet_record_fat'), this.foodInfo.fat, '#ffd100'), + new NutritionElement($r('app.string.diet_record_carbohydrates'), this.foodInfo.carbohydrates, '#4cd041') + ] + let lastEndAngle = -0.5 * Math.PI + this.nutritionElements.forEach((value) => { + let percent = value.weight / total + value.percent = Math.round(percent * 100) + value.beginAngle = lastEndAngle + value.endAngle = (percent * 2 * Math.PI) + lastEndAngle + lastEndAngle = value.endAngle + return value + }) + } + + build() { + Scroll() { + Column() { + PageTitle() + FoodImageDisplay({ foodInfo: this.foodInfo }) + Swiper() { + ContentTable({ foodInfo: this.foodInfo }) + CaloriesProgress({ foodInfo: this.foodInfo }) + NutritionPercent({ foodInfo: this.foodInfo, nutritionElements: this.nutritionElements }) + NutritionPieChart({ foodInfo: this.foodInfo, nutritionElements: this.nutritionElements }) + } + .indicator(true) + .displayCount(1) + .clip(new Rect().width('100%').height('100%').radiusWidth(15).radiusHeight(15)) + .itemSpace(20) + .height(330) + .indicatorStyle({ selectedColor: $r('app.color.theme_color_green') }) + .margin({ top: 10, right: 10, left: 10 }) + + Button($r('app.string.button_food_detail_record'), { type: ButtonType.Capsule, stateEffect: true }) + .height(42) + .width('80%') + .margin({ top: 32, bottom: 32 }) + .backgroundColor($r('app.color.theme_color_green')) + .onClick(() => { + this.dialogController.open() + }) + } + .alignItems(HorizontalAlign.Center) + } + .backgroundColor('#EDF2F5') + .height('100%') + .align(Alignment.Top) + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/pages/Index.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/pages/Index.ets" new file mode 100644 index 0000000000000000000000000000000000000000..bec1928f213984d5661ab0100a263ede612b539b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/ets/pages/Index.ets" @@ -0,0 +1,31 @@ +import { HomeBottom } from '../components/HomeBottom' +import { FoodsDisplay } from '../components/home/foods_display' +import { Records } from '../components/record/diet_record' + +@Entry +@Component +struct Index { + @State currentPage: number = 1 + + build() { + Column() { + Scroll() { + Column() { + if (this.currentPage == 1) { + //首页 + FoodsDisplay() + } else if (this.currentPage == 2) { + //列表 + Records() + } + } + .height(730) + } + .flexGrow(1) + HomeBottom({currentPage: $currentPage}) + } + .backgroundColor(0xffffff) + .height('100%') + .width('100%') + } +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/module.json5" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/module.json5" new file mode 100644 index 0000000000000000000000000000000000000000..e4e8a81b24f3e1beea6abf6dbf97bc56bc7a6080 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/module.json5" @@ -0,0 +1,36 @@ +{ + "module": { + "name": "entry", + "type": "entry", + "description": "$string:module_desc", + "mainElement": "EntryAbility", + "deviceTypes": [ + "phone" + ], + "deliveryWithInstall": true, + "installationFree": false, + "pages": "$profile:main_pages", + "abilities": [ + { + "name": "EntryAbility", + "srcEntrance": "./ets/entryability/EntryAbility.ts", + "description": "$string:EntryAbility_desc", + "icon": "$media:icon", + "label": "$string:EntryAbility_label", + "startWindowIcon": "$media:icon", + "startWindowBackground": "$color:start_window_background", + "visible": true, + "skills": [ + { + "entities": [ + "entity.system.home" + ], + "actions": [ + "action.system.home" + ] + } + ] + } + ] + } +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/color.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/color.json" new file mode 100644 index 0000000000000000000000000000000000000000..93359d97bbe8405c93420fca3d06cacb0b0d15d0 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/color.json" @@ -0,0 +1,40 @@ +{ + "color": [ + { + "name": "start_window_background", + "value": "#FFFFFF" + }, + { + "name": "white", + "value": "#FFFFFF" + }, + { + "name": "high_calorie", + "value": "#EE584C" + }, + { + "name": "low_calorie", + "value": "#73CD57" + }, + { + "name": "theme_color_orange", + "value": "#FD9A42" + }, + { + "name": "theme_color_green", + "value": "#73CD57" + }, + { + "name": "theme_color_grey", + "value": "#999999" + }, + { + "name": "tab_bar_select_color", + "value": "#73CD57" + }, + { + "name": "tab_bar_normal_color", + "value": "#999999" + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/strarray.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/strarray.json" new file mode 100644 index 0000000000000000000000000000000000000000..9650a29492e66f6cc1b44d3ec684e5bf00b52a6b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/strarray.json" @@ -0,0 +1,21 @@ +{ + "strarray": [ + { + "name": "mealTime_labels", + "value": [ + { + "value": "早餐" + }, + { + "value": "午餐" + }, + { + "value": "晚餐" + }, + { + "value": "宵夜" + } + ] + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/string.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/string.json" new file mode 100644 index 0000000000000000000000000000000000000000..5a61ff5a3079e2c805989e870d3fb08d1723c71b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/element/string.json" @@ -0,0 +1,208 @@ +{ + "string": [ + { + "name": "module_desc", + "value": "module description" + }, + { + "name": "EntryAbility_desc", + "value": "description" + }, + { + "name": "EntryAbility_label", + "value": "label" + }, + { + "name": "entry_desc", + "value": "description" + }, + { + "name": "MainAbility_desc", + "value": "健康的生活来自均衡的饮食" + }, + { + "name": "MainAbility_label", + "value": "健康饮食" + }, + { + "name": "title_record", + "value": "记录" + }, + { + "name": "no_record_content", + "value": "无记录,请返回首页添加." + }, + { + "name": "tab_bar_home", + "value": "首页" + }, + { + "name": "tab_bar_record", + "value": "记录" + }, + { + "name": "category_all", + "value": "所有" + }, + { + "name": "category_fruit", + "value": "水果" + }, + { + "name": "category_vegetable", + "value": "蔬菜" + }, + { + "name": "category_nut", + "value": "坚果" + }, + { + "name": "category_seafood", + "value": "海鲜" + }, + { + "name": "category_dessert", + "value": "甜点" + }, + { + "name": "diet_record_calorie", + "value": "热量" + }, + { + "name": "nutrition_element", + "value": "营养元素" + }, + { + "name": "high_calorie", + "value": "高热量" + }, + { + "name": "medium_low_calories", + "value": "中低热量" + }, + { + "name": "low_calorie", + "value": "低热量" + }, + { + "name": "low_calorie_food", + "value": "低热量食物" + }, + { + "name": "high_calorie_food", + "value": "高热量食物" + }, + { + "name": "diet_record_fat", + "value": "脂肪" + }, + { + "name": "diet_record_protein", + "value": "蛋白质" + }, + { + "name": "diet_record_vitaminC", + "value": "维他命C" + }, + { + "name": "diet_record_carbohydrates", + "value": "碳水" + }, + { + "name": "title_food_detail", + "value": "食物详情" + }, + { + "name": "button_food_detail_complete", + "value": "完成" + }, + { + "name": "button_food_detail_record", + "value": "记录" + }, + { + "name": "title_food_list", + "value": "食物列表" + }, + { + "name": "meal_time_breakfast", + "value": "早餐" + }, + { + "name": "meal_time_lunch", + "value": "午餐" + }, + { + "name": "meal_time_dinner", + "value": "晚餐" + }, + { + "name": "meal_time_supper", + "value": "夜宵" + }, + { + "name": "food_name_tomato", + "value": "番茄" + }, + { + "name": "food_name_walnut", + "value": "核桃" + }, + { + "name": "food_name_cucumber", + "value": "黄瓜" + }, + { + "name": "food_name_blueberry", + "value": "蓝莓" + }, + { + "name": "food_name_crab", + "value": "螃蟹" + }, + { + "name": "food_name_ice_cream", + "value": "冰激凌" + }, + { + "name": "food_name_onion", + "value": "洋葱" + }, + { + "name": "food_name_mushroom", + "value": "蘑菇" + }, + { + "name": "food_name_kiwi", + "value": "猕猴桃" + }, + { + "name": "food_name_pitaya", + "value": "火龙果" + }, + { + "name": "food_name_avocado", + "value": "牛油果" + }, + { + "name": "food_name_strawberry", + "value": "草莓" + }, + { + "name": "unit_weight", + "value": "每100克" + }, + { + "name": "weight_with_gram_unit", + "value": "%s 克" + }, + { + "name": "weight_with_milligram_unit", + "value": "%s 毫克" + }, + { + "name": "calorie_with_kcal_unit", + "value": "%s 千卡" + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/add.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/add.png" new file mode 100644 index 0000000000000000000000000000000000000000..c3b50d372ab0a1bfe0f8e96d80867fcb6bc7b01e Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/add.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/avocado.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/avocado.png" new file mode 100644 index 0000000000000000000000000000000000000000..a2848b10707f0f4f1c6a661826d822e678b3cceb Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/avocado.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/back.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/back.png" new file mode 100644 index 0000000000000000000000000000000000000000..2b0806c99ba80ca8bd23cf65f0b8eebf01dcb460 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/back.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/blueberry.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/blueberry.png" new file mode 100644 index 0000000000000000000000000000000000000000..a07421e575d4d41e718ace47c16aaba8ac0755ac Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/blueberry.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/crab.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/crab.png" new file mode 100644 index 0000000000000000000000000000000000000000..b71a627013711964e4d5d3b271e9311a2b525f65 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/crab.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/cucumber.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/cucumber.png" new file mode 100644 index 0000000000000000000000000000000000000000..6dd74778e8d76e29a269fdd0155084292504ef61 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/cucumber.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_bottom_home.svg" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_bottom_home.svg" new file mode 100644 index 0000000000000000000000000000000000000000..c74324a979a1b8ab7237ca210338a679d91db169 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_bottom_home.svg" @@ -0,0 +1 @@ + Public/ic_public_home_filled \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_bottom_record.svg" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_bottom_record.svg" new file mode 100644 index 0000000000000000000000000000000000000000..b3041818d9f2c6b1d9a830d71c41b78e44e3a8b3 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_bottom_record.svg" @@ -0,0 +1 @@ + Public/ic_public_notes_filled \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_public_delete.svg" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_public_delete.svg" new file mode 100644 index 0000000000000000000000000000000000000000..5e69d92bec10119023e8d891648ecce85d6507be --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_public_delete.svg" @@ -0,0 +1,31 @@ + + + Public/ic_public_delete + + + + + + + + + + \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_switch.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_switch.png" new file mode 100644 index 0000000000000000000000000000000000000000..51aa0fc19aeb19ee0599d09f9802fd1f344818ec Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/ic_switch.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/icecream.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/icecream.png" new file mode 100644 index 0000000000000000000000000000000000000000..13a867424f48674c3e95590ec9887d38cd00fbfd Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/icecream.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/icon.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/icon.png" new file mode 100644 index 0000000000000000000000000000000000000000..ce307a8827bd75456441ceb57d530e4c8d45d36c Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/icon.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/kiwi.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/kiwi.png" new file mode 100644 index 0000000000000000000000000000000000000000..f22fb4328a9850ddd526d165964096c1bb9778a7 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/kiwi.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/logo.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/logo.png" new file mode 100644 index 0000000000000000000000000000000000000000..826c9813215ecaef36f1900b9ad37c93598181c2 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/logo.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/mushroom.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/mushroom.png" new file mode 100644 index 0000000000000000000000000000000000000000..3e984ee10df7a0ff4dae4558f17f2c6c7b89075f Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/mushroom.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/norecord.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/norecord.png" new file mode 100644 index 0000000000000000000000000000000000000000..724b2e1a37f43c954e599e64d34e61e3826b8e5e Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/norecord.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/onion.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/onion.png" new file mode 100644 index 0000000000000000000000000000000000000000..9c1c5a81c2ff9717df20fcec6a7a8e128b41f1ee Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/onion.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/pitaya.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/pitaya.png" new file mode 100644 index 0000000000000000000000000000000000000000..2770b34deb402ab0639e861fb83e4c8a5865bf59 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/pitaya.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/remove.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/remove.png" new file mode 100644 index 0000000000000000000000000000000000000000..fadb680396143e5c923544d8a4cfa6c33dbcafaf Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/remove.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/strawberry.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/strawberry.png" new file mode 100644 index 0000000000000000000000000000000000000000..a8d239456cdac76fa31e919768151ed6e74cae44 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/strawberry.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/tomato.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/tomato.png" new file mode 100644 index 0000000000000000000000000000000000000000..93ad983d4862485684c34cfcf1632569a13ae5a1 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/tomato.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/walnut.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/walnut.png" new file mode 100644 index 0000000000000000000000000000000000000000..8187a4209586dae8522fb494386cc9d64aba95df Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/media/walnut.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/profile/main_pages.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/profile/main_pages.json" new file mode 100644 index 0000000000000000000000000000000000000000..c22a571f80d88a823be6ffdcfe947ed06e8126bb --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/base/profile/main_pages.json" @@ -0,0 +1,6 @@ +{ + "src": [ + "pages/Index", + "pages/FoodDetail" + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/en_US/element/string.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/en_US/element/string.json" new file mode 100644 index 0000000000000000000000000000000000000000..5a61ff5a3079e2c805989e870d3fb08d1723c71b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/en_US/element/string.json" @@ -0,0 +1,208 @@ +{ + "string": [ + { + "name": "module_desc", + "value": "module description" + }, + { + "name": "EntryAbility_desc", + "value": "description" + }, + { + "name": "EntryAbility_label", + "value": "label" + }, + { + "name": "entry_desc", + "value": "description" + }, + { + "name": "MainAbility_desc", + "value": "健康的生活来自均衡的饮食" + }, + { + "name": "MainAbility_label", + "value": "健康饮食" + }, + { + "name": "title_record", + "value": "记录" + }, + { + "name": "no_record_content", + "value": "无记录,请返回首页添加." + }, + { + "name": "tab_bar_home", + "value": "首页" + }, + { + "name": "tab_bar_record", + "value": "记录" + }, + { + "name": "category_all", + "value": "所有" + }, + { + "name": "category_fruit", + "value": "水果" + }, + { + "name": "category_vegetable", + "value": "蔬菜" + }, + { + "name": "category_nut", + "value": "坚果" + }, + { + "name": "category_seafood", + "value": "海鲜" + }, + { + "name": "category_dessert", + "value": "甜点" + }, + { + "name": "diet_record_calorie", + "value": "热量" + }, + { + "name": "nutrition_element", + "value": "营养元素" + }, + { + "name": "high_calorie", + "value": "高热量" + }, + { + "name": "medium_low_calories", + "value": "中低热量" + }, + { + "name": "low_calorie", + "value": "低热量" + }, + { + "name": "low_calorie_food", + "value": "低热量食物" + }, + { + "name": "high_calorie_food", + "value": "高热量食物" + }, + { + "name": "diet_record_fat", + "value": "脂肪" + }, + { + "name": "diet_record_protein", + "value": "蛋白质" + }, + { + "name": "diet_record_vitaminC", + "value": "维他命C" + }, + { + "name": "diet_record_carbohydrates", + "value": "碳水" + }, + { + "name": "title_food_detail", + "value": "食物详情" + }, + { + "name": "button_food_detail_complete", + "value": "完成" + }, + { + "name": "button_food_detail_record", + "value": "记录" + }, + { + "name": "title_food_list", + "value": "食物列表" + }, + { + "name": "meal_time_breakfast", + "value": "早餐" + }, + { + "name": "meal_time_lunch", + "value": "午餐" + }, + { + "name": "meal_time_dinner", + "value": "晚餐" + }, + { + "name": "meal_time_supper", + "value": "夜宵" + }, + { + "name": "food_name_tomato", + "value": "番茄" + }, + { + "name": "food_name_walnut", + "value": "核桃" + }, + { + "name": "food_name_cucumber", + "value": "黄瓜" + }, + { + "name": "food_name_blueberry", + "value": "蓝莓" + }, + { + "name": "food_name_crab", + "value": "螃蟹" + }, + { + "name": "food_name_ice_cream", + "value": "冰激凌" + }, + { + "name": "food_name_onion", + "value": "洋葱" + }, + { + "name": "food_name_mushroom", + "value": "蘑菇" + }, + { + "name": "food_name_kiwi", + "value": "猕猴桃" + }, + { + "name": "food_name_pitaya", + "value": "火龙果" + }, + { + "name": "food_name_avocado", + "value": "牛油果" + }, + { + "name": "food_name_strawberry", + "value": "草莓" + }, + { + "name": "unit_weight", + "value": "每100克" + }, + { + "name": "weight_with_gram_unit", + "value": "%s 克" + }, + { + "name": "weight_with_milligram_unit", + "value": "%s 毫克" + }, + { + "name": "calorie_with_kcal_unit", + "value": "%s 千卡" + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/index.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/index.png" new file mode 100644 index 0000000000000000000000000000000000000000..5c57223a5862f70e9d2ad17e1890fd1093c92097 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/index.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/indexgray.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/indexgray.png" new file mode 100644 index 0000000000000000000000000000000000000000..942ecebf349f33b47cdc3eb12848f6cc3d4699f1 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/indexgray.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/statistics.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/statistics.png" new file mode 100644 index 0000000000000000000000000000000000000000..28099adabd59be84757231da8c47daf7bfc11a04 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/statistics.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/statisticsgray.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/statisticsgray.png" new file mode 100644 index 0000000000000000000000000000000000000000..018f9c3177561e7aa7795e0e6975a2c30054c3cf Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/rawfile/nav/statisticsgray.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/zh_CN/element/string.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/zh_CN/element/string.json" new file mode 100644 index 0000000000000000000000000000000000000000..5a61ff5a3079e2c805989e870d3fb08d1723c71b --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/main/resources/zh_CN/element/string.json" @@ -0,0 +1,208 @@ +{ + "string": [ + { + "name": "module_desc", + "value": "module description" + }, + { + "name": "EntryAbility_desc", + "value": "description" + }, + { + "name": "EntryAbility_label", + "value": "label" + }, + { + "name": "entry_desc", + "value": "description" + }, + { + "name": "MainAbility_desc", + "value": "健康的生活来自均衡的饮食" + }, + { + "name": "MainAbility_label", + "value": "健康饮食" + }, + { + "name": "title_record", + "value": "记录" + }, + { + "name": "no_record_content", + "value": "无记录,请返回首页添加." + }, + { + "name": "tab_bar_home", + "value": "首页" + }, + { + "name": "tab_bar_record", + "value": "记录" + }, + { + "name": "category_all", + "value": "所有" + }, + { + "name": "category_fruit", + "value": "水果" + }, + { + "name": "category_vegetable", + "value": "蔬菜" + }, + { + "name": "category_nut", + "value": "坚果" + }, + { + "name": "category_seafood", + "value": "海鲜" + }, + { + "name": "category_dessert", + "value": "甜点" + }, + { + "name": "diet_record_calorie", + "value": "热量" + }, + { + "name": "nutrition_element", + "value": "营养元素" + }, + { + "name": "high_calorie", + "value": "高热量" + }, + { + "name": "medium_low_calories", + "value": "中低热量" + }, + { + "name": "low_calorie", + "value": "低热量" + }, + { + "name": "low_calorie_food", + "value": "低热量食物" + }, + { + "name": "high_calorie_food", + "value": "高热量食物" + }, + { + "name": "diet_record_fat", + "value": "脂肪" + }, + { + "name": "diet_record_protein", + "value": "蛋白质" + }, + { + "name": "diet_record_vitaminC", + "value": "维他命C" + }, + { + "name": "diet_record_carbohydrates", + "value": "碳水" + }, + { + "name": "title_food_detail", + "value": "食物详情" + }, + { + "name": "button_food_detail_complete", + "value": "完成" + }, + { + "name": "button_food_detail_record", + "value": "记录" + }, + { + "name": "title_food_list", + "value": "食物列表" + }, + { + "name": "meal_time_breakfast", + "value": "早餐" + }, + { + "name": "meal_time_lunch", + "value": "午餐" + }, + { + "name": "meal_time_dinner", + "value": "晚餐" + }, + { + "name": "meal_time_supper", + "value": "夜宵" + }, + { + "name": "food_name_tomato", + "value": "番茄" + }, + { + "name": "food_name_walnut", + "value": "核桃" + }, + { + "name": "food_name_cucumber", + "value": "黄瓜" + }, + { + "name": "food_name_blueberry", + "value": "蓝莓" + }, + { + "name": "food_name_crab", + "value": "螃蟹" + }, + { + "name": "food_name_ice_cream", + "value": "冰激凌" + }, + { + "name": "food_name_onion", + "value": "洋葱" + }, + { + "name": "food_name_mushroom", + "value": "蘑菇" + }, + { + "name": "food_name_kiwi", + "value": "猕猴桃" + }, + { + "name": "food_name_pitaya", + "value": "火龙果" + }, + { + "name": "food_name_avocado", + "value": "牛油果" + }, + { + "name": "food_name_strawberry", + "value": "草莓" + }, + { + "name": "unit_weight", + "value": "每100克" + }, + { + "name": "weight_with_gram_unit", + "value": "%s 克" + }, + { + "name": "weight_with_milligram_unit", + "value": "%s 毫克" + }, + { + "name": "calorie_with_kcal_unit", + "value": "%s 千卡" + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/test/Ability.test.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/test/Ability.test.ets" new file mode 100644 index 0000000000000000000000000000000000000000..460fe8c8c124c821c5451615acc8949f619dbc3f --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/test/Ability.test.ets" @@ -0,0 +1,36 @@ +import hilog from '@ohos.hilog'; +import { describe, beforeAll, beforeEach, afterEach, afterAll, it, expect } from '@ohos/hypium' + +export default function abilityTest() { + describe('ActsAbilityTest', function () { + // Defines a test suite. Two parameters are supported: test suite name and test suite function. + beforeAll(function () { + // Presets an action, which is performed only once before all test cases of the test suite start. + // This API supports only one parameter: preset action function. + }) + beforeEach(function () { + // Presets an action, which is performed before each unit test case starts. + // The number of execution times is the same as the number of test cases defined by **it**. + // This API supports only one parameter: preset action function. + }) + afterEach(function () { + // Presets a clear action, which is performed after each unit test case ends. + // The number of execution times is the same as the number of test cases defined by **it**. + // This API supports only one parameter: clear action function. + }) + afterAll(function () { + // Presets a clear action, which is performed after all test cases of the test suite end. + // This API supports only one parameter: clear action function. + }) + it('assertContain',0, function () { + // Defines a test case. This API supports three parameters: test case name, filter parameter, and test case function. + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'it begin'); + let a = 'abc' + let b = 'b' + // Defines a variety of assertion methods, which are used to declare expected boolean conditions. + expect(a).assertContain(b) + expect(a).assertEqual(a) + }) + }) +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/test/List.test.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/test/List.test.ets" new file mode 100644 index 0000000000000000000000000000000000000000..d766fe249dfc3ada636f27e64d9b64451ce32c93 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/test/List.test.ets" @@ -0,0 +1,5 @@ +import abilityTest from './Ability.test' + +export default function testsuite() { + abilityTest() +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testability/TestAbility.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testability/TestAbility.ets" new file mode 100644 index 0000000000000000000000000000000000000000..84765c417cbff3b90c08d4c9accb2ea581ba2df1 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testability/TestAbility.ets" @@ -0,0 +1,57 @@ +import hilog from '@ohos.hilog'; +import Ability from '@ohos.application.Ability' +import AbilityDelegatorRegistry from '@ohos.application.abilityDelegatorRegistry' +import { Hypium } from '@ohos/hypium' +import testsuite from '../test/List.test' +import Window from '@ohos.window' + +export default class TestAbility extends Ability { + onCreate(want, launchParam) { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility onCreate'); + hilog.info(0x0000, 'testTag', '%{public}s', 'want param:' + JSON.stringify(want) ?? ''); + hilog.info(0x0000, 'testTag', '%{public}s', 'launchParam:'+ JSON.stringify(launchParam) ?? ''); + var abilityDelegator: any + abilityDelegator = AbilityDelegatorRegistry.getAbilityDelegator() + var abilityDelegatorArguments: any + abilityDelegatorArguments = AbilityDelegatorRegistry.getArguments() + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'start run testcase!!!'); + Hypium.hypiumTest(abilityDelegator, abilityDelegatorArguments, testsuite) + } + + onDestroy() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility onDestroy'); + } + + onWindowStageCreate(windowStage: Window.WindowStage) { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility onWindowStageCreate'); + windowStage.loadContent('testability/pages/Index', (err, data) => { + if (err.code) { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.ERROR); + hilog.error(0x0000, 'testTag', 'Failed to load the content. Cause: %{public}s', JSON.stringify(err) ?? ''); + return; + } + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', 'Succeeded in loading the content. Data: %{public}s', + JSON.stringify(data) ?? ''); + }); + } + + onWindowStageDestroy() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility onWindowStageDestroy'); + } + + onForeground() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility onForeground'); + } + + onBackground() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility onBackground'); + } +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testability/pages/Index.ets" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testability/pages/Index.ets" new file mode 100644 index 0000000000000000000000000000000000000000..954dfe0e29874c9ef11a5ace1673f79e27999864 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testability/pages/Index.ets" @@ -0,0 +1,35 @@ +import hilog from '@ohos.hilog'; + +@Entry +@Component +struct Index { + aboutToAppear() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'TestAbility index aboutToAppear'); + } + @State message: string = 'Hello World' + build() { + Row() { + Column() { + Text(this.message) + .fontSize(50) + .fontWeight(FontWeight.Bold) + Button() { + Text('next page') + .fontSize(20) + .fontWeight(FontWeight.Bold) + }.type(ButtonType.Capsule) + .margin({ + top: 20 + }) + .backgroundColor('#0D9FFB') + .width('35%') + .height('5%') + .onClick(()=>{ + }) + } + .width('100%') + } + .height('100%') + } + } \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testrunner/OpenHarmonyTestRunner.ts" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testrunner/OpenHarmonyTestRunner.ts" new file mode 100644 index 0000000000000000000000000000000000000000..94579b9c1535bc11ee56ee53b48fc90a9977e33a --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/ets/testrunner/OpenHarmonyTestRunner.ts" @@ -0,0 +1,71 @@ +import hilog from '@ohos.hilog'; +import TestRunner from '@ohos.application.testRunner' +import AbilityDelegatorRegistry from '@ohos.application.abilityDelegatorRegistry' + +var abilityDelegator = undefined +var abilityDelegatorArguments = undefined + +function translateParamsToString(parameters) { + const keySet = new Set([ + '-s class', '-s notClass', '-s suite', '-s it', + '-s level', '-s testType', '-s size', '-s timeout', + '-s dryRun' + ]) + let targetParams = ''; + for (const key in parameters) { + if (keySet.has(key)) { + targetParams = `${targetParams} ${key} ${parameters[key]}` + } + } + return targetParams.trim() +} + +async function onAbilityCreateCallback() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'onAbilityCreateCallback'); +} + +async function addAbilityMonitorCallback(err: any) { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', 'addAbilityMonitorCallback : %{public}s', JSON.stringify(err) ?? ''); +} + +export default class OpenHarmonyTestRunner implements TestRunner { + constructor() { + } + + onPrepare() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'OpenHarmonyTestRunner OnPrepare '); + } + + async onRun() { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', '%{public}s', 'OpenHarmonyTestRunner onRun run'); + abilityDelegatorArguments = AbilityDelegatorRegistry.getArguments() + abilityDelegator = AbilityDelegatorRegistry.getAbilityDelegator() + var testAbilityName = abilityDelegatorArguments.bundleName + '.TestAbility' + let lMonitor = { + abilityName: testAbilityName, + onAbilityCreate: onAbilityCreateCallback, + }; + abilityDelegator.addAbilityMonitor(lMonitor, addAbilityMonitorCallback) + var cmd = 'aa start -d 0 -a TestAbility' + ' -b ' + abilityDelegatorArguments.bundleName + cmd += ' '+translateParamsToString(abilityDelegatorArguments.parameters) + var debug = abilityDelegatorArguments.parameters['-D'] + if (debug == 'true') + { + cmd += ' -D' + } + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', 'cmd : %{public}s', cmd); + abilityDelegator.executeShellCommand(cmd, + (err: any, d: any) => { + hilog.isLoggable(0x0000, 'testTag', hilog.LogLevel.INFO); + hilog.info(0x0000, 'testTag', 'executeShellCommand : err : %{public}s', JSON.stringify(err) ?? ''); + hilog.info(0x0000, 'testTag', 'executeShellCommand : data : %{public}s', d.stdResult ?? ''); + hilog.info(0x0000, 'testTag', 'executeShellCommand : data : %{public}s', d.exitCode ?? ''); + }) + hilog.info(0x0000, 'testTag', '%{public}s', 'OpenHarmonyTestRunner onRun end'); + } +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/module.json5" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/module.json5" new file mode 100644 index 0000000000000000000000000000000000000000..46d95d62f1d98834e61853653bc2369cbe5907de --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/module.json5" @@ -0,0 +1,36 @@ +{ + "module": { + "name": "entry_test", + "type": "feature", + "description": "$string:module_test_desc", + "mainElement": "TestAbility", + "deviceTypes": [ + "phone" + ], + "deliveryWithInstall": true, + "installationFree": false, + "pages": "$profile:test_pages", + "abilities": [ + { + "name": "TestAbility", + "srcEntrance": "./ets/testability/TestAbility.ets", + "description": "$string:TestAbility_desc", + "icon": "$media:icon", + "label": "$string:TestAbility_label", + "visible": true, + "startWindowIcon": "$media:icon", + "startWindowBackground": "$color:start_window_background", + "skills": [ + { + "actions": [ + "action.system.home" + ], + "entities": [ + "entity.system.home" + ] + } + ] + } + ] + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/element/color.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/element/color.json" new file mode 100644 index 0000000000000000000000000000000000000000..3c712962da3c2751c2b9ddb53559afcbd2b54a02 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/element/color.json" @@ -0,0 +1,8 @@ +{ + "color": [ + { + "name": "start_window_background", + "value": "#FFFFFF" + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/element/string.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/element/string.json" new file mode 100644 index 0000000000000000000000000000000000000000..65d8fa5a7cf54aa3943dcd0214f58d1771bc1f6c --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/element/string.json" @@ -0,0 +1,16 @@ +{ + "string": [ + { + "name": "module_test_desc", + "value": "test ability description" + }, + { + "name": "TestAbility_desc", + "value": "the test ability" + }, + { + "name": "TestAbility_label", + "value": "test label" + } + ] +} \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/media/icon.png" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/media/icon.png" new file mode 100644 index 0000000000000000000000000000000000000000..ce307a8827bd75456441ceb57d530e4c8d45d36c Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/media/icon.png" differ diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/profile/test_pages.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/profile/test_pages.json" new file mode 100644 index 0000000000000000000000000000000000000000..b7e7343cacb32ce982a45e76daad86e435e054fe --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/entry/src/ohosTest/resources/base/profile/test_pages.json" @@ -0,0 +1,5 @@ +{ + "src": [ + "testability/pages/Index" + ] +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/hvigorfile.ts" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/hvigorfile.ts" new file mode 100644 index 0000000000000000000000000000000000000000..6478186902c0c1ad7c966a929c7d6b7d8ae7a9f3 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/hvigorfile.ts" @@ -0,0 +1,2 @@ +// Script for compiling build behavior. It is built in the build plug-in and cannot be modified currently. +export { appTasks } from '@ohos/hvigor-ohos-plugin'; \ No newline at end of file diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/package-lock.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/package-lock.json" new file mode 100644 index 0000000000000000000000000000000000000000..15e70f88b20f209c1a9519b514953b0406383ffb --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/package-lock.json" @@ -0,0 +1,1098 @@ +{ + "name": "healthydietli", + "version": "1.0.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@ohos/hos-sdkmanager-common": { + "version": "2.0.7", + "resolved": "https://repo.harmonyos.com/npm/@ohos/hos-sdkmanager-common/-/@ohos/hos-sdkmanager-common-2.0.7.tgz", + "integrity": "sha512-1dbZlFPImIatThlZWds8sCe6VMKMWCNqOGhoRoEa8FJACKwlUrTybOjCi+MgR5X+vahQDLtDTvMJoZnfMMig6Q==", + "requires": { + "@ohos/sdkmanager-common": "^2.1.5" + } + }, + "@ohos/hvigor": { + "version": "1.3.1", + "resolved": "https://repo.harmonyos.com/npm/@ohos/hvigor/-/@ohos/hvigor-1.3.1.tgz", + "integrity": "sha512-YxIrzzKOPUrXgAe8isUG5q8CTRsP4TIF4Y4KrCeF+uLhMT2FMsd6LYkVj2X9Ib3+siZA+klIUv1Y+kKXMQ55tg==", + "requires": { + "@ohos/hvigor-base": "1.3.1", + "fs-extra": "10.0.1", + "interpret": "1.4.0", + "liftoff": "4.0.0", + "mute-stdout": "1.0.0", + "pretty-hrtime": "1.0.0", + "typescript": "4.7.4", + "v8flags": "3.2.0", + "yargs": "17.5.1" + } + }, + "@ohos/hvigor-base": { + "version": "1.3.1", + "resolved": "https://repo.harmonyos.com/npm/@ohos/hvigor-base/-/@ohos/hvigor-base-1.3.1.tgz", + "integrity": "sha512-0NBF9DGtrdG5YmEXPOgXokgd/ukIF7EDUqYSwYY0utwUJ08A1ukR+V+dcywrczu2erb80NCWbMyCeZOtrGNPMQ==", + "requires": { + "fs-extra": "10.0.1", + "iconv-lite": "0.6.3", + "json5": "2.2.0", + "lodash": "4.17.21", + "log4js": "6.4.1", + "once": "1.4.0", + "pretty-hrtime": "1.0.0" + } + }, + "@ohos/hvigor-ohos-plugin": { + "version": "1.3.1", + "resolved": "https://repo.harmonyos.com/npm/@ohos/hvigor-ohos-plugin/-/@ohos/hvigor-ohos-plugin-1.3.1.tgz", + "integrity": "sha512-K6Nk2tXNMTJlNf1Ad6nV3+DIQ7iFhBibrelUfHHWqDVlfFUWMxUtpk1Nvs/5RgKIu6O+BJRWJURDgm7mUooAWA==", + "requires": { + "@ohos/hos-sdkmanager-common": "2.0.7", + "@ohos/hvigor-base": "1.3.1", + "@ohos/sdkmanager-common": "2.1.5", + "adm-zip": "0.5.9", + "ajv": "8.10.0", + "deasync": "0.1.28", + "execa": "5.1.1", + "fast-xml-parser": "4.0.3", + "fs-extra": "10.0.1", + "glob": "7.2.0", + "iconv-lite": "0.6.3", + "json5": "2.2.0", + "lodash": "4.17.21", + "pretty-hrtime": "1.0.3", + "resolve-package-path": "4.0.3" + }, + "dependencies": { + "pretty-hrtime": { + "version": "1.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz", + "integrity": "sha512-66hKPCr+72mlfiSjlEB1+45IjXSqvVAIy6mocupoww4tBFE9R9IhwwUGoI4G++Tc9Aq+2rxOt0RFU6gPcrte0A==" + } + } + }, + "@ohos/hypium": { + "version": "1.0.3", + "resolved": "https://repo.harmonyos.com/npm/@ohos/hypium/-/@ohos/hypium-1.0.3.tgz", + "integrity": "sha512-QKh8ngJk1ySbAiKpSTLP5EJIbT8Oja1zV3zwgLD7U9+KX7w2gjNIk3qoP+d13CwpEfaSR3Lxt3exlQLwWSFx3g==" + }, + "@ohos/sdkmanager-common": { + "version": "2.1.5", + "resolved": "https://repo.harmonyos.com/npm/@ohos/sdkmanager-common/-/@ohos/sdkmanager-common-2.1.5.tgz", + "integrity": "sha512-Ka6DncGdEkZ5A9/8aR0oea/PL6yZtPudXTalAX+oXCLIGUxUu400TBcETFZ4fsIePbxmWyOSQW5T1VqUYYIdOg==", + "requires": { + "axios": "0.24.0", + "jszip": "^3.7.0" + } + }, + "adm-zip": { + "version": "0.5.9", + "resolved": "https://repo.huaweicloud.com/repository/npm/adm-zip/-/adm-zip-0.5.9.tgz", + "integrity": "sha512-s+3fXLkeeLjZ2kLjCBwQufpI5fuN+kIGBxu6530nVQZGVol0d7Y/M88/xw9HGGUcJjKf8LutN3VPRUBq6N7Ajg==" + }, + "ajv": { + "version": "8.10.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/ajv/-/ajv-8.10.0.tgz", + "integrity": "sha512-bzqAEZOjkrUMl2afH8dknrq5KEk2SrwdBROR+vH1EKVQTqaUbJVPdc/gEdggTMM0Se+s+Ja4ju4TlNcStKl2Hw==", + "requires": { + "fast-deep-equal": "^3.1.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2", + "uri-js": "^4.2.2" + } + }, + "ansi-regex": { + "version": "5.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" + }, + "ansi-styles": { + "version": "4.3.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "requires": { + "color-convert": "^2.0.1" + } + }, + "array-each": { + "version": "1.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/array-each/-/array-each-1.0.1.tgz", + "integrity": "sha512-zHjL5SZa68hkKHBFBK6DJCTtr9sfTCPCaph/L7tMSLcTFgy+zX7E+6q5UArbtOtMBCtxdICpfTCspRse+ywyXA==" + }, + "array-slice": { + "version": "1.1.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/array-slice/-/array-slice-1.1.0.tgz", + "integrity": "sha512-B1qMD3RBP7O8o0H2KbrXDyB0IccejMF15+87Lvlor12ONPRHP6gTjXMNkt/d3ZuOGbAe66hFmaCfECI24Ufp6w==" + }, + "axios": { + "version": "0.24.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/axios/-/axios-0.24.0.tgz", + "integrity": "sha512-Q6cWsys88HoPgAaFAVUb0WpPk0O8iTeisR9IMqy9G8AbO4NlpVknrnQS03zzF9PGAWgO3cgletO3VjV/P7VztA==", + "requires": { + "follow-redirects": "^1.14.4" + } + }, + "balanced-match": { + "version": "1.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" + }, + "bindings": { + "version": "1.5.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/bindings/-/bindings-1.5.0.tgz", + "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==", + "requires": { + "file-uri-to-path": "1.0.0" + } + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://repo.huaweicloud.com/repository/npm/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "requires": { + "fill-range": "^7.0.1" + } + }, + "cliui": { + "version": "7.0.4", + "resolved": "https://repo.huaweicloud.com/repository/npm/cliui/-/cliui-7.0.4.tgz", + "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", + "requires": { + "string-width": "^4.2.0", + "strip-ansi": "^6.0.0", + "wrap-ansi": "^7.0.0" + } + }, + "color-convert": { + "version": "2.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "requires": { + "color-name": "~1.1.4" + } + }, + "color-name": { + "version": "1.1.4", + "resolved": "https://repo.huaweicloud.com/repository/npm/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "core-util-is": { + "version": "1.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "cross-spawn": { + "version": "7.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/cross-spawn/-/cross-spawn-7.0.3.tgz", + "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "requires": { + "path-key": "^3.1.0", + "shebang-command": "^2.0.0", + "which": "^2.0.1" + }, + "dependencies": { + "which": { + "version": "2.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "requires": { + "isexe": "^2.0.0" + } + } + } + }, + "date-format": { + "version": "4.0.14", + "resolved": "https://repo.huaweicloud.com/repository/npm/date-format/-/date-format-4.0.14.tgz", + "integrity": "sha512-39BOQLs9ZjKh0/patS9nrT8wc3ioX3/eA/zgbKNopnF2wCqJEoxywwwElATYvRsXdnOxA/OQeQoFZ3rFjVajhg==" + }, + "deasync": { + "version": "0.1.28", + "resolved": "https://repo.huaweicloud.com/repository/npm/deasync/-/deasync-0.1.28.tgz", + "integrity": "sha512-QqLF6inIDwiATrfROIyQtwOQxjZuek13WRYZ7donU5wJPLoP67MnYxA6QtqdvdBy2mMqv5m3UefBVdJjvevOYg==", + "requires": { + "bindings": "^1.5.0", + "node-addon-api": "^1.7.1" + } + }, + "debug": { + "version": "4.3.4", + "resolved": "https://repo.huaweicloud.com/repository/npm/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "requires": { + "ms": "2.1.2" + } + }, + "detect-file": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/detect-file/-/detect-file-1.0.0.tgz", + "integrity": "sha512-DtCOLG98P007x7wiiOmfI0fi3eIKyWiLTGJ2MDnVi/E04lWGbf+JzrRHMm0rgIIZJGtHpKpbVgLWHrv8xXpc3Q==" + }, + "emoji-regex": { + "version": "8.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" + }, + "escalade": { + "version": "3.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/escalade/-/escalade-3.1.1.tgz", + "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==" + }, + "execa": { + "version": "5.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/execa/-/execa-5.1.1.tgz", + "integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==", + "requires": { + "cross-spawn": "^7.0.3", + "get-stream": "^6.0.0", + "human-signals": "^2.1.0", + "is-stream": "^2.0.0", + "merge-stream": "^2.0.0", + "npm-run-path": "^4.0.1", + "onetime": "^5.1.2", + "signal-exit": "^3.0.3", + "strip-final-newline": "^2.0.0" + } + }, + "expand-tilde": { + "version": "2.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/expand-tilde/-/expand-tilde-2.0.2.tgz", + "integrity": "sha512-A5EmesHW6rfnZ9ysHQjPdJRni0SRar0tjtG5MNtm9n5TUvsYU8oozprtRD4AqHxcZWWlVuAmQo2nWKfN9oyjTw==", + "requires": { + "homedir-polyfill": "^1.0.1" + } + }, + "extend": { + "version": "3.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/extend/-/extend-3.0.2.tgz", + "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==" + }, + "fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==" + }, + "fast-xml-parser": { + "version": "4.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/fast-xml-parser/-/fast-xml-parser-4.0.3.tgz", + "integrity": "sha512-xhQbg3a/EYNHwK0cxIG1nZmVkHX/0tWihamn5pU4Mhd9KEVE2ga8ZJiqEUgB2sApElvAATOdMTLjgqIpvYDUkQ==", + "requires": { + "strnum": "^1.0.5" + } + }, + "file-uri-to-path": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz", + "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==" + }, + "fill-range": { + "version": "7.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/fill-range/-/fill-range-7.0.1.tgz", + "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "findup-sync": { + "version": "5.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/findup-sync/-/findup-sync-5.0.0.tgz", + "integrity": "sha512-MzwXju70AuyflbgeOhzvQWAvvQdo1XL0A9bVvlXsYcFEBM87WR4OakL4OfZq+QRmr+duJubio+UtNQCPsVESzQ==", + "requires": { + "detect-file": "^1.0.0", + "is-glob": "^4.0.3", + "micromatch": "^4.0.4", + "resolve-dir": "^1.0.1" + } + }, + "fined": { + "version": "2.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/fined/-/fined-2.0.0.tgz", + "integrity": "sha512-OFRzsL6ZMHz5s0JrsEr+TpdGNCtrVtnuG3x1yzGNiQHT0yaDnXAj8V/lWcpJVrnoDpcwXcASxAZYbuXda2Y82A==", + "requires": { + "expand-tilde": "^2.0.2", + "is-plain-object": "^5.0.0", + "object.defaults": "^1.1.0", + "object.pick": "^1.3.0", + "parse-filepath": "^1.0.2" + } + }, + "flagged-respawn": { + "version": "2.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/flagged-respawn/-/flagged-respawn-2.0.0.tgz", + "integrity": "sha512-Gq/a6YCi8zexmGHMuJwahTGzXlAZAOsbCVKduWXC6TlLCjjFRlExMJc4GC2NYPYZ0r/brw9P7CpRgQmlPVeOoA==" + }, + "flatted": { + "version": "3.2.7", + "resolved": "https://repo.huaweicloud.com/repository/npm/flatted/-/flatted-3.2.7.tgz", + "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==" + }, + "follow-redirects": { + "version": "1.15.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==" + }, + "for-in": { + "version": "1.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/for-in/-/for-in-1.0.2.tgz", + "integrity": "sha512-7EwmXrOjyL+ChxMhmG5lnW9MPt1aIeZEwKhQzoBUdTV0N3zuwWDZYVJatDvZ2OyzPUvdIAZDsCetk3coyMfcnQ==" + }, + "for-own": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/for-own/-/for-own-1.0.0.tgz", + "integrity": "sha512-0OABksIGrxKK8K4kynWkQ7y1zounQxP+CWnyclVwj81KW3vlLlGUx57DKGcP/LH216GzqnstnPocF16Nxs0Ycg==", + "requires": { + "for-in": "^1.0.1" + } + }, + "fs-extra": { + "version": "10.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/fs-extra/-/fs-extra-10.0.1.tgz", + "integrity": "sha512-NbdoVMZso2Lsrn/QwLXOy6rm0ufY2zEOKCDzJR/0kBsb0E6qed0P3iYK+Ath3BfvXEeu4JhEtXLgILx5psUfag==", + "requires": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://repo.huaweicloud.com/repository/npm/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" + }, + "get-stream": { + "version": "6.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==" + }, + "glob": { + "version": "7.2.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/glob/-/glob-7.2.0.tgz", + "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.0.4", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "global-modules": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/global-modules/-/global-modules-1.0.0.tgz", + "integrity": "sha512-sKzpEkf11GpOFuw0Zzjzmt4B4UZwjOcG757PPvrfhxcLFbq0wpsgpOqxpxtxFiCG4DtG93M6XRVbF2oGdev7bg==", + "requires": { + "global-prefix": "^1.0.1", + "is-windows": "^1.0.1", + "resolve-dir": "^1.0.0" + } + }, + "global-prefix": { + "version": "1.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/global-prefix/-/global-prefix-1.0.2.tgz", + "integrity": "sha512-5lsx1NUDHtSjfg0eHlmYvZKv8/nVqX4ckFbM+FrGcQ+04KWcWFo9P5MxPZYSzUvyzmdTbI7Eix8Q4IbELDqzKg==", + "requires": { + "expand-tilde": "^2.0.2", + "homedir-polyfill": "^1.0.1", + "ini": "^1.3.4", + "is-windows": "^1.0.1", + "which": "^1.2.14" + } + }, + "graceful-fs": { + "version": "4.2.10", + "resolved": "https://repo.huaweicloud.com/repository/npm/graceful-fs/-/graceful-fs-4.2.10.tgz", + "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==" + }, + "has": { + "version": "1.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "requires": { + "function-bind": "^1.1.1" + } + }, + "homedir-polyfill": { + "version": "1.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/homedir-polyfill/-/homedir-polyfill-1.0.3.tgz", + "integrity": "sha512-eSmmWE5bZTK2Nou4g0AI3zZ9rswp7GRKoKXS1BLUkvPviOqs4YTN1djQIqrXy9k5gEtdLPy86JjRwsNM9tnDcA==", + "requires": { + "parse-passwd": "^1.0.0" + } + }, + "human-signals": { + "version": "2.1.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/human-signals/-/human-signals-2.1.0.tgz", + "integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==" + }, + "iconv-lite": { + "version": "0.6.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "requires": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + } + }, + "immediate": { + "version": "3.0.6", + "resolved": "https://repo.huaweicloud.com/repository/npm/immediate/-/immediate-3.0.6.tgz", + "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://repo.huaweicloud.com/repository/npm/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://repo.huaweicloud.com/repository/npm/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "ini": { + "version": "1.3.8", + "resolved": "https://repo.huaweicloud.com/repository/npm/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==" + }, + "interpret": { + "version": "1.4.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/interpret/-/interpret-1.4.0.tgz", + "integrity": "sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==" + }, + "is-absolute": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-absolute/-/is-absolute-1.0.0.tgz", + "integrity": "sha512-dOWoqflvcydARa360Gvv18DZ/gRuHKi2NU/wU5X1ZFzdYfH29nkiNZsF3mp4OJ3H4yo9Mx8A/uAGNzpzPN3yBA==", + "requires": { + "is-relative": "^1.0.0", + "is-windows": "^1.0.1" + } + }, + "is-core-module": { + "version": "2.11.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-core-module/-/is-core-module-2.11.0.tgz", + "integrity": "sha512-RRjxlvLDkD1YJwDbroBHMb+cukurkDWNyHx7D3oNB5x9rb5ogcksMC5wHCadcXoo67gVr/+3GFySh3134zi6rw==", + "requires": { + "has": "^1.0.3" + } + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==" + }, + "is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==" + }, + "is-glob": { + "version": "4.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-number": { + "version": "7.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" + }, + "is-plain-object": { + "version": "5.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-plain-object/-/is-plain-object-5.0.0.tgz", + "integrity": "sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==" + }, + "is-relative": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-relative/-/is-relative-1.0.0.tgz", + "integrity": "sha512-Kw/ReK0iqwKeu0MITLFuj0jbPAmEiOsIwyIXvvbfa6QfmN9pkD1M+8pdk7Rl/dTKbH34/XBFMbgD4iMJhLQbGA==", + "requires": { + "is-unc-path": "^1.0.0" + } + }, + "is-stream": { + "version": "2.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==" + }, + "is-unc-path": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-unc-path/-/is-unc-path-1.0.0.tgz", + "integrity": "sha512-mrGpVd0fs7WWLfVsStvgF6iEJnbjDFZh9/emhRDcGWTduTfNHd9CHeUwH3gYIjdbwo4On6hunkztwOaAw0yllQ==", + "requires": { + "unc-path-regex": "^0.1.2" + } + }, + "is-windows": { + "version": "1.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/is-windows/-/is-windows-1.0.2.tgz", + "integrity": "sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==" + }, + "isarray": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg==" + }, + "json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==" + }, + "json5": { + "version": "2.2.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/json5/-/json5-2.2.0.tgz", + "integrity": "sha512-f+8cldu7X/y7RAJurMEJmdoKXGB/X550w2Nr3tTbezL6RwEE/iMcm+tZnXeoZtKuOq6ft8+CqzEkrIgx1fPoQA==", + "requires": { + "minimist": "^1.2.5" + } + }, + "jsonfile": { + "version": "6.1.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/jsonfile/-/jsonfile-6.1.0.tgz", + "integrity": "sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==", + "requires": { + "graceful-fs": "^4.1.6", + "universalify": "^2.0.0" + } + }, + "jszip": { + "version": "3.10.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/jszip/-/jszip-3.10.1.tgz", + "integrity": "sha512-xXDvecyTpGLrqFrvkrUSoxxfJI5AH7U8zxxtVclpsUtMCq4JQ290LY8AW5c7Ggnr/Y/oK+bQMbqK2qmtk3pN4g==", + "requires": { + "lie": "~3.3.0", + "pako": "~1.0.2", + "readable-stream": "~2.3.6", + "setimmediate": "^1.0.5" + } + }, + "kind-of": { + "version": "6.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==" + }, + "lie": { + "version": "3.3.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/lie/-/lie-3.3.0.tgz", + "integrity": "sha512-UaiMJzeWRlEujzAuw5LokY1L5ecNQYZKfmyZ9L7wDHb/p5etKaxXhohBcrw0EYby+G/NA52vRSN4N39dxHAIwQ==", + "requires": { + "immediate": "~3.0.5" + } + }, + "liftoff": { + "version": "4.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/liftoff/-/liftoff-4.0.0.tgz", + "integrity": "sha512-rMGwYF8q7g2XhG2ulBmmJgWv25qBsqRbDn5gH0+wnuyeFt7QBJlHJmtg5qEdn4pN6WVAUMgXnIxytMFRX9c1aA==", + "requires": { + "extend": "^3.0.2", + "findup-sync": "^5.0.0", + "fined": "^2.0.0", + "flagged-respawn": "^2.0.0", + "is-plain-object": "^5.0.0", + "object.map": "^1.0.1", + "rechoir": "^0.8.0", + "resolve": "^1.20.0" + } + }, + "lodash": { + "version": "4.17.21", + "resolved": "https://repo.huaweicloud.com/repository/npm/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "log4js": { + "version": "6.4.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/log4js/-/log4js-6.4.1.tgz", + "integrity": "sha512-iUiYnXqAmNKiIZ1XSAitQ4TmNs8CdZYTAWINARF3LjnsLN8tY5m0vRwd6uuWj/yNY0YHxeZodnbmxKFUOM2rMg==", + "requires": { + "date-format": "^4.0.3", + "debug": "^4.3.3", + "flatted": "^3.2.4", + "rfdc": "^1.3.0", + "streamroller": "^3.0.2" + } + }, + "make-iterator": { + "version": "1.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/make-iterator/-/make-iterator-1.0.1.tgz", + "integrity": "sha512-pxiuXh0iVEq7VM7KMIhs5gxsfxCux2URptUQaXo4iZZJxBAzTPOLE2BumO5dbfVYq/hBJFBR/a1mFDmOx5AGmw==", + "requires": { + "kind-of": "^6.0.2" + } + }, + "map-cache": { + "version": "0.2.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/map-cache/-/map-cache-0.2.2.tgz", + "integrity": "sha512-8y/eV9QQZCiyn1SprXSrCmqJN0yNRATe+PO8ztwqrvrbdRLA3eYJF0yaR0YayLWkMbsQSKWS9N2gPcGEc4UsZg==" + }, + "merge-stream": { + "version": "2.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/merge-stream/-/merge-stream-2.0.0.tgz", + "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==" + }, + "micromatch": { + "version": "4.0.5", + "resolved": "https://repo.huaweicloud.com/repository/npm/micromatch/-/micromatch-4.0.5.tgz", + "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", + "requires": { + "braces": "^3.0.2", + "picomatch": "^2.3.1" + } + }, + "mimic-fn": { + "version": "2.1.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==" + }, + "minimatch": { + "version": "3.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "1.2.7", + "resolved": "https://repo.huaweicloud.com/repository/npm/minimist/-/minimist-1.2.7.tgz", + "integrity": "sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g==" + }, + "ms": { + "version": "2.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + }, + "mute-stdout": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/mute-stdout/-/mute-stdout-1.0.0.tgz", + "integrity": "sha512-MaSQenn0f9oxIjtCufclpV00MuYTiHaXPbdcfPIM+quMqoa8cXywjHHx4LhhIAZlXqPWMdcUpYviajfmHtHRJw==" + }, + "node-addon-api": { + "version": "1.7.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/node-addon-api/-/node-addon-api-1.7.2.tgz", + "integrity": "sha512-ibPK3iA+vaY1eEjESkQkM0BbCqFOaZMiXRTtdB0u7b4djtY6JnsjvPdUHVMg6xQt3B8fpTTWHI9A+ADjM9frzg==" + }, + "npm-run-path": { + "version": "4.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/npm-run-path/-/npm-run-path-4.0.1.tgz", + "integrity": "sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw==", + "requires": { + "path-key": "^3.0.0" + } + }, + "object.defaults": { + "version": "1.1.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/object.defaults/-/object.defaults-1.1.0.tgz", + "integrity": "sha512-c/K0mw/F11k4dEUBMW8naXUuBuhxRCfG7W+yFy8EcijU/rSmazOUd1XAEEe6bC0OuXY4HUKjTJv7xbxIMqdxrA==", + "requires": { + "array-each": "^1.0.1", + "array-slice": "^1.0.0", + "for-own": "^1.0.0", + "isobject": "^3.0.0" + } + }, + "object.map": { + "version": "1.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/object.map/-/object.map-1.0.1.tgz", + "integrity": "sha512-3+mAJu2PLfnSVGHwIWubpOFLscJANBKuB/6A4CxBstc4aqwQY0FWcsppuy4jU5GSB95yES5JHSI+33AWuS4k6w==", + "requires": { + "for-own": "^1.0.0", + "make-iterator": "^1.0.0" + } + }, + "object.pick": { + "version": "1.3.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/object.pick/-/object.pick-1.3.0.tgz", + "integrity": "sha512-tqa/UMy/CCoYmj+H5qc07qvSL9dqcs/WZENZ1JbtWBlATP+iVOe778gE6MSijnyCnORzDuX6hU+LA4SZ09YjFQ==", + "requires": { + "isobject": "^3.0.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "requires": { + "wrappy": "1" + } + }, + "onetime": { + "version": "5.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/onetime/-/onetime-5.1.2.tgz", + "integrity": "sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg==", + "requires": { + "mimic-fn": "^2.1.0" + } + }, + "pako": { + "version": "1.0.11", + "resolved": "https://repo.huaweicloud.com/repository/npm/pako/-/pako-1.0.11.tgz", + "integrity": "sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw==" + }, + "parse-filepath": { + "version": "1.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/parse-filepath/-/parse-filepath-1.0.2.tgz", + "integrity": "sha512-FwdRXKCohSVeXqwtYonZTXtbGJKrn+HNyWDYVcp5yuJlesTwNH4rsmRZ+GrKAPJ5bLpRxESMeS+Rl0VCHRvB2Q==", + "requires": { + "is-absolute": "^1.0.0", + "map-cache": "^0.2.0", + "path-root": "^0.1.1" + } + }, + "parse-passwd": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/parse-passwd/-/parse-passwd-1.0.0.tgz", + "integrity": "sha512-1Y1A//QUXEZK7YKz+rD9WydcE1+EuPr6ZBgKecAB8tmoW6UFv0NREVJe1p+jRxtThkcbbKkfwIbWJe/IeE6m2Q==" + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==" + }, + "path-key": { + "version": "3.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/path-key/-/path-key-3.1.1.tgz", + "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==" + }, + "path-parse": { + "version": "1.0.7", + "resolved": "https://repo.huaweicloud.com/repository/npm/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, + "path-root": { + "version": "0.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/path-root/-/path-root-0.1.1.tgz", + "integrity": "sha512-QLcPegTHF11axjfojBIoDygmS2E3Lf+8+jI6wOVmNVenrKSo3mFdSGiIgdSHenczw3wPtlVMQaFVwGmM7BJdtg==", + "requires": { + "path-root-regex": "^0.1.0" + } + }, + "path-root-regex": { + "version": "0.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/path-root-regex/-/path-root-regex-0.1.2.tgz", + "integrity": "sha512-4GlJ6rZDhQZFE0DPVKh0e9jmZ5egZfxTkp7bcRDuPlJXbAwhxcl2dINPUAsjLdejqaLsCeg8axcLjIbvBjN4pQ==" + }, + "picomatch": { + "version": "2.3.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==" + }, + "pretty-hrtime": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/pretty-hrtime/-/pretty-hrtime-1.0.0.tgz", + "integrity": "sha512-CU2l5CYUAptUYq/671ajexQfXuxJFwwg0n243Kdkx8bTjeenedsWgu8TGHPm03vLfNtk3aTXgySKPp3Usykudw==" + }, + "process-nextick-args": { + "version": "2.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "punycode": { + "version": "2.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/punycode/-/punycode-2.1.1.tgz", + "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==" + }, + "readable-stream": { + "version": "2.3.7", + "resolved": "https://repo.huaweicloud.com/repository/npm/readable-stream/-/readable-stream-2.3.7.tgz", + "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "rechoir": { + "version": "0.8.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/rechoir/-/rechoir-0.8.0.tgz", + "integrity": "sha512-/vxpCXddiX8NGfGO/mTafwjq4aFa/71pvamip0++IQk3zG8cbCj0fifNPrjjF1XMXUne91jL9OoxmdykoEtifQ==", + "requires": { + "resolve": "^1.20.0" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==" + }, + "require-from-string": { + "version": "2.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/require-from-string/-/require-from-string-2.0.2.tgz", + "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==" + }, + "resolve": { + "version": "1.22.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/resolve/-/resolve-1.22.1.tgz", + "integrity": "sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw==", + "requires": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + } + }, + "resolve-dir": { + "version": "1.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/resolve-dir/-/resolve-dir-1.0.1.tgz", + "integrity": "sha512-R7uiTjECzvOsWSfdM0QKFNBVFcK27aHOUwdvK53BcW8zqnGdYp0Fbj82cy54+2A4P2tFM22J5kRfe1R+lM/1yg==", + "requires": { + "expand-tilde": "^2.0.0", + "global-modules": "^1.0.0" + } + }, + "resolve-package-path": { + "version": "4.0.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/resolve-package-path/-/resolve-package-path-4.0.3.tgz", + "integrity": "sha512-SRpNAPW4kewOaNUt8VPqhJ0UMxawMwzJD8V7m1cJfdSTK9ieZwS6K7Dabsm4bmLFM96Z5Y/UznrpG5kt1im8yA==", + "requires": { + "path-root": "^0.1.1" + } + }, + "rfdc": { + "version": "1.3.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/rfdc/-/rfdc-1.3.0.tgz", + "integrity": "sha512-V2hovdzFbOi77/WajaSMXk2OLm+xNIeQdMMuB7icj7bk6zi2F8GGAxigcnDFpJHbNyNcgyJDiP+8nOrY5cZGrA==" + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "setimmediate": { + "version": "1.0.5", + "resolved": "https://repo.huaweicloud.com/repository/npm/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==" + }, + "shebang-command": { + "version": "2.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/shebang-command/-/shebang-command-2.0.0.tgz", + "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", + "requires": { + "shebang-regex": "^3.0.0" + } + }, + "shebang-regex": { + "version": "3.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/shebang-regex/-/shebang-regex-3.0.0.tgz", + "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==" + }, + "signal-exit": { + "version": "3.0.7", + "resolved": "https://repo.huaweicloud.com/repository/npm/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "streamroller": { + "version": "3.1.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/streamroller/-/streamroller-3.1.3.tgz", + "integrity": "sha512-CphIJyFx2SALGHeINanjFRKQ4l7x2c+rXYJ4BMq0gd+ZK0gi4VT8b+eHe2wi58x4UayBAKx4xtHpXT/ea1cz8w==", + "requires": { + "date-format": "^4.0.14", + "debug": "^4.3.4", + "fs-extra": "^8.1.0" + }, + "dependencies": { + "fs-extra": { + "version": "8.1.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/fs-extra/-/fs-extra-8.1.0.tgz", + "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", + "requires": { + "graceful-fs": "^4.2.0", + "jsonfile": "^4.0.0", + "universalify": "^0.1.0" + } + }, + "jsonfile": { + "version": "4.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/jsonfile/-/jsonfile-4.0.0.tgz", + "integrity": "sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==", + "requires": { + "graceful-fs": "^4.1.6" + } + }, + "universalify": { + "version": "0.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/universalify/-/universalify-0.1.2.tgz", + "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==" + } + } + }, + "string-width": { + "version": "4.2.3", + "resolved": "https://repo.huaweicloud.com/repository/npm/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "requires": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + } + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + } + }, + "strip-ansi": { + "version": "6.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "requires": { + "ansi-regex": "^5.0.1" + } + }, + "strip-final-newline": { + "version": "2.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/strip-final-newline/-/strip-final-newline-2.0.0.tgz", + "integrity": "sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA==" + }, + "strnum": { + "version": "1.0.5", + "resolved": "https://repo.huaweicloud.com/repository/npm/strnum/-/strnum-1.0.5.tgz", + "integrity": "sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA==" + }, + "supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==" + }, + "to-regex-range": { + "version": "5.0.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "requires": { + "is-number": "^7.0.0" + } + }, + "typescript": { + "version": "4.7.4", + "resolved": "https://repo.huaweicloud.com/repository/npm/typescript/-/typescript-4.7.4.tgz", + "integrity": "sha512-C0WQT0gezHuw6AdY1M2jxUO83Rjf0HP7Sk1DtXj6j1EwkQNZrHAg2XPWlq62oqEhYvONq5pkC2Y9oPljWToLmQ==" + }, + "unc-path-regex": { + "version": "0.1.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/unc-path-regex/-/unc-path-regex-0.1.2.tgz", + "integrity": "sha512-eXL4nmJT7oCpkZsHZUOJo8hcX3GbsiDOa0Qu9F646fi8dT3XuSVopVqAcEiVzSKKH7UoDti23wNX3qGFxcW5Qg==" + }, + "universalify": { + "version": "2.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/universalify/-/universalify-2.0.0.tgz", + "integrity": "sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ==" + }, + "uri-js": { + "version": "4.4.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/uri-js/-/uri-js-4.4.1.tgz", + "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", + "requires": { + "punycode": "^2.1.0" + } + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "v8flags": { + "version": "3.2.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/v8flags/-/v8flags-3.2.0.tgz", + "integrity": "sha512-mH8etigqMfiGWdeXpaaqGfs6BndypxusHHcv2qSHyZkGEznCd/qAXCWWRzeowtL54147cktFOC4P5y+kl8d8Jg==", + "requires": { + "homedir-polyfill": "^1.0.1" + } + }, + "which": { + "version": "1.3.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "requires": { + "isexe": "^2.0.0" + } + }, + "wrap-ansi": { + "version": "7.0.0", + "resolved": "https://repo.huaweicloud.com/repository/npm/wrap-ansi/-/wrap-ansi-7.0.0.tgz", + "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "requires": { + "ansi-styles": "^4.0.0", + "string-width": "^4.1.0", + "strip-ansi": "^6.0.0" + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://repo.huaweicloud.com/repository/npm/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + }, + "y18n": { + "version": "5.0.8", + "resolved": "https://repo.huaweicloud.com/repository/npm/y18n/-/y18n-5.0.8.tgz", + "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==" + }, + "yargs": { + "version": "17.5.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/yargs/-/yargs-17.5.1.tgz", + "integrity": "sha512-t6YAJcxDkNX7NFYiVtKvWUz8l+PaKTLiL63mJYWR2GnHq2gjEWISzsLp9wg3aY36dY1j+gfIEL3pIF+XlJJfbA==", + "requires": { + "cliui": "^7.0.2", + "escalade": "^3.1.1", + "get-caller-file": "^2.0.5", + "require-directory": "^2.1.1", + "string-width": "^4.2.3", + "y18n": "^5.0.5", + "yargs-parser": "^21.0.0" + } + }, + "yargs-parser": { + "version": "21.1.1", + "resolved": "https://repo.huaweicloud.com/repository/npm/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==" + } + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/package.json" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/package.json" new file mode 100644 index 0000000000000000000000000000000000000000..ccd32f8a0d4e65a89add3996b0ad0336210c0724 --- /dev/null +++ "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/package.json" @@ -0,0 +1,17 @@ +{ + "name": "healthydietli", + "version": "1.0.0", + "ohos": { + "org": "huawei", + "buildTool": "hvigor", + "directoryLevel": "project" + }, + "description": "example description", + "repository": {}, + "license": "ISC", + "dependencies": { + "@ohos/hypium": "1.0.3", + "@ohos/hvigor": "1.3.1", + "@ohos/hvigor-ohos-plugin": "1.3.1" + } +} diff --git "a/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/screenshots/healthy_diet_li.gif" "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/screenshots/healthy_diet_li.gif" new file mode 100644 index 0000000000000000000000000000000000000000..d41257aa66c9ef73400fe57706548e840b125e18 Binary files /dev/null and "b/2022_ArkUI_Bootcamp/HarmonyOS ArkUI\345\205\245\351\227\250\350\256\255\347\273\203\350\220\245+HealthyDietLi/screenshots/healthy_diet_li.gif" differ