File tree Expand file tree Collapse file tree 5 files changed +16
-22
lines changed
ghcjs/delivery-calculator
pub/xlsx/src/Codec/Xlsx/Types Expand file tree Collapse file tree 5 files changed +16
-22
lines changed Original file line number Diff line number Diff line change 11cabal-version : 2.2
22name : delivery-calculator
3- version : 0.1.0.1
3+ version : 0.1.0.2
44synopsis : Delivery Calculator
55category : Web
66build-type : Simple
Original file line number Diff line number Diff line change @@ -18,9 +18,7 @@ newXlsx st imgs = xlsx
1818 xlsx =
1919 fromXlsx 0
2020 $ def
21- & # xlStyles
22- .~ renderStyleSheet style
23- & atSheet " Delivery_Calculator"
21+ & atSheet " Delivery Calculator"
2422 ?~ sheet
2523 sheet =
2624 def
@@ -70,18 +68,6 @@ newColProps rows = nubOrd $ do
7068 cpBestFit = False
7169 }
7270
73- style :: StyleSheet
74- style =
75- def
76- & # styleSheetCellXfs
77- .~ [ def
78- & # cellXfAlignment
79- ?~ ( def
80- & # _alignmentVertical
81- ?~ CellVerticalAlignmentCenter
82- )
83- ]
84-
8571addHeader :: St Unique -> Worksheet -> Worksheet
8672addHeader st sheet =
8773 case sortOn length headers of
@@ -173,7 +159,7 @@ addCol imgs sheet rowIdx colIdx field =
173159 . _Just
174160 %~ \ case
175161 Drawing xs ->
176- Drawing $ newImg rowIdx colIdx (length xs) img : xs
162+ Drawing $ newImg rowIdx colIdx (length xs + 1 ) img : xs
177163 where
178164 txt = field ^. # fieldInput . # uniqueValue
179165
@@ -190,12 +176,19 @@ newImg (RowIndex rowIdx) (ColumnIndex colIdx) imgIdx rfc2397 =
190176 anchClientData = def
191177 }
192178 where
179+ mime = decodeUtf8 $ rfc2397Mime rfc2397
180+ ext =
181+ from @ Text @ String
182+ . maybe mempty (" ." <> )
183+ . safeHead
184+ . reverse
185+ $ splitWhen (== ' /' ) mime
193186 obj =
194187 picture
195188 (DrawingElementId imgIdx)
196189 FileInfo
197- { fiFilename = " img " ,
198- fiContentType = decodeUtf8 $ rfc2397Mime rfc2397 ,
190+ { fiFilename = " image " <> inspect imgIdx <> ext ,
191+ fiContentType = mime ,
199192 fiContents = rfc2397Bytes rfc2397
200193 }
201194
Original file line number Diff line number Diff line change 11platforms :
22 android :
33 appName : Delivery Calculator
4- versionCode : 1
5- versionName : 0.1.0.1
4+ versionCode : 2
5+ versionName : 0.1.0.2
66 packageName : com.functora.delivery_calculator
77 manifest :
88 - file : AndroidManifest.xml
Original file line number Diff line number Diff line change 563563 xorg . xev
564564 yewtube
565565 niv
566+ zip
566567 unzip
567568 pciutils
568569 docker-compose
Original file line number Diff line number Diff line change @@ -139,7 +139,7 @@ picture dId fi =
139139 shProps =
140140 ShapeProperties
141141 { spXfrm = Nothing ,
142- spGeometry = Nothing ,
142+ spGeometry = Just PresetGeometry ,
143143 spFill = Just NoFill ,
144144 spOutline = Just $ def {_lnFill = Just NoFill }
145145 }
You can’t perform that action at this time.
0 commit comments