Skip to content

Fix warnings revealed by v0.14.1 PS release #133

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ New features:
Bugfixes:

Other improvements:
- Fix warnings revealed by v0.14.1 PS release (#133 by @JordanMartinez)

## [v5.0.0](https://github.com/purescript-contrib/purescript-css/releases/tag/v5.0.0) - 2021-02-26

Expand Down
8 changes: 7 additions & 1 deletion spago.dhall
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
{ name = "css"
, dependencies =
[ "colors"
[ "arrays"
, "colors"
, "console"
, "effect"
, "either"
, "exceptions"
, "foldable-traversable"
, "maybe"
, "nonempty"
, "prelude"
, "profunctor"
, "psci-support"
, "strings"
, "these"
, "transformers"
, "tuples"
]
, packages = ./packages.dhall
, sources = [ "src/**/*.purs", "test/**/*.purs" ]
Expand Down
2 changes: 1 addition & 1 deletion src/CSS/Property.purs
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ instance valString :: Val String where
value = fromString

instance valUnit :: Val Unit where
value u = fromString ""
value _ = fromString ""

-- When `b` is Unit, the rendered value will have an extra
-- space appended to end. Shouldn't hurt. I'd fix if I knew how.
Expand Down
2 changes: 1 addition & 1 deletion src/CSS/Render.purs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ query' :: MediaQuery -> Array App -> Array Rule -> Rendered
query' q sel rs = Just <<< That <<< Sheet $ mediaQuery q <> " { " <> fromMaybe "" (renderedSheet $ rules sel rs) <> " }\n"

mediaQuery :: MediaQuery -> String
mediaQuery (MediaQuery no ty fs) = "@media " <> mediaType ty <> foldl1 (<>) ((" and " <> _) <<< feature <$> fs)
mediaQuery (MediaQuery _ ty fs) = "@media " <> mediaType ty <> foldl1 (<>) ((" and " <> _) <<< feature <$> fs)

mediaType :: MediaType -> String
mediaType (MediaType (Value s)) = plain s
Expand Down