packages feed

HJScript 0.5.0 → 0.6.0

raw patch · 3 files changed

+86/−53 lines, 3 filesdep ~hsxPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: hsx

API changes (from Hackage documentation)

- HJScript.DOM.Node: class IsClass n => IsNode n
+ HJScript.DOM.Node: class IsClass n => IsNode n where castToNode = castObject castFromNode = castObject
- HJScript.XMLGenerator: genEElement :: XMLGen m => Name -> [XMLGenT m [Attribute m]] -> XMLGenT m (XML m)
+ HJScript.XMLGenerator: genEElement :: XMLGen m => Name -> [XMLGenT m [AttributeType m]] -> XMLGenT m (XMLType m)
- HJScript.XMLGenerator: genElement :: XMLGen m => Name -> [XMLGenT m [Attribute m]] -> [XMLGenT m [Child m]] -> XMLGenT m (XML m)
+ HJScript.XMLGenerator: genElement :: XMLGen m => Name -> [XMLGenT m [AttributeType m]] -> [XMLGenT m [ChildType m]] -> XMLGenT m (XMLType m)

Files

HJScript.cabal view
@@ -1,10 +1,10 @@ Name:             HJScript-Version:          0.5.0+Version:          0.6.0 License:          BSD3-Author:           Joel Bjornson, joel.bjornson@gmail.com,-                  Niklas Broberg, nibro@cs.chalmers.se-Maintainer:       joel.bjornson@gmail.com,-                  nibro@cs.chalmers.se+License-File:     LICENSE+Author:           Joel Bjornson, Niklas Broberg+Maintainer:       Joel Bjornson <joel.bjornson@gmail.com>,+                  Niklas Broberg <niklas.broberg@gmail.com>  Synopsis:         HJScript is a Haskell EDSL for writing JavaScript programs. Description:      HJScript is a DSL built on top of HJavaScript, for writing @@ -15,46 +15,52 @@                   as defined by the hsx package, for creating DOM ElementNodes.                    Also notable is that HJScript supports Ajax functionality. -Hs-Source-Dirs:   src-Exposed-Modules:  HJScript,-                  HJScript.Lang,-                  HJScript.Objects.Array-                  HJScript.Objects.Boolean-                  HJScript.Objects.JQuery-                  HJScript.Objects.Date-                  HJScript.Objects.Math-                  HJScript.Objects.Object-                  HJScript.Objects.RegExp-                  HJScript.Objects.String-                  HJScript.Objects.ActiveXObject-                  HJScript.Objects.XMLHttpRequest-                  HJScript.DOM,-                  HJScript.DOM.NodeTypes-                  HJScript.DOM.Node-                  HJScript.DOM.ElementNode-                  HJScript.DOM.AttributeNode-                  HJScript.DOM.TextNode-                  HJScript.DOM.NamedNodeMap-                  HJScript.DOM.Window-                  HJScript.DOM.Document-                  HJScript.DOM.XHTML-                  HJScript.XMLGenerator-                  HJScript.Events-                  HJScript.Ajax-                  HJScript.Utils-Other-Modules:    HJScript.Monad--                  -Cabal-Version:    >= 1.2.3-Build-Depends:    base < 5, HJavaScript >= 0.4.6, mtl, hsx >= 0.7.0+Homepage:         http://patch-tag.com/r/nibro/hjscript Build-Type:       Simple Category:         Web, Language+Cabal-Version:    >= 1.6 -Extensions:             MultiParamTypeClasses,-                        GADTs,-                        TypeFamilies,-                        FlexibleContexts,-                        FlexibleInstances,-                        TypeSynonymInstances,-                        OverlappingInstances,-                        UndecidableInstances+source-repository head+    type:     darcs+    location: http://patch-tag.com/r/nibro/hsx++Library+    Hs-Source-Dirs:   src+    Exposed-Modules:  HJScript,+                      HJScript.Lang,+                      HJScript.Objects.Array+                      HJScript.Objects.Boolean+                      HJScript.Objects.JQuery+                      HJScript.Objects.Date+                      HJScript.Objects.Math+                      HJScript.Objects.Object+                      HJScript.Objects.RegExp+                      HJScript.Objects.String+                      HJScript.Objects.ActiveXObject+                      HJScript.Objects.XMLHttpRequest+                      HJScript.DOM,+                      HJScript.DOM.NodeTypes+                      HJScript.DOM.Node+                      HJScript.DOM.ElementNode+                      HJScript.DOM.AttributeNode+                      HJScript.DOM.TextNode+                      HJScript.DOM.NamedNodeMap+                      HJScript.DOM.Window+                      HJScript.DOM.Document+                      HJScript.DOM.XHTML+                      HJScript.XMLGenerator+                      HJScript.Events+                      HJScript.Ajax+                      HJScript.Utils+    Other-Modules:    HJScript.Monad++    Build-Depends:    base < 5, HJavaScript >= 0.4.6, mtl, hsx >= 0.10.0 && < 0.11++    Extensions:       MultiParamTypeClasses,+                      GADTs,+                      TypeFamilies,+                      FlexibleContexts,+                      FlexibleInstances,+                      TypeSynonymInstances,+                      OverlappingInstances,+                      UndecidableInstances
+ LICENSE view
@@ -0,0 +1,28 @@+All rights reserved.++Redistribution and use in source and binary forms, with or without+modification, are permitted provided that the following conditions+are met:++1. Redistributions of source code must retain the above copyright+   notice, this list of conditions and the following disclaimer.++2. Redistributions in binary form must reproduce the above copyright+   notice, this list of conditions and the following disclaimer in the+   documentation and/or other materials provided with the distribution.++3. Neither the name of the author nor the names of his contributors+   may be used to endorse or promote products derived from this software+   without specific prior written permission.++THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR+IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE+DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS+OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)+HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,+STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN+ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE+POSSIBILITY OF SUCH DAMAGE.
src/HJScript/XMLGenerator.hs view
@@ -5,9 +5,8 @@         genElement, genEElement, asChild, asAttr, Attr(..)         ) where -import qualified HSX.XMLGenerator as HSX (XMLGen(..))-import HSX.XMLGenerator hiding (XMLGen(..))-import HSX.XMLGenerator (genElement, genEElement)+--import qualified HSX.XMLGenerator as HSX (XMLGen(..))+import HSX.XMLGenerator  import HJScript.Monad import HJScript.Lang@@ -22,10 +21,10 @@ type Child = Exp Node type Attribute = Exp AttributeNode -instance HSX.XMLGen HJScript' where- type HSX.XML          HJScript' = XML- newtype HSX.Child     HJScript' = HJSChild Child- newtype HSX.Attribute HJScript' = HJSAttr Attribute+instance XMLGen HJScript' where+ type XMLType          HJScript' = XML+ newtype ChildType     HJScript' = HJSChild Child+ newtype AttributeType HJScript' = HJSAttr Attribute  genElement = element  genEElement = eElement  xmlToChild = HJSChild . castToNode@@ -67,7 +66,7 @@ -- This instance should already be there, probably doesn't work due -- to type families not being fully supported yet. instance EmbedAsChild HJScript' XML where- asChild = return . return . HSX.xmlToChild+ asChild = return . return . xmlToChild  instance EmbedAsAttr HJScript' Attribute where  asAttr = asAttr . HJSAttr