Skip to content

Commit

Permalink
Update Client.csproj, Program.cs, and add comments data
Browse files Browse the repository at this point in the history
- Added new `ItemGroup` in `Client.csproj` to include `comments.csv` and `comments.tt` files, with specific properties for `comments.tt`.
- Added another `ItemGroup` in `Client.csproj` to update `comments.csv` and `comments.json` files, specifying their copy behavior and dependencies.
- Modified `Program.cs` to change `apiHostAddress` initialization and updated the URL to fetch the model from `comments.json`.
- Added new content to `comments.csv` with categorized comments.
- Added a new `comments.json` file with structured JSON data derived from `comments.csv`.
- Added a new `comments.tt` T4 template file to generate `comments.json` from `comments.csv`.
  • Loading branch information
bpmerkel committed Dec 8, 2024
1 parent 44c1916 commit a7ddbc1
Show file tree
Hide file tree
Showing 5 changed files with 412 additions and 4 deletions.
22 changes: 22 additions & 0 deletions Client/Client.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,16 @@
<Deterministic>false</Deterministic>
</PropertyGroup>

<ItemGroup>
<None Include="wwwroot\Model\comments.csv" />
<None Include="wwwroot\Model\comments.tt">
<ExcludeFromSingleFile>true</ExcludeFromSingleFile>
<CopyToPublishDirectory>Never</CopyToPublishDirectory>
<LastGenOutput>comments.json</LastGenOutput>
<Generator>TextTemplatingFileGenerator</Generator>
</None>
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="9.0.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="9.0.0" PrivateAssets="all" />
Expand All @@ -26,4 +36,16 @@
<Service Include="{508349b6-6b84-4df5-91f0-309beebad82d}" />
</ItemGroup>

<ItemGroup>
<Content Update="wwwroot\Model\comments.csv">
<CopyToPublishDirectory>Never</CopyToPublishDirectory>
</Content>
<Content Update="wwwroot\Model\comments.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<DependentUpon>comments.tt</DependentUpon>
<DesignTime>True</DesignTime>
<AutoGen>True</AutoGen>
</Content>
</ItemGroup>

</Project>
8 changes: 4 additions & 4 deletions Client/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
// Add the root component "HeadOutlet" to the builder
builder.RootComponents.Add<HeadOutlet>("head::after");

var apiHostAddress = new Uri(builder.Configuration["API_Prefix"] ?? builder.HostEnvironment.BaseAddress);

var apiHostAddress = new Uri(builder.HostEnvironment.BaseAddress); // builder.Configuration["API_Prefix"] ??
// Add a singleton service of type Model to the builder
builder.Services.AddSingleton(s => GetModel(apiHostAddress));
// Add MudBlazor services to the builder
Expand All @@ -33,9 +32,10 @@ async static Task<Model> GetModel(Uri baseAddress)
// Fetch the JSON file from the server
// see https://stackoverflow.com/questions/58523617/blazor-client-side-webassembly-reading-a-json-file-on-startup-cs

Debug.WriteLine($"Fetching model from {baseAddress}");
using var httpClient = new HttpClient();
var url = new Uri(baseAddress, "/api/CommentDataFunction");
//var url = new Uri(baseAddress, "/api/CommentDataFunction");
var url = new Uri(baseAddress, "/Model/comments.json");
Debug.WriteLine(url.AbsoluteUri);
var model = await httpClient.GetFromJsonAsync<Model>(url)
.ConfigureAwait(false);

Expand Down
53 changes: 53 additions & 0 deletions Client/wwwroot/Model/comments.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
Area,Section,Comment
Core Values,GreatJob,We were impressed with your because ...
Core Values,GreatJob,We really liked the way you ... You should be proud of your work!
Core Values,GreatJob,Good description of applying Core Values as participants in sports
Core Values,GreatJob,Great division of roles - effective use of each other's strengths
Core Values,GreatJob,The team notebook to capture progress toward goals shows good planning
Core Values,GreatJob,The team was good about acknowledging ideas from every one
Core Values,GreatJob,The use of rotating buddy pairs to do both robot and project work shows good Coopertition
Core Values,GreatJob,We liked how you showed us your team meeting agenda including activities for all four aspects of the challenge
Core Values,GreatJob,Your slogan of 'Coaches guide, Kids decide' reflects kids doing the work
Core Values,ThinkAbout,You are making good progress with ... One way you could improve would be ...
Core Values,ThinkAbout,As a next step, consider (or have you considered?) doing ...
Core Values,ThinkAbout,Consider expressing how the team explored new skills and ideas
Core Values,ThinkAbout,Consider expressing how the team used creativity and persistence to solve problems
Core Values,ThinkAbout,Consider expressing how the team applied what they learned to improve their world
Core Values,ThinkAbout,Consider expressing how the team demonstrated respect and embraced their differences
Core Values,ThinkAbout,Consider expressing how the team clearly showed they had worked as a team throughout their journey
Core Values,ThinkAbout,Consider expressing how the team clearly had fun and celebrated what they have achieved - as individuals and a group
Innovation Project,GreatJob,We were impressed with your because ...
Innovation Project,GreatJob,We really liked the way you ... You should be proud of your work!
Innovation Project,GreatJob,We loved the way you talked to the expert about __ and then used their feedback to improve your ideas
Innovation Project,ThinkAbout,You are making good progress with ... One way you could improve would be ...
Innovation Project,ThinkAbout,As a next step, consider (or have you considered?) doing ...
Innovation Project,ThinkAbout,Consider expressing a clear definition of the problem
Innovation Project,ThinkAbout,Consider expressing clear and detailed research from a variety of sources
Innovation Project,ThinkAbout,Consider engaging additional experts in your research
Innovation Project,ThinkAbout,Consider expressing clear evidence of an inclusive selection process
Innovation Project,ThinkAbout,Consider expressing clear evidence of an effective plan
Innovation Project,ThinkAbout,Consider expressing clearly how the team developed an innovative solution
Innovation Project,ThinkAbout,Consider expressing a detailed model or drawing that helps to share the solution
Innovation Project,ThinkAbout,Consider expressing how the team shared their solution with users and professionals
Innovation Project,ThinkAbout,Consider expressing clear evidence of improvements in your solution
Innovation Project,ThinkAbout,Make your presentation more engaging by ___
Innovation Project,ThinkAbout,Consider expressing more clearly your solution and its potential impact on others
Robot Design,GreatJob,We were impressed with your because ...
Robot Design,GreatJob,We really liked the way you ... You should be proud of your work!
Robot Design,GreatJob,Cohesive team strategy and goals
Robot Design,GreatJob,Like the use of comments
Robot Design,GreatJob,Liked the reuse of attachments
Robot Design,GreatJob,Love your use of sensors
Robot Design,GreatJob,Strategy: Easy missions first, location, matrix points
Robot Design,GreatJob,You have a good strategy
Robot Design,GreatJob,Fantastic Robot
Robot Design,GreatJob,Good use of basic design
Robot Design,GreatJob,We like your wire management
Robot Design,ThinkAbout,You are making good progress with ... One way you could improve would be ...
Robot Design,ThinkAbout,As a next step, consider (or have you considered?) doing ...
Robot Design,ThinkAbout,Consider presenting a RDES
Robot Design,ThinkAbout,Consider use of myblocks
Robot Design,ThinkAbout,Consider using EV3Lessons.com
Robot Design,ThinkAbout,Consider using sensors
Robot Design,ThinkAbout,Consider use of a jig
Robot Design,ThinkAbout,Review the challenge document
282 changes: 282 additions & 0 deletions Client/wwwroot/Model/comments.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,282 @@
{
"areas": [
{
"areaid": "d9e995b9-b9a1-447e-b680-864e6a187616",
"name": "Core Values",
"comments": [
{
"commentid": "ba71d5ec-7666-4e83-b3db-a54c999cfdce",
"text": "As a next step, consider (or have you considered?) doing ...",
"section": "ThinkAbout"
},
{
"commentid": "a9653655-58cb-41c5-b2be-1775ad0ac5d0",
"text": "Consider expressing how the team applied what they learned to improve their world",
"section": "ThinkAbout"
},
{
"commentid": "877b0efa-fe01-434d-9c9e-d389fb5fc0a0",
"text": "Consider expressing how the team clearly had fun and celebrated what they have achieved - as individuals and a group",
"section": "ThinkAbout"
},
{
"commentid": "4fb1f968-e251-41d6-b5be-775d0b6125f4",
"text": "Consider expressing how the team clearly showed they had worked as a team throughout their journey",
"section": "ThinkAbout"
},
{
"commentid": "d318f9de-5986-49ba-b5a1-d70d0b598676",
"text": "Consider expressing how the team demonstrated respect and embraced their differences",
"section": "ThinkAbout"
},
{
"commentid": "a1514935-d091-4005-9f89-8f0bde44f352",
"text": "Consider expressing how the team explored new skills and ideas",
"section": "ThinkAbout"
},
{
"commentid": "2bc6f6a1-61c3-4d78-9518-f57f506d8b6a",
"text": "Consider expressing how the team used creativity and persistence to solve problems",
"section": "ThinkAbout"
},
{
"commentid": "4cbc39b9-8ed7-447f-a7b4-3c08c58676da",
"text": "Good description of applying Core Values as participants in sports",
"section": "GreatJob"
},
{
"commentid": "67c72cbf-4610-4375-9cc1-78a70cf2b6be",
"text": "Great division of roles - effective use of each other's strengths",
"section": "GreatJob"
},
{
"commentid": "844f69e2-12af-4131-b1a4-0d223c34b157",
"text": "The team notebook to capture progress toward goals shows good planning",
"section": "GreatJob"
},
{
"commentid": "9308c045-4896-4786-a3f0-9f6cfc8a9f72",
"text": "The team was good about acknowledging ideas from every one",
"section": "GreatJob"
},
{
"commentid": "21937f78-16c6-4e28-88a5-7847487403f4",
"text": "The use of rotating buddy pairs to do both robot and project work shows good Coopertition",
"section": "GreatJob"
},
{
"commentid": "5ca8a9ad-13bf-4083-9500-4a8305e6d051",
"text": "We liked how you showed us your team meeting agenda including activities for all four aspects of the challenge",
"section": "GreatJob"
},
{
"commentid": "26be2f4e-a3b4-46c7-b100-44f86156f439",
"text": "We really liked the way you ... You should be proud of your work!",
"section": "GreatJob"
},
{
"commentid": "3a5ce5eb-cf4f-488e-a5d8-038c701d3bb9",
"text": "We were impressed with your because ...",
"section": "GreatJob"
},
{
"commentid": "f2dac551-61d7-45a3-adbc-4c7708d14c3e",
"text": "You are making good progress with ... One way you could improve would be ...",
"section": "ThinkAbout"
},
{
"commentid": "45d155e2-7e5d-46b5-b073-a197dce6bdea",
"text": "Your slogan of 'Coaches guide, Kids decide' reflects kids doing the work",
"section": "GreatJob"
}
]
},
{
"areaid": "230b6476-a4c6-406a-9a4b-43a424d8e1a5",
"name": "Innovation Project",
"comments": [
{
"commentid": "5d61cc89-7e23-4fe9-a389-9119fbc47efd",
"text": "As a next step, consider (or have you considered?) doing ...",
"section": "ThinkAbout"
},
{
"commentid": "5b0f7daa-51e3-4bde-b48d-2d8a42a29e10",
"text": "Consider engaging additional experts in your research",
"section": "ThinkAbout"
},
{
"commentid": "61884514-58ca-45d5-aaa5-d3ed9d0ec925",
"text": "Consider expressing a clear definition of the problem",
"section": "ThinkAbout"
},
{
"commentid": "196405be-6046-4b58-9b1f-6f274bc50476",
"text": "Consider expressing a detailed model or drawing that helps to share the solution",
"section": "ThinkAbout"
},
{
"commentid": "47295b5f-45e9-45cc-97d6-471d4bea9e90",
"text": "Consider expressing clear and detailed research from a variety of sources",
"section": "ThinkAbout"
},
{
"commentid": "c0d8bfda-20e9-41fe-9d2f-ab0131119722",
"text": "Consider expressing clear evidence of an effective plan",
"section": "ThinkAbout"
},
{
"commentid": "a0da7d55-a2b7-4611-98db-93bdf2cc75d2",
"text": "Consider expressing clear evidence of an inclusive selection process",
"section": "ThinkAbout"
},
{
"commentid": "d70fb79b-4d34-4eb3-8526-a6f7aee923d1",
"text": "Consider expressing clear evidence of improvements in your solution",
"section": "ThinkAbout"
},
{
"commentid": "e9c91716-5e9d-49e3-a471-d6934bdae33b",
"text": "Consider expressing clearly how the team developed an innovative solution",
"section": "ThinkAbout"
},
{
"commentid": "03ab349e-d77f-416a-9b87-9cfc91ab41e0",
"text": "Consider expressing how the team shared their solution with users and professionals",
"section": "ThinkAbout"
},
{
"commentid": "9e4c4cd7-7520-4e56-a542-ccb5de3ee91b",
"text": "Consider expressing more clearly your solution and its potential impact on others",
"section": "ThinkAbout"
},
{
"commentid": "67fefa77-b518-4912-a800-1163246cd0e8",
"text": "Make your presentation more engaging by ___",
"section": "ThinkAbout"
},
{
"commentid": "89b7fedf-fbaa-40b7-885d-46b7bbc9133f",
"text": "We loved the way you talked to the expert about __ and then used their feedback to improve your ideas",
"section": "GreatJob"
},
{
"commentid": "63d15cfb-b6a8-49de-9d95-b0fed3084780",
"text": "We really liked the way you ... You should be proud of your work!",
"section": "GreatJob"
},
{
"commentid": "99ee333b-a0e0-4db3-bebe-3de3b232435c",
"text": "We were impressed with your because ...",
"section": "GreatJob"
},
{
"commentid": "eabd2659-6d4a-411f-8a7a-754b488e5955",
"text": "You are making good progress with ... One way you could improve would be ...",
"section": "ThinkAbout"
}
]
},
{
"areaid": "efe56082-798c-43b0-a662-401f52b608f0",
"name": "Robot Design",
"comments": [
{
"commentid": "a27212e4-a167-4f87-835b-7a35468746a0",
"text": "As a next step, consider (or have you considered?) doing ...",
"section": "ThinkAbout"
},
{
"commentid": "86cf91fe-3406-4871-a883-6c57ce2a29aa",
"text": "Cohesive team strategy and goals",
"section": "GreatJob"
},
{
"commentid": "a2ba5feb-e7b1-4720-a6cf-846212379058",
"text": "Consider presenting a RDES",
"section": "ThinkAbout"
},
{
"commentid": "b12f4835-747d-4302-a082-88b482fbb3a3",
"text": "Consider use of a jig",
"section": "ThinkAbout"
},
{
"commentid": "b815083e-1712-4f43-8f4a-163365cc7496",
"text": "Consider use of myblocks",
"section": "ThinkAbout"
},
{
"commentid": "ceabae41-009d-481c-9a94-84f270361d8e",
"text": "Consider using EV3Lessons.com",
"section": "ThinkAbout"
},
{
"commentid": "d73a3b16-c082-4689-9eb5-e924a2039ccb",
"text": "Consider using sensors",
"section": "ThinkAbout"
},
{
"commentid": "acbea96c-4cec-434d-b6cc-a98174b6c24e",
"text": "Fantastic Robot",
"section": "GreatJob"
},
{
"commentid": "833f6a9b-c021-4696-900b-866b958564d2",
"text": "Good use of basic design",
"section": "GreatJob"
},
{
"commentid": "2863569a-663d-4785-9571-815de659103c",
"text": "Like the use of comments",
"section": "GreatJob"
},
{
"commentid": "fb512b27-7892-4c99-8951-8f8ddfd08980",
"text": "Liked the reuse of attachments",
"section": "GreatJob"
},
{
"commentid": "03868480-8bbc-4f05-94c1-c8a219791e97",
"text": "Love your use of sensors",
"section": "GreatJob"
},
{
"commentid": "a3f6531b-fcf2-4176-bd5a-5f2a7b024551",
"text": "Review the challenge document",
"section": "ThinkAbout"
},
{
"commentid": "dfc8e3ac-9750-4478-be65-f5ce7a620d3c",
"text": "Strategy: Easy missions first, location, matrix points",
"section": "GreatJob"
},
{
"commentid": "de38dbf8-03e8-4eb7-a236-20ce8411c8ba",
"text": "We like your wire management",
"section": "GreatJob"
},
{
"commentid": "c024047b-87c7-4eed-aa77-f16ff13c77e2",
"text": "We really liked the way you ... You should be proud of your work!",
"section": "GreatJob"
},
{
"commentid": "2ba29f49-4e0c-4dd7-a41f-020522bc340c",
"text": "We were impressed with your because ...",
"section": "GreatJob"
},
{
"commentid": "df1c2bb7-1a63-4b8b-9866-702191890e8c",
"text": "You are making good progress with ... One way you could improve would be ...",
"section": "ThinkAbout"
},
{
"commentid": "b5315b67-a370-48ff-8d18-6662e1b15bb9",
"text": "You have a good strategy",
"section": "GreatJob"
}
]
}
]
}
Loading

0 comments on commit a7ddbc1

Please sign in to comment.