diff --git a/core/static/images/uk-map.svg b/core/static/images/uk-map.svg new file mode 100644 index 0000000000..f894ed8831 --- /dev/null +++ b/core/static/images/uk-map.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/core/templatetags/content_tags.py b/core/templatetags/content_tags.py index 406e68dfd2..303797b02f 100644 --- a/core/templatetags/content_tags.py +++ b/core/templatetags/content_tags.py @@ -435,6 +435,24 @@ def get_icon_path(url): return '' +@register.filter +def get_international_icon_path(url): + url_to_icon_list = ( + ('uk-investment-zones', 'Icon-investment-zones'), + ('uk-tax-and-incentives', 'Icon-tax-and-incentives'), + ('uk-talent-and-labour', 'Icon-talent-and-labour'), + ('uk-infrastructure', 'Icon-infrastructure'), + ('clean-growth-in-the-uk', 'Icon-clean-growth'), + ('freeports-in-the-uk', 'Icon-freeports'), + ('uk-innovation', 'Icon-innovation'), + ('sectors', 'Icon-sectors'), + ) + for url_to_icon in url_to_icon_list: + if url_to_icon[0] in url: + return 'international/includes/svg/' + url_to_icon[1] + '.svg' + return '' + + @register.simple_tag def render_automated_list_page_card_content(page, request, module_completion_data): if request.user.is_authenticated and module_completion_data: diff --git a/international/cms_panels.py b/international/cms_panels.py new file mode 100644 index 0000000000..0c98a693b8 --- /dev/null +++ b/international/cms_panels.py @@ -0,0 +1,26 @@ +from wagtail.admin.panels import FieldPanel, MultiFieldPanel + + +class GreatInternationalHomePagePanels: + content_panels = [ + FieldPanel('title'), + MultiFieldPanel( + heading='Hero', + classname='collapsible', + children=[ + FieldPanel('hero_image'), + FieldPanel('hero_mobile_image'), + FieldPanel('hero_text'), + FieldPanel('hero_subtitle'), + ], + ), + MultiFieldPanel( + heading='Digital Entry Point CTA', + classname='collapsible', + children=[ + FieldPanel('dep_title'), + FieldPanel('dep_sub_title'), + FieldPanel('dep_cards'), + ], + ), + ] diff --git a/international/migrations/0001_initial.py b/international/migrations/0001_initial.py new file mode 100644 index 0000000000..0ee842c633 --- /dev/null +++ b/international/migrations/0001_initial.py @@ -0,0 +1,539 @@ +# Generated by Django 4.1.13 on 2024-02-09 13:35 + +import django.db.models.deletion +import great_components.mixins +import wagtail.blocks +import wagtail.fields +from django.db import migrations, models + +import core.mixins +import international.cms_panels + + +class Migration(migrations.Migration): + initial = True + + dependencies = [ + ('wagtailcore', '0089_log_entry_data_json_null_to_object'), + ('core', '0133_alter_detailpage_body'), + ] + + operations = [ + migrations.CreateModel( + name='GreatInternationalHomePage', + fields=[ + ( + 'page_ptr', + models.OneToOneField( + auto_created=True, + on_delete=django.db.models.deletion.CASCADE, + parent_link=True, + primary_key=True, + serialize=False, + to='wagtailcore.page', + ), + ), + ( + 'canonical_url', + models.URLField( + blank=True, + help_text="Leave blank to use the page's URL.", + max_length=255, + verbose_name='Canonical URL', + ), + ), + ( + 'struct_org_type', + models.CharField( + blank=True, + choices=[ + ('Organization', 'Organization'), + ('Airline', 'Organization > Airline'), + ('Corporation', 'Organization > Corporation'), + ('EducationalOrganization', 'Organization > EducationalOrganization'), + ('CollegeOrUniversity', 'Organization > EducationalOrganization > CollegeOrUniversity'), + ('ElementarySchool', 'Organization > EducationalOrganization > ElementarySchool'), + ('HighSchool', 'Organization > EducationalOrganization > HighSchool'), + ('MiddleSchool', 'Organization > EducationalOrganization > MiddleSchool'), + ('Preschool', 'Organization > EducationalOrganization > Preschool'), + ('School', 'Organization > EducationalOrganization > School'), + ('GovernmentOrganization', 'Organization > GovernmentOrganization'), + ('LocalBusiness', 'Organization > LocalBusiness'), + ('AnimalShelter', 'Organization > LocalBusiness > AnimalShelter'), + ('AutomotiveBusiness', 'Organization > LocalBusiness > AutomotiveBusiness'), + ('AutoBodyShop', 'Organization > LocalBusiness > AutomotiveBusiness > AutoBodyShop'), + ('AutoDealer', 'Organization > LocalBusiness > AutomotiveBusiness > AutoDealer'), + ('AutoPartsStore', 'Organization > LocalBusiness > AutomotiveBusiness > AutoPartsStore'), + ('AutoRental', 'Organization > LocalBusiness > AutomotiveBusiness > AutoRental'), + ('AutoRepair', 'Organization > LocalBusiness > AutomotiveBusiness > AutoRepair'), + ('AutoWash', 'Organization > LocalBusiness > AutomotiveBusiness > AutoWash'), + ('GasStation', 'Organization > LocalBusiness > AutomotiveBusiness > GasStation'), + ( + 'MotorcycleDealer', + 'Organization > LocalBusiness > AutomotiveBusiness > MotorcycleDealer', + ), + ( + 'MotorcycleRepair', + 'Organization > LocalBusiness > AutomotiveBusiness > MotorcycleRepair', + ), + ('ChildCare', 'Organization > LocalBusiness > ChildCare'), + ('Dentist', 'Organization > LocalBusiness > Dentist'), + ('DryCleaningOrLaundry', 'Organization > LocalBusiness > DryCleaningOrLaundry'), + ('EmergencyService', 'Organization > LocalBusiness > EmergencyService'), + ('FireStation', 'Organization > LocalBusiness > EmergencyService > FireStation'), + ('Hospital', 'Organization > LocalBusiness > EmergencyService > Hospital'), + ('PoliceStation', 'Organization > LocalBusiness > EmergencyService > PoliceStation'), + ('EmploymentAgency', 'Organization > LocalBusiness > EmploymentAgency'), + ('EntertainmentBusiness', 'Organization > LocalBusiness > EntertainmentBusiness'), + ( + 'AdultEntertainment', + 'Organization > LocalBusiness > EntertainmentBusiness > AdultEntertainment', + ), + ('AmusementPark', 'Organization > LocalBusiness > EntertainmentBusiness > AmusementPark'), + ('ArtGallery', 'Organization > LocalBusiness > EntertainmentBusiness > ArtGallery'), + ('Casino', 'Organization > LocalBusiness > EntertainmentBusiness > Casino'), + ('ComedyClub', 'Organization > LocalBusiness > EntertainmentBusiness > ComedyClub'), + ('MovieTheater', 'Organization > LocalBusiness > EntertainmentBusiness > MovieTheater'), + ('NightClub', 'Organization > LocalBusiness > EntertainmentBusiness > NightClub'), + ('FinancialService', 'Organization > LocalBusiness > FinancialService'), + ( + 'AccountingService', + 'Organization > LocalBusiness > FinancialService > AccountingService', + ), + ('AutomatedTeller', 'Organization > LocalBusiness > FinancialService > AutomatedTeller'), + ( + 'BankOrCreditUnion', + 'Organization > LocalBusiness > FinancialService > BankOrCreditUnion', + ), + ('InsuranceAgency', 'Organization > LocalBusiness > FinancialService > InsuranceAgency'), + ('FoodEstablishment', 'Organization > LocalBusiness > FoodEstablishment'), + ('Bakery', 'Organization > LocalBusiness > FoodEstablishment > Bakery'), + ('BarOrPub', 'Organization > LocalBusiness > FoodEstablishment > BarOrPub'), + ('Brewery', 'Organization > LocalBusiness > FoodEstablishment > Brewery'), + ('CafeOrCoffeeShop', 'Organization > LocalBusiness > FoodEstablishment > CafeOrCoffeeShop'), + ( + 'FastFoodRestaurant', + 'Organization > LocalBusiness > FoodEstablishment > FastFoodRestaurant', + ), + ('IceCreamShop', 'Organization > LocalBusiness > FoodEstablishment > IceCreamShop'), + ('Restaurant', 'Organization > LocalBusiness > FoodEstablishment > Restaurant'), + ('Winery', 'Organization > LocalBusiness > FoodEstablishment > Winery'), + ('GovernmentOffice', 'Organization > LocalBusiness > GovernmentOffice'), + ('PostOffice', 'Organization > LocalBusiness > GovernmentOffice > PostOffice'), + ('HealthAndBeautyBusiness', 'Organization > LocalBusiness > HealthAndBeautyBusiness'), + ('BeautySalon', 'Organization > LocalBusiness > HealthAndBeautyBusiness > BeautySalon'), + ('DaySpa', 'Organization > LocalBusiness > HealthAndBeautyBusiness > DaySpa'), + ('HairSalon', 'Organization > LocalBusiness > HealthAndBeautyBusiness > HairSalon'), + ('HealthClub', 'Organization > LocalBusiness > HealthAndBeautyBusiness > HealthClub'), + ('NailSalon', 'Organization > LocalBusiness > HealthAndBeautyBusiness > NailSalon'), + ('TattooParlor', 'Organization > LocalBusiness > HealthAndBeautyBusiness > TattooParlor'), + ( + 'HomeAndConstructionBusiness', + 'Organization > LocalBusiness > HomeAndConstructionBusiness', + ), + ('Electrician', 'Organization > LocalBusiness > HomeAndConstructionBusiness > Electrician'), + ( + 'GeneralContractor', + 'Organization > LocalBusiness > HomeAndConstructionBusiness > GeneralContractor', + ), + ( + 'HVACBusiness', + 'Organization > LocalBusiness > HomeAndConstructionBusiness > HVACBusiness', + ), + ( + 'HousePainter', + 'Organization > LocalBusiness > HomeAndConstructionBusiness > HousePainter', + ), + ('Locksmith', 'Organization > LocalBusiness > HomeAndConstructionBusiness > Locksmith'), + ( + 'MovingCompany', + 'Organization > LocalBusiness > HomeAndConstructionBusiness > MovingCompany', + ), + ('Plumber', 'Organization > LocalBusiness > HomeAndConstructionBusiness > Plumber'), + ( + 'RoofingContractor', + 'Organization > LocalBusiness > HomeAndConstructionBusiness > RoofingContractor', + ), + ('InternetCafe', 'Organization > LocalBusiness > InternetCafe'), + ('LegalService', 'Organization > LocalBusiness > LegalService'), + ('Attorney', 'Organization > LocalBusiness > LegalService > Attorney'), + ('Notary', 'Organization > LocalBusiness > LegalService > Notary'), + ('Library', 'Organization > LocalBusiness > Library'), + ('LodgingBusiness', 'Organization > LocalBusiness > LodgingBusiness'), + ('BedAndBreakfast', 'Organization > LocalBusiness > LodgingBusiness > BedAndBreakfast'), + ('Campground', 'Organization > LocalBusiness > LodgingBusiness > Campground'), + ('Hostel', 'Organization > LocalBusiness > LodgingBusiness > Hostel'), + ('Hotel', 'Organization > LocalBusiness > LodgingBusiness > Hotel'), + ('Motel', 'Organization > LocalBusiness > LodgingBusiness > Motel'), + ('Resort', 'Organization > LocalBusiness > LodgingBusiness > Resort'), + ('ProfessionalService', 'Organization > LocalBusiness > ProfessionalService'), + ('RadioStation', 'Organization > LocalBusiness > RadioStation'), + ('RealEstateAgent', 'Organization > LocalBusiness > RealEstateAgent'), + ('RecyclingCenter', 'Organization > LocalBusiness > RecyclingCenter'), + ('SelfStorage', 'Organization > LocalBusiness > SelfStorage'), + ('ShoppingCenter', 'Organization > LocalBusiness > ShoppingCenter'), + ('SportsActivityLocation', 'Organization > LocalBusiness > SportsActivityLocation'), + ('BowlingAlley', 'Organization > LocalBusiness > SportsActivityLocation > BowlingAlley'), + ('ExerciseGym', 'Organization > LocalBusiness > SportsActivityLocation > ExerciseGym'), + ('GolfCourse', 'Organization > LocalBusiness > SportsActivityLocation > GolfCourse'), + ('HealthClub', 'Organization > LocalBusiness > SportsActivityLocation > HealthClub'), + ( + 'PublicSwimmingPool', + 'Organization > LocalBusiness > SportsActivityLocation > PublicSwimmingPool', + ), + ('SkiResort', 'Organization > LocalBusiness > SportsActivityLocation > SkiResort'), + ('SportsClub', 'Organization > LocalBusiness > SportsActivityLocation > SportsClub'), + ( + 'StadiumOrArena', + 'Organization > LocalBusiness > SportsActivityLocation > StadiumOrArena', + ), + ('TennisComplex', 'Organization > LocalBusiness > SportsActivityLocation > TennisComplex'), + ('Store', 'Organization > LocalBusiness > Store'), + ('AutoPartsStore', 'Organization > LocalBusiness > Store > AutoPartsStore'), + ('BikeStore', 'Organization > LocalBusiness > Store > BikeStore'), + ('BookStore', 'Organization > LocalBusiness > Store > BookStore'), + ('ClothingStore', 'Organization > LocalBusiness > Store > ClothingStore'), + ('ComputerStore', 'Organization > LocalBusiness > Store > ComputerStore'), + ('ConvenienceStore', 'Organization > LocalBusiness > Store > ConvenienceStore'), + ('DepartmentStore', 'Organization > LocalBusiness > Store > DepartmentStore'), + ('ElectronicsStore', 'Organization > LocalBusiness > Store > ElectronicsStore'), + ('Florist', 'Organization > LocalBusiness > Store > Florist'), + ('FurnitureStore', 'Organization > LocalBusiness > Store > FurnitureStore'), + ('GardenStore', 'Organization > LocalBusiness > Store > GardenStore'), + ('GroceryStore', 'Organization > LocalBusiness > Store > GroceryStore'), + ('HardwareStore', 'Organization > LocalBusiness > Store > HardwareStore'), + ('HobbyShop', 'Organization > LocalBusiness > Store > HobbyShop'), + ('HomeGoodsStore', 'Organization > LocalBusiness > Store > HomeGoodsStore'), + ('JewelryStore', 'Organization > LocalBusiness > Store > JewelryStore'), + ('LiquorStore', 'Organization > LocalBusiness > Store > LiquorStore'), + ('MensClothingStore', 'Organization > LocalBusiness > Store > MensClothingStore'), + ('MobilePhoneStore', 'Organization > LocalBusiness > Store > MobilePhoneStore'), + ('MovieRentalStore', 'Organization > LocalBusiness > Store > MovieRentalStore'), + ('MusicStore', 'Organization > LocalBusiness > Store > MusicStore'), + ('OfficeEquipmentStore', 'Organization > LocalBusiness > Store > OfficeEquipmentStore'), + ('OutletStore', 'Organization > LocalBusiness > Store > OutletStore'), + ('PawnShop', 'Organization > LocalBusiness > Store > PawnShop'), + ('PetStore', 'Organization > LocalBusiness > Store > PetStore'), + ('ShoeStore', 'Organization > LocalBusiness > Store > ShoeStore'), + ('SportingGoodsStore', 'Organization > LocalBusiness > Store > SportingGoodsStore'), + ('TireShop', 'Organization > LocalBusiness > Store > TireShop'), + ('ToyStore', 'Organization > LocalBusiness > Store > ToyStore'), + ('WholesaleStore', 'Organization > LocalBusiness > Store > WholesaleStore'), + ('TelevisionStation', 'Organization > LocalBusiness > TelevisionStation'), + ('TouristInformationCenter', 'Organization > LocalBusiness > TouristInformationCenter'), + ('TravelAgency', 'Organization > LocalBusiness > TravelAgency'), + ('MedicalOrganization', 'Organization > MedicalOrganization'), + ('Dentist', 'Organization > MedicalOrganization > Dentist'), + ('Hospital', 'Organization > MedicalOrganization > Hospital'), + ('Pharmacy', 'Organization > MedicalOrganization > Pharmacy'), + ('Physician', 'Organization > MedicalOrganization > Physician'), + ('NGO', 'Organization > NGO'), + ('PerformingGroup', 'Organization > PerformingGroup'), + ('DanceGroup', 'Organization > PerformingGroup > DanceGroup'), + ('MusicGroup', 'Organization > PerformingGroup > MusicGroup'), + ('TheaterGroup', 'Organization > PerformingGroup > TheaterGroup'), + ('SportsOrganization', 'Organization > SportsOrganization'), + ('SportsTeam', 'Organization > SportsOrganization > SportsTeam'), + ], + default='', + help_text='If blank, no structured data will be used on this page.', + max_length=255, + verbose_name='Organization type', + ), + ), + ( + 'struct_org_name', + models.CharField( + blank=True, + default='', + help_text='Leave blank to use the site name in Settings > Sites', + max_length=255, + verbose_name='Organization name', + ), + ), + ( + 'struct_org_phone', + models.CharField( + blank=True, + help_text='Include country code for best results. For example: +1-216-555-8000', + max_length=255, + verbose_name='Telephone number', + ), + ), + ( + 'struct_org_address_street', + models.CharField( + blank=True, + help_text='House number and street. For example, 55 Public Square Suite 1710', + max_length=255, + verbose_name='Street address', + ), + ), + ( + 'struct_org_address_locality', + models.CharField( + blank=True, + help_text='City or locality. For example, Cleveland', + max_length=255, + verbose_name='City', + ), + ), + ( + 'struct_org_address_region', + models.CharField( + blank=True, + help_text='State, province, county, or region. For example, OH', + max_length=255, + verbose_name='State', + ), + ), + ( + 'struct_org_address_postal', + models.CharField( + blank=True, + help_text='Zip or postal code. For example, 44113', + max_length=255, + verbose_name='Postal code', + ), + ), + ( + 'struct_org_address_country', + models.CharField( + blank=True, + help_text='For example, USA. Two-letter ISO 3166-1 alpha-2 country code is also acceptable https://en.wikipedia.org/wiki/ISO_3166-1', + max_length=255, + verbose_name='Country', + ), + ), + ( + 'struct_org_geo_lat', + models.DecimalField( + blank=True, decimal_places=8, max_digits=11, null=True, verbose_name='Geographic latitude' + ), + ), + ( + 'struct_org_geo_lng', + models.DecimalField( + blank=True, decimal_places=8, max_digits=11, null=True, verbose_name='Geographic longitude' + ), + ), + ( + 'struct_org_hours', + wagtail.fields.StreamField( + [ + ( + 'hours', + wagtail.blocks.StructBlock( + [ + ( + 'days', + wagtail.blocks.MultipleChoiceBlock( + choices=[ + ('Monday', 'Monday'), + ('Tuesday', 'Tuesday'), + ('Wednesday', 'Wednesday'), + ('Thursday', 'Thursday'), + ('Friday', 'Friday'), + ('Saturday', 'Saturday'), + ('Sunday', 'Sunday'), + ], + help_text='For late night hours past 23:59, define each day in a separate block.', + verbose_name='Days', + ), + ), + ('start_time', wagtail.blocks.TimeBlock(verbose_name='Opening time')), + ('end_time', wagtail.blocks.TimeBlock(verbose_name='Closing time')), + ] + ), + ) + ], + blank=True, + use_json_field=True, + verbose_name='Hours of operation', + ), + ), + ( + 'struct_org_actions', + wagtail.fields.StreamField( + [ + ( + 'actions', + wagtail.blocks.StructBlock( + [ + ( + 'action_type', + wagtail.blocks.ChoiceBlock( + choices=[ + ('OrderAction', 'OrderAction'), + ('ReserveAction', 'ReserveAction'), + ], + verbose_name='Action Type', + ), + ), + ('target', wagtail.blocks.URLBlock(verbose_name='Target URL')), + ( + 'language', + wagtail.blocks.CharBlock( + default='en-US', + help_text='If the action is offered in multiple languages, create separate actions for each language.', + verbose_name='Language', + ), + ), + ( + 'result_type', + wagtail.blocks.ChoiceBlock( + choices=[ + ('Reservation', 'Reservation'), + ('BusReservation', 'BusReservation'), + ('EventReservation', 'EventReservation'), + ('FlightReservation', 'FlightReservation'), + ('FoodEstablishmentReservation', 'FoodEstablishmentReservation'), + ('LodgingReservation', 'LodgingReservation'), + ('RentalCarReservation', 'RentalCarReservation'), + ('ReservationPackage', 'ReservationPackage'), + ('TaxiReservation', 'TaxiReservation'), + ('TrainReservation', 'TrainReservation'), + ], + help_text='Leave blank for OrderAction', + required=False, + verbose_name='Result Type', + ), + ), + ( + 'result_name', + wagtail.blocks.CharBlock( + help_text='Example: "Reserve a table", "Book an appointment", etc.', + required=False, + verbose_name='Result Name', + ), + ), + ( + 'extra_json', + wagtail.blocks.RawHTMLBlock( + form_classname='monospace', + help_text='Additional JSON-LD inserted into the Action dictionary. Must be properties of https://schema.org/Action.', + required=False, + verbose_name='Additional action markup', + ), + ), + ] + ), + ) + ], + blank=True, + use_json_field=True, + verbose_name='Actions', + ), + ), + ( + 'struct_org_extra_json', + models.TextField( + blank=True, + help_text='Additional JSON-LD inserted into the Organization dictionary. Must be properties of https://schema.org/Organization or the selected organization type.', + verbose_name='Additional Organization markup', + ), + ), + ('hero_text', models.TextField(blank=True, null=True)), + ('hero_subtitle', models.TextField(blank=True, null=True)), + ('dep_title', models.TextField(blank=True, null=True)), + ('dep_sub_title', models.TextField(blank=True, null=True)), + ( + 'dep_cards', + wagtail.fields.StreamField( + [ + ( + 'cards', + wagtail.blocks.StreamBlock( + [ + ( + 'topic_card', + wagtail.blocks.StructBlock( + [ + ('title', wagtail.blocks.CharBlock(label='Title', max_length=255)), + ( + 'description', + wagtail.blocks.CharBlock(label='Description', max_length=255), + ), + ('link_text', wagtail.blocks.CharBlock(label='Link text')), + ('link_url', wagtail.blocks.CharBlock(label='Link url')), + ] + ), + ) + ], + block_counts={'topic_card': {'min_num': 1}}, + ), + ) + ], + blank=True, + null=True, + use_json_field=True, + ), + ), + ( + 'hero_image', + models.ForeignKey( + blank=True, + null=True, + on_delete=django.db.models.deletion.SET_NULL, + related_name='+', + to='core.alttextimage', + ), + ), + ( + 'hero_mobile_image', + models.ForeignKey( + blank=True, + null=True, + on_delete=django.db.models.deletion.SET_NULL, + related_name='+', + to='core.alttextimage', + ), + ), + ( + 'og_image', + models.ForeignKey( + blank=True, + help_text='Shown when linking to this page on social media.', + null=True, + on_delete=django.db.models.deletion.SET_NULL, + related_name='+', + to='core.alttextimage', + verbose_name='Preview image', + ), + ), + ( + 'struct_org_image', + models.ForeignKey( + blank=True, + help_text='A photo of the facility. This photo will be cropped to 1:1, 4:3, and 16:9 aspect ratios automatically.', + null=True, + on_delete=django.db.models.deletion.SET_NULL, + related_name='+', + to='core.alttextimage', + verbose_name='Photo of Organization', + ), + ), + ( + 'struct_org_logo', + models.ForeignKey( + blank=True, + help_text='Leave blank to use the logo in Settings > Layout > Logo', + null=True, + on_delete=django.db.models.deletion.SET_NULL, + related_name='+', + to='core.alttextimage', + verbose_name='Organization logo', + ), + ), + ], + options={ + 'abstract': False, + }, + bases=( + international.cms_panels.GreatInternationalHomePagePanels, + 'wagtailcore.page', + core.mixins.WagtailGA360Mixin, + great_components.mixins.GA360Mixin, + ), + ), + ] diff --git a/international/migrations/__init__.py b/international/migrations/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/international/models.py b/international/models.py new file mode 100644 index 0000000000..6d901f6719 --- /dev/null +++ b/international/models.py @@ -0,0 +1,58 @@ +from django.db import models +from wagtail.fields import StreamBlock, StreamField + +from core.blocks import SupportTopicCardBlock +from domestic.models import BaseContentPage +from international import cms_panels + + +class GreatInternationalHomePage(cms_panels.GreatInternationalHomePagePanels, BaseContentPage): + # This is the main homepge for Great.gov.uk/international + + parent_page_types = [ + 'domestic.GreatDomesticHomePage', + ] + + template = 'international/index.html' + + # hero + hero_image = models.ForeignKey( + 'core.AltTextImage', + null=True, + blank=True, + on_delete=models.SET_NULL, + related_name='+', + ) + + hero_mobile_image = models.ForeignKey( + 'core.AltTextImage', + null=True, + blank=True, + on_delete=models.SET_NULL, + related_name='+', + ) + + hero_text = models.TextField(null=True, blank=True) + hero_subtitle = models.TextField(null=True, blank=True) + + dep_title = models.TextField(null=True, blank=True) + dep_sub_title = models.TextField(null=True, blank=True) + + dep_cards = StreamField( + [ + ( + 'cards', + StreamBlock( + [ + ('topic_card', SupportTopicCardBlock()), + ], + block_counts={ + 'topic_card': {'min_num': 1}, + }, + ), + ), + ], + use_json_field=True, + null=True, + blank=True, + ) diff --git a/international/sass/hero.scss b/international/sass/hero.scss new file mode 100644 index 0000000000..3dcf8c6f0c --- /dev/null +++ b/international/sass/hero.scss @@ -0,0 +1,74 @@ +// Hero banner + +.great-hero { + position: relative; + padding-top: 0; + padding-bottom: 0; + background-repeat: no-repeat; + background-size: cover; + background-position: center; + + + & > .container { + min-height: 200px; + overflow: visible; + padding-top: 45px; + } + + .great-hero-no-image { + background-color: $eyb-dark-blue; + } + + .great-hero__container { + @include govuk-media-query($from: desktop) { + display: flex; + } + } + + .great-hero__text { + max-width: 50%; + min-height: 335px; + display: flex; + flex-direction: column; + justify-content: end; + padding-bottom: 5px; + align-items: flex-start; + + .great-hero-heading { + color: white; + font-size: 32px; + } + + .great-hero-subheading { + color: white; + font-size: 18px; + margin-bottom: 0px; + } + + .great-hero-description { + margin-bottom: 0; + } + + } + + @media (min-width: 641px) { + .great-hero__text { + min-height: 560px; + max-width: 567px; + justify-content: center; + + .great-hero-heading { + font-size: 60px; + } + + .great-hero-subheading { + font-size: 24px; + margin-bottom: 0px; + } + } + } +} + +.great-hero-cards { + background: linear-gradient(270deg, #02022D 0%, #020130 100%); +} diff --git a/international/sass/main.scss b/international/sass/main.scss index 716af88137..59c630a0ce 100644 --- a/international/sass/main.scss +++ b/international/sass/main.scss @@ -12,23 +12,38 @@ ul { @import 'header.scss'; @import 'footer.scss'; @import '../../styles/great/utils'; +@import '../../styles/great/components'; +@import 'hero.scss'; + body { margin: 0; } -.great-hero { - background-image: url('/static/images/international-background-image.png'); - background-repeat: no-repeat; - background-position: center; - background-size: cover; - border-radius: var(--spacing-spacing-0, 0px); - flex-direction: column; - gap: 20px; - align-self: stretch; +// International home page styles start +.why-choose-uk-section { + background-color: #eef2f6; +} - .great-hero__heading { - color: white; +.international-card--cta { + div { + font-family: 'Euclid Flex B'; + } + .great-card__link { + font-family: 'Euclid Flex B'; + color: #04043F; + text-underline-offset: 3px; + text-decoration-thickness: 3px; } } + +.international-home-uk-map { + background: url('/static/images/uk-map.svg'); + display: block; + width: fixed; + height: 387px; + background-repeat: no-repeat; + background-size: contain; +} +// International home page styles end diff --git a/international/templates/international/components/landing_hero.html b/international/templates/international/components/landing_hero.html new file mode 100644 index 0000000000..26b935f6d7 --- /dev/null +++ b/international/templates/international/components/landing_hero.html @@ -0,0 +1,42 @@ +{% load wagtailimages_tags %} +{% load static %} +{% image hero_image original as rendition %} +{% image page.hero_mobile_image original as mobile_image %} + +
+
+
+
+

{{ heading }}

+

{{ subtitle }}

+
+
+
+
+
+
+
+
+
+ {% include 'components/great/card.html' with content="We can guide you every step of the way, to set up and grow your business in the UK" title="How to expand your business" url="/international/expand-your-business-in-the-uk/" show_title_link=True heading_class="govuk-heading-m" classes="international-card--cta" %} +
+
+ {% include 'components/great/card.html' with content="Explore a range of property development and infrastructure projects to suit your investment" title="Find investment opportunities" url="/international/investment/" show_title_link=True heading_class="govuk-heading-m" classes="international-card--cta" %} +
+
+ {% include 'components/great/card.html' with content="Get introduced to UK businesses who can partner with your business to achieve success" title="Buy UK products and services" url="/international/content/trade/how-we-help-you-buy/" show_title_link=True heading_class="govuk-heading-m" classes="international-card--cta" %} +
+
+
+
diff --git a/international/templates/international/header.html b/international/templates/international/header.html index 767a1f33d4..80e48dae1b 100644 --- a/international/templates/international/header.html +++ b/international/templates/international/header.html @@ -20,13 +20,13 @@ Expand your business in the UK {% else %} -