diff --git a/app/Nova/TrainingResource.php b/app/Nova/TrainingResource.php index 989cfbce3..1a32706d3 100644 --- a/app/Nova/TrainingResource.php +++ b/app/Nova/TrainingResource.php @@ -76,6 +76,15 @@ public function fields(Request $request): array ->nullable() ->help('Optional YouTube URL. Supports youtu.be, watch, embed, shorts.'), + Text::make('Video script URL', 'video_script_url') + ->nullable() + ->rules('nullable', 'url') + ->help('Optional link shown under the video, e.g. DOCX/PDF script.'), + + Text::make('Video script link text', 'video_script_text') + ->nullable() + ->help('Optional. Defaults to "Download the video script".'), + Text::make('Body image', 'body_image') ->nullable() ->help('Optional image path/URL (supports Amazon S3/CloudFront).'), @@ -87,6 +96,18 @@ public function fields(Request $request): array ->nullable() ->help('Main training content area'), + Trix::make('PDF links section', 'pdf_links_section') + ->nullable() + ->help('Optional area for numbered downloadable resources (e.g. 1-6 links).'), + + Trix::make('Contacts section', 'contacts_section') + ->nullable() + ->help('Optional contacts/extra info block.'), + + Trix::make('Register box section', 'register_box_section') + ->nullable() + ->help('Optional text shown in a highlighted callout box (register on map, hashtags, etc).'), + Text::make('Button text', 'button_text')->nullable(), Text::make('Button URL', 'button_url') diff --git a/app/TrainingResource.php b/app/TrainingResource.php index 46ee8fbb9..dfa6640cb 100644 --- a/app/TrainingResource.php +++ b/app/TrainingResource.php @@ -20,9 +20,14 @@ class TrainingResource extends Model 'intro', 'highlight_box', 'video_url', + 'video_script_url', + 'video_script_text', 'body_image', 'body_image_alt', 'content', + 'pdf_links_section', + 'contacts_section', + 'register_box_section', 'button_text', 'button_url', 'secondary_button_text', diff --git a/database/migrations/2026_03_19_140000_add_content_sections_to_training_resources_table.php b/database/migrations/2026_03_19_140000_add_content_sections_to_training_resources_table.php new file mode 100644 index 000000000..9720e5e8c --- /dev/null +++ b/database/migrations/2026_03_19_140000_add_content_sections_to_training_resources_table.php @@ -0,0 +1,34 @@ +longText('pdf_links_section')->nullable()->after('content'); + $table->longText('contacts_section')->nullable()->after('pdf_links_section'); + $table->longText('register_box_section')->nullable()->after('contacts_section'); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('training_resources', function (Blueprint $table) { + $table->dropColumn([ + 'pdf_links_section', + 'contacts_section', + 'register_box_section', + ]); + }); + } +}; diff --git a/database/migrations/2026_03_19_150000_add_video_script_fields_to_training_resources_table.php b/database/migrations/2026_03_19_150000_add_video_script_fields_to_training_resources_table.php new file mode 100644 index 000000000..d9119e97d --- /dev/null +++ b/database/migrations/2026_03_19_150000_add_video_script_fields_to_training_resources_table.php @@ -0,0 +1,32 @@ +string('video_script_url')->nullable()->after('video_url'); + $table->string('video_script_text')->nullable()->after('video_script_url'); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('training_resources', function (Blueprint $table) { + $table->dropColumn([ + 'video_script_url', + 'video_script_text', + ]); + }); + } +}; diff --git a/database/seeders/TrainingResourceVetToolkitSeeder.php b/database/seeders/TrainingResourceVetToolkitSeeder.php new file mode 100644 index 000000000..6d172aec6 --- /dev/null +++ b/database/seeders/TrainingResourceVetToolkitSeeder.php @@ -0,0 +1,80 @@ + 'eu-code-week-4-vet'], + [ + 'card_title' => 'EU CODE WEEK 4 VET', + 'card_author' => 'Scientific author: Flavio Renga & Marta Risoli', + 'card_image' => '/images/vet-toolkit-images.png', + 'page_title' => 'EU CODE WEEK 4 VET', + 'hero_author' => 'VET TOOLKIT', + 'highlight_box' => <<Scientific author: Flavio Renga & Marta Risoli - EdTech researchers at Fondazione LINKS, EU Code Week Italian HUB.
+Instructional design, project management, internationalisation: Veronica Ruberti & Lucia Terrone - Fondazione LINKS, EU Code Week Italian HUB Coordinator
+HTML, + 'intro' => <<In today's rapidly evolving technological landscape, it is crucial to equip Vocational Education and Training (VET) students both with technical competencies-such as coding, 3D modelling, and the Internet of Things (IoT)-and with essential social skills, including collaboration, problem-solving, and creativity. These skills are not just valuable for those pursuing a career in the tech industry but can open doors to a wide range of opportunities across various fields. +To support this vision, the VET Toolkit was created as part of the EU initiative Code Week to support educators to facilitate activities for students between 13 and 18 years of age.
+The toolkit is based on the Creative Learning approach and the TinkerCad tool to help students develop digital skills, acquire social and emotional competencies, and stay motivated to pursue careers in the digital field.
+The Creative Learning approach is based on the 4 Ps - Projects, Passion, Peers, and Play -, and it offers a flexible framework that shifts the focus from direct instruction to personalized, hands-on exploration. The approach also promotes inclusive learning environments, where teachers act as facilitators and peer students collaborate in flexible spaces that encourage experimentation and reduce the fear of mistakes.
+HTML, + 'body_image' => '/images/vet-toolkit-images.png', + 'body_image_alt' => 'EU Code Week 4 VET learning approach', + 'content' => <<Who is the VET Toolkit for? +The VET toolkit is aimed at VET teachers and educators who wants to:
+In this page you will discover the Learning Creative approach through an asynchronous training path in small, sequential, easy-to-follow steps, using accessible language. Every step is a downloadable PDF, easy to print and use in class. It contains theoretical background, lesson outlines, activity descriptions, facilitation prompts, and guidelines for teachers.
+The objective is to guide you from learning the Creative Learning approach to applying it in the classroom, supported by lesson plans and scaffolding materials.
+Let's start!
+HTML, + 'pdf_links_section' => <<PDF titles +For information, curiosities, and insights contact: codeweek@linksfoundation.com
+HTML, + 'secondary_button_text' => 'Register activity', + 'secondary_button_url' => 'https://codeweek.eu/add?skip=1', + 'register_box_section' => <<Every time you run an activity in class, during a school event, a team building, or a training course, register it on the map of the European Code Week with the hashtag #DreamJobsinDigital. Every organizer will receive a participation certificate for their commitment and will contribute to a campaign raising awareness of digital skills and careers. +If you want to get in touch with an international group of enthusiastic teachers, sign up for the EU Code Week teachers' Facebook group! To take a further step and collaborate with other schools in your country or across borders, join the Code Week 4 All challenge.
+HTML, + 'meta_title' => 'EU Code Week 4 VET - Training Toolkit', + 'meta_description' => 'A practical toolkit for VET teachers to run inclusive, creative, project-based digital activities with students aged 13-18.', + 'position' => 0, + 'active' => true, + ] + ); + } +} diff --git a/docs/training-resource-vet-toolkit-template.md b/docs/training-resource-vet-toolkit-template.md new file mode 100644 index 000000000..22ea4fa1d --- /dev/null +++ b/docs/training-resource-vet-toolkit-template.md @@ -0,0 +1,112 @@ +# Training Resource Nova Template (VET Toolkit) + +Use this as a copy/paste blueprint when creating a new `Training Resource` in Nova. + +## Core + +- **Slug**: `eu-code-week-4-vet` +- **Card title**: `EU CODE WEEK 4 VET` +- **Card author**: `Scientific author: Flavio Renga & Marta Risoli` +- **Card image**: `https://...` (S3/CloudFront URL) or `/img/learning/...` +- **Page title**: `EU CODE WEEK 4 VET` +- **Hero author**: `VET TOOLKIT` + +## Intro (Trix) + +Paste: + +```html +In today's rapidly evolving technological landscape, it is crucial to equip Vocational Education and Training (VET) students both with technical competencies—such as coding, 3D modelling, and the Internet of Things (IoT)—and with essential social skills, including collaboration, problem-solving, and creativity. These skills are not just valuable for those pursuing a career in the tech industry but can open doors to a wide range of opportunities across various fields.
+To support this vision, the VET Toolkit was created as part of the EU initiative Code Week to support educators to facilitate activities for students between 13 and 18 years of age.
+The toolkit is based on the Creative Learning approach and the TinkerCad tool to help students develop digital skills, acquire social and emotional competencies, and stay motivated to pursue careers in the digital field.
+The Creative Learning approach is based on the 4 Ps — Projects, Passion, Peers, and Play — and it offers a flexible framework that shifts the focus from direct instruction to personalized, hands-on exploration.
+``` + +## Highlight box (Trix) + +Paste: + +```html +Scientific author: Flavio Renga & Marta Risoli - EdTech researchers at Fondazione LINKS, EU Code Week Italian HUB.
+Instructional design, project management, internationalisation: Veronica Ruberti & Lucia Terrone - Fondazione LINKS, EU Code Week Italian HUB Coordinator.
+``` + +## Video URL + +- Add YouTube URL (optional), e.g. `https://www.youtube.com/watch?v=XXXXXXXXXXX` + +## Body image + +- Add body image URL/path (optional), e.g. `https://your-bucket.s3.eu-west-1.amazonaws.com/training/vet-toolkit-cover.png` +- **Body image alt text**: `EU Code Week 4 VET toolkit image` + +## Content (Trix) + +Paste: + +```html +The VET toolkit is aimed at VET teachers and educators who want to:
+In this page you will discover the Creative Learning approach through an asynchronous training path in small, sequential, easy-to-follow steps, using accessible language.
+The objective is to guide you from learning the Creative Learning approach to applying it in the classroom, supported by lesson plans and scaffolding materials.
+Let's start!
+``` + +## PDF links section (Trix) + +Paste: + +```html +For information, curiosities, and insights contact: codeweek@linksfoundation.com
+``` + +## Register box section (Trix) + +Paste: + +```html +Every time you run an activity in class, during a school event, a team building, or a training course, register it on the map of the European Code Week with the hashtag #DreamJobsinDigital. Every organizer will receive a participation certificate for their commitment and will contribute to a campaign raising awareness of digital skills and careers.
+If you want to get in touch with an international group of enthusiastic teachers, sign up for the EU Code Week teachers' Facebook group. To take a further step and collaborate with other schools in your country or across borders, join the Code Week 4 All challenge.
+``` + +## SEO (optional) + +- **Meta title**: `EU Code Week 4 VET – Training Toolkit` +- **Meta description**: `A practical toolkit for VET teachers to run inclusive, creative, project-based digital activities with students aged 13-18.` + +## Publish controls + +- **Position**: lower number = appears earlier on `/training` +- **Active**: enabled diff --git a/public/images/vet-toolkit-images.png b/public/images/vet-toolkit-images.png new file mode 100644 index 000000000..29733febc Binary files /dev/null and b/public/images/vet-toolkit-images.png differ diff --git a/resources/views/training/show.blade.php b/resources/views/training/show.blade.php index 45ecbd7e5..317f5e2ba 100644 --- a/resources/views/training/show.blade.php +++ b/resources/views/training/show.blade.php @@ -9,6 +9,12 @@ $displayTitle = $trainingResource->page_title ?: $trainingResource->card_title ?: 'Training'; $pageTitle = $trainingResource->meta_title ?: ($displayTitle . ' – EU Code Week'); $pageDescription = $trainingResource->meta_description ?: $fallbackDescription; + + $introClass = "text-[#20262C] font-normal text-lg md:text-xl p-0 mb-6 [&_p]:p-0 [&_p]:mb-6 [&_a]:text-dark-blue [&_a]:hover:underline"; + $contentClass = "text-[#333E48] font-normal text-lg md:text-xl p-0 mb-6 [&_p]:p-0 [&_p]:mb-6 [&_h2]:text-dark-blue [&_h2]:text-2xl [&_h2]:md:text-3xl [&_h2]:leading-[44px] [&_h2]:font-medium [&_h2]:font-['Montserrat'] [&_h2]:mb-4 [&_ul]:pl-8 [&_ul]:m-0 [&_ul]:mb-6 [&_ul]:list-disc [&_li]:p-0 [&_li]:text-lg [&_li]:font-normal [&_li]:leading-7 [&_li]:text-default [&_a]:text-dark-blue [&_a]:hover:underline"; + $pdfClass = "text-[#333E48] font-normal text-lg md:text-xl p-0 mb-6 [&_p]:p-0 [&_p]:mb-4 [&_h2]:text-dark-blue [&_h2]:text-2xl [&_h2]:md:text-3xl [&_h2]:leading-[44px] [&_h2]:font-medium [&_h2]:font-['Montserrat'] [&_h2]:mb-4 [&_ul]:m-0 [&_ul]:mb-6 [&_ul]:list-none [&_ol]:m-0 [&_ol]:mb-6 [&_ol]:list-none [&_li]:p-0 [&_li]:mb-2 [&_li]:font-normal [&_li]:leading-7 [&_li]:text-default [&_a]:text-lg [&_a]:text-dark-blue [&_a]:hover:underline"; + $contactsClass = "text-[#333E48] font-normal text-lg md:text-xl p-0 mb-8 [&_p]:p-0 [&_p]:mb-4 [&_h2]:text-dark-blue [&_h2]:text-2xl [&_h2]:md:text-3xl [&_h2]:leading-[44px] [&_h2]:font-medium [&_h2]:font-['Montserrat'] [&_h2]:mb-4 [&_a]:text-dark-blue [&_a]:hover:underline"; + $registerClass = "text-[#333E48] font-normal text-base md:text-lg [&_p]:p-0 [&_p]:mb-4 [&_p:last-child]:mb-0 [&_a]:font-medium [&_a]:text-dark-blue [&_a]:hover:underline"; @endphp @section('title', $pageTitle) @@ -22,16 +28,16 @@ ])