packages feed

xlsx 1.1.1 → 1.1.2

raw patch · 5 files changed

+21/−5 lines, 5 files

Files

CHANGELOG.markdown view
@@ -1,3 +1,8 @@+1.1.2+------------+* Strip leading slash from target paths in relations as the ECMA-376 spec requires+  (thanks to Luke Clifton <lukec@themk.net>)+ 1.1.1 ------------ * dropped support for GHC 8.8.* and 8.10.* and added support for GHC 9.4.* and 9.6.*
src/Codec/Xlsx/Parser.hs view
@@ -700,9 +700,20 @@     c <- xmlCursorOptional ar relsPath     return $ maybe Relationships.empty (setTargetsFrom fp . headNote "Missing rels" . fromCursor) c +-- According to part 2, section 7.3.4 of ECMA-376, when mapping logical item+-- names to ZIP item names we need to remove the leading slash.+--+-- Non-ASCII characters should be percent-encoded as well, but this is not+-- currently implemented.+--+-- https://ecma-international.org/publications-and-standards/standards/ecma-376/+logicalNameToZipItemName :: FilePath -> FilePath+logicalNameToZipItemName ('/' : name) = name+logicalNameToZipItemName name = name+ lookupRelPath :: FilePath               -> Relationships               -> RefId               -> Either ParseError FilePath lookupRelPath fp rels rId =-  relTarget <$> note (InvalidRef fp rId) (Relationships.lookup rId rels)+  logicalNameToZipItemName . relTarget <$> note (InvalidRef fp rId) (Relationships.lookup rId rels)
src/Codec/Xlsx/Types/Internal/SharedStringTable.hs view
@@ -37,7 +37,7 @@ -- reading and writing the repetitive information once. -- -- Relevant parts of the EMCA standard (2nd edition, part 1,--- <http://www.ecma-international.org/publications/standards/Ecma-376.htm>),+-- <https://ecma-international.org/publications-and-standards/standards/ecma-376/>), -- page numbers refer to the page in the PDF rather than the page number as -- printed on the page): --
src/Codec/Xlsx/Types/StyleSheet.hs view
@@ -157,7 +157,7 @@ -- | StyleSheet for an XML document -- -- Relevant parts of the EMCA standard (4th edition, part 1,--- <http://www.ecma-international.org/publications/standards/Ecma-376.htm>),+-- <https://ecma-international.org/publications-and-standards/standards/ecma-376/>), -- page numbers refer to the page in the PDF rather than the page number as -- printed on the page): --
xlsx.cabal view
@@ -1,6 +1,6 @@ Name:                xlsx -Version:             1.1.1+Version:             1.1.2  Synopsis:            Simple and incomplete Excel file parser/writer Description:@@ -10,7 +10,7 @@     For examples look into "Codec.Xlsx".     .     Format is covered by ECMA-376 standard:-    <http://www.ecma-international.org/publications/standards/Ecma-376.htm>+    <https://ecma-international.org/publications-and-standards/standards/ecma-376/>     .     4th edition of the standard with the transitional schema is used for this library. Extra-source-files: