Skip to content

Commit

Permalink
Add AoC 2024 banner
Browse files Browse the repository at this point in the history
  • Loading branch information
hojberg committed Dec 2, 2024
1 parent 05fe843 commit d1bf17e
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 24 deletions.
35 changes: 15 additions & 20 deletions src/UnisonShare/AppDocument.elm
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@ import Html exposing (Html, div)
import Html.Attributes exposing (class, id)
import Maybe.Extra as MaybeE
import UI
import UI.Button as Button
import UI.PageHeader as PageHeader exposing (PageHeader)
import UnisonShare.AppHeader as AppHeader exposing (AppHeader, AppHeaderContext)
import UnisonShare.Link as Link



Expand Down Expand Up @@ -89,26 +91,19 @@ map toMsgB { pageId, title, appHeader, pageHeader, page, modal } =

viewAnnouncement : Maybe (Html msg)
viewAnnouncement =
Nothing



{-
Just
(div [ id "announcement" ]
[ div [ class "announcement_content" ]
[ img [ src "https://www.unison-lang.org/assets/unison-forall.png", width 48 ] []
, Link.view
"The Unison Forall 2024 conference is coming up this September 20."
Link.conference
, Button.button_ Link.conference "Sign up for free"
|> Button.emphasized
|> Button.small
|> Button.view
]
]
)
-}
Just
(div [ id "announcement" ]
[ div [ class "announcement_content" ]
[ Link.view
"🎄 Season's Greetings! Join us for this year's Advent of Code puzzles."
Link.aoc2024
, Button.button_ Link.aoc2024 "Get started"
|> Button.emphasized
|> Button.small
|> Button.view
]
]
)


view : AppHeaderContext msg -> AppDocument msg -> Document msg
Expand Down
5 changes: 5 additions & 0 deletions src/UnisonShare/Link.elm
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ conference =
Click.externalHref "https://unison-lang.org/conference"


aoc2024 : Click msg
aoc2024 =
Click.externalHref "https://unison-lang.org/adventofcode2024"


whatsNew : Click msg
whatsNew =
Click.externalHref "https://unison-lang.org/whats-new"
Expand Down
8 changes: 4 additions & 4 deletions src/css/unison-share/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ body:has(#modal-overlay) {
}

#announcement {
--c-color_announcement_background: var(--color-purple-5);
--c-color_announcement_text: var(--color-gray-lighten-100);
--u-color_interactive: var(--color-purple-1);
--c-color_announcement_background: var(--color-green-4);
--c-color_announcement_text: var(--color-green-1);
--u-color_interactive: var(--color-green-0);

display: flex;
grid-area: announcement;
Expand All @@ -41,7 +41,7 @@ body:has(#modal-overlay) {
gap: 0.75rem;

& a:not(.button):hover {
color: var(--color-purple-2);
color: var(--color-pink-0);
}
}
}
Expand Down

0 comments on commit d1bf17e

Please sign in to comment.