Skip to content

Commit c06e5d6

Browse files
author
Harry Garrood
authored
Update dependencies, drop record-extra and typelevel-prelude (#42)
* Update dependencies, drop record-extra and typelevel-prelude This means that `bower install` in this repo now succeeds again. It also allows this project to build with purescript 0.13.0. I've dropped the typelevel-prelude dependency because we were only using re-exports from that. I've also dropped the record-extra dependency and used `rgb` directly for constructing colors so that we don't need the `mapRecord` call, as this is slightly safer (and doesn't require us to wait for record-extra to relax its upper bounds). * Fix warnings
1 parent 3da74fc commit c06e5d6

File tree

5 files changed

+35
-44
lines changed

5 files changed

+35
-44
lines changed

bower.json

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"purescript-coroutines": "^5.0.0",
1919
"purescript-fixed-precision": "^4.0.0",
2020
"purescript-foldable-traversable": "^4.0.0",
21-
"purescript-foreign-object": "^1.0.0",
21+
"purescript-foreign-object": ">= 1.0.0 < 3.0.0",
2222
"purescript-generics-rep": "^6.0.0",
2323
"purescript-foreign": "^5.0.0",
2424
"purescript-gen": "^2.0.0",
@@ -27,24 +27,22 @@
2727
"purescript-nullable": "^4.0.0",
2828
"purescript-numbers": "^6.0.0",
2929
"purescript-prelude": "^4.0.1",
30-
"purescript-profunctor-lenses": "^4.0.0",
30+
"purescript-profunctor-lenses": ">=4.0.0 <7.0.0",
3131
"purescript-random": "^4.0.0",
32-
"purescript-react-basic": "^8.0.0 || ^9.0.0",
32+
"purescript-react-basic": ">= 8.0.0 < 10.0.0",
3333
"purescript-react-dnd-basic": "^6.0.0",
34-
"purescript-record": "^1.0.0",
35-
"purescript-simple-json": "^4.0.0",
34+
"purescript-record": ">= 1.0.0 < 3.0.0",
35+
"purescript-simple-json": ">=4.0.0 <7.0.0",
3636
"purescript-strings": "^4.0.0",
3737
"purescript-tuples": "^5.0.0",
38-
"purescript-typelevel-prelude": "^3.0.0",
3938
"purescript-unsafe-reference": "^3.0.1",
40-
"purescript-web-html": "^1.0.0",
41-
"purescript-web-storage": "^2.0.0",
39+
"purescript-web-html": ">=1.0.0 <3.0.0",
40+
"purescript-web-storage": ">=2.0.0 <4.0.0",
4241
"purescript-validation": "^4.0.0",
4342
"purescript-js-timers": "^4.0.1",
44-
"purescript-heterogeneous": "^0.3.0",
43+
"purescript-heterogeneous": ">=0.3.0 <0.5.0",
4544
"purescript-free": "^5.1.0",
46-
"purescript-colors": "^5.0.0",
47-
"purescript-record-extra": "^2.0.2"
45+
"purescript-colors": "^5.0.0"
4846
},
4947
"devDependencies": {
5048
"purescript-debug": "^4.0.0",

src/Lumi/Components/Color.purs

Lines changed: 23 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,9 @@ module Lumi.Components.Color
66
, colorNames
77
) where
88

9-
import Prelude
10-
11-
import Color (rgba)
9+
import Color (rgb, rgba)
1210
import Color as C
13-
import Data.Maybe (fromMaybe)
1411
import Data.Newtype (class Newtype)
15-
import Record.Extra (mapRecord)
1612

1713
type Color = C.Color
1814

@@ -45,31 +41,29 @@ type ColorMap a =
4541
}
4642

4743
colors :: ColorMap Color
48-
colors = mapRecord (fromMaybe transparent <<< C.fromHexString)
49-
{ black: "#232220"
50-
, black1: "#91908d"
51-
, black2: "#bebcb9"
52-
, black3: "#dddddc"
53-
, black4: "#e7e6e5"
54-
, black5: "#f5f4f2"
55-
, black6: "#f7f6f4"
56-
, black7: "#f9f8f7"
57-
, black8: "#fbfaf9"
58-
, primary: "#0044e4"
59-
, primary1: "#a6bef6"
60-
, primary2: "#bfd0f8"
61-
, primary3: "#d9e3fb"
62-
, primary4: "#edf2fd"
63-
, secondary: "#91908d"
64-
, accent1: "#49b860"
65-
, accent2: "#ffa502"
66-
, accent3: "#f1500d"
67-
, accent33: "#fde5db"
68-
, white: "#ffffff"
69-
, transparent: "transparent"
44+
colors =
45+
{ black: rgb 0x23 0x22 0x20
46+
, black1: rgb 0x91 0x90 0x8d
47+
, black2: rgb 0xbe 0xbc 0xb9
48+
, black3: rgb 0xdd 0xdd 0xdc
49+
, black4: rgb 0xe7 0xe6 0xe5
50+
, black5: rgb 0xf5 0xf4 0xf2
51+
, black6: rgb 0xf7 0xf6 0xf4
52+
, black7: rgb 0xf9 0xf8 0xf7
53+
, black8: rgb 0xfb 0xfa 0xf9
54+
, primary: rgb 0x00 0x44 0xe4
55+
, primary1: rgb 0xa6 0xbe 0xf6
56+
, primary2: rgb 0xbf 0xd0 0xf8
57+
, primary3: rgb 0xd9 0xe3 0xfb
58+
, primary4: rgb 0xed 0xf2 0xfd
59+
, secondary: rgb 0x91 0x90 0x8d
60+
, accent1: rgb 0x49 0xb8 0x60
61+
, accent2: rgb 0xff 0xa5 0x02
62+
, accent3: rgb 0xf1 0x50 0x0d
63+
, accent33: rgb 0xfd 0xe5 0xdb
64+
, white: rgb 0xff 0xff 0xff
65+
, transparent: rgba 0 0 0 0.0
7066
}
71-
where
72-
transparent = rgba 0 0 0 0.0
7367

7468
colorNames :: ColorMap ColorName
7569
colorNames =

src/Lumi/Components/Form.purs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,15 +82,14 @@ import Lumi.Components.Select as Select
8282
import Lumi.Components.Text (body, body_, subsectionHeader, text)
8383
import Lumi.Components.Textarea as Textarea
8484
import Lumi.Components.Upload as Upload
85-
import Prim.Row (class Nub, class Union)
85+
import Prim.Row (class Nub, class Union, class Cons)
8686
import React.Basic (JSX, createComponent, element, empty, fragment, keyed, makeStateless)
8787
import React.Basic.Components.Async (async, asyncWithLoader)
8888
import React.Basic.DOM (css, unsafeCreateDOMComponent)
8989
import React.Basic.DOM as R
9090
import React.Basic.DOM.Events (capture, stopPropagation, targetChecked, targetValue)
9191
import React.Basic.Events as Events
9292
import Record (get)
93-
import Type.Row (class Cons)
9493
import Unsafe.Coerce (unsafeCoerce)
9594

9695
-- | Create a React component for a form from a `FormBuilder`.

src/Lumi/Components/Form/Defaults.purs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import Prim.Row (class Cons, class Lacks)
1515
import Prim.RowList (class RowToList, Cons, Nil)
1616
import Record.Builder (Builder)
1717
import Record.Builder as Builder
18-
import Type.Row (RLProxy(..))
18+
import Type.Data.RowList (RLProxy(..))
1919

2020
-- | Provides default values for primitive data types to be used as initial
2121
-- | values in form builders.

src/Lumi/Components/Modal.purs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import React.Basic.DOM as R
2323
import React.Basic.DOM.Events (currentTarget, stopPropagation, target)
2424
import React.Basic.Events as Events
2525
import Record (merge)
26-
import Type.Row (class Nub, class Union)
26+
import Prim.Row (class Nub, class Union)
2727

2828
foreign import toggleBodyClass :: EffectFn2 String Boolean Unit
2929

0 commit comments

Comments
 (0)