diff --git a/CHANGELOG.md b/CHANGELOG.md index 20f26bb..394b3d8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ New features: Bugfixes: Other improvements: +- `AttrName`, `ClassName`, and `PropName` types have been migrated to [web-dom](https://github.com/purescript-web/purescript-web-dom) but are re-exported to avoid breaking compatibility. See also purescript-web/purescript-web-dom#58. (#82 by @nsaunders) ## [v4.1.0](https://github.com/purescript-web/purescript-web-html/releases/tag/v4.1.0) - 2022-09-19 diff --git a/bower.json b/bower.json index c4dfd9e..96d4a00 100644 --- a/bower.json +++ b/bower.json @@ -16,8 +16,11 @@ ], "dependencies": { "purescript-js-date": "^8.0.0", - "purescript-web-dom": "^6.0.0", + "purescript-web-dom": "https://github.com/nsaunders/purescript-web-dom.git#8b1dfaa5cd", "purescript-web-file": "^4.0.0", "purescript-web-storage": "^5.0.0" + }, + "resolutions": { + "purescript-web-dom": "8b1dfaa5cd" } } diff --git a/src/Web/HTML/Common.purs b/src/Web/HTML/Common.purs index 6e5d8fa..23245e2 100644 --- a/src/Web/HTML/Common.purs +++ b/src/Web/HTML/Common.purs @@ -1,30 +1,3 @@ -module Web.HTML.Common where +module Web.HTML.Common (module Exports) where -import Prelude - -import Data.Newtype (class Newtype) - --- | A wrapper for property names. --- | --- | The phantom type `value` describes the type of value which this property --- | requires. -newtype PropName :: Type -> Type -newtype PropName value = PropName String - -derive instance newtypePropName :: Newtype (PropName value) _ -derive newtype instance eqPropName :: Eq (PropName value) -derive newtype instance ordPropName :: Ord (PropName value) - --- | A wrapper for attribute names. -newtype AttrName = AttrName String - -derive instance newtypeAttrName :: Newtype AttrName _ -derive newtype instance eqAttrName :: Eq AttrName -derive newtype instance ordAttrName :: Ord AttrName - --- | A wrapper for strings which are used as CSS classes. -newtype ClassName = ClassName String - -derive instance newtypeClassName :: Newtype ClassName _ -derive newtype instance eqClassName :: Eq ClassName -derive newtype instance ordClassName :: Ord ClassName +import Web.DOM.Element (AttrName(..), ClassName(..), PropName(..)) as Exports \ No newline at end of file