From 36f9c8921465fb544dca6908a237bc65877f873a Mon Sep 17 00:00:00 2001 From: Nick Date: Sun, 1 Dec 2024 02:56:13 -0600 Subject: [PATCH] feat: added some stuff --- frontend/src/Headers/Helpers.elm | 80 +++++++++++ frontend/src/Headers/Pages/Arguments.elm | 10 ++ frontend/src/Headers/Pages/Contact.elm | 10 ++ frontend/src/Headers/Pages/CuckList.elm | 10 ++ frontend/src/Headers/Pages/Donate.elm | 10 ++ frontend/src/Headers/Pages/HyperBlog.elm | 10 ++ frontend/src/Headers/Pages/Interviews.elm | 10 ++ frontend/src/Headers/Pages/NutriDex.elm | 10 ++ frontend/src/Headers/Pages/Services.elm | 10 ++ frontend/src/Headers/Types.elm | 7 + frontend/src/Interviews/Helpers.elm | 1 - frontend/src/Pages/Arguments.elm | 113 ++++++++-------- frontend/src/Pages/Cucklist.elm | 140 ++++++++++---------- frontend/src/Pages/Donate.elm | 23 ++-- frontend/src/Pages/Hyperblog.elm | 13 +- frontend/src/Pages/Interviews.elm | 27 ++-- frontend/src/Pages/Nutridex.elm | 107 +++++++++++++++ frontend/src/Pages/Services.elm | 18 ++- frontend/src/Products/Helpers.elm | 76 +++++++++++ frontend/src/Products/NutriDex/NutriDex.elm | 21 +++ frontend/src/Products/Types.elm | 22 +++ 21 files changed, 573 insertions(+), 155 deletions(-) create mode 100644 frontend/src/Headers/Helpers.elm create mode 100644 frontend/src/Headers/Pages/Arguments.elm create mode 100644 frontend/src/Headers/Pages/Contact.elm create mode 100644 frontend/src/Headers/Pages/CuckList.elm create mode 100644 frontend/src/Headers/Pages/Donate.elm create mode 100644 frontend/src/Headers/Pages/HyperBlog.elm create mode 100644 frontend/src/Headers/Pages/Interviews.elm create mode 100644 frontend/src/Headers/Pages/NutriDex.elm create mode 100644 frontend/src/Headers/Pages/Services.elm create mode 100644 frontend/src/Headers/Types.elm create mode 100644 frontend/src/Pages/Nutridex.elm create mode 100644 frontend/src/Products/Helpers.elm create mode 100644 frontend/src/Products/NutriDex/NutriDex.elm create mode 100644 frontend/src/Products/Types.elm diff --git a/frontend/src/Headers/Helpers.elm b/frontend/src/Headers/Helpers.elm new file mode 100644 index 0000000..7424552 --- /dev/null +++ b/frontend/src/Headers/Helpers.elm @@ -0,0 +1,80 @@ +module Headers.Helpers exposing (..) + +import Config.CardFormat exposing (..) +import Config.Colour exposing (..) +import Config.Format exposing (..) +import Config.StrengthBar exposing (..) +import Config.ToolTip exposing (..) +import Effect exposing (Effect) +import Element as E exposing (..) +import Element.Background as B exposing (..) +import Element.Border as D +import Element.Font as F +import Headers.Types exposing (..) +import Html.Attributes as H exposing (style) +import Interviews.Types exposing (..) +import Layouts +import Page exposing (Page) +import Route exposing (Route) +import Shared +import View exposing (View) + + +headerMaker : Header -> Element msg +headerMaker header = + row + topLevelBox + [ column + [ E.width <| px 785 + , D.width 5 + , D.color colourTheme.backgroundDarkGrey + , D.roundEach + { topLeft = 32 + , topRight = 32 + , bottomRight = 32 + , bottomLeft = 32 + } + ] + [ paragraph + (nonHighlightedTitleFormat + ++ [ F.size 20 + , B.color colourTheme.textDarkOrange + , paddingEach + { top = 6 + , bottom = 3 + , left = 25 + , right = 15 + } + , alignBottom + , width fill + , F.center + , D.roundEach + { topLeft = 26 + , topRight = 26 + , bottomRight = 0 + , bottomLeft = 0 + } + ] + ) + [ text header.headerTitle ] + , cardFormatter + [ cardContentSpacing + [ column + fieldSpacer + [ paragraph + (paragraphFormat + ++ [ F.size 18 + , F.center + ] + ) + [ text header.headerBody ] + ] + ] + ] + ] + ] + + +headerTitle : Header -> String +headerTitle header = + header.headerTitle diff --git a/frontend/src/Headers/Pages/Arguments.elm b/frontend/src/Headers/Pages/Arguments.elm new file mode 100644 index 0000000..cb433c3 --- /dev/null +++ b/frontend/src/Headers/Pages/Arguments.elm @@ -0,0 +1,10 @@ +module Headers.Pages.Arguments exposing (..) + +import Headers.Types exposing (..) + + +argumentHeader : Header +argumentHeader = + { headerTitle = "DEBATE" + , headerBody = "This page features arguments that I hold to be sound. I'm open to hearing all challenges, as I am ready to engage with and defend any argument listed." + } diff --git a/frontend/src/Headers/Pages/Contact.elm b/frontend/src/Headers/Pages/Contact.elm new file mode 100644 index 0000000..e35e1fe --- /dev/null +++ b/frontend/src/Headers/Pages/Contact.elm @@ -0,0 +1,10 @@ +module Headers.Pages.Contact exposing (..) + +import Headers.Types exposing (..) + + +contactHeader : Header +contactHeader = + { headerTitle = "CONTACT" + , headerBody = "fasdklfjasdlk;fjasdl;fjasdfl;kasjdfl;askdja;lsdkjas;ldfj" + } diff --git a/frontend/src/Headers/Pages/CuckList.elm b/frontend/src/Headers/Pages/CuckList.elm new file mode 100644 index 0000000..974fb04 --- /dev/null +++ b/frontend/src/Headers/Pages/CuckList.elm @@ -0,0 +1,10 @@ +module Headers.Pages.CuckList exposing (..) + +import Headers.Types exposing (..) + + +cuckListHeader : Header +cuckListHeader = + { headerTitle = "CUCKLIST" + , headerBody = "This page features a list of morons who wrote cheques with their mouths that their asses couldn't cash. Each person included in this list has dodged debating me." + } diff --git a/frontend/src/Headers/Pages/Donate.elm b/frontend/src/Headers/Pages/Donate.elm new file mode 100644 index 0000000..6386a44 --- /dev/null +++ b/frontend/src/Headers/Pages/Donate.elm @@ -0,0 +1,10 @@ +module Headers.Pages.Donate exposing (..) + +import Headers.Types exposing (..) + + +donateHeader : Header +donateHeader = + { headerTitle = "DONATE" + , headerBody = "My site, research, and content all cost time and money to run. If you find my contributions valuable, please consider supporting my work on any of the platforms listed below!" + } diff --git a/frontend/src/Headers/Pages/HyperBlog.elm b/frontend/src/Headers/Pages/HyperBlog.elm new file mode 100644 index 0000000..cb93aab --- /dev/null +++ b/frontend/src/Headers/Pages/HyperBlog.elm @@ -0,0 +1,10 @@ +module Headers.Pages.HyperBlog exposing (..) + +import Headers.Types exposing (..) + + +hyperBlogHeader : Header +hyperBlogHeader = + { headerTitle = "HYPERBLOG" + , headerBody = "fasdklfjasdlk;fjasdl;fjasdfl;kasjdfl;askdja;lsdkjas;ldfj" + } diff --git a/frontend/src/Headers/Pages/Interviews.elm b/frontend/src/Headers/Pages/Interviews.elm new file mode 100644 index 0000000..74dbcfc --- /dev/null +++ b/frontend/src/Headers/Pages/Interviews.elm @@ -0,0 +1,10 @@ +module Headers.Pages.Interviews exposing (..) + +import Headers.Types exposing (..) + + +interviewHeader : Header +interviewHeader = + { headerTitle = "INTERVIEWS" + , headerBody = "This page showcases various podcasts and shows I've been on. If you’d like to have me as a guest on your podcast, feel free to reach out—I’d love to share my perspectives with your audience!" + } diff --git a/frontend/src/Headers/Pages/NutriDex.elm b/frontend/src/Headers/Pages/NutriDex.elm new file mode 100644 index 0000000..2ecc279 --- /dev/null +++ b/frontend/src/Headers/Pages/NutriDex.elm @@ -0,0 +1,10 @@ +module Headers.Pages.NutriDex exposing (..) + +import Headers.Types exposing (..) + + +nutriDexHeader : Header +nutriDexHeader = + { headerTitle = "NUTRIDEX" + , headerBody = "fasdklfjasdlk;fjasdl;fjasdfl;kasjdfl;askdja;lsdkjas;ldfj" + } diff --git a/frontend/src/Headers/Pages/Services.elm b/frontend/src/Headers/Pages/Services.elm new file mode 100644 index 0000000..c931557 --- /dev/null +++ b/frontend/src/Headers/Pages/Services.elm @@ -0,0 +1,10 @@ +module Headers.Pages.Services exposing (..) + +import Headers.Types exposing (..) + + +servicesHeader : Header +servicesHeader = + { headerTitle = "SERVICES" + , headerBody = "Bundle any of the services below to receive a $10 discount per hour. For example, two Debate Analysis sessions would cost $140 total, instead of $80/hr. All prices are in CAD." + } diff --git a/frontend/src/Headers/Types.elm b/frontend/src/Headers/Types.elm new file mode 100644 index 0000000..1415d18 --- /dev/null +++ b/frontend/src/Headers/Types.elm @@ -0,0 +1,7 @@ +module Headers.Types exposing (..) + + +type alias Header = + { headerTitle : String + , headerBody : String + } diff --git a/frontend/src/Interviews/Helpers.elm b/frontend/src/Interviews/Helpers.elm index 9a06d03..e2d4a63 100755 --- a/frontend/src/Interviews/Helpers.elm +++ b/frontend/src/Interviews/Helpers.elm @@ -5,7 +5,6 @@ import Config.Colour exposing (..) import Config.Format exposing (..) import Config.StrengthBar exposing (..) import Config.ToolTip exposing (..) -import Cuckery.Types exposing (..) import Effect exposing (Effect) import Element as E exposing (..) import Element.Background as B exposing (..) diff --git a/frontend/src/Pages/Arguments.elm b/frontend/src/Pages/Arguments.elm index a0170e4..90dc09c 100755 --- a/frontend/src/Pages/Arguments.elm +++ b/frontend/src/Pages/Arguments.elm @@ -60,6 +60,8 @@ import Effect exposing (Effect) import Element exposing (..) import Element.Border as D exposing (..) import Element.Font as F +import Headers.Helpers exposing (headerMaker) +import Headers.Pages.Arguments exposing (argumentHeader) import Html import Html.Attributes as H exposing (style, title, wrap) import Layouts @@ -151,60 +153,61 @@ debateList = [ column pageList <| - List.map argumentMaker - [ argumentApoBCVD - , argumentAnabolicKeto - , argumentAntagonisticPleiotropy - , argumentCarbsObesity - , argumentDietaryCholesterol - , argumentFructoseNAFLD - , argumentHealthPromotingFoods - , argumentHealthSeeker - , argumentHealthyChocolate - , argumentHealthyDairy - , argumentHealthyFattyFish - , argumentHealthyFibre - , argumentHealthyFood - , argumentHealthyPlantFoods - , argumentHealthySeedOils - , argumentHealthySoy - , argumentMalondialdehyde - , argumentOmega3Omega6Ratio - , argumentPlantBasedCVDReversal - , argumentPolyphenolReductio - , argumentSodiumCVD - , argumentTMAOCausality - , argumentUnhealthyCoconutOil - , argumentUnhealthyProcessedMeat - , argumentUnhealthyRedMeat - , argumentUnhealthySaturatedFat - , argumentAbortion - , argumentAgnosticism - , argumentAgriculturalPredation - , argumentAnimalRights - , argumentAntiRewilding - , argumentAntiVandalism - , argumentColonizingNature - , argumentCropDeaths - , argumentDairyCowRape - , argumentEfilismPatrolSquad - , argumentEthicalSlurs - , argumentFineTuning - , argumentImmortalityReductio - , argumentOddOrderPredators - , argumentOstroveganism - , argumentPollinationReductio - , argumentScratcherPioneers - , argumentTransPeople - , argumentVeganSocietyReductio - , argumentBoobyTrapPagers - , argumentEpidemiologyCausality - , argumentFlatEarthDebunk - , argumentTruncatedMeta + List.concat + [ List.map headerMaker + [ argumentHeader ] + , List.map argumentMaker + [ argumentApoBCVD + , argumentAnabolicKeto + , argumentAntagonisticPleiotropy + , argumentCarbsObesity + , argumentDietaryCholesterol + , argumentFructoseNAFLD + , argumentHealthPromotingFoods + , argumentHealthSeeker + , argumentHealthyChocolate + , argumentHealthyDairy + , argumentHealthyFattyFish + , argumentHealthyFibre + , argumentHealthyFood + , argumentHealthyPlantFoods + , argumentHealthySeedOils + , argumentHealthySoy + , argumentMalondialdehyde + , argumentOmega3Omega6Ratio + , argumentPlantBasedCVDReversal + , argumentPolyphenolReductio + , argumentSodiumCVD + , argumentTMAOCausality + , argumentUnhealthyCoconutOil + , argumentUnhealthyProcessedMeat + , argumentUnhealthyRedMeat + , argumentUnhealthySaturatedFat + , argumentAbortion + , argumentAgnosticism + , argumentAgriculturalPredation + , argumentAnimalRights + , argumentAntiRewilding + , argumentAntiVandalism + , argumentColonizingNature + , argumentCropDeaths + , argumentDairyCowRape + , argumentEfilismPatrolSquad + , argumentEthicalSlurs + , argumentFineTuning + , argumentImmortalityReductio + , argumentOddOrderPredators + , argumentOstroveganism + , argumentPollinationReductio + , argumentScratcherPioneers + , argumentTransPeople + , argumentVeganSocietyReductio + , argumentBoobyTrapPagers + , argumentEpidemiologyCausality + , argumentFlatEarthDebunk + , argumentTruncatedMeta + ] + , List.map gibberishMaker + [ gibberishList ] ] - , column - pageList - <| - List.map gibberishMaker - [ gibberishList ] ] diff --git a/frontend/src/Pages/Cucklist.elm b/frontend/src/Pages/Cucklist.elm index 10d1ad0..f7a3782 100755 --- a/frontend/src/Pages/Cucklist.elm +++ b/frontend/src/Pages/Cucklist.elm @@ -74,6 +74,8 @@ import Effect exposing (Effect) import Element exposing (..) import Element.Border as D import Element.Font as F +import Headers.Helpers exposing (headerMaker) +import Headers.Pages.CuckList exposing (cuckListHeader) import Html.Attributes as H exposing (style) import Layouts import Page exposing (Page) @@ -161,71 +163,75 @@ dodgersList = column pageList <| - List.map cuckMaker - [ cuckAdamSinger - , cuckAmberOHearn - , cuckAnnChilders - , cuckAnthonyGustin - , cuckAshwaniGarg - , cuckAustinHerbert - , cuckBartKay - , cuckBenBikman - , cuckBennyMalone - , cuckBradCampbell - , cuckBradCohn - , cuckBradMarshall - , cuckBretWeinstein - , cuckBrianKerley - , cuckCarnivoreAurelius - , cuckCateShanahan - , cuckChrisBoettcher - , cuckClaraAboel - , cuckCliffHarvey - , cuckDaveFeldman - , cuckDavidDiamond - , cuckDavidGornoski - , cuckDianaRodgers - , cuckEdwardGoeke - , cuckElieJarrouge - , cuckGaryBrecka - , cuckGaryFettke - , cuckGaryTaubes - , cuckGeorgeMartin - , cuckGuyAustin - , cuckIvorCummins - , cuckJakeMey - , cuckJamesDiNicolantonio - , cuckJosephEverett - , cuckJustinMares - , cuckKaitMalthaner - , cuckKemMinnick - , cuckKenBerry - , cuckKevinStock - , cuckKyleMamounis - , cuckMarkSisson - , cuckMartyKendall - , cuckMaxLugavere - , cuckMichaelKummer - , cuckMichaelManderville - , cuckMikeMutzel - , cuckMikeSweeney - , cuckNickEggleton - , cuckNinaTeicholz - , cuckNorstrongChris - , cuckPaulMason - , cuckPaulSaladino - , cuckPhilipOvadia - , cuckPhilippeStephenson - , cuckRalphNapolitano - , cuckRaphaelSirtoli - , cuckRobbWolf - , cuckRobMeijer - , cuckSebastianRamirez - , cuckSimonGoddek - , cuckTravisStatham - , cuckTristanHaggard - , cuckTroKalayjian - , cuckTuckerGoodrich - , cuckZoeHarcombe - , cuckZsofiaClemens + List.concat + [ List.map headerMaker + [ cuckListHeader ] + , List.map cuckMaker + [ cuckAdamSinger + , cuckAmberOHearn + , cuckAnnChilders + , cuckAnthonyGustin + , cuckAshwaniGarg + , cuckAustinHerbert + , cuckBartKay + , cuckBenBikman + , cuckBennyMalone + , cuckBradCampbell + , cuckBradCohn + , cuckBradMarshall + , cuckBretWeinstein + , cuckBrianKerley + , cuckCarnivoreAurelius + , cuckCateShanahan + , cuckChrisBoettcher + , cuckClaraAboel + , cuckCliffHarvey + , cuckDaveFeldman + , cuckDavidDiamond + , cuckDavidGornoski + , cuckDianaRodgers + , cuckEdwardGoeke + , cuckElieJarrouge + , cuckGaryBrecka + , cuckGaryFettke + , cuckGaryTaubes + , cuckGeorgeMartin + , cuckGuyAustin + , cuckIvorCummins + , cuckJakeMey + , cuckJamesDiNicolantonio + , cuckJosephEverett + , cuckJustinMares + , cuckKaitMalthaner + , cuckKemMinnick + , cuckKenBerry + , cuckKevinStock + , cuckKyleMamounis + , cuckMarkSisson + , cuckMartyKendall + , cuckMaxLugavere + , cuckMichaelKummer + , cuckMichaelManderville + , cuckMikeMutzel + , cuckMikeSweeney + , cuckNickEggleton + , cuckNinaTeicholz + , cuckNorstrongChris + , cuckPaulMason + , cuckPaulSaladino + , cuckPhilipOvadia + , cuckPhilippeStephenson + , cuckRalphNapolitano + , cuckRaphaelSirtoli + , cuckRobbWolf + , cuckRobMeijer + , cuckSebastianRamirez + , cuckSimonGoddek + , cuckTravisStatham + , cuckTristanHaggard + , cuckTroKalayjian + , cuckTuckerGoodrich + , cuckZoeHarcombe + , cuckZsofiaClemens + ] ] diff --git a/frontend/src/Pages/Donate.elm b/frontend/src/Pages/Donate.elm index 0f60c65..2054643 100755 --- a/frontend/src/Pages/Donate.elm +++ b/frontend/src/Pages/Donate.elm @@ -17,6 +17,8 @@ import Element as E exposing (..) import Element.Background as B exposing (..) import Element.Border as D exposing (..) import Element.Font as F +import Headers.Helpers exposing (headerMaker) +import Headers.Pages.Donate exposing (donateHeader) import Html.Attributes as H exposing (style) import Layouts import Page exposing (Page) @@ -101,20 +103,11 @@ donateContainer = donateList : Element msg donateList = - column pageList - [ paragraph - (paragraphFormat - ++ [ F.size 18 - , alignTop - , E.width <| px 800 - , centerX, F.center - ] - ) - [ text "Any of the below services may be bundled for a $10 discount off each hour. For example, bundling two sessions of Debate Analysis would be $140 total, rather than $80/hr. All services are changed in CAD." ] - , column - pageList - <| - List.map donateMaker + column pageList <| + List.concat + [ List.map headerMaker + [ donateHeader ] + , List.map donateMaker [ donateLiberaPay , donatePayPal , donatePatreon @@ -123,4 +116,4 @@ donateList = , donateYouTube , donateMerch ] - ] + ] diff --git a/frontend/src/Pages/Hyperblog.elm b/frontend/src/Pages/Hyperblog.elm index a17fc95..93e94b4 100755 --- a/frontend/src/Pages/Hyperblog.elm +++ b/frontend/src/Pages/Hyperblog.elm @@ -7,6 +7,8 @@ import Config.Identity as I exposing (..) import Effect exposing (Effect) import Element exposing (..) import Element.Font as F +import Headers.Helpers exposing (headerMaker) +import Headers.Pages.NutriDex exposing (nutriDexHeader) import Html.Attributes as H exposing (style) import Layouts import Page exposing (Page) @@ -23,6 +25,12 @@ page shared route = , subscriptions = subscriptions , view = view } + |> Page.withLayout toLayout + + +toLayout : Model -> Layouts.Layout Msg +toLayout model = + Layouts.Navbar {} @@ -72,4 +80,7 @@ subscriptions model = view : Model -> View Msg view model = - View.fromString "Pages.Hyperblog" + { title = hyperBlogName + , attributes = [] + , element = none + } diff --git a/frontend/src/Pages/Interviews.elm b/frontend/src/Pages/Interviews.elm index 8a62cba..2f6d8a1 100755 --- a/frontend/src/Pages/Interviews.elm +++ b/frontend/src/Pages/Interviews.elm @@ -7,6 +7,8 @@ import Effect exposing (Effect) import Element exposing (..) import Element.Border as D import Element.Font as F +import Headers.Helpers exposing (headerMaker) +import Headers.Pages.Interviews exposing (interviewHeader) import Html import Html.Attributes as H exposing (style) import Interviews.Episodes.DrShawnBakerPodcast exposing (drShawnBakerPodcast) @@ -20,6 +22,7 @@ import Interviews.Episodes.SigmaNutritionRadio exposing (sigmaNutritionRadio) import Interviews.Episodes.StrenuousLifePodcast exposing (strenuousLifePodcast) import Interviews.Helpers exposing (..) import Layouts +import List exposing (head) import Page exposing (Page) import Route exposing (Route) import Shared @@ -105,14 +108,18 @@ interviewList = column pageList <| - List.map interviewMaker - [ sigmaNutritionRadio - , markBellsPowerProject - , foolproofMastery - , ketoGeeksPodcast - , legendaryLifePodcast - , muscleMemoirsPodcast - , fitAndFurious - , strenuousLifePodcast - , drShawnBakerPodcast + List.concat + [ List.map headerMaker + [ interviewHeader ] + , List.map interviewMaker + [ sigmaNutritionRadio + , markBellsPowerProject + , foolproofMastery + , ketoGeeksPodcast + , legendaryLifePodcast + , muscleMemoirsPodcast + , fitAndFurious + , strenuousLifePodcast + , drShawnBakerPodcast + ] ] diff --git a/frontend/src/Pages/Nutridex.elm b/frontend/src/Pages/Nutridex.elm new file mode 100644 index 0000000..8c0a8ce --- /dev/null +++ b/frontend/src/Pages/Nutridex.elm @@ -0,0 +1,107 @@ +module Pages.Nutridex exposing (Model, Msg, page) + +import Config.Colour as T exposing (..) +import Config.Format as O exposing (..) +import Config.Identity as I exposing (..) +import Donate.Types exposing (..) +import Effect exposing (Effect) +import Element as E exposing (..) +import Element.Background as B exposing (..) +import Element.Border as D exposing (..) +import Element.Font as F +import Headers.Helpers exposing (headerMaker) +import Headers.Pages.Donate exposing (donateHeader) +import Headers.Pages.NutriDex exposing (nutriDexHeader) +import Html +import Html.Attributes as H exposing (style) +import Layout exposing (..) +import Layouts +import Page exposing (Page) +import Products.Helpers exposing (..) +import Products.NutriDex.NutriDex exposing (productNutriDex) +import Route exposing (Route) +import Shared exposing (..) +import View exposing (View) + + +page : Shared.Model -> Route () -> Page Model Msg +page shared route = + Page.new + { init = init + , update = update + , subscriptions = subscriptions + , view = view + } + |> Page.withLayout toLayout + + +toLayout : Model -> Layouts.Layout Msg +toLayout model = + Layouts.Navbar {} + + + +-- INIT + + +type alias Model = + {} + + +init : () -> ( Model, Effect Msg ) +init () = + ( {} + , Effect.none + ) + + + +-- UPDATE + + +type Msg + = NoOp + + +update : Msg -> Model -> ( Model, Effect Msg ) +update msg model = + case msg of + NoOp -> + ( model + , Effect.none + ) + + + +-- SUBSCRIPTIONS + + +subscriptions : Model -> Sub Msg +subscriptions model = + Sub.none + + + +-- VIEW + + +view : Model -> View Msg +view model = + { title = nutriDexName + , attributes = [] + , element = nutriDexContainer + } + + +nutriDexContainer : Element msg +nutriDexContainer = + topLevelContainer nutriDexList + + +nutriDexList : Element msg +nutriDexList = + column pageList <| + List.concat + [ List.map nutriDexMaker + [ productNutriDex ] + ] diff --git a/frontend/src/Pages/Services.elm b/frontend/src/Pages/Services.elm index fd67d46..c9e5202 100755 --- a/frontend/src/Pages/Services.elm +++ b/frontend/src/Pages/Services.elm @@ -6,6 +6,8 @@ import Config.Identity as I exposing (..) import Effect exposing (Effect) import Element exposing (..) import Element.Font as F +import Headers.Helpers exposing (headerMaker) +import Headers.Pages.Services exposing (servicesHeader) import Html.Attributes as H exposing (style) import Layouts import Page exposing (Page) @@ -99,10 +101,14 @@ servicesList = column pageList <| - List.map serviceMaker - [ servicesDebateAnalysis - , servicesDebateTutoring - , servicesNutritionScience - , servicesNixBuilds - , servicesElmBuilds + List.concat + [ List.map headerMaker + [ servicesHeader ] + , List.map serviceMaker + [ servicesDebateAnalysis + , servicesDebateTutoring + , servicesNutritionScience + , servicesNixBuilds + , servicesElmBuilds + ] ] diff --git a/frontend/src/Products/Helpers.elm b/frontend/src/Products/Helpers.elm new file mode 100644 index 0000000..6e1c9e0 --- /dev/null +++ b/frontend/src/Products/Helpers.elm @@ -0,0 +1,76 @@ +module Products.Helpers exposing (..) + +import Config.CardFormat exposing (..) +import Config.Colour exposing (..) +import Config.Format exposing (..) +import Config.StrengthBar exposing (..) +import Config.ToolTip exposing (..) +import Effect exposing (Effect) +import Element as E exposing (..) +import Element.Background as B exposing (..) +import Element.Border as D +import Element.Font as F +import Headers.Types exposing (..) +import Html.Attributes as H exposing (style) +import Interviews.Types exposing (..) +import Layouts +import Page exposing (Page) +import Products.Types exposing (..) +import Route exposing (Route) +import Shared +import View exposing (View) + + +nutriDexMaker : NutriDex -> Element msg +nutriDexMaker nutridex = + row + topLevelBox + [ column + [ E.width <| px 785 + , D.width 5 + , D.color colourTheme.backgroundDarkGrey + , D.roundEach + { topLeft = 32 + , topRight = 32 + , bottomRight = 32 + , bottomLeft = 32 + } + ] + [ paragraph + (nonHighlightedTitleFormat + ++ [ F.size 20 + , B.color colourTheme.textDarkOrange + , paddingEach + { top = 6 + , bottom = 3 + , left = 25 + , right = 15 + } + , alignBottom + , width fill + , F.center + , D.roundEach + { topLeft = 26 + , topRight = 26 + , bottomRight = 0 + , bottomLeft = 0 + } + ] + ) + [ text nutridex.nutriDexTitle ] + , cardFormatter + [ cardContentSpacing + [ column + fieldSpacer + [ paragraph + (paragraphFormat + ++ [ F.size 18 + , F.center + ] + ) + [ text nutridex.nutriDexTitle ] + ] + ] + ] + ] + ] diff --git a/frontend/src/Products/NutriDex/NutriDex.elm b/frontend/src/Products/NutriDex/NutriDex.elm new file mode 100644 index 0000000..052f339 --- /dev/null +++ b/frontend/src/Products/NutriDex/NutriDex.elm @@ -0,0 +1,21 @@ +module Products.NutriDex.NutriDex exposing (..) + +import Products.Types exposing (..) + + +productNutriDex : NutriDex +productNutriDex = + { nutriDexTitle = "The NutriDex" + , nutriDexFeatures = + [ { feature = "feature" + } + ] + , nutriDexReference = + [ { reference = "reference" + , author = "author" + , year = "year" + , title = "title" + , link = "link" + } + ] + } diff --git a/frontend/src/Products/Types.elm b/frontend/src/Products/Types.elm new file mode 100644 index 0000000..8777b3a --- /dev/null +++ b/frontend/src/Products/Types.elm @@ -0,0 +1,22 @@ +module Products.Types exposing (..) + + +type alias NutriDex = + { nutriDexTitle : String + , nutriDexFeatures : List Features + , nutriDexReference : List References + } + + +type alias Features = + { feature : String + } + + +type alias References = + { reference : String + , author : String + , title : String + , link : String + , year : String + }