feat: slow refactor

This commit is contained in:
Nick 2024-12-27 01:30:21 -06:00
parent 903c16efed
commit e6f3a09919
54 changed files with 1103 additions and 1128 deletions

View file

@ -2,8 +2,14 @@ module Pages.Blog exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (extractFirstWords)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Inner.Helpers
exposing
( detailBodyMaker
, detailFormat
, detailTitleMaker
)
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Converters
exposing
( formatName
@ -42,7 +48,7 @@ import Config.Pages.Blog.Records.SeedOils exposing (articleSeedOils)
import Config.Pages.Blog.Records.Shenangians exposing (articleShenanigans)
import Config.Pages.Blog.Records.SweetDeception exposing (articleSweetDeception)
import Config.Pages.Blog.Types exposing (..)
import Config.Style.Colour as T exposing (..)
import Config.Style.Colour.Helpers as T exposing (..)
import Config.Style.Icons.Icons exposing (construction)
import Config.Style.Images exposing (imageSquareMaker)
import Effect exposing (Effect)
@ -176,7 +182,7 @@ articleImage :
, description : String
}
articleImage article =
{ src = "blog/" ++ article.articleImage ++ "thumb.png"
{ src = imagePathMaker M.BlogArticle article.articleImage
, description = article.articleName
}
@ -189,78 +195,40 @@ articleMaker device article =
el
[ alignLeft
, alignTop
, width fill
, paddingEach
{ top = 0
, right = 10
, bottom = 0
, bottom = 7
, left = 0
}
]
<|
imageSquareMaker device (imagePathMaker M.BlogCard article.articleImage) True size
imageSquareMaker device (imagePathMaker M.BlogArticle article.articleImage) True size
in
column
[ E.width fill
, centerX
]
[ row
[ width fill
]
[ case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
none
detailFormat column
[ case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
none
( Tablet, Portrait ) ->
none
( Tablet, Portrait ) ->
none
_ ->
image "Big"
, column
[ width fill
, alignTop
]
(articleRows article)
]
_ ->
image "Fill"
, detailFormat column
(articleRows article)
, el [] <|
paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, spacing 3
, F.regular
, F.alignLeft
, paddingEach
{ top = 8
, bottom = 0
, left = 0
, right = 0
}
]
[ renderDeviceMarkdownNoToc (extractFirstWords article.articleBody) ]
detailBodyMaker TextLightGrey (renderDeviceMarkdownNoToc (extractFirstWords article.articleBody))
]
infoRow : String -> String -> Element msg
infoRow : String -> Element msg -> Element msg
infoRow label value =
row [ width fill ]
[ el [ width <| px 88 ] <|
el
[ F.color colourTheme.textLightOrange
, paragraphSpacing
, F.bold
, headerFontSizeSmall
, E.width fill
]
<|
text label
, el [ width fill ] <|
paragraph
[ F.color colourTheme.textLightGrey
, F.regular
, paragraphFontSize
, width fill
]
[ text value ]
detailFormat row
[ el [ width <| px 82 ] <|
detailTitleMaker TextLightOrange label
, detailBodyMaker TextLightGrey value
]
@ -270,13 +238,28 @@ articleRows article =
referenceCount =
List.length article.articleReferences
in
[ infoRow "Published:" article.articlePublished
, infoRow "Author:" article.articleAuthor
, infoRow "Duration:" (String.fromInt (wordCount article.articleBody // 225) ++ " minutes")
, infoRow "Words:" (String.fromInt (wordCount article.articleBody))
[ infoRow "Published:" (text article.articlePublished)
, infoRow "Author:" (text article.articleAuthor)
, infoRow "Duration:"
(text
(String.fromInt
(wordCount article.articleBody // 225)
++ " minutes"
)
)
, infoRow "Words"
(text
(String.fromInt
(wordCount article.articleBody)
)
)
]
++ (if referenceCount >= 2 then
[ infoRow "Sources:" (String.fromInt referenceCount) ]
[ infoRow "Sources"
(text
(String.fromInt referenceCount)
)
]
else
[]

View file

@ -2,8 +2,8 @@ module Pages.Blog.Bigfatsurprise exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Everettvegans exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Huntergatherers exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Meatapologetics exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Nagragoodrich exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Plantbasedmeta exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Quacksmashing exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Sapiendiet exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Seedoils exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Shenanigans exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -2,8 +2,8 @@ module Pages.Blog.Sweetdeception exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (contentList)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response
exposing

View file

@ -1,8 +1,8 @@
module Pages.Contact exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format exposing (..)
import Config.Helpers.Headers.Helpers exposing (..)
import Config.Helpers.Headers.Records exposing (contactHeader, nutriDexHeader)
@ -15,12 +15,13 @@ import Config.Helpers.Response
import Config.Helpers.ServiceFormat
exposing
( chunkMaker
, divider
, titleMaker
)
import Config.Helpers.ToolTip exposing (..)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Contact.Types exposing (..)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (colourTheme)
import Config.Style.Transitions
exposing
( hoverFontDarkOrange

View file

@ -11,8 +11,8 @@ import Config.Data.Identity
exposing
( pageNames
)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Converters exposing (formatName)
import Config.Helpers.Format
exposing
@ -35,7 +35,7 @@ import Config.Pages.Debate.Arguments.List exposing (argumentList)
import Config.Pages.Debate.Cuckery.List exposing (cuckList)
import Config.Pages.Debate.Gibberish.List exposing (gibberishList)
import Config.Pages.Debate.Types exposing (..)
import Config.Style.Colour as T exposing (colourTheme)
import Config.Style.Colour.Helpers as T exposing (colourTheme)
import Config.Style.Glow
exposing
( glowDeepDarkGrey

View file

@ -1,8 +1,17 @@
module Pages.Debate.Arguments exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Inner.Helpers
exposing
( bodyFormat
, detailBodyMaker
, detailFormat
, detailSpacing
, detailTitleMaker
, proofTreeButton
)
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Converters exposing (toTitleCase)
import Config.Helpers.Format
exposing
@ -31,7 +40,13 @@ import Config.Pages.Debate.Arguments.List
( argumentList
)
import Config.Pages.Debate.Arguments.Types exposing (..)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers
exposing
( ThemeColor(..)
, colourTheme
, textLightGrey
, textLightOrange
)
import Config.Style.Glow
exposing
( glowDeepDarkGrey
@ -160,13 +175,13 @@ contentList device argument =
, alignTop
, paddingEach
{ top = 0
, right = 0
, right = 10
, bottom = 0
, left = 10
, left = 0
}
]
<|
imageSquareMaker device (imagePathMaker M.Argument argument.argumentImage) False size
imageSquareMaker device (imagePathMaker M.Argument argument.argumentImage) True size
in
[ row
[ width fill
@ -186,276 +201,39 @@ contentList device argument =
, left = 0
}
]
[ column
[ width fill
, spacing 8
]
[ summaryMakerDesktop device argument
, strengthBar device argument
]
, case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
none
[ detailFormat column
[ detailFormat paragraph
[ case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
none
( Tablet, Portrait ) ->
none
( Tablet, Portrait ) ->
none
_ ->
image "Fatty"
_ ->
image "Fatty"
, el ([ height fill ] ++ bodyFormat TextLightGrey) <| text argument.propositionSummary
]
, detailFormat row
[ strengthMaker
, barMaker getConfidenceTooltip argument.argumentCertainty
]
]
]
, tableMaker device argument
, desktopFormalizationMaker argument
, proofTreeButton argument.proofLink
, formalizationMaker argument
, proofTreeButton argument.proofLink "Proof Tree"
]
proofTreeButton : String -> Element msg
proofTreeButton url =
newTabLink
[ alignTop
, alignRight
, paddingXY 0 5
]
{ url = url
, label =
el
[ F.color colourTheme.textLightGrey
, B.color colourTheme.textDarkOrange
, D.rounded 10
, paddingEach
{ top = 6
, bottom = 3
, left = 10
, right = 10
}
, mouseOver
[ F.color colourTheme.textLightOrange
, B.color colourTheme.textDeepDarkOrange
]
, transitionStyleSlow
, headerFontSizeSmall
, F.bold
]
<|
text
"Proof Tree"
}
infoSpacing =
E.width <| px 100
propositionMaker : Element msg
propositionMaker =
column
[ E.alignTop, E.alignLeft ]
[ paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, headerFontSizeSmall
, F.bold
, infoSpacing
]
[ el
[ tooltip
"A proposition is a declarative statement that can be evaluated as either true or false, and which serves as the basis for debate."
]
(text "Proposition:")
|> el [ F.color colourTheme.textLightOrange ]
]
]
propositionTitleMaker : Argument -> Element msg
propositionTitleMaker argument =
column
[ E.width fill, E.alignLeft ]
[ paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, headerFontSizeSmall
, F.bold
]
[ text argument.propositionTitle
|> el
[ F.color colourTheme.textLightGrey
, F.regular
, paragraphFontSize
]
]
]
reductioMakerDesktop : Argument -> Element msg
reductioMakerDesktop argument =
case argument.propositionReductio of
"" ->
none
reductio ->
row
[]
[ reductioMaker
, reductioMakerTitle reductio
]
reductioMaker : Element msg
reductioMaker =
column
[ E.alignTop, E.alignLeft ]
[ paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, headerFontSizeSmall
, F.bold
, infoSpacing
]
[ el
[ tooltip
"This is the position from which the reductio ad absurdum is derived."
]
(text "Reductio:")
|> el [ F.color colourTheme.textLightOrange ]
]
]
reductioMakerTitle : String -> Element msg
reductioMakerTitle reductio =
column [ E.width fill, E.alignLeft ]
[ paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, spacing 3
]
[ text reductio ]
]
summaryMakerDesktop : Device -> Argument -> Element msg
summaryMakerDesktop device argument =
(case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
column
( Tablet, Portrait ) ->
column
_ ->
row
)
[]
[ summaryMaker
, summaryMakerTitle argument
]
summaryMaker : Element msg
summaryMaker =
column
[ E.alignTop
, E.alignLeft
]
[ paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
, infoSpacing
, headerFontSizeSmall
]
[ el
[ tooltip
"The following information provides additional context and insight into the reasoning behind the argument."
]
(text "Summary:")
|> el [ F.color colourTheme.textLightOrange ]
]
]
summaryMakerTitle : Argument -> Element msg
summaryMakerTitle argument =
column
[ E.width fill
, E.alignLeft
]
[ paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, F.bold
, spacing 3
, headerFontSizeSmall
]
[ text argument.propositionSummary
|> el
[ F.color colourTheme.textLightGrey
, F.regular
, paragraphFontSize
]
]
]
strengthBar : Device -> Argument -> Element msg
strengthBar device argument =
(case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
column
( Tablet, Portrait ) ->
column
_ ->
row
)
[ E.width fill ]
[ strengthMaker
, strengthMakerBar argument
]
strengthMaker : Element msg
strengthMaker =
column
[ E.alignTop
, E.alignLeft
el
[ tooltip
"This represents my confidence in the soundness of the argument."
]
[ paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
, E.width fill
, headerFontSizeSmall
]
[ el
[ tooltip
"This represents my confidence in the soundness of the argument."
]
(el
[ paddingEach
{ top = 0
, right = 5
, bottom = 0
, left = 0
}
]
<|
text "Confidence:"
)
|> el [ F.color colourTheme.textLightOrange ]
]
]
strengthMakerBar : Argument -> Element msg
strengthMakerBar argument =
barPadding
[ barMaker getConfidenceTooltip argument.argumentCertainty ]
<|
detailTitleMaker TextLightOrange "Confidence:"
getConfidenceTooltip : Int -> String
@ -510,12 +288,7 @@ tableMaker device argument =
, E.width fill
]
[ el
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
, E.alignLeft
, E.width fill
[ E.width fill
, htmlAttribute <| H.style "position" "relative"
]
<|
@ -552,15 +325,14 @@ tableMaker device argument =
, E.width fill
]
<|
el [ F.color colourTheme.textLightOrange ] <|
text "Definiendum"
detailTitleMaker
TextLightOrange
"Definiendum"
, width = fill |> maximum 30
, view =
\definition ->
el
[ F.color colourTheme.textLightOrange
, F.bold
, D.widthEach
[ D.widthEach
{ bottom = 1
, top = 0
, left = 1
@ -571,13 +343,16 @@ tableMaker device argument =
, E.height fill
]
<|
el [ centerX ] <|
paragraph [] [ text definition.definiendum ]
el
[ centerX
, centerY
]
<|
paragraph [] [ detailTitleMaker TextLightOrange definition.definiendum ]
}
, { header =
el
[ F.bold
, D.widthEach
[ D.widthEach
{ bottom = 1
, top = 1
, left = 0
@ -588,17 +363,12 @@ tableMaker device argument =
, E.width fill
]
<|
el
[ F.color colourTheme.textLightOrange ]
<|
text "Definiens"
detailTitleMaker TextLightOrange "Definiens"
, width = fill
, view =
\definition ->
el
[ F.color colourTheme.textLightGrey
, F.regular
, D.widthEach
[ D.widthEach
{ bottom = 1
, top = 0
, left = 0
@ -610,25 +380,15 @@ tableMaker device argument =
]
<|
el [] <|
paragraph [] [ text definition.definiens ]
paragraph [] [ detailBodyMaker TextLightGrey (text definition.definiens) ]
}
]
}
]
argumentDesktopPadding : Attribute msg
argumentDesktopPadding =
paddingXY 40 3
desktopFormalizationMaker : Argument -> Element msg
desktopFormalizationMaker argument =
formalizationMaker argument argumentDesktopPadding
formalizationMaker : Argument -> Attribute msg -> Element msg
formalizationMaker argument padding =
formalizationMaker : Argument -> Element msg
formalizationMaker argument =
column
[ centerX
, E.width fill
@ -637,57 +397,42 @@ formalizationMaker argument padding =
(List.indexedMap
(\index argumentEntry ->
column
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, spacing 3
, centerX
, E.width fill
, padding
[ paddingXY 40 3
]
(List.indexedMap
(\entryIndex entryWithNotation ->
column
[ centerX
, F.center
, spacing 3
, detailSpacing
, E.width fill
]
[ paragraph
[ F.color colourTheme.textLightOrange
, F.bold
, spacing 3
, paragraphFontSize
]
[ text
[ width fill ]
[ detailTitleMaker
TextLightOrange
(if entryIndex < List.length argumentEntry.premises then
"P" ++ String.fromInt (entryIndex + 1) ++ ") "
else
"C) "
)
, text
(if entryIndex < List.length argumentEntry.premises then
entryWithNotation.premise
, detailBodyMaker TextLightGrey
(text
(if entryIndex < List.length argumentEntry.premises then
entryWithNotation.premise
else
argumentEntry.conclusion
else
argumentEntry.conclusion
)
)
|> el
[ F.color colourTheme.textLightGrey
, F.regular
, E.width fill
]
[]
]
, paragraph
[ centerX
, F.center
, spacing 3
, E.width fill
, F.color colourTheme.textLightOrange
, F.bold
]
[ text
[]
[ detailTitleMaker
TextLightOrange
(if entryIndex < List.length argumentEntry.premises then
"(" ++ entryWithNotation.notation ++ ")"

View file

@ -1,8 +1,9 @@
module Pages.Debate.Cucklist exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Inner.Helpers exposing (detailBodyMaker, detailFormat, detailSpacing, detailTitleLink, detailTitleMaker, numberedListItem)
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Converters exposing (formatSocial)
import Config.Helpers.Format
exposing
@ -28,7 +29,7 @@ import Config.Pages.Debate.Cuckery.List
, cuckListNumber
)
import Config.Pages.Debate.Cuckery.Types exposing (..)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (ThemeColor(..), colourTheme, textLightGrey)
import Config.Style.Images exposing (imageSquareMaker)
import Config.Style.Transitions
exposing
@ -152,7 +153,7 @@ contentList device cuck =
[ alignRight
, alignTop
, paddingEach
{ top = 3
{ top = 0
, right = 10
, bottom = 0
, left = 0
@ -161,7 +162,7 @@ contentList device cuck =
<|
imageSquareMaker device (imagePathMaker M.Cuck cuck.cuckImage) True size
in
[ row [ width fill ]
[ detailFormat row
[ case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
image "Smallish"
@ -170,26 +171,8 @@ contentList device cuck =
image "Smallish"
_ ->
image "Medium"
, column
[ width fill
, spacing 3
, paddingEach
{ top =
case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
3
( Tablet, Portrait ) ->
3
_ ->
0
, right = 0
, bottom = 0
, left = 0
}
]
image "Test"
, detailFormat column
[ socialMaker cuck
, dodgeTitle cuck
, dodgeMaker device cuck
@ -212,93 +195,29 @@ dodgeMaker device cuck =
socialMaker : Cuck -> Element msg
socialMaker cuck =
paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, F.bold
, headerFontSizeSmall
, spacing 8
]
[ text "Social: "
, newTabLink
[ paragraphFontSize
, F.color colourTheme.textLightOrange
]
{ url = cuck.cuckSocial
, label =
el
[ transitionStyleSlow
, hoverFontDarkOrange
]
<|
text (formatSocial cuck.cuckSocial)
}
]
newTabLink
[]
{ url = cuck.cuckSocial
, label =
detailTitleLink
TextLightOrange
(formatSocial cuck.cuckSocial)
}
dodgeTitle : Cuck -> Element msg
dodgeTitle cuck =
paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, F.bold
, headerFontSizeSmall
]
[ text "Dodges: " ]
detailTitleMaker
TextLightGrey
"Dodges: "
makeDodge : Device -> Cuck -> Dodge -> Int -> Element msg
makeDodge device cuck dodge index =
column
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, alignLeft
, spacing 8
, width fill
]
[ row
[ width fill
, case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
moveLeft 40
( Tablet, Portrait ) ->
moveLeft 40
_ ->
paddingEach
{ top = 0
, right = 0
, bottom = 0
, left = 10
}
]
[ column
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, headerFontSizeSmall
, alignTop
, alignRight
, F.alignRight
]
[ text (String.fromInt index ++ ". ") ]
, column
[ spacing 3
, width fill
]
[ circumstanceMaker cuck dodge
, column
[ spacing 3
, width fill
]
[ propositionMaker device dodge
, reductioMaker device dodge
, attitudeMaker device dodge
, reasonMaker device dodge
]
]
]
detailFormat row
[ numberedListItem TextLightGrey index
, detailFormat column
(dodgeRows device cuck dodge)
]
@ -317,64 +236,45 @@ formatProposition proposition =
dodgeCounter : Int -> Element msg
dodgeCounter index =
column
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, headerFontSizeSmall
]
[ text (String.fromInt index ++ ". ") ]
detailTitleMaker TextLightGrey
(String.fromInt index ++ ". ")
circumstanceMaker : Cuck -> Dodge -> Element msg
circumstanceMaker cuck dodge =
el
[ spacing 5
]
<|
newTabLink
[ paragraphFontSize
, F.color colourTheme.textLightOrange
]
{ url = dodge.dodgeLink
, label =
el
[ headerFontSizeSmall
]
<|
circumstance cuck dodge
}
newTabLink
[]
{ url = dodge.dodgeLink
, label = circumstance cuck dodge
}
circumstance : Cuck -> Dodge -> Element msg
circumstance cuck dodge =
paragraph
[]
[ el
[ transitionStyleSlow
, hoverFontDarkOrange
]
<|
case dodge.dodgeDescription of
detailFormat paragraph
[ detailTitleLink TextLightOrange
(case dodge.dodgeDescription of
NoReply ->
text "Debate invitation extended with no response"
"Debate invitation extended with no response"
RanAway ->
text "Engaged in written debate and ran away when cornered"
"Engaged in written debate and ran away when cornered"
GhostedMe ->
text "Debate invitation accepted with no follow-up"
"Debate invitation accepted with no follow-up"
OutrightNo ->
text "Debate invitation declined"
"Debate invitation declined"
InTooDeep ->
text "Debate invitation accepted and subsequently retracted"
"Debate invitation accepted and subsequently retracted"
KillScreen ->
text "All further debate invitations preemptively declined"
"All further debate invitations preemptively declined"
VagueGesture ->
text "Chose to gesture vaguely instead of engaging"
"Chose to gesture vaguely instead of engaging"
)
, el [ F.color colourTheme.textLightGrey ] <|
text "."
@ -414,92 +314,83 @@ receipts cuck dodge =
dodge.dodgeReceipts
propositionMaker : Device -> Dodge -> Element msg
propositionMaker device dodge =
(case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
column
infoRow : Device -> String -> Element msg -> Element msg
infoRow device label value =
detailFormat
(case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
column
( Tablet, Portrait ) ->
column
( Tablet, Portrait ) ->
column
_ ->
row
)
(if String.isEmpty label then
[ detailBodyMaker TextLightGrey value ]
else
[ el
[ width <| px 75
, alignTop
]
<|
detailTitleMaker TextLightGrey label
, detailBodyMaker TextLightGrey value
]
)
dodgeRows : Device -> Cuck -> Dodge -> List (Element msg)
dodgeRows device cuck dodge =
[ infoRow device "" (circumstanceMaker cuck dodge)
, infoRow device "Prop:" (text (formatProposition dodge.dodgeProposition))
, case dodge.dodgeFallacy of
Nothing ->
none
_ ->
row
)
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
]
[ paragraph
[ alignTop
, dodgeWidth
]
[ text "Proposition:"
]
, paragraph
[ E.width fill
, alignLeft
]
[ paragraph [ F.regular ] [ text (formatProposition dodge.dodgeProposition) ]
]
]
infoRow device "Fallacy:" (reductioMaker device dodge)
, infoRow device "Attitude:" (attitudeMaker device dodge)
, infoRow device "Reason:" (reasonMaker device dodge)
]
attitudeMaker : Device -> Dodge -> Element msg
attitudeMaker device dodge =
(case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
column
detailFormat paragraph
[ case dodge.dodgeNicksDoxasticState of
Nothing ->
paragraph [ F.regular ] [ text "I don't form a doxastic state." ]
( Tablet, Portrait ) ->
column
Just Belief ->
paragraph [ F.regular ]
[ text "I lean more toward "
, el [ F.bold ] (text "TRUE")
, text " than false."
]
_ ->
row
)
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
, width fill
]
[ paragraph
[ alignTop
, dodgeWidth
]
[ text "Attitude:"
]
, paragraph
[ E.width fill
, alignLeft
]
[ case dodge.dodgeNicksDoxasticState of
Nothing ->
paragraph [ F.regular ] [ text "I don't form a doxastic state." ]
Just Disbelief ->
paragraph [ F.regular ]
[ text "I lean more toward "
, text "FALSE" |> el [ F.bold ]
, text " than true."
]
Just Belief ->
paragraph [ F.regular ]
[ text "I lean more toward "
, el [ F.bold ] (text "TRUE")
, text " than false."
]
Just Disbelief ->
paragraph [ F.regular ]
[ text "I lean more toward "
, text "FALSE" |> el [ F.bold ]
, text " than true."
]
Just Agnostic ->
el [ F.regular ] (text "I don't form beliefs about this proposition.")
]
Just Agnostic ->
el [ F.regular ] (text "I don't form beliefs about this proposition.")
]
reductioMaker : Device -> Dodge -> Element msg
reductioMaker device dodge =
let
displayFallacy : String -> Element msg
displayFallacy fallacyText =
detailFormat paragraph
[ text fallacyText ]
in
case dodge.dodgeFallacy of
Nothing ->
none
@ -511,106 +402,50 @@ reductioMaker device dodge =
none
else
displayFallacy device str
displayFallacy str
AppealToNature ->
displayFallacy device "Appeal to Nature"
displayFallacy "Appeal to Nature"
AppealToTradition ->
displayFallacy device "Appeal to Tradition"
displayFallacy "Appeal to Tradition"
AppealToIgnorance ->
displayFallacy device "Appeal to Ignorance"
displayFallacy "Appeal to Ignorance"
AppealFromIncredulity ->
displayFallacy device "Appeal from Incredulity"
displayFallacy "Appeal from Incredulity"
RedHerring ->
displayFallacy device "Red Herring"
displayFallacy "Red Herring"
BeggingTheQuestion ->
displayFallacy device "Begging the Question"
displayFallacy "Begging the Question"
Strawman ->
displayFallacy device "Strawman"
displayFallacy "Strawman"
Equivocation ->
displayFallacy device "Equivocation"
displayFallacy "Equivocation"
GeneticFallacy ->
displayFallacy device "Genetic Fallacy"
displayFallacy "Genetic Fallacy"
MotteAndBailey ->
displayFallacy device "Motte and Bailey"
displayFallacy "Motte and Bailey"
reasonMaker : Device -> Dodge -> Element msg
reasonMaker device dodge =
(case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
column
detailFormat paragraph
[ text <|
case dodge.dodgeNicksDoxasticReason of
NoProp ->
"There is no proposition to evaluate."
( Tablet, Portrait ) ->
column
VagueProp ->
"The proposition is too vague to evaluate."
_ ->
row
)
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
, width fill
]
[ paragraph
[ alignTop
, dodgeWidth
]
[ text "Reason:"
]
, paragraph [ F.regular ]
[ text <|
case dodge.dodgeNicksDoxasticReason of
NoProp ->
"There is no proposition to evaluate."
VagueProp ->
"The proposition is too vague to evaluate."
SpecificPropReason str ->
str
]
]
displayFallacy : Device -> String -> Element msg
displayFallacy device fallacyText =
(case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
column
( Tablet, Portrait ) ->
column
_ ->
row
)
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
]
[ paragraph
[ alignTop
, dodgeWidth
]
[ text "Fallacy:"
]
, paragraph
[ E.width fill
, alignLeft
]
[ paragraph [ F.regular ]
[ text fallacyText ]
]
SpecificPropReason str ->
str
]

View file

@ -1,8 +1,8 @@
module Pages.Debate.Gibberish exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Converters exposing (toTitleCase)
import Config.Helpers.Format
exposing
@ -37,7 +37,7 @@ import Config.Pages.Debate.Gibberish.Records.PhilOfLanguage exposing (philOfLang
import Config.Pages.Debate.Gibberish.Records.PhilOfMind exposing (philOfMindGibberish)
import Config.Pages.Debate.Gibberish.Records.Theology exposing (theologyGibberish)
import Config.Pages.Debate.Gibberish.Types exposing (..)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (colourTheme)
import Config.Style.Images exposing (imageSquareMaker)
import Effect exposing (Effect)
import Element as E exposing (..)

View file

@ -1,8 +1,8 @@
module Pages.Donate exposing (Model, Msg, page)
import Config.Data.Identity as I exposing (..)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format
exposing
( headerFontSizeSmall
@ -34,7 +34,7 @@ import Config.Pages.Donate.Records.PayPal exposing (donatePayPal)
import Config.Pages.Donate.Records.Stripe exposing (donateStripe)
import Config.Pages.Donate.Records.YouTube exposing (donateYouTube)
import Config.Pages.Donate.Types exposing (..)
import Config.Style.Colour as T exposing (..)
import Config.Style.Colour.Helpers as T exposing (..)
import Config.Style.Images exposing (imageSquareMaker)
import Effect exposing (Effect)
import Element as E exposing (..)

View file

@ -13,7 +13,7 @@ import Config.Helpers.Response
, topLevelContainer
)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (colourTheme)
import Config.Style.Glow exposing (glowDeepDarkGrey)
import Config.Style.Icons.Icons
exposing

View file

@ -1,8 +1,9 @@
module Pages.Interviews exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Inner.Helpers exposing (..)
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Converters exposing (formatSocial)
import Config.Helpers.Format
exposing
@ -26,6 +27,7 @@ import Config.Helpers.StrengthBar
)
import Config.Helpers.ToolTip exposing (tooltip)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Debate.Cuckery.List exposing (cuckListNumber)
import Config.Pages.Interviews.Records.DrShawnBakerPodcast exposing (drShawnBakerPodcast)
import Config.Pages.Interviews.Records.FitAndFurious exposing (fitAndFurious)
import Config.Pages.Interviews.Records.FoolproofMastery exposing (foolproofMastery)
@ -36,7 +38,7 @@ import Config.Pages.Interviews.Records.MuscleMemoirsPodcast exposing (muscleMemo
import Config.Pages.Interviews.Records.SigmaNutritionRadio exposing (sigmaNutritionRadio)
import Config.Pages.Interviews.Records.StrenuousLifePodcast exposing (strenuousLifePodcast)
import Config.Pages.Interviews.Types exposing (..)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (ThemeColor(..), colourTheme)
import Config.Style.Images exposing (imageSquareMaker)
import Config.Style.Transitions
exposing
@ -177,6 +179,18 @@ contentList device interview =
]
<|
imageSquareMaker device (imagePathMaker M.Interviews interview.interviewImage) True size
imageMaker : Element msg
imageMaker =
case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
image "Smallish"
( Tablet, Portrait ) ->
image "Smallish"
_ ->
image "Test"
in
[ row
[ paddingEach
@ -185,80 +199,19 @@ contentList device interview =
, bottom = 0
, left = 0
}
, detailSpacing
, width fill
]
[ case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
image "Smallish"
( Tablet, Portrait ) ->
image "Smallish"
_ ->
image "Medium"
, column
[ width fill
]
[ socialMaker interview
, appearanceTitle interview
[ imageMaker
, detailFormat column
[ socialMaker interview.interviewSocial interview.interviewSocial
, detailTitleMaker TextLightGrey "Appearances:"
, appearanceMaker interview
]
]
, el
[ paddingEach
{ top = 0
, right = 0
, bottom = 0
, left =
case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
5
( Tablet, Portrait ) ->
5
_ ->
55
}
]
<|
appearanceMaker interview
]
socialMaker : Interview -> Element msg
socialMaker interview =
paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, F.bold
, headerFontSizeSmall
]
[ newTabLink
[ paragraphFontSize
, F.color colourTheme.textLightOrange
]
{ url = interview.interviewSocial
, label =
el
[ transitionStyleSlow
, hoverFontDarkOrange
]
<|
text (formatSocial interview.interviewSocial)
}
]
appearanceTitle : Interview -> Element msg
appearanceTitle interview =
paragraph
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, headerFontSizeSmall
, F.bold
]
[ text "Appearances: " ]
appearanceMaker : Interview -> Element msg
appearanceMaker interview =
column [ spacing 10, width fill ] <|
@ -269,55 +222,24 @@ appearanceMaker interview =
makeAppearance : Appearance -> Int -> Element msg
makeAppearance appearanceEntry index =
el
[ alignLeft
, width fill
detailFormat row
[ listCounter index
, detailFormat column
[ episodeMaker appearanceEntry
, experienceMaker appearanceEntry
, dateMaker appearanceEntry
, subjectMaker appearanceEntry
, subjectList appearanceEntry
]
]
<|
row
[ E.width fill
, spacing 3
]
[ el
[ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
, alignTop
, F.alignRight
]
<|
text (String.fromInt index ++ ". ")
, column
[ width fill
, spacing 3
]
[ episodeMaker appearanceEntry
, experienceMaker appearanceEntry
, dateMaker appearanceEntry
, subjectMaker appearanceEntry
, subjectList appearanceEntry
]
]
episodeMaker : Appearance -> Element msg
episodeMaker appearanceEntry =
newTabLink
[ paragraphFontSize
, F.color colourTheme.textLightOrange
]
[]
{ url = appearanceEntry.appearanceLink
, label =
paragraph
[ headerFontSizeSmall
]
[ text ("#" ++ appearanceEntry.appearanceEpisode ++ ": " ++ appearanceEntry.appearanceTitle)
|> el
[ F.color colourTheme.textLightOrange
, hoverFontDarkOrange
]
]
, label = detailTitleMaker TextLightOrange ("#" ++ appearanceEntry.appearanceEpisode ++ ": " ++ appearanceEntry.appearanceTitle)
}
@ -468,3 +390,4 @@ makeSubject subjects =
, paragraphFontSize
]
[ text (" " ++ subjects.subject) ]

View file

@ -1,8 +1,8 @@
module Pages.NotFound_ exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Headers.Helpers exposing (..)
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Response

View file

@ -3,12 +3,12 @@ module Pages.Nutridex exposing (Model, Msg, page)
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Articles.Article exposing (makeReference)
import Config.Helpers.Articles.Types exposing (References)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Inner.Helpers exposing (detailBodyMaker, detailFormat, detailTitleMaker)
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format
exposing
( divider
, headerFontSizeBig
( headerFontSizeBig
, headerFontSizeSmall
, paragraphFontSize
, paragraphSpacing
@ -23,6 +23,7 @@ import Config.Helpers.Response
( pageList
, topLevelContainer
)
import Config.Helpers.ServiceFormat exposing (divider)
import Config.Helpers.StrengthBar
exposing
( barMaker
@ -32,7 +33,7 @@ import Config.Helpers.ToolTip exposing (tooltip)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Products.Records.NutriDex exposing (productNutriDex)
import Config.Pages.Products.Types exposing (..)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (ThemeColor(..), colourTheme)
import Config.Style.Glow exposing (glowDeepDarkGrey)
import Config.Style.Icons.Icons exposing (nutriDexLogo)
import Config.Style.Transitions
@ -176,7 +177,7 @@ contentList device nutridex =
makeFeature : Features -> Element msg
makeFeature features =
column
el
[ E.width fill
, alignLeft
, paddingEach
@ -186,31 +187,14 @@ makeFeature features =
, left = 8
}
]
[ row [ E.width fill ]
[ column [ E.width fill ]
[ paragraph [ F.regular, F.alignLeft ]
[ text " ", el [ F.bold, F.color colourTheme.textLightOrange ] (text features.featureTitle), text features.feature ]
<|
detailFormat column
[ detailFormat paragraph
[ text " "
, detailTitleMaker TextLightOrange features.featureTitle
, detailBodyMaker TextLightGrey (text features.feature |> el [ smallTextFontSize ])
]
]
]
price : Element msg
price =
newTabLink []
{ url = "https://uprootnutrition.myshopify.com/cart/31192710807615:1?channel=buy_button"
, label =
row
[ F.center
, paddingEach
{ top = 3
, right = 0
, bottom = 0
, left = 0
}
]
[ text "$19.99" ]
}
featureList : NutriDex -> Device -> Element msg
@ -714,7 +698,6 @@ nutriDexFattyAcids =
{ url = "https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5946201/"
, label = text "17"
}
, text ", "
, newTabLink referenceFormat
{ url = "https://www.ncbi.nlm.nih.gov/pmc/articles/PMC5452278/"
, label = text "18"

View file

@ -2,8 +2,16 @@ module Pages.Services exposing (Model, Msg, page)
import Browser
import Config.Data.Identity exposing (pageNames)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Inner.Helpers
exposing
( detailBodyMaker
, detailFormat
, detailTitleMaker
, listItem
, listMaker
)
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format
exposing
( headerFontSizeMedium
@ -20,6 +28,7 @@ import Config.Helpers.Response
( pageList
, topLevelContainer
)
import Config.Helpers.ServiceFormat exposing (divider)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Services.Records.DebateAnalysis exposing (..)
import Config.Pages.Services.Records.DebateCoaching exposing (..)
@ -27,7 +36,7 @@ import Config.Pages.Services.Records.ElmBuilds exposing (..)
import Config.Pages.Services.Records.NixBuilds exposing (..)
import Config.Pages.Services.Records.NutritionScience exposing (..)
import Config.Pages.Services.Types exposing (..)
import Config.Style.Colour as T exposing (..)
import Config.Style.Colour.Helpers as T exposing (..)
import Config.Style.Glow exposing (glowDeepDarkGrey, glowDeepDarkOrange)
import Config.Style.Images exposing (imageSquareMaker)
import Config.Style.Transitions exposing (transitionStyleMedium)
@ -160,93 +169,45 @@ contentList device service =
<|
imageSquareMaker device (imagePathMaker M.ServicePage service.serviceImage) True size
in
[ row []
[ image "Small"
, column [ alignBottom ]
[ detailFormat row
[ case ( device.class, device.orientation ) of
( Phone, Portrait ) ->
none
( Tablet, Portrait ) ->
none
_ ->
image "Test"
, detailFormat column
[ rateMaker service
, descriptionMaker service
, descriptionMaker
, offeringMaker service
]
]
, offeringMaker service
]
serviceWidth =
width <| px 45
rateMaker : Service msg -> Element msg
rateMaker service =
row
[ F.color colourTheme.textLightOrange
, paragraphSpacing
, F.bold
, headerFontSizeSmall
, E.width fill
]
[ column
[ alignTop
, serviceWidth
]
[ E.text "Rate:"
]
, column
[ E.width fill
, alignLeft
]
[ el
[ F.regular
, paragraphFontSize
, F.color colourTheme.textLightGrey
]
<|
E.text service.serviceRate
]
detailFormat row
[ detailTitleMaker TextLightOrange "Rate:"
, el [ width fill ] <| detailBodyMaker TextLightGrey (text service.serviceRate)
]
descriptionMaker : Service msg -> Element msg
descriptionMaker service =
row
[ F.color colourTheme.textLightOrange
, paragraphSpacing
, headerFontSizeSmall
, F.bold
]
[ column
[ alignTop
, width <| px 80
]
[ E.text "Offerings:"
]
]
descriptionMaker : Element msg
descriptionMaker =
detailTitleMaker TextLightOrange "Offerings:"
offeringMaker : Service msg -> Element msg
offeringMaker service =
column
[ spacing 8
, width fill
]
<|
List.map2 (\x y -> makeDescription x)
service.serviceDescription
(List.range 1 (List.length service.serviceDescription))
listMaker makeDescription service.serviceDescription
makeDescription : Description -> Element msg
makeDescription description =
column
([ F.color colourTheme.textLightGrey
, paragraphSpacing
, paragraphFontSize
, F.bold
, alignLeft
]
++ [ spacing 8
, width fill
]
)
[ paragraph [ F.regular ]
[ E.text (" " ++ description.point) ]
]
listItem
description.point
textLightGrey

View file

@ -1,7 +1,7 @@
module Pages.Services.Analysis exposing (Model, Msg, page)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C exposing (..)
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C exposing (..)
import Config.Helpers.Format exposing (..)
import Config.Helpers.Headers.Types exposing (Header)
import Config.Helpers.Price exposing (buyButton)
@ -10,7 +10,7 @@ import Config.Helpers.ServiceFormat exposing (..)
import Config.Helpers.ToolTip exposing (..)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Services.Records.DebateAnalysis exposing (..)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (colourTheme)
import Config.Style.Transitions
exposing
( hoverFontDarkOrange

View file

@ -1,7 +1,7 @@
module Pages.Services.Coaching exposing (Model, Msg, page)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format exposing (..)
import Config.Helpers.Headers.Helpers exposing (..)
import Config.Helpers.Headers.Types exposing (Header)
@ -15,7 +15,7 @@ import Config.Helpers.ServiceFormat exposing (..)
import Config.Helpers.ToolTip exposing (..)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Services.Records.DebateCoaching exposing (servicesDebateCoaching)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (colourTheme)
import Config.Style.Transitions
exposing
( hoverFontDarkOrange

View file

@ -1,7 +1,7 @@
module Pages.Services.Elm exposing (Model, Msg, page)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format exposing (..)
import Config.Helpers.Headers.Helpers exposing (..)
import Config.Helpers.Headers.Types exposing (Header)
@ -14,7 +14,7 @@ import Config.Helpers.ServiceFormat exposing (..)
import Config.Helpers.ToolTip exposing (..)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Services.Records.ElmBuilds exposing (servicesElmBuilds)
import Config.Style.Colour exposing (..)
import Config.Style.Colour.Helpers exposing (..)
import Config.Style.Transitions
exposing
( hoverFontDarkOrange

View file

@ -1,7 +1,7 @@
module Pages.Services.Nix exposing (Model, Msg, page)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format exposing (..)
import Config.Helpers.Headers.Helpers exposing (..)
import Config.Helpers.Headers.Types exposing (Header)
@ -14,7 +14,8 @@ import Config.Helpers.ServiceFormat exposing (..)
import Config.Helpers.ToolTip exposing (..)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Services.Records.NixBuilds exposing (servicesNixBuilds)
import Config.Style.Colour exposing (..)
import Config.Style.Colour.Helpers exposing (..)
import Config.Style.Colour.Types exposing (..)
import Config.Style.Transitions
exposing
( hoverFontDarkOrange

View file

@ -1,7 +1,7 @@
module Pages.Services.Nutrition exposing (Model, Msg, page)
import Config.Helpers.Cards.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Types as C
import Config.Helpers.Cards.Outer.Helpers exposing (cardMaker)
import Config.Helpers.Cards.Outer.Types as C
import Config.Helpers.Format exposing (..)
import Config.Helpers.Headers.Helpers exposing (..)
import Config.Helpers.Headers.Types exposing (Header)
@ -15,7 +15,7 @@ import Config.Helpers.ServiceFormat exposing (..)
import Config.Helpers.ToolTip exposing (..)
import Config.Helpers.Viewport exposing (resetViewport)
import Config.Pages.Services.Records.NutritionScience exposing (servicesNutritionScience)
import Config.Style.Colour exposing (colourTheme)
import Config.Style.Colour.Helpers exposing (colourTheme)
import Config.Style.Transitions
exposing
( hoverFontDarkOrange