mirror of
https://github.com/dillonkearns/elm-pages-v3-beta.git
synced 2025-01-03 17:31:58 +03:00
Remove unused code.
This commit is contained in:
parent
dc4ba8105d
commit
1e3bfe373a
@ -174,73 +174,6 @@ update msg model =
|
||||
( { model | showMobileMenu = not model.showMobileMenu }, Cmd.none )
|
||||
|
||||
|
||||
pageView :
|
||||
Int
|
||||
-> Model
|
||||
-> List ( PagePath Pages.PathKey, GlobalMetadata.Metadata )
|
||||
-> { path : PagePath Pages.PathKey, frontmatter : Metadata }
|
||||
-> ( MarkdownRenderer.TableOfContents, List (Element Msg) )
|
||||
-> { title : String, body : Element Msg }
|
||||
pageView stars model siteMetadata page viewForPage =
|
||||
case page.frontmatter of
|
||||
Metadata.Doc metadata ->
|
||||
{ title = metadata.title
|
||||
, body =
|
||||
[ Element.row []
|
||||
[ DocSidebar.view page.path siteMetadata
|
||||
|> Element.el [ Element.width (Element.fillPortion 2), Element.alignTop, Element.height Element.fill ]
|
||||
, Element.column [ Element.width (Element.fillPortion 8), Element.padding 35, Element.spacing 15 ]
|
||||
[ Palette.heading 1 [ Element.text metadata.title ]
|
||||
, Element.column [ Element.spacing 20 ]
|
||||
[ tocView (Tuple.first viewForPage)
|
||||
, Element.column
|
||||
[ Element.padding 50
|
||||
, Element.spacing 30
|
||||
, Element.Region.mainContent
|
||||
]
|
||||
(Tuple.second viewForPage)
|
||||
]
|
||||
]
|
||||
]
|
||||
]
|
||||
|> Element.textColumn
|
||||
[ Element.width Element.fill
|
||||
, Element.height Element.fill
|
||||
]
|
||||
}
|
||||
|
||||
_ ->
|
||||
Debug.todo ""
|
||||
|
||||
|
||||
{-| <https://developer.twitter.com/en/docs/tweets/optimize-with-cards/overview/abouts-cards>
|
||||
<https://htmlhead.dev>
|
||||
<https://html.spec.whatwg.org/multipage/semantics.html#standard-metadata-names>
|
||||
<https://ogp.me/>
|
||||
-}
|
||||
head : PagePath Pages.PathKey -> Metadata -> List (Head.Tag Pages.PathKey)
|
||||
head currentPath metadata =
|
||||
case metadata of
|
||||
Metadata.Doc meta ->
|
||||
Seo.summary
|
||||
{ canonicalUrlOverride = Nothing
|
||||
, siteName = "elm-pages"
|
||||
, image =
|
||||
{ url = images.iconPng
|
||||
, alt = "elm pages logo"
|
||||
, dimensions = Nothing
|
||||
, mimeType = Nothing
|
||||
}
|
||||
, locale = Nothing
|
||||
, description = siteTagline
|
||||
, title = meta.title
|
||||
}
|
||||
|> Seo.website
|
||||
|
||||
_ ->
|
||||
Debug.todo ""
|
||||
|
||||
|
||||
canonicalSiteUrl : String
|
||||
canonicalSiteUrl =
|
||||
"https://elm-pages.com"
|
||||
|
Loading…
Reference in New Issue
Block a user